\frac{\left(-b_2\right) - \sqrt{b_2 \cdot b_2 - a \cdot c}}{a}\begin{array}{l}
\mathbf{if}\;b_2 \le -1.37866586320142018 \cdot 10^{-92}:\\
\;\;\;\;\frac{-1}{2} \cdot \frac{c}{b_2}\\
\mathbf{elif}\;b_2 \le -6.3130237661631722 \cdot 10^{-125}:\\
\;\;\;\;\frac{1 \cdot \mathsf{fma}\left(b_2, b_2, -\left(b_2 \cdot b_2 - a \cdot c\right)\right)}{a} \cdot \frac{1}{\left(-b_2\right) + \sqrt{b_2 \cdot b_2 - a \cdot c}}\\
\mathbf{elif}\;b_2 \le -9.09785312290987894 \cdot 10^{-156}:\\
\;\;\;\;\frac{-1}{2} \cdot \frac{c}{b_2}\\
\mathbf{elif}\;b_2 \le 3.9701546350182474 \cdot 10^{129}:\\
\;\;\;\;\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 VAR;
if ((b_2 <= -1.3786658632014202e-92)) {
VAR = (-0.5 * (c / b_2));
} else {
double VAR_1;
if ((b_2 <= -6.313023766163172e-125)) {
VAR_1 = (((1.0 * fma(b_2, b_2, -((b_2 * b_2) - (a * c)))) / a) * (1.0 / (-b_2 + sqrt(((b_2 * b_2) - (a * c))))));
} else {
double VAR_2;
if ((b_2 <= -9.097853122909879e-156)) {
VAR_2 = (-0.5 * (c / b_2));
} else {
double VAR_3;
if ((b_2 <= 3.9701546350182474e+129)) {
VAR_3 = (1.0 / (a / (-b_2 - sqrt(((b_2 * b_2) - (a * c))))));
} else {
VAR_3 = ((0.5 * (c / b_2)) - (2.0 * (b_2 / a)));
}
VAR_2 = VAR_3;
}
VAR_1 = VAR_2;
}
VAR = VAR_1;
}
return VAR;
}



Bits error versus a



Bits error versus b_2



Bits error versus c
Results
if b_2 < -1.3786658632014202e-92 or -6.313023766163172e-125 < b_2 < -9.097853122909879e-156Initial program 51.3
Taylor expanded around -inf 11.5
if -1.3786658632014202e-92 < b_2 < -6.313023766163172e-125Initial program 26.2
rmApplied clear-num26.3
rmApplied flip--26.3
Applied associate-/r/26.3
Applied add-cube-cbrt26.3
Applied times-frac26.3
Simplified26.1
Simplified26.1
if -9.097853122909879e-156 < b_2 < 3.9701546350182474e+129Initial program 10.9
rmApplied clear-num11.1
if 3.9701546350182474e+129 < b_2 Initial program 54.3
Taylor expanded around inf 2.0
Final simplification10.4
herbie shell --seed 2020106 +o rules:numerics
(FPCore (a b_2 c)
:name "quad2m (problem 3.2.1, negative)"
:precision binary64
(/ (- (- b_2) (sqrt (- (* b_2 b_2) (* a c)))) a))