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

Theorem lgsdir2lem2 20579
Description: Lemma for lgsdir2 20583. (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 964 . . . . . 6  |-  K  e.  ZZ
5 peano2z 10076 . . . . . 6  |-  ( K  e.  ZZ  ->  ( K  +  1 )  e.  ZZ )
64, 5ax-mp 8 . . . . 5  |-  ( K  +  1 )  e.  ZZ
72, 6eqeltri 2366 . . . 4  |-  M  e.  ZZ
8 peano2z 10076 . . . 4  |-  ( M  e.  ZZ  ->  ( M  +  1 )  e.  ZZ )
97, 8ax-mp 8 . . 3  |-  ( M  +  1 )  e.  ZZ
101, 9eqeltri 2366 . 2  |-  N  e.  ZZ
113simp2i 965 . . . 4  |-  2  ||  ( K  +  1 )
12 2z 10070 . . . . 5  |-  2  e.  ZZ
13 dvdsadd 12583 . . . . 5  |-  ( ( 2  e.  ZZ  /\  ( K  +  1
)  e.  ZZ )  ->  ( 2  ||  ( K  +  1
)  <->  2  ||  (
2  +  ( K  +  1 ) ) ) )
1412, 6, 13mp2an 653 . . . 4  |-  ( 2 
||  ( K  + 
1 )  <->  2  ||  ( 2  +  ( K  +  1 ) ) )
1511, 14mpbi 199 . . 3  |-  2  ||  ( 2  +  ( K  +  1 ) )
16 zcn 10045 . . . . . . . . . . 11  |-  ( K  e.  ZZ  ->  K  e.  CC )
174, 16ax-mp 8 . . . . . . . . . 10  |-  K  e.  CC
18 ax-1cn 8811 . . . . . . . . . 10  |-  1  e.  CC
1917, 18addcomi 9019 . . . . . . . . 9  |-  ( K  +  1 )  =  ( 1  +  K
)
202, 19eqtri 2316 . . . . . . . 8  |-  M  =  ( 1  +  K
)
2120oveq1i 5884 . . . . . . 7  |-  ( M  +  1 )  =  ( ( 1  +  K )  +  1 )
221, 21eqtri 2316 . . . . . 6  |-  N  =  ( ( 1  +  K )  +  1 )
23 df-2 9820 . . . . . . . 8  |-  2  =  ( 1  +  1 )
2423oveq1i 5884 . . . . . . 7  |-  ( 2  +  K )  =  ( ( 1  +  1 )  +  K
)
2518, 17, 18add32i 9046 . . . . . . 7  |-  ( ( 1  +  K )  +  1 )  =  ( ( 1  +  1 )  +  K
)
2624, 25eqtr4i 2319 . . . . . 6  |-  ( 2  +  K )  =  ( ( 1  +  K )  +  1 )
2722, 26eqtr4i 2319 . . . . 5  |-  N  =  ( 2  +  K
)
2827oveq1i 5884 . . . 4  |-  ( N  +  1 )  =  ( ( 2  +  K )  +  1 )
29 2cn 9832 . . . . 5  |-  2  e.  CC
3029, 17, 18addassi 8861 . . . 4  |-  ( ( 2  +  K )  +  1 )  =  ( 2  +  ( K  +  1 ) )
3128, 30eqtri 2316 . . 3  |-  ( N  +  1 )  =  ( 2  +  ( K  +  1 ) )
3215, 31breqtrri 4064 . 2  |-  2  ||  ( N  +  1 )
33 elfzuz2 10817 . . . . 5  |-  ( ( A  mod  8 )  e.  ( 0 ... N )  ->  N  e.  ( ZZ>= `  0 )
)
34 fzm1 10878 . . . . 5  |-  ( N  e.  ( ZZ>= `  0
)  ->  ( ( A  mod  8 )  e.  ( 0 ... N
)  <->  ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  \/  ( A  mod  8 )  =  N ) ) )
3533, 34syl 15 . . . 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 232 . . 3  |-  ( ( A  mod  8 )  e.  ( 0 ... N )  ->  (
( A  mod  8
)  e.  ( 0 ... ( N  - 
1 ) )  \/  ( A  mod  8
)  =  N ) )
37 elfzuz2 10817 . . . . . . . 8  |-  ( ( A  mod  8 )  e.  ( 0 ... M )  ->  M  e.  ( ZZ>= `  0 )
)
38 fzm1 10878 . . . . . . . 8  |-  ( M  e.  ( ZZ>= `  0
)  ->  ( ( A  mod  8 )  e.  ( 0 ... M
)  <->  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  \/  ( A  mod  8 )  =  M ) ) )
3937, 38syl 15 . . . . . . 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 232 . . . . . 6  |-  ( ( A  mod  8 )  e.  ( 0 ... M )  ->  (
( A  mod  8
)  e.  ( 0 ... ( M  - 
1 ) )  \/  ( A  mod  8
)  =  M ) )
41 zcn 10045 . . . . . . . . 9  |-  ( N  e.  ZZ  ->  N  e.  CC )
4210, 41ax-mp 8 . . . . . . . 8  |-  N  e.  CC
43 zcn 10045 . . . . . . . . 9  |-  ( M  e.  ZZ  ->  M  e.  CC )
447, 43ax-mp 8 . . . . . . . 8  |-  M  e.  CC
4518, 44addcomi 9019 . . . . . . . . 9  |-  ( 1  +  M )  =  ( M  +  1 )
4645, 1eqtr4i 2319 . . . . . . . 8  |-  ( 1  +  M )  =  N
4742, 18, 44, 46subaddrii 9151 . . . . . . 7  |-  ( N  -  1 )  =  M
4847oveq2i 5885 . . . . . 6  |-  ( 0 ... ( N  - 
1 ) )  =  ( 0 ... M
)
4940, 48eleq2s 2388 . . . . 5  |-  ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  ->  (
( A  mod  8
)  e.  ( 0 ... ( M  - 
1 ) )  \/  ( A  mod  8
)  =  M ) )
5020eqcomi 2300 . . . . . . . . . 10  |-  ( 1  +  K )  =  M
5144, 18, 17, 50subaddrii 9151 . . . . . . . . 9  |-  ( M  -  1 )  =  K
5251oveq2i 5885 . . . . . . . 8  |-  ( 0 ... ( M  - 
1 ) )  =  ( 0 ... K
)
5352eleq2i 2360 . . . . . . 7  |-  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  <->  ( A  mod  8 )  e.  ( 0 ... K ) )
543simp3i 966 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... K
)  ->  ( A  mod  8 )  e.  S
) )
5553, 54syl5bi 208 . . . . . 6  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  ->  ( A  mod  8 )  e.  S
) )
56 2nn 9893 . . . . . . . . . . 11  |-  2  e.  NN
57 8nn 9899 . . . . . . . . . . 11  |-  8  e.  NN
58 4nn 9895 . . . . . . . . . . . . . . 15  |-  4  e.  NN
5958nnzi 10063 . . . . . . . . . . . . . 14  |-  4  e.  ZZ
60 dvdsmul2 12567 . . . . . . . . . . . . . 14  |-  ( ( 4  e.  ZZ  /\  2  e.  ZZ )  ->  2  ||  ( 4  x.  2 ) )
6159, 12, 60mp2an 653 . . . . . . . . . . . . 13  |-  2  ||  ( 4  x.  2 )
62 4t2e8 9890 . . . . . . . . . . . . 13  |-  ( 4  x.  2 )  =  8
6361, 62breqtri 4062 . . . . . . . . . . . 12  |-  2  ||  8
64 dvdsmod 12601 . . . . . . . . . . . 12  |-  ( ( ( 2  e.  NN  /\  8  e.  NN  /\  A  e.  ZZ )  /\  2  ||  8 )  ->  ( 2  ||  ( A  mod  8
)  <->  2  ||  A
) )
6563, 64mpan2 652 . . . . . . . . . . 11  |-  ( ( 2  e.  NN  /\  8  e.  NN  /\  A  e.  ZZ )  ->  (
2  ||  ( A  mod  8 )  <->  2  ||  A ) )
6656, 57, 65mp3an12 1267 . . . . . . . . . 10  |-  ( A  e.  ZZ  ->  (
2  ||  ( A  mod  8 )  <->  2  ||  A ) )
6766notbid 285 . . . . . . . . 9  |-  ( A  e.  ZZ  ->  ( -.  2  ||  ( A  mod  8 )  <->  -.  2  ||  A ) )
6867biimpar 471 . . . . . . . 8  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  -.  2  ||  ( A  mod  8
) )
6911, 2breqtrri 4064 . . . . . . . . 9  |-  2  ||  M
70 id 19 . . . . . . . . 9  |-  ( ( A  mod  8 )  =  M  ->  ( A  mod  8 )  =  M )
7169, 70syl5breqr 4075 . . . . . . . 8  |-  ( ( A  mod  8 )  =  M  ->  2  ||  ( A  mod  8
) )
7268, 71nsyl 113 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  -.  ( A  mod  8 )  =  M )
7372pm2.21d 98 . . . . . 6  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  =  M  ->  ( A  mod  8 )  e.  S
) )
7455, 73jaod 369 . . . . 5  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( ( A  mod  8 )  e.  ( 0 ... ( M  -  1 ) )  \/  ( A  mod  8 )  =  M )  ->  ( A  mod  8 )  e.  S ) )
7549, 74syl5 28 . . . 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 2356 . . . . . 6  |-  ( ( A  mod  8 )  =  N  ->  (
( A  mod  8
)  e.  S  <->  N  e.  S ) )
7876, 77mpbiri 224 . . . . 5  |-  ( ( A  mod  8 )  =  N  ->  ( A  mod  8 )  e.  S )
7978a1i 10 . . . 4  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  =  N  ->  ( A  mod  8 )  e.  S
) )
8075, 79jaod 369 . . 3  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( ( A  mod  8 )  e.  ( 0 ... ( N  -  1 ) )  \/  ( A  mod  8 )  =  N )  ->  ( A  mod  8 )  e.  S ) )
8136, 80syl5 28 . 2  |-  ( ( A  e.  ZZ  /\  -.  2  ||  A )  ->  ( ( A  mod  8 )  e.  ( 0 ... N
)  ->  ( A  mod  8 )  e.  S
) )
8210, 32, 813pm3.2i 1130 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 176    \/ wo 357    /\ wa 358    /\ w3a 934    = wceq 1632    e. wcel 1696   class class class wbr 4039   ` cfv 5271  (class class class)co 5874   CCcc 8751   0cc0 8753   1c1 8754    + caddc 8756    x. cmul 8758    - cmin 9053   NNcn 9762   2c2 9811   4c4 9813   8c8 9817   ZZcz 10040   ZZ>=cuz 10246   ...cfz 10798    mod cmo 10989    || cdivides 12547
This theorem is referenced by:  lgsdir2lem3  20580
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-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-er 6676  df-en 6880  df-dom 6881  df-sdom 6882  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-n0 9982  df-z 10041  df-uz 10247  df-rp 10371  df-fz 10799  df-fl 10941  df-mod 10990  df-dvds 12548
  Copyright terms: Public domain W3C validator