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

Theorem omeo 13880
Description: The difference of an odd and an even is odd. (Contributed by Scott Fenton, 7-Apr-2014.) (Revised by Mario Carneiro, 19-Apr-2014.)
Assertion
Ref Expression
omeo  |-  ( ( ( A  e.  ZZ  /\ 
-.  2  ||  A
)  /\  ( B  e.  ZZ  /\  2  ||  B ) )  ->  -.  2  ||  ( A  -  B ) )

Proof of Theorem omeo
Dummy variables  a 
b  c are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 odd2np1 13591 . . . . . 6  |-  ( A  e.  ZZ  ->  ( -.  2  ||  A  <->  E. a  e.  ZZ  ( ( 2  x.  a )  +  1 )  =  A ) )
2 2z 10677 . . . . . . 7  |-  2  e.  ZZ
3 divides 13536 . . . . . . 7  |-  ( ( 2  e.  ZZ  /\  B  e.  ZZ )  ->  ( 2  ||  B  <->  E. b  e.  ZZ  (
b  x.  2 )  =  B ) )
42, 3mpan 670 . . . . . 6  |-  ( B  e.  ZZ  ->  (
2  ||  B  <->  E. b  e.  ZZ  ( b  x.  2 )  =  B ) )
51, 4bi2anan9 868 . . . . 5  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ )  ->  ( ( -.  2  ||  A  /\  2  ||  B )  <->  ( E. a  e.  ZZ  (
( 2  x.  a
)  +  1 )  =  A  /\  E. b  e.  ZZ  (
b  x.  2 )  =  B ) ) )
6 reeanv 2887 . . . . . 6  |-  ( E. a  e.  ZZ  E. b  e.  ZZ  (
( ( 2  x.  a )  +  1 )  =  A  /\  ( b  x.  2 )  =  B )  <-> 
( E. a  e.  ZZ  ( ( 2  x.  a )  +  1 )  =  A  /\  E. b  e.  ZZ  ( b  x.  2 )  =  B ) )
7 zsubcl 10686 . . . . . . . . 9  |-  ( ( a  e.  ZZ  /\  b  e.  ZZ )  ->  ( a  -  b
)  e.  ZZ )
8 zcn 10650 . . . . . . . . . 10  |-  ( a  e.  ZZ  ->  a  e.  CC )
9 zcn 10650 . . . . . . . . . 10  |-  ( b  e.  ZZ  ->  b  e.  CC )
10 2cn 10391 . . . . . . . . . . . . 13  |-  2  e.  CC
11 subdi 9777 . . . . . . . . . . . . 13  |-  ( ( 2  e.  CC  /\  a  e.  CC  /\  b  e.  CC )  ->  (
2  x.  ( a  -  b ) )  =  ( ( 2  x.  a )  -  ( 2  x.  b
) ) )
1210, 11mp3an1 1301 . . . . . . . . . . . 12  |-  ( ( a  e.  CC  /\  b  e.  CC )  ->  ( 2  x.  (
a  -  b ) )  =  ( ( 2  x.  a )  -  ( 2  x.  b ) ) )
1312oveq1d 6105 . . . . . . . . . . 11  |-  ( ( a  e.  CC  /\  b  e.  CC )  ->  ( ( 2  x.  ( a  -  b
) )  +  1 )  =  ( ( ( 2  x.  a
)  -  ( 2  x.  b ) )  +  1 ) )
14 mulcl 9365 . . . . . . . . . . . . 13  |-  ( ( 2  e.  CC  /\  a  e.  CC )  ->  ( 2  x.  a
)  e.  CC )
1510, 14mpan 670 . . . . . . . . . . . 12  |-  ( a  e.  CC  ->  (
2  x.  a )  e.  CC )
16 mulcl 9365 . . . . . . . . . . . . 13  |-  ( ( 2  e.  CC  /\  b  e.  CC )  ->  ( 2  x.  b
)  e.  CC )
1710, 16mpan 670 . . . . . . . . . . . 12  |-  ( b  e.  CC  ->  (
2  x.  b )  e.  CC )
18 ax-1cn 9339 . . . . . . . . . . . . 13  |-  1  e.  CC
19 addsub 9620 . . . . . . . . . . . . 13  |-  ( ( ( 2  x.  a
)  e.  CC  /\  1  e.  CC  /\  (
2  x.  b )  e.  CC )  -> 
( ( ( 2  x.  a )  +  1 )  -  (
2  x.  b ) )  =  ( ( ( 2  x.  a
)  -  ( 2  x.  b ) )  +  1 ) )
2018, 19mp3an2 1302 . . . . . . . . . . . 12  |-  ( ( ( 2  x.  a
)  e.  CC  /\  ( 2  x.  b
)  e.  CC )  ->  ( ( ( 2  x.  a )  +  1 )  -  ( 2  x.  b
) )  =  ( ( ( 2  x.  a )  -  (
2  x.  b ) )  +  1 ) )
2115, 17, 20syl2an 477 . . . . . . . . . . 11  |-  ( ( a  e.  CC  /\  b  e.  CC )  ->  ( ( ( 2  x.  a )  +  1 )  -  (
2  x.  b ) )  =  ( ( ( 2  x.  a
)  -  ( 2  x.  b ) )  +  1 ) )
22 mulcom 9367 . . . . . . . . . . . . . 14  |-  ( ( 2  e.  CC  /\  b  e.  CC )  ->  ( 2  x.  b
)  =  ( b  x.  2 ) )
2310, 22mpan 670 . . . . . . . . . . . . 13  |-  ( b  e.  CC  ->  (
2  x.  b )  =  ( b  x.  2 ) )
2423oveq2d 6106 . . . . . . . . . . . 12  |-  ( b  e.  CC  ->  (
( ( 2  x.  a )  +  1 )  -  ( 2  x.  b ) )  =  ( ( ( 2  x.  a )  +  1 )  -  ( b  x.  2 ) ) )
2524adantl 466 . . . . . . . . . . 11  |-  ( ( a  e.  CC  /\  b  e.  CC )  ->  ( ( ( 2  x.  a )  +  1 )  -  (
2  x.  b ) )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) ) )
2613, 21, 253eqtr2d 2480 . . . . . . . . . 10  |-  ( ( a  e.  CC  /\  b  e.  CC )  ->  ( ( 2  x.  ( a  -  b
) )  +  1 )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) ) )
278, 9, 26syl2an 477 . . . . . . . . 9  |-  ( ( a  e.  ZZ  /\  b  e.  ZZ )  ->  ( ( 2  x.  ( a  -  b
) )  +  1 )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) ) )
28 oveq2 6098 . . . . . . . . . . . 12  |-  ( c  =  ( a  -  b )  ->  (
2  x.  c )  =  ( 2  x.  ( a  -  b
) ) )
2928oveq1d 6105 . . . . . . . . . . 11  |-  ( c  =  ( a  -  b )  ->  (
( 2  x.  c
)  +  1 )  =  ( ( 2  x.  ( a  -  b ) )  +  1 ) )
3029eqeq1d 2450 . . . . . . . . . 10  |-  ( c  =  ( a  -  b )  ->  (
( ( 2  x.  c )  +  1 )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) )  <->  ( (
2  x.  ( a  -  b ) )  +  1 )  =  ( ( ( 2  x.  a )  +  1 )  -  (
b  x.  2 ) ) ) )
3130rspcev 3072 . . . . . . . . 9  |-  ( ( ( a  -  b
)  e.  ZZ  /\  ( ( 2  x.  ( a  -  b
) )  +  1 )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) ) )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) ) )
327, 27, 31syl2anc 661 . . . . . . . 8  |-  ( ( a  e.  ZZ  /\  b  e.  ZZ )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( ( ( 2  x.  a
)  +  1 )  -  ( b  x.  2 ) ) )
33 oveq12 6099 . . . . . . . . . 10  |-  ( ( ( ( 2  x.  a )  +  1 )  =  A  /\  ( b  x.  2 )  =  B )  ->  ( ( ( 2  x.  a )  +  1 )  -  ( b  x.  2 ) )  =  ( A  -  B ) )
3433eqeq2d 2453 . . . . . . . . 9  |-  ( ( ( ( 2  x.  a )  +  1 )  =  A  /\  ( b  x.  2 )  =  B )  ->  ( ( ( 2  x.  c )  +  1 )  =  ( ( ( 2  x.  a )  +  1 )  -  (
b  x.  2 ) )  <->  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) ) )
3534rexbidv 2735 . . . . . . . 8  |-  ( ( ( ( 2  x.  a )  +  1 )  =  A  /\  ( b  x.  2 )  =  B )  ->  ( E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( ( ( 2  x.  a )  +  1 )  -  ( b  x.  2 ) )  <->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) ) )
3632, 35syl5ibcom 220 . . . . . . 7  |-  ( ( a  e.  ZZ  /\  b  e.  ZZ )  ->  ( ( ( ( 2  x.  a )  +  1 )  =  A  /\  ( b  x.  2 )  =  B )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) ) )
3736rexlimivv 2845 . . . . . 6  |-  ( E. a  e.  ZZ  E. b  e.  ZZ  (
( ( 2  x.  a )  +  1 )  =  A  /\  ( b  x.  2 )  =  B )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) )
386, 37sylbir 213 . . . . 5  |-  ( ( E. a  e.  ZZ  ( ( 2  x.  a )  +  1 )  =  A  /\  E. b  e.  ZZ  (
b  x.  2 )  =  B )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) )
395, 38syl6bi 228 . . . 4  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ )  ->  ( ( -.  2  ||  A  /\  2  ||  B )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) ) )
4039imp 429 . . 3  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ )  /\  ( -.  2  ||  A  /\  2  ||  B ) )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) )
4140an4s 822 . 2  |-  ( ( ( A  e.  ZZ  /\ 
-.  2  ||  A
)  /\  ( B  e.  ZZ  /\  2  ||  B ) )  ->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) )
42 zsubcl 10686 . . . 4  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ )  ->  ( A  -  B
)  e.  ZZ )
4342ad2ant2r 746 . . 3  |-  ( ( ( A  e.  ZZ  /\ 
-.  2  ||  A
)  /\  ( B  e.  ZZ  /\  2  ||  B ) )  -> 
( A  -  B
)  e.  ZZ )
44 odd2np1 13591 . . 3  |-  ( ( A  -  B )  e.  ZZ  ->  ( -.  2  ||  ( A  -  B )  <->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) ) )
4543, 44syl 16 . 2  |-  ( ( ( A  e.  ZZ  /\ 
-.  2  ||  A
)  /\  ( B  e.  ZZ  /\  2  ||  B ) )  -> 
( -.  2  ||  ( A  -  B
)  <->  E. c  e.  ZZ  ( ( 2  x.  c )  +  1 )  =  ( A  -  B ) ) )
4641, 45mpbird 232 1  |-  ( ( ( A  e.  ZZ  /\ 
-.  2  ||  A
)  /\  ( B  e.  ZZ  /\  2  ||  B ) )  ->  -.  2  ||  ( A  -  B ) )
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 184    /\ wa 369    = wceq 1369    e. wcel 1756   E.wrex 2715   class class class wbr 4291  (class class class)co 6090   CCcc 9279   1c1 9282    + caddc 9284    x. cmul 9286    - cmin 9594   2c2 10370   ZZcz 10645    || cdivides 13534
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1591  ax-4 1602  ax-5 1670  ax-6 1708  ax-7 1728  ax-8 1758  ax-9 1760  ax-10 1775  ax-11 1780  ax-12 1792  ax-13 1943  ax-ext 2423  ax-sep 4412  ax-nul 4420  ax-pow 4469  ax-pr 4530  ax-un 6371  ax-resscn 9338  ax-1cn 9339  ax-icn 9340  ax-addcl 9341  ax-addrcl 9342  ax-mulcl 9343  ax-mulrcl 9344  ax-mulcom 9345  ax-addass 9346  ax-mulass 9347  ax-distr 9348  ax-i2m1 9349  ax-1ne0 9350  ax-1rid 9351  ax-rnegex 9352  ax-rrecex 9353  ax-cnre 9354  ax-pre-lttri 9355  ax-pre-lttrn 9356  ax-pre-ltadd 9357  ax-pre-mulgt0 9358
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 966  df-3an 967  df-tru 1372  df-ex 1587  df-nf 1590  df-sb 1701  df-eu 2257  df-mo 2258  df-clab 2429  df-cleq 2435  df-clel 2438  df-nfc 2567  df-ne 2607  df-nel 2608  df-ral 2719  df-rex 2720  df-reu 2721  df-rmo 2722  df-rab 2723  df-v 2973  df-sbc 3186  df-csb 3288  df-dif 3330  df-un 3332  df-in 3334  df-ss 3341  df-pss 3343  df-nul 3637  df-if 3791  df-pw 3861  df-sn 3877  df-pr 3879  df-tp 3881  df-op 3883  df-uni 4091  df-iun 4172  df-br 4292  df-opab 4350  df-mpt 4351  df-tr 4385  df-eprel 4631  df-id 4635  df-po 4640  df-so 4641  df-fr 4678  df-we 4680  df-ord 4721  df-on 4722  df-lim 4723  df-suc 4724  df-xp 4845  df-rel 4846  df-cnv 4847  df-co 4848  df-dm 4849  df-rn 4850  df-res 4851  df-ima 4852  df-iota 5380  df-fun 5419  df-fn 5420  df-f 5421  df-f1 5422  df-fo 5423  df-f1o 5424  df-fv 5425  df-riota 6051  df-ov 6093  df-oprab 6094  df-mpt2 6095  df-om 6476  df-recs 6831  df-rdg 6865  df-er 7100  df-en 7310  df-dom 7311  df-sdom 7312  df-pnf 9419  df-mnf 9420  df-xr 9421  df-ltxr 9422  df-le 9423  df-sub 9596  df-neg 9597  df-div 9993  df-nn 10322  df-2 10379  df-n0 10579  df-z 10646  df-dvds 13535
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator