Cubic critical

Percentage Accurate: 52.3% → 86.9%
Time: 16.0s
Alternatives: 11
Speedup: 16.4×

Specification

?
\[\begin{array}{l} \\ \frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (/ (+ (- b) (sqrt (- (* b b) (* (* 3.0 a) c)))) (* 3.0 a)))
double code(double a, double b, double c) {
	return (-b + sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a);
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    code = (-b + sqrt(((b * b) - ((3.0d0 * a) * c)))) / (3.0d0 * a)
end function
public static double code(double a, double b, double c) {
	return (-b + Math.sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a);
}
def code(a, b, c):
	return (-b + math.sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a)
function code(a, b, c)
	return Float64(Float64(Float64(-b) + sqrt(Float64(Float64(b * b) - Float64(Float64(3.0 * a) * c)))) / Float64(3.0 * a))
end
function tmp = code(a, b, c)
	tmp = (-b + sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a);
end
code[a_, b_, c_] := N[(N[((-b) + N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(N[(3.0 * a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / N[(3.0 * a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 11 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 52.3% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (/ (+ (- b) (sqrt (- (* b b) (* (* 3.0 a) c)))) (* 3.0 a)))
double code(double a, double b, double c) {
	return (-b + sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a);
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    code = (-b + sqrt(((b * b) - ((3.0d0 * a) * c)))) / (3.0d0 * a)
end function
public static double code(double a, double b, double c) {
	return (-b + Math.sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a);
}
def code(a, b, c):
	return (-b + math.sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a)
function code(a, b, c)
	return Float64(Float64(Float64(-b) + sqrt(Float64(Float64(b * b) - Float64(Float64(3.0 * a) * c)))) / Float64(3.0 * a))
end
function tmp = code(a, b, c)
	tmp = (-b + sqrt(((b * b) - ((3.0 * a) * c)))) / (3.0 * a);
end
code[a_, b_, c_] := N[(N[((-b) + N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(N[(3.0 * a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / N[(3.0 * a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a}
\end{array}

Alternative 1: 86.9% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -4.5 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 8 \cdot 10^{-149}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{elif}\;b \leq 105000:\\ \;\;\;\;\frac{a \cdot \left(c \cdot -3\right)}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -4.5e+94)
   (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
   (if (<= b 8e-149)
     (/ (- (sqrt (- (* b b) (* c (* a 3.0)))) b) (* a 3.0))
     (if (<= b 105000.0)
       (*
        (/ (* a (* c -3.0)) (+ b (sqrt (fma a (* c -3.0) (pow b 2.0)))))
        (/ 0.3333333333333333 a))
       (/ 1.0 (+ (* -2.0 (/ b c)) (* 1.5 (/ a b))))))))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -4.5e+94) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else if (b <= 8e-149) {
		tmp = (sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	} else if (b <= 105000.0) {
		tmp = ((a * (c * -3.0)) / (b + sqrt(fma(a, (c * -3.0), pow(b, 2.0))))) * (0.3333333333333333 / a);
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
function code(a, b, c)
	tmp = 0.0
	if (b <= -4.5e+94)
		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
	elseif (b <= 8e-149)
		tmp = Float64(Float64(sqrt(Float64(Float64(b * b) - Float64(c * Float64(a * 3.0)))) - b) / Float64(a * 3.0));
	elseif (b <= 105000.0)
		tmp = Float64(Float64(Float64(a * Float64(c * -3.0)) / Float64(b + sqrt(fma(a, Float64(c * -3.0), (b ^ 2.0))))) * Float64(0.3333333333333333 / a));
	else
		tmp = Float64(1.0 / Float64(Float64(-2.0 * Float64(b / c)) + Float64(1.5 * Float64(a / b))));
	end
	return tmp
end
code[a_, b_, c_] := If[LessEqual[b, -4.5e+94], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 8e-149], N[(N[(N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(c * N[(a * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 105000.0], N[(N[(N[(a * N[(c * -3.0), $MachinePrecision]), $MachinePrecision] / N[(b + N[Sqrt[N[(a * N[(c * -3.0), $MachinePrecision] + N[Power[b, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(0.3333333333333333 / a), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(-2.0 * N[(b / c), $MachinePrecision]), $MachinePrecision] + N[(1.5 * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -4.5 \cdot 10^{+94}:\\
\;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\

\mathbf{elif}\;b \leq 8 \cdot 10^{-149}:\\
\;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\

\mathbf{elif}\;b \leq 105000:\\
\;\;\;\;\frac{a \cdot \left(c \cdot -3\right)}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -4.49999999999999972e94

    1. Initial program 59.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Taylor expanded in b around -inf 91.5%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}} \]

    if -4.49999999999999972e94 < b < 7.99999999999999983e-149

    1. Initial program 91.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]

    if 7.99999999999999983e-149 < b < 105000

    1. Initial program 57.1%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Applied egg-rr57.1%

      \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} + \left(-b \cdot \frac{0.3333333333333333}{a}\right)} \]
    3. Step-by-step derivation
      1. sub-neg57.1%

        \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} - b \cdot \frac{0.3333333333333333}{a}} \]
      2. distribute-rgt-out--57.1%

        \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    4. Simplified57.1%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    5. Step-by-step derivation
      1. *-commutative57.1%

        \[\leadsto \color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right) \cdot \frac{0.3333333333333333}{a}} \]
      2. flip--56.8%

        \[\leadsto \color{blue}{\frac{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b \cdot b}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + b}} \cdot \frac{0.3333333333333333}{a} \]
      3. frac-times46.4%

        \[\leadsto \color{blue}{\frac{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b \cdot b\right) \cdot 0.3333333333333333}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + b\right) \cdot a}} \]
      4. add-sqr-sqrt46.3%

        \[\leadsto \frac{\left(\color{blue}{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b \cdot b\right) \cdot 0.3333333333333333}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + b\right) \cdot a} \]
      5. unpow246.3%

        \[\leadsto \frac{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) - \color{blue}{{b}^{2}}\right) \cdot 0.3333333333333333}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + b\right) \cdot a} \]
      6. +-commutative46.3%

        \[\leadsto \frac{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) - {b}^{2}\right) \cdot 0.3333333333333333}{\color{blue}{\left(b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot a} \]
    6. Applied egg-rr46.3%

      \[\leadsto \color{blue}{\frac{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) - {b}^{2}\right) \cdot 0.3333333333333333}{\left(b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot a}} \]
    7. Step-by-step derivation
      1. times-frac56.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) - {b}^{2}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a}} \]
      2. unpow256.7%

        \[\leadsto \frac{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) - \color{blue}{b \cdot b}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      3. sqr-neg56.7%

        \[\leadsto \frac{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) - \color{blue}{\left(-b\right) \cdot \left(-b\right)}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      4. cancel-sign-sub56.7%

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right) + b \cdot \left(-b\right)}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      5. fma-udef56.7%

        \[\leadsto \frac{\color{blue}{\left(a \cdot \left(c \cdot -3\right) + {b}^{2}\right)} + b \cdot \left(-b\right)}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      6. associate-+l+75.6%

        \[\leadsto \frac{\color{blue}{a \cdot \left(c \cdot -3\right) + \left({b}^{2} + b \cdot \left(-b\right)\right)}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      7. unpow275.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \left(\color{blue}{b \cdot b} + b \cdot \left(-b\right)\right)}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      8. distribute-lft-in75.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \color{blue}{b \cdot \left(b + \left(-b\right)\right)}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      9. neg-mul-175.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + b \cdot \left(b + \color{blue}{-1 \cdot b}\right)}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      10. *-commutative75.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \color{blue}{\left(b + -1 \cdot b\right) \cdot b}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      11. distribute-rgt1-in75.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \color{blue}{\left(\left(-1 + 1\right) \cdot b\right)} \cdot b}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      12. metadata-eval75.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \left(\color{blue}{0} \cdot b\right) \cdot b}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      13. mul0-lft75.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \color{blue}{0} \cdot b}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
      14. mul0-lft75.6%

        \[\leadsto \frac{a \cdot \left(c \cdot -3\right) + \color{blue}{0}}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a} \]
    8. Simplified75.6%

      \[\leadsto \color{blue}{\frac{a \cdot \left(c \cdot -3\right) + 0}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a}} \]

    if 105000 < b

    1. Initial program 13.8%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt10.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow210.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/210.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow110.3%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow210.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval10.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr10.3%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num10.3%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow10.3%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative10.3%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-110.3%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow13.8%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval13.8%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/213.8%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def13.8%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr13.8%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-113.8%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified13.8%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in b around inf 93.5%

      \[\leadsto \frac{1}{\color{blue}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification90.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -4.5 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 8 \cdot 10^{-149}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{elif}\;b \leq 105000:\\ \;\;\;\;\frac{a \cdot \left(c \cdot -3\right)}{b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}} \cdot \frac{0.3333333333333333}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \]

Alternative 2: 78.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\ \mathbf{if}\;b \leq -4.5 \cdot 10^{-14}:\\ \;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\ \mathbf{elif}\;b \leq -8 \cdot 10^{-64}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{elif}\;b \leq 3 \cdot 10^{-12}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (let* ((t_0 (/ (- (sqrt (* c (* a -3.0))) b) (* a 3.0))))
   (if (<= b -4.5e-14)
     (/ (+ (* 1.5 (* c (/ a b))) (* b -2.0)) (* a 3.0))
     (if (<= b -8e-64)
       t_0
       (if (<= b -4.5e-133)
         (* b (/ -0.6666666666666666 a))
         (if (<= b 3e-12)
           t_0
           (/ 1.0 (+ (* -2.0 (/ b c)) (* 1.5 (/ a b))))))))))
double code(double a, double b, double c) {
	double t_0 = (sqrt((c * (a * -3.0))) - b) / (a * 3.0);
	double tmp;
	if (b <= -4.5e-14) {
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	} else if (b <= -8e-64) {
		tmp = t_0;
	} else if (b <= -4.5e-133) {
		tmp = b * (-0.6666666666666666 / a);
	} else if (b <= 3e-12) {
		tmp = t_0;
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: t_0
    real(8) :: tmp
    t_0 = (sqrt((c * (a * (-3.0d0)))) - b) / (a * 3.0d0)
    if (b <= (-4.5d-14)) then
        tmp = ((1.5d0 * (c * (a / b))) + (b * (-2.0d0))) / (a * 3.0d0)
    else if (b <= (-8d-64)) then
        tmp = t_0
    else if (b <= (-4.5d-133)) then
        tmp = b * ((-0.6666666666666666d0) / a)
    else if (b <= 3d-12) then
        tmp = t_0
    else
        tmp = 1.0d0 / (((-2.0d0) * (b / c)) + (1.5d0 * (a / b)))
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double t_0 = (Math.sqrt((c * (a * -3.0))) - b) / (a * 3.0);
	double tmp;
	if (b <= -4.5e-14) {
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	} else if (b <= -8e-64) {
		tmp = t_0;
	} else if (b <= -4.5e-133) {
		tmp = b * (-0.6666666666666666 / a);
	} else if (b <= 3e-12) {
		tmp = t_0;
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
def code(a, b, c):
	t_0 = (math.sqrt((c * (a * -3.0))) - b) / (a * 3.0)
	tmp = 0
	if b <= -4.5e-14:
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0)
	elif b <= -8e-64:
		tmp = t_0
	elif b <= -4.5e-133:
		tmp = b * (-0.6666666666666666 / a)
	elif b <= 3e-12:
		tmp = t_0
	else:
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)))
	return tmp
function code(a, b, c)
	t_0 = Float64(Float64(sqrt(Float64(c * Float64(a * -3.0))) - b) / Float64(a * 3.0))
	tmp = 0.0
	if (b <= -4.5e-14)
		tmp = Float64(Float64(Float64(1.5 * Float64(c * Float64(a / b))) + Float64(b * -2.0)) / Float64(a * 3.0));
	elseif (b <= -8e-64)
		tmp = t_0;
	elseif (b <= -4.5e-133)
		tmp = Float64(b * Float64(-0.6666666666666666 / a));
	elseif (b <= 3e-12)
		tmp = t_0;
	else
		tmp = Float64(1.0 / Float64(Float64(-2.0 * Float64(b / c)) + Float64(1.5 * Float64(a / b))));
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	t_0 = (sqrt((c * (a * -3.0))) - b) / (a * 3.0);
	tmp = 0.0;
	if (b <= -4.5e-14)
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	elseif (b <= -8e-64)
		tmp = t_0;
	elseif (b <= -4.5e-133)
		tmp = b * (-0.6666666666666666 / a);
	elseif (b <= 3e-12)
		tmp = t_0;
	else
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := Block[{t$95$0 = N[(N[(N[Sqrt[N[(c * N[(a * -3.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -4.5e-14], N[(N[(N[(1.5 * N[(c * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * -2.0), $MachinePrecision]), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -8e-64], t$95$0, If[LessEqual[b, -4.5e-133], N[(b * N[(-0.6666666666666666 / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3e-12], t$95$0, N[(1.0 / N[(N[(-2.0 * N[(b / c), $MachinePrecision]), $MachinePrecision] + N[(1.5 * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\
\mathbf{if}\;b \leq -4.5 \cdot 10^{-14}:\\
\;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\

\mathbf{elif}\;b \leq -8 \cdot 10^{-64}:\\
\;\;\;\;t_0\\

\mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\
\;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\

\mathbf{elif}\;b \leq 3 \cdot 10^{-12}:\\
\;\;\;\;t_0\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -4.4999999999999998e-14

    1. Initial program 72.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt72.1%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow272.1%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/272.1%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow172.1%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef72.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow272.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval72.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr72.2%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Taylor expanded in b around -inf 82.5%

      \[\leadsto \frac{\color{blue}{2 \cdot \left(-1 \cdot b\right) + 1.5 \cdot \frac{a \cdot c}{b}}}{3 \cdot a} \]
    5. Step-by-step derivation
      1. +-commutative82.5%

        \[\leadsto \frac{\color{blue}{1.5 \cdot \frac{a \cdot c}{b} + 2 \cdot \left(-1 \cdot b\right)}}{3 \cdot a} \]
      2. associate-/l*86.1%

        \[\leadsto \frac{1.5 \cdot \color{blue}{\frac{a}{\frac{b}{c}}} + 2 \cdot \left(-1 \cdot b\right)}{3 \cdot a} \]
      3. associate-/r/86.1%

        \[\leadsto \frac{1.5 \cdot \color{blue}{\left(\frac{a}{b} \cdot c\right)} + 2 \cdot \left(-1 \cdot b\right)}{3 \cdot a} \]
      4. associate-*r*86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{\left(2 \cdot -1\right) \cdot b}}{3 \cdot a} \]
      5. metadata-eval86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{-2} \cdot b}{3 \cdot a} \]
      6. *-commutative86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{b \cdot -2}}{3 \cdot a} \]
    6. Simplified86.1%

      \[\leadsto \frac{\color{blue}{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + b \cdot -2}}{3 \cdot a} \]

    if -4.4999999999999998e-14 < b < -7.99999999999999972e-64 or -4.50000000000000009e-133 < b < 3.0000000000000001e-12

    1. Initial program 81.7%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. prod-diff81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\mathsf{fma}\left(b, b, -c \cdot \left(3 \cdot a\right)\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}}{3 \cdot a} \]
      2. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\mathsf{fma}\left(b, b, -\color{blue}{\left(3 \cdot a\right) \cdot c}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      3. fma-def81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      4. associate-+l+81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{b \cdot b + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}}{3 \cdot a} \]
      5. pow281.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2}} + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      6. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\left(-\color{blue}{c \cdot \left(3 \cdot a\right)}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      7. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      8. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      9. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      10. metadata-eval81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      11. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \mathsf{fma}\left(-c, 3 \cdot a, \color{blue}{\left(3 \cdot a\right) \cdot c}\right)\right)}}{3 \cdot a} \]
      12. fma-udef81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{\left(\left(-c\right) \cdot \left(3 \cdot a\right) + \left(3 \cdot a\right) \cdot c\right)}\right)}}{3 \cdot a} \]
      13. distribute-lft-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{\left(-c \cdot \left(3 \cdot a\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      14. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      15. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      16. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      17. metadata-eval81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      18. associate-*l*81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{3 \cdot \left(a \cdot c\right)}\right)\right)}}{3 \cdot a} \]
    3. Applied egg-rr81.4%

      \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + 3 \cdot \left(a \cdot c\right)\right)\right)}}}{3 \cdot a} \]
    4. Taylor expanded in b around 0 78.6%

      \[\leadsto \frac{\color{blue}{\sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)} + -1 \cdot b}}{3 \cdot a} \]
    5. Step-by-step derivation
      1. neg-mul-178.6%

        \[\leadsto \frac{\sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)} + \color{blue}{\left(-b\right)}}{3 \cdot a} \]
      2. unsub-neg78.6%

        \[\leadsto \frac{\color{blue}{\sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)} - b}}{3 \cdot a} \]
      3. distribute-rgt-out78.9%

        \[\leadsto \frac{\sqrt{\color{blue}{\left(a \cdot c\right) \cdot \left(-6 + 3\right)}} - b}{3 \cdot a} \]
      4. metadata-eval78.9%

        \[\leadsto \frac{\sqrt{\left(a \cdot c\right) \cdot \color{blue}{-3}} - b}{3 \cdot a} \]
      5. *-commutative78.9%

        \[\leadsto \frac{\sqrt{\color{blue}{\left(c \cdot a\right)} \cdot -3} - b}{3 \cdot a} \]
      6. associate-*r*79.0%

        \[\leadsto \frac{\sqrt{\color{blue}{c \cdot \left(a \cdot -3\right)}} - b}{3 \cdot a} \]
    6. Simplified79.0%

      \[\leadsto \frac{\color{blue}{\sqrt{c \cdot \left(a \cdot -3\right)} - b}}{3 \cdot a} \]

    if -7.99999999999999972e-64 < b < -4.50000000000000009e-133

    1. Initial program 89.8%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Applied egg-rr89.6%

      \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} + \left(-b \cdot \frac{0.3333333333333333}{a}\right)} \]
    3. Step-by-step derivation
      1. sub-neg89.6%

        \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} - b \cdot \frac{0.3333333333333333}{a}} \]
      2. distribute-rgt-out--89.6%

        \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    4. Simplified89.6%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    5. Step-by-step derivation
      1. associate-*l/89.3%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)}{a}} \]
      2. *-commutative89.3%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right) \cdot 0.3333333333333333}}{a} \]
      3. sub-neg89.3%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)\right)} \cdot 0.3333333333333333}{a} \]
      4. +-commutative89.3%

        \[\leadsto \frac{\color{blue}{\left(\left(-b\right) + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      5. neg-mul-189.3%

        \[\leadsto \frac{\left(\color{blue}{-1 \cdot b} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot 0.3333333333333333}{a} \]
      6. fma-udef89.3%

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      7. metadata-eval89.3%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot \color{blue}{\frac{1}{3}}}{a} \]
      8. div-inv89.5%

        \[\leadsto \frac{\color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3}}}{a} \]
      9. associate-/r*89.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3 \cdot a}} \]
      10. *-commutative89.8%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{\color{blue}{a \cdot 3}} \]
      11. associate-/r*89.5%

        \[\leadsto \color{blue}{\frac{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{a}}{3}} \]
      12. fma-udef89.5%

        \[\leadsto \frac{\frac{\color{blue}{-1 \cdot b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}{a}}{3} \]
      13. neg-mul-189.5%

        \[\leadsto \frac{\frac{\color{blue}{\left(-b\right)} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}{a}}{3} \]
      14. +-commutative89.5%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)}}{a}}{3} \]
      15. sub-neg89.5%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}}{a}}{3} \]
    6. Applied egg-rr89.5%

      \[\leadsto \color{blue}{\frac{\frac{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}{a}}{3}} \]
    7. Taylor expanded in b around -inf 71.7%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a}} \]
    8. Step-by-step derivation
      1. *-commutative71.7%

        \[\leadsto \color{blue}{\frac{b}{a} \cdot -0.6666666666666666} \]
      2. associate-*l/71.8%

        \[\leadsto \color{blue}{\frac{b \cdot -0.6666666666666666}{a}} \]
      3. associate-*r/72.1%

        \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]
    9. Simplified72.1%

      \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]

    if 3.0000000000000001e-12 < b

    1. Initial program 14.6%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt11.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow211.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/211.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow111.2%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow211.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr11.3%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num11.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow11.2%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative11.2%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-111.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/214.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr14.7%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-114.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified14.7%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in b around inf 91.0%

      \[\leadsto \frac{1}{\color{blue}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification84.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -4.5 \cdot 10^{-14}:\\ \;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\ \mathbf{elif}\;b \leq -8 \cdot 10^{-64}:\\ \;\;\;\;\frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\ \mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{elif}\;b \leq 3 \cdot 10^{-12}:\\ \;\;\;\;\frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \]

Alternative 3: 84.7% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -1.3 \cdot 10^{+97}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 3.2 \cdot 10^{-12}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -1.3e+97)
   (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
   (if (<= b 3.2e-12)
     (/ (- (sqrt (- (* b b) (* c (* a 3.0)))) b) (* a 3.0))
     (/ 1.0 (+ (* -2.0 (/ b c)) (* 1.5 (/ a b)))))))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -1.3e+97) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else if (b <= 3.2e-12) {
		tmp = (sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: tmp
    if (b <= (-1.3d+97)) then
        tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
    else if (b <= 3.2d-12) then
        tmp = (sqrt(((b * b) - (c * (a * 3.0d0)))) - b) / (a * 3.0d0)
    else
        tmp = 1.0d0 / (((-2.0d0) * (b / c)) + (1.5d0 * (a / b)))
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -1.3e+97) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else if (b <= 3.2e-12) {
		tmp = (Math.sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -1.3e+97:
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
	elif b <= 3.2e-12:
		tmp = (math.sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0)
	else:
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)))
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -1.3e+97)
		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
	elseif (b <= 3.2e-12)
		tmp = Float64(Float64(sqrt(Float64(Float64(b * b) - Float64(c * Float64(a * 3.0)))) - b) / Float64(a * 3.0));
	else
		tmp = Float64(1.0 / Float64(Float64(-2.0 * Float64(b / c)) + Float64(1.5 * Float64(a / b))));
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -1.3e+97)
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	elseif (b <= 3.2e-12)
		tmp = (sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	else
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -1.3e+97], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3.2e-12], N[(N[(N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(c * N[(a * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(-2.0 * N[(b / c), $MachinePrecision]), $MachinePrecision] + N[(1.5 * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.3 \cdot 10^{+97}:\\
\;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\

\mathbf{elif}\;b \leq 3.2 \cdot 10^{-12}:\\
\;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -1.3e97

    1. Initial program 59.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Taylor expanded in b around -inf 91.5%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}} \]

    if -1.3e97 < b < 3.2000000000000001e-12

    1. Initial program 86.0%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]

    if 3.2000000000000001e-12 < b

    1. Initial program 14.6%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt11.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow211.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/211.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow111.2%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow211.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr11.3%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num11.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow11.2%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative11.2%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-111.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/214.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr14.7%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-114.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified14.7%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in b around inf 91.0%

      \[\leadsto \frac{1}{\color{blue}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification88.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.3 \cdot 10^{+97}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 3.2 \cdot 10^{-12}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \]

Alternative 4: 78.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := 0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}\\ \mathbf{if}\;b \leq -1.4 \cdot 10^{-17}:\\ \;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\ \mathbf{elif}\;b \leq -5.5 \cdot 10^{-63}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{elif}\;b \leq 3 \cdot 10^{-12}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (let* ((t_0 (* 0.3333333333333333 (/ (sqrt (* c (* a -3.0))) a))))
   (if (<= b -1.4e-17)
     (/ (+ (* 1.5 (* c (/ a b))) (* b -2.0)) (* a 3.0))
     (if (<= b -5.5e-63)
       t_0
       (if (<= b -4.5e-133)
         (* b (/ -0.6666666666666666 a))
         (if (<= b 3e-12)
           t_0
           (/ 1.0 (+ (* -2.0 (/ b c)) (* 1.5 (/ a b))))))))))
double code(double a, double b, double c) {
	double t_0 = 0.3333333333333333 * (sqrt((c * (a * -3.0))) / a);
	double tmp;
	if (b <= -1.4e-17) {
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	} else if (b <= -5.5e-63) {
		tmp = t_0;
	} else if (b <= -4.5e-133) {
		tmp = b * (-0.6666666666666666 / a);
	} else if (b <= 3e-12) {
		tmp = t_0;
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: t_0
    real(8) :: tmp
    t_0 = 0.3333333333333333d0 * (sqrt((c * (a * (-3.0d0)))) / a)
    if (b <= (-1.4d-17)) then
        tmp = ((1.5d0 * (c * (a / b))) + (b * (-2.0d0))) / (a * 3.0d0)
    else if (b <= (-5.5d-63)) then
        tmp = t_0
    else if (b <= (-4.5d-133)) then
        tmp = b * ((-0.6666666666666666d0) / a)
    else if (b <= 3d-12) then
        tmp = t_0
    else
        tmp = 1.0d0 / (((-2.0d0) * (b / c)) + (1.5d0 * (a / b)))
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double t_0 = 0.3333333333333333 * (Math.sqrt((c * (a * -3.0))) / a);
	double tmp;
	if (b <= -1.4e-17) {
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	} else if (b <= -5.5e-63) {
		tmp = t_0;
	} else if (b <= -4.5e-133) {
		tmp = b * (-0.6666666666666666 / a);
	} else if (b <= 3e-12) {
		tmp = t_0;
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
def code(a, b, c):
	t_0 = 0.3333333333333333 * (math.sqrt((c * (a * -3.0))) / a)
	tmp = 0
	if b <= -1.4e-17:
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0)
	elif b <= -5.5e-63:
		tmp = t_0
	elif b <= -4.5e-133:
		tmp = b * (-0.6666666666666666 / a)
	elif b <= 3e-12:
		tmp = t_0
	else:
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)))
	return tmp
function code(a, b, c)
	t_0 = Float64(0.3333333333333333 * Float64(sqrt(Float64(c * Float64(a * -3.0))) / a))
	tmp = 0.0
	if (b <= -1.4e-17)
		tmp = Float64(Float64(Float64(1.5 * Float64(c * Float64(a / b))) + Float64(b * -2.0)) / Float64(a * 3.0));
	elseif (b <= -5.5e-63)
		tmp = t_0;
	elseif (b <= -4.5e-133)
		tmp = Float64(b * Float64(-0.6666666666666666 / a));
	elseif (b <= 3e-12)
		tmp = t_0;
	else
		tmp = Float64(1.0 / Float64(Float64(-2.0 * Float64(b / c)) + Float64(1.5 * Float64(a / b))));
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	t_0 = 0.3333333333333333 * (sqrt((c * (a * -3.0))) / a);
	tmp = 0.0;
	if (b <= -1.4e-17)
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	elseif (b <= -5.5e-63)
		tmp = t_0;
	elseif (b <= -4.5e-133)
		tmp = b * (-0.6666666666666666 / a);
	elseif (b <= 3e-12)
		tmp = t_0;
	else
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := Block[{t$95$0 = N[(0.3333333333333333 * N[(N[Sqrt[N[(c * N[(a * -3.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.4e-17], N[(N[(N[(1.5 * N[(c * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * -2.0), $MachinePrecision]), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -5.5e-63], t$95$0, If[LessEqual[b, -4.5e-133], N[(b * N[(-0.6666666666666666 / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3e-12], t$95$0, N[(1.0 / N[(N[(-2.0 * N[(b / c), $MachinePrecision]), $MachinePrecision] + N[(1.5 * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := 0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}\\
\mathbf{if}\;b \leq -1.4 \cdot 10^{-17}:\\
\;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\

\mathbf{elif}\;b \leq -5.5 \cdot 10^{-63}:\\
\;\;\;\;t_0\\

\mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\
\;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\

\mathbf{elif}\;b \leq 3 \cdot 10^{-12}:\\
\;\;\;\;t_0\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -1.3999999999999999e-17

    1. Initial program 72.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt72.1%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow272.1%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/272.1%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow172.1%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef72.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow272.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval72.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr72.2%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Taylor expanded in b around -inf 82.5%

      \[\leadsto \frac{\color{blue}{2 \cdot \left(-1 \cdot b\right) + 1.5 \cdot \frac{a \cdot c}{b}}}{3 \cdot a} \]
    5. Step-by-step derivation
      1. +-commutative82.5%

        \[\leadsto \frac{\color{blue}{1.5 \cdot \frac{a \cdot c}{b} + 2 \cdot \left(-1 \cdot b\right)}}{3 \cdot a} \]
      2. associate-/l*86.1%

        \[\leadsto \frac{1.5 \cdot \color{blue}{\frac{a}{\frac{b}{c}}} + 2 \cdot \left(-1 \cdot b\right)}{3 \cdot a} \]
      3. associate-/r/86.1%

        \[\leadsto \frac{1.5 \cdot \color{blue}{\left(\frac{a}{b} \cdot c\right)} + 2 \cdot \left(-1 \cdot b\right)}{3 \cdot a} \]
      4. associate-*r*86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{\left(2 \cdot -1\right) \cdot b}}{3 \cdot a} \]
      5. metadata-eval86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{-2} \cdot b}{3 \cdot a} \]
      6. *-commutative86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{b \cdot -2}}{3 \cdot a} \]
    6. Simplified86.1%

      \[\leadsto \frac{\color{blue}{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + b \cdot -2}}{3 \cdot a} \]

    if -1.3999999999999999e-17 < b < -5.50000000000000043e-63 or -4.50000000000000009e-133 < b < 3.0000000000000001e-12

    1. Initial program 81.7%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. prod-diff81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\mathsf{fma}\left(b, b, -c \cdot \left(3 \cdot a\right)\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}}{3 \cdot a} \]
      2. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\mathsf{fma}\left(b, b, -\color{blue}{\left(3 \cdot a\right) \cdot c}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      3. fma-def81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      4. associate-+l+81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{b \cdot b + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}}{3 \cdot a} \]
      5. pow281.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2}} + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      6. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\left(-\color{blue}{c \cdot \left(3 \cdot a\right)}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      7. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      8. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      9. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      10. metadata-eval81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      11. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \mathsf{fma}\left(-c, 3 \cdot a, \color{blue}{\left(3 \cdot a\right) \cdot c}\right)\right)}}{3 \cdot a} \]
      12. fma-udef81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{\left(\left(-c\right) \cdot \left(3 \cdot a\right) + \left(3 \cdot a\right) \cdot c\right)}\right)}}{3 \cdot a} \]
      13. distribute-lft-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{\left(-c \cdot \left(3 \cdot a\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      14. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      15. *-commutative81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      16. distribute-rgt-neg-in81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      17. metadata-eval81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      18. associate-*l*81.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{3 \cdot \left(a \cdot c\right)}\right)\right)}}{3 \cdot a} \]
    3. Applied egg-rr81.4%

      \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + 3 \cdot \left(a \cdot c\right)\right)\right)}}}{3 \cdot a} \]
    4. Taylor expanded in b around 0 77.6%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \left(\frac{1}{a} \cdot \sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}\right)} \]
    5. Step-by-step derivation
      1. associate-*l/77.8%

        \[\leadsto 0.3333333333333333 \cdot \color{blue}{\frac{1 \cdot \sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}}{a}} \]
      2. *-lft-identity77.8%

        \[\leadsto 0.3333333333333333 \cdot \frac{\color{blue}{\sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}}}{a} \]
      3. distribute-rgt-out78.0%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\color{blue}{\left(a \cdot c\right) \cdot \left(-6 + 3\right)}}}{a} \]
      4. metadata-eval78.0%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\left(a \cdot c\right) \cdot \color{blue}{-3}}}{a} \]
      5. *-commutative78.0%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\color{blue}{\left(c \cdot a\right)} \cdot -3}}{a} \]
      6. associate-*r*78.0%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\color{blue}{c \cdot \left(a \cdot -3\right)}}}{a} \]
    6. Simplified78.0%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}} \]

    if -5.50000000000000043e-63 < b < -4.50000000000000009e-133

    1. Initial program 89.8%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Applied egg-rr89.6%

      \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} + \left(-b \cdot \frac{0.3333333333333333}{a}\right)} \]
    3. Step-by-step derivation
      1. sub-neg89.6%

        \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} - b \cdot \frac{0.3333333333333333}{a}} \]
      2. distribute-rgt-out--89.6%

        \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    4. Simplified89.6%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    5. Step-by-step derivation
      1. associate-*l/89.3%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)}{a}} \]
      2. *-commutative89.3%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right) \cdot 0.3333333333333333}}{a} \]
      3. sub-neg89.3%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)\right)} \cdot 0.3333333333333333}{a} \]
      4. +-commutative89.3%

        \[\leadsto \frac{\color{blue}{\left(\left(-b\right) + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      5. neg-mul-189.3%

        \[\leadsto \frac{\left(\color{blue}{-1 \cdot b} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot 0.3333333333333333}{a} \]
      6. fma-udef89.3%

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      7. metadata-eval89.3%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot \color{blue}{\frac{1}{3}}}{a} \]
      8. div-inv89.5%

        \[\leadsto \frac{\color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3}}}{a} \]
      9. associate-/r*89.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3 \cdot a}} \]
      10. *-commutative89.8%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{\color{blue}{a \cdot 3}} \]
      11. associate-/r*89.5%

        \[\leadsto \color{blue}{\frac{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{a}}{3}} \]
      12. fma-udef89.5%

        \[\leadsto \frac{\frac{\color{blue}{-1 \cdot b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}{a}}{3} \]
      13. neg-mul-189.5%

        \[\leadsto \frac{\frac{\color{blue}{\left(-b\right)} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}{a}}{3} \]
      14. +-commutative89.5%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)}}{a}}{3} \]
      15. sub-neg89.5%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}}{a}}{3} \]
    6. Applied egg-rr89.5%

      \[\leadsto \color{blue}{\frac{\frac{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}{a}}{3}} \]
    7. Taylor expanded in b around -inf 71.7%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a}} \]
    8. Step-by-step derivation
      1. *-commutative71.7%

        \[\leadsto \color{blue}{\frac{b}{a} \cdot -0.6666666666666666} \]
      2. associate-*l/71.8%

        \[\leadsto \color{blue}{\frac{b \cdot -0.6666666666666666}{a}} \]
      3. associate-*r/72.1%

        \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]
    9. Simplified72.1%

      \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]

    if 3.0000000000000001e-12 < b

    1. Initial program 14.6%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt11.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow211.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/211.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow111.2%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow211.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr11.3%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num11.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow11.2%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative11.2%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-111.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/214.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr14.7%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-114.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified14.7%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in b around inf 91.0%

      \[\leadsto \frac{1}{\color{blue}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification84.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.4 \cdot 10^{-17}:\\ \;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\ \mathbf{elif}\;b \leq -5.5 \cdot 10^{-63}:\\ \;\;\;\;0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}\\ \mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{elif}\;b \leq 3 \cdot 10^{-12}:\\ \;\;\;\;0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \]

