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

Theorem 1259lem5 14491
Description: Lemma for 1259prm 14492. 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 10696 . . . 4  |-  2  e.  NN
2 3nn0 10816 . . . . 5  |-  3  e.  NN0
3 4nn0 10817 . . . . 5  |-  4  e.  NN0
42, 3deccl 10995 . . . 4  |- ; 3 4  e.  NN0
5 nnexpcl 12155 . . . 4  |-  ( ( 2  e.  NN  /\ ; 3 4  e.  NN0 )  -> 
( 2 ^; 3 4 )  e.  NN )
61, 4, 5mp2an 672 . . 3  |-  ( 2 ^; 3 4 )  e.  NN
7 nnm1nn0 10840 . . 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 10821 . . . 4  |-  8  e.  NN0
10 6nn0 10819 . . . 4  |-  6  e.  NN0
119, 10deccl 10995 . . 3  |- ; 8 6  e.  NN0
12 9nn0 10822 . . 3  |-  9  e.  NN0
1311, 12deccl 10995 . 2  |- ;; 8 6 9  e.  NN0
14 1259prm.1 . . 3  |-  N  = ;;; 1 2 5 9
15 1nn0 10814 . . . . . 6  |-  1  e.  NN0
16 2nn0 10815 . . . . . 6  |-  2  e.  NN0
1715, 16deccl 10995 . . . . 5  |- ; 1 2  e.  NN0
18 5nn0 10818 . . . . 5  |-  5  e.  NN0
1917, 18deccl 10995 . . . 4  |- ;; 1 2 5  e.  NN0
20 9nn 10703 . . . 4  |-  9  e.  NN
2119, 20decnncl 10994 . . 3  |- ;;; 1 2 5 9  e.  NN
2214, 21eqeltri 2525 . 2  |-  N  e.  NN
23141259lem2 14488 . . 3  |-  ( ( 2 ^; 3 4 )  mod 
N )  =  (;; 8 7 0  mod 
N )
24 6p1e7 10667 . . . . 5  |-  ( 6  +  1 )  =  7
25 eqid 2441 . . . . 5  |- ; 8 6  = ; 8 6
269, 10, 24, 25decsuc 11004 . . . 4  |-  (; 8 6  +  1 )  = ; 8 7
27 eqid 2441 . . . 4  |- ;; 8 6 9  = ;; 8 6 9
2811, 26, 27decsucc 11008 . . 3  |-  (;; 8 6 9  +  1 )  = ;; 8 7 0
2922, 6, 15, 13, 23, 28modsubi 14432 . 2  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  mod  N
)  =  (;; 8 6 9  mod  N
)
302, 12deccl 10995 . . . 4  |- ; 3 9  e.  NN0
31 0nn0 10813 . . . 4  |-  0  e.  NN0
3230, 31deccl 10995 . . 3  |- ;; 3 9 0  e.  NN0
339, 12deccl 10995 . . . 4  |- ; 8 9  e.  NN0
3416, 15deccl 10995 . . . . . 6  |- ; 2 1  e.  NN0
3515, 2deccl 10995 . . . . . . 7  |- ; 1 3  e.  NN0
3634nn0zi 10892 . . . . . . . . 9  |- ; 2 1  e.  ZZ
3735nn0zi 10892 . . . . . . . . 9  |- ; 1 3  e.  ZZ
38 gcdcom 14032 . . . . . . . . 9  |-  ( (; 2
1  e.  ZZ  /\ ; 1 3  e.  ZZ )  -> 
(; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 ) )
3936, 37, 38mp2an 672 . . . . . . . 8  |-  (; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 )
40 3nn 10697 . . . . . . . . . . 11  |-  3  e.  NN
4115, 40decnncl 10994 . . . . . . . . . 10  |- ; 1 3  e.  NN
42 8nn 10702 . . . . . . . . . 10  |-  8  e.  NN
43 eqid 2441 . . . . . . . . . . 11  |- ; 1 3  = ; 1 3
449dec0h 10997 . . . . . . . . . . 11  |-  8  = ; 0 8
45 ax-1cn 9550 . . . . . . . . . . . . . 14  |-  1  e.  CC
4645mulid1i 9598 . . . . . . . . . . . . 13  |-  ( 1  x.  1 )  =  1
4745addid2i 9768 . . . . . . . . . . . . 13  |-  ( 0  +  1 )  =  1
4846, 47oveq12i 6290 . . . . . . . . . . . 12  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  ( 1  +  1 )
49 1p1e2 10652 . . . . . . . . . . . 12  |-  ( 1  +  1 )  =  2
5048, 49eqtri 2470 . . . . . . . . . . 11  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  2
51 3cn 10613 . . . . . . . . . . . . . 14  |-  3  e.  CC
5251mulid1i 9598 . . . . . . . . . . . . 13  |-  ( 3  x.  1 )  =  3
5352oveq1i 6288 . . . . . . . . . . . 12  |-  ( ( 3  x.  1 )  +  8 )  =  ( 3  +  8 )
54 8cn 10624 . . . . . . . . . . . . 13  |-  8  e.  CC
55 8p3e11 11037 . . . . . . . . . . . . 13  |-  ( 8  +  3 )  = ; 1
1
5654, 51, 55addcomli 9772 . . . . . . . . . . . 12  |-  ( 3  +  8 )  = ; 1
1
5753, 56eqtri 2470 . . . . . . . . . . 11  |-  ( ( 3  x.  1 )  +  8 )  = ; 1
1
5815, 2, 31, 9, 43, 44, 15, 15, 15, 50, 57decmac 11020 . . . . . . . . . 10  |-  ( (; 1
3  x.  1 )  +  8 )  = ; 2
1
59 1nn 10550 . . . . . . . . . . 11  |-  1  e.  NN
60 8lt10 10742 . . . . . . . . . . 11  |-  8  <  10
6159, 2, 9, 60declti 11006 . . . . . . . . . 10  |-  8  < ; 1
3
6241, 15, 42, 58, 61ndvdsi 13942 . . . . . . . . 9  |-  -. ; 1 3  || ; 2 1
63 13prm 14475 . . . . . . . . . 10  |- ; 1 3  e.  Prime
64 coprm 14115 . . . . . . . . . 10  |-  ( (; 1
3  e.  Prime  /\ ; 2 1  e.  ZZ )  ->  ( -. ; 1 3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 ) )
6563, 36, 64mp2an 672 . . . . . . . . 9  |-  ( -. ; 1
3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 )
6662, 65mpbi 208 . . . . . . . 8  |-  (; 1 3  gcd ; 2 1 )  =  1
6739, 66eqtri 2470 . . . . . . 7  |-  (; 2 1  gcd ; 1 3 )  =  1
68 eqid 2441 . . . . . . . 8  |- ; 2 1  = ; 2 1
69 2cn 10609 . . . . . . . . . . 11  |-  2  e.  CC
7069mulid2i 9599 . . . . . . . . . 10  |-  ( 1  x.  2 )  =  2
7145addid1i 9767 . . . . . . . . . 10  |-  ( 1  +  0 )  =  1
7270, 71oveq12i 6290 . . . . . . . . 9  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  ( 2  +  1 )
73 2p1e3 10662 . . . . . . . . 9  |-  ( 2  +  1 )  =  3
7472, 73eqtri 2470 . . . . . . . 8  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  3
7546oveq1i 6288 . . . . . . . . 9  |-  ( ( 1  x.  1 )  +  3 )  =  ( 1  +  3 )
76 3p1e4 10664 . . . . . . . . . 10  |-  ( 3  +  1 )  =  4
7751, 45, 76addcomli 9772 . . . . . . . . 9  |-  ( 1  +  3 )  =  4
783dec0h 10997 . . . . . . . . 9  |-  4  = ; 0 4
7975, 77, 783eqtri 2474 . . . . . . . 8  |-  ( ( 1  x.  1 )  +  3 )  = ; 0
4
8016, 15, 15, 2, 68, 43, 15, 3, 31, 74, 79decma2c 11021 . . . . . . 7  |-  ( ( 1  x. ; 2 1 )  + ; 1
3 )  = ; 3 4
8115, 35, 34, 67, 80gcdi 14433 . . . . . 6  |-  (; 3 4  gcd ; 2 1 )  =  1
82 eqid 2441 . . . . . . 7  |- ; 3 4  = ; 3 4
83 3t2e6 10690 . . . . . . . . . 10  |-  ( 3  x.  2 )  =  6
8451, 69, 83mulcomli 9603 . . . . . . . . 9  |-  ( 2  x.  3 )  =  6
8569addid1i 9767 . . . . . . . . 9  |-  ( 2  +  0 )  =  2
8684, 85oveq12i 6290 . . . . . . . 8  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  ( 6  +  2 )
87 6p2e8 10680 . . . . . . . 8  |-  ( 6  +  2 )  =  8
8886, 87eqtri 2470 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  8
89 4cn 10616 . . . . . . . . . 10  |-  4  e.  CC
90 4t2e8 10692 . . . . . . . . . 10  |-  ( 4  x.  2 )  =  8
9189, 69, 90mulcomli 9603 . . . . . . . . 9  |-  ( 2  x.  4 )  =  8
9291oveq1i 6288 . . . . . . . 8  |-  ( ( 2  x.  4 )  +  1 )  =  ( 8  +  1 )
93 8p1e9 10669 . . . . . . . 8  |-  ( 8  +  1 )  =  9
9412dec0h 10997 . . . . . . . 8  |-  9  = ; 0 9
9592, 93, 943eqtri 2474 . . . . . . 7  |-  ( ( 2  x.  4 )  +  1 )  = ; 0
9
962, 3, 16, 15, 82, 68, 16, 12, 31, 88, 95decma2c 11021 . . . . . 6  |-  ( ( 2  x. ; 3 4 )  + ; 2
1 )  = ; 8 9
9716, 34, 4, 81, 96gcdi 14433 . . . . 5  |-  (; 8 9  gcd ; 3 4 )  =  1
98 eqid 2441 . . . . . 6  |- ; 8 9  = ; 8 9
99 4p3e7 10674 . . . . . . . . 9  |-  ( 4  +  3 )  =  7
10089, 51, 99addcomli 9772 . . . . . . . 8  |-  ( 3  +  4 )  =  7
101100oveq2i 6289 . . . . . . 7  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  =  ( ( 4  x.  8 )  +  7 )
102 7nn0 10820 . . . . . . . 8  |-  7  e.  NN0
103 8t4e32 11071 . . . . . . . . 9  |-  ( 8  x.  4 )  = ; 3
2
10454, 89, 103mulcomli 9603 . . . . . . . 8  |-  ( 4  x.  8 )  = ; 3
2
105 7cn 10622 . . . . . . . . 9  |-  7  e.  CC
106 7p2e9 10683 . . . . . . . . 9  |-  ( 7  +  2 )  =  9
107105, 69, 106addcomli 9772 . . . . . . . 8  |-  ( 2  +  7 )  =  9
1082, 16, 102, 104, 107decaddi 11025 . . . . . . 7  |-  ( ( 4  x.  8 )  +  7 )  = ; 3
9
109101, 108eqtri 2470 . . . . . 6  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  = ; 3
9
110 9cn 10626 . . . . . . . 8  |-  9  e.  CC
111 9t4e36 11078 . . . . . . . 8  |-  ( 9  x.  4 )  = ; 3
6
112110, 89, 111mulcomli 9603 . . . . . . 7  |-  ( 4  x.  9 )  = ; 3
6
113 6p4e10 10682 . . . . . . 7  |-  ( 6  +  4 )  =  10
1142, 10, 3, 112, 76, 113decaddci2 11027 . . . . . 6  |-  ( ( 4  x.  9 )  +  4 )  = ; 4
0
1159, 12, 2, 3, 98, 82, 3, 31, 3, 109, 114decma2c 11021 . . . . 5  |-  ( ( 4  x. ; 8 9 )  + ; 3
4 )  = ;; 3 9 0
1163, 4, 33, 97, 115gcdi 14433 . . . 4  |-  (;; 3 9 0  gcd ; 8 9 )  =  1
117 eqid 2441 . . . . 5  |- ;; 3 9 0  = ;; 3 9 0
118 eqid 2441 . . . . . 6  |- ; 3 9  = ; 3 9
11954addid1i 9767 . . . . . . 7  |-  ( 8  +  0 )  =  8
120119, 44eqtri 2470 . . . . . 6  |-  ( 8  +  0 )  = ; 0
8
12169addid2i 9768 . . . . . . . 8  |-  ( 0  +  2 )  =  2
12284, 121oveq12i 6290 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  ( 6  +  2 )
123122, 87eqtri 2470 . . . . . 6  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  8
124 9t2e18 11076 . . . . . . . 8  |-  ( 9  x.  2 )  = ; 1
8
125110, 69, 124mulcomli 9603 . . . . . . 7  |-  ( 2  x.  9 )  = ; 1
8
126 8p8e16 11042 . . . . . . 7  |-  ( 8  +  8 )  = ; 1
6
12715, 9, 9, 125, 49, 10, 126decaddci 11026 . . . . . 6  |-  ( ( 2  x.  9 )  +  8 )  = ; 2
6
1282, 12, 31, 9, 118, 120, 16, 10, 16, 123, 127decma2c 11021 . . . . 5  |-  ( ( 2  x. ; 3 9 )  +  ( 8  +  0 ) )  = ; 8 6
129 2t0e0 10694 . . . . . . 7  |-  ( 2  x.  0 )  =  0
130129oveq1i 6288 . . . . . 6  |-  ( ( 2  x.  0 )  +  9 )  =  ( 0  +  9 )
131110addid2i 9768 . . . . . 6  |-  ( 0  +  9 )  =  9
132130, 131, 943eqtri 2474 . . . . 5  |-  ( ( 2  x.  0 )  +  9 )  = ; 0
9
13330, 31, 9, 12, 117, 98, 16, 12, 31, 128, 132decma2c 11021 . . . 4  |-  ( ( 2  x. ;; 3 9 0 )  + ; 8
9 )  = ;; 8 6 9
13416, 33, 32, 116, 133gcdi 14433 . . 3  |-  (;; 8 6 9  gcd ;; 3 9 0 )  =  1
13530nn0cni 10810 . . . . . . 7  |- ; 3 9  e.  CC
136135addid1i 9767 . . . . . 6  |-  (; 3 9  +  0 )  = ; 3 9
13754mulid2i 9599 . . . . . . . 8  |-  ( 1  x.  8 )  =  8
138137, 76oveq12i 6290 . . . . . . 7  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  =  ( 8  +  4 )
139 8p4e12 11038 . . . . . . 7  |-  ( 8  +  4 )  = ; 1
2
140138, 139eqtri 2470 . . . . . 6  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  = ; 1
2
141 6cn 10620 . . . . . . . . 9  |-  6  e.  CC
142141mulid2i 9599 . . . . . . . 8  |-  ( 1  x.  6 )  =  6
143142oveq1i 6288 . . . . . . 7  |-  ( ( 1  x.  6 )  +  9 )  =  ( 6  +  9 )
144 9p6e15 11047 . . . . . . . 8  |-  ( 9  +  6 )  = ; 1
5
145110, 141, 144addcomli 9772 . . . . . . 7  |-  ( 6  +  9 )  = ; 1
5
146143, 145eqtri 2470 . . . . . 6  |-  ( ( 1  x.  6 )  +  9 )  = ; 1
5
1479, 10, 2, 12, 25, 136, 15, 18, 15, 140, 146decma2c 11021 . . . . 5  |-  ( ( 1  x. ; 8 6 )  +  (; 3 9  +  0 ) )  = ;; 1 2 5
148110mulid2i 9599 . . . . . . 7  |-  ( 1  x.  9 )  =  9
149148oveq1i 6288 . . . . . 6  |-  ( ( 1  x.  9 )  +  0 )  =  ( 9  +  0 )
150110addid1i 9767 . . . . . 6  |-  ( 9  +  0 )  =  9
151149, 150, 943eqtri 2474 . . . . 5  |-  ( ( 1  x.  9 )  +  0 )  = ; 0
9
15211, 12, 30, 31, 27, 117, 15, 12, 31, 147, 151decma2c 11021 . . . 4  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  = ;;; 1 2 5 9
153152, 14eqtr4i 2473 . . 3  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  =  N
15415, 32, 13, 134, 153gcdi 14433 . 2  |-  ( N  gcd ;; 8 6 9 )  =  1
1558, 13, 22, 29, 154gcdmodi 14434 1  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  gcd  N
)  =  1
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    <-> wb 184    = wceq 1381    e. wcel 1802   class class class wbr 4434  (class class class)co 6278   0cc0 9492   1c1 9493    + caddc 9495    x. cmul 9497    - cmin 9807   NNcn 10539   2c2 10588   3c3 10589   4c4 10590   5c5 10591   6c6 10592   7c7 10593   8c8 10594   9c9 10595   NN0cn0 10798   ZZcz 10867  ;cdc 10981   ^cexp 12142    || cdvds 13860    gcd cgcd 14018   Primecprime 14091
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1603  ax-4 1616  ax-5 1689  ax-6 1732  ax-7 1774  ax-8 1804  ax-9 1806  ax-10 1821  ax-11 1826  ax-12 1838  ax-13 1983  ax-ext 2419  ax-sep 4555  ax-nul 4563  ax-pow 4612  ax-pr 4673  ax-un 6574  ax-cnex 9548  ax-resscn 9549  ax-1cn 9550  ax-icn 9551  ax-addcl 9552  ax-addrcl 9553  ax-mulcl 9554  ax-mulrcl 9555  ax-mulcom 9556  ax-addass 9557  ax-mulass 9558  ax-distr 9559  ax-i2m1 9560  ax-1ne0 9561  ax-1rid 9562  ax-rnegex 9563  ax-rrecex 9564  ax-cnre 9565  ax-pre-lttri 9566  ax-pre-lttrn 9567  ax-pre-ltadd 9568  ax-pre-mulgt0 9569  ax-pre-sup 9570
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 973  df-3an 974  df-tru 1384  df-ex 1598  df-nf 1602  df-sb 1725  df-eu 2270  df-mo 2271  df-clab 2427  df-cleq 2433  df-clel 2436  df-nfc 2591  df-ne 2638  df-nel 2639  df-ral 2796  df-rex 2797  df-reu 2798  df-rmo 2799  df-rab 2800  df-v 3095  df-sbc 3312  df-csb 3419  df-dif 3462  df-un 3464  df-in 3466  df-ss 3473  df-pss 3475  df-nul 3769  df-if 3924  df-pw 3996  df-sn 4012  df-pr 4014  df-tp 4016  df-op 4018  df-uni 4232  df-int 4269  df-iun 4314  df-br 4435  df-opab 4493  df-mpt 4494  df-tr 4528  df-eprel 4778  df-id 4782  df-po 4787  df-so 4788  df-fr 4825  df-we 4827  df-ord 4868  df-on 4869  df-lim 4870  df-suc 4871  df-xp 4992  df-rel 4993  df-cnv 4994  df-co 4995  df-dm 4996  df-rn 4997  df-res 4998  df-ima 4999  df-iota 5538  df-fun 5577  df-fn 5578  df-f 5579  df-f1 5580  df-fo 5581  df-f1o 5582  df-fv 5583  df-riota 6239  df-ov 6281  df-oprab 6282  df-mpt2 6283  df-om 6683  df-1st 6782  df-2nd 6783  df-recs 7041  df-rdg 7075  df-1o 7129  df-2o 7130  df-oadd 7133  df-er 7310  df-en 7516  df-dom 7517  df-sdom 7518  df-fin 7519  df-sup 7900  df-pnf 9630  df-mnf 9631  df-xr 9632  df-ltxr 9633  df-le 9634  df-sub 9809  df-neg 9810  df-div 10210  df-nn 10540  df-2 10597  df-3 10598  df-4 10599  df-5 10600  df-6 10601  df-7 10602  df-8 10603  df-9 10604  df-10 10605  df-n0 10799  df-z 10868  df-dec 10982  df-uz 11088  df-rp 11227  df-fz 11679  df-fl 11905  df-mod 11973  df-seq 12084  df-exp 12143  df-cj 12908  df-re 12909  df-im 12910  df-sqrt 13044  df-abs 13045  df-dvds 13861  df-gcd 14019  df-prm 14092
This theorem is referenced by:  1259prm  14492
  Copyright terms: Public domain W3C validator