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

Theorem 1259lem5 13149
Description: Lemma for 1259prm 13150. 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 9893 . . . 4  |-  2  e.  NN
2 3nn0 9999 . . . . 5  |-  3  e.  NN0
3 4nn0 10000 . . . . 5  |-  4  e.  NN0
42, 3deccl 10154 . . . 4  |- ; 3 4  e.  NN0
5 nnexpcl 11132 . . . 4  |-  ( ( 2  e.  NN  /\ ; 3 4  e.  NN0 )  -> 
( 2 ^; 3 4 )  e.  NN )
61, 4, 5mp2an 653 . . 3  |-  ( 2 ^; 3 4 )  e.  NN
7 nnm1nn0 10021 . . 3  |-  ( ( 2 ^; 3 4 )  e.  NN  ->  ( (
2 ^; 3 4 )  - 
1 )  e.  NN0 )
86, 7ax-mp 8 . 2  |-  ( ( 2 ^; 3 4 )  - 
1 )  e.  NN0
9 8nn0 10004 . . . 4  |-  8  e.  NN0
10 6nn0 10002 . . . 4  |-  6  e.  NN0
119, 10deccl 10154 . . 3  |- ; 8 6  e.  NN0
12 9nn0 10005 . . 3  |-  9  e.  NN0
1311, 12deccl 10154 . 2  |- ;; 8 6 9  e.  NN0
14 1259prm.1 . . 3  |-  N  = ;;; 1 2 5 9
15 1nn0 9997 . . . . . 6  |-  1  e.  NN0
16 2nn0 9998 . . . . . 6  |-  2  e.  NN0
1715, 16deccl 10154 . . . . 5  |- ; 1 2  e.  NN0
18 5nn0 10001 . . . . 5  |-  5  e.  NN0
1917, 18deccl 10154 . . . 4  |- ;; 1 2 5  e.  NN0
20 9nn 9900 . . . 4  |-  9  e.  NN
2119, 20decnncl 10153 . . 3  |- ;;; 1 2 5 9  e.  NN
2214, 21eqeltri 2366 . 2  |-  N  e.  NN
23141259lem2 13146 . . 3  |-  ( ( 2 ^; 3 4 )  mod 
N )  =  (;; 8 7 0  mod 
N )
24 6p1e7 9867 . . . . 5  |-  ( 6  +  1 )  =  7
25 eqid 2296 . . . . 5  |- ; 8 6  = ; 8 6
269, 10, 24, 25decsuc 10163 . . . 4  |-  (; 8 6  +  1 )  = ; 8 7
27 eqid 2296 . . . 4  |- ;; 8 6 9  = ;; 8 6 9
2811, 26, 27decsucc 10167 . . 3  |-  (;; 8 6 9  +  1 )  = ;; 8 7 0
2922, 6, 15, 13, 23, 28modsubi 13103 . 2  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  mod  N
)  =  (;; 8 6 9  mod  N
)
302, 12deccl 10154 . . . 4  |- ; 3 9  e.  NN0
31 0nn0 9996 . . . 4  |-  0  e.  NN0
3230, 31deccl 10154 . . 3  |- ;; 3 9 0  e.  NN0
339, 12deccl 10154 . . . 4  |- ; 8 9  e.  NN0
3416, 15deccl 10154 . . . . . 6  |- ; 2 1  e.  NN0
3515, 2deccl 10154 . . . . . . 7  |- ; 1 3  e.  NN0
3634nn0zi 10064 . . . . . . . . 9  |- ; 2 1  e.  ZZ
3735nn0zi 10064 . . . . . . . . 9  |- ; 1 3  e.  ZZ
38 gcdcom 12715 . . . . . . . . 9  |-  ( (; 2
1  e.  ZZ  /\ ; 1 3  e.  ZZ )  -> 
(; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 ) )
3936, 37, 38mp2an 653 . . . . . . . 8  |-  (; 2 1  gcd ; 1 3 )  =  (; 1 3  gcd ; 2 1 )
40 3nn 9894 . . . . . . . . . . 11  |-  3  e.  NN
4115, 40decnncl 10153 . . . . . . . . . 10  |- ; 1 3  e.  NN
42 8nn 9899 . . . . . . . . . 10  |-  8  e.  NN
43 eqid 2296 . . . . . . . . . . 11  |- ; 1 3  = ; 1 3
449dec0h 10156 . . . . . . . . . . 11  |-  8  = ; 0 8
45 ax-1cn 8811 . . . . . . . . . . . . . 14  |-  1  e.  CC
4645mulid1i 8855 . . . . . . . . . . . . 13  |-  ( 1  x.  1 )  =  1
4745addid2i 9016 . . . . . . . . . . . . 13  |-  ( 0  +  1 )  =  1
4846, 47oveq12i 5886 . . . . . . . . . . . 12  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  ( 1  +  1 )
49 1p1e2 9856 . . . . . . . . . . . 12  |-  ( 1  +  1 )  =  2
5048, 49eqtri 2316 . . . . . . . . . . 11  |-  ( ( 1  x.  1 )  +  ( 0  +  1 ) )  =  2
51 3cn 9834 . . . . . . . . . . . . . 14  |-  3  e.  CC
5251mulid1i 8855 . . . . . . . . . . . . 13  |-  ( 3  x.  1 )  =  3
5352oveq1i 5884 . . . . . . . . . . . 12  |-  ( ( 3  x.  1 )  +  8 )  =  ( 3  +  8 )
5442nncni 9772 . . . . . . . . . . . . 13  |-  8  e.  CC
55 8p3e11 10196 . . . . . . . . . . . . 13  |-  ( 8  +  3 )  = ; 1
1
5654, 51, 55addcomli 9020 . . . . . . . . . . . 12  |-  ( 3  +  8 )  = ; 1
1
5753, 56eqtri 2316 . . . . . . . . . . 11  |-  ( ( 3  x.  1 )  +  8 )  = ; 1
1
5815, 2, 31, 9, 43, 44, 15, 15, 15, 50, 57decmac 10179 . . . . . . . . . 10  |-  ( (; 1
3  x.  1 )  +  8 )  = ; 2
1
59 1nn 9773 . . . . . . . . . . 11  |-  1  e.  NN
60 8lt10 9939 . . . . . . . . . . 11  |-  8  <  10
6159, 2, 9, 60declti 10165 . . . . . . . . . 10  |-  8  < ; 1
3
6241, 15, 42, 58, 61ndvdsi 12625 . . . . . . . . 9  |-  -. ; 1 3  || ; 2 1
63 13prm 13133 . . . . . . . . . 10  |- ; 1 3  e.  Prime
64 coprm 12795 . . . . . . . . . 10  |-  ( (; 1
3  e.  Prime  /\ ; 2 1  e.  ZZ )  ->  ( -. ; 1 3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 ) )
6563, 36, 64mp2an 653 . . . . . . . . 9  |-  ( -. ; 1
3  || ; 2 1  <->  (; 1 3  gcd ; 2 1 )  =  1 )
6662, 65mpbi 199 . . . . . . . 8  |-  (; 1 3  gcd ; 2 1 )  =  1
6739, 66eqtri 2316 . . . . . . 7  |-  (; 2 1  gcd ; 1 3 )  =  1
68 eqid 2296 . . . . . . . 8  |- ; 2 1  = ; 2 1
69 2cn 9832 . . . . . . . . . . 11  |-  2  e.  CC
7069mulid2i 8856 . . . . . . . . . 10  |-  ( 1  x.  2 )  =  2
7145addid1i 9015 . . . . . . . . . 10  |-  ( 1  +  0 )  =  1
7270, 71oveq12i 5886 . . . . . . . . 9  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  ( 2  +  1 )
73 2p1e3 9863 . . . . . . . . 9  |-  ( 2  +  1 )  =  3
7472, 73eqtri 2316 . . . . . . . 8  |-  ( ( 1  x.  2 )  +  ( 1  +  0 ) )  =  3
7546oveq1i 5884 . . . . . . . . 9  |-  ( ( 1  x.  1 )  +  3 )  =  ( 1  +  3 )
76 3p1e4 9864 . . . . . . . . . 10  |-  ( 3  +  1 )  =  4
7751, 45, 76addcomli 9020 . . . . . . . . 9  |-  ( 1  +  3 )  =  4
783dec0h 10156 . . . . . . . . 9  |-  4  = ; 0 4
7975, 77, 783eqtri 2320 . . . . . . . 8  |-  ( ( 1  x.  1 )  +  3 )  = ; 0
4
8016, 15, 15, 2, 68, 43, 15, 3, 31, 74, 79decma2c 10180 . . . . . . 7  |-  ( ( 1  x. ; 2 1 )  + ; 1
3 )  = ; 3 4
8115, 35, 34, 67, 80gcdi 13104 . . . . . 6  |-  (; 3 4  gcd ; 2 1 )  =  1
82 eqid 2296 . . . . . . 7  |- ; 3 4  = ; 3 4
83 3t2e6 9888 . . . . . . . . . 10  |-  ( 3  x.  2 )  =  6
8451, 69, 83mulcomli 8860 . . . . . . . . 9  |-  ( 2  x.  3 )  =  6
8569addid1i 9015 . . . . . . . . 9  |-  ( 2  +  0 )  =  2
8684, 85oveq12i 5886 . . . . . . . 8  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  ( 6  +  2 )
87 6p2e8 9880 . . . . . . . 8  |-  ( 6  +  2 )  =  8
8886, 87eqtri 2316 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 2  +  0 ) )  =  8
89 4cn 9836 . . . . . . . . . 10  |-  4  e.  CC
90 4t2e8 9890 . . . . . . . . . 10  |-  ( 4  x.  2 )  =  8
9189, 69, 90mulcomli 8860 . . . . . . . . 9  |-  ( 2  x.  4 )  =  8
9291oveq1i 5884 . . . . . . . 8  |-  ( ( 2  x.  4 )  +  1 )  =  ( 8  +  1 )
93 8p1e9 9869 . . . . . . . 8  |-  ( 8  +  1 )  =  9
9412dec0h 10156 . . . . . . . 8  |-  9  = ; 0 9
9592, 93, 943eqtri 2320 . . . . . . 7  |-  ( ( 2  x.  4 )  +  1 )  = ; 0
9
962, 3, 16, 15, 82, 68, 16, 12, 31, 88, 95decma2c 10180 . . . . . 6  |-  ( ( 2  x. ; 3 4 )  + ; 2
1 )  = ; 8 9
9716, 34, 4, 81, 96gcdi 13104 . . . . 5  |-  (; 8 9  gcd ; 3 4 )  =  1
98 eqid 2296 . . . . . 6  |- ; 8 9  = ; 8 9
99 4p3e7 9874 . . . . . . . . 9  |-  ( 4  +  3 )  =  7
10089, 51, 99addcomli 9020 . . . . . . . 8  |-  ( 3  +  4 )  =  7
101100oveq2i 5885 . . . . . . 7  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  =  ( ( 4  x.  8 )  +  7 )
102 7nn0 10003 . . . . . . . 8  |-  7  e.  NN0
103 8t4e32 10230 . . . . . . . . 9  |-  ( 8  x.  4 )  = ; 3
2
10454, 89, 103mulcomli 8860 . . . . . . . 8  |-  ( 4  x.  8 )  = ; 3
2
105 7nn 9898 . . . . . . . . . 10  |-  7  e.  NN
106105nncni 9772 . . . . . . . . 9  |-  7  e.  CC
107 7p2e9 9883 . . . . . . . . 9  |-  ( 7  +  2 )  =  9
108106, 69, 107addcomli 9020 . . . . . . . 8  |-  ( 2  +  7 )  =  9
1092, 16, 102, 104, 108decaddi 10184 . . . . . . 7  |-  ( ( 4  x.  8 )  +  7 )  = ; 3
9
110101, 109eqtri 2316 . . . . . 6  |-  ( ( 4  x.  8 )  +  ( 3  +  4 ) )  = ; 3
9
11120nncni 9772 . . . . . . . 8  |-  9  e.  CC
112 9t4e36 10237 . . . . . . . 8  |-  ( 9  x.  4 )  = ; 3
6
113111, 89, 112mulcomli 8860 . . . . . . 7  |-  ( 4  x.  9 )  = ; 3
6
114 6p4e10 9882 . . . . . . 7  |-  ( 6  +  4 )  =  10
1152, 10, 3, 113, 76, 114decaddci2 10186 . . . . . 6  |-  ( ( 4  x.  9 )  +  4 )  = ; 4
0
1169, 12, 2, 3, 98, 82, 3, 31, 3, 110, 115decma2c 10180 . . . . 5  |-  ( ( 4  x. ; 8 9 )  + ; 3
4 )  = ;; 3 9 0
1173, 4, 33, 97, 116gcdi 13104 . . . 4  |-  (;; 3 9 0  gcd ; 8 9 )  =  1
118 eqid 2296 . . . . 5  |- ;; 3 9 0  = ;; 3 9 0
119 eqid 2296 . . . . . 6  |- ; 3 9  = ; 3 9
12054addid1i 9015 . . . . . . 7  |-  ( 8  +  0 )  =  8
121120, 44eqtri 2316 . . . . . 6  |-  ( 8  +  0 )  = ; 0
8
12269addid2i 9016 . . . . . . . 8  |-  ( 0  +  2 )  =  2
12384, 122oveq12i 5886 . . . . . . 7  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  ( 6  +  2 )
124123, 87eqtri 2316 . . . . . 6  |-  ( ( 2  x.  3 )  +  ( 0  +  2 ) )  =  8
125 9t2e18 10235 . . . . . . . 8  |-  ( 9  x.  2 )  = ; 1
8
126111, 69, 125mulcomli 8860 . . . . . . 7  |-  ( 2  x.  9 )  = ; 1
8
127 8p8e16 10201 . . . . . . 7  |-  ( 8  +  8 )  = ; 1
6
12815, 9, 9, 126, 49, 10, 127decaddci 10185 . . . . . 6  |-  ( ( 2  x.  9 )  +  8 )  = ; 2
6
1292, 12, 31, 9, 119, 121, 16, 10, 16, 124, 128decma2c 10180 . . . . 5  |-  ( ( 2  x. ; 3 9 )  +  ( 8  +  0 ) )  = ; 8 6
13069mul01i 9018 . . . . . . 7  |-  ( 2  x.  0 )  =  0
131130oveq1i 5884 . . . . . 6  |-  ( ( 2  x.  0 )  +  9 )  =  ( 0  +  9 )
132111addid2i 9016 . . . . . 6  |-  ( 0  +  9 )  =  9
133131, 132, 943eqtri 2320 . . . . 5  |-  ( ( 2  x.  0 )  +  9 )  = ; 0
9
13430, 31, 9, 12, 118, 98, 16, 12, 31, 129, 133decma2c 10180 . . . 4  |-  ( ( 2  x. ;; 3 9 0 )  + ; 8
9 )  = ;; 8 6 9
13516, 33, 32, 117, 134gcdi 13104 . . 3  |-  (;; 8 6 9  gcd ;; 3 9 0 )  =  1
13630nn0cni 9993 . . . . . . 7  |- ; 3 9  e.  CC
137136addid1i 9015 . . . . . 6  |-  (; 3 9  +  0 )  = ; 3 9
13854mulid2i 8856 . . . . . . . 8  |-  ( 1  x.  8 )  =  8
139138, 76oveq12i 5886 . . . . . . 7  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  =  ( 8  +  4 )
140 8p4e12 10197 . . . . . . 7  |-  ( 8  +  4 )  = ; 1
2
141139, 140eqtri 2316 . . . . . 6  |-  ( ( 1  x.  8 )  +  ( 3  +  1 ) )  = ; 1
2
142 6nn 9897 . . . . . . . . . 10  |-  6  e.  NN
143142nncni 9772 . . . . . . . . 9  |-  6  e.  CC
144143mulid2i 8856 . . . . . . . 8  |-  ( 1  x.  6 )  =  6
145144oveq1i 5884 . . . . . . 7  |-  ( ( 1  x.  6 )  +  9 )  =  ( 6  +  9 )
146 9p6e15 10206 . . . . . . . 8  |-  ( 9  +  6 )  = ; 1
5
147111, 143, 146addcomli 9020 . . . . . . 7  |-  ( 6  +  9 )  = ; 1
5
148145, 147eqtri 2316 . . . . . 6  |-  ( ( 1  x.  6 )  +  9 )  = ; 1
5
1499, 10, 2, 12, 25, 137, 15, 18, 15, 141, 148decma2c 10180 . . . . 5  |-  ( ( 1  x. ; 8 6 )  +  (; 3 9  +  0 ) )  = ;; 1 2 5
150111mulid2i 8856 . . . . . . 7  |-  ( 1  x.  9 )  =  9
151150oveq1i 5884 . . . . . 6  |-  ( ( 1  x.  9 )  +  0 )  =  ( 9  +  0 )
152111addid1i 9015 . . . . . 6  |-  ( 9  +  0 )  =  9
153151, 152, 943eqtri 2320 . . . . 5  |-  ( ( 1  x.  9 )  +  0 )  = ; 0
9
15411, 12, 30, 31, 27, 118, 15, 12, 31, 149, 153decma2c 10180 . . . 4  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  = ;;; 1 2 5 9
155154, 14eqtr4i 2319 . . 3  |-  ( ( 1  x. ;; 8 6 9 )  + ;; 3 9 0 )  =  N
15615, 32, 13, 135, 155gcdi 13104 . 2  |-  ( N  gcd ;; 8 6 9 )  =  1
1578, 13, 22, 29, 156gcdmodi 13105 1  |-  ( ( ( 2 ^; 3 4 )  - 
1 )  gcd  N
)  =  1
Colors of variables: wff set class
Syntax hints:   -. wn 3    <-> wb 176    = wceq 1632    e. wcel 1696   class class class wbr 4039  (class class class)co 5874   0cc0 8753   1c1 8754    + caddc 8756    x. cmul 8758    - cmin 9053   NNcn 9762   2c2 9811   3c3 9812   4c4 9813   5c5 9814   6c6 9815   7c7 9816   8c8 9817   9c9 9818   NN0cn0 9981   ZZcz 10040  ;cdc 10140   ^cexp 11120    || cdivides 12547    gcd cgcd 12701   Primecprime 12774
This theorem is referenced by:  1259prm  13150
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1536  ax-5 1547  ax-17 1606  ax-9 1644  ax-8 1661  ax-13 1698  ax-14 1700  ax-6 1715  ax-7 1720  ax-11 1727  ax-12 1878  ax-ext 2277  ax-sep 4157  ax-nul 4165  ax-pow 4204  ax-pr 4230  ax-un 4528  ax-cnex 8809  ax-resscn 8810  ax-1cn 8811  ax-icn 8812  ax-addcl 8813  ax-addrcl 8814  ax-mulcl 8815  ax-mulrcl 8816  ax-mulcom 8817  ax-addass 8818  ax-mulass 8819  ax-distr 8820  ax-i2m1 8821  ax-1ne0 8822  ax-1rid 8823  ax-rnegex 8824  ax-rrecex 8825  ax-cnre 8826  ax-pre-lttri 8827  ax-pre-lttrn 8828  ax-pre-ltadd 8829  ax-pre-mulgt0 8830  ax-pre-sup 8831
This theorem depends on definitions:  df-bi 177  df-or 359  df-an 360  df-3or 935  df-3an 936  df-tru 1310  df-ex 1532  df-nf 1535  df-sb 1639  df-eu 2160  df-mo 2161  df-clab 2283  df-cleq 2289  df-clel 2292  df-nfc 2421  df-ne 2461  df-nel 2462  df-ral 2561  df-rex 2562  df-reu 2563  df-rmo 2564  df-rab 2565  df-v 2803  df-sbc 3005  df-csb 3095  df-dif 3168  df-un 3170  df-in 3172  df-ss 3179  df-pss 3181  df-nul 3469  df-if 3579  df-pw 3640  df-sn 3659  df-pr 3660  df-tp 3661  df-op 3662  df-uni 3844  df-int 3879  df-iun 3923  df-br 4040  df-opab 4094  df-mpt 4095  df-tr 4130  df-eprel 4321  df-id 4325  df-po 4330  df-so 4331  df-fr 4368  df-we 4370  df-ord 4411  df-on 4412  df-lim 4413  df-suc 4414  df-om 4673  df-xp 4711  df-rel 4712  df-cnv 4713  df-co 4714  df-dm 4715  df-rn 4716  df-res 4717  df-ima 4718  df-iota 5235  df-fun 5273  df-fn 5274  df-f 5275  df-f1 5276  df-fo 5277  df-f1o 5278  df-fv 5279  df-ov 5877  df-oprab 5878  df-mpt2 5879  df-1st 6138  df-2nd 6139  df-riota 6320  df-recs 6404  df-rdg 6439  df-1o 6495  df-2o 6496  df-oadd 6499  df-er 6676  df-en 6880  df-dom 6881  df-sdom 6882  df-fin 6883  df-sup 7210  df-pnf 8885  df-mnf 8886  df-xr 8887  df-ltxr 8888  df-le 8889  df-sub 9055  df-neg 9056  df-div 9440  df-nn 9763  df-2 9820  df-3 9821  df-4 9822  df-5 9823  df-6 9824  df-7 9825  df-8 9826  df-9 9827  df-10 9828  df-n0 9982  df-z 10041  df-dec 10141  df-uz 10247  df-rp 10371  df-fz 10799  df-fl 10941  df-mod 10990  df-seq 11063  df-exp 11121  df-cj 11600  df-re 11601  df-im 11602  df-sqr 11736  df-abs 11737  df-dvds 12548  df-gcd 12702  df-prm 12775
  Copyright terms: Public domain W3C validator