ABCF->ab-angle a

Percentage Accurate: 19.4% → 51.8%
Time: 27.0s
Alternatives: 13
Speedup: 3.1×

Specification

?
\[\begin{array}{l} \\ \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} \end{array} \]
(FPCore (A B C F)
 :precision binary64
 (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)
    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]]
\begin{array}{l}

\\
\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}
\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 13 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.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \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} \end{array} \]
(FPCore (A B C F)
 :precision binary64
 (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)
    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]]
\begin{array}{l}

\\
\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}
\end{array}

Alternative 1: 51.8% accurate, 1.0× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} \mathbf{if}\;{B_m}^{2} \leq 10^{+14}:\\ \;\;\;\;\frac{\sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B_m\right)\right)} \cdot \left(-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\right)}\right)}{{B_m}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (if (<= (pow B_m 2.0) 1e+14)
   (/
    (*
     (sqrt (+ A (+ C (hypot (- A C) B_m))))
     (- (sqrt (* 2.0 (* F (fma B_m B_m (* A (* C -4.0))))))))
    (- (pow B_m 2.0) (* C (* A 4.0))))
   (* (/ (sqrt 2.0) B_m) (* (sqrt (+ A (hypot B_m A))) (- (sqrt F))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double tmp;
	if (pow(B_m, 2.0) <= 1e+14) {
		tmp = (sqrt((A + (C + hypot((A - C), B_m)))) * -sqrt((2.0 * (F * fma(B_m, B_m, (A * (C * -4.0))))))) / (pow(B_m, 2.0) - (C * (A * 4.0)));
	} else {
		tmp = (sqrt(2.0) / B_m) * (sqrt((A + hypot(B_m, A))) * -sqrt(F));
	}
	return tmp;
}
B_m = abs(B)
function code(A, B_m, C, F)
	tmp = 0.0
	if ((B_m ^ 2.0) <= 1e+14)
		tmp = Float64(Float64(sqrt(Float64(A + Float64(C + hypot(Float64(A - C), B_m)))) * Float64(-sqrt(Float64(2.0 * Float64(F * fma(B_m, B_m, Float64(A * Float64(C * -4.0)))))))) / Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0))));
	else
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(sqrt(Float64(A + hypot(B_m, A))) * Float64(-sqrt(F))));
	end
	return tmp
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 1e+14], N[(N[(N[Sqrt[N[(A + N[(C + N[Sqrt[N[(A - C), $MachinePrecision] ^ 2 + B$95$m ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[N[(2.0 * N[(F * N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision] / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[F], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
\mathbf{if}\;{B_m}^{2} \leq 10^{+14}:\\
\;\;\;\;\frac{\sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B_m\right)\right)} \cdot \left(-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\right)}\right)}{{B_m}^{2} - C \cdot \left(A \cdot 4\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 B 2) < 1e14

    1. Initial program 24.1%

      \[\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. Step-by-step derivation
      1. sqrt-prod25.9%

        \[\leadsto \frac{-\color{blue}{\sqrt{2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)} \cdot \sqrt{\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. associate-*r*25.9%

        \[\leadsto \frac{-\sqrt{\color{blue}{\left(2 \cdot \left({B}^{2} - \left(4 \cdot A\right) \cdot C\right)\right) \cdot F}} \cdot \sqrt{\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. associate-*l*25.9%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left({B}^{2} - \color{blue}{4 \cdot \left(A \cdot C\right)}\right)\right) \cdot F} \cdot \sqrt{\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      4. associate-+l+26.5%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right)\right) \cdot F} \cdot \sqrt{\color{blue}{A + \left(C + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      5. unpow226.5%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right)\right) \cdot F} \cdot \sqrt{A + \left(C + \sqrt{\color{blue}{\left(A - C\right) \cdot \left(A - C\right)} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      6. unpow226.5%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right)\right) \cdot F} \cdot \sqrt{A + \left(C + \sqrt{\left(A - C\right) \cdot \left(A - C\right) + \color{blue}{B \cdot B}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      7. hypot-def41.3%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right)\right) \cdot F} \cdot \sqrt{A + \left(C + \color{blue}{\mathsf{hypot}\left(A - C, B\right)}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    3. Applied egg-rr41.3%

      \[\leadsto \frac{-\color{blue}{\sqrt{\left(2 \cdot \left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right)\right) \cdot F} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    4. Step-by-step derivation
      1. associate-*l*41.3%

        \[\leadsto \frac{-\sqrt{\color{blue}{2 \cdot \left(\left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right) \cdot F\right)}} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. *-commutative41.3%

        \[\leadsto \frac{-\sqrt{2 \cdot \color{blue}{\left(F \cdot \left({B}^{2} - 4 \cdot \left(A \cdot C\right)\right)\right)}} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. unpow241.3%

        \[\leadsto \frac{-\sqrt{2 \cdot \left(F \cdot \left(\color{blue}{B \cdot B} - 4 \cdot \left(A \cdot C\right)\right)\right)} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      4. fma-neg41.3%

        \[\leadsto \frac{-\sqrt{2 \cdot \left(F \cdot \color{blue}{\mathsf{fma}\left(B, B, -4 \cdot \left(A \cdot C\right)\right)}\right)} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      5. distribute-lft-neg-in41.3%

        \[\leadsto \frac{-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B, B, \color{blue}{\left(-4\right) \cdot \left(A \cdot C\right)}\right)\right)} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      6. metadata-eval41.3%

        \[\leadsto \frac{-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B, B, \color{blue}{-4} \cdot \left(A \cdot C\right)\right)\right)} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      7. *-commutative41.3%

        \[\leadsto \frac{-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B, B, \color{blue}{\left(A \cdot C\right) \cdot -4}\right)\right)} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      8. associate-*l*41.4%

        \[\leadsto \frac{-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B, B, \color{blue}{A \cdot \left(C \cdot -4\right)}\right)\right)} \cdot \sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    5. Simplified41.4%

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

    if 1e14 < (pow.f64 B 2)

    1. Initial program 12.0%

      \[\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 C around 0 15.6%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg15.6%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in15.6%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative15.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow215.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow215.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def27.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified27.5%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/227.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}\right) \]
      2. *-commutative27.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}}^{0.5}\right) \]
      3. metadata-eval27.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}\right) \]
      4. unpow-prod-down39.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}}\right) \]
      5. metadata-eval39.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      6. pow1/239.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      7. metadata-eval39.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {F}^{\color{blue}{0.5}}\right) \]
      8. pow1/239.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{F}}\right) \]
    6. Applied egg-rr39.2%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{F}}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification40.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;{B}^{2} \leq 10^{+14}:\\ \;\;\;\;\frac{\sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)} \cdot \left(-\sqrt{2 \cdot \left(F \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)\right)}\right)}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \]

Alternative 2: 48.9% accurate, 1.2× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\ \mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{+131}:\\ \;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B_m, A - C\right)\right)\right)}}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (fma B_m B_m (* A (* C -4.0)))))
   (if (<= (pow B_m 2.0) 2e+131)
     (/ (- (sqrt (* (* t_0 (* 2.0 F)) (+ A (+ C (hypot B_m (- A C))))))) t_0)
     (* (/ (sqrt 2.0) B_m) (* (sqrt (+ A (hypot B_m A))) (- (sqrt F)))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
	double tmp;
	if (pow(B_m, 2.0) <= 2e+131) {
		tmp = -sqrt(((t_0 * (2.0 * F)) * (A + (C + hypot(B_m, (A - C)))))) / t_0;
	} else {
		tmp = (sqrt(2.0) / B_m) * (sqrt((A + hypot(B_m, A))) * -sqrt(F));
	}
	return tmp;
}
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0)))
	tmp = 0.0
	if ((B_m ^ 2.0) <= 2e+131)
		tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * Float64(A + Float64(C + hypot(B_m, Float64(A - C))))))) / t_0);
	else
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(sqrt(Float64(A + hypot(B_m, A))) * Float64(-sqrt(F))));
	end
	return tmp
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e+131], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + N[(C + N[Sqrt[B$95$m ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[F], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{+131}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B_m, A - C\right)\right)\right)}}{t_0}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 B 2) < 1.9999999999999998e131

    1. Initial program 25.7%

      \[\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. Simplified33.6%

      \[\leadsto \color{blue}{\frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}} \]

    if 1.9999999999999998e131 < (pow.f64 B 2)

    1. Initial program 7.0%

      \[\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 C around 0 15.1%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg15.1%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in15.1%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative15.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow215.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow215.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def29.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified29.4%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/229.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}\right) \]
      2. *-commutative29.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}}^{0.5}\right) \]
      3. metadata-eval29.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}\right) \]
      4. unpow-prod-down41.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}}\right) \]
      5. metadata-eval41.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      6. pow1/241.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      7. metadata-eval41.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {F}^{\color{blue}{0.5}}\right) \]
      8. pow1/241.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{F}}\right) \]
    6. Applied egg-rr41.3%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{F}}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification36.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;{B}^{2} \leq 2 \cdot 10^{+131}:\\ \;\;\;\;\frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \]

