Cubic critical

Percentage Accurate: 52.1% → 86.0%
Time: 13.5s
Alternatives: 11
Speedup: 11.6×

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.1% 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.0% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -3.6 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 3 \cdot 10^{-65}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
(FPCore (a b c)
 :precision binary64
 (if (<= b -3.6e+94)
   (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
   (if (<= b 3e-65)
     (/ (- (sqrt (- (* b b) (* c (* a 3.0)))) b) (* a 3.0))
     (* (/ c b) -0.5))))
double code(double a, double b, double c) {
	double tmp;
	if (b <= -3.6e+94) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else if (b <= 3e-65) {
		tmp = (sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	} else {
		tmp = (c / b) * -0.5;
	}
	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 <= (-3.6d+94)) then
        tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
    else if (b <= 3d-65) then
        tmp = (sqrt(((b * b) - (c * (a * 3.0d0)))) - b) / (a * 3.0d0)
    else
        tmp = (c / b) * (-0.5d0)
    end if
    code = tmp
end function
public static double code(double a, double b, double c) {
	double tmp;
	if (b <= -3.6e+94) {
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	} else if (b <= 3e-65) {
		tmp = (Math.sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	} else {
		tmp = (c / b) * -0.5;
	}
	return tmp;
}
def code(a, b, c):
	tmp = 0
	if b <= -3.6e+94:
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
	elif b <= 3e-65:
		tmp = (math.sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0)
	else:
		tmp = (c / b) * -0.5
	return tmp
function code(a, b, c)
	tmp = 0.0
	if (b <= -3.6e+94)
		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
	elseif (b <= 3e-65)
		tmp = Float64(Float64(sqrt(Float64(Float64(b * b) - Float64(c * Float64(a * 3.0)))) - b) / Float64(a * 3.0));
	else
		tmp = Float64(Float64(c / b) * -0.5);
	end
	return tmp
end
function tmp_2 = code(a, b, c)
	tmp = 0.0;
	if (b <= -3.6e+94)
		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
	elseif (b <= 3e-65)
		tmp = (sqrt(((b * b) - (c * (a * 3.0)))) - b) / (a * 3.0);
	else
		tmp = (c / b) * -0.5;
	end
	tmp_2 = tmp;
end
code[a_, b_, c_] := If[LessEqual[b, -3.6e+94], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3e-65], 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[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]]
\begin{array}{l}

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

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

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


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

    1. Initial program 52.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. Simplified52.8%

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

        \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
      4. Step-by-step derivation
        1. mul-1-neg93.0%

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

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

          \[\leadsto \color{blue}{\left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right) \cdot \left(-b\right)} \]
        4. fma-define93.0%

          \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
        5. associate-*r/93.0%

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

          \[\leadsto \mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{\color{blue}{0.6666666666666666}}{a}\right) \cdot \left(-b\right) \]
      5. Simplified93.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
      6. Taylor expanded in c around 0 93.4%

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

      if -3.59999999999999992e94 < b < 2.99999999999999998e-65

      1. Initial program 83.4%

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

      if 2.99999999999999998e-65 < b

      1. Initial program 11.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. Simplified11.4%

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

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

        \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -3.6 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 3 \cdot 10^{-65}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - c \cdot \left(a \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
      5. Add Preprocessing

      Alternative 2: 85.9% accurate, 0.9× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -7.5 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 1.1 \cdot 10^{-64}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - a \cdot \left(c \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
      (FPCore (a b c)
       :precision binary64
       (if (<= b -7.5e+94)
         (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
         (if (<= b 1.1e-64)
           (/ (- (sqrt (- (* b b) (* a (* c 3.0)))) b) (* a 3.0))
           (* (/ c b) -0.5))))
      double code(double a, double b, double c) {
      	double tmp;
      	if (b <= -7.5e+94) {
      		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
      	} else if (b <= 1.1e-64) {
      		tmp = (sqrt(((b * b) - (a * (c * 3.0)))) - b) / (a * 3.0);
      	} else {
      		tmp = (c / b) * -0.5;
      	}
      	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 <= (-7.5d+94)) then
              tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
          else if (b <= 1.1d-64) then
              tmp = (sqrt(((b * b) - (a * (c * 3.0d0)))) - b) / (a * 3.0d0)
          else
              tmp = (c / b) * (-0.5d0)
          end if
          code = tmp
      end function
      
      public static double code(double a, double b, double c) {
      	double tmp;
      	if (b <= -7.5e+94) {
      		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
      	} else if (b <= 1.1e-64) {
      		tmp = (Math.sqrt(((b * b) - (a * (c * 3.0)))) - b) / (a * 3.0);
      	} else {
      		tmp = (c / b) * -0.5;
      	}
      	return tmp;
      }
      
      def code(a, b, c):
      	tmp = 0
      	if b <= -7.5e+94:
      		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
      	elif b <= 1.1e-64:
      		tmp = (math.sqrt(((b * b) - (a * (c * 3.0)))) - b) / (a * 3.0)
      	else:
      		tmp = (c / b) * -0.5
      	return tmp
      
      function code(a, b, c)
      	tmp = 0.0
      	if (b <= -7.5e+94)
      		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
      	elseif (b <= 1.1e-64)
      		tmp = Float64(Float64(sqrt(Float64(Float64(b * b) - Float64(a * Float64(c * 3.0)))) - b) / Float64(a * 3.0));
      	else
      		tmp = Float64(Float64(c / b) * -0.5);
      	end
      	return tmp
      end
      
      function tmp_2 = code(a, b, c)
      	tmp = 0.0;
      	if (b <= -7.5e+94)
      		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
      	elseif (b <= 1.1e-64)
      		tmp = (sqrt(((b * b) - (a * (c * 3.0)))) - b) / (a * 3.0);
      	else
      		tmp = (c / b) * -0.5;
      	end
      	tmp_2 = tmp;
      end
      
      code[a_, b_, c_] := If[LessEqual[b, -7.5e+94], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.1e-64], N[(N[(N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(a * N[(c * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      \mathbf{if}\;b \leq -7.5 \cdot 10^{+94}:\\
      \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\
      
      \mathbf{elif}\;b \leq 1.1 \cdot 10^{-64}:\\
      \;\;\;\;\frac{\sqrt{b \cdot b - a \cdot \left(c \cdot 3\right)} - b}{a \cdot 3}\\
      
      \mathbf{else}:\\
      \;\;\;\;\frac{c}{b} \cdot -0.5\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if b < -7.49999999999999978e94

        1. Initial program 52.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. Simplified52.8%

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

            \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
          4. Step-by-step derivation
            1. mul-1-neg93.0%

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

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

              \[\leadsto \color{blue}{\left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right) \cdot \left(-b\right)} \]
            4. fma-define93.0%

              \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
            5. associate-*r/93.0%

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

              \[\leadsto \mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{\color{blue}{0.6666666666666666}}{a}\right) \cdot \left(-b\right) \]
          5. Simplified93.0%

            \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
          6. Taylor expanded in c around 0 93.4%

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

          if -7.49999999999999978e94 < b < 1.1e-64

          1. Initial program 83.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. sqr-neg83.4%

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

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

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

            \[\leadsto \color{blue}{\frac{\left(-b\right) + \sqrt{b \cdot b - 3 \cdot \left(a \cdot c\right)}}{3 \cdot a}} \]
          4. Add Preprocessing
          5. Step-by-step derivation
            1. add-cube-cbrt83.0%

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

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

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

            \[\leadsto \frac{\left(-b\right) + \sqrt{b \cdot b - \color{blue}{3 \cdot \left(a \cdot c\right)}}}{3 \cdot a} \]
          8. Step-by-step derivation
            1. *-commutative83.3%

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

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

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

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

          if 1.1e-64 < b

          1. Initial program 11.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. Simplified11.4%

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

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

            \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -7.5 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 1.1 \cdot 10^{-64}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - a \cdot \left(c \cdot 3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
          5. Add Preprocessing

          Alternative 3: 85.9% accurate, 0.9× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -2.25 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 10^{-65}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - 3 \cdot \left(a \cdot c\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
          (FPCore (a b c)
           :precision binary64
           (if (<= b -2.25e+94)
             (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
             (if (<= b 1e-65)
               (/ (- (sqrt (- (* b b) (* 3.0 (* a c)))) b) (* a 3.0))
               (* (/ c b) -0.5))))
          double code(double a, double b, double c) {
          	double tmp;
          	if (b <= -2.25e+94) {
          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
          	} else if (b <= 1e-65) {
          		tmp = (sqrt(((b * b) - (3.0 * (a * c)))) - b) / (a * 3.0);
          	} else {
          		tmp = (c / b) * -0.5;
          	}
          	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.25d+94)) then
                  tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
              else if (b <= 1d-65) then
                  tmp = (sqrt(((b * b) - (3.0d0 * (a * c)))) - b) / (a * 3.0d0)
              else
                  tmp = (c / b) * (-0.5d0)
              end if
              code = tmp
          end function
          
          public static double code(double a, double b, double c) {
          	double tmp;
          	if (b <= -2.25e+94) {
          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
          	} else if (b <= 1e-65) {
          		tmp = (Math.sqrt(((b * b) - (3.0 * (a * c)))) - b) / (a * 3.0);
          	} else {
          		tmp = (c / b) * -0.5;
          	}
          	return tmp;
          }
          
          def code(a, b, c):
          	tmp = 0
          	if b <= -2.25e+94:
          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
          	elif b <= 1e-65:
          		tmp = (math.sqrt(((b * b) - (3.0 * (a * c)))) - b) / (a * 3.0)
          	else:
          		tmp = (c / b) * -0.5
          	return tmp
          
          function code(a, b, c)
          	tmp = 0.0
          	if (b <= -2.25e+94)
          		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
          	elseif (b <= 1e-65)
          		tmp = Float64(Float64(sqrt(Float64(Float64(b * b) - Float64(3.0 * Float64(a * c)))) - b) / Float64(a * 3.0));
          	else
          		tmp = Float64(Float64(c / b) * -0.5);
          	end
          	return tmp
          end
          
          function tmp_2 = code(a, b, c)
          	tmp = 0.0;
          	if (b <= -2.25e+94)
          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
          	elseif (b <= 1e-65)
          		tmp = (sqrt(((b * b) - (3.0 * (a * c)))) - b) / (a * 3.0);
          	else
          		tmp = (c / b) * -0.5;
          	end
          	tmp_2 = tmp;
          end
          
          code[a_, b_, c_] := If[LessEqual[b, -2.25e+94], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1e-65], N[(N[(N[Sqrt[N[(N[(b * b), $MachinePrecision] - N[(3.0 * N[(a * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          \mathbf{if}\;b \leq -2.25 \cdot 10^{+94}:\\
          \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\
          
          \mathbf{elif}\;b \leq 10^{-65}:\\
          \;\;\;\;\frac{\sqrt{b \cdot b - 3 \cdot \left(a \cdot c\right)} - b}{a \cdot 3}\\
          
          \mathbf{else}:\\
          \;\;\;\;\frac{c}{b} \cdot -0.5\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if b < -2.24999999999999986e94

            1. Initial program 52.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. Simplified52.8%

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

                \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
              4. Step-by-step derivation
                1. mul-1-neg93.0%

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

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

                  \[\leadsto \color{blue}{\left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right) \cdot \left(-b\right)} \]
                4. fma-define93.0%

                  \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
                5. associate-*r/93.0%

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

                  \[\leadsto \mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{\color{blue}{0.6666666666666666}}{a}\right) \cdot \left(-b\right) \]
              5. Simplified93.0%

                \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
              6. Taylor expanded in c around 0 93.4%

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

              if -2.24999999999999986e94 < b < 9.99999999999999923e-66

              1. Initial program 83.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. sqr-neg83.4%

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

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

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

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

              if 9.99999999999999923e-66 < b

              1. Initial program 11.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. Simplified11.4%

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

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

                \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2.25 \cdot 10^{+94}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 10^{-65}:\\ \;\;\;\;\frac{\sqrt{b \cdot b - 3 \cdot \left(a \cdot c\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
              5. Add Preprocessing

              Alternative 4: 81.4% accurate, 1.0× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -9 \cdot 10^{-54}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 2.1 \cdot 10^{-66}:\\ \;\;\;\;\frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
              (FPCore (a b c)
               :precision binary64
               (if (<= b -9e-54)
                 (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
                 (if (<= b 2.1e-66)
                   (/ (- (sqrt (* c (* a -3.0))) b) (* a 3.0))
                   (* (/ c b) -0.5))))
              double code(double a, double b, double c) {
              	double tmp;
              	if (b <= -9e-54) {
              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
              	} else if (b <= 2.1e-66) {
              		tmp = (sqrt((c * (a * -3.0))) - b) / (a * 3.0);
              	} else {
              		tmp = (c / b) * -0.5;
              	}
              	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 <= (-9d-54)) then
                      tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
                  else if (b <= 2.1d-66) then
                      tmp = (sqrt((c * (a * (-3.0d0)))) - b) / (a * 3.0d0)
                  else
                      tmp = (c / b) * (-0.5d0)
                  end if
                  code = tmp
              end function
              
              public static double code(double a, double b, double c) {
              	double tmp;
              	if (b <= -9e-54) {
              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
              	} else if (b <= 2.1e-66) {
              		tmp = (Math.sqrt((c * (a * -3.0))) - b) / (a * 3.0);
              	} else {
              		tmp = (c / b) * -0.5;
              	}
              	return tmp;
              }
              
              def code(a, b, c):
              	tmp = 0
              	if b <= -9e-54:
              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
              	elif b <= 2.1e-66:
              		tmp = (math.sqrt((c * (a * -3.0))) - b) / (a * 3.0)
              	else:
              		tmp = (c / b) * -0.5
              	return tmp
              
              function code(a, b, c)
              	tmp = 0.0
              	if (b <= -9e-54)
              		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
              	elseif (b <= 2.1e-66)
              		tmp = Float64(Float64(sqrt(Float64(c * Float64(a * -3.0))) - b) / Float64(a * 3.0));
              	else
              		tmp = Float64(Float64(c / b) * -0.5);
              	end
              	return tmp
              end
              
              function tmp_2 = code(a, b, c)
              	tmp = 0.0;
              	if (b <= -9e-54)
              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
              	elseif (b <= 2.1e-66)
              		tmp = (sqrt((c * (a * -3.0))) - b) / (a * 3.0);
              	else
              		tmp = (c / b) * -0.5;
              	end
              	tmp_2 = tmp;
              end
              
              code[a_, b_, c_] := If[LessEqual[b, -9e-54], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.1e-66], N[(N[(N[Sqrt[N[(c * N[(a * -3.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / N[(a * 3.0), $MachinePrecision]), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;b \leq -9 \cdot 10^{-54}:\\
              \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\
              
              \mathbf{elif}\;b \leq 2.1 \cdot 10^{-66}:\\
              \;\;\;\;\frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{c}{b} \cdot -0.5\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if b < -8.9999999999999997e-54

                1. Initial program 66.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. Simplified66.8%

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

                    \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
                  4. Step-by-step derivation
                    1. mul-1-neg86.2%

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

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

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

                      \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
                    5. associate-*r/86.3%

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
                  6. Taylor expanded in c around 0 86.5%

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

                  if -8.9999999999999997e-54 < b < 2.1e-66

                  1. Initial program 79.2%

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

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

                      \[\leadsto \frac{\sqrt{\color{blue}{-3 \cdot \left(a \cdot c\right)}} - b}{3 \cdot a} \]
                    4. Step-by-step derivation
                      1. associate-*r*78.0%

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

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

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

                    if 2.1e-66 < b

                    1. Initial program 11.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. Simplified11.4%

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

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

                      \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -9 \cdot 10^{-54}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 2.1 \cdot 10^{-66}:\\ \;\;\;\;\frac{\sqrt{c \cdot \left(a \cdot -3\right)} - b}{a \cdot 3}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
                    5. Add Preprocessing

                    Alternative 5: 81.4% accurate, 1.0× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -1.7 \cdot 10^{-53}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 2.9 \cdot 10^{-70}:\\ \;\;\;\;0.3333333333333333 \cdot \frac{\sqrt{a \cdot \left(c \cdot -3\right)} - b}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
                    (FPCore (a b c)
                     :precision binary64
                     (if (<= b -1.7e-53)
                       (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
                       (if (<= b 2.9e-70)
                         (* 0.3333333333333333 (/ (- (sqrt (* a (* c -3.0))) b) a))
                         (* (/ c b) -0.5))))
                    double code(double a, double b, double c) {
                    	double tmp;
                    	if (b <= -1.7e-53) {
                    		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                    	} else if (b <= 2.9e-70) {
                    		tmp = 0.3333333333333333 * ((sqrt((a * (c * -3.0))) - b) / a);
                    	} else {
                    		tmp = (c / b) * -0.5;
                    	}
                    	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.7d-53)) then
                            tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
                        else if (b <= 2.9d-70) then
                            tmp = 0.3333333333333333d0 * ((sqrt((a * (c * (-3.0d0)))) - b) / a)
                        else
                            tmp = (c / b) * (-0.5d0)
                        end if
                        code = tmp
                    end function
                    
                    public static double code(double a, double b, double c) {
                    	double tmp;
                    	if (b <= -1.7e-53) {
                    		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                    	} else if (b <= 2.9e-70) {
                    		tmp = 0.3333333333333333 * ((Math.sqrt((a * (c * -3.0))) - b) / a);
                    	} else {
                    		tmp = (c / b) * -0.5;
                    	}
                    	return tmp;
                    }
                    
                    def code(a, b, c):
                    	tmp = 0
                    	if b <= -1.7e-53:
                    		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
                    	elif b <= 2.9e-70:
                    		tmp = 0.3333333333333333 * ((math.sqrt((a * (c * -3.0))) - b) / a)
                    	else:
                    		tmp = (c / b) * -0.5
                    	return tmp
                    
                    function code(a, b, c)
                    	tmp = 0.0
                    	if (b <= -1.7e-53)
                    		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
                    	elseif (b <= 2.9e-70)
                    		tmp = Float64(0.3333333333333333 * Float64(Float64(sqrt(Float64(a * Float64(c * -3.0))) - b) / a));
                    	else
                    		tmp = Float64(Float64(c / b) * -0.5);
                    	end
                    	return tmp
                    end
                    
                    function tmp_2 = code(a, b, c)
                    	tmp = 0.0;
                    	if (b <= -1.7e-53)
                    		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                    	elseif (b <= 2.9e-70)
                    		tmp = 0.3333333333333333 * ((sqrt((a * (c * -3.0))) - b) / a);
                    	else
                    		tmp = (c / b) * -0.5;
                    	end
                    	tmp_2 = tmp;
                    end
                    
                    code[a_, b_, c_] := If[LessEqual[b, -1.7e-53], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.9e-70], N[(0.3333333333333333 * N[(N[(N[Sqrt[N[(a * N[(c * -3.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    \mathbf{if}\;b \leq -1.7 \cdot 10^{-53}:\\
                    \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\
                    
                    \mathbf{elif}\;b \leq 2.9 \cdot 10^{-70}:\\
                    \;\;\;\;0.3333333333333333 \cdot \frac{\sqrt{a \cdot \left(c \cdot -3\right)} - b}{a}\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;\frac{c}{b} \cdot -0.5\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 3 regimes
                    2. if b < -1.7e-53

                      1. Initial program 66.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. Simplified66.8%

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

                          \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
                        4. Step-by-step derivation
                          1. mul-1-neg86.2%

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

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
                          5. associate-*r/86.3%

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

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

                          \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
                        6. Taylor expanded in c around 0 86.5%

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

                        if -1.7e-53 < b < 2.89999999999999971e-70

                        1. Initial program 79.2%

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

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

                            \[\leadsto \frac{\sqrt{\color{blue}{-3 \cdot \left(a \cdot c\right)}} - b}{3 \cdot a} \]
                          4. Step-by-step derivation
                            1. associate-*r*78.0%

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

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

                            \[\leadsto \frac{\sqrt{\color{blue}{\left(a \cdot -3\right) \cdot c}} - b}{3 \cdot a} \]
                          6. Step-by-step derivation
                            1. *-un-lft-identity78.0%

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

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

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

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

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

                          if 2.89999999999999971e-70 < b

                          1. Initial program 11.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. Simplified11.4%

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

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

                            \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.7 \cdot 10^{-53}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 2.9 \cdot 10^{-70}:\\ \;\;\;\;0.3333333333333333 \cdot \frac{\sqrt{a \cdot \left(c \cdot -3\right)} - b}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
                          5. Add Preprocessing

                          Alternative 6: 71.4% accurate, 1.0× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -3.6 \cdot 10^{-67}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 5 \cdot 10^{-203}:\\ \;\;\;\;\sqrt{c \cdot \frac{-3}{a}} \cdot \left(--0.3333333333333333\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
                          (FPCore (a b c)
                           :precision binary64
                           (if (<= b -3.6e-67)
                             (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
                             (if (<= b 5e-203)
                               (* (sqrt (* c (/ -3.0 a))) (- -0.3333333333333333))
                               (* (/ c b) -0.5))))
                          double code(double a, double b, double c) {
                          	double tmp;
                          	if (b <= -3.6e-67) {
                          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                          	} else if (b <= 5e-203) {
                          		tmp = sqrt((c * (-3.0 / a))) * -(-0.3333333333333333);
                          	} else {
                          		tmp = (c / b) * -0.5;
                          	}
                          	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 <= (-3.6d-67)) then
                                  tmp = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
                              else if (b <= 5d-203) then
                                  tmp = sqrt((c * ((-3.0d0) / a))) * -(-0.3333333333333333d0)
                              else
                                  tmp = (c / b) * (-0.5d0)
                              end if
                              code = tmp
                          end function
                          
                          public static double code(double a, double b, double c) {
                          	double tmp;
                          	if (b <= -3.6e-67) {
                          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                          	} else if (b <= 5e-203) {
                          		tmp = Math.sqrt((c * (-3.0 / a))) * -(-0.3333333333333333);
                          	} else {
                          		tmp = (c / b) * -0.5;
                          	}
                          	return tmp;
                          }
                          
                          def code(a, b, c):
                          	tmp = 0
                          	if b <= -3.6e-67:
                          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
                          	elif b <= 5e-203:
                          		tmp = math.sqrt((c * (-3.0 / a))) * -(-0.3333333333333333)
                          	else:
                          		tmp = (c / b) * -0.5
                          	return tmp
                          
                          function code(a, b, c)
                          	tmp = 0.0
                          	if (b <= -3.6e-67)
                          		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
                          	elseif (b <= 5e-203)
                          		tmp = Float64(sqrt(Float64(c * Float64(-3.0 / a))) * Float64(-(-0.3333333333333333)));
                          	else
                          		tmp = Float64(Float64(c / b) * -0.5);
                          	end
                          	return tmp
                          end
                          
                          function tmp_2 = code(a, b, c)
                          	tmp = 0.0;
                          	if (b <= -3.6e-67)
                          		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                          	elseif (b <= 5e-203)
                          		tmp = sqrt((c * (-3.0 / a))) * -(-0.3333333333333333);
                          	else
                          		tmp = (c / b) * -0.5;
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          code[a_, b_, c_] := If[LessEqual[b, -3.6e-67], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 5e-203], N[(N[Sqrt[N[(c * N[(-3.0 / a), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (--0.3333333333333333)), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          \mathbf{if}\;b \leq -3.6 \cdot 10^{-67}:\\
                          \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\
                          
                          \mathbf{elif}\;b \leq 5 \cdot 10^{-203}:\\
                          \;\;\;\;\sqrt{c \cdot \frac{-3}{a}} \cdot \left(--0.3333333333333333\right)\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\frac{c}{b} \cdot -0.5\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 3 regimes
                          2. if b < -3.59999999999999999e-67

                            1. Initial program 66.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. Simplified66.8%

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

                                \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
                              4. Step-by-step derivation
                                1. mul-1-neg86.2%

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

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

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

                                  \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
                                5. associate-*r/86.3%

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

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

                                \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
                              6. Taylor expanded in c around 0 86.5%

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

                              if -3.59999999999999999e-67 < b < 5.0000000000000002e-203

                              1. Initial program 81.6%

                                \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(3 \cdot a\right) \cdot c}}{3 \cdot a} \]
                              2. Add Preprocessing
                              3. Step-by-step derivation
                                1. add-cube-cbrt80.9%

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

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

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

                                \[\leadsto \color{blue}{-0.3333333333333333 \cdot \left(\sqrt{\frac{c \cdot {\left(\sqrt[3]{-3}\right)}^{3}}{a}} \cdot {\left(\sqrt{-1}\right)}^{2}\right)} \]
                              6. Step-by-step derivation
                                1. *-commutative0.0%

                                  \[\leadsto -0.3333333333333333 \cdot \color{blue}{\left({\left(\sqrt{-1}\right)}^{2} \cdot \sqrt{\frac{c \cdot {\left(\sqrt[3]{-3}\right)}^{3}}{a}}\right)} \]
                                2. unpow20.0%

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

                                  \[\leadsto -0.3333333333333333 \cdot \left(\color{blue}{-1} \cdot \sqrt{\frac{c \cdot {\left(\sqrt[3]{-3}\right)}^{3}}{a}}\right) \]
                                4. rem-cube-cbrt36.9%

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

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

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

                              if 5.0000000000000002e-203 < b

                              1. Initial program 18.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. Simplified18.4%

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

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

                                \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -3.6 \cdot 10^{-67}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{elif}\;b \leq 5 \cdot 10^{-203}:\\ \;\;\;\;\sqrt{c \cdot \frac{-3}{a}} \cdot \left(--0.3333333333333333\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
                              5. Add Preprocessing

                              Alternative 7: 68.1% accurate, 7.2× speedup?

                              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\ \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
                              (FPCore (a b c)
                               :precision binary64
                               (if (<= b -5e-310)
                                 (+ (* -0.6666666666666666 (/ b a)) (* 0.5 (/ c b)))
                                 (* (/ c b) -0.5)))
                              double code(double a, double b, double c) {
                              	double tmp;
                              	if (b <= -5e-310) {
                              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                              	} else {
                              		tmp = (c / b) * -0.5;
                              	}
                              	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 = ((-0.6666666666666666d0) * (b / a)) + (0.5d0 * (c / b))
                                  else
                                      tmp = (c / b) * (-0.5d0)
                                  end if
                                  code = tmp
                              end function
                              
                              public static double code(double a, double b, double c) {
                              	double tmp;
                              	if (b <= -5e-310) {
                              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                              	} else {
                              		tmp = (c / b) * -0.5;
                              	}
                              	return tmp;
                              }
                              
                              def code(a, b, c):
                              	tmp = 0
                              	if b <= -5e-310:
                              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b))
                              	else:
                              		tmp = (c / b) * -0.5
                              	return tmp
                              
                              function code(a, b, c)
                              	tmp = 0.0
                              	if (b <= -5e-310)
                              		tmp = Float64(Float64(-0.6666666666666666 * Float64(b / a)) + Float64(0.5 * Float64(c / b)));
                              	else
                              		tmp = Float64(Float64(c / b) * -0.5);
                              	end
                              	return tmp
                              end
                              
                              function tmp_2 = code(a, b, c)
                              	tmp = 0.0;
                              	if (b <= -5e-310)
                              		tmp = (-0.6666666666666666 * (b / a)) + (0.5 * (c / b));
                              	else
                              		tmp = (c / b) * -0.5;
                              	end
                              	tmp_2 = tmp;
                              end
                              
                              code[a_, b_, c_] := If[LessEqual[b, -5e-310], N[(N[(-0.6666666666666666 * N[(b / a), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(c / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]
                              
                              \begin{array}{l}
                              
                              \\
                              \begin{array}{l}
                              \mathbf{if}\;b \leq -5 \cdot 10^{-310}:\\
                              \;\;\;\;-0.6666666666666666 \cdot \frac{b}{a} + 0.5 \cdot \frac{c}{b}\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;\frac{c}{b} \cdot -0.5\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 2 regimes
                              2. if b < -4.999999999999985e-310

                                1. Initial program 71.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. Simplified71.6%

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

                                    \[\leadsto \color{blue}{-1 \cdot \left(b \cdot \left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right)\right)} \]
                                  4. Step-by-step derivation
                                    1. mul-1-neg62.9%

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

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

                                      \[\leadsto \color{blue}{\left(-0.5 \cdot \frac{c}{{b}^{2}} + 0.6666666666666666 \cdot \frac{1}{a}\right) \cdot \left(-b\right)} \]
                                    4. fma-define62.9%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, 0.6666666666666666 \cdot \frac{1}{a}\right)} \cdot \left(-b\right) \]
                                    5. associate-*r/63.0%

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

                                      \[\leadsto \mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{\color{blue}{0.6666666666666666}}{a}\right) \cdot \left(-b\right) \]
                                  5. Simplified63.0%

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(-0.5, \frac{c}{{b}^{2}}, \frac{0.6666666666666666}{a}\right) \cdot \left(-b\right)} \]
                                  6. Taylor expanded in c around 0 64.9%

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

                                  if -4.999999999999985e-310 < b

                                  1. Initial program 24.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. Simplified24.0%

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

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

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

                                  Alternative 8: 68.0% accurate, 11.6× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq 1.15 \cdot 10^{-300}:\\ \;\;\;\;\frac{b \cdot -0.6666666666666666}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
                                  (FPCore (a b c)
                                   :precision binary64
                                   (if (<= b 1.15e-300) (/ (* b -0.6666666666666666) a) (* (/ c b) -0.5)))
                                  double code(double a, double b, double c) {
                                  	double tmp;
                                  	if (b <= 1.15e-300) {
                                  		tmp = (b * -0.6666666666666666) / a;
                                  	} else {
                                  		tmp = (c / b) * -0.5;
                                  	}
                                  	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.15d-300) then
                                          tmp = (b * (-0.6666666666666666d0)) / a
                                      else
                                          tmp = (c / b) * (-0.5d0)
                                      end if
                                      code = tmp
                                  end function
                                  
                                  public static double code(double a, double b, double c) {
                                  	double tmp;
                                  	if (b <= 1.15e-300) {
                                  		tmp = (b * -0.6666666666666666) / a;
                                  	} else {
                                  		tmp = (c / b) * -0.5;
                                  	}
                                  	return tmp;
                                  }
                                  
                                  def code(a, b, c):
                                  	tmp = 0
                                  	if b <= 1.15e-300:
                                  		tmp = (b * -0.6666666666666666) / a
                                  	else:
                                  		tmp = (c / b) * -0.5
                                  	return tmp
                                  
                                  function code(a, b, c)
                                  	tmp = 0.0
                                  	if (b <= 1.15e-300)
                                  		tmp = Float64(Float64(b * -0.6666666666666666) / a);
                                  	else
                                  		tmp = Float64(Float64(c / b) * -0.5);
                                  	end
                                  	return tmp
                                  end
                                  
                                  function tmp_2 = code(a, b, c)
                                  	tmp = 0.0;
                                  	if (b <= 1.15e-300)
                                  		tmp = (b * -0.6666666666666666) / a;
                                  	else
                                  		tmp = (c / b) * -0.5;
                                  	end
                                  	tmp_2 = tmp;
                                  end
                                  
                                  code[a_, b_, c_] := If[LessEqual[b, 1.15e-300], N[(N[(b * -0.6666666666666666), $MachinePrecision] / a), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \begin{array}{l}
                                  \mathbf{if}\;b \leq 1.15 \cdot 10^{-300}:\\
                                  \;\;\;\;\frac{b \cdot -0.6666666666666666}{a}\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;\frac{c}{b} \cdot -0.5\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 2 regimes
                                  2. if b < 1.15e-300

                                    1. Initial program 71.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. sqr-neg71.8%

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

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

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

                                      \[\leadsto \color{blue}{\frac{\left(-b\right) + \sqrt{b \cdot b - 3 \cdot \left(a \cdot c\right)}}{3 \cdot a}} \]
                                    4. Add Preprocessing
                                    5. Step-by-step derivation
                                      1. add-cube-cbrt71.6%

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

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

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

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

                                        \[\leadsto \color{blue}{\frac{-0.6666666666666666 \cdot b}{a}} \]
                                      2. *-commutative64.1%

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

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

                                    if 1.15e-300 < b

                                    1. Initial program 23.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. Simplified23.4%

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

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

                                      \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 1.15 \cdot 10^{-300}:\\ \;\;\;\;\frac{b \cdot -0.6666666666666666}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
                                    5. Add Preprocessing

                                    Alternative 9: 68.0% accurate, 11.6× speedup?

                                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq 2.8 \cdot 10^{-301}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \end{array} \]
                                    (FPCore (a b c)
                                     :precision binary64
                                     (if (<= b 2.8e-301) (* b (/ -0.6666666666666666 a)) (* (/ c b) -0.5)))
                                    double code(double a, double b, double c) {
                                    	double tmp;
                                    	if (b <= 2.8e-301) {
                                    		tmp = b * (-0.6666666666666666 / a);
                                    	} else {
                                    		tmp = (c / b) * -0.5;
                                    	}
                                    	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.8d-301) then
                                            tmp = b * ((-0.6666666666666666d0) / a)
                                        else
                                            tmp = (c / b) * (-0.5d0)
                                        end if
                                        code = tmp
                                    end function
                                    
                                    public static double code(double a, double b, double c) {
                                    	double tmp;
                                    	if (b <= 2.8e-301) {
                                    		tmp = b * (-0.6666666666666666 / a);
                                    	} else {
                                    		tmp = (c / b) * -0.5;
                                    	}
                                    	return tmp;
                                    }
                                    
                                    def code(a, b, c):
                                    	tmp = 0
                                    	if b <= 2.8e-301:
                                    		tmp = b * (-0.6666666666666666 / a)
                                    	else:
                                    		tmp = (c / b) * -0.5
                                    	return tmp
                                    
                                    function code(a, b, c)
                                    	tmp = 0.0
                                    	if (b <= 2.8e-301)
                                    		tmp = Float64(b * Float64(-0.6666666666666666 / a));
                                    	else
                                    		tmp = Float64(Float64(c / b) * -0.5);
                                    	end
                                    	return tmp
                                    end
                                    
                                    function tmp_2 = code(a, b, c)
                                    	tmp = 0.0;
                                    	if (b <= 2.8e-301)
                                    		tmp = b * (-0.6666666666666666 / a);
                                    	else
                                    		tmp = (c / b) * -0.5;
                                    	end
                                    	tmp_2 = tmp;
                                    end
                                    
                                    code[a_, b_, c_] := If[LessEqual[b, 2.8e-301], N[(b * N[(-0.6666666666666666 / a), $MachinePrecision]), $MachinePrecision], N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]]
                                    
                                    \begin{array}{l}
                                    
                                    \\
                                    \begin{array}{l}
                                    \mathbf{if}\;b \leq 2.8 \cdot 10^{-301}:\\
                                    \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\
                                    
                                    \mathbf{else}:\\
                                    \;\;\;\;\frac{c}{b} \cdot -0.5\\
                                    
                                    
                                    \end{array}
                                    \end{array}
                                    
                                    Derivation
                                    1. Split input into 2 regimes
                                    2. if b < 2.8000000000000001e-301

                                      1. Initial program 71.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. Simplified71.8%

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

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

                                            \[\leadsto \color{blue}{\frac{b}{a} \cdot -0.6666666666666666} \]
                                        5. Simplified64.0%

                                          \[\leadsto \color{blue}{\frac{b}{a} \cdot -0.6666666666666666} \]
                                        6. Taylor expanded in b around 0 64.0%

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

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

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

                                            \[\leadsto \color{blue}{b \cdot \frac{-0.6666666666666666}{a}} \]
                                        8. Simplified64.0%

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

                                        if 2.8000000000000001e-301 < b

                                        1. Initial program 23.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. Simplified23.4%

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

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

                                          \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 2.8 \cdot 10^{-301}:\\ \;\;\;\;b \cdot \frac{-0.6666666666666666}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{c}{b} \cdot -0.5\\ \end{array} \]
                                        5. Add Preprocessing

                                        Alternative 10: 35.6% accurate, 23.2× speedup?

                                        \[\begin{array}{l} \\ \frac{c}{b} \cdot -0.5 \end{array} \]
                                        (FPCore (a b c) :precision binary64 (* (/ c b) -0.5))
                                        double code(double a, double b, double c) {
                                        	return (c / b) * -0.5;
                                        }
                                        
                                        real(8) function code(a, b, c)
                                            real(8), intent (in) :: a
                                            real(8), intent (in) :: b
                                            real(8), intent (in) :: c
                                            code = (c / b) * (-0.5d0)
                                        end function
                                        
                                        public static double code(double a, double b, double c) {
                                        	return (c / b) * -0.5;
                                        }
                                        
                                        def code(a, b, c):
                                        	return (c / b) * -0.5
                                        
                                        function code(a, b, c)
                                        	return Float64(Float64(c / b) * -0.5)
                                        end
                                        
                                        function tmp = code(a, b, c)
                                        	tmp = (c / b) * -0.5;
                                        end
                                        
                                        code[a_, b_, c_] := N[(N[(c / b), $MachinePrecision] * -0.5), $MachinePrecision]
                                        
                                        \begin{array}{l}
                                        
                                        \\
                                        \frac{c}{b} \cdot -0.5
                                        \end{array}
                                        
                                        Derivation
                                        1. Initial program 49.1%

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

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

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

                                            \[\leadsto \frac{c}{b} \cdot -0.5 \]
                                          5. Add Preprocessing

                                          Alternative 11: 11.0% accurate, 116.0× speedup?

                                          \[\begin{array}{l} \\ 0 \end{array} \]
                                          (FPCore (a b c) :precision binary64 0.0)
                                          double code(double a, double b, double c) {
                                          	return 0.0;
                                          }
                                          
                                          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
                                          end function
                                          
                                          public static double code(double a, double b, double c) {
                                          	return 0.0;
                                          }
                                          
                                          def code(a, b, c):
                                          	return 0.0
                                          
                                          function code(a, b, c)
                                          	return 0.0
                                          end
                                          
                                          function tmp = code(a, b, c)
                                          	tmp = 0.0;
                                          end
                                          
                                          code[a_, b_, c_] := 0.0
                                          
                                          \begin{array}{l}
                                          
                                          \\
                                          0
                                          \end{array}
                                          
                                          Derivation
                                          1. Initial program 49.1%

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

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

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

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

                                            \[\leadsto \color{blue}{\frac{\left(-b\right) + \sqrt{b \cdot b - 3 \cdot \left(a \cdot c\right)}}{3 \cdot a}} \]
                                          4. Add Preprocessing
                                          5. Step-by-step derivation
                                            1. add-cube-cbrt48.9%

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

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

                                            \[\leadsto \frac{\left(-b\right) + \sqrt{b \cdot b - 3 \cdot \color{blue}{{\left(\sqrt[3]{a \cdot c}\right)}^{3}}}}{3 \cdot a} \]
                                          7. Step-by-step derivation
                                            1. div-inv48.9%

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

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

                                              \[\leadsto \color{blue}{\mathsf{fma}\left(-1, b, \sqrt{b \cdot b - 3 \cdot {\left(\sqrt[3]{a \cdot c}\right)}^{3}}\right)} \cdot \frac{1}{3 \cdot a} \]
                                            4. cancel-sign-sub-inv48.9%

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

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

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

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

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

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(b, b, -3 \cdot \left(a \cdot c\right)\right)}\right) \cdot \frac{1}{3 \cdot a}} \]
                                          9. Step-by-step derivation
                                            1. associate-/r*49.0%

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

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

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

                                              \[\leadsto \mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(b, b, -3 \cdot \left(a \cdot c\right)\right)}\right) \cdot \color{blue}{\left(0.3333333333333333 \cdot \frac{1}{a}\right)} \]
                                            5. *-commutative48.9%

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

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

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

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

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

                                              \[\leadsto \frac{0.3333333333333333}{a} \cdot \mathsf{fma}\left(-1, b, \sqrt{{b}^{2} + \color{blue}{\left(-3\right)} \cdot \left(a \cdot c\right)}\right) \]
                                            11. cancel-sign-sub-inv49.0%

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

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

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

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

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

                                              \[\leadsto \frac{0.3333333333333333}{a} \cdot \mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(b, b, -\color{blue}{\left(3 \cdot a\right) \cdot c}\right)}\right) \]
                                            17. associate-*r*49.0%

                                              \[\leadsto \frac{0.3333333333333333}{a} \cdot \mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(b, b, -\color{blue}{3 \cdot \left(a \cdot c\right)}\right)}\right) \]
                                            18. distribute-lft-neg-in49.0%

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

                                              \[\leadsto \frac{0.3333333333333333}{a} \cdot \mathsf{fma}\left(-1, b, \sqrt{\mathsf{fma}\left(b, b, \color{blue}{-3} \cdot \left(a \cdot c\right)\right)}\right) \]
                                            20. associate-*r*49.1%

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

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

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

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

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

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

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

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

                                              \[\leadsto \frac{\color{blue}{0}}{a} \]
                                            6. div012.5%

                                              \[\leadsto \color{blue}{0} \]
                                          13. Simplified12.5%

                                            \[\leadsto \color{blue}{0} \]
                                          14. Add Preprocessing

                                          Reproduce

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