ABCF->ab-angle b

Percentage Accurate: 19.2% → 59.8%
Time: 7.7s
Alternatives: 11
Speedup: 10.0×

Specification

?
\[\begin{array}{l} t_0 := {B}^{2} - \left(4 \cdot A\right) \cdot C\\ \frac{-\sqrt{\left(2 \cdot \left(t\_0 \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{t\_0} \end{array} \]
(FPCore (A B C F)
  :precision binary64
  :pre TRUE
  (let* ((t_0 (- (pow B 2.0) (* (* 4.0 A) C))))
  (/
   (-
    (sqrt
     (*
      (* 2.0 (* t_0 F))
      (- (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))))
   t_0)))
double code(double A, double B, double C, double F) {
	double t_0 = pow(B, 2.0) - ((4.0 * A) * C);
	return -sqrt(((2.0 * (t_0 * F)) * ((A + C) - sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / t_0;
}
real(8) function code(a, b, c, f)
use fmin_fmax_functions
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: f
    real(8) :: t_0
    t_0 = (b ** 2.0d0) - ((4.0d0 * a) * c)
    code = -sqrt(((2.0d0 * (t_0 * f)) * ((a + c) - sqrt((((a - c) ** 2.0d0) + (b ** 2.0d0)))))) / t_0
end function
public static double code(double A, double B, double C, double F) {
	double t_0 = Math.pow(B, 2.0) - ((4.0 * A) * C);
	return -Math.sqrt(((2.0 * (t_0 * F)) * ((A + C) - Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / t_0;
}
def code(A, B, C, F):
	t_0 = math.pow(B, 2.0) - ((4.0 * A) * C)
	return -math.sqrt(((2.0 * (t_0 * F)) * ((A + C) - math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / t_0
function code(A, B, C, F)
	t_0 = Float64((B ^ 2.0) - Float64(Float64(4.0 * A) * C))
	return Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(Float64(A + C) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0))))))) / t_0)
end
function tmp = code(A, B, C, F)
	t_0 = (B ^ 2.0) - ((4.0 * A) * C);
	tmp = -sqrt(((2.0 * (t_0 * F)) * ((A + C) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / t_0;
end
code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[Power[B, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(N[(A + C), $MachinePrecision] - N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision]]
f(A, B, C, F):
	A in [-inf, +inf],
	B in [-inf, +inf],
	C in [-inf, +inf],
	F in [-inf, +inf]
code: THEORY
BEGIN
f(A, B, C, F: real): real =
	LET t_0 = ((B ^ (2)) - (((4) * A) * C)) IN
	(- (sqrt((((2) * (t_0 * F)) * ((A + C) - (sqrt((((A - C) ^ (2)) + (B ^ (2)))))))))) / t_0
END code
\begin{array}{l}
t_0 := {B}^{2} - \left(4 \cdot A\right) \cdot C\\
\frac{-\sqrt{\left(2 \cdot \left(t\_0 \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{t\_0}
\end{array}

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: 19.2% accurate, 1.0× speedup?

\[\begin{array}{l} t_0 := {B}^{2} - \left(4 \cdot A\right) \cdot C\\ \frac{-\sqrt{\left(2 \cdot \left(t\_0 \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{t\_0} \end{array} \]
(FPCore (A B C F)
  :precision binary64
  :pre TRUE
  (let* ((t_0 (- (pow B 2.0) (* (* 4.0 A) C))))
  (/
   (-
    (sqrt
     (*
      (* 2.0 (* t_0 F))
      (- (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))))
   t_0)))
double code(double A, double B, double C, double F) {
	double t_0 = pow(B, 2.0) - ((4.0 * A) * C);
	return -sqrt(((2.0 * (t_0 * F)) * ((A + C) - sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / t_0;
}
real(8) function code(a, b, c, f)
use fmin_fmax_functions
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: f
    real(8) :: t_0
    t_0 = (b ** 2.0d0) - ((4.0d0 * a) * c)
    code = -sqrt(((2.0d0 * (t_0 * f)) * ((a + c) - sqrt((((a - c) ** 2.0d0) + (b ** 2.0d0)))))) / t_0
end function
public static double code(double A, double B, double C, double F) {
	double t_0 = Math.pow(B, 2.0) - ((4.0 * A) * C);
	return -Math.sqrt(((2.0 * (t_0 * F)) * ((A + C) - Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / t_0;
}
def code(A, B, C, F):
	t_0 = math.pow(B, 2.0) - ((4.0 * A) * C)
	return -math.sqrt(((2.0 * (t_0 * F)) * ((A + C) - math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / t_0
function code(A, B, C, F)
	t_0 = Float64((B ^ 2.0) - Float64(Float64(4.0 * A) * C))
	return Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(Float64(A + C) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0))))))) / t_0)
end
function tmp = code(A, B, C, F)
	t_0 = (B ^ 2.0) - ((4.0 * A) * C);
	tmp = -sqrt(((2.0 * (t_0 * F)) * ((A + C) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / t_0;
end
code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[Power[B, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(N[(A + C), $MachinePrecision] - N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision]]
f(A, B, C, F):
	A in [-inf, +inf],
	B in [-inf, +inf],
	C in [-inf, +inf],
	F in [-inf, +inf]
code: THEORY
BEGIN
f(A, B, C, F: real): real =
	LET t_0 = ((B ^ (2)) - (((4) * A) * C)) IN
	(- (sqrt((((2) * (t_0 * F)) * ((A + C) - (sqrt((((A - C) ^ (2)) + (B ^ (2)))))))))) / t_0
END code
\begin{array}{l}
t_0 := {B}^{2} - \left(4 \cdot A\right) \cdot C\\
\frac{-\sqrt{\left(2 \cdot \left(t\_0 \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{t\_0}
\end{array}

Alternative 1: 59.8% accurate, 1.4× speedup?

\[\begin{array}{l} \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\ \;\;\;\;\frac{-\sqrt{\left|\mathsf{fma}\left(\mathsf{max}\left(A, C\right) \cdot -4, \mathsf{min}\left(A, C\right), \left|B\right| \cdot \left|B\right|\right)\right|} \cdot \sqrt{\left|4 \cdot \left(\mathsf{min}\left(A, C\right) \cdot F\right)\right|}}{{\left(\left|B\right|\right)}^{2} - \left(4 \cdot \mathsf{min}\left(A, C\right)\right) \cdot \mathsf{max}\left(A, C\right)}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\ \end{array} \]
(FPCore (A B C F)
  :precision binary64
  :pre TRUE
  (if (<= (fabs B) 6.214827610791501e+20)
  (/
   (-
    (*
     (sqrt
      (fabs
       (fma (* (fmax A C) -4.0) (fmin A C) (* (fabs B) (fabs B)))))
     (sqrt (fabs (* 4.0 (* (fmin A C) F))))))
   (- (pow (fabs B) 2.0) (* (* 4.0 (fmin A C)) (fmax A C))))
  (- (* (sqrt (fabs (+ F F))) (sqrt (/ 1.0 (fabs (fabs B))))))))
double code(double A, double B, double C, double F) {
	double tmp;
	if (fabs(B) <= 6.214827610791501e+20) {
		tmp = -(sqrt(fabs(fma((fmax(A, C) * -4.0), fmin(A, C), (fabs(B) * fabs(B))))) * sqrt(fabs((4.0 * (fmin(A, C) * F))))) / (pow(fabs(B), 2.0) - ((4.0 * fmin(A, C)) * fmax(A, C)));
	} else {
		tmp = -(sqrt(fabs((F + F))) * sqrt((1.0 / fabs(fabs(B)))));
	}
	return tmp;
}
function code(A, B, C, F)
	tmp = 0.0
	if (abs(B) <= 6.214827610791501e+20)
		tmp = Float64(Float64(-Float64(sqrt(abs(fma(Float64(fmax(A, C) * -4.0), fmin(A, C), Float64(abs(B) * abs(B))))) * sqrt(abs(Float64(4.0 * Float64(fmin(A, C) * F)))))) / Float64((abs(B) ^ 2.0) - Float64(Float64(4.0 * fmin(A, C)) * fmax(A, C))));
	else
		tmp = Float64(-Float64(sqrt(abs(Float64(F + F))) * sqrt(Float64(1.0 / abs(abs(B))))));
	end
	return tmp
end
code[A_, B_, C_, F_] := If[LessEqual[N[Abs[B], $MachinePrecision], 6.214827610791501e+20], N[((-N[(N[Sqrt[N[Abs[N[(N[(N[Max[A, C], $MachinePrecision] * -4.0), $MachinePrecision] * N[Min[A, C], $MachinePrecision] + N[(N[Abs[B], $MachinePrecision] * N[Abs[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[Abs[N[(4.0 * N[(N[Min[A, C], $MachinePrecision] * F), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]) / N[(N[Power[N[Abs[B], $MachinePrecision], 2.0], $MachinePrecision] - N[(N[(4.0 * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * N[Max[A, C], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], (-N[(N[Sqrt[N[Abs[N[(F + F), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(1.0 / N[Abs[N[Abs[B], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]
f(A, B, C, F):
	A in [-inf, +inf],
	B in [-inf, +inf],
	C in [-inf, +inf],
	F in [-inf, +inf]
code: THEORY
BEGIN
f(A, B, C, F: real): real =
	LET tmp_6 = IF (A > C) THEN A ELSE C ENDIF IN
	LET tmp_7 = IF (A < C) THEN A ELSE C ENDIF IN
	LET tmp_8 = IF (A < C) THEN A ELSE C ENDIF IN
	LET tmp_9 = IF (A < C) THEN A ELSE C ENDIF IN
	LET tmp_10 = IF (A > C) THEN A ELSE C ENDIF IN
	LET tmp_5 = IF ((abs(B)) <= (621482761079150084096)) THEN ((- ((sqrt((abs((((tmp_6 * (-4)) * tmp_7) + ((abs(B)) * (abs(B)))))))) * (sqrt((abs(((4) * (tmp_8 * F)))))))) / (((abs(B)) ^ (2)) - (((4) * tmp_9) * tmp_10))) ELSE (- ((sqrt((abs((F + F))))) * (sqrt(((1) / (abs((abs(B))))))))) ENDIF IN
	tmp_5
END code
\begin{array}{l}
\mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\
\;\;\;\;\frac{-\sqrt{\left|\mathsf{fma}\left(\mathsf{max}\left(A, C\right) \cdot -4, \mathsf{min}\left(A, C\right), \left|B\right| \cdot \left|B\right|\right)\right|} \cdot \sqrt{\left|4 \cdot \left(\mathsf{min}\left(A, C\right) \cdot F\right)\right|}}{{\left(\left|B\right|\right)}^{2} - \left(4 \cdot \mathsf{min}\left(A, C\right)\right) \cdot \mathsf{max}\left(A, C\right)}\\

\mathbf{else}:\\
\;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\


\end{array}
Derivation
  1. Split input into 2 regimes
  2. if B < 621482761079150080000

    1. Initial program 19.2%

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Applied rewrites24.9%

      \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|\left(F + F\right) \cdot \left(\left(C + A\right) - \sqrt{\mathsf{fma}\left(C - A, C - A, B \cdot B\right)}\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    3. Taylor expanded in A around -inf

      \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    4. Step-by-step derivation
      1. Applied rewrites20.3%

        \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

      if 621482761079150080000 < B

      1. Initial program 19.2%

        \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. Taylor expanded in B around inf

        \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
      3. Step-by-step derivation
        1. Applied rewrites13.6%

          \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
        2. Applied rewrites13.6%

          \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
        3. Step-by-step derivation
          1. Applied rewrites35.6%

            \[\leadsto -\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|B\right|}} \]
        4. Recombined 2 regimes into one program.
        5. Add Preprocessing

        Alternative 2: 59.8% accurate, 1.6× speedup?

        \[\begin{array}{l} t_0 := \mathsf{fma}\left(-4 \cdot \mathsf{min}\left(A, C\right), \mathsf{max}\left(A, C\right), \left|B\right| \cdot \left|B\right|\right)\\ \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\ \;\;\;\;\frac{\sqrt{\left|\left(F \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4\right|}}{t\_0 \cdot \frac{-1}{\sqrt{\left|t\_0\right|}}}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\ \end{array} \]
        (FPCore (A B C F)
          :precision binary64
          :pre TRUE
          (let* ((t_0
                (fma (* -4.0 (fmin A C)) (fmax A C) (* (fabs B) (fabs B)))))
          (if (<= (fabs B) 6.214827610791501e+20)
            (/
             (sqrt (fabs (* (* F (fmin A C)) 4.0)))
             (* t_0 (/ -1.0 (sqrt (fabs t_0)))))
            (- (* (sqrt (fabs (+ F F))) (sqrt (/ 1.0 (fabs (fabs B)))))))))
        double code(double A, double B, double C, double F) {
        	double t_0 = fma((-4.0 * fmin(A, C)), fmax(A, C), (fabs(B) * fabs(B)));
        	double tmp;
        	if (fabs(B) <= 6.214827610791501e+20) {
        		tmp = sqrt(fabs(((F * fmin(A, C)) * 4.0))) / (t_0 * (-1.0 / sqrt(fabs(t_0))));
        	} else {
        		tmp = -(sqrt(fabs((F + F))) * sqrt((1.0 / fabs(fabs(B)))));
        	}
        	return tmp;
        }
        
        function code(A, B, C, F)
        	t_0 = fma(Float64(-4.0 * fmin(A, C)), fmax(A, C), Float64(abs(B) * abs(B)))
        	tmp = 0.0
        	if (abs(B) <= 6.214827610791501e+20)
        		tmp = Float64(sqrt(abs(Float64(Float64(F * fmin(A, C)) * 4.0))) / Float64(t_0 * Float64(-1.0 / sqrt(abs(t_0)))));
        	else
        		tmp = Float64(-Float64(sqrt(abs(Float64(F + F))) * sqrt(Float64(1.0 / abs(abs(B))))));
        	end
        	return tmp
        end
        
        code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[(-4.0 * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * N[Max[A, C], $MachinePrecision] + N[(N[Abs[B], $MachinePrecision] * N[Abs[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Abs[B], $MachinePrecision], 6.214827610791501e+20], N[(N[Sqrt[N[Abs[N[(N[(F * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] / N[(t$95$0 * N[(-1.0 / N[Sqrt[N[Abs[t$95$0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], (-N[(N[Sqrt[N[Abs[N[(F + F), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(1.0 / N[Abs[N[Abs[B], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]]
        
        f(A, B, C, F):
        	A in [-inf, +inf],
        	B in [-inf, +inf],
        	C in [-inf, +inf],
        	F in [-inf, +inf]
        code: THEORY
        BEGIN
        f(A, B, C, F: real): real =
        	LET tmp = IF (A < C) THEN A ELSE C ENDIF IN
        	LET tmp_1 = IF (A > C) THEN A ELSE C ENDIF IN
        	LET t_0 = ((((-4) * tmp) * tmp_1) + ((abs(B)) * (abs(B)))) IN
        		LET tmp_4 = IF (A < C) THEN A ELSE C ENDIF IN
        		LET tmp_3 = IF ((abs(B)) <= (621482761079150084096)) THEN ((sqrt((abs(((F * tmp_4) * (4)))))) / (t_0 * ((-1) / (sqrt((abs(t_0))))))) ELSE (- ((sqrt((abs((F + F))))) * (sqrt(((1) / (abs((abs(B))))))))) ENDIF IN
        	tmp_3
        END code
        \begin{array}{l}
        t_0 := \mathsf{fma}\left(-4 \cdot \mathsf{min}\left(A, C\right), \mathsf{max}\left(A, C\right), \left|B\right| \cdot \left|B\right|\right)\\
        \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\
        \;\;\;\;\frac{\sqrt{\left|\left(F \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4\right|}}{t\_0 \cdot \frac{-1}{\sqrt{\left|t\_0\right|}}}\\
        
        \mathbf{else}:\\
        \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\
        
        
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if B < 621482761079150080000

          1. Initial program 19.2%

            \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
          2. Applied rewrites24.9%

            \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|\left(F + F\right) \cdot \left(\left(C + A\right) - \sqrt{\mathsf{fma}\left(C - A, C - A, B \cdot B\right)}\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
          3. Taylor expanded in A around -inf

            \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
          4. Step-by-step derivation
            1. Applied rewrites20.3%

              \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
            2. Step-by-step derivation
              1. Applied rewrites20.3%

                \[\leadsto \frac{-\frac{1}{{\left(\sqrt{\left|\mathsf{fma}\left(-4 \cdot C, A, B \cdot B\right)\right|}\right)}^{-1}} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
              2. Applied rewrites20.3%

                \[\leadsto \frac{\sqrt{\left|\left(F \cdot A\right) \cdot 4\right|}}{\mathsf{fma}\left(-4 \cdot A, C, B \cdot B\right) \cdot \frac{-1}{\sqrt{\left|\mathsf{fma}\left(-4 \cdot A, C, B \cdot B\right)\right|}}} \]

              if 621482761079150080000 < B

              1. Initial program 19.2%

                \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
              2. Taylor expanded in B around inf

                \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
              3. Step-by-step derivation
                1. Applied rewrites13.6%

                  \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                2. Applied rewrites13.6%

                  \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                3. Step-by-step derivation
                  1. Applied rewrites35.6%

                    \[\leadsto -\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|B\right|}} \]
                4. Recombined 2 regimes into one program.
                5. Add Preprocessing

                Alternative 3: 58.7% accurate, 1.7× speedup?

                \[\begin{array}{l} t_0 := \left|B\right| \cdot \left|B\right|\\ \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\ \;\;\;\;\sqrt{\left|\mathsf{fma}\left(-4 \cdot \mathsf{max}\left(A, C\right), \mathsf{min}\left(A, C\right), t\_0\right)\right|} \cdot \frac{\sqrt{\left|\left(F \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4\right|}}{\left(\mathsf{max}\left(A, C\right) \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4 - t\_0}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\ \end{array} \]
                (FPCore (A B C F)
                  :precision binary64
                  :pre TRUE
                  (let* ((t_0 (* (fabs B) (fabs B))))
                  (if (<= (fabs B) 6.214827610791501e+20)
                    (*
                     (sqrt (fabs (fma (* -4.0 (fmax A C)) (fmin A C) t_0)))
                     (/
                      (sqrt (fabs (* (* F (fmin A C)) 4.0)))
                      (- (* (* (fmax A C) (fmin A C)) 4.0) t_0)))
                    (- (* (sqrt (fabs (+ F F))) (sqrt (/ 1.0 (fabs (fabs B)))))))))
                double code(double A, double B, double C, double F) {
                	double t_0 = fabs(B) * fabs(B);
                	double tmp;
                	if (fabs(B) <= 6.214827610791501e+20) {
                		tmp = sqrt(fabs(fma((-4.0 * fmax(A, C)), fmin(A, C), t_0))) * (sqrt(fabs(((F * fmin(A, C)) * 4.0))) / (((fmax(A, C) * fmin(A, C)) * 4.0) - t_0));
                	} else {
                		tmp = -(sqrt(fabs((F + F))) * sqrt((1.0 / fabs(fabs(B)))));
                	}
                	return tmp;
                }
                
                function code(A, B, C, F)
                	t_0 = Float64(abs(B) * abs(B))
                	tmp = 0.0
                	if (abs(B) <= 6.214827610791501e+20)
                		tmp = Float64(sqrt(abs(fma(Float64(-4.0 * fmax(A, C)), fmin(A, C), t_0))) * Float64(sqrt(abs(Float64(Float64(F * fmin(A, C)) * 4.0))) / Float64(Float64(Float64(fmax(A, C) * fmin(A, C)) * 4.0) - t_0)));
                	else
                		tmp = Float64(-Float64(sqrt(abs(Float64(F + F))) * sqrt(Float64(1.0 / abs(abs(B))))));
                	end
                	return tmp
                end
                
                code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[Abs[B], $MachinePrecision] * N[Abs[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Abs[B], $MachinePrecision], 6.214827610791501e+20], N[(N[Sqrt[N[Abs[N[(N[(-4.0 * N[Max[A, C], $MachinePrecision]), $MachinePrecision] * N[Min[A, C], $MachinePrecision] + t$95$0), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[Sqrt[N[Abs[N[(N[(F * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] / N[(N[(N[(N[Max[A, C], $MachinePrecision] * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision] - t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], (-N[(N[Sqrt[N[Abs[N[(F + F), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(1.0 / N[Abs[N[Abs[B], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]]
                
                f(A, B, C, F):
                	A in [-inf, +inf],
                	B in [-inf, +inf],
                	C in [-inf, +inf],
                	F in [-inf, +inf]
                code: THEORY
                BEGIN
                f(A, B, C, F: real): real =
                	LET t_0 = ((abs(B)) * (abs(B))) IN
                		LET tmp_6 = IF (A > C) THEN A ELSE C ENDIF IN
                		LET tmp_7 = IF (A < C) THEN A ELSE C ENDIF IN
                		LET tmp_8 = IF (A < C) THEN A ELSE C ENDIF IN
                		LET tmp_9 = IF (A > C) THEN A ELSE C ENDIF IN
                		LET tmp_10 = IF (A < C) THEN A ELSE C ENDIF IN
                		LET tmp_5 = IF ((abs(B)) <= (621482761079150084096)) THEN ((sqrt((abs(((((-4) * tmp_6) * tmp_7) + t_0))))) * ((sqrt((abs(((F * tmp_8) * (4)))))) / (((tmp_9 * tmp_10) * (4)) - t_0))) ELSE (- ((sqrt((abs((F + F))))) * (sqrt(((1) / (abs((abs(B))))))))) ENDIF IN
                	tmp_5
                END code
                \begin{array}{l}
                t_0 := \left|B\right| \cdot \left|B\right|\\
                \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\
                \;\;\;\;\sqrt{\left|\mathsf{fma}\left(-4 \cdot \mathsf{max}\left(A, C\right), \mathsf{min}\left(A, C\right), t\_0\right)\right|} \cdot \frac{\sqrt{\left|\left(F \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4\right|}}{\left(\mathsf{max}\left(A, C\right) \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4 - t\_0}\\
                
                \mathbf{else}:\\
                \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\
                
                
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if B < 621482761079150080000

                  1. Initial program 19.2%

                    \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                  2. Applied rewrites24.9%

                    \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|\left(F + F\right) \cdot \left(\left(C + A\right) - \sqrt{\mathsf{fma}\left(C - A, C - A, B \cdot B\right)}\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                  3. Taylor expanded in A around -inf

                    \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                  4. Step-by-step derivation
                    1. Applied rewrites20.3%

                      \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                    2. Applied rewrites19.6%

                      \[\leadsto \sqrt{\left|\mathsf{fma}\left(-4 \cdot C, A, B \cdot B\right)\right|} \cdot \frac{\sqrt{\left|\left(F \cdot A\right) \cdot 4\right|}}{\left(C \cdot A\right) \cdot 4 - B \cdot B} \]

                    if 621482761079150080000 < B

                    1. Initial program 19.2%

                      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                    2. Taylor expanded in B around inf

                      \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                    3. Step-by-step derivation
                      1. Applied rewrites13.6%

                        \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                      2. Applied rewrites13.6%

                        \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                      3. Step-by-step derivation
                        1. Applied rewrites35.6%

                          \[\leadsto -\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|B\right|}} \]
                      4. Recombined 2 regimes into one program.
                      5. Add Preprocessing

                      Alternative 4: 53.1% accurate, 1.8× speedup?

                      \[\begin{array}{l} t_0 := \left|B\right| \cdot \left|B\right|\\ \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\ \;\;\;\;\frac{\sqrt{\left|\left(\left(F \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4\right) \cdot \mathsf{fma}\left(-4 \cdot \mathsf{max}\left(A, C\right), \mathsf{min}\left(A, C\right), t\_0\right)\right|}}{\left(\mathsf{max}\left(A, C\right) \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4 - t\_0}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\ \end{array} \]
                      (FPCore (A B C F)
                        :precision binary64
                        :pre TRUE
                        (let* ((t_0 (* (fabs B) (fabs B))))
                        (if (<= (fabs B) 6.214827610791501e+20)
                          (/
                           (sqrt
                            (fabs
                             (*
                              (* (* F (fmin A C)) 4.0)
                              (fma (* -4.0 (fmax A C)) (fmin A C) t_0))))
                           (- (* (* (fmax A C) (fmin A C)) 4.0) t_0))
                          (- (* (sqrt (fabs (+ F F))) (sqrt (/ 1.0 (fabs (fabs B)))))))))
                      double code(double A, double B, double C, double F) {
                      	double t_0 = fabs(B) * fabs(B);
                      	double tmp;
                      	if (fabs(B) <= 6.214827610791501e+20) {
                      		tmp = sqrt(fabs((((F * fmin(A, C)) * 4.0) * fma((-4.0 * fmax(A, C)), fmin(A, C), t_0)))) / (((fmax(A, C) * fmin(A, C)) * 4.0) - t_0);
                      	} else {
                      		tmp = -(sqrt(fabs((F + F))) * sqrt((1.0 / fabs(fabs(B)))));
                      	}
                      	return tmp;
                      }
                      
                      function code(A, B, C, F)
                      	t_0 = Float64(abs(B) * abs(B))
                      	tmp = 0.0
                      	if (abs(B) <= 6.214827610791501e+20)
                      		tmp = Float64(sqrt(abs(Float64(Float64(Float64(F * fmin(A, C)) * 4.0) * fma(Float64(-4.0 * fmax(A, C)), fmin(A, C), t_0)))) / Float64(Float64(Float64(fmax(A, C) * fmin(A, C)) * 4.0) - t_0));
                      	else
                      		tmp = Float64(-Float64(sqrt(abs(Float64(F + F))) * sqrt(Float64(1.0 / abs(abs(B))))));
                      	end
                      	return tmp
                      end
                      
                      code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[Abs[B], $MachinePrecision] * N[Abs[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Abs[B], $MachinePrecision], 6.214827610791501e+20], N[(N[Sqrt[N[Abs[N[(N[(N[(F * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision] * N[(N[(-4.0 * N[Max[A, C], $MachinePrecision]), $MachinePrecision] * N[Min[A, C], $MachinePrecision] + t$95$0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] / N[(N[(N[(N[Max[A, C], $MachinePrecision] * N[Min[A, C], $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision] - t$95$0), $MachinePrecision]), $MachinePrecision], (-N[(N[Sqrt[N[Abs[N[(F + F), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(1.0 / N[Abs[N[Abs[B], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]]
                      
                      f(A, B, C, F):
                      	A in [-inf, +inf],
                      	B in [-inf, +inf],
                      	C in [-inf, +inf],
                      	F in [-inf, +inf]
                      code: THEORY
                      BEGIN
                      f(A, B, C, F: real): real =
                      	LET t_0 = ((abs(B)) * (abs(B))) IN
                      		LET tmp_6 = IF (A < C) THEN A ELSE C ENDIF IN
                      		LET tmp_7 = IF (A > C) THEN A ELSE C ENDIF IN
                      		LET tmp_8 = IF (A < C) THEN A ELSE C ENDIF IN
                      		LET tmp_9 = IF (A > C) THEN A ELSE C ENDIF IN
                      		LET tmp_10 = IF (A < C) THEN A ELSE C ENDIF IN
                      		LET tmp_5 = IF ((abs(B)) <= (621482761079150084096)) THEN ((sqrt((abs((((F * tmp_6) * (4)) * ((((-4) * tmp_7) * tmp_8) + t_0)))))) / (((tmp_9 * tmp_10) * (4)) - t_0)) ELSE (- ((sqrt((abs((F + F))))) * (sqrt(((1) / (abs((abs(B))))))))) ENDIF IN
                      	tmp_5
                      END code
                      \begin{array}{l}
                      t_0 := \left|B\right| \cdot \left|B\right|\\
                      \mathbf{if}\;\left|B\right| \leq 6.214827610791501 \cdot 10^{+20}:\\
                      \;\;\;\;\frac{\sqrt{\left|\left(\left(F \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4\right) \cdot \mathsf{fma}\left(-4 \cdot \mathsf{max}\left(A, C\right), \mathsf{min}\left(A, C\right), t\_0\right)\right|}}{\left(\mathsf{max}\left(A, C\right) \cdot \mathsf{min}\left(A, C\right)\right) \cdot 4 - t\_0}\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\
                      
                      
                      \end{array}
                      
                      Derivation
                      1. Split input into 2 regimes
                      2. if B < 621482761079150080000

                        1. Initial program 19.2%

                          \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                        2. Applied rewrites24.9%

                          \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|\left(F + F\right) \cdot \left(\left(C + A\right) - \sqrt{\mathsf{fma}\left(C - A, C - A, B \cdot B\right)}\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                        3. Taylor expanded in A around -inf

                          \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                        4. Step-by-step derivation
                          1. Applied rewrites20.3%

                            \[\leadsto \frac{-\sqrt{\left|\mathsf{fma}\left(C \cdot -4, A, B \cdot B\right)\right|} \cdot \sqrt{\left|4 \cdot \left(A \cdot F\right)\right|}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                          2. Applied rewrites15.7%

                            \[\leadsto \frac{\sqrt{\left|\left(\left(F \cdot A\right) \cdot 4\right) \cdot \mathsf{fma}\left(-4 \cdot C, A, B \cdot B\right)\right|}}{\left(C \cdot A\right) \cdot 4 - B \cdot B} \]

                          if 621482761079150080000 < B

                          1. Initial program 19.2%

                            \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                          2. Taylor expanded in B around inf

                            \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                          3. Step-by-step derivation
                            1. Applied rewrites13.6%

                              \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                            2. Applied rewrites13.6%

                              \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                            3. Step-by-step derivation
                              1. Applied rewrites35.6%

                                \[\leadsto -\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|B\right|}} \]
                            4. Recombined 2 regimes into one program.
                            5. Add Preprocessing

                            Alternative 5: 52.7% accurate, 4.3× speedup?

                            \[\begin{array}{l} \mathbf{if}\;\left|B\right| \leq 2.185206893097166 \cdot 10^{-86}:\\ \;\;\;\;-0.25 \cdot \frac{\sqrt{-16 \cdot \left(\mathsf{max}\left(A, C\right) \cdot F\right)}}{\mathsf{max}\left(A, C\right)}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\ \end{array} \]
                            (FPCore (A B C F)
                              :precision binary64
                              :pre TRUE
                              (if (<= (fabs B) 2.185206893097166e-86)
                              (* -0.25 (/ (sqrt (* -16.0 (* (fmax A C) F))) (fmax A C)))
                              (- (* (sqrt (fabs (+ F F))) (sqrt (/ 1.0 (fabs (fabs B))))))))
                            double code(double A, double B, double C, double F) {
                            	double tmp;
                            	if (fabs(B) <= 2.185206893097166e-86) {
                            		tmp = -0.25 * (sqrt((-16.0 * (fmax(A, C) * F))) / fmax(A, C));
                            	} else {
                            		tmp = -(sqrt(fabs((F + F))) * sqrt((1.0 / fabs(fabs(B)))));
                            	}
                            	return tmp;
                            }
                            
                            real(8) function code(a, b, c, f)
                            use fmin_fmax_functions
                                real(8), intent (in) :: a
                                real(8), intent (in) :: b
                                real(8), intent (in) :: c
                                real(8), intent (in) :: f
                                real(8) :: tmp
                                if (abs(b) <= 2.185206893097166d-86) then
                                    tmp = (-0.25d0) * (sqrt(((-16.0d0) * (fmax(a, c) * f))) / fmax(a, c))
                                else
                                    tmp = -(sqrt(abs((f + f))) * sqrt((1.0d0 / abs(abs(b)))))
                                end if
                                code = tmp
                            end function
                            
                            public static double code(double A, double B, double C, double F) {
                            	double tmp;
                            	if (Math.abs(B) <= 2.185206893097166e-86) {
                            		tmp = -0.25 * (Math.sqrt((-16.0 * (fmax(A, C) * F))) / fmax(A, C));
                            	} else {
                            		tmp = -(Math.sqrt(Math.abs((F + F))) * Math.sqrt((1.0 / Math.abs(Math.abs(B)))));
                            	}
                            	return tmp;
                            }
                            
                            def code(A, B, C, F):
                            	tmp = 0
                            	if math.fabs(B) <= 2.185206893097166e-86:
                            		tmp = -0.25 * (math.sqrt((-16.0 * (fmax(A, C) * F))) / fmax(A, C))
                            	else:
                            		tmp = -(math.sqrt(math.fabs((F + F))) * math.sqrt((1.0 / math.fabs(math.fabs(B)))))
                            	return tmp
                            
                            function code(A, B, C, F)
                            	tmp = 0.0
                            	if (abs(B) <= 2.185206893097166e-86)
                            		tmp = Float64(-0.25 * Float64(sqrt(Float64(-16.0 * Float64(fmax(A, C) * F))) / fmax(A, C)));
                            	else
                            		tmp = Float64(-Float64(sqrt(abs(Float64(F + F))) * sqrt(Float64(1.0 / abs(abs(B))))));
                            	end
                            	return tmp
                            end
                            
                            function tmp_2 = code(A, B, C, F)
                            	tmp = 0.0;
                            	if (abs(B) <= 2.185206893097166e-86)
                            		tmp = -0.25 * (sqrt((-16.0 * (max(A, C) * F))) / max(A, C));
                            	else
                            		tmp = -(sqrt(abs((F + F))) * sqrt((1.0 / abs(abs(B)))));
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            code[A_, B_, C_, F_] := If[LessEqual[N[Abs[B], $MachinePrecision], 2.185206893097166e-86], N[(-0.25 * N[(N[Sqrt[N[(-16.0 * N[(N[Max[A, C], $MachinePrecision] * F), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Max[A, C], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], (-N[(N[Sqrt[N[Abs[N[(F + F), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(1.0 / N[Abs[N[Abs[B], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]
                            
                            f(A, B, C, F):
                            	A in [-inf, +inf],
                            	B in [-inf, +inf],
                            	C in [-inf, +inf],
                            	F in [-inf, +inf]
                            code: THEORY
                            BEGIN
                            f(A, B, C, F: real): real =
                            	LET tmp_3 = IF (A > C) THEN A ELSE C ENDIF IN
                            	LET tmp_4 = IF (A > C) THEN A ELSE C ENDIF IN
                            	LET tmp_2 = IF ((abs(B)) <= (218520689309716607584212702156401430072517028504360065962079226682236356000747442372593782807492504447498037620917440821845640855543927858022800660004620647762367861234046727990999322559392714746452902240537161972222524042308577918447554111480712890625e-337)) THEN ((-25e-2) * ((sqrt(((-16) * (tmp_3 * F)))) / tmp_4)) ELSE (- ((sqrt((abs((F + F))))) * (sqrt(((1) / (abs((abs(B))))))))) ENDIF IN
                            	tmp_2
                            END code
                            \begin{array}{l}
                            \mathbf{if}\;\left|B\right| \leq 2.185206893097166 \cdot 10^{-86}:\\
                            \;\;\;\;-0.25 \cdot \frac{\sqrt{-16 \cdot \left(\mathsf{max}\left(A, C\right) \cdot F\right)}}{\mathsf{max}\left(A, C\right)}\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;-\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|\left|B\right|\right|}}\\
                            
                            
                            \end{array}
                            
                            Derivation
                            1. Split input into 2 regimes
                            2. if B < 2.1852068930971661e-86

                              1. Initial program 19.2%

                                \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                              2. Taylor expanded in A around -inf

                                \[\leadsto \frac{-1}{4} \cdot \frac{\sqrt{-16 \cdot \left(C \cdot F\right)}}{C} \]
                              3. Step-by-step derivation
                                1. Applied rewrites19.3%

                                  \[\leadsto -0.25 \cdot \frac{\sqrt{-16 \cdot \left(C \cdot F\right)}}{C} \]

                                if 2.1852068930971661e-86 < B

                                1. Initial program 19.2%

                                  \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                2. Taylor expanded in B around inf

                                  \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                3. Step-by-step derivation
                                  1. Applied rewrites13.6%

                                    \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                  2. Applied rewrites13.6%

                                    \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                                  3. Step-by-step derivation
                                    1. Applied rewrites35.6%

                                      \[\leadsto -\sqrt{\left|F + F\right|} \cdot \sqrt{\frac{1}{\left|B\right|}} \]
                                  4. Recombined 2 regimes into one program.
                                  5. Add Preprocessing

                                  Alternative 6: 52.7% accurate, 4.3× speedup?

                                  \[\begin{array}{l} \mathbf{if}\;\left|B\right| \leq 2.185206893097166 \cdot 10^{-86}:\\ \;\;\;\;-0.25 \cdot \frac{\sqrt{-16 \cdot \left(\mathsf{max}\left(A, C\right) \cdot F\right)}}{\mathsf{max}\left(A, C\right)}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{\left|F\right|} \cdot \sqrt{\left|\frac{-2}{\left|B\right|}\right|}\\ \end{array} \]
                                  (FPCore (A B C F)
                                    :precision binary64
                                    :pre TRUE
                                    (if (<= (fabs B) 2.185206893097166e-86)
                                    (* -0.25 (/ (sqrt (* -16.0 (* (fmax A C) F))) (fmax A C)))
                                    (- (* (sqrt (fabs F)) (sqrt (fabs (/ -2.0 (fabs B))))))))
                                  double code(double A, double B, double C, double F) {
                                  	double tmp;
                                  	if (fabs(B) <= 2.185206893097166e-86) {
                                  		tmp = -0.25 * (sqrt((-16.0 * (fmax(A, C) * F))) / fmax(A, C));
                                  	} else {
                                  		tmp = -(sqrt(fabs(F)) * sqrt(fabs((-2.0 / fabs(B)))));
                                  	}
                                  	return tmp;
                                  }
                                  
                                  real(8) function code(a, b, c, f)
                                  use fmin_fmax_functions
                                      real(8), intent (in) :: a
                                      real(8), intent (in) :: b
                                      real(8), intent (in) :: c
                                      real(8), intent (in) :: f
                                      real(8) :: tmp
                                      if (abs(b) <= 2.185206893097166d-86) then
                                          tmp = (-0.25d0) * (sqrt(((-16.0d0) * (fmax(a, c) * f))) / fmax(a, c))
                                      else
                                          tmp = -(sqrt(abs(f)) * sqrt(abs(((-2.0d0) / abs(b)))))
                                      end if
                                      code = tmp
                                  end function
                                  
                                  public static double code(double A, double B, double C, double F) {
                                  	double tmp;
                                  	if (Math.abs(B) <= 2.185206893097166e-86) {
                                  		tmp = -0.25 * (Math.sqrt((-16.0 * (fmax(A, C) * F))) / fmax(A, C));
                                  	} else {
                                  		tmp = -(Math.sqrt(Math.abs(F)) * Math.sqrt(Math.abs((-2.0 / Math.abs(B)))));
                                  	}
                                  	return tmp;
                                  }
                                  
                                  def code(A, B, C, F):
                                  	tmp = 0
                                  	if math.fabs(B) <= 2.185206893097166e-86:
                                  		tmp = -0.25 * (math.sqrt((-16.0 * (fmax(A, C) * F))) / fmax(A, C))
                                  	else:
                                  		tmp = -(math.sqrt(math.fabs(F)) * math.sqrt(math.fabs((-2.0 / math.fabs(B)))))
                                  	return tmp
                                  
                                  function code(A, B, C, F)
                                  	tmp = 0.0
                                  	if (abs(B) <= 2.185206893097166e-86)
                                  		tmp = Float64(-0.25 * Float64(sqrt(Float64(-16.0 * Float64(fmax(A, C) * F))) / fmax(A, C)));
                                  	else
                                  		tmp = Float64(-Float64(sqrt(abs(F)) * sqrt(abs(Float64(-2.0 / abs(B))))));
                                  	end
                                  	return tmp
                                  end
                                  
                                  function tmp_2 = code(A, B, C, F)
                                  	tmp = 0.0;
                                  	if (abs(B) <= 2.185206893097166e-86)
                                  		tmp = -0.25 * (sqrt((-16.0 * (max(A, C) * F))) / max(A, C));
                                  	else
                                  		tmp = -(sqrt(abs(F)) * sqrt(abs((-2.0 / abs(B)))));
                                  	end
                                  	tmp_2 = tmp;
                                  end
                                  
                                  code[A_, B_, C_, F_] := If[LessEqual[N[Abs[B], $MachinePrecision], 2.185206893097166e-86], N[(-0.25 * N[(N[Sqrt[N[(-16.0 * N[(N[Max[A, C], $MachinePrecision] * F), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Max[A, C], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], (-N[(N[Sqrt[N[Abs[F], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[Abs[N[(-2.0 / N[Abs[B], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]
                                  
                                  f(A, B, C, F):
                                  	A in [-inf, +inf],
                                  	B in [-inf, +inf],
                                  	C in [-inf, +inf],
                                  	F in [-inf, +inf]
                                  code: THEORY
                                  BEGIN
                                  f(A, B, C, F: real): real =
                                  	LET tmp_3 = IF (A > C) THEN A ELSE C ENDIF IN
                                  	LET tmp_4 = IF (A > C) THEN A ELSE C ENDIF IN
                                  	LET tmp_2 = IF ((abs(B)) <= (218520689309716607584212702156401430072517028504360065962079226682236356000747442372593782807492504447498037620917440821845640855543927858022800660004620647762367861234046727990999322559392714746452902240537161972222524042308577918447554111480712890625e-337)) THEN ((-25e-2) * ((sqrt(((-16) * (tmp_3 * F)))) / tmp_4)) ELSE (- ((sqrt((abs(F)))) * (sqrt((abs(((-2) / (abs(B))))))))) ENDIF IN
                                  	tmp_2
                                  END code
                                  \begin{array}{l}
                                  \mathbf{if}\;\left|B\right| \leq 2.185206893097166 \cdot 10^{-86}:\\
                                  \;\;\;\;-0.25 \cdot \frac{\sqrt{-16 \cdot \left(\mathsf{max}\left(A, C\right) \cdot F\right)}}{\mathsf{max}\left(A, C\right)}\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;-\sqrt{\left|F\right|} \cdot \sqrt{\left|\frac{-2}{\left|B\right|}\right|}\\
                                  
                                  
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 2 regimes
                                  2. if B < 2.1852068930971661e-86

                                    1. Initial program 19.2%

                                      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                    2. Taylor expanded in A around -inf

                                      \[\leadsto \frac{-1}{4} \cdot \frac{\sqrt{-16 \cdot \left(C \cdot F\right)}}{C} \]
                                    3. Step-by-step derivation
                                      1. Applied rewrites19.3%

                                        \[\leadsto -0.25 \cdot \frac{\sqrt{-16 \cdot \left(C \cdot F\right)}}{C} \]

                                      if 2.1852068930971661e-86 < B

                                      1. Initial program 19.2%

                                        \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                      2. Taylor expanded in B around inf

                                        \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                      3. Step-by-step derivation
                                        1. Applied rewrites13.6%

                                          \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                        2. Applied rewrites13.6%

                                          \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                                        3. Step-by-step derivation
                                          1. Applied rewrites35.6%

                                            \[\leadsto -\sqrt{\left|F\right|} \cdot \sqrt{\left|\frac{-2}{B}\right|} \]
                                        4. Recombined 2 regimes into one program.
                                        5. Add Preprocessing

                                        Alternative 7: 35.6% accurate, 7.7× speedup?

                                        \[-\sqrt{\left|F\right|} \cdot \sqrt{\left|\frac{-2}{B}\right|} \]
                                        (FPCore (A B C F)
                                          :precision binary64
                                          :pre TRUE
                                          (- (* (sqrt (fabs F)) (sqrt (fabs (/ -2.0 B))))))
                                        double code(double A, double B, double C, double F) {
                                        	return -(sqrt(fabs(F)) * sqrt(fabs((-2.0 / B))));
                                        }
                                        
                                        real(8) function code(a, b, c, f)
                                        use fmin_fmax_functions
                                            real(8), intent (in) :: a
                                            real(8), intent (in) :: b
                                            real(8), intent (in) :: c
                                            real(8), intent (in) :: f
                                            code = -(sqrt(abs(f)) * sqrt(abs(((-2.0d0) / b))))
                                        end function
                                        
                                        public static double code(double A, double B, double C, double F) {
                                        	return -(Math.sqrt(Math.abs(F)) * Math.sqrt(Math.abs((-2.0 / B))));
                                        }
                                        
                                        def code(A, B, C, F):
                                        	return -(math.sqrt(math.fabs(F)) * math.sqrt(math.fabs((-2.0 / B))))
                                        
                                        function code(A, B, C, F)
                                        	return Float64(-Float64(sqrt(abs(F)) * sqrt(abs(Float64(-2.0 / B)))))
                                        end
                                        
                                        function tmp = code(A, B, C, F)
                                        	tmp = -(sqrt(abs(F)) * sqrt(abs((-2.0 / B))));
                                        end
                                        
                                        code[A_, B_, C_, F_] := (-N[(N[Sqrt[N[Abs[F], $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[Abs[N[(-2.0 / B), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision])
                                        
                                        f(A, B, C, F):
                                        	A in [-inf, +inf],
                                        	B in [-inf, +inf],
                                        	C in [-inf, +inf],
                                        	F in [-inf, +inf]
                                        code: THEORY
                                        BEGIN
                                        f(A, B, C, F: real): real =
                                        	- ((sqrt((abs(F)))) * (sqrt((abs(((-2) / B))))))
                                        END code
                                        -\sqrt{\left|F\right|} \cdot \sqrt{\left|\frac{-2}{B}\right|}
                                        
                                        Derivation
                                        1. Initial program 19.2%

                                          \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                        2. Taylor expanded in B around inf

                                          \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                        3. Step-by-step derivation
                                          1. Applied rewrites13.6%

                                            \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                          2. Applied rewrites13.6%

                                            \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                                          3. Step-by-step derivation
                                            1. Applied rewrites35.6%

                                              \[\leadsto -\sqrt{\left|F\right|} \cdot \sqrt{\left|\frac{-2}{B}\right|} \]
                                            2. Add Preprocessing

                                            Alternative 8: 35.6% accurate, 7.9× speedup?

                                            \[\frac{\sqrt{\left|F + F\right|}}{-\sqrt{\left|B\right|}} \]
                                            (FPCore (A B C F)
                                              :precision binary64
                                              :pre TRUE
                                              (/ (sqrt (fabs (+ F F))) (- (sqrt (fabs B)))))
                                            double code(double A, double B, double C, double F) {
                                            	return sqrt(fabs((F + F))) / -sqrt(fabs(B));
                                            }
                                            
                                            real(8) function code(a, b, c, f)
                                            use fmin_fmax_functions
                                                real(8), intent (in) :: a
                                                real(8), intent (in) :: b
                                                real(8), intent (in) :: c
                                                real(8), intent (in) :: f
                                                code = sqrt(abs((f + f))) / -sqrt(abs(b))
                                            end function
                                            
                                            public static double code(double A, double B, double C, double F) {
                                            	return Math.sqrt(Math.abs((F + F))) / -Math.sqrt(Math.abs(B));
                                            }
                                            
                                            def code(A, B, C, F):
                                            	return math.sqrt(math.fabs((F + F))) / -math.sqrt(math.fabs(B))
                                            
                                            function code(A, B, C, F)
                                            	return Float64(sqrt(abs(Float64(F + F))) / Float64(-sqrt(abs(B))))
                                            end
                                            
                                            function tmp = code(A, B, C, F)
                                            	tmp = sqrt(abs((F + F))) / -sqrt(abs(B));
                                            end
                                            
                                            code[A_, B_, C_, F_] := N[(N[Sqrt[N[Abs[N[(F + F), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] / (-N[Sqrt[N[Abs[B], $MachinePrecision]], $MachinePrecision])), $MachinePrecision]
                                            
                                            f(A, B, C, F):
                                            	A in [-inf, +inf],
                                            	B in [-inf, +inf],
                                            	C in [-inf, +inf],
                                            	F in [-inf, +inf]
                                            code: THEORY
                                            BEGIN
                                            f(A, B, C, F: real): real =
                                            	(sqrt((abs((F + F))))) / (- (sqrt((abs(B)))))
                                            END code
                                            \frac{\sqrt{\left|F + F\right|}}{-\sqrt{\left|B\right|}}
                                            
                                            Derivation
                                            1. Initial program 19.2%

                                              \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                            2. Taylor expanded in B around inf

                                              \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                            3. Step-by-step derivation
                                              1. Applied rewrites13.6%

                                                \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                              2. Step-by-step derivation
                                                1. Applied rewrites35.6%

                                                  \[\leadsto \frac{\sqrt{\left|F + F\right|}}{-\sqrt{\left|B\right|}} \]
                                                2. Add Preprocessing

                                                Alternative 9: 27.3% accurate, 10.0× speedup?

                                                \[-\sqrt{\left|\frac{F + F}{B}\right|} \]
                                                (FPCore (A B C F)
                                                  :precision binary64
                                                  :pre TRUE
                                                  (- (sqrt (fabs (/ (+ F F) B)))))
                                                double code(double A, double B, double C, double F) {
                                                	return -sqrt(fabs(((F + F) / B)));
                                                }
                                                
                                                real(8) function code(a, b, c, f)
                                                use fmin_fmax_functions
                                                    real(8), intent (in) :: a
                                                    real(8), intent (in) :: b
                                                    real(8), intent (in) :: c
                                                    real(8), intent (in) :: f
                                                    code = -sqrt(abs(((f + f) / b)))
                                                end function
                                                
                                                public static double code(double A, double B, double C, double F) {
                                                	return -Math.sqrt(Math.abs(((F + F) / B)));
                                                }
                                                
                                                def code(A, B, C, F):
                                                	return -math.sqrt(math.fabs(((F + F) / B)))
                                                
                                                function code(A, B, C, F)
                                                	return Float64(-sqrt(abs(Float64(Float64(F + F) / B))))
                                                end
                                                
                                                function tmp = code(A, B, C, F)
                                                	tmp = -sqrt(abs(((F + F) / B)));
                                                end
                                                
                                                code[A_, B_, C_, F_] := (-N[Sqrt[N[Abs[N[(N[(F + F), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]], $MachinePrecision])
                                                
                                                f(A, B, C, F):
                                                	A in [-inf, +inf],
                                                	B in [-inf, +inf],
                                                	C in [-inf, +inf],
                                                	F in [-inf, +inf]
                                                code: THEORY
                                                BEGIN
                                                f(A, B, C, F: real): real =
                                                	- (sqrt((abs(((F + F) / B)))))
                                                END code
                                                -\sqrt{\left|\frac{F + F}{B}\right|}
                                                
                                                Derivation
                                                1. Initial program 19.2%

                                                  \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                                2. Taylor expanded in B around inf

                                                  \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                                3. Step-by-step derivation
                                                  1. Applied rewrites13.6%

                                                    \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                                  2. Applied rewrites13.6%

                                                    \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                                                  3. Step-by-step derivation
                                                    1. Applied rewrites27.3%

                                                      \[\leadsto -\sqrt{\left|\frac{F + F}{B}\right|} \]
                                                    2. Add Preprocessing

                                                    Alternative 10: 14.3% accurate, 10.6× speedup?

                                                    \[-\sqrt{\frac{F}{B} \cdot -2} \]
                                                    (FPCore (A B C F)
                                                      :precision binary64
                                                      :pre TRUE
                                                      (- (sqrt (* (/ F B) -2.0))))
                                                    double code(double A, double B, double C, double F) {
                                                    	return -sqrt(((F / B) * -2.0));
                                                    }
                                                    
                                                    real(8) function code(a, b, c, f)
                                                    use fmin_fmax_functions
                                                        real(8), intent (in) :: a
                                                        real(8), intent (in) :: b
                                                        real(8), intent (in) :: c
                                                        real(8), intent (in) :: f
                                                        code = -sqrt(((f / b) * (-2.0d0)))
                                                    end function
                                                    
                                                    public static double code(double A, double B, double C, double F) {
                                                    	return -Math.sqrt(((F / B) * -2.0));
                                                    }
                                                    
                                                    def code(A, B, C, F):
                                                    	return -math.sqrt(((F / B) * -2.0))
                                                    
                                                    function code(A, B, C, F)
                                                    	return Float64(-sqrt(Float64(Float64(F / B) * -2.0)))
                                                    end
                                                    
                                                    function tmp = code(A, B, C, F)
                                                    	tmp = -sqrt(((F / B) * -2.0));
                                                    end
                                                    
                                                    code[A_, B_, C_, F_] := (-N[Sqrt[N[(N[(F / B), $MachinePrecision] * -2.0), $MachinePrecision]], $MachinePrecision])
                                                    
                                                    f(A, B, C, F):
                                                    	A in [-inf, +inf],
                                                    	B in [-inf, +inf],
                                                    	C in [-inf, +inf],
                                                    	F in [-inf, +inf]
                                                    code: THEORY
                                                    BEGIN
                                                    f(A, B, C, F: real): real =
                                                    	- (sqrt(((F / B) * (-2))))
                                                    END code
                                                    -\sqrt{\frac{F}{B} \cdot -2}
                                                    
                                                    Derivation
                                                    1. Initial program 19.2%

                                                      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                                    2. Taylor expanded in B around inf

                                                      \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                                    3. Step-by-step derivation
                                                      1. Applied rewrites13.6%

                                                        \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                                      2. Applied rewrites13.6%

                                                        \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                                                      3. Add Preprocessing

                                                      Alternative 11: 13.6% accurate, 9.7× speedup?

                                                      \[-\sqrt{\left|F\right| \cdot \frac{-2}{B}} \]
                                                      (FPCore (A B C F)
                                                        :precision binary64
                                                        :pre TRUE
                                                        (- (sqrt (* (fabs F) (/ -2.0 B)))))
                                                      double code(double A, double B, double C, double F) {
                                                      	return -sqrt((fabs(F) * (-2.0 / B)));
                                                      }
                                                      
                                                      real(8) function code(a, b, c, f)
                                                      use fmin_fmax_functions
                                                          real(8), intent (in) :: a
                                                          real(8), intent (in) :: b
                                                          real(8), intent (in) :: c
                                                          real(8), intent (in) :: f
                                                          code = -sqrt((abs(f) * ((-2.0d0) / b)))
                                                      end function
                                                      
                                                      public static double code(double A, double B, double C, double F) {
                                                      	return -Math.sqrt((Math.abs(F) * (-2.0 / B)));
                                                      }
                                                      
                                                      def code(A, B, C, F):
                                                      	return -math.sqrt((math.fabs(F) * (-2.0 / B)))
                                                      
                                                      function code(A, B, C, F)
                                                      	return Float64(-sqrt(Float64(abs(F) * Float64(-2.0 / B))))
                                                      end
                                                      
                                                      function tmp = code(A, B, C, F)
                                                      	tmp = -sqrt((abs(F) * (-2.0 / B)));
                                                      end
                                                      
                                                      code[A_, B_, C_, F_] := (-N[Sqrt[N[(N[Abs[F], $MachinePrecision] * N[(-2.0 / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])
                                                      
                                                      f(A, B, C, F):
                                                      	A in [-inf, +inf],
                                                      	B in [-inf, +inf],
                                                      	C in [-inf, +inf],
                                                      	F in [-inf, +inf]
                                                      code: THEORY
                                                      BEGIN
                                                      f(A, B, C, F: real): real =
                                                      	- (sqrt(((abs(F)) * ((-2) / B))))
                                                      END code
                                                      -\sqrt{\left|F\right| \cdot \frac{-2}{B}}
                                                      
                                                      Derivation
                                                      1. Initial program 19.2%

                                                        \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
                                                      2. Taylor expanded in B around inf

                                                        \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                                      3. Step-by-step derivation
                                                        1. Applied rewrites13.6%

                                                          \[\leadsto -1 \cdot \sqrt{-2 \cdot \frac{F}{B}} \]
                                                        2. Applied rewrites13.6%

                                                          \[\leadsto -\sqrt{\frac{F}{B} \cdot -2} \]
                                                        3. Step-by-step derivation
                                                          1. Applied rewrites13.6%

                                                            \[\leadsto -\sqrt{F \cdot \frac{-2}{B}} \]
                                                          2. Add Preprocessing

                                                          Reproduce

                                                          ?
                                                          herbie shell --seed 2026047 
                                                          (FPCore (A B C F)
                                                            :name "ABCF->ab-angle b"
                                                            :precision binary64
                                                            (/ (- (sqrt (* (* 2.0 (* (- (pow B 2.0) (* (* 4.0 A) C)) F)) (- (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))) (- (pow B 2.0) (* (* 4.0 A) C))))