\frac{\left(-b_2\right) - \sqrt{b_2 \cdot b_2 - a \cdot c}}{a}\begin{array}{l}
\mathbf{if}\;b_2 \le -1.0366436397824178 \cdot 10^{68}:\\
\;\;\;\;\frac{-1}{2} \cdot \frac{c}{b_2}\\
\mathbf{elif}\;b_2 \le -2.75036677292823045 \cdot 10^{-219}:\\
\;\;\;\;\frac{\frac{1}{\sqrt[3]{\sqrt{b_2 \cdot b_2 - a \cdot c} - b_2} \cdot \sqrt[3]{\sqrt{b_2 \cdot b_2 - a \cdot c} - b_2}} \cdot \frac{a}{\frac{\sqrt[3]{\sqrt{b_2 \cdot b_2 - a \cdot c} - b_2}}{c}}}{a}\\
\mathbf{elif}\;b_2 \le 5.34931179548294658 \cdot 10^{30}:\\
\;\;\;\;\frac{1}{\frac{a}{\left(-b_2\right) - \sqrt{b_2 \cdot b_2 - a \cdot c}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{2} \cdot \frac{c}{b_2} - 2 \cdot \frac{b_2}{a}\\
\end{array}double code(double a, double b_2, double c) {
return ((-b_2 - sqrt(((b_2 * b_2) - (a * c)))) / a);
}
double code(double a, double b_2, double c) {
double temp;
if ((b_2 <= -1.0366436397824178e+68)) {
temp = (-0.5 * (c / b_2));
} else {
double temp_1;
if ((b_2 <= -2.7503667729282305e-219)) {
temp_1 = (((1.0 / (cbrt((sqrt(((b_2 * b_2) - (a * c))) - b_2)) * cbrt((sqrt(((b_2 * b_2) - (a * c))) - b_2)))) * (a / (cbrt((sqrt(((b_2 * b_2) - (a * c))) - b_2)) / c))) / a);
} else {
double temp_2;
if ((b_2 <= 5.349311795482947e+30)) {
temp_2 = (1.0 / (a / (-b_2 - sqrt(((b_2 * b_2) - (a * c))))));
} else {
temp_2 = ((0.5 * (c / b_2)) - (2.0 * (b_2 / a)));
}
temp_1 = temp_2;
}
temp = temp_1;
}
return temp;
}



Bits error versus a



Bits error versus b_2



Bits error versus c
Results
if b_2 < -1.0366436397824178e+68Initial program 57.9
Taylor expanded around -inf 3.6
if -1.0366436397824178e+68 < b_2 < -2.7503667729282305e-219Initial program 34.6
rmApplied flip--34.6
Simplified16.9
Simplified16.9
rmApplied add-cube-cbrt17.6
Applied *-un-lft-identity17.6
Applied times-frac17.6
Simplified16.9
if -2.7503667729282305e-219 < b_2 < 5.349311795482947e+30Initial program 11.2
rmApplied clear-num11.3
if 5.349311795482947e+30 < b_2 Initial program 35.5
Taylor expanded around inf 6.4
Final simplification9.4
herbie shell --seed 2020049
(FPCore (a b_2 c)
:name "quad2m (problem 3.2.1, negative)"
:precision binary64
(/ (- (- b_2) (sqrt (- (* b_2 b_2) (* a c)))) a))