Alternative 5: 78.5% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt{c \cdot \left(a \cdot -3\right)}\\ \mathbf{if}\;b \leq -1.9 \cdot 10^{-17}:\\ \;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\ \mathbf{elif}\;b \leq -7.8 \cdot 10^{-64}:\\ \;\;\;\;t_0 \cdot \left(0.3333333333333333 \cdot \frac{1}{a}\right)\\ \mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{elif}\;b \leq 5.5 \cdot 10^{-11}:\\ \;\;\;\;0.3333333333333333 \cdot \frac{t_0}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (let* ((t_0 (sqrt (* c (* a -3.0)))))
   (if (<= b -1.9e-17)
     (/ (+ (* 1.5 (* c (/ a b))) (* b -2.0)) (* a 3.0))
     (if (<= b -7.8e-64)
       (* t_0 (* 0.3333333333333333 (/ 1.0 a)))
       (if (<= b -4.5e-133)
         (* b (/ -0.6666666666666666 a))
         (if (<= b 5.5e-11)
           (* 0.3333333333333333 (/ t_0 a))
           (/ 1.0 (+ (* -2.0 (/ b c)) (* 1.5 (/ a b))))))))))
double code(double a, double b, double c) {
	double t_0 = sqrt((c * (a * -3.0)));
	double tmp;
	if (b <= -1.9e-17) {
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	} else if (b <= -7.8e-64) {
		tmp = t_0 * (0.3333333333333333 * (1.0 / a));
	} else if (b <= -4.5e-133) {
		tmp = b * (-0.6666666666666666 / a);
	} else if (b <= 5.5e-11) {
		tmp = 0.3333333333333333 * (t_0 / a);
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: t_0
    real(8) :: tmp
    t_0 = sqrt((c * (a * (-3.0d0))))
    if (b <= (-1.9d-17)) then
        tmp = ((1.5d0 * (c * (a / b))) + (b * (-2.0d0))) / (a * 3.0d0)
    else if (b <= (-7.8d-64)) then
        tmp = t_0 * (0.3333333333333333d0 * (1.0d0 / a))
    else if (b <= (-4.5d-133)) then
        tmp = b * ((-0.6666666666666666d0) / a)
    else if (b <= 5.5d-11) then
        tmp = 0.3333333333333333d0 * (t_0 / a)
    else
        tmp = 1.0d0 / (((-2.0d0) * (b / c)) + (1.5d0 * (a / b)))
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double t_0 = Math.sqrt((c * (a * -3.0)));
	double tmp;
	if (b <= -1.9e-17) {
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	} else if (b <= -7.8e-64) {
		tmp = t_0 * (0.3333333333333333 * (1.0 / a));
	} else if (b <= -4.5e-133) {
		tmp = b * (-0.6666666666666666 / a);
	} else if (b <= 5.5e-11) {
		tmp = 0.3333333333333333 * (t_0 / a);
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
def code(a, b, c):
	t_0 = math.sqrt((c * (a * -3.0)))
	tmp = 0
	if b <= -1.9e-17:
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0)
	elif b <= -7.8e-64:
		tmp = t_0 * (0.3333333333333333 * (1.0 / a))
	elif b <= -4.5e-133:
		tmp = b * (-0.6666666666666666 / a)
	elif b <= 5.5e-11:
		tmp = 0.3333333333333333 * (t_0 / a)
	else:
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)))
	return tmp