Alternative 3: 47.0% accurate, 1.2× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\ t_1 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\ t_2 := 2 \cdot \left(F \cdot t_0\right)\\ t_3 := \sqrt{A + \mathsf{hypot}\left(B_m, A\right)}\\ \mathbf{if}\;B_m \leq 1.16 \cdot 10^{-253}:\\ \;\;\;\;\frac{-\sqrt{t_2 \cdot \left(2 \cdot C\right)}}{t_0}\\ \mathbf{elif}\;B_m \leq 1.55 \cdot 10^{-111}:\\ \;\;\;\;\frac{\sqrt{t_2} \cdot \left(-t_3\right)}{t_0}\\ \mathbf{elif}\;B_m \leq 1.55 \cdot 10^{+66}:\\ \;\;\;\;\frac{-\sqrt{\left(t_1 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B_m, A - C\right)\right)\right)}}{t_1}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(t_3 \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (- (pow B_m 2.0) (* C (* A 4.0))))
        (t_1 (fma B_m B_m (* A (* C -4.0))))
        (t_2 (* 2.0 (* F t_0)))
        (t_3 (sqrt (+ A (hypot B_m A)))))
   (if (<= B_m 1.16e-253)
     (/ (- (sqrt (* t_2 (* 2.0 C)))) t_0)
     (if (<= B_m 1.55e-111)
       (/ (* (sqrt t_2) (- t_3)) t_0)
       (if (<= B_m 1.55e+66)
         (/
          (- (sqrt (* (* t_1 (* 2.0 F)) (+ A (+ C (hypot B_m (- A C)))))))
          t_1)
         (* (/ (sqrt 2.0) B_m) (* t_3 (- (sqrt F)))))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = pow(B_m, 2.0) - (C * (A * 4.0));
	double t_1 = fma(B_m, B_m, (A * (C * -4.0)));
	double t_2 = 2.0 * (F * t_0);
	double t_3 = sqrt((A + hypot(B_m, A)));
	double tmp;
	if (B_m <= 1.16e-253) {
		tmp = -sqrt((t_2 * (2.0 * C))) / t_0;
	} else if (B_m <= 1.55e-111) {
		tmp = (sqrt(t_2) * -t_3) / t_0;
	} else if (B_m <= 1.55e+66) {
		tmp = -sqrt(((t_1 * (2.0 * F)) * (A + (C + hypot(B_m, (A - C)))))) / t_1;
	} else {
		tmp = (sqrt(2.0) / B_m) * (t_3 * -sqrt(F));
	}
	return tmp;
}
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0)))
	t_1 = fma(B_m, B_m, Float64(A * Float64(C * -4.0)))
	t_2 = Float64(2.0 * Float64(F * t_0))
	t_3 = sqrt(Float64(A + hypot(B_m, A)))
	tmp = 0.0
	if (B_m <= 1.16e-253)
		tmp = Float64(Float64(-sqrt(Float64(t_2 * Float64(2.0 * C)))) / t_0);
	elseif (B_m <= 1.55e-111)
		tmp = Float64(Float64(sqrt(t_2) * Float64(-t_3)) / t_0);
	elseif (B_m <= 1.55e+66)
		tmp = Float64(Float64(-sqrt(Float64(Float64(t_1 * Float64(2.0 * F)) * Float64(A + Float64(C + hypot(B_m, Float64(A - C))))))) / t_1);
	else
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(t_3 * Float64(-sqrt(F))));
	end
	return tmp
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(2.0 * N[(F * t$95$0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[B$95$m, 1.16e-253], N[((-N[Sqrt[N[(t$95$2 * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[B$95$m, 1.55e-111], N[(N[(N[Sqrt[t$95$2], $MachinePrecision] * (-t$95$3)), $MachinePrecision] / t$95$0), $MachinePrecision], If[LessEqual[B$95$m, 1.55e+66], N[((-N[Sqrt[N[(N[(t$95$1 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + N[(C + N[Sqrt[B$95$m ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * N[(t$95$3 * (-N[Sqrt[F], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\
t_1 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_2 := 2 \cdot \left(F \cdot t_0\right)\\
t_3 := \sqrt{A + \mathsf{hypot}\left(B_m, A\right)}\\
\mathbf{if}\;B_m \leq 1.16 \cdot 10^{-253}:\\
\;\;\;\;\frac{-\sqrt{t_2 \cdot \left(2 \cdot C\right)}}{t_0}\\

\mathbf{elif}\;B_m \leq 1.55 \cdot 10^{-111}:\\
\;\;\;\;\frac{\sqrt{t_2} \cdot \left(-t_3\right)}{t_0}\\

\mathbf{elif}\;B_m \leq 1.55 \cdot 10^{+66}:\\
\;\;\;\;\frac{-\sqrt{\left(t_1 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B_m, A - C\right)\right)\right)}}{t_1}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(t_3 \cdot \left(-\sqrt{F}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if B < 1.16e-253

    1. Initial program 17.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 20.2%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(2 \cdot C\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 1.16e-253 < B < 1.55000000000000007e-111

    1. Initial program 17.8%

      \[\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 C around 0 18.7%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    3. Step-by-step derivation
      1. +-commutative18.7%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. unpow218.7%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. unpow218.7%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      4. hypot-def21.0%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    4. Simplified21.0%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(A + \mathsf{hypot}\left(B, A\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    5. Step-by-step derivation
      1. pow1/221.0%

        \[\leadsto \frac{-\color{blue}{{\left(\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. *-commutative21.0%

        \[\leadsto \frac{-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot \left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right)\right)}}^{0.5}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. metadata-eval21.0%

        \[\leadsto \frac{-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot \left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right)\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      4. unpow-prod-down33.1%

        \[\leadsto \frac{-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right)}^{\left(0.25 \cdot 2\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      5. metadata-eval33.1%

        \[\leadsto \frac{-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right)}^{\left(0.25 \cdot 2\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      6. pow1/233.1%

        \[\leadsto \frac{-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right)}^{\left(0.25 \cdot 2\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      7. metadata-eval33.1%

        \[\leadsto \frac{-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right)}^{\color{blue}{0.5}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      8. pow1/233.1%

        \[\leadsto \frac{-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      9. *-commutative33.1%

        \[\leadsto \frac{-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{2 \cdot \color{blue}{\left(F \cdot \left({B}^{2} - \left(4 \cdot A\right) \cdot C\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      10. *-commutative33.1%

        \[\leadsto \frac{-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{2 \cdot \left(F \cdot \left({B}^{2} - \color{blue}{C \cdot \left(4 \cdot A\right)}\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      11. *-commutative33.1%

        \[\leadsto \frac{-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \color{blue}{\left(A \cdot 4\right)}\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    6. Applied egg-rr33.1%

      \[\leadsto \frac{-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 1.55000000000000007e-111 < B < 1.55000000000000009e66

    1. Initial program 43.7%

      \[\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. Simplified51.3%

      \[\leadsto \color{blue}{\frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}} \]

    if 1.55000000000000009e66 < B

    1. Initial program 6.7%

      \[\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 C around 0 27.3%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg27.3%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in27.3%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative27.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow227.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow227.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def52.9%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified52.9%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/252.9%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}\right) \]
      2. *-commutative52.9%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}}^{0.5}\right) \]
      3. metadata-eval52.9%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}\right) \]
      4. unpow-prod-down75.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}}\right) \]
      5. metadata-eval75.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      6. pow1/275.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      7. metadata-eval75.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {F}^{\color{blue}{0.5}}\right) \]
      8. pow1/275.4%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{F}}\right) \]
    6. Applied egg-rr75.4%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{F}}\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification36.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq 1.16 \cdot 10^{-253}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;B \leq 1.55 \cdot 10^{-111}:\\ \;\;\;\;\frac{\sqrt{2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)}\right)}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;B \leq 1.55 \cdot 10^{+66}:\\ \;\;\;\;\frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \]

Alternative 4: 44.2% accurate, 1.2× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\ \mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-58}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{F} \cdot \left(-\sqrt{C + \mathsf{hypot}\left(B_m, C\right)}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (- (pow B_m 2.0) (* C (* A 4.0)))))
   (if (<= (pow B_m 2.0) 2e-58)
     (/ (- (sqrt (* (* 2.0 (* F t_0)) (* 2.0 C)))) t_0)
     (* (/ (sqrt 2.0) B_m) (* (sqrt F) (- (sqrt (+ C (hypot B_m C)))))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = pow(B_m, 2.0) - (C * (A * 4.0));
	double tmp;
	if (pow(B_m, 2.0) <= 2e-58) {
		tmp = -sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	} else {
		tmp = (sqrt(2.0) / B_m) * (sqrt(F) * -sqrt((C + hypot(B_m, C))));
	}
	return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double t_0 = Math.pow(B_m, 2.0) - (C * (A * 4.0));
	double tmp;
	if (Math.pow(B_m, 2.0) <= 2e-58) {
		tmp = -Math.sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	} else {
		tmp = (Math.sqrt(2.0) / B_m) * (Math.sqrt(F) * -Math.sqrt((C + Math.hypot(B_m, C))));
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	t_0 = math.pow(B_m, 2.0) - (C * (A * 4.0))
	tmp = 0
	if math.pow(B_m, 2.0) <= 2e-58:
		tmp = -math.sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0
	else:
		tmp = (math.sqrt(2.0) / B_m) * (math.sqrt(F) * -math.sqrt((C + math.hypot(B_m, C))))
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0)))
	tmp = 0.0
	if ((B_m ^ 2.0) <= 2e-58)
		tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(F * t_0)) * Float64(2.0 * C)))) / t_0);
	else
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(sqrt(F) * Float64(-sqrt(Float64(C + hypot(B_m, C))))));
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	t_0 = (B_m ^ 2.0) - (C * (A * 4.0));
	tmp = 0.0;
	if ((B_m ^ 2.0) <= 2e-58)
		tmp = -sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	else
		tmp = (sqrt(2.0) / B_m) * (sqrt(F) * -sqrt((C + hypot(B_m, C))));
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-58], N[((-N[Sqrt[N[(N[(2.0 * N[(F * t$95$0), $MachinePrecision]), $MachinePrecision] * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * N[(N[Sqrt[F], $MachinePrecision] * (-N[Sqrt[N[(C + N[Sqrt[B$95$m ^ 2 + C ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-58}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{F} \cdot \left(-\sqrt{C + \mathsf{hypot}\left(B_m, C\right)}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 B 2) < 2.0000000000000001e-58

    1. Initial program 21.9%

      \[\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 26.3%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(2 \cdot C\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 2.0000000000000001e-58 < (pow.f64 B 2)

    1. Initial program 15.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 0 15.6%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg15.6%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}} \]
      2. *-commutative15.6%

        \[\leadsto -\color{blue}{\sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)} \cdot \frac{\sqrt{2}}{B}} \]
      3. distribute-rgt-neg-in15.6%

        \[\leadsto \color{blue}{\sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right)} \]
      4. unpow215.6%

        \[\leadsto \sqrt{F \cdot \left(C + \sqrt{\color{blue}{B \cdot B} + {C}^{2}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      5. unpow215.6%

        \[\leadsto \sqrt{F \cdot \left(C + \sqrt{B \cdot B + \color{blue}{C \cdot C}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      6. hypot-def27.3%

        \[\leadsto \sqrt{F \cdot \left(C + \color{blue}{\mathsf{hypot}\left(B, C\right)}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
    4. Simplified27.3%

      \[\leadsto \color{blue}{\sqrt{F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right)} \]
    5. Step-by-step derivation
      1. pow1/227.3%

        \[\leadsto \color{blue}{{\left(F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)\right)}^{0.5}} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      2. *-commutative27.3%

        \[\leadsto {\color{blue}{\left(\left(C + \mathsf{hypot}\left(B, C\right)\right) \cdot F\right)}}^{0.5} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      3. hypot-udef15.6%

        \[\leadsto {\left(\left(C + \color{blue}{\sqrt{B \cdot B + C \cdot C}}\right) \cdot F\right)}^{0.5} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      4. unpow215.6%

        \[\leadsto {\left(\left(C + \sqrt{\color{blue}{{B}^{2}} + C \cdot C}\right) \cdot F\right)}^{0.5} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      5. unpow215.6%

        \[\leadsto {\left(\left(C + \sqrt{{B}^{2} + \color{blue}{{C}^{2}}}\right) \cdot F\right)}^{0.5} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      6. metadata-eval15.6%

        \[\leadsto {\left(\left(C + \sqrt{{B}^{2} + {C}^{2}}\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      7. unpow-prod-down18.7%

        \[\leadsto \color{blue}{\left({\left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      8. metadata-eval18.7%

        \[\leadsto \left({\left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      9. pow1/218.7%

        \[\leadsto \left(\color{blue}{\sqrt{C + \sqrt{{B}^{2} + {C}^{2}}}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      10. unpow218.7%

        \[\leadsto \left(\sqrt{C + \sqrt{\color{blue}{B \cdot B} + {C}^{2}}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      11. unpow218.7%

        \[\leadsto \left(\sqrt{C + \sqrt{B \cdot B + \color{blue}{C \cdot C}}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      12. hypot-udef37.4%

        \[\leadsto \left(\sqrt{C + \color{blue}{\mathsf{hypot}\left(B, C\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      13. metadata-eval37.4%

        \[\leadsto \left(\sqrt{C + \mathsf{hypot}\left(B, C\right)} \cdot {F}^{\color{blue}{0.5}}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      14. pow1/237.4%

        \[\leadsto \left(\sqrt{C + \mathsf{hypot}\left(B, C\right)} \cdot \color{blue}{\sqrt{F}}\right) \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
    6. Applied egg-rr37.4%

      \[\leadsto \color{blue}{\left(\sqrt{C + \mathsf{hypot}\left(B, C\right)} \cdot \sqrt{F}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification31.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;{B}^{2} \leq 2 \cdot 10^{-58}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{F} \cdot \left(-\sqrt{C + \mathsf{hypot}\left(B, C\right)}\right)\right)\\ \end{array} \]

Alternative 5: 44.6% accurate, 1.2× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\ \mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-58}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (- (pow B_m 2.0) (* C (* A 4.0)))))
   (if (<= (pow B_m 2.0) 2e-58)
     (/ (- (sqrt (* (* 2.0 (* F t_0)) (* 2.0 C)))) t_0)
     (* (/ (sqrt 2.0) B_m) (* (sqrt (+ A (hypot B_m A))) (- (sqrt F)))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = pow(B_m, 2.0) - (C * (A * 4.0));
	double tmp;
	if (pow(B_m, 2.0) <= 2e-58) {
		tmp = -sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	} else {
		tmp = (sqrt(2.0) / B_m) * (sqrt((A + hypot(B_m, A))) * -sqrt(F));
	}
	return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double t_0 = Math.pow(B_m, 2.0) - (C * (A * 4.0));
	double tmp;
	if (Math.pow(B_m, 2.0) <= 2e-58) {
		tmp = -Math.sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	} else {
		tmp = (Math.sqrt(2.0) / B_m) * (Math.sqrt((A + Math.hypot(B_m, A))) * -Math.sqrt(F));
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	t_0 = math.pow(B_m, 2.0) - (C * (A * 4.0))
	tmp = 0
	if math.pow(B_m, 2.0) <= 2e-58:
		tmp = -math.sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0
	else:
		tmp = (math.sqrt(2.0) / B_m) * (math.sqrt((A + math.hypot(B_m, A))) * -math.sqrt(F))
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0)))
	tmp = 0.0
	if ((B_m ^ 2.0) <= 2e-58)
		tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(F * t_0)) * Float64(2.0 * C)))) / t_0);
	else
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(sqrt(Float64(A + hypot(B_m, A))) * Float64(-sqrt(F))));
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	t_0 = (B_m ^ 2.0) - (C * (A * 4.0));
	tmp = 0.0;
	if ((B_m ^ 2.0) <= 2e-58)
		tmp = -sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	else
		tmp = (sqrt(2.0) / B_m) * (sqrt((A + hypot(B_m, A))) * -sqrt(F));
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-58], N[((-N[Sqrt[N[(N[(2.0 * N[(F * t$95$0), $MachinePrecision]), $MachinePrecision] * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[F], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-58}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 B 2) < 2.0000000000000001e-58

    1. Initial program 21.9%

      \[\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 26.3%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(2 \cdot C\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 2.0000000000000001e-58 < (pow.f64 B 2)

    1. Initial program 15.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 C around 0 15.5%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg15.5%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in15.5%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative15.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow215.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow215.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def26.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified26.6%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/226.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}\right) \]
      2. *-commutative26.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}}^{0.5}\right) \]
      3. metadata-eval26.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}\right) \]
      4. unpow-prod-down37.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}}\right) \]
      5. metadata-eval37.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      6. pow1/237.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      7. metadata-eval37.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {F}^{\color{blue}{0.5}}\right) \]
      8. pow1/237.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{F}}\right) \]
    6. Applied egg-rr37.5%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{F}}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification31.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;{B}^{2} \leq 2 \cdot 10^{-58}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \]

Alternative 6: 44.4% accurate, 1.5× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := \frac{\sqrt{2}}{B_m}\\ t_1 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\ t_2 := 2 \cdot \left(F \cdot t_1\right)\\ t_3 := \frac{-\sqrt{t_2 \cdot \left(2 \cdot C\right)}}{t_1}\\ t_4 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\ t_5 := A + \mathsf{hypot}\left(B_m, A\right)\\ \mathbf{if}\;B_m \leq 6.5 \cdot 10^{-254}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;B_m \leq 2.2 \cdot 10^{-175}:\\ \;\;\;\;\frac{-\sqrt{\left(t_4 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_4}\\ \mathbf{elif}\;B_m \leq 2 \cdot 10^{-81}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;B_m \leq 2 \cdot 10^{-69}:\\ \;\;\;\;\frac{-\sqrt{t_5 \cdot t_2}}{t_1}\\ \mathbf{elif}\;B_m \leq 1.1 \cdot 10^{-47}:\\ \;\;\;\;t_0 \cdot \left(-\sqrt{-0.5 \cdot \frac{{B_m}^{2}}{\frac{C}{F}}}\right)\\ \mathbf{else}:\\ \;\;\;\;t_0 \cdot \left(\sqrt{t_5} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (/ (sqrt 2.0) B_m))
        (t_1 (- (pow B_m 2.0) (* C (* A 4.0))))
        (t_2 (* 2.0 (* F t_1)))
        (t_3 (/ (- (sqrt (* t_2 (* 2.0 C)))) t_1))
        (t_4 (fma B_m B_m (* A (* C -4.0))))
        (t_5 (+ A (hypot B_m A))))
   (if (<= B_m 6.5e-254)
     t_3
     (if (<= B_m 2.2e-175)
       (/ (- (sqrt (* (* t_4 (* 2.0 F)) (+ A A)))) t_4)
       (if (<= B_m 2e-81)
         t_3
         (if (<= B_m 2e-69)
           (/ (- (sqrt (* t_5 t_2))) t_1)
           (if (<= B_m 1.1e-47)
             (* t_0 (- (sqrt (* -0.5 (/ (pow B_m 2.0) (/ C F))))))
             (* t_0 (* (sqrt t_5) (- (sqrt F)))))))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = sqrt(2.0) / B_m;
	double t_1 = pow(B_m, 2.0) - (C * (A * 4.0));
	double t_2 = 2.0 * (F * t_1);
	double t_3 = -sqrt((t_2 * (2.0 * C))) / t_1;
	double t_4 = fma(B_m, B_m, (A * (C * -4.0)));
	double t_5 = A + hypot(B_m, A);
	double tmp;
	if (B_m <= 6.5e-254) {
		tmp = t_3;
	} else if (B_m <= 2.2e-175) {
		tmp = -sqrt(((t_4 * (2.0 * F)) * (A + A))) / t_4;
	} else if (B_m <= 2e-81) {
		tmp = t_3;
	} else if (B_m <= 2e-69) {
		tmp = -sqrt((t_5 * t_2)) / t_1;
	} else if (B_m <= 1.1e-47) {
		tmp = t_0 * -sqrt((-0.5 * (pow(B_m, 2.0) / (C / F))));
	} else {
		tmp = t_0 * (sqrt(t_5) * -sqrt(F));
	}
	return tmp;
}
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64(sqrt(2.0) / B_m)
	t_1 = Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0)))
	t_2 = Float64(2.0 * Float64(F * t_1))
	t_3 = Float64(Float64(-sqrt(Float64(t_2 * Float64(2.0 * C)))) / t_1)
	t_4 = fma(B_m, B_m, Float64(A * Float64(C * -4.0)))
	t_5 = Float64(A + hypot(B_m, A))
	tmp = 0.0
	if (B_m <= 6.5e-254)
		tmp = t_3;
	elseif (B_m <= 2.2e-175)
		tmp = Float64(Float64(-sqrt(Float64(Float64(t_4 * Float64(2.0 * F)) * Float64(A + A)))) / t_4);
	elseif (B_m <= 2e-81)
		tmp = t_3;
	elseif (B_m <= 2e-69)
		tmp = Float64(Float64(-sqrt(Float64(t_5 * t_2))) / t_1);
	elseif (B_m <= 1.1e-47)
		tmp = Float64(t_0 * Float64(-sqrt(Float64(-0.5 * Float64((B_m ^ 2.0) / Float64(C / F))))));
	else
		tmp = Float64(t_0 * Float64(sqrt(t_5) * Float64(-sqrt(F))));
	end
	return tmp
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision]}, Block[{t$95$1 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(2.0 * N[(F * t$95$1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[((-N[Sqrt[N[(t$95$2 * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision]}, Block[{t$95$4 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B$95$m, 6.5e-254], t$95$3, If[LessEqual[B$95$m, 2.2e-175], N[((-N[Sqrt[N[(N[(t$95$4 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$4), $MachinePrecision], If[LessEqual[B$95$m, 2e-81], t$95$3, If[LessEqual[B$95$m, 2e-69], N[((-N[Sqrt[N[(t$95$5 * t$95$2), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], If[LessEqual[B$95$m, 1.1e-47], N[(t$95$0 * (-N[Sqrt[N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / N[(C / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision], N[(t$95$0 * N[(N[Sqrt[t$95$5], $MachinePrecision] * (-N[Sqrt[F], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := \frac{\sqrt{2}}{B_m}\\
t_1 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\
t_2 := 2 \cdot \left(F \cdot t_1\right)\\
t_3 := \frac{-\sqrt{t_2 \cdot \left(2 \cdot C\right)}}{t_1}\\
t_4 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_5 := A + \mathsf{hypot}\left(B_m, A\right)\\
\mathbf{if}\;B_m \leq 6.5 \cdot 10^{-254}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;B_m \leq 2.2 \cdot 10^{-175}:\\
\;\;\;\;\frac{-\sqrt{\left(t_4 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_4}\\

\mathbf{elif}\;B_m \leq 2 \cdot 10^{-81}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;B_m \leq 2 \cdot 10^{-69}:\\
\;\;\;\;\frac{-\sqrt{t_5 \cdot t_2}}{t_1}\\

\mathbf{elif}\;B_m \leq 1.1 \cdot 10^{-47}:\\
\;\;\;\;t_0 \cdot \left(-\sqrt{-0.5 \cdot \frac{{B_m}^{2}}{\frac{C}{F}}}\right)\\

\mathbf{else}:\\
\;\;\;\;t_0 \cdot \left(\sqrt{t_5} \cdot \left(-\sqrt{F}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if B < 6.5e-254 or 2.2e-175 < B < 1.9999999999999999e-81

    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 20.0%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(2 \cdot C\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 6.5e-254 < B < 2.2e-175

    1. Initial program 8.7%

      \[\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. Simplified19.9%

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

      \[\leadsto \frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \color{blue}{\left(A + \left(C + -1 \cdot C\right)\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
    4. Step-by-step derivation
      1. distribute-rgt1-in40.8%

        \[\leadsto \frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(A + \color{blue}{\left(-1 + 1\right) \cdot C}\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
      2. metadata-eval40.8%

        \[\leadsto \frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(A + \color{blue}{0} \cdot C\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
      3. mul0-lft40.8%

        \[\leadsto \frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(A + \color{blue}{0}\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
    5. Simplified40.8%

      \[\leadsto \frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \color{blue}{\left(A + 0\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]

    if 1.9999999999999999e-81 < B < 1.9999999999999999e-69

    1. Initial program 100.0%

      \[\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 C around 0 100.0%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    3. Step-by-step derivation
      1. +-commutative100.0%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. unpow2100.0%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. unpow2100.0%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      4. hypot-def100.0%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    4. Simplified100.0%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(A + \mathsf{hypot}\left(B, A\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 1.9999999999999999e-69 < B < 1.10000000000000009e-47

    1. Initial program 16.3%

      \[\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 0 16.7%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg16.7%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}} \]
      2. *-commutative16.7%

        \[\leadsto -\color{blue}{\sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)} \cdot \frac{\sqrt{2}}{B}} \]
      3. distribute-rgt-neg-in16.7%

        \[\leadsto \color{blue}{\sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right)} \]
      4. unpow216.7%

        \[\leadsto \sqrt{F \cdot \left(C + \sqrt{\color{blue}{B \cdot B} + {C}^{2}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      5. unpow216.7%

        \[\leadsto \sqrt{F \cdot \left(C + \sqrt{B \cdot B + \color{blue}{C \cdot C}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      6. hypot-def18.2%

        \[\leadsto \sqrt{F \cdot \left(C + \color{blue}{\mathsf{hypot}\left(B, C\right)}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
    4. Simplified18.2%

      \[\leadsto \color{blue}{\sqrt{F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right)} \]
    5. Taylor expanded in C around -inf 30.1%

      \[\leadsto \sqrt{\color{blue}{-0.5 \cdot \frac{{B}^{2} \cdot F}{C}}} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
    6. Step-by-step derivation
      1. associate-/l*30.1%

        \[\leadsto \sqrt{-0.5 \cdot \color{blue}{\frac{{B}^{2}}{\frac{C}{F}}}} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
    7. Simplified30.1%

      \[\leadsto \sqrt{\color{blue}{-0.5 \cdot \frac{{B}^{2}}{\frac{C}{F}}}} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]

    if 1.10000000000000009e-47 < B

    1. Initial program 15.9%

      \[\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 C around 0 29.0%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg29.0%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in29.0%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative29.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow229.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow229.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def48.7%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified48.7%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/248.7%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}\right) \]
      2. *-commutative48.7%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}}^{0.5}\right) \]
      3. metadata-eval48.7%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}\right) \]
      4. unpow-prod-down69.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}}\right) \]
      5. metadata-eval69.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      6. pow1/269.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      7. metadata-eval69.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {F}^{\color{blue}{0.5}}\right) \]
      8. pow1/269.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{F}}\right) \]
    6. Applied egg-rr69.1%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{F}}\right) \]
  3. Recombined 5 regimes into one program.
  4. Final simplification35.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq 6.5 \cdot 10^{-254}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;B \leq 2.2 \cdot 10^{-175}:\\ \;\;\;\;\frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\\ \mathbf{elif}\;B \leq 2 \cdot 10^{-81}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;B \leq 2 \cdot 10^{-69}:\\ \;\;\;\;\frac{-\sqrt{\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot \left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;B \leq 1.1 \cdot 10^{-47}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{-0.5 \cdot \frac{{B}^{2}}{\frac{C}{F}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \]

Alternative 7: 44.8% accurate, 1.5× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\ t_1 := 2 \cdot \left(F \cdot t_0\right)\\ \mathbf{if}\;B_m \leq 10^{-252}:\\ \;\;\;\;\frac{-\sqrt{t_1 \cdot \left(2 \cdot C\right)}}{t_0}\\ \mathbf{elif}\;B_m \leq 1.5 \cdot 10^{-111}:\\ \;\;\;\;\frac{-{\left({\left(\left(F \cdot C\right) \cdot -16\right)}^{0.25} \cdot \sqrt{A}\right)}^{2}}{\mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)}\\ \mathbf{elif}\;B_m \leq 33000000000000:\\ \;\;\;\;\frac{-\sqrt{t_1 \cdot \left(C + \mathsf{hypot}\left(B_m, C\right)\right)}}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (- (pow B_m 2.0) (* C (* A 4.0)))) (t_1 (* 2.0 (* F t_0))))
   (if (<= B_m 1e-252)
     (/ (- (sqrt (* t_1 (* 2.0 C)))) t_0)
     (if (<= B_m 1.5e-111)
       (/
        (- (pow (* (pow (* (* F C) -16.0) 0.25) (sqrt A)) 2.0))
        (fma B_m B_m (* A (* C -4.0))))
       (if (<= B_m 33000000000000.0)
         (/ (- (sqrt (* t_1 (+ C (hypot B_m C))))) t_0)
         (*
          (/ (sqrt 2.0) B_m)
          (* (sqrt (+ A (hypot B_m A))) (- (sqrt F)))))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = pow(B_m, 2.0) - (C * (A * 4.0));
	double t_1 = 2.0 * (F * t_0);
	double tmp;
	if (B_m <= 1e-252) {
		tmp = -sqrt((t_1 * (2.0 * C))) / t_0;
	} else if (B_m <= 1.5e-111) {
		tmp = -pow((pow(((F * C) * -16.0), 0.25) * sqrt(A)), 2.0) / fma(B_m, B_m, (A * (C * -4.0)));
	} else if (B_m <= 33000000000000.0) {
		tmp = -sqrt((t_1 * (C + hypot(B_m, C)))) / t_0;
	} else {
		tmp = (sqrt(2.0) / B_m) * (sqrt((A + hypot(B_m, A))) * -sqrt(F));
	}
	return tmp;
}
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0)))
	t_1 = Float64(2.0 * Float64(F * t_0))
	tmp = 0.0
	if (B_m <= 1e-252)
		tmp = Float64(Float64(-sqrt(Float64(t_1 * Float64(2.0 * C)))) / t_0);
	elseif (B_m <= 1.5e-111)
		tmp = Float64(Float64(-(Float64((Float64(Float64(F * C) * -16.0) ^ 0.25) * sqrt(A)) ^ 2.0)) / fma(B_m, B_m, Float64(A * Float64(C * -4.0))));
	elseif (B_m <= 33000000000000.0)
		tmp = Float64(Float64(-sqrt(Float64(t_1 * Float64(C + hypot(B_m, C))))) / t_0);
	else
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(sqrt(Float64(A + hypot(B_m, A))) * Float64(-sqrt(F))));
	end
	return tmp
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(2.0 * N[(F * t$95$0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B$95$m, 1e-252], N[((-N[Sqrt[N[(t$95$1 * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[B$95$m, 1.5e-111], N[((-N[Power[N[(N[Power[N[(N[(F * C), $MachinePrecision] * -16.0), $MachinePrecision], 0.25], $MachinePrecision] * N[Sqrt[A], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]) / N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[B$95$m, 33000000000000.0], N[((-N[Sqrt[N[(t$95$1 * N[(C + N[Sqrt[B$95$m ^ 2 + C ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[F], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\
t_1 := 2 \cdot \left(F \cdot t_0\right)\\
\mathbf{if}\;B_m \leq 10^{-252}:\\
\;\;\;\;\frac{-\sqrt{t_1 \cdot \left(2 \cdot C\right)}}{t_0}\\

\mathbf{elif}\;B_m \leq 1.5 \cdot 10^{-111}:\\
\;\;\;\;\frac{-{\left({\left(\left(F \cdot C\right) \cdot -16\right)}^{0.25} \cdot \sqrt{A}\right)}^{2}}{\mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)}\\

\mathbf{elif}\;B_m \leq 33000000000000:\\
\;\;\;\;\frac{-\sqrt{t_1 \cdot \left(C + \mathsf{hypot}\left(B_m, C\right)\right)}}{t_0}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if B < 9.99999999999999943e-253

    1. Initial program 17.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 20.2%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(2 \cdot C\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 9.99999999999999943e-253 < B < 1.50000000000000004e-111

    1. Initial program 17.8%

      \[\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. Simplified23.5%

      \[\leadsto \color{blue}{\frac{-\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}} \]
    3. Step-by-step derivation
      1. add-sqr-sqrt23.3%

        \[\leadsto \frac{-\color{blue}{\sqrt{\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}} \cdot \sqrt{\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
      2. pow223.3%

        \[\leadsto \frac{-\color{blue}{{\left(\sqrt{\sqrt{\left(\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(F \cdot 2\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}\right)}^{2}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
    4. Applied egg-rr23.3%

      \[\leadsto \frac{-\color{blue}{{\left({\left(\left(A + \left(C + \mathsf{hypot}\left(A - C, B\right)\right)\right) \cdot \left(\mathsf{fma}\left(B, B, \left(A \cdot C\right) \cdot -4\right) \cdot \left(2 \cdot F\right)\right)\right)}^{0.25}\right)}^{2}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
    5. Taylor expanded in B around 0 33.0%

      \[\leadsto \frac{-{\color{blue}{\left({\left(-16 \cdot \left(C \cdot F\right)\right)}^{0.25} \cdot \sqrt{A}\right)}}^{2}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
    6. Step-by-step derivation
      1. *-commutative33.0%

        \[\leadsto \frac{-{\left({\color{blue}{\left(\left(C \cdot F\right) \cdot -16\right)}}^{0.25} \cdot \sqrt{A}\right)}^{2}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
      2. *-commutative33.0%

        \[\leadsto \frac{-{\left({\left(\color{blue}{\left(F \cdot C\right)} \cdot -16\right)}^{0.25} \cdot \sqrt{A}\right)}^{2}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \]
    7. Simplified33.0%

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

    if 1.50000000000000004e-111 < B < 3.3e13

    1. Initial program 44.6%

      \[\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 0 37.1%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    3. Step-by-step derivation
      1. unpow237.1%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(C + \sqrt{\color{blue}{B \cdot B} + {C}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. unpow237.1%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(C + \sqrt{B \cdot B + \color{blue}{C \cdot C}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. hypot-def41.7%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(C + \color{blue}{\mathsf{hypot}\left(B, C\right)}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    4. Simplified41.7%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(C + \mathsf{hypot}\left(B, C\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 3.3e13 < B

    1. Initial program 12.4%

      \[\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 C around 0 28.2%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg28.2%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in28.2%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative28.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow228.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow228.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def49.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified49.8%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/249.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)\right)}^{0.5}}\right) \]
      2. *-commutative49.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\color{blue}{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}}^{0.5}\right) \]
      3. metadata-eval49.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot F\right)}^{\color{blue}{\left(0.25 \cdot 2\right)}}\right) \]
      4. unpow-prod-down72.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\left(0.25 \cdot 2\right)} \cdot {F}^{\left(0.25 \cdot 2\right)}}\right) \]
      5. metadata-eval72.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-{\left(A + \mathsf{hypot}\left(B, A\right)\right)}^{\color{blue}{0.5}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      6. pow1/272.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)}} \cdot {F}^{\left(0.25 \cdot 2\right)}\right) \]
      7. metadata-eval72.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot {F}^{\color{blue}{0.5}}\right) \]
      8. pow1/272.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \color{blue}{\sqrt{F}}\right) \]
    6. Applied egg-rr72.2%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\color{blue}{\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \sqrt{F}}\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification36.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq 10^{-252}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;B \leq 1.5 \cdot 10^{-111}:\\ \;\;\;\;\frac{-{\left({\left(\left(F \cdot C\right) \cdot -16\right)}^{0.25} \cdot \sqrt{A}\right)}^{2}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\\ \mathbf{elif}\;B \leq 33000000000000:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(\sqrt{A + \mathsf{hypot}\left(B, A\right)} \cdot \left(-\sqrt{F}\right)\right)\\ \end{array} \]

Alternative 8: 35.1% accurate, 1.5× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\ \mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-58}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\right)}{B_m}\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (- (pow B_m 2.0) (* C (* A 4.0)))))
   (if (<= (pow B_m 2.0) 2e-58)
     (/ (- (sqrt (* (* 2.0 (* F t_0)) (* 2.0 C)))) t_0)
     (/ (* (sqrt 2.0) (- (sqrt (* F (+ A (hypot B_m A)))))) B_m))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = pow(B_m, 2.0) - (C * (A * 4.0));
	double tmp;
	if (pow(B_m, 2.0) <= 2e-58) {
		tmp = -sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	} else {
		tmp = (sqrt(2.0) * -sqrt((F * (A + hypot(B_m, A))))) / B_m;
	}
	return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double t_0 = Math.pow(B_m, 2.0) - (C * (A * 4.0));
	double tmp;
	if (Math.pow(B_m, 2.0) <= 2e-58) {
		tmp = -Math.sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	} else {
		tmp = (Math.sqrt(2.0) * -Math.sqrt((F * (A + Math.hypot(B_m, A))))) / B_m;
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	t_0 = math.pow(B_m, 2.0) - (C * (A * 4.0))
	tmp = 0
	if math.pow(B_m, 2.0) <= 2e-58:
		tmp = -math.sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0
	else:
		tmp = (math.sqrt(2.0) * -math.sqrt((F * (A + math.hypot(B_m, A))))) / B_m
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0)))
	tmp = 0.0
	if ((B_m ^ 2.0) <= 2e-58)
		tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(F * t_0)) * Float64(2.0 * C)))) / t_0);
	else
		tmp = Float64(Float64(sqrt(2.0) * Float64(-sqrt(Float64(F * Float64(A + hypot(B_m, A)))))) / B_m);
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	t_0 = (B_m ^ 2.0) - (C * (A * 4.0));
	tmp = 0.0;
	if ((B_m ^ 2.0) <= 2e-58)
		tmp = -sqrt(((2.0 * (F * t_0)) * (2.0 * C))) / t_0;
	else
		tmp = (sqrt(2.0) * -sqrt((F * (A + hypot(B_m, A))))) / B_m;
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-58], N[((-N[Sqrt[N[(N[(2.0 * N[(F * t$95$0), $MachinePrecision]), $MachinePrecision] * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[2.0], $MachinePrecision] * (-N[Sqrt[N[(F * N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision] / B$95$m), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := {B_m}^{2} - C \cdot \left(A \cdot 4\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-58}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\right)}{B_m}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 B 2) < 2.0000000000000001e-58

    1. Initial program 21.9%

      \[\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 26.3%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(2 \cdot C\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if 2.0000000000000001e-58 < (pow.f64 B 2)

    1. Initial program 15.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 C around 0 15.5%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg15.5%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in15.5%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative15.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow215.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow215.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def26.6%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified26.6%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Step-by-step derivation
      1. associate-*l/26.6%

        \[\leadsto \color{blue}{\frac{\sqrt{2} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)}{B}} \]
    6. Applied egg-rr26.6%

      \[\leadsto \color{blue}{\frac{\sqrt{2} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)}{B}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification26.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;{B}^{2} \leq 2 \cdot 10^{-58}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot \left({B}^{2} - C \cdot \left(A \cdot 4\right)\right)\right)\right) \cdot \left(2 \cdot C\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)}{B}\\ \end{array} \]

Alternative 9: 38.6% accurate, 1.9× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} t_0 := A + \mathsf{hypot}\left(B_m, A\right)\\ \mathbf{if}\;F \leq -1.15 \cdot 10^{-288}:\\ \;\;\;\;\frac{-\sqrt{t_0 \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(F \cdot C\right)\right)\right)\right)}}{{B_m}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;F \leq 7.5 \cdot 10^{+40}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(-\sqrt{F \cdot t_0}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (let* ((t_0 (+ A (hypot B_m A))))
   (if (<= F -1.15e-288)
     (/
      (- (sqrt (* t_0 (* 2.0 (* -4.0 (* A (* F C)))))))
      (- (pow B_m 2.0) (* C (* A 4.0))))
     (if (<= F 7.5e+40)
       (* (/ (sqrt 2.0) B_m) (- (sqrt (* F t_0))))
       (- (* (sqrt 2.0) (sqrt (/ F B_m))))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double t_0 = A + hypot(B_m, A);
	double tmp;
	if (F <= -1.15e-288) {
		tmp = -sqrt((t_0 * (2.0 * (-4.0 * (A * (F * C)))))) / (pow(B_m, 2.0) - (C * (A * 4.0)));
	} else if (F <= 7.5e+40) {
		tmp = (sqrt(2.0) / B_m) * -sqrt((F * t_0));
	} else {
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	}
	return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double t_0 = A + Math.hypot(B_m, A);
	double tmp;
	if (F <= -1.15e-288) {
		tmp = -Math.sqrt((t_0 * (2.0 * (-4.0 * (A * (F * C)))))) / (Math.pow(B_m, 2.0) - (C * (A * 4.0)));
	} else if (F <= 7.5e+40) {
		tmp = (Math.sqrt(2.0) / B_m) * -Math.sqrt((F * t_0));
	} else {
		tmp = -(Math.sqrt(2.0) * Math.sqrt((F / B_m)));
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	t_0 = A + math.hypot(B_m, A)
	tmp = 0
	if F <= -1.15e-288:
		tmp = -math.sqrt((t_0 * (2.0 * (-4.0 * (A * (F * C)))))) / (math.pow(B_m, 2.0) - (C * (A * 4.0)))
	elif F <= 7.5e+40:
		tmp = (math.sqrt(2.0) / B_m) * -math.sqrt((F * t_0))
	else:
		tmp = -(math.sqrt(2.0) * math.sqrt((F / B_m)))
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	t_0 = Float64(A + hypot(B_m, A))
	tmp = 0.0
	if (F <= -1.15e-288)
		tmp = Float64(Float64(-sqrt(Float64(t_0 * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(F * C))))))) / Float64((B_m ^ 2.0) - Float64(C * Float64(A * 4.0))));
	elseif (F <= 7.5e+40)
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(-sqrt(Float64(F * t_0))));
	else
		tmp = Float64(-Float64(sqrt(2.0) * sqrt(Float64(F / B_m))));
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	t_0 = A + hypot(B_m, A);
	tmp = 0.0;
	if (F <= -1.15e-288)
		tmp = -sqrt((t_0 * (2.0 * (-4.0 * (A * (F * C)))))) / ((B_m ^ 2.0) - (C * (A * 4.0)));
	elseif (F <= 7.5e+40)
		tmp = (sqrt(2.0) / B_m) * -sqrt((F * t_0));
	else
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -1.15e-288], N[((-N[Sqrt[N[(t$95$0 * N[(2.0 * N[(-4.0 * N[(A * N[(F * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(C * N[(A * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 7.5e+40], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * (-N[Sqrt[N[(F * t$95$0), $MachinePrecision]], $MachinePrecision])), $MachinePrecision], (-N[(N[Sqrt[2.0], $MachinePrecision] * N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]]]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
t_0 := A + \mathsf{hypot}\left(B_m, A\right)\\
\mathbf{if}\;F \leq -1.15 \cdot 10^{-288}:\\
\;\;\;\;\frac{-\sqrt{t_0 \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(F \cdot C\right)\right)\right)\right)}}{{B_m}^{2} - C \cdot \left(A \cdot 4\right)}\\

\mathbf{elif}\;F \leq 7.5 \cdot 10^{+40}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(-\sqrt{F \cdot t_0}\right)\\

\mathbf{else}:\\
\;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if F < -1.15e-288

    1. Initial program 33.3%

      \[\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 C around 0 23.8%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    3. Step-by-step derivation
      1. +-commutative23.8%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      2. unpow223.8%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      3. unpow223.8%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
      4. hypot-def30.6%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    4. Simplified30.6%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \color{blue}{\left(A + \mathsf{hypot}\left(B, A\right)\right)}}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    5. Taylor expanded in B around 0 26.7%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \color{blue}{\left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)}\right) \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    6. Step-by-step derivation
      1. *-commutative26.7%

        \[\leadsto \frac{-\sqrt{\left(2 \cdot \left(-4 \cdot \left(A \cdot \color{blue}{\left(F \cdot C\right)}\right)\right)\right) \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    7. Simplified26.7%

      \[\leadsto \frac{-\sqrt{\left(2 \cdot \color{blue}{\left(-4 \cdot \left(A \cdot \left(F \cdot C\right)\right)\right)}\right) \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]

    if -1.15e-288 < F < 7.4999999999999996e40

    1. Initial program 15.8%

      \[\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 C around 0 13.0%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg13.0%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in13.0%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative13.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow213.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow213.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def23.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified23.2%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]

    if 7.4999999999999996e40 < F

    1. Initial program 18.4%

      \[\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 C around 0 11.5%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg11.5%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in11.5%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative11.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow211.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow211.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def12.9%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified12.9%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Taylor expanded in A around 0 20.4%

      \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{\frac{F}{B}} \cdot \sqrt{2}\right)} \]
    6. Step-by-step derivation
      1. mul-1-neg20.4%

        \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
    7. Simplified20.4%

      \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification22.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;F \leq -1.15 \cdot 10^{-288}:\\ \;\;\;\;\frac{-\sqrt{\left(A + \mathsf{hypot}\left(B, A\right)\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(F \cdot C\right)\right)\right)\right)}}{{B}^{2} - C \cdot \left(A \cdot 4\right)}\\ \mathbf{elif}\;F \leq 7.5 \cdot 10^{+40}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B}}\\ \end{array} \]

Alternative 10: 36.3% accurate, 2.0× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} \mathbf{if}\;F \leq 7.6 \cdot 10^{+40}:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (if (<= F 7.6e+40)
   (* (/ (sqrt 2.0) B_m) (- (sqrt (* F (+ A (hypot B_m A))))))
   (- (* (sqrt 2.0) (sqrt (/ F B_m))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double tmp;
	if (F <= 7.6e+40) {
		tmp = (sqrt(2.0) / B_m) * -sqrt((F * (A + hypot(B_m, A))));
	} else {
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	}
	return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double tmp;
	if (F <= 7.6e+40) {
		tmp = (Math.sqrt(2.0) / B_m) * -Math.sqrt((F * (A + Math.hypot(B_m, A))));
	} else {
		tmp = -(Math.sqrt(2.0) * Math.sqrt((F / B_m)));
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	tmp = 0
	if F <= 7.6e+40:
		tmp = (math.sqrt(2.0) / B_m) * -math.sqrt((F * (A + math.hypot(B_m, A))))
	else:
		tmp = -(math.sqrt(2.0) * math.sqrt((F / B_m)))
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	tmp = 0.0
	if (F <= 7.6e+40)
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(-sqrt(Float64(F * Float64(A + hypot(B_m, A))))));
	else
		tmp = Float64(-Float64(sqrt(2.0) * sqrt(Float64(F / B_m))));
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	tmp = 0.0;
	if (F <= 7.6e+40)
		tmp = (sqrt(2.0) / B_m) * -sqrt((F * (A + hypot(B_m, A))));
	else
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := If[LessEqual[F, 7.6e+40], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * (-N[Sqrt[N[(F * N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision], (-N[(N[Sqrt[2.0], $MachinePrecision] * N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
\mathbf{if}\;F \leq 7.6 \cdot 10^{+40}:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\right)\\

\mathbf{else}:\\
\;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if F < 7.60000000000000009e40

    1. Initial program 18.7%

      \[\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 C around 0 10.8%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg10.8%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in10.8%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative10.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow210.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow210.8%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def19.3%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified19.3%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]

    if 7.60000000000000009e40 < F

    1. Initial program 18.4%

      \[\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 C around 0 11.5%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg11.5%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in11.5%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative11.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow211.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow211.5%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def12.9%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified12.9%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Taylor expanded in A around 0 20.4%

      \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{\frac{F}{B}} \cdot \sqrt{2}\right)} \]
    6. Step-by-step derivation
      1. mul-1-neg20.4%

        \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
    7. Simplified20.4%

      \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification19.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;F \leq 7.6 \cdot 10^{+40}:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B}}\\ \end{array} \]

Alternative 11: 35.0% accurate, 3.0× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} \mathbf{if}\;F \leq 3.1 \cdot 10^{-89}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot F\right) \cdot \left(C + \mathsf{hypot}\left(B_m, C\right)\right)}}{B_m}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (if (<= F 3.1e-89)
   (/ (- (sqrt (* (* 2.0 F) (+ C (hypot B_m C))))) B_m)
   (- (* (sqrt 2.0) (sqrt (/ F B_m))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double tmp;
	if (F <= 3.1e-89) {
		tmp = -sqrt(((2.0 * F) * (C + hypot(B_m, C)))) / B_m;
	} else {
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	}
	return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double tmp;
	if (F <= 3.1e-89) {
		tmp = -Math.sqrt(((2.0 * F) * (C + Math.hypot(B_m, C)))) / B_m;
	} else {
		tmp = -(Math.sqrt(2.0) * Math.sqrt((F / B_m)));
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	tmp = 0
	if F <= 3.1e-89:
		tmp = -math.sqrt(((2.0 * F) * (C + math.hypot(B_m, C)))) / B_m
	else:
		tmp = -(math.sqrt(2.0) * math.sqrt((F / B_m)))
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	tmp = 0.0
	if (F <= 3.1e-89)
		tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * F) * Float64(C + hypot(B_m, C))))) / B_m);
	else
		tmp = Float64(-Float64(sqrt(2.0) * sqrt(Float64(F / B_m))));
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	tmp = 0.0;
	if (F <= 3.1e-89)
		tmp = -sqrt(((2.0 * F) * (C + hypot(B_m, C)))) / B_m;
	else
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := If[LessEqual[F, 3.1e-89], N[((-N[Sqrt[N[(N[(2.0 * F), $MachinePrecision] * N[(C + N[Sqrt[B$95$m ^ 2 + C ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / B$95$m), $MachinePrecision], (-N[(N[Sqrt[2.0], $MachinePrecision] * N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
\mathbf{if}\;F \leq 3.1 \cdot 10^{-89}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot F\right) \cdot \left(C + \mathsf{hypot}\left(B_m, C\right)\right)}}{B_m}\\

\mathbf{else}:\\
\;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if F < 3.09999999999999996e-89

    1. Initial program 19.6%

      \[\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 0 6.3%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg6.3%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)}} \]
      2. *-commutative6.3%

        \[\leadsto -\color{blue}{\sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)} \cdot \frac{\sqrt{2}}{B}} \]
      3. distribute-rgt-neg-in6.3%

        \[\leadsto \color{blue}{\sqrt{F \cdot \left(C + \sqrt{{B}^{2} + {C}^{2}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right)} \]
      4. unpow26.3%

        \[\leadsto \sqrt{F \cdot \left(C + \sqrt{\color{blue}{B \cdot B} + {C}^{2}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      5. unpow26.3%

        \[\leadsto \sqrt{F \cdot \left(C + \sqrt{B \cdot B + \color{blue}{C \cdot C}}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
      6. hypot-def15.5%

        \[\leadsto \sqrt{F \cdot \left(C + \color{blue}{\mathsf{hypot}\left(B, C\right)}\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right) \]
    4. Simplified15.5%

      \[\leadsto \color{blue}{\sqrt{F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{B}\right)} \]
    5. Applied egg-rr4.2%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\frac{{\left(2 \cdot \left(F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)\right)\right)}^{0.5}}{B}\right)} - 1} \]
    6. Step-by-step derivation
      1. expm1-def15.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\frac{{\left(2 \cdot \left(F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)\right)\right)}^{0.5}}{B}\right)\right)} \]
      2. expm1-log1p15.6%

        \[\leadsto \color{blue}{-\frac{{\left(2 \cdot \left(F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)\right)\right)}^{0.5}}{B}} \]
      3. distribute-neg-frac15.6%

        \[\leadsto \color{blue}{\frac{-{\left(2 \cdot \left(F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)\right)\right)}^{0.5}}{B}} \]
      4. unpow1/215.5%

        \[\leadsto \frac{-\color{blue}{\sqrt{2 \cdot \left(F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)\right)}}}{B} \]
      5. associate-*r*15.5%

        \[\leadsto \frac{-\sqrt{\color{blue}{\left(2 \cdot F\right) \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}}{B} \]
      6. *-commutative15.5%

        \[\leadsto \frac{-\sqrt{\color{blue}{\left(F \cdot 2\right)} \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{B} \]
    7. Simplified15.5%

      \[\leadsto \color{blue}{\frac{-\sqrt{\left(F \cdot 2\right) \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{B}} \]

    if 3.09999999999999996e-89 < F

    1. Initial program 17.7%

      \[\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 C around 0 16.0%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg16.0%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in16.0%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative16.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow216.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow216.0%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def20.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified20.1%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Taylor expanded in A around 0 23.8%

      \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{\frac{F}{B}} \cdot \sqrt{2}\right)} \]
    6. Step-by-step derivation
      1. mul-1-neg23.8%

        \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
    7. Simplified23.8%

      \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification20.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;F \leq 3.1 \cdot 10^{-89}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot F\right) \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{B}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B}}\\ \end{array} \]

Alternative 12: 34.2% accurate, 3.0× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ \begin{array}{l} \mathbf{if}\;F \leq 10:\\ \;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(-\sqrt{B_m \cdot F}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\ \end{array} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
 :precision binary64
 (if (<= F 10.0)
   (* (/ (sqrt 2.0) B_m) (- (sqrt (* B_m F))))
   (- (* (sqrt 2.0) (sqrt (/ F B_m))))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	double tmp;
	if (F <= 10.0) {
		tmp = (sqrt(2.0) / B_m) * -sqrt((B_m * F));
	} else {
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	}
	return tmp;
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
    real(8), intent (in) :: a
    real(8), intent (in) :: b_m
    real(8), intent (in) :: c
    real(8), intent (in) :: f
    real(8) :: tmp
    if (f <= 10.0d0) then
        tmp = (sqrt(2.0d0) / b_m) * -sqrt((b_m * f))
    else
        tmp = -(sqrt(2.0d0) * sqrt((f / b_m)))
    end if
    code = tmp
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	double tmp;
	if (F <= 10.0) {
		tmp = (Math.sqrt(2.0) / B_m) * -Math.sqrt((B_m * F));
	} else {
		tmp = -(Math.sqrt(2.0) * Math.sqrt((F / B_m)));
	}
	return tmp;
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	tmp = 0
	if F <= 10.0:
		tmp = (math.sqrt(2.0) / B_m) * -math.sqrt((B_m * F))
	else:
		tmp = -(math.sqrt(2.0) * math.sqrt((F / B_m)))
	return tmp
B_m = abs(B)
function code(A, B_m, C, F)
	tmp = 0.0
	if (F <= 10.0)
		tmp = Float64(Float64(sqrt(2.0) / B_m) * Float64(-sqrt(Float64(B_m * F))));
	else
		tmp = Float64(-Float64(sqrt(2.0) * sqrt(Float64(F / B_m))));
	end
	return tmp
end
B_m = abs(B);
function tmp_2 = code(A, B_m, C, F)
	tmp = 0.0;
	if (F <= 10.0)
		tmp = (sqrt(2.0) / B_m) * -sqrt((B_m * F));
	else
		tmp = -(sqrt(2.0) * sqrt((F / B_m)));
	end
	tmp_2 = tmp;
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := If[LessEqual[F, 10.0], N[(N[(N[Sqrt[2.0], $MachinePrecision] / B$95$m), $MachinePrecision] * (-N[Sqrt[N[(B$95$m * F), $MachinePrecision]], $MachinePrecision])), $MachinePrecision], (-N[(N[Sqrt[2.0], $MachinePrecision] * N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])]
\begin{array}{l}
B_m = \left|B\right|

\\
\begin{array}{l}
\mathbf{if}\;F \leq 10:\\
\;\;\;\;\frac{\sqrt{2}}{B_m} \cdot \left(-\sqrt{B_m \cdot F}\right)\\

\mathbf{else}:\\
\;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if F < 10

    1. Initial program 19.6%

      \[\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 C around 0 9.1%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg9.1%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in9.1%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative9.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow29.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow29.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def17.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified17.1%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Taylor expanded in A around 0 17.0%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \color{blue}{B}}\right) \]

    if 10 < F

    1. Initial program 17.0%

      \[\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 C around 0 14.1%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg14.1%

        \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
      2. distribute-rgt-neg-in14.1%

        \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
      3. +-commutative14.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
      4. unpow214.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
      5. unpow214.1%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
      6. hypot-def17.2%

        \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
    4. Simplified17.2%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
    5. Taylor expanded in A around 0 22.7%

      \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{\frac{F}{B}} \cdot \sqrt{2}\right)} \]
    6. Step-by-step derivation
      1. mul-1-neg22.7%

        \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
    7. Simplified22.7%

      \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification19.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;F \leq 10:\\ \;\;\;\;\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{B \cdot F}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{\frac{F}{B}}\\ \end{array} \]

Alternative 13: 27.2% accurate, 3.1× speedup?

\[\begin{array}{l} B_m = \left|B\right| \\ -\sqrt{2} \cdot \sqrt{\frac{F}{B_m}} \end{array} \]
B_m = (fabs.f64 B)
(FPCore (A B_m C F) :precision binary64 (- (* (sqrt 2.0) (sqrt (/ F B_m)))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
	return -(sqrt(2.0) * sqrt((F / B_m)));
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
    real(8), intent (in) :: a
    real(8), intent (in) :: b_m
    real(8), intent (in) :: c
    real(8), intent (in) :: f
    code = -(sqrt(2.0d0) * sqrt((f / b_m)))
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
	return -(Math.sqrt(2.0) * Math.sqrt((F / B_m)));
}
B_m = math.fabs(B)
def code(A, B_m, C, F):
	return -(math.sqrt(2.0) * math.sqrt((F / B_m)))
B_m = abs(B)
function code(A, B_m, C, F)
	return Float64(-Float64(sqrt(2.0) * sqrt(Float64(F / B_m))))
end
B_m = abs(B);
function tmp = code(A, B_m, C, F)
	tmp = -(sqrt(2.0) * sqrt((F / B_m)));
end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := (-N[(N[Sqrt[2.0], $MachinePrecision] * N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision])
\begin{array}{l}
B_m = \left|B\right|

\\
-\sqrt{2} \cdot \sqrt{\frac{F}{B_m}}
\end{array}
Derivation
  1. Initial program 18.6%

    \[\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 C around 0 11.1%

    \[\leadsto \color{blue}{-1 \cdot \left(\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
  3. Step-by-step derivation
    1. mul-1-neg11.1%

      \[\leadsto \color{blue}{-\frac{\sqrt{2}}{B} \cdot \sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}} \]
    2. distribute-rgt-neg-in11.1%

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}\right)} \]
    3. +-commutative11.1%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{{B}^{2} + {A}^{2}}}\right)}\right) \]
    4. unpow211.1%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{\color{blue}{B \cdot B} + {A}^{2}}\right)}\right) \]
    5. unpow211.1%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \sqrt{B \cdot B + \color{blue}{A \cdot A}}\right)}\right) \]
    6. hypot-def17.1%

      \[\leadsto \frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \color{blue}{\mathsf{hypot}\left(B, A\right)}\right)}\right) \]
  4. Simplified17.1%

    \[\leadsto \color{blue}{\frac{\sqrt{2}}{B} \cdot \left(-\sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}\right)} \]
  5. Taylor expanded in A around 0 15.8%

    \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{\frac{F}{B}} \cdot \sqrt{2}\right)} \]
  6. Step-by-step derivation
    1. mul-1-neg15.8%

      \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
  7. Simplified15.8%

    \[\leadsto \color{blue}{-\sqrt{\frac{F}{B}} \cdot \sqrt{2}} \]
  8. Final simplification15.8%

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

Reproduce

?
herbie shell --seed 2023332 
(FPCore (A B C F)
  :name "ABCF->ab-angle a"
  :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))))