Average Error: 20.0 → 6.4
Time: 6.9s
Precision: binary64
\[\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\\ \end{array} \]
\[\begin{array}{l} t_0 := \frac{c \cdot -2}{b + \mathsf{fma}\left(-2, a \cdot \frac{c}{b}, b\right)}\\ t_1 := \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\\ t_2 := \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + t_1}\\ \mathbf{else}:\\ \;\;\;\;\frac{b - \sqrt{\mathsf{fma}\left(c, a \cdot -4, b \cdot b\right)}}{a \cdot -2}\\ \end{array}\\ t_3 := -\frac{b}{a}\\ t_4 := \sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)}\\ t_5 := \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - t_4}\\ \mathbf{else}:\\ \;\;\;\;\frac{t_4 - b}{2 \cdot a}\\ \end{array}\\ \mathbf{if}\;t_5 \leq -\infty:\\ \;\;\;\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{b}{a}\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array}\\ \mathbf{elif}\;t_5 \leq -5 \cdot 10^{-226}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t_5 \leq 0:\\ \;\;\;\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\left(b - t_1\right) \cdot \frac{-0.5}{a}\\ \end{array}\\ \mathbf{elif}\;t_5 \leq 5 \cdot 10^{+295}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \geq 0:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (>= b 0.0)
   (/ (* 2.0 c) (- (- b) (sqrt (- (* b b) (* (* 4.0 a) c)))))
   (/ (+ (- b) (sqrt (- (* b b) (* (* 4.0 a) c)))) (* 2.0 a))))
(FPCore (a b c)
 :precision binary64
 (let* ((t_0 (/ (* c -2.0) (+ b (fma -2.0 (* a (/ c b)) b))))
        (t_1 (sqrt (fma c (/ a -0.25) (* b b))))
        (t_2
         (if (>= b 0.0)
           (/ (* c -2.0) (+ b t_1))
           (/ (- b (sqrt (fma c (* a -4.0) (* b b)))) (* a -2.0))))
        (t_3 (- (/ b a)))
        (t_4 (sqrt (- (* b b) (* c (* 4.0 a)))))
        (t_5
         (if (>= b 0.0) (/ (* 2.0 c) (- (- b) t_4)) (/ (- t_4 b) (* 2.0 a)))))
   (if (<= t_5 (- INFINITY))
     (if (>= b 0.0) (/ b a) t_3)
     (if (<= t_5 -5e-226)
       t_2
       (if (<= t_5 0.0)
         (if (>= b 0.0) t_0 (* (- b t_1) (/ -0.5 a)))
         (if (<= t_5 5e+295) t_2 (if (>= b 0.0) t_0 t_3)))))))
double code(double a, double b, double c) {
	double tmp;
	if (b >= 0.0) {
		tmp = (2.0 * c) / (-b - sqrt(((b * b) - ((4.0 * a) * c))));
	} else {
		tmp = (-b + sqrt(((b * b) - ((4.0 * a) * c)))) / (2.0 * a);
	}
	return tmp;
}
double code(double a, double b, double c) {
	double t_0 = (c * -2.0) / (b + fma(-2.0, (a * (c / b)), b));
	double t_1 = sqrt(fma(c, (a / -0.25), (b * b)));
	double tmp;
	if (b >= 0.0) {
		tmp = (c * -2.0) / (b + t_1);
	} else {
		tmp = (b - sqrt(fma(c, (a * -4.0), (b * b)))) / (a * -2.0);
	}
	double t_2 = tmp;
	double t_3 = -(b / a);
	double t_4 = sqrt(((b * b) - (c * (4.0 * a))));
	double tmp_1;
	if (b >= 0.0) {
		tmp_1 = (2.0 * c) / (-b - t_4);
	} else {
		tmp_1 = (t_4 - b) / (2.0 * a);
	}
	double t_5 = tmp_1;
	double tmp_3;
	if (t_5 <= -((double) INFINITY)) {
		double tmp_4;
		if (b >= 0.0) {
			tmp_4 = b / a;
		} else {
			tmp_4 = t_3;
		}
		tmp_3 = tmp_4;
	} else if (t_5 <= -5e-226) {
		tmp_3 = t_2;
	} else if (t_5 <= 0.0) {
		double tmp_5;
		if (b >= 0.0) {
			tmp_5 = t_0;
		} else {
			tmp_5 = (b - t_1) * (-0.5 / a);
		}
		tmp_3 = tmp_5;
	} else if (t_5 <= 5e+295) {
		tmp_3 = t_2;
	} else if (b >= 0.0) {
		tmp_3 = t_0;
	} else {
		tmp_3 = t_3;
	}
	return tmp_3;
}
function code(a, b, c)
	tmp = 0.0
	if (b >= 0.0)
		tmp = Float64(Float64(2.0 * c) / Float64(Float64(-b) - sqrt(Float64(Float64(b * b) - Float64(Float64(4.0 * a) * c)))));
	else
		tmp = Float64(Float64(Float64(-b) + sqrt(Float64(Float64(b * b) - Float64(Float64(4.0 * a) * c)))) / Float64(2.0 * a));
	end
	return tmp
