Users' Mathboxes Mathbox for Stefan O'Rear < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  pell1234qrdich Unicode version

Theorem pell1234qrdich 26946
Description: A general Pell solution is either a positive solution, or its negation is. (Contributed by Stefan O'Rear, 18-Sep-2014.)
Assertion
Ref Expression
pell1234qrdich  |-  ( ( D  e.  ( NN 
\NN )  /\  A  e.  (Pell1234QR `  D ) )  -> 
( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D )
) )

Proof of Theorem pell1234qrdich
Dummy variables  a 
b  c  d are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 elpell1234qr 26936 . . 3  |-  ( D  e.  ( NN  \NN )  -> 
( A  e.  (Pell1234QR `  D )  <->  ( A  e.  RR  /\  E. a  e.  ZZ  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) ) ) )
2 simplr 731 . . . . . . . . . 10  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  A  e.  RR )
32ad2antrr 706 . . . . . . . . 9  |-  ( ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  a  e.  NN0 )  /\  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  A  e.  RR )
4 oveq1 5865 . . . . . . . . . . . . . 14  |-  ( c  =  a  ->  (
c  +  ( ( sqr `  D )  x.  b ) )  =  ( a  +  ( ( sqr `  D
)  x.  b ) ) )
54eqeq2d 2294 . . . . . . . . . . . . 13  |-  ( c  =  a  ->  ( A  =  ( c  +  ( ( sqr `  D )  x.  b
) )  <->  A  =  ( a  +  ( ( sqr `  D
)  x.  b ) ) ) )
6 oveq1 5865 . . . . . . . . . . . . . . 15  |-  ( c  =  a  ->  (
c ^ 2 )  =  ( a ^
2 ) )
76oveq1d 5873 . . . . . . . . . . . . . 14  |-  ( c  =  a  ->  (
( c ^ 2 )  -  ( D  x.  ( b ^
2 ) ) )  =  ( ( a ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) ) )
87eqeq1d 2291 . . . . . . . . . . . . 13  |-  ( c  =  a  ->  (
( ( c ^
2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1  <->  (
( a ^ 2 )  -  ( D  x.  ( b ^
2 ) ) )  =  1 ) )
95, 8anbi12d 691 . . . . . . . . . . . 12  |-  ( c  =  a  ->  (
( A  =  ( c  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( c ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 )  <->  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) ) )
109rexbidv 2564 . . . . . . . . . . 11  |-  ( c  =  a  ->  ( E. b  e.  ZZ  ( A  =  (
c  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( c ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 )  <->  E. b  e.  ZZ  ( A  =  (
a  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 ) ) )
1110rspcev 2884 . . . . . . . . . 10  |-  ( ( a  e.  NN0  /\  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D )  x.  b
) )  /\  (
( a ^ 2 )  -  ( D  x.  ( b ^
2 ) ) )  =  1 ) )  ->  E. c  e.  NN0  E. b  e.  ZZ  ( A  =  ( c  +  ( ( sqr `  D )  x.  b
) )  /\  (
( c ^ 2 )  -  ( D  x.  ( b ^
2 ) ) )  =  1 ) )
1211adantll 694 . . . . . . . . 9  |-  ( ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  a  e.  NN0 )  /\  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  E. c  e.  NN0  E. b  e.  ZZ  ( A  =  ( c  +  ( ( sqr `  D )  x.  b
) )  /\  (
( c ^ 2 )  -  ( D  x.  ( b ^
2 ) ) )  =  1 ) )
13 elpell14qr 26934 . . . . . . . . . . 11  |-  ( D  e.  ( NN  \NN )  -> 
( A  e.  (Pell14QR `  D )  <->  ( A  e.  RR  /\  E. c  e.  NN0  E. b  e.  ZZ  ( A  =  ( c  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) ) ) )
1413adantr 451 . . . . . . . . . 10  |-  ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  ->  ( A  e.  (Pell14QR `  D )  <->  ( A  e.  RR  /\  E. c  e.  NN0  E. b  e.  ZZ  ( A  =  ( c  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) ) ) )
1514ad3antrrr 710 . . . . . . . . 9  |-  ( ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  a  e.  NN0 )  /\  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( A  e.  (Pell14QR `  D )  <->  ( A  e.  RR  /\  E. c  e.  NN0  E. b  e.  ZZ  ( A  =  ( c  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) ) ) )
163, 12, 15mpbir2and 888 . . . . . . . 8  |-  ( ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  a  e.  NN0 )  /\  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  A  e.  (Pell14QR `  D
) )
1716orcd 381 . . . . . . 7  |-  ( ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  a  e.  NN0 )  /\  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D )
) )
1817exp31 587 . . . . . 6  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  (
a  e.  NN0  ->  ( E. b  e.  ZZ  ( A  =  (
a  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 )  ->  ( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D ) ) ) ) )
192ad3antrrr 710 . . . . . . . . . . . 12  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  A  e.  RR )
2019renegcld 9210 . . . . . . . . . . 11  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u A  e.  RR )
21 simpllr 735 . . . . . . . . . . . 12  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u a  e.  NN0 )
22 znegcl 10055 . . . . . . . . . . . . 13  |-  ( b  e.  ZZ  ->  -u b  e.  ZZ )
2322ad2antlr 707 . . . . . . . . . . . 12  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u b  e.  ZZ )
24 simprl 732 . . . . . . . . . . . . . 14  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  A  =  ( a  +  ( ( sqr `  D )  x.  b
) ) )
2524negeqd 9046 . . . . . . . . . . . . 13  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u A  =  -u (
a  +  ( ( sqr `  D )  x.  b ) ) )
26 zcn 10029 . . . . . . . . . . . . . . . 16  |-  ( a  e.  ZZ  ->  a  e.  CC )
2726adantl 452 . . . . . . . . . . . . . . 15  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  a  e.  CC )
2827ad3antrrr 710 . . . . . . . . . . . . . 14  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
a  e.  CC )
29 eldifi 3298 . . . . . . . . . . . . . . . . . . 19  |-  ( D  e.  ( NN  \NN )  ->  D  e.  NN )
3029nncnd 9762 . . . . . . . . . . . . . . . . . 18  |-  ( D  e.  ( NN  \NN )  ->  D  e.  CC )
3130ad2antrr 706 . . . . . . . . . . . . . . . . 17  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  D  e.  CC )
3231ad3antrrr 710 . . . . . . . . . . . . . . . 16  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  D  e.  CC )
3332sqrcld 11919 . . . . . . . . . . . . . . 15  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( sqr `  D
)  e.  CC )
34 zcn 10029 . . . . . . . . . . . . . . . 16  |-  ( b  e.  ZZ  ->  b  e.  CC )
3534ad2antlr 707 . . . . . . . . . . . . . . 15  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
b  e.  CC )
3633, 35mulcld 8855 . . . . . . . . . . . . . 14  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( ( sqr `  D
)  x.  b )  e.  CC )
3728, 36negdid 9170 . . . . . . . . . . . . 13  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u ( a  +  ( ( sqr `  D
)  x.  b ) )  =  ( -u a  +  -u ( ( sqr `  D )  x.  b ) ) )
38 mulneg2 9217 . . . . . . . . . . . . . . . 16  |-  ( ( ( sqr `  D
)  e.  CC  /\  b  e.  CC )  ->  ( ( sqr `  D
)  x.  -u b
)  =  -u (
( sqr `  D
)  x.  b ) )
3938eqcomd 2288 . . . . . . . . . . . . . . 15  |-  ( ( ( sqr `  D
)  e.  CC  /\  b  e.  CC )  -> 
-u ( ( sqr `  D )  x.  b
)  =  ( ( sqr `  D )  x.  -u b ) )
4033, 35, 39syl2anc 642 . . . . . . . . . . . . . 14  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u ( ( sqr `  D
)  x.  b )  =  ( ( sqr `  D )  x.  -u b
) )
4140oveq2d 5874 . . . . . . . . . . . . 13  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( -u a  +  -u ( ( sqr `  D
)  x.  b ) )  =  ( -u a  +  ( ( sqr `  D )  x.  -u b ) ) )
4225, 37, 413eqtrd 2319 . . . . . . . . . . . 12  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u A  =  ( -u a  +  ( ( sqr `  D )  x.  -u b ) ) )
43 sqneg 11164 . . . . . . . . . . . . . . 15  |-  ( a  e.  CC  ->  ( -u a ^ 2 )  =  ( a ^
2 ) )
4428, 43syl 15 . . . . . . . . . . . . . 14  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( -u a ^ 2 )  =  ( a ^ 2 ) )
45 sqneg 11164 . . . . . . . . . . . . . . . 16  |-  ( b  e.  CC  ->  ( -u b ^ 2 )  =  ( b ^
2 ) )
4635, 45syl 15 . . . . . . . . . . . . . . 15  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( -u b ^ 2 )  =  ( b ^ 2 ) )
4746oveq2d 5874 . . . . . . . . . . . . . 14  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( D  x.  ( -u b ^ 2 ) )  =  ( D  x.  ( b ^
2 ) ) )
4844, 47oveq12d 5876 . . . . . . . . . . . . 13  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( ( -u a ^ 2 )  -  ( D  x.  ( -u b ^ 2 ) ) )  =  ( ( a ^ 2 )  -  ( D  x.  ( b ^
2 ) ) ) )
49 simprr 733 . . . . . . . . . . . . 13  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( ( a ^
2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 )
5048, 49eqtrd 2315 . . . . . . . . . . . 12  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( ( -u a ^ 2 )  -  ( D  x.  ( -u b ^ 2 ) ) )  =  1 )
51 oveq1 5865 . . . . . . . . . . . . . . 15  |-  ( c  =  -u a  ->  (
c  +  ( ( sqr `  D )  x.  d ) )  =  ( -u a  +  ( ( sqr `  D )  x.  d
) ) )
5251eqeq2d 2294 . . . . . . . . . . . . . 14  |-  ( c  =  -u a  ->  ( -u A  =  ( c  +  ( ( sqr `  D )  x.  d
) )  <->  -u A  =  ( -u a  +  ( ( sqr `  D
)  x.  d ) ) ) )
53 oveq1 5865 . . . . . . . . . . . . . . . 16  |-  ( c  =  -u a  ->  (
c ^ 2 )  =  ( -u a ^ 2 ) )
5453oveq1d 5873 . . . . . . . . . . . . . . 15  |-  ( c  =  -u a  ->  (
( c ^ 2 )  -  ( D  x.  ( d ^
2 ) ) )  =  ( ( -u a ^ 2 )  -  ( D  x.  (
d ^ 2 ) ) ) )
5554eqeq1d 2291 . . . . . . . . . . . . . 14  |-  ( c  =  -u a  ->  (
( ( c ^
2 )  -  ( D  x.  ( d ^ 2 ) ) )  =  1  <->  (
( -u a ^ 2 )  -  ( D  x.  ( d ^
2 ) ) )  =  1 ) )
5652, 55anbi12d 691 . . . . . . . . . . . . 13  |-  ( c  =  -u a  ->  (
( -u A  =  ( c  +  ( ( sqr `  D )  x.  d ) )  /\  ( ( c ^ 2 )  -  ( D  x.  (
d ^ 2 ) ) )  =  1 )  <->  ( -u A  =  ( -u a  +  ( ( sqr `  D )  x.  d
) )  /\  (
( -u a ^ 2 )  -  ( D  x.  ( d ^
2 ) ) )  =  1 ) ) )
57 oveq2 5866 . . . . . . . . . . . . . . . 16  |-  ( d  =  -u b  ->  (
( sqr `  D
)  x.  d )  =  ( ( sqr `  D )  x.  -u b
) )
5857oveq2d 5874 . . . . . . . . . . . . . . 15  |-  ( d  =  -u b  ->  ( -u a  +  ( ( sqr `  D )  x.  d ) )  =  ( -u a  +  ( ( sqr `  D )  x.  -u b
) ) )
5958eqeq2d 2294 . . . . . . . . . . . . . 14  |-  ( d  =  -u b  ->  ( -u A  =  ( -u a  +  ( ( sqr `  D )  x.  d ) )  <->  -u A  =  ( -u a  +  ( ( sqr `  D
)  x.  -u b
) ) ) )
60 oveq1 5865 . . . . . . . . . . . . . . . . 17  |-  ( d  =  -u b  ->  (
d ^ 2 )  =  ( -u b ^ 2 ) )
6160oveq2d 5874 . . . . . . . . . . . . . . . 16  |-  ( d  =  -u b  ->  ( D  x.  ( d ^ 2 ) )  =  ( D  x.  ( -u b ^ 2 ) ) )
6261oveq2d 5874 . . . . . . . . . . . . . . 15  |-  ( d  =  -u b  ->  (
( -u a ^ 2 )  -  ( D  x.  ( d ^
2 ) ) )  =  ( ( -u a ^ 2 )  -  ( D  x.  ( -u b ^ 2 ) ) ) )
6362eqeq1d 2291 . . . . . . . . . . . . . 14  |-  ( d  =  -u b  ->  (
( ( -u a ^ 2 )  -  ( D  x.  (
d ^ 2 ) ) )  =  1  <-> 
( ( -u a ^ 2 )  -  ( D  x.  ( -u b ^ 2 ) ) )  =  1 ) )
6459, 63anbi12d 691 . . . . . . . . . . . . 13  |-  ( d  =  -u b  ->  (
( -u A  =  (
-u a  +  ( ( sqr `  D
)  x.  d ) )  /\  ( (
-u a ^ 2 )  -  ( D  x.  ( d ^
2 ) ) )  =  1 )  <->  ( -u A  =  ( -u a  +  ( ( sqr `  D )  x.  -u b
) )  /\  (
( -u a ^ 2 )  -  ( D  x.  ( -u b ^ 2 ) ) )  =  1 ) ) )
6556, 64rspc2ev 2892 . . . . . . . . . . . 12  |-  ( (
-u a  e.  NN0  /\  -u b  e.  ZZ  /\  ( -u A  =  ( -u a  +  ( ( sqr `  D
)  x.  -u b
) )  /\  (
( -u a ^ 2 )  -  ( D  x.  ( -u b ^ 2 ) ) )  =  1 ) )  ->  E. c  e.  NN0  E. d  e.  ZZ  ( -u A  =  ( c  +  ( ( sqr `  D
)  x.  d ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( d ^ 2 ) ) )  =  1 ) )
6621, 23, 42, 50, 65syl112anc 1186 . . . . . . . . . . 11  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  E. c  e.  NN0  E. d  e.  ZZ  ( -u A  =  ( c  +  ( ( sqr `  D )  x.  d
) )  /\  (
( c ^ 2 )  -  ( D  x.  ( d ^
2 ) ) )  =  1 ) )
67 elpell14qr 26934 . . . . . . . . . . . . 13  |-  ( D  e.  ( NN  \NN )  -> 
( -u A  e.  (Pell14QR `  D )  <->  ( -u A  e.  RR  /\  E. c  e.  NN0  E. d  e.  ZZ  ( -u A  =  ( c  +  ( ( sqr `  D
)  x.  d ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( d ^ 2 ) ) )  =  1 ) ) ) )
6867ad2antrr 706 . . . . . . . . . . . 12  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  ( -u A  e.  (Pell14QR `  D
)  <->  ( -u A  e.  RR  /\  E. c  e.  NN0  E. d  e.  ZZ  ( -u A  =  ( c  +  ( ( sqr `  D
)  x.  d ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( d ^ 2 ) ) )  =  1 ) ) ) )
6968ad3antrrr 710 . . . . . . . . . . 11  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( -u A  e.  (Pell14QR `  D )  <->  ( -u A  e.  RR  /\  E. c  e.  NN0  E. d  e.  ZZ  ( -u A  =  ( c  +  ( ( sqr `  D
)  x.  d ) )  /\  ( ( c ^ 2 )  -  ( D  x.  ( d ^ 2 ) ) )  =  1 ) ) ) )
7020, 66, 69mpbir2and 888 . . . . . . . . . 10  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  ->  -u A  e.  (Pell14QR `  D
) )
7170olcd 382 . . . . . . . . 9  |-  ( ( ( ( ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  /\  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D )
) )
7271ex 423 . . . . . . . 8  |-  ( ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  /\  b  e.  ZZ )  ->  ( ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 )  ->  ( A  e.  (Pell14QR `  D
)  \/  -u A  e.  (Pell14QR `  D )
) ) )
7372rexlimdva 2667 . . . . . . 7  |-  ( ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  /\  -u a  e.  NN0 )  ->  ( E. b  e.  ZZ  ( A  =  (
a  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 )  ->  ( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D ) ) ) )
7473ex 423 . . . . . 6  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  ( -u a  e.  NN0  ->  ( E. b  e.  ZZ  ( A  =  (
a  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 )  ->  ( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D ) ) ) ) )
75 elznn0 10038 . . . . . . . 8  |-  ( a  e.  ZZ  <->  ( a  e.  RR  /\  ( a  e.  NN0  \/  -u a  e.  NN0 ) ) )
7675simprbi 450 . . . . . . 7  |-  ( a  e.  ZZ  ->  (
a  e.  NN0  \/  -u a  e.  NN0 )
)
7776adantl 452 . . . . . 6  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  (
a  e.  NN0  \/  -u a  e.  NN0 )
)
7818, 74, 77mpjaod 370 . . . . 5  |-  ( ( ( D  e.  ( NN  \NN )  /\  A  e.  RR )  /\  a  e.  ZZ )  ->  ( E. b  e.  ZZ  ( A  =  (
a  +  ( ( sqr `  D )  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  (
b ^ 2 ) ) )  =  1 )  ->  ( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D ) ) ) )
7978rexlimdva 2667 . . . 4  |-  ( ( D  e.  ( NN 
\NN )  /\  A  e.  RR )  ->  ( E. a  e.  ZZ  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 )  ->  ( A  e.  (Pell14QR `  D
)  \/  -u A  e.  (Pell14QR `  D )
) ) )
8079expimpd 586 . . 3  |-  ( D  e.  ( NN  \NN )  -> 
( ( A  e.  RR  /\  E. a  e.  ZZ  E. b  e.  ZZ  ( A  =  ( a  +  ( ( sqr `  D
)  x.  b ) )  /\  ( ( a ^ 2 )  -  ( D  x.  ( b ^ 2 ) ) )  =  1 ) )  -> 
( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D )
) ) )
811, 80sylbid 206 . 2  |-  ( D  e.  ( NN  \NN )  -> 
( A  e.  (Pell1234QR `  D )  ->  ( A  e.  (Pell14QR `  D
)  \/  -u A  e.  (Pell14QR `  D )
) ) )
8281imp 418 1  |-  ( ( D  e.  ( NN 
\NN )  /\  A  e.  (Pell1234QR `  D ) )  -> 
( A  e.  (Pell14QR `  D )  \/  -u A  e.  (Pell14QR `  D )
) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    <-> wb 176    \/ wo 357    /\ wa 358    = wceq 1623    e. wcel 1684   E.wrex 2544    \ cdif 3149   ` cfv 5255  (class class class)co 5858   CCcc 8735   RRcr 8736   1c1 8738    + caddc 8740    x. cmul 8742    - cmin 9037   -ucneg 9038   NNcn 9746   2c2 9795   NN0cn0 9965   ZZcz 10024   ^cexp 11104   sqrcsqr 11718  ◻NNcsquarenn 26921  Pell1234QRcpell1234qr 26923  Pell14QRcpell14qr 26924
This theorem is referenced by:  elpell14qr2  26947
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1533  ax-5 1544  ax-17 1603  ax-9 1635  ax-8 1643  ax-13 1686  ax-14 1688  ax-6 1703  ax-7 1708  ax-11 1715  ax-12 1866  ax-ext 2264  ax-sep 4141  ax-nul 4149  ax-pow 4188  ax-pr 4214  ax-un 4512  ax-cnex 8793  ax-resscn 8794  ax-1cn 8795  ax-icn 8796  ax-addcl 8797  ax-addrcl 8798  ax-mulcl 8799  ax-mulrcl 8800  ax-mulcom 8801  ax-addass 8802  ax-mulass 8803  ax-distr 8804  ax-i2m1 8805  ax-1ne0 8806  ax-1rid 8807  ax-rnegex 8808  ax-rrecex 8809  ax-cnre 8810  ax-pre-lttri 8811  ax-pre-lttrn 8812  ax-pre-ltadd 8813  ax-pre-mulgt0 8814  ax-pre-sup 8815
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 1529  df-nf 1532  df-sb 1630  df-eu 2147  df-mo 2148  df-clab 2270  df-cleq 2276  df-clel 2279  df-nfc 2408  df-ne 2448  df-nel 2449  df-ral 2548  df-rex 2549  df-reu 2550  df-rmo 2551  df-rab 2552  df-v 2790  df-sbc 2992  df-csb 3082  df-dif 3155  df-un 3157  df-in 3159  df-ss 3166  df-pss 3168  df-nul 3456  df-if 3566  df-pw 3627  df-sn 3646  df-pr 3647  df-tp 3648  df-op 3649  df-uni 3828  df-iun 3907  df-br 4024  df-opab 4078  df-mpt 4079  df-tr 4114  df-eprel 4305  df-id 4309  df-po 4314  df-so 4315  df-fr 4352  df-we 4354  df-ord 4395  df-on 4396  df-lim 4397  df-suc 4398  df-om 4657  df-xp 4695  df-rel 4696  df-cnv 4697  df-co 4698  df-dm 4699  df-rn 4700  df-res 4701  df-ima 4702  df-iota 5219  df-fun 5257  df-fn 5258  df-f 5259  df-f1 5260  df-fo 5261  df-f1o 5262  df-fv 5263  df-ov 5861  df-oprab 5862  df-mpt2 5863  df-2nd 6123  df-riota 6304  df-recs 6388  df-rdg 6423  df-er 6660  df-en 6864  df-dom 6865  df-sdom 6866  df-sup 7194  df-pnf 8869  df-mnf 8870  df-xr 8871  df-ltxr 8872  df-le 8873  df-sub 9039  df-neg 9040  df-div 9424  df-nn 9747  df-2 9804  df-3 9805  df-n0 9966  df-z 10025  df-uz 10231  df-rp 10355  df-seq 11047  df-exp 11105  df-cj 11584  df-re 11585  df-im 11586  df-sqr 11720  df-abs 11721  df-pell14qr 26928  df-pell1234qr 26929
  Copyright terms: Public domain W3C validator