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

Theorem 1259lem5 15842
Description: Lemma for 1259prm 15843. 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 11185 . . . 4  |-  2  e.  NN
2 3nn0 11310 . . . . 5  |-  3  e.  NN0
3 4nn0 11311 . . . . 5  |-  4  e.  NN0
42, 3deccl 11512 . . . 4  |- ; 3 4  e.  NN0
5 nnexpcl 12873 . . . 4  |-  ( ( 2  e.  NN  /\ ; 3 4  e.  NN0 )  -> 
( 2 ^; 3 4 )  e.  NN )
61, 4, 5mp2an 708 . . 3  |-  ( 2 ^; 3 4 )  e.  NN
7 nnm1nn0 11334 . . 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 11315 . . . 4  |-  8  e.  NN0
10 6nn0 11313 . . . 4  |-  6  e.  NN0
119, 10deccl 11512 . . 3  |- ; 8 6  e.  NN0
12 9nn0 11316 . . 3  |-  9  e.  NN0
1311, 12deccl 11512 . 2  |- ;; 8 6 9  e.  NN0
14 1259prm.1 . . 3  |-  N  = ;;; 1 2 5 9
15 1nn0 11308 . . . . . 6  |-  1  e.  NN0
16 2nn0 11309 . . . . . 6  |-  2  e.  NN0
1715, 16deccl 11512 . . . . 5  |- ; 1 2  e.  NN0
18 5nn0 11312 . . . . 5  |-  5  e.  NN0
1917, 18deccl 11512 . . . 4  |- ;; 1 2 5  e.  NN0
20 9nn 11192 . . . 4  |-  9  e.  NN
2119, 20decnncl 11518 . . 3  |- ;;; 1 2 5 9  e.  NN
2214, 21eqeltri 2697 . 2  |-  N  e.  NN
23141259lem2 15839 . . 3  |-  ( ( 2 ^; 3 4 )  mod 
N )  =  (;; 8 7 0  mod 
N )
24 6p1e7 11156 . . . . 5  |-  ( 6  +  1 )  =  7
25 eqid 2622 . . . . 5  |- ; 8 6  = ; 8 6
269, 10, 24, 25decsuc 11535 . . . 4  |-  (; 8 6  +  1 )  = ; 8 7
27 eqid 2622 . . . 4  |- ;; 8 6 9  = ;; 8 6 9
2811, 26, 27decsucc 11550 . . 3  |-  (;; 8 6 9  +  1 )  = ;; 8 7 0
2922, 6, 15, 13, 23, 28modsubi 15776 . 2  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  mod  N
)  =  (;; 8 6 9  mod  N
)
302, 12deccl 11512 . . . 4  |- ; 3 9  e.  NN0
31 0nn0 11307 . . . 4  |-  0  e.  NN0
3230, 31deccl 11512 . . 3  |- ;; 3 9 0  e.  NN0
339, 12deccl 11512 . . . 4  |- ; 8 9  e.  NN0
3416, 15deccl 11512 . . . . . 6  |- ; 2 1  e.  NN0
3515, 2deccl 11512 . . . . . . 7  |- ; 1 3  e.  NN0
3634nn0zi 11402 . . . . . . . . 9  |- ; 2 1  e.  ZZ
3735nn0zi 11402 . . . . . . . . 9  |- ; 1 3  e.  ZZ
38 gcdcom 15235 . . . . . . . . 9  |-  ( (; 2
1  e.  ZZ  /\ ; 1 3  e.  ZZ )  -> 
(; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 ) )
3936, 37, 38mp2an 708 . . . . . . . 8  |-  (; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 )
40 3nn 11186 . . . . . . . . . . 11  |-  3  e.  NN
4115, 40decnncl 11518 . . . . . . . . . 10  |- ; 1 3  e.  NN
42 8nn 11191 . . . . . . . . . 10  |-  8  e.  NN
43 eqid 2622 . . . . . . . . . . 11  |- ; 1 3  = ; 1 3
449dec0h 11522 . . . . . . . . . . 11  |-  8  = ; 0 8
45 ax-1cn 9994 . . . . . . . . . . . . . 14  |-  1  e.  CC
4645mulid1i 10042 . . . . . . . . . . . . 13  |-  ( 1  x.  1 )  =  1
4745addid2i 10224 . . . . . . . . . . . . 13  |-  ( 0  +  1 )  =  1
4846, 47oveq12i 6662 . . . . . . . . . . . 12  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  ( 1  +  1 )
49 1p1e2 11134 . . . . . . . . . . . 12  |-  ( 1  +  1 )  =  2
5048, 49eqtri 2644 . . . . . . . . . . 11  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  2
51 3cn 11095 . . . . . . . . . . . . . 14  |-  3  e.  CC
5251mulid1i 10042 . . . . . . . . . . . . 13  |-  ( 3  x.  1 )  =  3
5352oveq1i 6660 . . . . . . . . . . . 12  |-  ( ( 3  x.  1 )  +  8 )  =  ( 3  +  8 )
54 8cn 11106 . . . . . . . . . . . . 13  |-  8  e.  CC
55 8p3e11 11612 . . . . . . . . . . . . 13  |-  ( 8  +  3 )  = ; 1
1
5654, 51, 55addcomli 10228 . . . . . . . . . . . 12  |-  ( 3  +  8 )  = ; 1
1
5753, 56eqtri 2644 . . . . . . . . . . 11  |-  ( ( 3  x.  1 )  +  8 )  = ; 1
1
5815, 2, 31, 9, 43, 44, 15, 15, 15, 50, 57decmac 11566 . . . . . . . . . 10  |-  ( (; 1
3  x.  1 )  +  8 )  = ; 2
1
59 1nn 11031 . . . . . . . . . . 11  |-  1  e.  NN
60 8lt10 11674 . . . . . . . . . . 11  |-  8  < ; 1
0
6159, 2, 9, 60declti 11546 . . . . . . . . . 10  |-  8  < ; 1
3
6241, 15, 42, 58, 61ndvdsi 15136 . . . . . . . . 9  |-  -. ; 1 3  || ; 2 1
63 13prm 15823 . . . . . . . . . 10  |- ; 1 3  e.  Prime
64 coprm 15423 . . . . . . . . . 10  |-  ( (; 1
3  e.  Prime  /\ ; 2 1  e.  ZZ )  ->  ( -. ; 1 3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 ) )
6563, 36, 64mp2an 708 . . . . . . . . 9  |-  ( -. ; 1
3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 )
6662, 65mpbi 220 . . . . . . . 8  |-  (; 1 3  gcd ; 2 1 )  =  1
6739, 66eqtri 2644 . . . . . . 7  |-  (; 2 1  gcd ; 1 3 )  =  1
68 eqid 2622 . . . . . . . 8  |- ; 2 1  = ; 2 1
69 2cn 11091 . . . . . . . . . . 11  |-  2  e.  CC
7069mulid2i 10043 . . . . . . . . . 10  |-  ( 1  x.  2 )  =  2
7145addid1i 10223 . . . . . . . . . 10  |-  ( 1  +  0 )  =  1
7270, 71oveq12i 6662 . . . . . . . . 9  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  ( 2  +  1 )
73 2p1e3 11151 . . . . . . . . 9  |-  ( 2  +  1 )  =  3
7472, 73eqtri 2644 . . . . . . . 8  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  3
7546oveq1i 6660 . . . . . . . . 9  |-  ( ( 1  x.  1 )  +  3 )  =  ( 1  +  3 )
76 3p1e4 11153 . . . . . . . . . 10  |-  ( 3  +  1 )  =  4
7751, 45, 76addcomli 10228 . . . . . . . . 9  |-  ( 1  +  3 )  =  4
783dec0h 11522 . . . . . . . . 9  |-  4  = ; 0 4
7975, 77, 783eqtri 2648 . . . . . . . 8  |-  ( ( 1  x.  1 )  +  3 )  = ; 0
4
8016, 15, 15, 2, 68, 43, 15, 3, 31, 74, 79decma2c 11568 . . . . . . 7  |-  ( ( 1  x. ; 2 1 )  + ; 1
3 )  = ; 3 4
8115, 35, 34, 67, 80gcdi 15777 . . . . . 6  |-  (; 3 4  gcd ; 2 1 )  =  1
82 eqid 2622 . . . . . . 7  |- ; 3 4  = ; 3 4
83 3t2e6 11179 . . . . . . . . . 10  |-  ( 3  x.  2 )  =  6
8451, 69, 83mulcomli 10047 . . . . . . . . 9  |-  ( 2  x.  3 )  =  6
8569addid1i 10223 . . . . . . . . 9  |-  ( 2  +  0 )  =  2
8684, 85oveq12i 6662 . . . . . . . 8  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  ( 6  +  2 )
87 6p2e8 11169 . . . . . . . 8  |-  ( 6  +  2 )  =  8
8886, 87eqtri 2644 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  8
89 4cn 11098 . . . . . . . . . 10  |-  4  e.  CC
90 4t2e8 11181 . . . . . . . . . 10  |-  ( 4  x.  2 )  =  8
9189, 69, 90mulcomli 10047 . . . . . . . . 9  |-  ( 2  x.  4 )  =  8
9291oveq1i 6660 . . . . . . . 8  |-  ( ( 2  x.  4 )  +  1 )  =  ( 8  +  1 )
93 8p1e9 11158 . . . . . . . 8  |-  ( 8  +  1 )  =  9
9412dec0h 11522 . . . . . . . 8  |-  9  = ; 0 9
9592, 93, 943eqtri 2648 . . . . . . 7  |-  ( ( 2  x.  4 )  +  1 )  = ; 0
9
962, 3, 16, 15, 82, 68, 16, 12, 31, 88, 95decma2c 11568 . . . . . 6  |-  ( ( 2  x. ; 3 4 )  + ; 2
1 )  = ; 8 9
9716, 34, 4, 81, 96gcdi 15777 . . . . 5  |-  (; 8 9  gcd ; 3 4 )  =  1
98 eqid 2622 . . . . . 6  |- ; 8 9  = ; 8 9
99 4p3e7 11163 . . . . . . . . 9  |-  ( 4  +  3 )  =  7
10089, 51, 99addcomli 10228 . . . . . . . 8  |-  ( 3  +  4 )  =  7
101100oveq2i 6661 . . . . . . 7  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  =  ( ( 4  x.  8 )  +  7 )
102 7nn0 11314 . . . . . . . 8  |-  7  e.  NN0
103 8t4e32 11656 . . . . . . . . 9  |-  ( 8  x.  4 )  = ; 3
2
10454, 89, 103mulcomli 10047 . . . . . . . 8  |-  ( 4  x.  8 )  = ; 3
2
105 7cn 11104 . . . . . . . . 9  |-  7  e.  CC
106 7p2e9 11172 . . . . . . . . 9  |-  ( 7  +  2 )  =  9
107105, 69, 106addcomli 10228 . . . . . . . 8  |-  ( 2  +  7 )  =  9
1082, 16, 102, 104, 107decaddi 11579 . . . . . . 7  |-  ( ( 4  x.  8 )  +  7 )  = ; 3
9
109101, 108eqtri 2644 . . . . . 6  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  = ; 3
9
110 9cn 11108 . . . . . . . 8  |-  9  e.  CC
111 9t4e36 11665 . . . . . . . 8  |-  ( 9  x.  4 )  = ; 3
6
112110, 89, 111mulcomli 10047 . . . . . . 7  |-  ( 4  x.  9 )  = ; 3
6
113 6p4e10 11598 . . . . . . 7  |-  ( 6  +  4 )  = ; 1
0
1142, 10, 3, 112, 76, 113decaddci2 11581 . . . . . 6  |-  ( ( 4  x.  9 )  +  4 )  = ; 4
0
1159, 12, 2, 3, 98, 82, 3, 31, 3, 109, 114decma2c 11568 . . . . 5  |-  ( ( 4  x. ; 8 9 )  + ; 3
4 )  = ;; 3 9 0
1163, 4, 33, 97, 115gcdi 15777 . . . 4  |-  (;; 3 9 0  gcd ; 8 9 )  =  1
117 eqid 2622 . . . . 5  |- ;; 3 9 0  = ;; 3 9 0
118 eqid 2622 . . . . . 6  |- ; 3 9  = ; 3 9
11954addid1i 10223 . . . . . . 7  |-  ( 8  +  0 )  =  8
120119, 44eqtri 2644 . . . . . 6  |-  ( 8  +  0 )  = ; 0
8
12169addid2i 10224 . . . . . . . 8  |-  ( 0  +  2 )  =  2
12284, 121oveq12i 6662 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  ( 6  +  2 )
123122, 87eqtri 2644 . . . . . 6  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  8
124 9t2e18 11663 . . . . . . . 8  |-  ( 9  x.  2 )  = ; 1
8
125110, 69, 124mulcomli 10047 . . . . . . 7  |-  ( 2  x.  9 )  = ; 1
8
126 8p8e16 11618 . . . . . . 7  |-  ( 8  +  8 )  = ; 1
6
12715, 9, 9, 125, 49, 10, 126decaddci 11580 . . . . . 6  |-  ( ( 2  x.  9 )  +  8 )  = ; 2
6
1282, 12, 31, 9, 118, 120, 16, 10, 16, 123, 127decma2c 11568 . . . . 5  |-  ( ( 2  x. ; 3 9 )  +  ( 8  +  0 ) )  = ; 8 6
129 2t0e0 11183 . . . . . . 7  |-  ( 2  x.  0 )  =  0
130129oveq1i 6660 . . . . . 6  |-  ( ( 2  x.  0 )  +  9 )  =  ( 0  +  9 )
131110addid2i 10224 . . . . . 6  |-  ( 0  +  9 )  =  9
132130, 131, 943eqtri 2648 . . . . 5  |-  ( ( 2  x.  0 )  +  9 )  = ; 0
9
13330, 31, 9, 12, 117, 98, 16, 12, 31, 128, 132decma2c 11568 . . . 4  |-  ( ( 2  x. ;; 3 9 0 )  + ; 8
9 )  = ;; 8 6 9
13416, 33, 32, 116, 133gcdi 15777 . . 3  |-  (;; 8 6 9  gcd ;; 3 9 0 )  =  1
13530nn0cni 11304 . . . . . . 7  |- ; 3 9  e.  CC
136135addid1i 10223 . . . . . 6  |-  (; 3 9  +  0 )  = ; 3 9
13754mulid2i 10043 . . . . . . . 8  |-  ( 1  x.  8 )  =  8
138137, 76oveq12i 6662 . . . . . . 7  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  =  ( 8  +  4 )
139 8p4e12 11614 . . . . . . 7  |-  ( 8  +  4 )  = ; 1
2
140138, 139eqtri 2644 . . . . . 6  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  = ; 1
2
141 6cn 11102 . . . . . . . . 9  |-  6  e.  CC
142141mulid2i 10043 . . . . . . . 8  |-  ( 1  x.  6 )  =  6
143142oveq1i 6660 . . . . . . 7  |-  ( ( 1  x.  6 )  +  9 )  =  ( 6  +  9 )
144 9p6e15 11624 . . . . . . . 8  |-  ( 9  +  6 )  = ; 1
5
145110, 141, 144addcomli 10228 . . . . . . 7  |-  ( 6  +  9 )  = ; 1
5
146143, 145eqtri 2644 . . . . . 6  |-  ( ( 1  x.  6 )  +  9 )  = ; 1
5
1479, 10, 2, 12, 25, 136, 15, 18, 15, 140, 146decma2c 11568 . . . . 5  |-  ( ( 1  x. ; 8 6 )  +  (; 3 9  +  0 ) )  = ;; 1 2 5
148110mulid2i 10043 . . . . . . 7  |-  ( 1  x.  9 )  =  9
149148oveq1i 6660 . . . . . 6  |-  ( ( 1  x.  9 )  +  0 )  =  ( 9  +  0 )
150110addid1i 10223 . . . . . 6  |-  ( 9  +  0 )  =  9
151149, 150, 943eqtri 2648 . . . . 5  |-  ( ( 1  x.  9 )  +  0 )  = ; 0
9
15211, 12, 30, 31, 27, 117, 15, 12, 31, 147, 151decma2c 11568 . . . 4  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  = ;;; 1 2 5 9
153152, 14eqtr4i 2647 . . 3  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  =  N
15415, 32, 13, 134, 153gcdi 15777 . 2  |-  ( N  gcd ;; 8 6 9 )  =  1
1558, 13, 22, 29, 154gcdmodi 15778 1  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  gcd  N
)  =  1
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    <-> wb 196    = wceq 1483    e. wcel 1990   class class class wbr 4653  (class class class)co 6650   0cc0 9936   1c1 9937    + caddc 9939    x. cmul 9941    - cmin 10266   NNcn 11020   2c2 11070   3c3 11071   4c4 11072   5c5 11073   6c6 11074   7c7 11075   8c8 11076   9c9 11077   NN0cn0 11292   ZZcz 11377  ;cdc 11493   ^cexp 12860    || cdvds 14983    gcd cgcd 15216   Primecprime 15385
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1722  ax-4 1737  ax-5 1839  ax-6 1888  ax-7 1935  ax-8 1992  ax-9 1999  ax-10 2019  ax-11 2034  ax-12 2047  ax-13 2246  ax-ext 2602  ax-sep 4781  ax-nul 4789  ax-pow 4843  ax-pr 4906  ax-un 6949  ax-cnex 9992  ax-resscn 9993  ax-1cn 9994  ax-icn 9995  ax-addcl 9996  ax-addrcl 9997  ax-mulcl 9998  ax-mulrcl 9999  ax-mulcom 10000  ax-addass 10001  ax-mulass 10002  ax-distr 10003  ax-i2m1 10004  ax-1ne0 10005  ax-1rid 10006  ax-rnegex 10007  ax-rrecex 10008  ax-cnre 10009  ax-pre-lttri 10010  ax-pre-lttrn 10011  ax-pre-ltadd 10012  ax-pre-mulgt0 10013  ax-pre-sup 10014
This theorem depends on definitions:  df-bi 197  df-or 385  df-an 386  df-3or 1038  df-3an 1039  df-tru 1486  df-ex 1705  df-nf 1710  df-sb 1881  df-eu 2474  df-mo 2475  df-clab 2609  df-cleq 2615  df-clel 2618  df-nfc 2753  df-ne 2795  df-nel 2898  df-ral 2917  df-rex 2918  df-reu 2919  df-rmo 2920  df-rab 2921  df-v 3202  df-sbc 3436  df-csb 3534  df-dif 3577  df-un 3579  df-in 3581  df-ss 3588  df-pss 3590  df-nul 3916  df-if 4087  df-pw 4160  df-sn 4178  df-pr 4180  df-tp 4182  df-op 4184  df-uni 4437  df-iun 4522  df-br 4654  df-opab 4713  df-mpt 4730  df-tr 4753  df-id 5024  df-eprel 5029  df-po 5035  df-so 5036  df-fr 5073  df-we 5075  df-xp 5120  df-rel 5121  df-cnv 5122  df-co 5123  df-dm 5124  df-rn 5125  df-res 5126  df-ima 5127  df-pred 5680  df-ord 5726  df-on 5727  df-lim 5728  df-suc 5729  df-iota 5851  df-fun 5890  df-fn 5891  df-f 5892  df-f1 5893  df-fo 5894  df-f1o 5895  df-fv 5896  df-riota 6611  df-ov 6653  df-oprab 6654  df-mpt2 6655  df-om 7066  df-1st 7168  df-2nd 7169  df-wrecs 7407  df-recs 7468  df-rdg 7506  df-1o 7560  df-2o 7561  df-er 7742  df-en 7956  df-dom 7957  df-sdom 7958  df-fin 7959  df-sup 8348  df-inf 8349  df-pnf 10076  df-mnf 10077  df-xr 10078  df-ltxr 10079  df-le 10080  df-sub 10268  df-neg 10269  df-div 10685  df-nn 11021  df-2 11079  df-3 11080  df-4 11081  df-5 11082  df-6 11083  df-7 11084  df-8 11085  df-9 11086  df-n0 11293  df-z 11378  df-dec 11494  df-uz 11688  df-rp 11833  df-fz 12327  df-fl 12593  df-mod 12669  df-seq 12802  df-exp 12861  df-cj 13839  df-re 13840  df-im 13841  df-sqrt 13975  df-abs 13976  df-dvds 14984  df-gcd 15217  df-prm 15386
This theorem is referenced by:  1259prm  15843
  Copyright terms: Public domain W3C validator