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

Theorem dvdseq 12898
Description: If two integers divide each other, they must be equal, up to a difference in sign. (Contributed by Mario Carneiro, 30-May-2014.)
Assertion
Ref Expression
dvdseq  |-  ( ( ( M  e.  NN0  /\  N  e.  NN0 )  /\  ( M  ||  N  /\  N  ||  M ) )  ->  M  =  N )

Proof of Theorem dvdseq
StepHypRef Expression
1 elnn0 10224 . . 3  |-  ( N  e.  NN0  <->  ( N  e.  NN  \/  N  =  0 ) )
2 simprl 734 . . . . . . 7  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  M  ||  N )
3 nn0z 10305 . . . . . . . . 9  |-  ( M  e.  NN0  ->  M  e.  ZZ )
43ad2antrr 708 . . . . . . . 8  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  M  e.  ZZ )
5 simplr 733 . . . . . . . 8  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  N  e.  NN )
6 dvdsle 12896 . . . . . . . 8  |-  ( ( M  e.  ZZ  /\  N  e.  NN )  ->  ( M  ||  N  ->  M  <_  N )
)
74, 5, 6syl2anc 644 . . . . . . 7  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( M  ||  N  ->  M  <_  N ) )
82, 7mpd 15 . . . . . 6  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  M  <_  N )
9 simprr 735 . . . . . . 7  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  N  ||  M )
10 nnz 10304 . . . . . . . . 9  |-  ( N  e.  NN  ->  N  e.  ZZ )
1110ad2antlr 709 . . . . . . . 8  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  N  e.  ZZ )
12 nnne0 10033 . . . . . . . . . . 11  |-  ( N  e.  NN  ->  N  =/=  0 )
1312ad2antlr 709 . . . . . . . . . 10  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  N  =/=  0 )
14 breq1 4216 . . . . . . . . . . . . . 14  |-  ( M  =  0  ->  ( M  ||  N  <->  0  ||  N ) )
1514biimpcd 217 . . . . . . . . . . . . 13  |-  ( M 
||  N  ->  ( M  =  0  ->  0 
||  N ) )
1615ad2antrl 710 . . . . . . . . . . . 12  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( M  =  0  ->  0 
||  N ) )
17 0dvds 12871 . . . . . . . . . . . . 13  |-  ( N  e.  ZZ  ->  (
0  ||  N  <->  N  = 
0 ) )
1811, 17syl 16 . . . . . . . . . . . 12  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  (
0  ||  N  <->  N  = 
0 ) )
1916, 18sylibd 207 . . . . . . . . . . 11  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( M  =  0  ->  N  =  0 ) )
2019necon3ad 2638 . . . . . . . . . 10  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( N  =/=  0  ->  -.  M  =  0 ) )
2113, 20mpd 15 . . . . . . . . 9  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  -.  M  =  0 )
22 simpll 732 . . . . . . . . . . 11  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  M  e.  NN0 )
23 elnn0 10224 . . . . . . . . . . 11  |-  ( M  e.  NN0  <->  ( M  e.  NN  \/  M  =  0 ) )
2422, 23sylib 190 . . . . . . . . . 10  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( M  e.  NN  \/  M  =  0 ) )
2524ord 368 . . . . . . . . 9  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( -.  M  e.  NN  ->  M  =  0 ) )
2621, 25mt3d 120 . . . . . . . 8  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  M  e.  NN )
27 dvdsle 12896 . . . . . . . 8  |-  ( ( N  e.  ZZ  /\  M  e.  NN )  ->  ( N  ||  M  ->  N  <_  M )
)
2811, 26, 27syl2anc 644 . . . . . . 7  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( N  ||  M  ->  N  <_  M ) )
299, 28mpd 15 . . . . . 6  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  N  <_  M )
30 nn0re 10231 . . . . . . . 8  |-  ( M  e.  NN0  ->  M  e.  RR )
31 nnre 10008 . . . . . . . 8  |-  ( N  e.  NN  ->  N  e.  RR )
32 letri3 9161 . . . . . . . 8  |-  ( ( M  e.  RR  /\  N  e.  RR )  ->  ( M  =  N  <-> 
( M  <_  N  /\  N  <_  M ) ) )
3330, 31, 32syl2an 465 . . . . . . 7  |-  ( ( M  e.  NN0  /\  N  e.  NN )  ->  ( M  =  N  <-> 
( M  <_  N  /\  N  <_  M ) ) )
3433adantr 453 . . . . . 6  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  ( M  =  N  <->  ( M  <_  N  /\  N  <_  M ) ) )
358, 29, 34mpbir2and 890 . . . . 5  |-  ( ( ( M  e.  NN0  /\  N  e.  NN )  /\  ( M  ||  N  /\  N  ||  M
) )  ->  M  =  N )
3635ex 425 . . . 4  |-  ( ( M  e.  NN0  /\  N  e.  NN )  ->  ( ( M  ||  N  /\  N  ||  M
)  ->  M  =  N ) )
37 simpr 449 . . . . 5  |-  ( ( M  ||  N  /\  N  ||  M )  ->  N  ||  M )
38 breq1 4216 . . . . . . 7  |-  ( N  =  0  ->  ( N  ||  M  <->  0  ||  M ) )
39 0dvds 12871 . . . . . . . 8  |-  ( M  e.  ZZ  ->  (
0  ||  M  <->  M  = 
0 ) )
403, 39syl 16 . . . . . . 7  |-  ( M  e.  NN0  ->  ( 0 
||  M  <->  M  = 
0 ) )
4138, 40sylan9bbr 683 . . . . . 6  |-  ( ( M  e.  NN0  /\  N  =  0 )  ->  ( N  ||  M 
<->  M  =  0 ) )
42 simpr 449 . . . . . . 7  |-  ( ( M  e.  NN0  /\  N  =  0 )  ->  N  =  0 )
4342eqeq2d 2448 . . . . . 6  |-  ( ( M  e.  NN0  /\  N  =  0 )  ->  ( M  =  N  <->  M  =  0
) )
4441, 43bitr4d 249 . . . . 5  |-  ( ( M  e.  NN0  /\  N  =  0 )  ->  ( N  ||  M 
<->  M  =  N ) )
4537, 44syl5ib 212 . . . 4  |-  ( ( M  e.  NN0  /\  N  =  0 )  ->  ( ( M 
||  N  /\  N  ||  M )  ->  M  =  N ) )
4636, 45jaodan 762 . . 3  |-  ( ( M  e.  NN0  /\  ( N  e.  NN  \/  N  =  0
) )  ->  (
( M  ||  N  /\  N  ||  M )  ->  M  =  N ) )
471, 46sylan2b 463 . 2  |-  ( ( M  e.  NN0  /\  N  e.  NN0 )  -> 
( ( M  ||  N  /\  N  ||  M
)  ->  M  =  N ) )
4847imp 420 1  |-  ( ( ( M  e.  NN0  /\  N  e.  NN0 )  /\  ( M  ||  N  /\  N  ||  M ) )  ->  M  =  N )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 178    \/ wo 359    /\ wa 360    = wceq 1653    e. wcel 1726    =/= wne 2600   class class class wbr 4213   RRcr 8990   0cc0 8991    <_ cle 9122   NNcn 10001   NN0cn0 10222   ZZcz 10283    || cdivides 12853
This theorem is referenced by:  dvds1  12899  dvdsext  12901  mulgcd  13047  rpmulgcd2  13106  isprm6  13110  pc11  13254  pcprmpw2  13256  odeq  15189  odadd  15466  gexexlem  15468  lt6abl  15505  cyggex2  15507  ablfacrp2  15626  ablfac1c  15630  ablfac1eu  15632  znidomb  16843  dvdsmulf1o  20980
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1556  ax-5 1567  ax-17 1627  ax-9 1667  ax-8 1688  ax-13 1728  ax-14 1730  ax-6 1745  ax-7 1750  ax-11 1762  ax-12 1951  ax-ext 2418  ax-sep 4331  ax-nul 4339  ax-pow 4378  ax-pr 4404  ax-un 4702  ax-resscn 9048  ax-1cn 9049  ax-icn 9050  ax-addcl 9051  ax-addrcl 9052  ax-mulcl 9053  ax-mulrcl 9054  ax-mulcom 9055  ax-addass 9056  ax-mulass 9057  ax-distr 9058  ax-i2m1 9059  ax-1ne0 9060  ax-1rid 9061  ax-rnegex 9062  ax-rrecex 9063  ax-cnre 9064  ax-pre-lttri 9065  ax-pre-lttrn 9066  ax-pre-ltadd 9067  ax-pre-mulgt0 9068
This theorem depends on definitions:  df-bi 179  df-or 361  df-an 362  df-3or 938  df-3an 939  df-tru 1329  df-ex 1552  df-nf 1555  df-sb 1660  df-eu 2286  df-mo 2287  df-clab 2424  df-cleq 2430  df-clel 2433  df-nfc 2562  df-ne 2602  df-nel 2603  df-ral 2711  df-rex 2712  df-reu 2713  df-rab 2715  df-v 2959  df-sbc 3163  df-csb 3253  df-dif 3324  df-un 3326  df-in 3328  df-ss 3335  df-pss 3337  df-nul 3630  df-if 3741  df-pw 3802  df-sn 3821  df-pr 3822  df-tp 3823  df-op 3824  df-uni 4017  df-iun 4096  df-br 4214  df-opab 4268  df-mpt 4269  df-tr 4304  df-eprel 4495  df-id 4499  df-po 4504  df-so 4505  df-fr 4542  df-we 4544  df-ord 4585  df-on 4586  df-lim 4587  df-suc 4588  df-om 4847  df-xp 4885  df-rel 4886  df-cnv 4887  df-co 4888  df-dm 4889  df-rn 4890  df-res 4891  df-ima 4892  df-iota 5419  df-fun 5457  df-fn 5458  df-f 5459  df-f1 5460  df-fo 5461  df-f1o 5462  df-fv 5463  df-ov 6085  df-oprab 6086  df-mpt2 6087  df-riota 6550  df-recs 6634  df-rdg 6669  df-er 6906  df-en 7111  df-dom 7112  df-sdom 7113  df-pnf 9123  df-mnf 9124  df-xr 9125  df-ltxr 9126  df-le 9127  df-sub 9294  df-neg 9295  df-nn 10002  df-n0 10223  df-z 10284  df-dvds 12854
  Copyright terms: Public domain W3C validator