Metamath Proof Explorer


Theorem dvdsnegb

Description: An integer divides another iff it divides its negation. (Contributed by Paul Chapman, 21-Mar-2011)

Ref Expression
Assertion dvdsnegb M N M N M -N

Proof

Step Hyp Ref Expression
1 id M N M N
2 znegcl N N
3 2 anim2i M N M N
4 znegcl x x
5 4 adantl M N x x
6 zcn x x
7 zcn M M
8 mulneg1 x M x M = x M
9 negeq x M = N x M = N
10 9 eqeq2d x M = N x M = x M x M = N
11 8 10 syl5ibcom x M x M = N x M = N
12 6 7 11 syl2anr M x x M = N x M = N
13 12 adantlr M N x x M = N x M = N
14 1 3 5 13 dvds1lem M N M N M -N
15 zcn N N
16 negeq x M = N x M = -N
17 negneg N -N = N
18 16 17 sylan9eqr N x M = N x M = N
19 8 18 sylan9eq x M N x M = N x M = N
20 19 expr x M N x M = N x M = N
21 20 3impa x M N x M = N x M = N
22 6 7 15 21 syl3an x M N x M = N x M = N
23 22 3coml M N x x M = N x M = N
24 23 3expa M N x x M = N x M = N
25 3 1 5 24 dvds1lem M N M -N M N
26 14 25 impbid M N M N M -N