MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  1259lem5 Structured version   Visualization version   Unicode version

Theorem 1259lem5 15106
Description: Lemma for 1259prm 15107. Calculate the GCD of  2 ^ 3 4  -  1  ==  8 6 9 with  N  =  1 2 5 9. (Contributed by Mario Carneiro, 22-Feb-2014.) (Revised by Mario Carneiro, 20-Apr-2015.)
Hypothesis
Ref Expression
1259prm.1  |-  N  = ;;; 1 2 5 9
Assertion
Ref Expression
1259lem5  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  gcd  N
)  =  1

Proof of Theorem 1259lem5
StepHypRef Expression
1 2nn 10767 . . . 4  |-  2  e.  NN
2 3nn0 10887 . . . . 5  |-  3  e.  NN0
3 4nn0 10888 . . . . 5  |-  4  e.  NN0
42, 3deccl 11065 . . . 4  |- ; 3 4  e.  NN0
5 nnexpcl 12285 . . . 4  |-  ( ( 2  e.  NN  /\ ; 3 4  e.  NN0 )  -> 
( 2 ^; 3 4 )  e.  NN )
61, 4, 5mp2an 678 . . 3  |-  ( 2 ^; 3 4 )  e.  NN
7 nnm1nn0 10911 . . 3  |-  ( ( 2 ^; 3 4 )  e.  NN  ->  ( (
2 ^; 3 4 )  - 
1 )  e.  NN0 )
86, 7ax-mp 5 . 2  |-  ( ( 2 ^; 3 4 )  - 
1 )  e.  NN0
9 8nn0 10892 . . . 4  |-  8  e.  NN0
10 6nn0 10890 . . . 4  |-  6  e.  NN0
119, 10deccl 11065 . . 3  |- ; 8 6  e.  NN0
12 9nn0 10893 . . 3  |-  9  e.  NN0
1311, 12deccl 11065 . 2  |- ;; 8 6 9  e.  NN0
14 1259prm.1 . . 3  |-  N  = ;;; 1 2 5 9
15 1nn0 10885 . . . . . 6  |-  1  e.  NN0
16 2nn0 10886 . . . . . 6  |-  2  e.  NN0
1715, 16deccl 11065 . . . . 5  |- ; 1 2  e.  NN0
18 5nn0 10889 . . . . 5  |-  5  e.  NN0
1917, 18deccl 11065 . . . 4  |- ;; 1 2 5  e.  NN0
20 9nn 10774 . . . 4  |-  9  e.  NN
2119, 20decnncl 11064 . . 3  |- ;;; 1 2 5 9  e.  NN
2214, 21eqeltri 2525 . 2  |-  N  e.  NN
23141259lem2 15103 . . 3  |-  ( ( 2 ^; 3 4 )  mod 
N )  =  (;; 8 7 0  mod 
N )
24 6p1e7 10738 . . . . 5  |-  ( 6  +  1 )  =  7
25 eqid 2451 . . . . 5  |- ; 8 6  = ; 8 6
269, 10, 24, 25decsuc 11074 . . . 4  |-  (; 8 6  +  1 )  = ; 8 7
27 eqid 2451 . . . 4  |- ;; 8 6 9  = ;; 8 6 9
2811, 26, 27decsucc 11078 . . 3  |-  (;; 8 6 9  +  1 )  = ;; 8 7 0
2922, 6, 15, 13, 23, 28modsubi 15044 . 2  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  mod  N
)  =  (;; 8 6 9  mod  N
)
302, 12deccl 11065 . . . 4  |- ; 3 9  e.  NN0
31 0nn0 10884 . . . 4  |-  0  e.  NN0
3230, 31deccl 11065 . . 3  |- ;; 3 9 0  e.  NN0
339, 12deccl 11065 . . . 4  |- ; 8 9  e.  NN0
3416, 15deccl 11065 . . . . . 6  |- ; 2 1  e.  NN0
3515, 2deccl 11065 . . . . . . 7  |- ; 1 3  e.  NN0
3634nn0zi 10962 . . . . . . . . 9  |- ; 2 1  e.  ZZ
3735nn0zi 10962 . . . . . . . . 9  |- ; 1 3  e.  ZZ
38 gcdcom 14484 . . . . . . . . 9  |-  ( (; 2
1  e.  ZZ  /\ ; 1 3  e.  ZZ )  -> 
(; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 ) )
3936, 37, 38mp2an 678 . . . . . . . 8  |-  (; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 )
40 3nn 10768 . . . . . . . . . . 11  |-  3  e.  NN
4115, 40decnncl 11064 . . . . . . . . . 10  |- ; 1 3  e.  NN
42 8nn 10773 . . . . . . . . . 10  |-  8  e.  NN
43 eqid 2451 . . . . . . . . . . 11  |- ; 1 3  = ; 1 3
449dec0h 11067 . . . . . . . . . . 11  |-  8  = ; 0 8
45 ax-1cn 9597 . . . . . . . . . . . . . 14  |-  1  e.  CC
4645mulid1i 9645 . . . . . . . . . . . . 13  |-  ( 1  x.  1 )  =  1
4745addid2i 9821 . . . . . . . . . . . . 13  |-  ( 0  +  1 )  =  1
4846, 47oveq12i 6302 . . . . . . . . . . . 12  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  ( 1  +  1 )
49 1p1e2 10723 . . . . . . . . . . . 12  |-  ( 1  +  1 )  =  2
5048, 49eqtri 2473 . . . . . . . . . . 11  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  2
51 3cn 10684 . . . . . . . . . . . . . 14  |-  3  e.  CC
5251mulid1i 9645 . . . . . . . . . . . . 13  |-  ( 3  x.  1 )  =  3
5352oveq1i 6300 . . . . . . . . . . . 12  |-  ( ( 3  x.  1 )  +  8 )  =  ( 3  +  8 )
54 8cn 10695 . . . . . . . . . . . . 13  |-  8  e.  CC
55 8p3e11 11107 . . . . . . . . . . . . 13  |-  ( 8  +  3 )  = ; 1
1
5654, 51, 55addcomli 9825 . . . . . . . . . . . 12  |-  ( 3  +  8 )  = ; 1
1
5753, 56eqtri 2473 . . . . . . . . . . 11  |-  ( ( 3  x.  1 )  +  8 )  = ; 1
1
5815, 2, 31, 9, 43, 44, 15, 15, 15, 50, 57decmac 11090 . . . . . . . . . 10  |-  ( (; 1
3  x.  1 )  +  8 )  = ; 2
1
59 1nn 10620 . . . . . . . . . . 11  |-  1  e.  NN
60 8lt10 10813 . . . . . . . . . . 11  |-  8  <  10
6159, 2, 9, 60declti 11076 . . . . . . . . . 10  |-  8  < ; 1
3
6241, 15, 42, 58, 61ndvdsi 14391 . . . . . . . . 9  |-  -. ; 1 3  || ; 2 1
63 13prm 15087 . . . . . . . . . 10  |- ; 1 3  e.  Prime
64 coprm 14657 . . . . . . . . . 10  |-  ( (; 1
3  e.  Prime  /\ ; 2 1  e.  ZZ )  ->  ( -. ; 1 3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 ) )
6563, 36, 64mp2an 678 . . . . . . . . 9  |-  ( -. ; 1
3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 )
6662, 65mpbi 212 . . . . . . . 8  |-  (; 1 3  gcd ; 2 1 )  =  1
6739, 66eqtri 2473 . . . . . . 7  |-  (; 2 1  gcd ; 1 3 )  =  1
68 eqid 2451 . . . . . . . 8  |- ; 2 1  = ; 2 1
69 2cn 10680 . . . . . . . . . . 11  |-  2  e.  CC
7069mulid2i 9646 . . . . . . . . . 10  |-  ( 1  x.  2 )  =  2
7145addid1i 9820 . . . . . . . . . 10  |-  ( 1  +  0 )  =  1
7270, 71oveq12i 6302 . . . . . . . . 9  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  ( 2  +  1 )
73 2p1e3 10733 . . . . . . . . 9  |-  ( 2  +  1 )  =  3
7472, 73eqtri 2473 . . . . . . . 8  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  3
7546oveq1i 6300 . . . . . . . . 9  |-  ( ( 1  x.  1 )  +  3 )  =  ( 1  +  3 )
76 3p1e4 10735 . . . . . . . . . 10  |-  ( 3  +  1 )  =  4
7751, 45, 76addcomli 9825 . . . . . . . . 9  |-  ( 1  +  3 )  =  4
783dec0h 11067 . . . . . . . . 9  |-  4  = ; 0 4
7975, 77, 783eqtri 2477 . . . . . . . 8  |-  ( ( 1  x.  1 )  +  3 )  = ; 0
4
8016, 15, 15, 2, 68, 43, 15, 3, 31, 74, 79decma2c 11091 . . . . . . 7  |-  ( ( 1  x. ; 2 1 )  + ; 1
3 )  = ; 3 4
8115, 35, 34, 67, 80gcdi 15045 . . . . . 6  |-  (; 3 4  gcd ; 2 1 )  =  1
82 eqid 2451 . . . . . . 7  |- ; 3 4  = ; 3 4
83 3t2e6 10761 . . . . . . . . . 10  |-  ( 3  x.  2 )  =  6
8451, 69, 83mulcomli 9650 . . . . . . . . 9  |-  ( 2  x.  3 )  =  6
8569addid1i 9820 . . . . . . . . 9  |-  ( 2  +  0 )  =  2
8684, 85oveq12i 6302 . . . . . . . 8  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  ( 6  +  2 )
87 6p2e8 10751 . . . . . . . 8  |-  ( 6  +  2 )  =  8
8886, 87eqtri 2473 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  8
89 4cn 10687 . . . . . . . . . 10  |-  4  e.  CC
90 4t2e8 10763 . . . . . . . . . 10  |-  ( 4  x.  2 )  =  8
9189, 69, 90mulcomli 9650 . . . . . . . . 9  |-  ( 2  x.  4 )  =  8
9291oveq1i 6300 . . . . . . . 8  |-  ( ( 2  x.  4 )  +  1 )  =  ( 8  +  1 )
93 8p1e9 10740 . . . . . . . 8  |-  ( 8  +  1 )  =  9
9412dec0h 11067 . . . . . . . 8  |-  9  = ; 0 9
9592, 93, 943eqtri 2477 . . . . . . 7  |-  ( ( 2  x.  4 )  +  1 )  = ; 0
9
962, 3, 16, 15, 82, 68, 16, 12, 31, 88, 95decma2c 11091 . . . . . 6  |-  ( ( 2  x. ; 3 4 )  + ; 2
1 )  = ; 8 9
9716, 34, 4, 81, 96gcdi 15045 . . . . 5  |-  (; 8 9  gcd ; 3 4 )  =  1
98 eqid 2451 . . . . . 6  |- ; 8 9  = ; 8 9
99 4p3e7 10745 . . . . . . . . 9  |-  ( 4  +  3 )  =  7
10089, 51, 99addcomli 9825 . . . . . . . 8  |-  ( 3  +  4 )  =  7
101100oveq2i 6301 . . . . . . 7  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  =  ( ( 4  x.  8 )  +  7 )
102 7nn0 10891 . . . . . . . 8  |-  7  e.  NN0
103 8t4e32 11141 . . . . . . . . 9  |-  ( 8  x.  4 )  = ; 3
2
10454, 89, 103mulcomli 9650 . . . . . . . 8  |-  ( 4  x.  8 )  = ; 3
2
105 7cn 10693 . . . . . . . . 9  |-  7  e.  CC
106 7p2e9 10754 . . . . . . . . 9  |-  ( 7  +  2 )  =  9
107105, 69, 106addcomli 9825 . . . . . . . 8  |-  ( 2  +  7 )  =  9
1082, 16, 102, 104, 107decaddi 11095 . . . . . . 7  |-  ( ( 4  x.  8 )  +  7 )  = ; 3
9
109101, 108eqtri 2473 . . . . . 6  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  = ; 3
9
110 9cn 10697 . . . . . . . 8  |-  9  e.  CC
111 9t4e36 11148 . . . . . . . 8  |-  ( 9  x.  4 )  = ; 3
6
112110, 89, 111mulcomli 9650 . . . . . . 7  |-  ( 4  x.  9 )  = ; 3
6
113 6p4e10 10753 . . . . . . 7  |-  ( 6  +  4 )  =  10
1142, 10, 3, 112, 76, 113decaddci2 11097 . . . . . 6  |-  ( ( 4  x.  9 )  +  4 )  = ; 4
0
1159, 12, 2, 3, 98, 82, 3, 31, 3, 109, 114decma2c 11091 . . . . 5  |-  ( ( 4  x. ; 8 9 )  + ; 3
4 )  = ;; 3 9 0
1163, 4, 33, 97, 115gcdi 15045 . . . 4  |-  (;; 3 9 0  gcd ; 8 9 )  =  1
117 eqid 2451 . . . . 5  |- ;; 3 9 0  = ;; 3 9 0
118 eqid 2451 . . . . . 6  |- ; 3 9  = ; 3 9
11954addid1i 9820 . . . . . . 7  |-  ( 8  +  0 )  =  8
120119, 44eqtri 2473 . . . . . 6  |-  ( 8  +  0 )  = ; 0
8
12169addid2i 9821 . . . . . . . 8  |-  ( 0  +  2 )  =  2
12284, 121oveq12i 6302 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  ( 6  +  2 )
123122, 87eqtri 2473 . . . . . 6  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  8
124 9t2e18 11146 . . . . . . . 8  |-  ( 9  x.  2 )  = ; 1
8
125110, 69, 124mulcomli 9650 . . . . . . 7  |-  ( 2  x.  9 )  = ; 1
8
126 8p8e16 11112 . . . . . . 7  |-  ( 8  +  8 )  = ; 1
6
12715, 9, 9, 125, 49, 10, 126decaddci 11096 . . . . . 6  |-  ( ( 2  x.  9 )  +  8 )  = ; 2
6
1282, 12, 31, 9, 118, 120, 16, 10, 16, 123, 127decma2c 11091 . . . . 5  |-  ( ( 2  x. ; 3 9 )  +  ( 8  +  0 ) )  = ; 8 6
129 2t0e0 10765 . . . . . . 7  |-  ( 2  x.  0 )  =  0
130129oveq1i 6300 . . . . . 6  |-  ( ( 2  x.  0 )  +  9 )  =  ( 0  +  9 )
131110addid2i 9821 . . . . . 6  |-  ( 0  +  9 )  =  9
132130, 131, 943eqtri 2477 . . . . 5  |-  ( ( 2  x.  0 )  +  9 )  = ; 0
9
13330, 31, 9, 12, 117, 98, 16, 12, 31, 128, 132decma2c 11091 . . . 4  |-  ( ( 2  x. ;; 3 9 0 )  + ; 8
9 )  = ;; 8 6 9
13416, 33, 32, 116, 133gcdi 15045 . . 3  |-  (;; 8 6 9  gcd ;; 3 9 0 )  =  1
13530nn0cni 10881 . . . . . . 7  |- ; 3 9  e.  CC
136135addid1i 9820 . . . . . 6  |-  (; 3 9  +  0 )  = ; 3 9
13754mulid2i 9646 . . . . . . . 8  |-  ( 1  x.  8 )  =  8
138137, 76oveq12i 6302 . . . . . . 7  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  =  ( 8  +  4 )
139 8p4e12 11108 . . . . . . 7  |-  ( 8  +  4 )  = ; 1
2
140138, 139eqtri 2473 . . . . . 6  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  = ; 1
2
141 6cn 10691 . . . . . . . . 9  |-  6  e.  CC
142141mulid2i 9646 . . . . . . . 8  |-  ( 1  x.  6 )  =  6
143142oveq1i 6300 . . . . . . 7  |-  ( ( 1  x.  6 )  +  9 )  =  ( 6  +  9 )
144 9p6e15 11117 . . . . . . . 8  |-  ( 9  +  6 )  = ; 1
5
145110, 141, 144addcomli 9825 . . . . . . 7  |-  ( 6  +  9 )  = ; 1
5
146143, 145eqtri 2473 . . . . . 6  |-  ( ( 1  x.  6 )  +  9 )  = ; 1
5
1479, 10, 2, 12, 25, 136, 15, 18, 15, 140, 146decma2c 11091 . . . . 5  |-  ( ( 1  x. ; 8 6 )  +  (; 3 9  +  0 ) )  = ;; 1 2 5
148110mulid2i 9646 . . . . . . 7  |-  ( 1  x.  9 )  =  9
149148oveq1i 6300 . . . . . 6  |-  ( ( 1  x.  9 )  +  0 )  =  ( 9  +  0 )
150110addid1i 9820 . . . . . 6  |-  ( 9  +  0 )  =  9
151149, 150, 943eqtri 2477 . . . . 5  |-  ( ( 1  x.  9 )  +  0 )  = ; 0
9
15211, 12, 30, 31, 27, 117, 15, 12, 31, 147, 151decma2c 11091 . . . 4  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  = ;;; 1 2 5 9
153152, 14eqtr4i 2476 . . 3  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  =  N
15415, 32, 13, 134, 153gcdi 15045 . 2  |-  ( N  gcd ;; 8 6 9 )  =  1
1558, 13, 22, 29, 154gcdmodi 15046 1  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  gcd  N
)  =  1
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    <-> wb 188    = wceq 1444    e. wcel 1887   class class class wbr 4402  (class class class)co 6290   0cc0 9539   1c1 9540    + caddc 9542    x. cmul 9544    - cmin 9860   NNcn 10609   2c2 10659   3c3 10660   4c4 10661   5c5 10662   6c6 10663   7c7 10664   8c8 10665   9c9 10666   NN0cn0 10869   ZZcz 10937  ;cdc 11051   ^cexp 12272    || cdvds 14305    gcd cgcd 14468   Primecprime 14622
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1669  ax-4 1682  ax-5 1758  ax-6 1805  ax-7 1851  ax-8 1889  ax-9 1896  ax-10 1915  ax-11 1920  ax-12 1933  ax-13 2091  ax-ext 2431  ax-sep 4525  ax-nul 4534  ax-pow 4581  ax-pr 4639  ax-un 6583  ax-cnex 9595  ax-resscn 9596  ax-1cn 9597  ax-icn 9598  ax-addcl 9599  ax-addrcl 9600  ax-mulcl 9601  ax-mulrcl 9602  ax-mulcom 9603  ax-addass 9604  ax-mulass 9605  ax-distr 9606  ax-i2m1 9607  ax-1ne0 9608  ax-1rid 9609  ax-rnegex 9610  ax-rrecex 9611  ax-cnre 9612  ax-pre-lttri 9613  ax-pre-lttrn 9614  ax-pre-ltadd 9615  ax-pre-mulgt0 9616  ax-pre-sup 9617
This theorem depends on definitions:  df-bi 189  df-or 372  df-an 373  df-3or 986  df-3an 987  df-tru 1447  df-ex 1664  df-nf 1668  df-sb 1798  df-eu 2303  df-mo 2304  df-clab 2438  df-cleq 2444  df-clel 2447  df-nfc 2581  df-ne 2624  df-nel 2625  df-ral 2742  df-rex 2743  df-reu 2744  df-rmo 2745  df-rab 2746  df-v 3047  df-sbc 3268  df-csb 3364  df-dif 3407  df-un 3409  df-in 3411  df-ss 3418  df-pss 3420  df-nul 3732  df-if 3882  df-pw 3953  df-sn 3969  df-pr 3971  df-tp 3973  df-op 3975  df-uni 4199  df-int 4235  df-iun 4280  df-br 4403  df-opab 4462  df-mpt 4463  df-tr 4498  df-eprel 4745  df-id 4749  df-po 4755  df-so 4756  df-fr 4793  df-we 4795  df-xp 4840  df-rel 4841  df-cnv 4842  df-co 4843  df-dm 4844  df-rn 4845  df-res 4846  df-ima 4847  df-pred 5380  df-ord 5426  df-on 5427  df-lim 5428  df-suc 5429  df-iota 5546  df-fun 5584  df-fn 5585  df-f 5586  df-f1 5587  df-fo 5588  df-f1o 5589  df-fv 5590  df-riota 6252  df-ov 6293  df-oprab 6294  df-mpt2 6295  df-om 6693  df-1st 6793  df-2nd 6794  df-wrecs 7028  df-recs 7090  df-rdg 7128  df-1o 7182  df-2o 7183  df-oadd 7186  df-er 7363  df-en 7570  df-dom 7571  df-sdom 7572  df-fin 7573  df-sup 7956  df-inf 7957  df-pnf 9677  df-mnf 9678  df-xr 9679  df-ltxr 9680  df-le 9681  df-sub 9862  df-neg 9863  df-div 10270  df-nn 10610  df-2 10668  df-3 10669  df-4 10670  df-5 10671  df-6 10672  df-7 10673  df-8 10674  df-9 10675  df-10 10676  df-n0 10870  df-z 10938  df-dec 11052  df-uz 11160  df-rp 11303  df-fz 11785  df-fl 12028  df-mod 12097  df-seq 12214  df-exp 12273  df-cj 13162  df-re 13163  df-im 13164  df-sqrt 13298  df-abs 13299  df-dvds 14306  df-gcd 14469  df-prm 14623
This theorem is referenced by:  1259prm  15107
  Copyright terms: Public domain W3C validator