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

Theorem 1259lem3 15840
Description: Lemma for 1259prm 15843. Calculate a power mod. In decimal, we calculate  2 ^ 3 8  =  2 ^ 3 4  x.  2 ^ 4  ==  8
7 0  x.  1 6  =  1 1 N  +  7 1 and  2 ^ 7 6  =  ( 2 ^ 3 4 ) ^ 2  ==  7
1 ^ 2  =  4 N  +  5  ==  5. (Contributed by Mario Carneiro, 22-Feb-2014.) (Revised by Mario Carneiro, 20-Apr-2015.) (Proof shortened by AV, 16-Sep-2021.)
Hypothesis
Ref Expression
1259prm.1  |-  N  = ;;; 1 2 5 9
Assertion
Ref Expression
1259lem3  |-  ( ( 2 ^; 7 6 )  mod 
N )  =  ( 5  mod  N )

Proof of Theorem 1259lem3
StepHypRef Expression
1 1259prm.1 . . 3  |-  N  = ;;; 1 2 5 9
2 1nn0 11308 . . . . . 6  |-  1  e.  NN0
3 2nn0 11309 . . . . . 6  |-  2  e.  NN0
42, 3deccl 11512 . . . . 5  |- ; 1 2  e.  NN0
5 5nn0 11312 . . . . 5  |-  5  e.  NN0
64, 5deccl 11512 . . . 4  |- ;; 1 2 5  e.  NN0
7 9nn 11192 . . . 4  |-  9  e.  NN
86, 7decnncl 11518 . . 3  |- ;;; 1 2 5 9  e.  NN
91, 8eqeltri 2697 . 2  |-  N  e.  NN
10 2nn 11185 . 2  |-  2  e.  NN
11 3nn0 11310 . . 3  |-  3  e.  NN0
12 8nn0 11315 . . 3  |-  8  e.  NN0
1311, 12deccl 11512 . 2  |- ; 3 8  e.  NN0
14 4z 11411 . 2  |-  4  e.  ZZ
15 7nn0 11314 . . 3  |-  7  e.  NN0
1615, 2deccl 11512 . 2  |- ; 7 1  e.  NN0
17 4nn0 11311 . . . 4  |-  4  e.  NN0
1811, 17deccl 11512 . . 3  |- ; 3 4  e.  NN0
192, 2deccl 11512 . . . 4  |- ; 1 1  e.  NN0
2019nn0zi 11402 . . 3  |- ; 1 1  e.  ZZ
2112, 15deccl 11512 . . . 4  |- ; 8 7  e.  NN0
22 0nn0 11307 . . . 4  |-  0  e.  NN0
2321, 22deccl 11512 . . 3  |- ;; 8 7 0  e.  NN0
24 6nn0 11313 . . . 4  |-  6  e.  NN0
252, 24deccl 11512 . . 3  |- ; 1 6  e.  NN0
2611259lem2 15839 . . 3  |-  ( ( 2 ^; 3 4 )  mod 
N )  =  (;; 8 7 0  mod 
N )
27 2exp4 15794 . . . 4  |-  ( 2 ^ 4 )  = ; 1
6
2827oveq1i 6660 . . 3  |-  ( ( 2 ^ 4 )  mod  N )  =  (; 1 6  mod  N
)
29 eqid 2622 . . . 4  |- ; 3 4  = ; 3 4
30 4p4e8 11164 . . . 4  |-  ( 4  +  4 )  =  8
3111, 17, 17, 29, 30decaddi 11579 . . 3  |-  (; 3 4  +  4 )  = ; 3 8
32 9nn0 11316 . . . . 5  |-  9  e.  NN0
33 eqid 2622 . . . . 5  |- ; 7 1  = ; 7 1
34 10nn0 11516 . . . . 5  |- ; 1 0  e.  NN0
35 eqid 2622 . . . . . 6  |- ; 1 1  = ; 1 1
3634nn0cni 11304 . . . . . . 7  |- ; 1 0  e.  CC
37 7cn 11104 . . . . . . 7  |-  7  e.  CC
38 dec10p 11553 . . . . . . 7  |-  (; 1 0  +  7 )  = ; 1 7
3936, 37, 38addcomli 10228 . . . . . 6  |-  ( 7  + ; 1 0 )  = ; 1
7
402, 11deccl 11512 . . . . . 6  |- ; 1 3  e.  NN0
416nn0cni 11304 . . . . . . . 8  |- ;; 1 2 5  e.  CC
4241mulid2i 10043 . . . . . . 7  |-  ( 1  x. ;; 1 2 5 )  = ;; 1 2 5
432dec0h 11522 . . . . . . . 8  |-  1  = ; 0 1
44 eqid 2622 . . . . . . . 8  |- ; 1 3  = ; 1 3
45 0p1e1 11132 . . . . . . . 8  |-  ( 0  +  1 )  =  1
46 3cn 11095 . . . . . . . . 9  |-  3  e.  CC
47 ax-1cn 9994 . . . . . . . . 9  |-  1  e.  CC
48 3p1e4 11153 . . . . . . . . 9  |-  ( 3  +  1 )  =  4
4946, 47, 48addcomli 10228 . . . . . . . 8  |-  ( 1  +  3 )  =  4
5022, 2, 2, 11, 43, 44, 45, 49decadd 11570 . . . . . . 7  |-  ( 1  + ; 1 3 )  = ; 1
4
51 2p1e3 11151 . . . . . . . 8  |-  ( 2  +  1 )  =  3
52 eqid 2622 . . . . . . . 8  |- ; 1 2  = ; 1 2
532, 3, 51, 52decsuc 11535 . . . . . . 7  |-  (; 1 2  +  1 )  = ; 1 3
54 5p4e9 11167 . . . . . . 7  |-  ( 5  +  4 )  =  9
554, 5, 2, 17, 42, 50, 53, 54decadd 11570 . . . . . 6  |-  ( ( 1  x. ;; 1 2 5 )  +  ( 1  + ; 1 3 ) )  = ;; 1 3 9
56 5cn 11100 . . . . . . . 8  |-  5  e.  CC
57 7p5e12 11607 . . . . . . . 8  |-  ( 7  +  5 )  = ; 1
2
5837, 56, 57addcomli 10228 . . . . . . 7  |-  ( 5  +  7 )  = ; 1
2
594, 5, 15, 42, 53, 3, 58decaddci 11580 . . . . . 6  |-  ( ( 1  x. ;; 1 2 5 )  +  7 )  = ;; 1 3 2
602, 2, 2, 15, 35, 39, 6, 3, 40, 55, 59decmac 11566 . . . . 5  |-  ( (; 1
1  x. ;; 1 2 5 )  +  ( 7  + ; 1 0 ) )  = ;;; 1 3 9 2
61 9p1e10 11496 . . . . . 6  |-  ( 9  +  1 )  = ; 1
0
62 9cn 11108 . . . . . . 7  |-  9  e.  CC
6319nn0cni 11304 . . . . . . 7  |- ; 1 1  e.  CC
64 9t11e99 11671 . . . . . . 7  |-  ( 9  x. ; 1 1 )  = ; 9
9
6562, 63, 64mulcomli 10047 . . . . . 6  |-  (; 1 1  x.  9 )  = ; 9 9
6632, 61, 65decsucc 11550 . . . . 5  |-  ( (; 1
1  x.  9 )  +  1 )  = ;; 1 0 0
676, 32, 15, 2, 1, 33, 19, 22, 34, 60, 66decma2c 11568 . . . 4  |-  ( (; 1
1  x.  N )  + ; 7 1 )  = ;;;; 1 3 9 2 0
68 eqid 2622 . . . . 5  |- ; 1 6  = ; 1 6
695, 3deccl 11512 . . . . . 6  |- ; 5 2  e.  NN0
7069, 3deccl 11512 . . . . 5  |- ;; 5 2 2  e.  NN0
71 eqid 2622 . . . . . 6  |- ;; 8 7 0  = ;; 8 7 0
72 eqid 2622 . . . . . 6  |- ;; 5 2 2  = ;; 5 2 2
73 eqid 2622 . . . . . . 7  |- ; 8 7  = ; 8 7
7469nn0cni 11304 . . . . . . . 8  |- ; 5 2  e.  CC
7574addid1i 10223 . . . . . . 7  |-  (; 5 2  +  0 )  = ; 5 2
76 8cn 11106 . . . . . . . . . 10  |-  8  e.  CC
7776mulid1i 10042 . . . . . . . . 9  |-  ( 8  x.  1 )  =  8
7856addid1i 10223 . . . . . . . . 9  |-  ( 5  +  0 )  =  5
7977, 78oveq12i 6662 . . . . . . . 8  |-  ( ( 8  x.  1 )  +  ( 5  +  0 ) )  =  ( 8  +  5 )
80 8p5e13 11615 . . . . . . . 8  |-  ( 8  +  5 )  = ; 1
3
8179, 80eqtri 2644 . . . . . . 7  |-  ( ( 8  x.  1 )  +  ( 5  +  0 ) )  = ; 1
3
8237mulid1i 10042 . . . . . . . . 9  |-  ( 7  x.  1 )  =  7
8382oveq1i 6660 . . . . . . . 8  |-  ( ( 7  x.  1 )  +  2 )  =  ( 7  +  2 )
84 7p2e9 11172 . . . . . . . 8  |-  ( 7  +  2 )  =  9
8532dec0h 11522 . . . . . . . 8  |-  9  = ; 0 9
8683, 84, 853eqtri 2648 . . . . . . 7  |-  ( ( 7  x.  1 )  +  2 )  = ; 0
9
8712, 15, 5, 3, 73, 75, 2, 32, 22, 81, 86decmac 11566 . . . . . 6  |-  ( (; 8
7  x.  1 )  +  (; 5 2  +  0 ) )  = ;; 1 3 9
8847mul02i 10225 . . . . . . . 8  |-  ( 0  x.  1 )  =  0
8988oveq1i 6660 . . . . . . 7  |-  ( ( 0  x.  1 )  +  2 )  =  ( 0  +  2 )
90 2cn 11091 . . . . . . . 8  |-  2  e.  CC
9190addid2i 10224 . . . . . . 7  |-  ( 0  +  2 )  =  2
923dec0h 11522 . . . . . . 7  |-  2  = ; 0 2
9389, 91, 923eqtri 2648 . . . . . 6  |-  ( ( 0  x.  1 )  +  2 )  = ; 0
2
9421, 22, 69, 3, 71, 72, 2, 3, 22, 87, 93decmac 11566 . . . . 5  |-  ( (;; 8 7 0  x.  1 )  + ;; 5 2 2 )  = ;;; 1 3 9 2
95 8t6e48 11659 . . . . . . . 8  |-  ( 8  x.  6 )  = ; 4
8
96 4p1e5 11154 . . . . . . . 8  |-  ( 4  +  1 )  =  5
97 8p4e12 11614 . . . . . . . 8  |-  ( 8  +  4 )  = ; 1
2
9817, 12, 17, 95, 96, 3, 97decaddci 11580 . . . . . . 7  |-  ( ( 8  x.  6 )  +  4 )  = ; 5
2
99 7t6e42 11652 . . . . . . 7  |-  ( 7  x.  6 )  = ; 4
2
10024, 12, 15, 73, 3, 17, 98, 99decmul1c 11587 . . . . . 6  |-  (; 8 7  x.  6 )  = ;; 5 2 2
101 6cn 11102 . . . . . . 7  |-  6  e.  CC
102101mul02i 10225 . . . . . 6  |-  ( 0  x.  6 )  =  0
10324, 21, 22, 71, 22, 100, 102decmul1 11585 . . . . 5  |-  (;; 8 7 0  x.  6 )  = ;;; 5 2 2 0
10423, 2, 24, 68, 22, 70, 94, 103decmul2c 11589 . . . 4  |-  (;; 8 7 0  x. ; 1 6 )  = ;;;; 1 3 9 2 0
10567, 104eqtr4i 2647 . . 3  |-  ( (; 1
1  x.  N )  + ; 7 1 )  =  (;; 8 7 0  x. ; 1 6 )
1069, 10, 18, 20, 23, 16, 17, 25, 26, 28, 31, 105modxai 15772 . 2  |-  ( ( 2 ^; 3 8 )  mod 
N )  =  (; 7
1  mod  N )
107 eqid 2622 . . 3  |- ; 3 8  = ; 3 8
108 3t2e6 11179 . . . . . 6  |-  ( 3  x.  2 )  =  6
10946, 90, 108mulcomli 10047 . . . . 5  |-  ( 2  x.  3 )  =  6
110109oveq1i 6660 . . . 4  |-  ( ( 2  x.  3 )  +  1 )  =  ( 6  +  1 )
111 6p1e7 11156 . . . 4  |-  ( 6  +  1 )  =  7
112110, 111eqtri 2644 . . 3  |-  ( ( 2  x.  3 )  +  1 )  =  7
113 8t2e16 11654 . . . 4  |-  ( 8  x.  2 )  = ; 1
6
11476, 90, 113mulcomli 10047 . . 3  |-  ( 2  x.  8 )  = ; 1
6
1153, 11, 12, 107, 24, 2, 112, 114decmul2c 11589 . 2  |-  ( 2  x. ; 3 8 )  = ; 7
6
1165dec0h 11522 . . . 4  |-  5  = ; 0 5
117 eqid 2622 . . . . 5  |- ;; 1 2 5  = ;; 1 2 5
118 4cn 11098 . . . . . . 7  |-  4  e.  CC
119118addid2i 10224 . . . . . 6  |-  ( 0  +  4 )  =  4
12017dec0h 11522 . . . . . 6  |-  4  = ; 0 4
121119, 120eqtri 2644 . . . . 5  |-  ( 0  +  4 )  = ; 0
4
12291, 92eqtri 2644 . . . . . 6  |-  ( 0  +  2 )  = ; 0
2
123118mulid1i 10042 . . . . . . . 8  |-  ( 4  x.  1 )  =  4
124123, 45oveq12i 6662 . . . . . . 7  |-  ( ( 4  x.  1 )  +  ( 0  +  1 ) )  =  ( 4  +  1 )
125124, 96eqtri 2644 . . . . . 6  |-  ( ( 4  x.  1 )  +  ( 0  +  1 ) )  =  5
126 4t2e8 11181 . . . . . . . 8  |-  ( 4  x.  2 )  =  8
127126oveq1i 6660 . . . . . . 7  |-  ( ( 4  x.  2 )  +  2 )  =  ( 8  +  2 )
128 8p2e10 11610 . . . . . . 7  |-  ( 8  +  2 )  = ; 1
0
129127, 128eqtri 2644 . . . . . 6  |-  ( ( 4  x.  2 )  +  2 )  = ; 1
0
1302, 3, 22, 3, 52, 122, 17, 22, 2, 125, 129decma2c 11568 . . . . 5  |-  ( ( 4  x. ; 1 2 )  +  ( 0  +  2 ) )  = ; 5 0
131 5t4e20 11637 . . . . . . 7  |-  ( 5  x.  4 )  = ; 2
0
13256, 118, 131mulcomli 10047 . . . . . 6  |-  ( 4  x.  5 )  = ; 2
0
1333, 22, 17, 132, 119decaddi 11579 . . . . 5  |-  ( ( 4  x.  5 )  +  4 )  = ; 2
4
1344, 5, 22, 17, 117, 121, 17, 17, 3, 130, 133decma2c 11568 . . . 4  |-  ( ( 4  x. ;; 1 2 5 )  +  ( 0  +  4 ) )  = ;; 5 0 4
135 9t4e36 11665 . . . . . 6  |-  ( 9  x.  4 )  = ; 3
6
13662, 118, 135mulcomli 10047 . . . . 5  |-  ( 4  x.  9 )  = ; 3
6
137 6p5e11 11600 . . . . 5  |-  ( 6  +  5 )  = ; 1
1
13811, 24, 5, 136, 48, 2, 137decaddci 11580 . . . 4  |-  ( ( 4  x.  9 )  +  5 )  = ; 4
1
1396, 32, 22, 5, 1, 116, 17, 2, 17, 134, 138decma2c 11568 . . 3  |-  ( ( 4  x.  N )  +  5 )  = ;;; 5 0 4 1
140 7t7e49 11653 . . . . . 6  |-  ( 7  x.  7 )  = ; 4
9
14117, 96, 140decsucc 11550 . . . . 5  |-  ( ( 7  x.  7 )  +  1 )  = ; 5
0
14237mulid2i 10043 . . . . . . 7  |-  ( 1  x.  7 )  =  7
143142oveq1i 6660 . . . . . 6  |-  ( ( 1  x.  7 )  +  7 )  =  ( 7  +  7 )
144 7p7e14 11609 . . . . . 6  |-  ( 7  +  7 )  = ; 1
4
145143, 144eqtri 2644 . . . . 5  |-  ( ( 1  x.  7 )  +  7 )  = ; 1
4
14615, 2, 15, 33, 15, 17, 2, 141, 145decrmac 11577 . . . 4  |-  ( (; 7
1  x.  7 )  +  7 )  = ;; 5 0 4
14716nn0cni 11304 . . . . 5  |- ; 7 1  e.  CC
148147mulid1i 10042 . . . 4  |-  (; 7 1  x.  1 )  = ; 7 1
14916, 15, 2, 33, 2, 15, 146, 148decmul2c 11589 . . 3  |-  (; 7 1  x. ; 7 1 )  = ;;; 5 0 4 1
150139, 149eqtr4i 2647 . 2  |-  ( ( 4  x.  N )  +  5 )  =  (; 7 1  x. ; 7 1 )
1519, 10, 13, 14, 16, 5, 106, 115, 150mod2xi 15773 1  |-  ( ( 2 ^; 7 6 )  mod 
N )  =  ( 5  mod  N )
Colors of variables: wff setvar class
Syntax hints:    = wceq 1483  (class class class)co 6650   0cc0 9936   1c1 9937    + caddc 9939    x. cmul 9941   NNcn 11020   2c2 11070   3c3 11071   4c4 11072   5c5 11073   6c6 11074   7c7 11075   8c8 11076   9c9 11077  ;cdc 11493    mod cmo 12668   ^cexp 12860
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-2nd 7169  df-wrecs 7407  df-recs 7468  df-rdg 7506  df-er 7742  df-en 7956  df-dom 7957  df-sdom 7958  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-fl 12593  df-mod 12669  df-seq 12802  df-exp 12861
This theorem is referenced by:  1259lem4  15841
  Copyright terms: Public domain W3C validator