end
function code(a, b, c)
	t_0 = Float64(Float64(c * -2.0) / Float64(b + fma(-2.0, Float64(a * Float64(c / b)), b)))
	t_1 = sqrt(fma(c, Float64(a / -0.25), Float64(b * b)))
	tmp = 0.0
	if (b >= 0.0)
		tmp = Float64(Float64(c * -2.0) / Float64(b + t_1));
	else
		tmp = Float64(Float64(b - sqrt(fma(c, Float64(a * -4.0), Float64(b * b)))) / Float64(a * -2.0));
	end
	t_2 = tmp
	t_3 = Float64(-Float64(b / a))
	t_4 = sqrt(Float64(Float64(b * b) - Float64(c * Float64(4.0 * a))))
	tmp_1 = 0.0
	if (b >= 0.0)
		tmp_1 = Float64(Float64(2.0 * c) / Float64(Float64(-b) - t_4));
	else
		tmp_1 = Float64(Float64(t_4 - b) / Float64(2.0 * a));
	end
	t_5 = tmp_1
	tmp_3 = 0.0
	if (t_5 <= Float64(-Inf))
		tmp_4 = 0.0
		if (b >= 0.0)
			tmp_4 = Float64(b / a);
		else
			tmp_4 = t_3;
		end
		tmp_3 = tmp_4;
	elseif (t_5 <= -5e-226)
		tmp_3 = t_2;
	elseif (t_5 <= 0.0)
		tmp_5 = 0.0
		if (b >= 0.0)
			tmp_5 = t_0;
		else
			tmp_5 = Float64(Float64(b - t_1) * Float64(-0.5 / a));
		end
		tmp_3 = tmp_5;
	elseif (t_5 <= 5e+295)
		tmp_3 = t_2;
	elseif (b >= 0.0)
		tmp_3 = t_0;
	else
		tmp_3 = t_3;
	end
	return tmp_3
