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

Theorem lgsdir2lem2 21100
Description: Lemma for lgsdir2 21104. (Contributed by Mario Carneiro, 4-Feb-2015.)
Hypotheses
Ref Expression
lgsdir2lem2.1  |-  ( K  e.  ZZ  /\  2  ||  ( K  +  1 )  /\  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... K
)  ->  ( A  mod  8 )  e.  S
) ) )
lgsdir2lem2.2  |-  M  =  ( K  +  1 )
lgsdir2lem2.3  |-  N  =  ( M  +  1 )
lgsdir2lem2.4  |-  N  e.  S
Assertion
Ref Expression
lgsdir2lem2  |-  ( N  e.  ZZ  /\  2  ||  ( N  +  1 )  /\  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... N
)  ->  ( A  mod  8 )  e.  S
) ) )

Proof of Theorem lgsdir2lem2
StepHypRef Expression
1 lgsdir2lem2.3 . . 3  |-  N  =  ( M  +  1 )
2 lgsdir2lem2.2 . . . . 5  |-  M  =  ( K  +  1 )
3 lgsdir2lem2.1 . . . . . . 7  |-  ( K  e.  ZZ  /\  2  ||  ( K  +  1 )  /\  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... K
)  ->  ( A  mod  8 )  e.  S
) ) )
43simp1i 966 . . . . . 6  |-  K  e.  ZZ
5 peano2z 10310 . . . . . 6  |-  ( K  e.  ZZ  ->  ( K  +  1 )  e.  ZZ )
64, 5ax-mp 8 . . . . 5  |-  ( K  +  1 )  e.  ZZ
72, 6eqeltri 2505 . . . 4  |-  M  e.  ZZ
8 peano2z 10310 . . . 4  |-  ( M  e.  ZZ  ->  ( M  +  1 )  e.  ZZ )
97, 8ax-mp 8 . . 3  |-  ( M  +  1 )  e.  ZZ
101, 9eqeltri 2505 . 2  |-  N  e.  ZZ
113simp2i 967 . . . 4  |-  2  ||  ( K  +  1 )
12 2z 10304 . . . . 5  |-  2  e.  ZZ
13 dvdsadd 12880 . . . . 5  |-  ( ( 2  e.  ZZ  /\  ( K  +  1
)  e.  ZZ )  ->  ( 2  ||  ( K  +  1
)  <->  2  ||  (
2  +  ( K  +  1 ) ) ) )
1412, 6, 13mp2an 654 . . . 4  |-  ( 2 
||  ( K  + 
1 )  <->  2  ||  ( 2  +  ( K  +  1 ) ) )
1511, 14mpbi 200 . . 3  |-  2  ||  ( 2  +  ( K  +  1 ) )
16 zcn 10279 . . . . . . . . . . 11  |-  ( K  e.  ZZ  ->  K  e.  CC )
174, 16ax-mp 8 . . . . . . . . . 10  |-  K  e.  CC
18 ax-1cn 9040 . . . . . . . . . 10  |-  1  e.  CC
1917, 18addcomi 9249 . . . . . . . . 9  |-  ( K  +  1 )  =  ( 1  +  K
)
202, 19eqtri 2455 . . . . . . . 8  |-  M  =  ( 1  +  K
)
2120oveq1i 6083 . . . . . . 7  |-  ( M  +  1 )  =  ( ( 1  +  K )  +  1 )
221, 21eqtri 2455 . . . . . 6  |-  N  =  ( ( 1  +  K )  +  1 )
23 df-2 10050 . . . . . . . 8  |-  2  =  ( 1  +  1 )
2423oveq1i 6083 . . . . . . 7  |-  ( 2  +  K )  =  ( ( 1  +  1 )  +  K
)
2518, 17, 18add32i 9276 . . . . . . 7  |-  ( ( 1  +  K )  +  1 )  =  ( ( 1  +  1 )  +  K
)
2624, 25eqtr4i 2458 . . . . . 6  |-  ( 2  +  K )  =  ( ( 1  +  K )  +  1 )
2722, 26eqtr4i 2458 . . . . 5  |-  N  =  ( 2  +  K
)
2827oveq1i 6083 . . . 4  |-  ( N  +  1 )  =  ( ( 2  +  K )  +  1 )
29 2cn 10062 . . . . 5  |-  2  e.  CC
3029, 17, 18addassi 9090 . . . 4  |-  ( ( 2  +  K )  +  1 )  =  ( 2  +  ( K  +  1 ) )
3128, 30eqtri 2455 . . 3  |-  ( N  +  1 )  =  ( 2  +  ( K  +  1 ) )
3215, 31breqtrri 4229 . 2  |-  2  ||  ( N  +  1 )
33 elfzuz2 11054 . . . . 5  |-  ( ( A  mod  8 )  e.  ( 0 ... N )  ->  N  e.  ( ZZ>= `  0 )
)
34 fzm1 11119 . . . . 5  |-  ( N  e.  ( ZZ>= `  0
)  ->  ( ( A  mod  8 )  e.  ( 0 ... N
)  <->  ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  \/  ( A  mod  8 )  =  N ) ) )
3533, 34syl 16 . . . 4  |-  ( ( A  mod  8 )  e.  ( 0 ... N )  ->  (
( A  mod  8
)  e.  ( 0 ... N )  <->  ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  \/  ( A  mod  8 )  =  N ) ) )
3635ibi 233 . . 3  |-  ( ( A  mod  8 )  e.  ( 0 ... N )  ->  (
( A  mod  8
)  e.  ( 0 ... ( N  - 
1 ) )  \/  ( A  mod  8
)  =  N ) )
37 elfzuz2 11054 . . . . . . . 8  |-  ( ( A  mod  8 )  e.  ( 0 ... M )  ->  M  e.  ( ZZ>= `  0 )
)
38 fzm1 11119 . . . . . . . 8  |-  ( M  e.  ( ZZ>= `  0
)  ->  ( ( A  mod  8 )  e.  ( 0 ... M
)  <->  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  \/  ( A  mod  8 )  =  M ) ) )
3937, 38syl 16 . . . . . . 7  |-  ( ( A  mod  8 )  e.  ( 0 ... M )  ->  (
( A  mod  8
)  e.  ( 0 ... M )  <->  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  \/  ( A  mod  8 )  =  M ) ) )
4039ibi 233 . . . . . 6  |-  ( ( A  mod  8 )  e.  ( 0 ... M )  ->  (
( A  mod  8
)  e.  ( 0 ... ( M  - 
1 ) )  \/  ( A  mod  8
)  =  M ) )
41 zcn 10279 . . . . . . . . 9  |-  ( N  e.  ZZ  ->  N  e.  CC )
4210, 41ax-mp 8 . . . . . . . 8  |-  N  e.  CC
43 zcn 10279 . . . . . . . . 9  |-  ( M  e.  ZZ  ->  M  e.  CC )
447, 43ax-mp 8 . . . . . . . 8  |-  M  e.  CC
4518, 44addcomi 9249 . . . . . . . . 9  |-  ( 1  +  M )  =  ( M  +  1 )
4645, 1eqtr4i 2458 . . . . . . . 8  |-  ( 1  +  M )  =  N
4742, 18, 44, 46subaddrii 9381 . . . . . . 7  |-  ( N  -  1 )  =  M
4847oveq2i 6084 . . . . . 6  |-  ( 0 ... ( N  - 
1 ) )  =  ( 0 ... M
)
4940, 48eleq2s 2527 . . . . 5  |-  ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  ->  (
( A  mod  8
)  e.  ( 0 ... ( M  - 
1 ) )  \/  ( A  mod  8
)  =  M ) )
5020eqcomi 2439 . . . . . . . . . 10  |-  ( 1  +  K )  =  M
5144, 18, 17, 50subaddrii 9381 . . . . . . . . 9  |-  ( M  -  1 )  =  K
5251oveq2i 6084 . . . . . . . 8  |-  ( 0 ... ( M  - 
1 ) )  =  ( 0 ... K
)
5352eleq2i 2499 . . . . . . 7  |-  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  <->  ( A  mod  8 )  e.  ( 0 ... K ) )
543simp3i 968 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... K
)  ->  ( A  mod  8 )  e.  S
) )
5553, 54syl5bi 209 . . . . . 6  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  ->  ( A  mod  8 )  e.  S
) )
56 2nn 10125 . . . . . . . . . . 11  |-  2  e.  NN
57 8nn 10131 . . . . . . . . . . 11  |-  8  e.  NN
58 4nn 10127 . . . . . . . . . . . . . . 15  |-  4  e.  NN
5958nnzi 10297 . . . . . . . . . . . . . 14  |-  4  e.  ZZ
60 dvdsmul2 12864 . . . . . . . . . . . . . 14  |-  ( ( 4  e.  ZZ  /\  2  e.  ZZ )  ->  2  ||  ( 4  x.  2 ) )
6159, 12, 60mp2an 654 . . . . . . . . . . . . 13  |-  2  ||  ( 4  x.  2 )
62 4t2e8 10122 . . . . . . . . . . . . 13  |-  ( 4  x.  2 )  =  8
6361, 62breqtri 4227 . . . . . . . . . . . 12  |-  2  ||  8
64 dvdsmod 12898 . . . . . . . . . . . 12  |-  ( ( ( 2  e.  NN  /\  8  e.  NN  /\  A  e.  ZZ )  /\  2  ||  8 )  ->  ( 2  ||  ( A  mod  8
)  <->  2  ||  A
) )
6563, 64mpan2 653 . . . . . . . . . . 11  |-  ( ( 2  e.  NN  /\  8  e.  NN  /\  A  e.  ZZ )  ->  (
2  ||  ( A  mod  8 )  <->  2  ||  A ) )
6656, 57, 65mp3an12 1269 . . . . . . . . . 10  |-  ( A  e.  ZZ  ->  (
2  ||  ( A  mod  8 )  <->  2  ||  A ) )
6766notbid 286 . . . . . . . . 9  |-  ( A  e.  ZZ  ->  ( -.  2  ||  ( A  mod  8 )  <->  -.  2  ||  A ) )
6867biimpar 472 . . . . . . . 8  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  -.  2  ||  ( A  mod  8
) )
6911, 2breqtrri 4229 . . . . . . . . 9  |-  2  ||  M
70 id 20 . . . . . . . . 9  |-  ( ( A  mod  8 )  =  M  ->  ( A  mod  8 )  =  M )
7169, 70syl5breqr 4240 . . . . . . . 8  |-  ( ( A  mod  8 )  =  M  ->  2  ||  ( A  mod  8
) )
7268, 71nsyl 115 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  -.  ( A  mod  8 )  =  M )
7372pm2.21d 100 . . . . . 6  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  =  M  ->  ( A  mod  8 )  e.  S
) )
7455, 73jaod 370 . . . . 5  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  \/  ( A  mod  8 )  =  M )  ->  ( A  mod  8 )  e.  S ) )
7549, 74syl5 30 . . . 4  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  ->  ( A  mod  8 )  e.  S
) )
76 lgsdir2lem2.4 . . . . . 6  |-  N  e.  S
77 eleq1 2495 . . . . . 6  |-  ( ( A  mod  8 )  =  N  ->  (
( A  mod  8
)  e.  S  <->  N  e.  S ) )
7876, 77mpbiri 225 . . . . 5  |-  ( ( A  mod  8 )  =  N  ->  ( A  mod  8 )  e.  S )
7978a1i 11 . . . 4  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  =  N  ->  ( A  mod  8 )  e.  S
) )
8075, 79jaod 370 . . 3  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  \/  ( A  mod  8 )  =  N )  ->  ( A  mod  8 )  e.  S ) )
8136, 80syl5 30 . 2  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... N
)  ->  ( A  mod  8 )  e.  S
) )
8210, 32, 813pm3.2i 1132 1  |-  ( N  e.  ZZ  /\  2  ||  ( N  +  1 )  /\  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... N
)  ->  ( A  mod  8 )  e.  S
) ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 177    \/ wo 358    /\ wa 359    /\ w3a 936    = wceq 1652    e. wcel 1725   class class class wbr 4204   ` cfv 5446  (class class class)co 6073   CCcc 8980   0cc0 8982   1c1 8983    + caddc 8985    x. cmul 8987    - cmin 9283   NNcn 9992   2c2 10041   4c4 10043   8c8 10047   ZZcz 10274   ZZ>=cuz 10480   ...cfz 11035    mod cmo 11242    || cdivides 12844
This theorem is referenced by:  lgsdir2lem3  21101
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1555  ax-5 1566  ax-17 1626  ax-9 1666  ax-8 1687  ax-13 1727  ax-14 1729  ax-6 1744  ax-7 1749  ax-11 1761  ax-12 1950  ax-ext 2416  ax-sep 4322  ax-nul 4330  ax-pow 4369  ax-pr 4395  ax-un 4693  ax-cnex 9038  ax-resscn 9039  ax-1cn 9040  ax-icn 9041  ax-addcl 9042  ax-addrcl 9043  ax-mulcl 9044  ax-mulrcl 9045  ax-mulcom 9046  ax-addass 9047  ax-mulass 9048  ax-distr 9049  ax-i2m1 9050  ax-1ne0 9051  ax-1rid 9052  ax-rnegex 9053  ax-rrecex 9054  ax-cnre 9055  ax-pre-lttri 9056  ax-pre-lttrn 9057  ax-pre-ltadd 9058  ax-pre-mulgt0 9059  ax-pre-sup 9060
This theorem depends on definitions:  df-bi 178  df-or 360  df-an 361  df-3or 937  df-3an 938  df-tru 1328  df-ex 1551  df-nf 1554  df-sb 1659  df-eu 2284  df-mo 2285  df-clab 2422  df-cleq 2428  df-clel 2431  df-nfc 2560  df-ne 2600  df-nel 2601  df-ral 2702  df-rex 2703  df-reu 2704  df-rmo 2705  df-rab 2706  df-v 2950  df-sbc 3154  df-csb 3244  df-dif 3315  df-un 3317  df-in 3319  df-ss 3326  df-pss 3328  df-nul 3621  df-if 3732  df-pw 3793  df-sn 3812  df-pr 3813  df-tp 3814  df-op 3815  df-uni 4008  df-iun 4087  df-br 4205  df-opab 4259  df-mpt 4260  df-tr 4295  df-eprel 4486  df-id 4490  df-po 4495  df-so 4496  df-fr 4533  df-we 4535  df-ord 4576  df-on 4577  df-lim 4578  df-suc 4579  df-om 4838  df-xp 4876  df-rel 4877  df-cnv 4878  df-co 4879  df-dm 4880  df-rn 4881  df-res 4882  df-ima 4883  df-iota 5410  df-fun 5448  df-fn 5449  df-f 5450  df-f1 5451  df-fo 5452  df-f1o 5453  df-fv 5454  df-ov 6076  df-oprab 6077  df-mpt2 6078  df-1st 6341  df-2nd 6342  df-riota 6541  df-recs 6625  df-rdg 6660  df-er 6897  df-en 7102  df-dom 7103  df-sdom 7104  df-sup 7438  df-pnf 9114  df-mnf 9115  df-xr 9116  df-ltxr 9117  df-le 9118  df-sub 9285  df-neg 9286  df-div 9670  df-nn 9993  df-2 10050  df-3 10051  df-4 10052  df-5 10053  df-6 10054  df-7 10055  df-8 10056  df-n0 10214  df-z 10275  df-uz 10481  df-rp 10605  df-fz 11036  df-fl 11194  df-mod 11243  df-dvds 12845
  Copyright terms: Public domain W3C validator