ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  dvdsabseq Unicode version

Theorem dvdsabseq 11785
Description: If two integers divide each other, they must be equal, up to a difference in sign. Theorem 1.1(j) in [ApostolNT] p. 14. (Contributed by Mario Carneiro, 30-May-2014.) (Revised by AV, 7-Aug-2021.)
Assertion
Ref Expression
dvdsabseq  |-  ( ( M  ||  N  /\  N  ||  M )  -> 
( abs `  M
)  =  ( abs `  N ) )

Proof of Theorem dvdsabseq
StepHypRef Expression
1 dvdszrcl 11732 . . 3  |-  ( M 
||  N  ->  ( M  e.  ZZ  /\  N  e.  ZZ ) )
2 simpr 109 . . . . . . 7  |-  ( ( M  ||  N  /\  N  ||  M )  ->  N  ||  M )
3 breq1 3985 . . . . . . . . 9  |-  ( N  =  0  ->  ( N  ||  M  <->  0  ||  M ) )
4 0dvds 11751 . . . . . . . . . . 11  |-  ( M  e.  ZZ  ->  (
0  ||  M  <->  M  = 
0 ) )
54adantr 274 . . . . . . . . . 10  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( 0  ||  M  <->  M  =  0 ) )
6 zcn 9196 . . . . . . . . . . . . 13  |-  ( M  e.  ZZ  ->  M  e.  CC )
76abs00ad 11007 . . . . . . . . . . . 12  |-  ( M  e.  ZZ  ->  (
( abs `  M
)  =  0  <->  M  =  0 ) )
87bicomd 140 . . . . . . . . . . 11  |-  ( M  e.  ZZ  ->  ( M  =  0  <->  ( abs `  M )  =  0 ) )
98adantr 274 . . . . . . . . . 10  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( M  =  0  <-> 
( abs `  M
)  =  0 ) )
105, 9bitrd 187 . . . . . . . . 9  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( 0  ||  M  <->  ( abs `  M )  =  0 ) )
113, 10sylan9bb 458 . . . . . . . 8  |-  ( ( N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( N  ||  M  <->  ( abs `  M
)  =  0 ) )
12 fveq2 5486 . . . . . . . . . . 11  |-  ( N  =  0  ->  ( abs `  N )  =  ( abs `  0
) )
13 abs0 11000 . . . . . . . . . . 11  |-  ( abs `  0 )  =  0
1412, 13eqtrdi 2215 . . . . . . . . . 10  |-  ( N  =  0  ->  ( abs `  N )  =  0 )
1514adantr 274 . . . . . . . . 9  |-  ( ( N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( abs `  N )  =  0 )
1615eqeq2d 2177 . . . . . . . 8  |-  ( ( N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( ( abs `  M )  =  ( abs `  N
)  <->  ( abs `  M
)  =  0 ) )
1711, 16bitr4d 190 . . . . . . 7  |-  ( ( N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( N  ||  M  <->  ( abs `  M
)  =  ( abs `  N ) ) )
182, 17syl5ib 153 . . . . . 6  |-  ( ( N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( ( M  ||  N  /\  N  ||  M )  ->  ( abs `  M )  =  ( abs `  N
) ) )
1918expd 256 . . . . 5  |-  ( ( N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( abs `  M )  =  ( abs `  N ) ) ) )
2019expcom 115 . . . 4  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( N  =  0  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( abs `  M
)  =  ( abs `  N ) ) ) ) )
21 simprl 521 . . . . . . 7  |-  ( ( -.  N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  M  e.  ZZ )
22 simpr 109 . . . . . . . 8  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  N  e.  ZZ )
2322adantl 275 . . . . . . 7  |-  ( ( -.  N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  N  e.  ZZ )
24 neqne 2344 . . . . . . . 8  |-  ( -.  N  =  0  ->  N  =/=  0 )
2524adantr 274 . . . . . . 7  |-  ( ( -.  N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  N  =/=  0 )
26 dvdsleabs2 11784 . . . . . . 7  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ  /\  N  =/=  0 )  ->  ( M  ||  N  ->  ( abs `  M )  <_ 
( abs `  N
) ) )
2721, 23, 25, 26syl3anc 1228 . . . . . 6  |-  ( ( -.  N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( M  ||  N  ->  ( abs `  M
)  <_  ( abs `  N ) ) )
28 simpr 109 . . . . . . . . . . . . 13  |-  ( ( N  ||  M  /\  M  ||  N )  ->  M  ||  N )
29 breq1 3985 . . . . . . . . . . . . . . 15  |-  ( M  =  0  ->  ( M  ||  N  <->  0  ||  N ) )
30 0dvds 11751 . . . . . . . . . . . . . . . . 17  |-  ( N  e.  ZZ  ->  (
0  ||  N  <->  N  = 
0 ) )
31 zcn 9196 . . . . . . . . . . . . . . . . . . 19  |-  ( N  e.  ZZ  ->  N  e.  CC )
3231abs00ad 11007 . . . . . . . . . . . . . . . . . 18  |-  ( N  e.  ZZ  ->  (
( abs `  N
)  =  0  <->  N  =  0 ) )
33 eqcom 2167 . . . . . . . . . . . . . . . . . 18  |-  ( ( abs `  N )  =  0  <->  0  =  ( abs `  N ) )
3432, 33bitr3di 194 . . . . . . . . . . . . . . . . 17  |-  ( N  e.  ZZ  ->  ( N  =  0  <->  0  =  ( abs `  N ) ) )
3530, 34bitrd 187 . . . . . . . . . . . . . . . 16  |-  ( N  e.  ZZ  ->  (
0  ||  N  <->  0  =  ( abs `  N ) ) )
3635adantl 275 . . . . . . . . . . . . . . 15  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( 0  ||  N  <->  0  =  ( abs `  N
) ) )
3729, 36sylan9bb 458 . . . . . . . . . . . . . 14  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( M  ||  N  <->  0  =  ( abs `  N ) ) )
38 fveq2 5486 . . . . . . . . . . . . . . . . 17  |-  ( M  =  0  ->  ( abs `  M )  =  ( abs `  0
) )
3938, 13eqtrdi 2215 . . . . . . . . . . . . . . . 16  |-  ( M  =  0  ->  ( abs `  M )  =  0 )
4039adantr 274 . . . . . . . . . . . . . . 15  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( abs `  M )  =  0 )
4140eqeq1d 2174 . . . . . . . . . . . . . 14  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( ( abs `  M )  =  ( abs `  N
)  <->  0  =  ( abs `  N ) ) )
4237, 41bitr4d 190 . . . . . . . . . . . . 13  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( M  ||  N  <->  ( abs `  M
)  =  ( abs `  N ) ) )
4328, 42syl5ib 153 . . . . . . . . . . . 12  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( ( N  ||  M  /\  M  ||  N )  ->  ( abs `  M )  =  ( abs `  N
) ) )
4443a1dd 48 . . . . . . . . . . 11  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( ( N  ||  M  /\  M  ||  N )  ->  (
( abs `  M
)  <_  ( abs `  N )  ->  ( abs `  M )  =  ( abs `  N
) ) ) )
4544expcomd 1429 . . . . . . . . . 10  |-  ( ( M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( ( abs `  M )  <_ 
( abs `  N
)  ->  ( abs `  M )  =  ( abs `  N ) ) ) ) )
4645expcom 115 . . . . . . . . 9  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( M  =  0  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( ( abs `  M )  <_  ( abs `  N )  -> 
( abs `  M
)  =  ( abs `  N ) ) ) ) ) )
4722adantl 275 . . . . . . . . . . . . 13  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  N  e.  ZZ )
48 simprl 521 . . . . . . . . . . . . 13  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  M  e.  ZZ )
49 neqne 2344 . . . . . . . . . . . . . 14  |-  ( -.  M  =  0  ->  M  =/=  0 )
5049adantr 274 . . . . . . . . . . . . 13  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  ->  M  =/=  0 )
51 dvdsleabs2 11784 . . . . . . . . . . . . 13  |-  ( ( N  e.  ZZ  /\  M  e.  ZZ  /\  M  =/=  0 )  ->  ( N  ||  M  ->  ( abs `  N )  <_ 
( abs `  M
) ) )
5247, 48, 50, 51syl3anc 1228 . . . . . . . . . . . 12  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( N  ||  M  ->  ( abs `  N
)  <_  ( abs `  M ) ) )
53 eqcom 2167 . . . . . . . . . . . . . . . 16  |-  ( ( abs `  M )  =  ( abs `  N
)  <->  ( abs `  N
)  =  ( abs `  M ) )
5431abscld 11123 . . . . . . . . . . . . . . . . 17  |-  ( N  e.  ZZ  ->  ( abs `  N )  e.  RR )
556abscld 11123 . . . . . . . . . . . . . . . . 17  |-  ( M  e.  ZZ  ->  ( abs `  M )  e.  RR )
56 letri3 7979 . . . . . . . . . . . . . . . . 17  |-  ( ( ( abs `  N
)  e.  RR  /\  ( abs `  M )  e.  RR )  -> 
( ( abs `  N
)  =  ( abs `  M )  <->  ( ( abs `  N )  <_ 
( abs `  M
)  /\  ( abs `  M )  <_  ( abs `  N ) ) ) )
5754, 55, 56syl2anr 288 . . . . . . . . . . . . . . . 16  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( abs `  N
)  =  ( abs `  M )  <->  ( ( abs `  N )  <_ 
( abs `  M
)  /\  ( abs `  M )  <_  ( abs `  N ) ) ) )
5853, 57syl5bb 191 . . . . . . . . . . . . . . 15  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( abs `  M
)  =  ( abs `  N )  <->  ( ( abs `  N )  <_ 
( abs `  M
)  /\  ( abs `  M )  <_  ( abs `  N ) ) ) )
5958biimprd 157 . . . . . . . . . . . . . 14  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( ( abs `  N )  <_  ( abs `  M )  /\  ( abs `  M )  <_  ( abs `  N
) )  ->  ( abs `  M )  =  ( abs `  N
) ) )
6059expd 256 . . . . . . . . . . . . 13  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( abs `  N
)  <_  ( abs `  M )  ->  (
( abs `  M
)  <_  ( abs `  N )  ->  ( abs `  M )  =  ( abs `  N
) ) ) )
6160adantl 275 . . . . . . . . . . . 12  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( ( abs `  N
)  <_  ( abs `  M )  ->  (
( abs `  M
)  <_  ( abs `  N )  ->  ( abs `  M )  =  ( abs `  N
) ) ) )
6252, 61syld 45 . . . . . . . . . . 11  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( N  ||  M  ->  ( ( abs `  M
)  <_  ( abs `  N )  ->  ( abs `  M )  =  ( abs `  N
) ) ) )
6362a1d 22 . . . . . . . . . 10  |-  ( ( -.  M  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( M  ||  N  ->  ( N  ||  M  ->  ( ( abs `  M
)  <_  ( abs `  N )  ->  ( abs `  M )  =  ( abs `  N
) ) ) ) )
6463expcom 115 . . . . . . . . 9  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( -.  M  =  0  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( ( abs `  M )  <_ 
( abs `  N
)  ->  ( abs `  M )  =  ( abs `  N ) ) ) ) ) )
65 0z 9202 . . . . . . . . . . . 12  |-  0  e.  ZZ
66 zdceq 9266 . . . . . . . . . . . 12  |-  ( ( M  e.  ZZ  /\  0  e.  ZZ )  -> DECID  M  =  0 )
6765, 66mpan2 422 . . . . . . . . . . 11  |-  ( M  e.  ZZ  -> DECID  M  =  0
)
68 exmiddc 826 . . . . . . . . . . 11  |-  (DECID  M  =  0  ->  ( M  =  0  \/  -.  M  =  0 ) )
6967, 68syl 14 . . . . . . . . . 10  |-  ( M  e.  ZZ  ->  ( M  =  0  \/  -.  M  =  0
) )
7069adantr 274 . . . . . . . . 9  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( M  =  0  \/  -.  M  =  0 ) )
7146, 64, 70mpjaod 708 . . . . . . . 8  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( ( abs `  M
)  <_  ( abs `  N )  ->  ( abs `  M )  =  ( abs `  N
) ) ) ) )
7271com34 83 . . . . . . 7  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( M  ||  N  ->  ( ( abs `  M
)  <_  ( abs `  N )  ->  ( N  ||  M  ->  ( abs `  M )  =  ( abs `  N
) ) ) ) )
7372adantl 275 . . . . . 6  |-  ( ( -.  N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( M  ||  N  ->  ( ( abs `  M
)  <_  ( abs `  N )  ->  ( N  ||  M  ->  ( abs `  M )  =  ( abs `  N
) ) ) ) )
7427, 73mpdd 41 . . . . 5  |-  ( ( -.  N  =  0  /\  ( M  e.  ZZ  /\  N  e.  ZZ ) )  -> 
( M  ||  N  ->  ( N  ||  M  ->  ( abs `  M
)  =  ( abs `  N ) ) ) )
7574expcom 115 . . . 4  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( -.  N  =  0  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( abs `  M )  =  ( abs `  N ) ) ) ) )
76 zdceq 9266 . . . . . . 7  |-  ( ( N  e.  ZZ  /\  0  e.  ZZ )  -> DECID  N  =  0 )
7765, 76mpan2 422 . . . . . 6  |-  ( N  e.  ZZ  -> DECID  N  =  0
)
78 exmiddc 826 . . . . . 6  |-  (DECID  N  =  0  ->  ( N  =  0  \/  -.  N  =  0 ) )
7977, 78syl 14 . . . . 5  |-  ( N  e.  ZZ  ->  ( N  =  0  \/  -.  N  =  0
) )
8079adantl 275 . . . 4  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( N  =  0  \/  -.  N  =  0 ) )
8120, 75, 80mpjaod 708 . . 3  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( M  ||  N  ->  ( N  ||  M  ->  ( abs `  M
)  =  ( abs `  N ) ) ) )
821, 81mpcom 36 . 2  |-  ( M 
||  N  ->  ( N  ||  M  ->  ( abs `  M )  =  ( abs `  N
) ) )
8382imp 123 1  |-  ( ( M  ||  N  /\  N  ||  M )  -> 
( abs `  M
)  =  ( abs `  N ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    /\ wa 103    <-> wb 104    \/ wo 698  DECID wdc 824    = wceq 1343    e. wcel 2136    =/= wne 2336   class class class wbr 3982   ` cfv 5188   RRcr 7752   0cc0 7753    <_ cle 7934   ZZcz 9191   abscabs 10939    || cdvds 11727
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 105  ax-ia2 106  ax-ia3 107  ax-in1 604  ax-in2 605  ax-io 699  ax-5 1435  ax-7 1436  ax-gen 1437  ax-ie1 1481  ax-ie2 1482  ax-8 1492  ax-10 1493  ax-11 1494  ax-i12 1495  ax-bndl 1497  ax-4 1498  ax-17 1514  ax-i9 1518  ax-ial 1522  ax-i5r 1523  ax-13 2138  ax-14 2139  ax-ext 2147  ax-coll 4097  ax-sep 4100  ax-nul 4108  ax-pow 4153  ax-pr 4187  ax-un 4411  ax-setind 4514  ax-iinf 4565  ax-cnex 7844  ax-resscn 7845  ax-1cn 7846  ax-1re 7847  ax-icn 7848  ax-addcl 7849  ax-addrcl 7850  ax-mulcl 7851  ax-mulrcl 7852  ax-addcom 7853  ax-mulcom 7854  ax-addass 7855  ax-mulass 7856  ax-distr 7857  ax-i2m1 7858  ax-0lt1 7859  ax-1rid 7860  ax-0id 7861  ax-rnegex 7862  ax-precex 7863  ax-cnre 7864  ax-pre-ltirr 7865  ax-pre-ltwlin 7866  ax-pre-lttrn 7867  ax-pre-apti 7868  ax-pre-ltadd 7869  ax-pre-mulgt0 7870  ax-pre-mulext 7871  ax-arch 7872  ax-caucvg 7873
This theorem depends on definitions:  df-bi 116  df-dc 825  df-3or 969  df-3an 970  df-tru 1346  df-fal 1349  df-nf 1449  df-sb 1751  df-eu 2017  df-mo 2018  df-clab 2152  df-cleq 2158  df-clel 2161  df-nfc 2297  df-ne 2337  df-nel 2432  df-ral 2449  df-rex 2450  df-reu 2451  df-rmo 2452  df-rab 2453  df-v 2728  df-sbc 2952  df-csb 3046  df-dif 3118  df-un 3120  df-in 3122  df-ss 3129  df-nul 3410  df-if 3521  df-pw 3561  df-sn 3582  df-pr 3583  df-op 3585  df-uni 3790  df-int 3825  df-iun 3868  df-br 3983  df-opab 4044  df-mpt 4045  df-tr 4081  df-id 4271  df-po 4274  df-iso 4275  df-iord 4344  df-on 4346  df-ilim 4347  df-suc 4349  df-iom 4568  df-xp 4610  df-rel 4611  df-cnv 4612  df-co 4613  df-dm 4614  df-rn 4615  df-res 4616  df-ima 4617  df-iota 5153  df-fun 5190  df-fn 5191  df-f 5192  df-f1 5193  df-fo 5194  df-f1o 5195  df-fv 5196  df-riota 5798  df-ov 5845  df-oprab 5846  df-mpo 5847  df-1st 6108  df-2nd 6109  df-recs 6273  df-frec 6359  df-pnf 7935  df-mnf 7936  df-xr 7937  df-ltxr 7938  df-le 7939  df-sub 8071  df-neg 8072  df-reap 8473  df-ap 8480  df-div 8569  df-inn 8858  df-2 8916  df-3 8917  df-4 8918  df-n0 9115  df-z 9192  df-uz 9467  df-q 9558  df-rp 9590  df-seqfrec 10381  df-exp 10455  df-cj 10784  df-re 10785  df-im 10786  df-rsqrt 10940  df-abs 10941  df-dvds 11728
This theorem is referenced by:  dvdseq  11786
  Copyright terms: Public domain W3C validator