Metamath Proof Explorer


Theorem requad2

Description: A condition for a quadratic equation with real coefficients to have (exactly) two different real solutions. (Contributed by AV, 28-Jan-2023)

Ref Expression
Hypotheses requad2.a φ A
requad2.z φ A 0
requad2.b φ B
requad2.c φ C
requad2.d φ D = B 2 4 A C
Assertion requad2 φ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D

Proof

Step Hyp Ref Expression
1 requad2.a φ A
2 requad2.z φ A 0
3 requad2.b φ B
4 requad2.c φ C
5 requad2.d φ D = B 2 4 A C
6 1 recnd φ A
7 6 ad3antrrr φ 0 D p 𝒫 x p A
8 2 ad3antrrr φ 0 D p 𝒫 x p A 0
9 3 recnd φ B
10 9 ad3antrrr φ 0 D p 𝒫 x p B
11 4 recnd φ C
12 11 ad3antrrr φ 0 D p 𝒫 x p C
13 elelpwi x p p 𝒫 x
14 13 expcom p 𝒫 x p x
15 14 adantl φ 0 D p 𝒫 x p x
16 15 imp φ 0 D p 𝒫 x p x
17 16 recnd φ 0 D p 𝒫 x p x
18 5 ad3antrrr φ 0 D p 𝒫 x p D = B 2 4 A C
19 7 8 10 12 17 18 quad φ 0 D p 𝒫 x p A x 2 + B x + C = 0 x = - B + D 2 A x = - B - D 2 A
20 19 ralbidva φ 0 D p 𝒫 x p A x 2 + B x + C = 0 x p x = - B + D 2 A x = - B - D 2 A
21 20 anbi2d φ 0 D p 𝒫 p = 2 x p A x 2 + B x + C = 0 p = 2 x p x = - B + D 2 A x = - B - D 2 A
22 21 reubidva φ 0 D ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 ∃! p 𝒫 p = 2 x p x = - B + D 2 A x = - B - D 2 A
23 eqid q 𝒫 | q = 2 = q 𝒫 | q = 2
24 23 pairreueq ∃! p q 𝒫 | q = 2 x p x = - B + D 2 A x = - B - D 2 A ∃! p 𝒫 p = 2 x p x = - B + D 2 A x = - B - D 2 A
25 24 bicomi ∃! p 𝒫 p = 2 x p x = - B + D 2 A x = - B - D 2 A ∃! p q 𝒫 | q = 2 x p x = - B + D 2 A x = - B - D 2 A
26 25 a1i φ 0 D ∃! p 𝒫 p = 2 x p x = - B + D 2 A x = - B - D 2 A ∃! p q 𝒫 | q = 2 x p x = - B + D 2 A x = - B - D 2 A
27 3 renegcld φ B
28 27 adantr φ 0 D B
29 3 resqcld φ B 2
30 4re 4
31 30 a1i φ 4
32 1 4 remulcld φ A C
33 31 32 remulcld φ 4 A C
34 29 33 resubcld φ B 2 4 A C
35 5 34 eqeltrd φ D
36 35 adantr φ 0 D D
37 simpr φ 0 D 0 D
38 36 37 resqrtcld φ 0 D D
39 28 38 readdcld φ 0 D - B + D
40 2re 2
41 40 a1i φ 2
42 41 1 remulcld φ 2 A
43 42 adantr φ 0 D 2 A
44 2cnne0 2 2 0
45 44 a1i φ 2 2 0
46 mulne0 2 2 0 A A 0 2 A 0
47 45 6 2 46 syl12anc φ 2 A 0
48 47 adantr φ 0 D 2 A 0
49 39 43 48 redivcld φ 0 D - B + D 2 A
50 3 adantr φ 0 D B
51 50 renegcld φ 0 D B
52 51 38 resubcld φ 0 D - B - D
53 40 a1i φ 0 D 2
54 1 adantr φ 0 D A
55 53 54 remulcld φ 0 D 2 A
56 52 55 48 redivcld φ 0 D - B - D 2 A
57 fveqeq2 q = x q = 2 x = 2
58 57 cbvrabv q 𝒫 | q = 2 = x 𝒫 | x = 2
59 49 56 58 paireqne φ 0 D ∃! p q 𝒫 | q = 2 x p x = - B + D 2 A x = - B - D 2 A - B + D 2 A - B - D 2 A
60 9 negcld φ B
61 35 recnd φ D
62 61 sqrtcld φ D
63 60 62 addcld φ - B + D
64 60 62 subcld φ - B - D
65 2cnd φ 2
66 65 6 mulcld φ 2 A
67 div11 - B + D - B - D 2 A 2 A 0 - B + D 2 A = - B - D 2 A - B + D = - B - D
68 63 64 66 47 67 syl112anc φ - B + D 2 A = - B - D 2 A - B + D = - B - D
69 60 62 negsubd φ - B + D = - B - D
70 69 eqcomd φ - B - D = - B + D
71 70 eqeq2d φ - B + D = - B - D - B + D = - B + D
72 62 negcld φ D
73 60 62 72 addcand φ - B + D = - B + D D = D
74 68 71 73 3bitrd φ - B + D 2 A = - B - D 2 A D = D
75 74 necon3bid φ - B + D 2 A - B - D 2 A D D
76 75 adantr φ 0 D - B + D 2 A - B - D 2 A D D
77 cnsqrt00 D D = 0 D = 0
78 61 77 syl φ D = 0 D = 0
79 78 necon3bid φ D 0 D 0
80 79 adantr φ 0 D D 0 D 0
81 62 eqnegd φ D = D D = 0
82 81 adantr φ 0 D D = D D = 0
83 82 necon3bid φ 0 D D D D 0
84 0red φ 0 D 0
85 84 36 37 leltned φ 0 D 0 < D D 0
86 80 83 85 3bitr4d φ 0 D D D 0 < D
87 76 86 bitrd φ 0 D - B + D 2 A - B - D 2 A 0 < D
88 26 59 87 3bitrd φ 0 D ∃! p 𝒫 p = 2 x p x = - B + D 2 A x = - B - D 2 A 0 < D
89 22 88 bitrd φ 0 D ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D
90 89 expcom 0 D φ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D
91 hash2prb p 𝒫 p = 2 a p b p a b p = a b
92 91 adantl φ p 𝒫 p = 2 a p b p a b p = a b
93 raleq p = a b x p A x 2 + B x + C = 0 x a b A x 2 + B x + C = 0
94 vex a V
95 vex b V
96 oveq1 x = a x 2 = a 2
97 96 oveq2d x = a A x 2 = A a 2
98 oveq2 x = a B x = B a
99 98 oveq1d x = a B x + C = B a + C
100 97 99 oveq12d x = a A x 2 + B x + C = A a 2 + B a + C
101 100 eqeq1d x = a A x 2 + B x + C = 0 A a 2 + B a + C = 0
102 oveq1 x = b x 2 = b 2
103 102 oveq2d x = b A x 2 = A b 2
104 oveq2 x = b B x = B b
105 104 oveq1d x = b B x + C = B b + C
106 103 105 oveq12d x = b A x 2 + B x + C = A b 2 + B b + C
107 106 eqeq1d x = b A x 2 + B x + C = 0 A b 2 + B b + C = 0
108 94 95 101 107 ralpr x a b A x 2 + B x + C = 0 A a 2 + B a + C = 0 A b 2 + B b + C = 0
109 93 108 bitrdi p = a b x p A x 2 + B x + C = 0 A a 2 + B a + C = 0 A b 2 + B b + C = 0
110 109 adantl a b p = a b x p A x 2 + B x + C = 0 A a 2 + B a + C = 0 A b 2 + B b + C = 0
111 110 adantl φ p 𝒫 a p b p a b p = a b x p A x 2 + B x + C = 0 A a 2 + B a + C = 0 A b 2 + B b + C = 0
112 elelpwi b p p 𝒫 b
113 112 ex b p p 𝒫 b
114 113 adantl a p b p p 𝒫 b
115 114 com12 p 𝒫 a p b p b
116 115 adantl φ p 𝒫 a p b p b
117 116 imp φ p 𝒫 a p b p b
118 oveq1 y = b y 2 = b 2
119 118 oveq2d y = b A y 2 = A b 2
120 oveq2 y = b B y = B b
121 120 oveq1d y = b B y + C = B b + C
122 119 121 oveq12d y = b A y 2 + B y + C = A b 2 + B b + C
123 122 eqeq1d y = b A y 2 + B y + C = 0 A b 2 + B b + C = 0
124 123 adantl φ p 𝒫 a p b p y = b A y 2 + B y + C = 0 A b 2 + B b + C = 0
125 117 124 rspcedv φ p 𝒫 a p b p A b 2 + B b + C = 0 y A y 2 + B y + C = 0
126 125 adantr φ p 𝒫 a p b p a b p = a b A b 2 + B b + C = 0 y A y 2 + B y + C = 0
127 126 adantld φ p 𝒫 a p b p a b p = a b A a 2 + B a + C = 0 A b 2 + B b + C = 0 y A y 2 + B y + C = 0
128 111 127 sylbid φ p 𝒫 a p b p a b p = a b x p A x 2 + B x + C = 0 y A y 2 + B y + C = 0
129 128 ex φ p 𝒫 a p b p a b p = a b x p A x 2 + B x + C = 0 y A y 2 + B y + C = 0
130 129 rexlimdvva φ p 𝒫 a p b p a b p = a b x p A x 2 + B x + C = 0 y A y 2 + B y + C = 0
131 92 130 sylbid φ p 𝒫 p = 2 x p A x 2 + B x + C = 0 y A y 2 + B y + C = 0
132 131 impd φ p 𝒫 p = 2 x p A x 2 + B x + C = 0 y A y 2 + B y + C = 0
133 132 rexlimdva φ p 𝒫 p = 2 x p A x 2 + B x + C = 0 y A y 2 + B y + C = 0
134 1 2 3 4 5 requad01 φ y A y 2 + B y + C = 0 0 D
135 133 134 sylibd φ p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 D
136 135 con3d φ ¬ 0 D ¬ p 𝒫 p = 2 x p A x 2 + B x + C = 0
137 136 impcom ¬ 0 D φ ¬ p 𝒫 p = 2 x p A x 2 + B x + C = 0
138 reurex ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 p 𝒫 p = 2 x p A x 2 + B x + C = 0
139 137 138 nsyl ¬ 0 D φ ¬ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0
140 139 pm2.21d ¬ 0 D φ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D
141 0red φ 0
142 ltle 0 D 0 < D 0 D
143 141 35 142 syl2anc φ 0 < D 0 D
144 pm2.24 0 D ¬ 0 D ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0
145 143 144 syl6 φ 0 < D ¬ 0 D ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0
146 145 com23 φ ¬ 0 D 0 < D ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0
147 146 impcom ¬ 0 D φ 0 < D ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0
148 140 147 impbid ¬ 0 D φ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D
149 148 ex ¬ 0 D φ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D
150 90 149 pm2.61i φ ∃! p 𝒫 p = 2 x p A x 2 + B x + C = 0 0 < D