Metamath Proof Explorer


Theorem zneo

Description: No even integer equals an odd integer (i.e. no integer can be both even and odd). Exercise 10(a) of Apostol p. 28. (Contributed by NM, 31-Jul-2004) (Proof shortened by Mario Carneiro, 18-May-2014)

Ref Expression
Assertion zneo A B 2 A 2 B + 1

Proof

Step Hyp Ref Expression
1 halfnz ¬ 1 2
2 2cn 2
3 zcn A A
4 3 adantr A B A
5 mulcl 2 A 2 A
6 2 4 5 sylancr A B 2 A
7 zcn B B
8 7 adantl A B B
9 mulcl 2 B 2 B
10 2 8 9 sylancr A B 2 B
11 1cnd A B 1
12 6 10 11 subaddd A B 2 A 2 B = 1 2 B + 1 = 2 A
13 2 a1i A B 2
14 13 4 8 subdid A B 2 A B = 2 A 2 B
15 14 oveq1d A B 2 A B 2 = 2 A 2 B 2
16 zsubcl A B A B
17 zcn A B A B
18 16 17 syl A B A B
19 2ne0 2 0
20 19 a1i A B 2 0
21 18 13 20 divcan3d A B 2 A B 2 = A B
22 15 21 eqtr3d A B 2 A 2 B 2 = A B
23 22 16 eqeltrd A B 2 A 2 B 2
24 oveq1 2 A 2 B = 1 2 A 2 B 2 = 1 2
25 24 eleq1d 2 A 2 B = 1 2 A 2 B 2 1 2
26 23 25 syl5ibcom A B 2 A 2 B = 1 1 2
27 12 26 sylbird A B 2 B + 1 = 2 A 1 2
28 27 necon3bd A B ¬ 1 2 2 B + 1 2 A
29 1 28 mpi A B 2 B + 1 2 A
30 29 necomd A B 2 A 2 B + 1