function code(a, b, c)
	t_0 = sqrt(Float64(c * Float64(a * -3.0)))
	tmp = 0.0
	if (b <= -1.9e-17)
		tmp = Float64(Float64(Float64(1.5 * Float64(c * Float64(a / b))) + Float64(b * -2.0)) / Float64(a * 3.0));
	elseif (b <= -7.8e-64)
		tmp = Float64(t_0 * Float64(0.3333333333333333 * Float64(1.0 / a)));
	elseif (b <= -4.5e-133)
		tmp = Float64(b * Float64(-0.6666666666666666 / a));
	elseif (b <= 5.5e-11)
		tmp = Float64(0.3333333333333333 * Float64(t_0 / a));
	else
		tmp = Float64(1.0 / Float64(Float64(-2.0 * Float64(b / c)) + Float64(1.5 * Float64(a / b))));
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	t_0 = sqrt((c * (a * -3.0)));
	tmp = 0.0;
	if (b <= -1.9e-17)
		tmp = ((1.5 * (c * (a / b))) + (b * -2.0)) / (a * 3.0);
	elseif (b <= -7.8e-64)
		tmp = t_0 * (0.3333333333333333 * (1.0 / a));
	elseif (b <= -4.5e-133)
		tmp = b * (-0.6666666666666666 / a);
	elseif (b <= 5.5e-11)
		tmp = 0.3333333333333333 * (t_0 / a);
	else
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := Block[{t$95$0 = N[Sqrt[N[(c * N[(a * -3.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[b, -1.9e-17], N[(N[(N[(1.5 * N[(c * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * -2.0), $MachinePrecision]), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -7.8e-64], N[(t$95$0 * N[(0.3333333333333333 * N[(1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -4.5e-133], N[(b * N[(-0.6666666666666666 / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 5.5e-11], N[(0.3333333333333333 * N[(t$95$0 / a), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(-2.0 * N[(b / c), $MachinePrecision]), $MachinePrecision] + N[(1.5 * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt{c \cdot \left(a \cdot -3\right)}\\
\mathbf{if}\;b \leq -1.9 \cdot 10^{-17}:\\
\;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\

\mathbf{elif}\;b \leq -7.8 \cdot 10^{-64}:\\
\;\;\;\;t_0 \cdot \left(0.3333333333333333 \cdot \frac{1}{a}\right)\\

\mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\
\;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\

\mathbf{elif}\;b \leq 5.5 \cdot 10^{-11}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{t_0}{a}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if b < -1.9000000000000001e-17

    1. Initial program 72.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt72.1%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow272.1%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/272.1%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow172.1%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative72.1%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef72.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow272.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval72.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr72.2%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Taylor expanded in b around -inf 82.5%

      \[\leadsto \frac{\color{blue}{2 \cdot \left(-1 \cdot b\right) + 1.5 \cdot \frac{a \cdot c}{b}}}{3 \cdot a} \]
    5. Step-by-step derivation
      1. +-commutative82.5%

        \[\leadsto \frac{\color{blue}{1.5 \cdot \frac{a \cdot c}{b} + 2 \cdot \left(-1 \cdot b\right)}}{3 \cdot a} \]
      2. associate-/l*86.1%

        \[\leadsto \frac{1.5 \cdot \color{blue}{\frac{a}{\frac{b}{c}}} + 2 \cdot \left(-1 \cdot b\right)}{3 \cdot a} \]
      3. associate-/r/86.1%

        \[\leadsto \frac{1.5 \cdot \color{blue}{\left(\frac{a}{b} \cdot c\right)} + 2 \cdot \left(-1 \cdot b\right)}{3 \cdot a} \]
      4. associate-*r*86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{\left(2 \cdot -1\right) \cdot b}}{3 \cdot a} \]
      5. metadata-eval86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{-2} \cdot b}{3 \cdot a} \]
      6. *-commutative86.1%

        \[\leadsto \frac{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + \color{blue}{b \cdot -2}}{3 \cdot a} \]
    6. Simplified86.1%

      \[\leadsto \frac{\color{blue}{1.5 \cdot \left(\frac{a}{b} \cdot c\right) + b \cdot -2}}{3 \cdot a} \]

    if -1.9000000000000001e-17 < b < -7.7999999999999994e-64

    1. Initial program 99.4%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. prod-diff99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\mathsf{fma}\left(b, b, -c \cdot \left(3 \cdot a\right)\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}}{3 \cdot a} \]
      2. *-commutative99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\mathsf{fma}\left(b, b, -\color{blue}{\left(3 \cdot a\right) \cdot c}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      3. fma-def99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      4. associate-+l+99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{b \cdot b + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}}{3 \cdot a} \]
      5. pow299.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2}} + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      6. *-commutative99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\left(-\color{blue}{c \cdot \left(3 \cdot a\right)}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      7. distribute-rgt-neg-in99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      8. *-commutative99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      9. distribute-rgt-neg-in99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      10. metadata-eval99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      11. *-commutative99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \mathsf{fma}\left(-c, 3 \cdot a, \color{blue}{\left(3 \cdot a\right) \cdot c}\right)\right)}}{3 \cdot a} \]
      12. fma-udef99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{\left(\left(-c\right) \cdot \left(3 \cdot a\right) + \left(3 \cdot a\right) \cdot c\right)}\right)}}{3 \cdot a} \]
      13. distribute-lft-neg-in99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{\left(-c \cdot \left(3 \cdot a\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      14. distribute-rgt-neg-in99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      15. *-commutative99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      16. distribute-rgt-neg-in99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      17. metadata-eval99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      18. associate-*l*99.4%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{3 \cdot \left(a \cdot c\right)}\right)\right)}}{3 \cdot a} \]
    3. Applied egg-rr99.4%

      \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + 3 \cdot \left(a \cdot c\right)\right)\right)}}}{3 \cdot a} \]
    4. Taylor expanded in b around 0 98.8%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \left(\frac{1}{a} \cdot \sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}\right)} \]
    5. Step-by-step derivation
      1. associate-*r*99.4%

        \[\leadsto \color{blue}{\left(0.3333333333333333 \cdot \frac{1}{a}\right) \cdot \sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}} \]
      2. distribute-rgt-out99.4%

        \[\leadsto \left(0.3333333333333333 \cdot \frac{1}{a}\right) \cdot \sqrt{\color{blue}{\left(a \cdot c\right) \cdot \left(-6 + 3\right)}} \]
      3. metadata-eval99.4%

        \[\leadsto \left(0.3333333333333333 \cdot \frac{1}{a}\right) \cdot \sqrt{\left(a \cdot c\right) \cdot \color{blue}{-3}} \]
      4. *-commutative99.4%

        \[\leadsto \left(0.3333333333333333 \cdot \frac{1}{a}\right) \cdot \sqrt{\color{blue}{\left(c \cdot a\right)} \cdot -3} \]
      5. associate-*r*99.1%

        \[\leadsto \left(0.3333333333333333 \cdot \frac{1}{a}\right) \cdot \sqrt{\color{blue}{c \cdot \left(a \cdot -3\right)}} \]
    6. Simplified99.1%

      \[\leadsto \color{blue}{\left(0.3333333333333333 \cdot \frac{1}{a}\right) \cdot \sqrt{c \cdot \left(a \cdot -3\right)}} \]

    if -7.7999999999999994e-64 < b < -4.50000000000000009e-133

    1. Initial program 89.8%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Applied egg-rr89.6%

      \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} + \left(-b \cdot \frac{0.3333333333333333}{a}\right)} \]
    3. Step-by-step derivation
      1. sub-neg89.6%

        \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} - b \cdot \frac{0.3333333333333333}{a}} \]
      2. distribute-rgt-out--89.6%

        \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    4. Simplified89.6%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    5. Step-by-step derivation
      1. associate-*l/89.3%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)}{a}} \]
      2. *-commutative89.3%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right) \cdot 0.3333333333333333}}{a} \]
      3. sub-neg89.3%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)\right)} \cdot 0.3333333333333333}{a} \]
      4. +-commutative89.3%

        \[\leadsto \frac{\color{blue}{\left(\left(-b\right) + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      5. neg-mul-189.3%

        \[\leadsto \frac{\left(\color{blue}{-1 \cdot b} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot 0.3333333333333333}{a} \]
      6. fma-udef89.3%

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      7. metadata-eval89.3%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot \color{blue}{\frac{1}{3}}}{a} \]
      8. div-inv89.5%

        \[\leadsto \frac{\color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3}}}{a} \]
      9. associate-/r*89.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3 \cdot a}} \]
      10. *-commutative89.8%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{\color{blue}{a \cdot 3}} \]
      11. associate-/r*89.5%

        \[\leadsto \color{blue}{\frac{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{a}}{3}} \]
      12. fma-udef89.5%

        \[\leadsto \frac{\frac{\color{blue}{-1 \cdot b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}{a}}{3} \]
      13. neg-mul-189.5%

        \[\leadsto \frac{\frac{\color{blue}{\left(-b\right)} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}{a}}{3} \]
      14. +-commutative89.5%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)}}{a}}{3} \]
      15. sub-neg89.5%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}}{a}}{3} \]
    6. Applied egg-rr89.5%

      \[\leadsto \color{blue}{\frac{\frac{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}{a}}{3}} \]
    7. Taylor expanded in b around -inf 71.7%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a}} \]
    8. Step-by-step derivation
      1. *-commutative71.7%

        \[\leadsto \color{blue}{\frac{b}{a} \cdot -0.6666666666666666} \]
      2. associate-*l/71.8%

        \[\leadsto \color{blue}{\frac{b \cdot -0.6666666666666666}{a}} \]
      3. associate-*r/72.1%

        \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]
    9. Simplified72.1%

      \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]

    if -4.50000000000000009e-133 < b < 5.49999999999999975e-11

    1. Initial program 80.5%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. prod-diff80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\mathsf{fma}\left(b, b, -c \cdot \left(3 \cdot a\right)\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}}{3 \cdot a} \]
      2. *-commutative80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\mathsf{fma}\left(b, b, -\color{blue}{\left(3 \cdot a\right) \cdot c}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      3. fma-def80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)}}{3 \cdot a} \]
      4. associate-+l+80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{b \cdot b + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}}{3 \cdot a} \]
      5. pow280.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2}} + \left(\left(-\left(3 \cdot a\right) \cdot c\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      6. *-commutative80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\left(-\color{blue}{c \cdot \left(3 \cdot a\right)}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      7. distribute-rgt-neg-in80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      8. *-commutative80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      9. distribute-rgt-neg-in80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      10. metadata-eval80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \mathsf{fma}\left(-c, 3 \cdot a, c \cdot \left(3 \cdot a\right)\right)\right)}}{3 \cdot a} \]
      11. *-commutative80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \mathsf{fma}\left(-c, 3 \cdot a, \color{blue}{\left(3 \cdot a\right) \cdot c}\right)\right)}}{3 \cdot a} \]
      12. fma-udef80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{\left(\left(-c\right) \cdot \left(3 \cdot a\right) + \left(3 \cdot a\right) \cdot c\right)}\right)}}{3 \cdot a} \]
      13. distribute-lft-neg-in80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{\left(-c \cdot \left(3 \cdot a\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      14. distribute-rgt-neg-in80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(\color{blue}{c \cdot \left(-3 \cdot a\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      15. *-commutative80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(-\color{blue}{a \cdot 3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      16. distribute-rgt-neg-in80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \color{blue}{\left(a \cdot \left(-3\right)\right)} + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      17. metadata-eval80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot \color{blue}{-3}\right) + \left(3 \cdot a\right) \cdot c\right)\right)}}{3 \cdot a} \]
      18. associate-*l*80.2%

        \[\leadsto \frac{\left(-b\right) + \sqrt{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + \color{blue}{3 \cdot \left(a \cdot c\right)}\right)\right)}}{3 \cdot a} \]
    3. Applied egg-rr80.2%

      \[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2} + \left(c \cdot \left(a \cdot -3\right) + \left(c \cdot \left(a \cdot -3\right) + 3 \cdot \left(a \cdot c\right)\right)\right)}}}{3 \cdot a} \]
    4. Taylor expanded in b around 0 76.2%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \left(\frac{1}{a} \cdot \sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}\right)} \]
    5. Step-by-step derivation
      1. associate-*l/76.3%

        \[\leadsto 0.3333333333333333 \cdot \color{blue}{\frac{1 \cdot \sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}}{a}} \]
      2. *-lft-identity76.3%

        \[\leadsto 0.3333333333333333 \cdot \frac{\color{blue}{\sqrt{-6 \cdot \left(a \cdot c\right) + 3 \cdot \left(a \cdot c\right)}}}{a} \]
      3. distribute-rgt-out76.6%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\color{blue}{\left(a \cdot c\right) \cdot \left(-6 + 3\right)}}}{a} \]
      4. metadata-eval76.6%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\left(a \cdot c\right) \cdot \color{blue}{-3}}}{a} \]
      5. *-commutative76.6%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\color{blue}{\left(c \cdot a\right)} \cdot -3}}{a} \]
      6. associate-*r*76.6%

        \[\leadsto 0.3333333333333333 \cdot \frac{\sqrt{\color{blue}{c \cdot \left(a \cdot -3\right)}}}{a} \]
    6. Simplified76.6%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}} \]

    if 5.49999999999999975e-11 < b

    1. Initial program 14.6%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt11.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow211.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/211.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow111.2%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative11.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow211.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval11.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr11.3%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num11.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow11.2%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative11.2%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-111.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/214.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def14.7%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr14.7%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-114.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified14.7%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in b around inf 91.0%

      \[\leadsto \frac{1}{\color{blue}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification84.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.9 \cdot 10^{-17}:\\ \;\;\;\;\frac{1.5 \cdot \left(c \cdot \frac{a}{b}\right) + b \cdot -2}{a \cdot 3}\\ \mathbf{elif}\;b \leq -7.8 \cdot 10^{-64}:\\ \;\;\;\;\sqrt{c \cdot \left(a \cdot -3\right)} \cdot \left(0.3333333333333333 \cdot \frac{1}{a}\right)\\ \mathbf{elif}\;b \leq -4.5 \cdot 10^{-133}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{elif}\;b \leq 5.5 \cdot 10^{-11}:\\ \;\;\;\;0.3333333333333333 \cdot \frac{\sqrt{c \cdot \left(a \cdot -3\right)}}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \]

Alternative 6: 67.2% accurate, 7.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -2.05 \cdot 10^{-268}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -2.05e-268)
   (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
   (/ 1.0 (+ (* -2.0 (/ b c)) (* 1.5 (/ a b))))))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -2.05e-268) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: tmp
    if (b <= (-2.05d-268)) then
        tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
    else
        tmp = 1.0d0 / (((-2.0d0) * (b / c)) + (1.5d0 * (a / b)))
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -2.05e-268) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else {
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -2.05e-268:
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
	else:
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)))
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -2.05e-268)
		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
	else
		tmp = Float64(1.0 / Float64(Float64(-2.0 * Float64(b / c)) + Float64(1.5 * Float64(a / b))));
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -2.05e-268)
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	else
		tmp = 1.0 / ((-2.0 * (b / c)) + (1.5 * (a / b)));
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -2.05e-268], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(-2.0 * N[(b / c), $MachinePrecision]), $MachinePrecision] + N[(1.5 * N[(a / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -2.05 \cdot 10^{-268}:\\
\;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -2.0499999999999999e-268

    1. Initial program 77.1%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Taylor expanded in b around -inf 70.0%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}} \]

    if -2.0499999999999999e-268 < b

    1. Initial program 42.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt40.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow240.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/240.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow140.3%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow240.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval40.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr40.3%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num40.3%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow40.3%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative40.3%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-140.3%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow42.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval42.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/242.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def42.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr42.2%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-142.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified42.2%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in b around inf 58.6%

      \[\leadsto \frac{1}{\color{blue}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification64.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2.05 \cdot 10^{-268}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{-2 \cdot \frac{b}{c} + 1.5 \cdot \frac{a}{b}}\\ \end{array} \]

Alternative 7: 23.8% accurate, 16.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -1.4 \cdot 10^{-291}:\\ \;\;\;\;\frac{b}{a} \cdot -0.3333333333333333\\ \mathbf{else}:\\ \;\;\;\;\frac{0}{a}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -1.4e-291) (* (/ b a) -0.3333333333333333) (/ 0.0 a)))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -1.4e-291) {
		tmp = (b / a) * -0.3333333333333333;
	} else {
		tmp = 0.0 / a;
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: tmp
    if (b <= (-1.4d-291)) then
        tmp = (b / a) * (-0.3333333333333333d0)
    else
        tmp = 0.0d0 / a
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -1.4e-291) {
		tmp = (b / a) * -0.3333333333333333;
	} else {
		tmp = 0.0 / a;
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -1.4e-291:
		tmp = (b / a) * -0.3333333333333333
	else:
		tmp = 0.0 / a
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -1.4e-291)
		tmp = Float64(Float64(b / a) * -0.3333333333333333);
	else
		tmp = Float64(0.0 / a);
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -1.4e-291)
		tmp = (b / a) * -0.3333333333333333;
	else
		tmp = 0.0 / a;
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -1.4e-291], N[(N[(b / a), $MachinePrecision] * -0.3333333333333333), $MachinePrecision], N[(0.0 / a), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.4 \cdot 10^{-291}:\\
\;\;\;\;\frac{b}{a} \cdot -0.3333333333333333\\

\mathbf{else}:\\
\;\;\;\;\frac{0}{a}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -1.4e-291

    1. Initial program 77.6%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt77.3%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow277.3%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/277.3%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow177.3%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative77.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef77.4%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow277.4%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval77.4%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr77.4%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Taylor expanded in b around inf 30.7%

      \[\leadsto \color{blue}{-0.3333333333333333 \cdot \frac{b}{a}} \]

    if -1.4e-291 < b

    1. Initial program 40.8%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt38.7%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow238.7%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/238.7%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow138.8%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*38.7%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative38.7%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow238.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval38.8%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr38.8%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num38.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow38.7%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative38.7%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-138.7%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow40.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval40.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/240.7%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def40.7%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr40.7%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-140.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified40.7%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in a around 0 16.9%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \frac{b + -1 \cdot b}{a}} \]
    9. Step-by-step derivation
      1. associate-*r/16.9%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(b + -1 \cdot b\right)}{a}} \]
      2. distribute-rgt1-in16.9%

        \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{\left(\left(-1 + 1\right) \cdot b\right)}}{a} \]
      3. metadata-eval16.9%

        \[\leadsto \frac{0.3333333333333333 \cdot \left(\color{blue}{0} \cdot b\right)}{a} \]
      4. mul0-lft16.9%

        \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{0}}{a} \]
      5. metadata-eval16.9%

        \[\leadsto \frac{\color{blue}{0}}{a} \]
    10. Simplified16.9%

      \[\leadsto \color{blue}{\frac{0}{a}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification24.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.4 \cdot 10^{-291}:\\ \;\;\;\;\frac{b}{a} \cdot -0.3333333333333333\\ \mathbf{else}:\\ \;\;\;\;\frac{0}{a}\\ \end{array} \]

Alternative 8: 43.4% accurate, 16.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{0}{a}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -5e-310) (* b (/ -0.6666666666666666 a)) (/ 0.0 a)))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -5e-310) {
		tmp = b * (-0.6666666666666666 / a);
	} else {
		tmp = 0.0 / a;
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: tmp
    if (b <= (-5d-310)) then
        tmp = b * ((-0.6666666666666666d0) / a)
    else
        tmp = 0.0d0 / a
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -5e-310) {
		tmp = b * (-0.6666666666666666 / a);
	} else {
		tmp = 0.0 / a;
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -5e-310:
		tmp = b * (-0.6666666666666666 / a)
	else:
		tmp = 0.0 / a
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -5e-310)
		tmp = Float64(b * Float64(-0.6666666666666666 / a));
	else
		tmp = Float64(0.0 / a);
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -5e-310)
		tmp = b * (-0.6666666666666666 / a);
	else
		tmp = 0.0 / a;
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -5e-310], N[(b * N[(-0.6666666666666666 / a), $MachinePrecision]), $MachinePrecision], N[(0.0 / a), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\
\;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\

\mathbf{else}:\\
\;\;\;\;\frac{0}{a}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -4.999999999999985e-310

    1. Initial program 77.7%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Applied egg-rr77.6%

      \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} + \left(-b \cdot \frac{0.3333333333333333}{a}\right)} \]
    3. Step-by-step derivation
      1. sub-neg77.6%

        \[\leadsto \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} \cdot \frac{0.3333333333333333}{a} - b \cdot \frac{0.3333333333333333}{a}} \]
      2. distribute-rgt-out--77.6%

        \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    4. Simplified77.6%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{a} \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)} \]
    5. Step-by-step derivation
      1. associate-*l/77.6%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right)}{a}} \]
      2. *-commutative77.6%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b\right) \cdot 0.3333333333333333}}{a} \]
      3. sub-neg77.6%

        \[\leadsto \frac{\color{blue}{\left(\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)\right)} \cdot 0.3333333333333333}{a} \]
      4. +-commutative77.6%

        \[\leadsto \frac{\color{blue}{\left(\left(-b\right) + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      5. neg-mul-177.6%

        \[\leadsto \frac{\left(\color{blue}{-1 \cdot b} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot 0.3333333333333333}{a} \]
      6. fma-udef77.6%

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)} \cdot 0.3333333333333333}{a} \]
      7. metadata-eval77.6%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot \color{blue}{\frac{1}{3}}}{a} \]
      8. div-inv77.7%

        \[\leadsto \frac{\color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3}}}{a} \]
      9. associate-/r*77.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{3 \cdot a}} \]
      10. *-commutative77.8%

        \[\leadsto \frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{\color{blue}{a \cdot 3}} \]
      11. associate-/r*77.7%

        \[\leadsto \color{blue}{\frac{\frac{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}{a}}{3}} \]
      12. fma-udef77.7%

        \[\leadsto \frac{\frac{\color{blue}{-1 \cdot b + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}{a}}{3} \]
      13. neg-mul-177.7%

        \[\leadsto \frac{\frac{\color{blue}{\left(-b\right)} + \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}{a}}{3} \]
      14. +-commutative77.7%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} + \left(-b\right)}}{a}}{3} \]
      15. sub-neg77.7%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}}{a}}{3} \]
    6. Applied egg-rr77.7%

      \[\leadsto \color{blue}{\frac{\frac{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)} - b}{a}}{3}} \]
    7. Taylor expanded in b around -inf 68.1%

      \[\leadsto \color{blue}{-0.6666666666666666 \cdot \frac{b}{a}} \]
    8. Step-by-step derivation
      1. *-commutative68.1%

        \[\leadsto \color{blue}{\frac{b}{a} \cdot -0.6666666666666666} \]
      2. associate-*l/68.0%

        \[\leadsto \color{blue}{\frac{b \cdot -0.6666666666666666}{a}} \]
      3. associate-*r/68.1%

        \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]
    9. Simplified68.1%

      \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]

    if -4.999999999999985e-310 < b

    1. Initial program 40.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt38.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow238.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/238.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow138.3%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow238.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr38.2%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num38.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow38.2%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative38.2%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-138.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow40.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval40.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/240.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def40.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr40.2%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-140.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified40.2%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in a around 0 17.0%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \frac{b + -1 \cdot b}{a}} \]
    9. Step-by-step derivation
      1. associate-*r/17.0%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(b + -1 \cdot b\right)}{a}} \]
      2. distribute-rgt1-in17.0%

        \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{\left(\left(-1 + 1\right) \cdot b\right)}}{a} \]
      3. metadata-eval17.0%

        \[\leadsto \frac{0.3333333333333333 \cdot \left(\color{blue}{0} \cdot b\right)}{a} \]
      4. mul0-lft17.0%

        \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{0}}{a} \]
      5. metadata-eval17.0%

        \[\leadsto \frac{\color{blue}{0}}{a} \]
    10. Simplified17.0%

      \[\leadsto \color{blue}{\frac{0}{a}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification45.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{0}{a}\\ \end{array} \]

Alternative 9: 43.5% accurate, 16.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\frac{b}{a \cdot -1.5}\\ \mathbf{else}:\\ \;\;\;\;\frac{0}{a}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -5e-310) (/ b (* a -1.5)) (/ 0.0 a)))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -5e-310) {
		tmp = b / (a * -1.5);
	} else {
		tmp = 0.0 / a;
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: tmp
    if (b <= (-5d-310)) then
        tmp = b / (a * (-1.5d0))
    else
        tmp = 0.0d0 / a
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -5e-310) {
		tmp = b / (a * -1.5);
	} else {
		tmp = 0.0 / a;
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -5e-310:
		tmp = b / (a * -1.5)
	else:
		tmp = 0.0 / a
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -5e-310)
		tmp = Float64(b / Float64(a * -1.5));
	else
		tmp = Float64(0.0 / a);
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -5e-310)
		tmp = b / (a * -1.5);
	else
		tmp = 0.0 / a;
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -5e-310], N[(b / N[(a * -1.5), $MachinePrecision]), $MachinePrecision], N[(0.0 / a), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\
\;\;\;\;\frac{b}{a \cdot -1.5}\\

\mathbf{else}:\\
\;\;\;\;\frac{0}{a}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -4.999999999999985e-310

    1. Initial program 77.7%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. frac-2neg77.7%

        \[\leadsto \color{blue}{\frac{-\left(\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}\right)}{-3 \cdot a}} \]
      2. div-inv77.6%

        \[\leadsto \color{blue}{\left(-\left(\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}\right)\right) \cdot \frac{1}{-3 \cdot a}} \]
    3. Applied egg-rr77.7%

      \[\leadsto \color{blue}{\left(b - \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot \frac{1}{a \cdot -3}} \]
    4. Taylor expanded in b around -inf 68.1%

      \[\leadsto \color{blue}{\left(2 \cdot b\right)} \cdot \frac{1}{a \cdot -3} \]
    5. Step-by-step derivation
      1. *-commutative68.1%

        \[\leadsto \color{blue}{\left(b \cdot 2\right)} \cdot \frac{1}{a \cdot -3} \]
    6. Simplified68.1%

      \[\leadsto \color{blue}{\left(b \cdot 2\right)} \cdot \frac{1}{a \cdot -3} \]
    7. Step-by-step derivation
      1. un-div-inv68.2%

        \[\leadsto \color{blue}{\frac{b \cdot 2}{a \cdot -3}} \]
      2. times-frac68.1%

        \[\leadsto \color{blue}{\frac{b}{a} \cdot \frac{2}{-3}} \]
      3. metadata-eval68.1%

        \[\leadsto \frac{b}{a} \cdot \color{blue}{-0.6666666666666666} \]
      4. associate-/r/68.1%

        \[\leadsto \color{blue}{\frac{b}{\frac{a}{-0.6666666666666666}}} \]
      5. div-inv68.2%

        \[\leadsto \frac{b}{\color{blue}{a \cdot \frac{1}{-0.6666666666666666}}} \]
      6. metadata-eval68.2%

        \[\leadsto \frac{b}{a \cdot \color{blue}{-1.5}} \]
    8. Applied egg-rr68.2%

      \[\leadsto \color{blue}{\frac{b}{a \cdot -1.5}} \]

    if -4.999999999999985e-310 < b

    1. Initial program 40.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. add-sqr-sqrt38.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
      2. pow238.2%

        \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
      3. pow1/238.2%

        \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
      4. sqrt-pow138.3%

        \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
      5. sub-neg38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      6. +-commutative38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      7. distribute-lft-neg-in38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      8. *-commutative38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      9. distribute-rgt-neg-in38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      10. metadata-eval38.3%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      11. associate-*r*38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      12. *-commutative38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      13. fma-udef38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      14. pow238.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
      15. metadata-eval38.2%

        \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
    3. Applied egg-rr38.2%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
    4. Step-by-step derivation
      1. clear-num38.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
      2. inv-pow38.2%

        \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
      3. *-commutative38.2%

        \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      4. neg-mul-138.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
      5. pow-pow40.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
      6. metadata-eval40.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
      7. pow1/240.2%

        \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
      8. fma-def40.2%

        \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
    5. Applied egg-rr40.2%

      \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-140.2%

        \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    7. Simplified40.2%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
    8. Taylor expanded in a around 0 17.0%

      \[\leadsto \color{blue}{0.3333333333333333 \cdot \frac{b + -1 \cdot b}{a}} \]
    9. Step-by-step derivation
      1. associate-*r/17.0%

        \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(b + -1 \cdot b\right)}{a}} \]
      2. distribute-rgt1-in17.0%

        \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{\left(\left(-1 + 1\right) \cdot b\right)}}{a} \]
      3. metadata-eval17.0%

        \[\leadsto \frac{0.3333333333333333 \cdot \left(\color{blue}{0} \cdot b\right)}{a} \]
      4. mul0-lft17.0%

        \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{0}}{a} \]
      5. metadata-eval17.0%

        \[\leadsto \frac{\color{blue}{0}}{a} \]
    10. Simplified17.0%

      \[\leadsto \color{blue}{\frac{0}{a}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification45.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\frac{b}{a \cdot -1.5}\\ \mathbf{else}:\\ \;\;\;\;\frac{0}{a}\\ \end{array} \]

Alternative 10: 67.3% accurate, 16.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\frac{b}{a \cdot -1.5}\\ \mathbf{else}:\\ \;\;\;\;\frac{c \cdot -0.5}{b}\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -5e-310) (/ b (* a -1.5)) (/ (* c -0.5) b)))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -5e-310) {
		tmp = b / (a * -1.5);
	} else {
		tmp = (c * -0.5) / b;
	}
	return tmp;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8) :: tmp
    if (b <= (-5d-310)) then
        tmp = b / (a * (-1.5d0))
    else
        tmp = (c * (-0.5d0)) / b
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -5e-310) {
		tmp = b / (a * -1.5);
	} else {
		tmp = (c * -0.5) / b;
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -5e-310:
		tmp = b / (a * -1.5)
	else:
		tmp = (c * -0.5) / b
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -5e-310)
		tmp = Float64(b / Float64(a * -1.5));
	else
		tmp = Float64(Float64(c * -0.5) / b);
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -5e-310)
		tmp = b / (a * -1.5);
	else
		tmp = (c * -0.5) / b;
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -5e-310], N[(b / N[(a * -1.5), $MachinePrecision]), $MachinePrecision], N[(N[(c * -0.5), $MachinePrecision] / b), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\
\;\;\;\;\frac{b}{a \cdot -1.5}\\

\mathbf{else}:\\
\;\;\;\;\frac{c \cdot -0.5}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -4.999999999999985e-310

    1. Initial program 77.7%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Step-by-step derivation
      1. frac-2neg77.7%

        \[\leadsto \color{blue}{\frac{-\left(\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}\right)}{-3 \cdot a}} \]
      2. div-inv77.6%

        \[\leadsto \color{blue}{\left(-\left(\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}\right)\right) \cdot \frac{1}{-3 \cdot a}} \]
    3. Applied egg-rr77.7%

      \[\leadsto \color{blue}{\left(b - \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right) \cdot \frac{1}{a \cdot -3}} \]
    4. Taylor expanded in b around -inf 68.1%

      \[\leadsto \color{blue}{\left(2 \cdot b\right)} \cdot \frac{1}{a \cdot -3} \]
    5. Step-by-step derivation
      1. *-commutative68.1%

        \[\leadsto \color{blue}{\left(b \cdot 2\right)} \cdot \frac{1}{a \cdot -3} \]
    6. Simplified68.1%

      \[\leadsto \color{blue}{\left(b \cdot 2\right)} \cdot \frac{1}{a \cdot -3} \]
    7. Step-by-step derivation
      1. un-div-inv68.2%

        \[\leadsto \color{blue}{\frac{b \cdot 2}{a \cdot -3}} \]
      2. times-frac68.1%

        \[\leadsto \color{blue}{\frac{b}{a} \cdot \frac{2}{-3}} \]
      3. metadata-eval68.1%

        \[\leadsto \frac{b}{a} \cdot \color{blue}{-0.6666666666666666} \]
      4. associate-/r/68.1%

        \[\leadsto \color{blue}{\frac{b}{\frac{a}{-0.6666666666666666}}} \]
      5. div-inv68.2%

        \[\leadsto \frac{b}{\color{blue}{a \cdot \frac{1}{-0.6666666666666666}}} \]
      6. metadata-eval68.2%

        \[\leadsto \frac{b}{a \cdot \color{blue}{-1.5}} \]
    8. Applied egg-rr68.2%

      \[\leadsto \color{blue}{\frac{b}{a \cdot -1.5}} \]

    if -4.999999999999985e-310 < b

    1. Initial program 40.3%

      \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
    2. Taylor expanded in b around inf 60.4%

      \[\leadsto \color{blue}{-0.5 \cdot \frac{c}{b}} \]
    3. Step-by-step derivation
      1. *-commutative60.4%

        \[\leadsto \color{blue}{\frac{c}{b} \cdot -0.5} \]
      2. associate-*l/60.4%

        \[\leadsto \color{blue}{\frac{c \cdot -0.5}{b}} \]
    4. Simplified60.4%

      \[\leadsto \color{blue}{\frac{c \cdot -0.5}{b}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification64.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\frac{b}{a \cdot -1.5}\\ \mathbf{else}:\\ \;\;\;\;\frac{c \cdot -0.5}{b}\\ \end{array} \]

Alternative 11: 11.2% accurate, 38.7× speedup?

\[\begin{array}{l} \\ \frac{0}{a} \end{array} \]
(FPCore (a b c) :precision binary64 (/ 0.0 a))
double code(double a, double b, double c) {
	return 0.0 / a;
}
real(8) function code(a, b, c)
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    code = 0.0d0 / a
end function
public static double code(double a, double b, double c) {
	return 0.0 / a;
}
def code(a, b, c):
	return 0.0 / a
function code(a, b, c)
	return Float64(0.0 / a)
end
function tmp = code(a, b, c)
	tmp = 0.0 / a;
end
code[a_, b_, c_] := N[(0.0 / a), $MachinePrecision]
\begin{array}{l}

\\
\frac{0}{a}
\end{array}
Derivation
  1. Initial program 61.0%

    \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
  2. Step-by-step derivation
    1. add-sqr-sqrt60.0%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}} \cdot \sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}}}{3 \cdot a} \]
    2. pow260.0%

      \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left(\sqrt{\sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}\right)}^{2}}}{3 \cdot a} \]
    3. pow1/260.0%

      \[\leadsto \frac{\left(-b\right) + {\left(\sqrt{\color{blue}{{\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{0.5}}}\right)}^{2}}{3 \cdot a} \]
    4. sqrt-pow160.0%

      \[\leadsto \frac{\left(-b\right) + {\color{blue}{\left({\left(b \cdot b - \left(3 \cdot a\right) \cdot c\right)}^{\left(\frac{0.5}{2}\right)}\right)}}^{2}}{3 \cdot a} \]
    5. sub-neg60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(b \cdot b + \left(-\left(3 \cdot a\right) \cdot c\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    6. +-commutative60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\left(-\left(3 \cdot a\right) \cdot c\right) + b \cdot b\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    7. distribute-lft-neg-in60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(-3 \cdot a\right) \cdot c} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    8. *-commutative60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(-\color{blue}{a \cdot 3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    9. distribute-rgt-neg-in60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{\left(a \cdot \left(-3\right)\right)} \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    10. metadata-eval60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\left(a \cdot \color{blue}{-3}\right) \cdot c + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    11. associate-*r*60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\color{blue}{a \cdot \left(-3 \cdot c\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    12. *-commutative60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(a \cdot \color{blue}{\left(c \cdot -3\right)} + b \cdot b\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    13. fma-udef60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\color{blue}{\left(\mathsf{fma}\left(a, c \cdot -3, b \cdot b\right)\right)}}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    14. pow260.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, \color{blue}{{b}^{2}}\right)\right)}^{\left(\frac{0.5}{2}\right)}\right)}^{2}}{3 \cdot a} \]
    15. metadata-eval60.0%

      \[\leadsto \frac{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.25}}\right)}^{2}}{3 \cdot a} \]
  3. Applied egg-rr60.0%

    \[\leadsto \frac{\left(-b\right) + \color{blue}{{\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}{3 \cdot a} \]
  4. Step-by-step derivation
    1. clear-num60.0%

      \[\leadsto \color{blue}{\frac{1}{\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}}} \]
    2. inv-pow60.0%

      \[\leadsto \color{blue}{{\left(\frac{3 \cdot a}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1}} \]
    3. *-commutative60.0%

      \[\leadsto {\left(\frac{\color{blue}{a \cdot 3}}{\left(-b\right) + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
    4. neg-mul-160.0%

      \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{-1 \cdot b} + {\left({\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{0.25}\right)}^{2}}\right)}^{-1} \]
    5. pow-pow61.0%

      \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{{\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\left(0.25 \cdot 2\right)}}}\right)}^{-1} \]
    6. metadata-eval61.0%

      \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + {\left(\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)\right)}^{\color{blue}{0.5}}}\right)}^{-1} \]
    7. pow1/261.0%

      \[\leadsto {\left(\frac{a \cdot 3}{-1 \cdot b + \color{blue}{\sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}}}\right)}^{-1} \]
    8. fma-def61.0%

      \[\leadsto {\left(\frac{a \cdot 3}{\color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}\right)}^{-1} \]
  5. Applied egg-rr61.0%

    \[\leadsto \color{blue}{{\left(\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}\right)}^{-1}} \]
  6. Step-by-step derivation
    1. unpow-161.0%

      \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
  7. Simplified61.0%

    \[\leadsto \color{blue}{\frac{1}{\frac{a \cdot 3}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(a, c \cdot -3, {b}^{2}\right)}\right)}}} \]
  8. Taylor expanded in a around 0 9.1%

    \[\leadsto \color{blue}{0.3333333333333333 \cdot \frac{b + -1 \cdot b}{a}} \]
  9. Step-by-step derivation
    1. associate-*r/9.1%

      \[\leadsto \color{blue}{\frac{0.3333333333333333 \cdot \left(b + -1 \cdot b\right)}{a}} \]
    2. distribute-rgt1-in9.1%

      \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{\left(\left(-1 + 1\right) \cdot b\right)}}{a} \]
    3. metadata-eval9.1%

      \[\leadsto \frac{0.3333333333333333 \cdot \left(\color{blue}{0} \cdot b\right)}{a} \]
    4. mul0-lft9.1%

      \[\leadsto \frac{0.3333333333333333 \cdot \color{blue}{0}}{a} \]
    5. metadata-eval9.1%

      \[\leadsto \frac{\color{blue}{0}}{a} \]
  10. Simplified9.1%

    \[\leadsto \color{blue}{\frac{0}{a}} \]
  11. Final simplification9.1%

    \[\leadsto \frac{0}{a} \]

Reproduce

?
herbie shell --seed 2023305 
(FPCore (a b c)
  :name "Cubic critical"
  :precision binary64
  (/ (+ (- b) (sqrt (- (* b b) (* (* 3.0 a) c)))) (* 3.0 a)))