end
code[a_, b_, c_] := If[GreaterEqual[b, 0.0], N[(N[(2.0 * c), $MachinePrecision] / N[((-b) - N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(N[(4.0 * a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[((-b) + N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(N[(4.0 * a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / N[(2.0 * a), $MachinePrecision]), $MachinePrecision]]
code[a_, b_, c_] := Block[{t$95$0 = N[(N[(c * -2.0), $MachinePrecision] / N[(b + N[(-2.0 * N[(a * N[(c / b), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[Sqrt[N[(c * N[(a / -0.25), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = If[GreaterEqual[b, 0.0], N[(N[(c * -2.0), $MachinePrecision] / N[(b + t$95$1), $MachinePrecision]), $MachinePrecision], N[(N[(b - N[Sqrt[N[(c * N[(a * -4.0), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / N[(a * -2.0), $MachinePrecision]), $MachinePrecision]]}, Block[{t$95$3 = (-N[(b / a), $MachinePrecision])}, Block[{t$95$4 = N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(c * N[(4.0 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$5 = If[GreaterEqual[b, 0.0], N[(N[(2.0 * c), $MachinePrecision] / N[((-b) - t$95$4), $MachinePrecision]), $MachinePrecision], N[(N[(t$95$4 - b), $MachinePrecision] / N[(2.0 * a), $MachinePrecision]), $MachinePrecision]]}, If[LessEqual[t$95$5, (-Infinity)], If[GreaterEqual[b, 0.0], N[(b / a), $MachinePrecision], t$95$3], If[LessEqual[t$95$5, -5e-226], t$95$2, If[LessEqual[t$95$5, 0.0], If[GreaterEqual[b, 0.0], t$95$0, N[(N[(b - t$95$1), $MachinePrecision] * N[(-0.5 / a), $MachinePrecision]), $MachinePrecision]], If[LessEqual[t$95$5, 5e+295], t$95$2, If[GreaterEqual[b, 0.0], t$95$0, t$95$3]]]]]]]]]]]
\begin{array}{l}
\mathbf{if}\;b \geq 0:\\
\;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\\

\mathbf{else}:\\
\;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\\


\end{array}
\begin{array}{l}
t_0 := \frac{c \cdot -2}{b + \mathsf{fma}\left(-2, a \cdot \frac{c}{b}, b\right)}\\
t_1 := \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\\
t_2 := \begin{array}{l}
\mathbf{if}\;b \geq 0:\\
\;\;\;\;\frac{c \cdot -2}{b + t_1}\\

\mathbf{else}:\\
\;\;\;\;\frac{b - \sqrt{\mathsf{fma}\left(c, a \cdot -4, b \cdot b\right)}}{a \cdot -2}\\


\end{array}\\
t_3 := -\frac{b}{a}\\
t_4 := \sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)}\\
t_5 := \begin{array}{l}
\mathbf{if}\;b \geq 0:\\
\;\;\;\;\frac{2 \cdot c}{\left(-b\right) - t_4}\\

\mathbf{else}:\\
\;\;\;\;\frac{t_4 - b}{2 \cdot a}\\


\end{array}\\
\mathbf{if}\;t_5 \leq -\infty:\\
\;\;\;\;\begin{array}{l}
\mathbf{if}\;b \geq 0:\\
\;\;\;\;\frac{b}{a}\\

\mathbf{else}:\\
\;\;\;\;t_3\\


\end{array}\\

\mathbf{elif}\;t_5 \leq -5 \cdot 10^{-226}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;t_5 \leq 0:\\
\;\;\;\;\begin{array}{l}
\mathbf{if}\;b \geq 0:\\
\;\;\;\;t_0\\

\mathbf{else}:\\
\;\;\;\;\left(b - t_1\right) \cdot \frac{-0.5}{a}\\


\end{array}\\

\mathbf{elif}\;t_5 \leq 5 \cdot 10^{+295}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;b \geq 0:\\
\;\;\;\;t_0\\

\mathbf{else}:\\
\;\;\;\;t_3\\


\end{array}

Error

Derivation

  1. Split input into 4 regimes
  2. if (if (>=.f64 b 0) (/.f64 (*.f64 2 c) (-.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c))))) (/.f64 (+.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c)))) (*.f64 2 a))) < -inf.0

    1. Initial program 64.0

      \[\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\\ \end{array} \]
    2. Simplified64.0

      \[\leadsto \color{blue}{\begin{array}{l} \color{blue}{\mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ } \end{array}} \]
    3. Taylor expanded in b around -inf 15.8

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]
    4. Taylor expanded in c around 0 15.8

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \color{blue}{\left(b + -2 \cdot \frac{c \cdot a}{b}\right)}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]
    5. Simplified15.8

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \color{blue}{\mathsf{fma}\left(-2, \frac{c}{b} \cdot a, b\right)}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]
    6. Taylor expanded in c around inf 15.8

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\color{blue}{\frac{b}{a}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]

    if -inf.0 < (if (>=.f64 b 0) (/.f64 (*.f64 2 c) (-.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c))))) (/.f64 (+.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c)))) (*.f64 2 a))) < -4.9999999999999998e-226 or 0.0 < (if (>=.f64 b 0) (/.f64 (*.f64 2 c) (-.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c))))) (/.f64 (+.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c)))) (*.f64 2 a))) < 4.99999999999999991e295

    1. Initial program 2.7

      \[\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\\ \end{array} \]
    2. Simplified2.8

      \[\leadsto \color{blue}{\begin{array}{l} \color{blue}{\mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ } \end{array}} \]
    3. Applied egg-rr2.7

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{b - \sqrt{\mathsf{fma}\left(c, a \cdot -4, b \cdot b\right)}}{a \cdot -2}\\ \end{array} \]

    if -4.9999999999999998e-226 < (if (>=.f64 b 0) (/.f64 (*.f64 2 c) (-.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c))))) (/.f64 (+.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c)))) (*.f64 2 a))) < 0.0

    1. Initial program 34.7

      \[\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\\ \end{array} \]
    2. Simplified34.7

      \[\leadsto \color{blue}{\begin{array}{l} \color{blue}{\mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ } \end{array}} \]
    3. Taylor expanded in c around 0 12.3

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \color{blue}{\left(b + -2 \cdot \frac{c \cdot a}{b}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ \end{array} \]
    4. Simplified10.4

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \color{blue}{\mathsf{fma}\left(-2, \frac{c}{b} \cdot a, b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ \end{array} \]

    if 4.99999999999999991e295 < (if (>=.f64 b 0) (/.f64 (*.f64 2 c) (-.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c))))) (/.f64 (+.f64 (neg.f64 b) (sqrt.f64 (-.f64 (*.f64 b b) (*.f64 (*.f64 4 a) c)))) (*.f64 2 a)))

    1. Initial program 62.1

      \[\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\\ \end{array} \]
    2. Simplified61.9

      \[\leadsto \color{blue}{\begin{array}{l} \color{blue}{\mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ } \end{array}} \]
    3. Taylor expanded in b around -inf 19.7

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]
    4. Taylor expanded in c around 0 19.7

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \color{blue}{\left(b + -2 \cdot \frac{c \cdot a}{b}\right)}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]
    5. Simplified13.2

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \color{blue}{\mathsf{fma}\left(-2, \frac{c}{b} \cdot a, b\right)}}\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \frac{b}{a}\\ \end{array} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification6.4

    \[\leadsto \begin{array}{l} \mathbf{if}\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)} - b}{2 \cdot a}\\ \end{array} \leq -\infty:\\ \;\;\;\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{b}{a}\\ \mathbf{else}:\\ \;\;\;\;-\frac{b}{a}\\ \end{array}\\ \mathbf{elif}\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)} - b}{2 \cdot a}\\ \end{array} \leq -5 \cdot 10^{-226}:\\ \;\;\;\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{b - \sqrt{\mathsf{fma}\left(c, a \cdot -4, b \cdot b\right)}}{a \cdot -2}\\ \end{array}\\ \mathbf{elif}\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)} - b}{2 \cdot a}\\ \end{array} \leq 0:\\ \;\;\;\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \mathsf{fma}\left(-2, a \cdot \frac{c}{b}, b\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(b - \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}\right) \cdot \frac{-0.5}{a}\\ \end{array}\\ \mathbf{elif}\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{2 \cdot c}{\left(-b\right) - \sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(4 \cdot a\right)} - b}{2 \cdot a}\\ \end{array} \leq 5 \cdot 10^{+295}:\\ \;\;\;\;\begin{array}{l} \mathbf{if}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \sqrt{\mathsf{fma}\left(c, \frac{a}{-0.25}, b \cdot b\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{b - \sqrt{\mathsf{fma}\left(c, a \cdot -4, b \cdot b\right)}}{a \cdot -2}\\ \end{array}\\ \mathbf{elif}\;b \geq 0:\\ \;\;\;\;\frac{c \cdot -2}{b + \mathsf{fma}\left(-2, a \cdot \frac{c}{b}, b\right)}\\ \mathbf{else}:\\ \;\;\;\;-\frac{b}{a}\\ \end{array} \]

Reproduce

herbie shell --seed 2022185 
(FPCore (a b c)
  :name "jeff quadratic root 2"
  :precision binary64
  (if (>= b 0.0) (/ (* 2.0 c) (- (- b) (sqrt (- (* b b) (* (* 4.0 a) c))))) (/ (+ (- b) (sqrt (- (* b b) (* (* 4.0 a) c)))) (* 2.0 a))))