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

Theorem gcdcllem3 12942
Description: Lemma for gcdn0cl 12943, gcddvds 12944 and dvdslegcd 12945. (Contributed by Paul Chapman, 21-Mar-2011.)
Hypotheses
Ref Expression
gcdcllem2.1  |-  S  =  { z  e.  ZZ  |  A. n  e.  { M ,  N }
z  ||  n }
gcdcllem2.2  |-  R  =  { z  e.  ZZ  |  ( z  ||  M  /\  z  ||  N
) }
Assertion
Ref Expression
gcdcllem3  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( sup ( R ,  RR ,  <  )  e.  NN  /\  ( sup ( R ,  RR ,  <  )  ||  M  /\  sup ( R ,  RR ,  <  ) 
||  N )  /\  ( ( K  e.  ZZ  /\  K  ||  M  /\  K  ||  N
)  ->  K  <_  sup ( R ,  RR ,  <  ) ) ) )
Distinct variable groups:    z, K    z, n, M    n, N, z
Allowed substitution hints:    R( z, n)    S( z, n)    K( n)

Proof of Theorem gcdcllem3
Dummy variables  x  y are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 gcdcllem2.2 . . . . 5  |-  R  =  { z  e.  ZZ  |  ( z  ||  M  /\  z  ||  N
) }
2 ssrab2 3373 . . . . 5  |-  { z  e.  ZZ  |  ( z  ||  M  /\  z  ||  N ) } 
C_  ZZ
31, 2eqsstri 3323 . . . 4  |-  R  C_  ZZ
4 prssi 3899 . . . . . . . 8  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  { M ,  N }  C_  ZZ )
54adantr 452 . . . . . . 7  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  { M ,  N }  C_  ZZ )
6 neorian 2639 . . . . . . . 8  |-  ( ( M  =/=  0  \/  N  =/=  0 )  <->  -.  ( M  =  0  /\  N  =  0 ) )
7 prid1g 3855 . . . . . . . . . . 11  |-  ( M  e.  ZZ  ->  M  e.  { M ,  N } )
8 neeq1 2560 . . . . . . . . . . . 12  |-  ( n  =  M  ->  (
n  =/=  0  <->  M  =/=  0 ) )
98rspcev 2997 . . . . . . . . . . 11  |-  ( ( M  e.  { M ,  N }  /\  M  =/=  0 )  ->  E. n  e.  { M ,  N } n  =/=  0
)
107, 9sylan 458 . . . . . . . . . 10  |-  ( ( M  e.  ZZ  /\  M  =/=  0 )  ->  E. n  e.  { M ,  N } n  =/=  0 )
1110adantlr 696 . . . . . . . . 9  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  M  =/=  0
)  ->  E. n  e.  { M ,  N } n  =/=  0
)
12 prid2g 3856 . . . . . . . . . . 11  |-  ( N  e.  ZZ  ->  N  e.  { M ,  N } )
13 neeq1 2560 . . . . . . . . . . . 12  |-  ( n  =  N  ->  (
n  =/=  0  <->  N  =/=  0 ) )
1413rspcev 2997 . . . . . . . . . . 11  |-  ( ( N  e.  { M ,  N }  /\  N  =/=  0 )  ->  E. n  e.  { M ,  N } n  =/=  0
)
1512, 14sylan 458 . . . . . . . . . 10  |-  ( ( N  e.  ZZ  /\  N  =/=  0 )  ->  E. n  e.  { M ,  N } n  =/=  0 )
1615adantll 695 . . . . . . . . 9  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  N  =/=  0
)  ->  E. n  e.  { M ,  N } n  =/=  0
)
1711, 16jaodan 761 . . . . . . . 8  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  ( M  =/=  0  \/  N  =/=  0 ) )  ->  E. n  e.  { M ,  N } n  =/=  0 )
186, 17sylan2br 463 . . . . . . 7  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  E. n  e.  { M ,  N }
n  =/=  0 )
19 gcdcllem2.1 . . . . . . . 8  |-  S  =  { z  e.  ZZ  |  A. n  e.  { M ,  N }
z  ||  n }
2019gcdcllem1 12940 . . . . . . 7  |-  ( ( { M ,  N }  C_  ZZ  /\  E. n  e.  { M ,  N } n  =/=  0 )  ->  ( S  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  S  y  <_  x
) )
215, 18, 20syl2anc 643 . . . . . 6  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( S  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  S  y  <_  x
) )
2219, 1gcdcllem2 12941 . . . . . . . 8  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  R  =  S )
23 neeq1 2560 . . . . . . . . 9  |-  ( R  =  S  ->  ( R  =/=  (/)  <->  S  =/=  (/) ) )
24 raleq 2849 . . . . . . . . . 10  |-  ( R  =  S  ->  ( A. y  e.  R  y  <_  x  <->  A. y  e.  S  y  <_  x ) )
2524rexbidv 2672 . . . . . . . . 9  |-  ( R  =  S  ->  ( E. x  e.  ZZ  A. y  e.  R  y  <_  x  <->  E. x  e.  ZZ  A. y  e.  S  y  <_  x
) )
2623, 25anbi12d 692 . . . . . . . 8  |-  ( R  =  S  ->  (
( R  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x )  <->  ( S  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  S  y  <_  x
) ) )
2722, 26syl 16 . . . . . . 7  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( R  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x
)  <->  ( S  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  S  y  <_  x
) ) )
2827adantr 452 . . . . . 6  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( ( R  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x
)  <->  ( S  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  S  y  <_  x
) ) )
2921, 28mpbird 224 . . . . 5  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( R  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x
) )
30 suprzcl2 10500 . . . . . 6  |-  ( ( R  C_  ZZ  /\  R  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x
)  ->  sup ( R ,  RR ,  <  )  e.  R )
313, 30mp3an1 1266 . . . . 5  |-  ( ( R  =/=  (/)  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x )  ->  sup ( R ,  RR ,  <  )  e.  R )
3229, 31syl 16 . . . 4  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  sup ( R ,  RR ,  <  )  e.  R )
333, 32sseldi 3291 . . 3  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  sup ( R ,  RR ,  <  )  e.  ZZ )
343a1i 11 . . . 4  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  R  C_  ZZ )
3529simprd 450 . . . 4  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  E. x  e.  ZZ  A. y  e.  R  y  <_  x )
36 1dvds 12793 . . . . . . 7  |-  ( M  e.  ZZ  ->  1  ||  M )
37 1dvds 12793 . . . . . . 7  |-  ( N  e.  ZZ  ->  1  ||  N )
3836, 37anim12i 550 . . . . . 6  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  ( 1  ||  M  /\  1  ||  N ) )
39 1z 10245 . . . . . . 7  |-  1  e.  ZZ
40 breq1 4158 . . . . . . . . 9  |-  ( z  =  1  ->  (
z  ||  M  <->  1  ||  M ) )
41 breq1 4158 . . . . . . . . 9  |-  ( z  =  1  ->  (
z  ||  N  <->  1  ||  N ) )
4240, 41anbi12d 692 . . . . . . . 8  |-  ( z  =  1  ->  (
( z  ||  M  /\  z  ||  N )  <-> 
( 1  ||  M  /\  1  ||  N ) ) )
4342, 1elrab2 3039 . . . . . . 7  |-  ( 1  e.  R  <->  ( 1  e.  ZZ  /\  (
1  ||  M  /\  1  ||  N ) ) )
4439, 43mpbiran 885 . . . . . 6  |-  ( 1  e.  R  <->  ( 1 
||  M  /\  1  ||  N ) )
4538, 44sylibr 204 . . . . 5  |-  ( ( M  e.  ZZ  /\  N  e.  ZZ )  ->  1  e.  R )
4645adantr 452 . . . 4  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  1  e.  R
)
47 suprzub 10501 . . . 4  |-  ( ( R  C_  ZZ  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x  /\  1  e.  R
)  ->  1  <_  sup ( R ,  RR ,  <  ) )
4834, 35, 46, 47syl3anc 1184 . . 3  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  1  <_  sup ( R ,  RR ,  <  ) )
49 elnnz1 10241 . . 3  |-  ( sup ( R ,  RR ,  <  )  e.  NN  <->  ( sup ( R ,  RR ,  <  )  e.  ZZ  /\  1  <_  sup ( R ,  RR ,  <  ) ) )
5033, 48, 49sylanbrc 646 . 2  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  sup ( R ,  RR ,  <  )  e.  NN )
51 breq1 4158 . . . . . 6  |-  ( x  =  sup ( R ,  RR ,  <  )  ->  ( x  ||  M 
<->  sup ( R ,  RR ,  <  )  ||  M ) )
52 breq1 4158 . . . . . 6  |-  ( x  =  sup ( R ,  RR ,  <  )  ->  ( x  ||  N 
<->  sup ( R ,  RR ,  <  )  ||  N ) )
5351, 52anbi12d 692 . . . . 5  |-  ( x  =  sup ( R ,  RR ,  <  )  ->  ( ( x 
||  M  /\  x  ||  N )  <->  ( sup ( R ,  RR ,  <  )  ||  M  /\  sup ( R ,  RR ,  <  )  ||  N
) ) )
54 breq1 4158 . . . . . . . 8  |-  ( z  =  x  ->  (
z  ||  M  <->  x  ||  M
) )
55 breq1 4158 . . . . . . . 8  |-  ( z  =  x  ->  (
z  ||  N  <->  x  ||  N
) )
5654, 55anbi12d 692 . . . . . . 7  |-  ( z  =  x  ->  (
( z  ||  M  /\  z  ||  N )  <-> 
( x  ||  M  /\  x  ||  N ) ) )
5756cbvrabv 2900 . . . . . 6  |-  { z  e.  ZZ  |  ( z  ||  M  /\  z  ||  N ) }  =  { x  e.  ZZ  |  ( x 
||  M  /\  x  ||  N ) }
581, 57eqtri 2409 . . . . 5  |-  R  =  { x  e.  ZZ  |  ( x  ||  M  /\  x  ||  N
) }
5953, 58elrab2 3039 . . . 4  |-  ( sup ( R ,  RR ,  <  )  e.  R  <->  ( sup ( R ,  RR ,  <  )  e.  ZZ  /\  ( sup ( R ,  RR ,  <  )  ||  M  /\  sup ( R ,  RR ,  <  )  ||  N ) ) )
6032, 59sylib 189 . . 3  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( sup ( R ,  RR ,  <  )  e.  ZZ  /\  ( sup ( R ,  RR ,  <  )  ||  M  /\  sup ( R ,  RR ,  <  ) 
||  N ) ) )
6160simprd 450 . 2  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( sup ( R ,  RR ,  <  )  ||  M  /\  sup ( R ,  RR ,  <  )  ||  N
) )
62 breq1 4158 . . . . . . 7  |-  ( z  =  K  ->  (
z  ||  M  <->  K  ||  M
) )
63 breq1 4158 . . . . . . 7  |-  ( z  =  K  ->  (
z  ||  N  <->  K  ||  N
) )
6462, 63anbi12d 692 . . . . . 6  |-  ( z  =  K  ->  (
( z  ||  M  /\  z  ||  N )  <-> 
( K  ||  M  /\  K  ||  N ) ) )
6564, 1elrab2 3039 . . . . 5  |-  ( K  e.  R  <->  ( K  e.  ZZ  /\  ( K 
||  M  /\  K  ||  N ) ) )
6665biimpri 198 . . . 4  |-  ( ( K  e.  ZZ  /\  ( K  ||  M  /\  K  ||  N ) )  ->  K  e.  R
)
67663impb 1149 . . 3  |-  ( ( K  e.  ZZ  /\  K  ||  M  /\  K  ||  N )  ->  K  e.  R )
68 suprzub 10501 . . . . 5  |-  ( ( R  C_  ZZ  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x  /\  K  e.  R
)  ->  K  <_  sup ( R ,  RR ,  <  ) )
69683expia 1155 . . . 4  |-  ( ( R  C_  ZZ  /\  E. x  e.  ZZ  A. y  e.  R  y  <_  x )  ->  ( K  e.  R  ->  K  <_  sup ( R ,  RR ,  <  ) ) )
703, 69mpan 652 . . 3  |-  ( E. x  e.  ZZ  A. y  e.  R  y  <_  x  ->  ( K  e.  R  ->  K  <_  sup ( R ,  RR ,  <  ) ) )
7135, 67, 70syl2im 36 . 2  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( ( K  e.  ZZ  /\  K  ||  M  /\  K  ||  N )  ->  K  <_  sup ( R ,  RR ,  <  ) ) )
7250, 61, 713jca 1134 1  |-  ( ( ( M  e.  ZZ  /\  N  e.  ZZ )  /\  -.  ( M  =  0  /\  N  =  0 ) )  ->  ( sup ( R ,  RR ,  <  )  e.  NN  /\  ( sup ( R ,  RR ,  <  )  ||  M  /\  sup ( R ,  RR ,  <  ) 
||  N )  /\  ( ( K  e.  ZZ  /\  K  ||  M  /\  K  ||  N
)  ->  K  <_  sup ( R ,  RR ,  <  ) ) ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 177    \/ wo 358    /\ wa 359    /\ w3a 936    = wceq 1649    e. wcel 1717    =/= wne 2552   A.wral 2651   E.wrex 2652   {crab 2655    C_ wss 3265   (/)c0 3573   {cpr 3760   class class class wbr 4155   supcsup 7382   RRcr 8924   0cc0 8925   1c1 8926    < clt 9055    <_ cle 9056   NNcn 9934   ZZcz 10216    || cdivides 12781
This theorem is referenced by:  gcdn0cl  12943  gcddvds  12944  dvdslegcd  12945
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1552  ax-5 1563  ax-17 1623  ax-9 1661  ax-8 1682  ax-13 1719  ax-14 1721  ax-6 1736  ax-7 1741  ax-11 1753  ax-12 1939  ax-ext 2370  ax-sep 4273  ax-nul 4281  ax-pow 4320  ax-pr 4346  ax-un 4643  ax-cnex 8981  ax-resscn 8982  ax-1cn 8983  ax-icn 8984  ax-addcl 8985  ax-addrcl 8986  ax-mulcl 8987  ax-mulrcl 8988  ax-mulcom 8989  ax-addass 8990  ax-mulass 8991  ax-distr 8992  ax-i2m1 8993  ax-1ne0 8994  ax-1rid 8995  ax-rnegex 8996  ax-rrecex 8997  ax-cnre 8998  ax-pre-lttri 8999  ax-pre-lttrn 9000  ax-pre-ltadd 9001  ax-pre-mulgt0 9002  ax-pre-sup 9003
This theorem depends on definitions:  df-bi 178  df-or 360  df-an 361  df-3or 937  df-3an 938  df-tru 1325  df-ex 1548  df-nf 1551  df-sb 1656  df-eu 2244  df-mo 2245  df-clab 2376  df-cleq 2382  df-clel 2385  df-nfc 2514  df-ne 2554  df-nel 2555  df-ral 2656  df-rex 2657  df-reu 2658  df-rmo 2659  df-rab 2660  df-v 2903  df-sbc 3107  df-csb 3197  df-dif 3268  df-un 3270  df-in 3272  df-ss 3279  df-pss 3281  df-nul 3574  df-if 3685  df-pw 3746  df-sn 3765  df-pr 3766  df-tp 3767  df-op 3768  df-uni 3960  df-iun 4039  df-br 4156  df-opab 4210  df-mpt 4211  df-tr 4246  df-eprel 4437  df-id 4441  df-po 4446  df-so 4447  df-fr 4484  df-we 4486  df-ord 4527  df-on 4528  df-lim 4529  df-suc 4530  df-om 4788  df-xp 4826  df-rel 4827  df-cnv 4828  df-co 4829  df-dm 4830  df-rn 4831  df-res 4832  df-ima 4833  df-iota 5360  df-fun 5398  df-fn 5399  df-f 5400  df-f1 5401  df-fo 5402  df-f1o 5403  df-fv 5404  df-ov 6025  df-oprab 6026  df-mpt2 6027  df-2nd 6291  df-riota 6487  df-recs 6571  df-rdg 6606  df-er 6843  df-en 7048  df-dom 7049  df-sdom 7050  df-sup 7383  df-pnf 9057  df-mnf 9058  df-xr 9059  df-ltxr 9060  df-le 9061  df-sub 9227  df-neg 9228  df-div 9612  df-nn 9935  df-2 9992  df-3 9993  df-n0 10156  df-z 10217  df-uz 10423  df-rp 10547  df-seq 11253  df-exp 11312  df-cj 11833  df-re 11834  df-im 11835  df-sqr 11969  df-abs 11970  df-dvds 12782
  Copyright terms: Public domain W3C validator