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

Theorem 4sqlem13 13020
Description: Lemma for 4sq 13027. (Contributed by Mario Carneiro, 16-Jul-2014.)
Hypotheses
Ref Expression
4sq.1  |-  S  =  { n  |  E. x  e.  ZZ  E. y  e.  ZZ  E. z  e.  ZZ  E. w  e.  ZZ  n  =  ( ( ( x ^
2 )  +  ( y ^ 2 ) )  +  ( ( z ^ 2 )  +  ( w ^
2 ) ) ) }
4sq.2  |-  ( ph  ->  N  e.  NN )
4sq.3  |-  ( ph  ->  P  =  ( ( 2  x.  N )  +  1 ) )
4sq.4  |-  ( ph  ->  P  e.  Prime )
4sq.5  |-  ( ph  ->  ( 0 ... (
2  x.  N ) )  C_  S )
4sq.6  |-  T  =  { i  e.  NN  |  ( i  x.  P )  e.  S }
4sq.7  |-  M  =  sup ( T ,  RR ,  `'  <  )
Assertion
Ref Expression
4sqlem13  |-  ( ph  ->  ( T  =/=  (/)  /\  M  <  P ) )
Distinct variable groups:    w, n, x, y, z    i, n, M    n, N    P, i, n    ph, n    S, i, n
Allowed substitution hints:    ph( x, y, z, w, i)    P( x, y, z, w)    S( x, y, z, w)    T( x, y, z, w, i, n)    M( x, y, z, w)    N( x, y, z, w, i)

Proof of Theorem 4sqlem13
Dummy variables  k 
v  u  m are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 4sq.1 . . 3  |-  S  =  { n  |  E. x  e.  ZZ  E. y  e.  ZZ  E. z  e.  ZZ  E. w  e.  ZZ  n  =  ( ( ( x ^
2 )  +  ( y ^ 2 ) )  +  ( ( z ^ 2 )  +  ( w ^
2 ) ) ) }
2 4sq.2 . . 3  |-  ( ph  ->  N  e.  NN )
3 4sq.3 . . 3  |-  ( ph  ->  P  =  ( ( 2  x.  N )  +  1 ) )
4 4sq.4 . . 3  |-  ( ph  ->  P  e.  Prime )
5 eqid 2296 . . 3  |-  { u  |  E. m  e.  ( 0 ... N ) u  =  ( ( m ^ 2 )  mod  P ) }  =  { u  |  E. m  e.  ( 0 ... N ) u  =  ( ( m ^ 2 )  mod  P ) }
6 eqid 2296 . . 3  |-  ( v  e.  { u  |  E. m  e.  ( 0 ... N ) u  =  ( ( m ^ 2 )  mod  P ) } 
|->  ( ( P  - 
1 )  -  v
) )  =  ( v  e.  { u  |  E. m  e.  ( 0 ... N ) u  =  ( ( m ^ 2 )  mod  P ) } 
|->  ( ( P  - 
1 )  -  v
) )
71, 2, 3, 4, 5, 64sqlem12 13019 . 2  |-  ( ph  ->  E. k  e.  ( 1 ... ( P  -  1 ) ) E. u  e.  ZZ [ _i ]  ( ( ( abs `  u
) ^ 2 )  +  1 )  =  ( k  x.  P
) )
8 simplrl 736 . . . . . . . 8  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
k  e.  ( 1 ... ( P  - 
1 ) ) )
9 elfznn 10835 . . . . . . . 8  |-  ( k  e.  ( 1 ... ( P  -  1 ) )  ->  k  e.  NN )
108, 9syl 15 . . . . . . 7  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
k  e.  NN )
11 simpr 447 . . . . . . . 8  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )
12 abs1 11798 . . . . . . . . . . . 12  |-  ( abs `  1 )  =  1
1312oveq1i 5884 . . . . . . . . . . 11  |-  ( ( abs `  1 ) ^ 2 )  =  ( 1 ^ 2 )
14 sq1 11214 . . . . . . . . . . 11  |-  ( 1 ^ 2 )  =  1
1513, 14eqtri 2316 . . . . . . . . . 10  |-  ( ( abs `  1 ) ^ 2 )  =  1
1615oveq2i 5885 . . . . . . . . 9  |-  ( ( ( abs `  u
) ^ 2 )  +  ( ( abs `  1 ) ^
2 ) )  =  ( ( ( abs `  u ) ^ 2 )  +  1 )
17 simplrr 737 . . . . . . . . . 10  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  u  e.  ZZ [ _i ] )
18 1z 10069 . . . . . . . . . . 11  |-  1  e.  ZZ
19 zgz 12996 . . . . . . . . . . 11  |-  ( 1  e.  ZZ  ->  1  e.  ZZ [ _i ]
)
2018, 19ax-mp 8 . . . . . . . . . 10  |-  1  e.  ZZ [ _i ]
2114sqlem4a 13014 . . . . . . . . . 10  |-  ( ( u  e.  ZZ [
_i ]  /\  1  e.  ZZ [ _i ]
)  ->  ( (
( abs `  u
) ^ 2 )  +  ( ( abs `  1 ) ^
2 ) )  e.  S )
2217, 20, 21sylancl 643 . . . . . . . . 9  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( ( ( abs `  u ) ^ 2 )  +  ( ( abs `  1 ) ^ 2 ) )  e.  S )
2316, 22syl5eqelr 2381 . . . . . . . 8  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( ( ( abs `  u ) ^ 2 )  +  1 )  e.  S )
2411, 23eqeltrrd 2371 . . . . . . 7  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( k  x.  P
)  e.  S )
25 oveq1 5881 . . . . . . . . 9  |-  ( i  =  k  ->  (
i  x.  P )  =  ( k  x.  P ) )
2625eleq1d 2362 . . . . . . . 8  |-  ( i  =  k  ->  (
( i  x.  P
)  e.  S  <->  ( k  x.  P )  e.  S
) )
27 4sq.6 . . . . . . . 8  |-  T  =  { i  e.  NN  |  ( i  x.  P )  e.  S }
2826, 27elrab2 2938 . . . . . . 7  |-  ( k  e.  T  <->  ( k  e.  NN  /\  ( k  x.  P )  e.  S ) )
2910, 24, 28sylanbrc 645 . . . . . 6  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
k  e.  T )
30 ne0i 3474 . . . . . 6  |-  ( k  e.  T  ->  T  =/=  (/) )
3129, 30syl 15 . . . . 5  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  T  =/=  (/) )
32 ssrab2 3271 . . . . . . . . 9  |-  { i  e.  NN  |  ( i  x.  P )  e.  S }  C_  NN
3327, 32eqsstri 3221 . . . . . . . 8  |-  T  C_  NN
34 4sq.7 . . . . . . . . 9  |-  M  =  sup ( T ,  RR ,  `'  <  )
35 nnuz 10279 . . . . . . . . . . 11  |-  NN  =  ( ZZ>= `  1 )
3633, 35sseqtri 3223 . . . . . . . . . 10  |-  T  C_  ( ZZ>= `  1 )
37 infmssuzcl 10317 . . . . . . . . . 10  |-  ( ( T  C_  ( ZZ>= ` 
1 )  /\  T  =/=  (/) )  ->  sup ( T ,  RR ,  `'  <  )  e.  T
)
3836, 31, 37sylancr 644 . . . . . . . . 9  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  sup ( T ,  RR ,  `'  <  )  e.  T )
3934, 38syl5eqel 2380 . . . . . . . 8  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  M  e.  T )
4033, 39sseldi 3191 . . . . . . 7  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  M  e.  NN )
4140nnred 9777 . . . . . 6  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  M  e.  RR )
4210nnred 9777 . . . . . 6  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
k  e.  RR )
434ad2antrr 706 . . . . . . . 8  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  P  e.  Prime )
44 prmnn 12777 . . . . . . . 8  |-  ( P  e.  Prime  ->  P  e.  NN )
4543, 44syl 15 . . . . . . 7  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  P  e.  NN )
4645nnred 9777 . . . . . 6  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  P  e.  RR )
47 infmssuzle 10316 . . . . . . . 8  |-  ( ( T  C_  ( ZZ>= ` 
1 )  /\  k  e.  T )  ->  sup ( T ,  RR ,  `'  <  )  <_  k
)
4836, 29, 47sylancr 644 . . . . . . 7  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  sup ( T ,  RR ,  `'  <  )  <_ 
k )
4934, 48syl5eqbr 4072 . . . . . 6  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  M  <_  k )
50 prmz 12778 . . . . . . . . . 10  |-  ( P  e.  Prime  ->  P  e.  ZZ )
5143, 50syl 15 . . . . . . . . 9  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  P  e.  ZZ )
52 elfzm11 10869 . . . . . . . . 9  |-  ( ( 1  e.  ZZ  /\  P  e.  ZZ )  ->  ( k  e.  ( 1 ... ( P  -  1 ) )  <-> 
( k  e.  ZZ  /\  1  <_  k  /\  k  <  P ) ) )
5318, 51, 52sylancr 644 . . . . . . . 8  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( k  e.  ( 1 ... ( P  -  1 ) )  <-> 
( k  e.  ZZ  /\  1  <_  k  /\  k  <  P ) ) )
548, 53mpbid 201 . . . . . . 7  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( k  e.  ZZ  /\  1  <_  k  /\  k  <  P ) )
5554simp3d 969 . . . . . 6  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
k  <  P )
5641, 42, 46, 49, 55lelttrd 8990 . . . . 5  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  ->  M  <  P )
5731, 56jca 518 . . . 4  |-  ( ( ( ph  /\  (
k  e.  ( 1 ... ( P  - 
1 ) )  /\  u  e.  ZZ [ _i ] ) )  /\  ( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P ) )  -> 
( T  =/=  (/)  /\  M  <  P ) )
5857ex 423 . . 3  |-  ( (
ph  /\  ( k  e.  ( 1 ... ( P  -  1 ) )  /\  u  e.  ZZ [ _i ]
) )  ->  (
( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P )  ->  ( T  =/=  (/)  /\  M  < 
P ) ) )
5958rexlimdvva 2687 . 2  |-  ( ph  ->  ( E. k  e.  ( 1 ... ( P  -  1 ) ) E. u  e.  ZZ [ _i ] 
( ( ( abs `  u ) ^ 2 )  +  1 )  =  ( k  x.  P )  ->  ( T  =/=  (/)  /\  M  < 
P ) ) )
607, 59mpd 14 1  |-  ( ph  ->  ( T  =/=  (/)  /\  M  <  P ) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    <-> wb 176    /\ wa 358    /\ w3a 934    = wceq 1632    e. wcel 1696   {cab 2282    =/= wne 2459   E.wrex 2557   {crab 2560    C_ wss 3165   (/)c0 3468   class class class wbr 4039    e. cmpt 4093   `'ccnv 4704   ` cfv 5271  (class class class)co 5874   supcsup 7209   RRcr 8752   0cc0 8753   1c1 8754    + caddc 8756    x. cmul 8758    < clt 8883    <_ cle 8884    - cmin 9053   NNcn 9762   2c2 9811   ZZcz 10040   ZZ>=cuz 10246   ...cfz 10798    mod cmo 10989   ^cexp 11120   abscabs 11735   Primecprime 12774   ZZ [ _i ]cgz 12992
This theorem is referenced by:  4sqlem14  13021  4sqlem17  13024  4sqlem18  13025
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1536  ax-5 1547  ax-17 1606  ax-9 1644  ax-8 1661  ax-13 1698  ax-14 1700  ax-6 1715  ax-7 1720  ax-11 1727  ax-12 1878  ax-ext 2277  ax-rep 4147  ax-sep 4157  ax-nul 4165  ax-pow 4204  ax-pr 4230  ax-un 4528  ax-cnex 8809  ax-resscn 8810  ax-1cn 8811  ax-icn 8812  ax-addcl 8813  ax-addrcl 8814  ax-mulcl 8815  ax-mulrcl 8816  ax-mulcom 8817  ax-addass 8818  ax-mulass 8819  ax-distr 8820  ax-i2m1 8821  ax-1ne0 8822  ax-1rid 8823  ax-rnegex 8824  ax-rrecex 8825  ax-cnre 8826  ax-pre-lttri 8827  ax-pre-lttrn 8828  ax-pre-ltadd 8829  ax-pre-mulgt0 8830  ax-pre-sup 8831
This theorem depends on definitions:  df-bi 177  df-or 359  df-an 360  df-3or 935  df-3an 936  df-tru 1310  df-ex 1532  df-nf 1535  df-sb 1639  df-eu 2160  df-mo 2161  df-clab 2283  df-cleq 2289  df-clel 2292  df-nfc 2421  df-ne 2461  df-nel 2462  df-ral 2561  df-rex 2562  df-reu 2563  df-rmo 2564  df-rab 2565  df-v 2803  df-sbc 3005  df-csb 3095  df-dif 3168  df-un 3170  df-in 3172  df-ss 3179  df-pss 3181  df-nul 3469  df-if 3579  df-pw 3640  df-sn 3659  df-pr 3660  df-tp 3661  df-op 3662  df-uni 3844  df-int 3879  df-iun 3923  df-br 4040  df-opab 4094  df-mpt 4095  df-tr 4130  df-eprel 4321  df-id 4325  df-po 4330  df-so 4331  df-fr 4368  df-we 4370  df-ord 4411  df-on 4412  df-lim 4413  df-suc 4414  df-om 4673  df-xp 4711  df-rel 4712  df-cnv 4713  df-co 4714  df-dm 4715  df-rn 4716  df-res 4717  df-ima 4718  df-iota 5235  df-fun 5273  df-fn 5274  df-f 5275  df-f1 5276  df-fo 5277  df-f1o 5278  df-fv 5279  df-ov 5877  df-oprab 5878  df-mpt2 5879  df-1st 6138  df-2nd 6139  df-riota 6320  df-recs 6404  df-rdg 6439  df-1o 6495  df-2o 6496  df-oadd 6499  df-er 6676  df-en 6880  df-dom 6881  df-sdom 6882  df-fin 6883  df-sup 7210  df-card 7588  df-cda 7810  df-pnf 8885  df-mnf 8886  df-xr 8887  df-ltxr 8888  df-le 8889  df-sub 9055  df-neg 9056  df-div 9440  df-nn 9763  df-2 9820  df-3 9821  df-4 9822  df-n0 9982  df-z 10041  df-uz 10247  df-rp 10371  df-fz 10799  df-fl 10941  df-mod 10990  df-seq 11063  df-exp 11121  df-hash 11354  df-cj 11600  df-re 11601  df-im 11602  df-sqr 11736  df-abs 11737  df-dvds 12548  df-gcd 12702  df-prm 12775  df-gz 12993
  Copyright terms: Public domain W3C validator