Average Error: 52.0 → 41.5
Time: 39.9s
Precision: binary64
Cost: 74500
\[ \begin{array}{c}[A, C] = \mathsf{sort}([A, C])\\ \end{array} \]
\[\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} \]
\[\begin{array}{l} t_0 := \mathsf{hypot}\left(B, A - C\right)\\ t_1 := \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)\\ t_2 := {B}^{2} + C \cdot \left(A \cdot -4\right)\\ \mathbf{if}\;\frac{-\sqrt{\left(2 \cdot \left(t_2 \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{B}^{2} + {\left(A - C\right)}^{2}}\right)}}{t_2} \leq 0:\\ \;\;\;\;\frac{\sqrt{F \cdot \left(A + \left(C - t_0\right)\right)} \cdot \left(-\sqrt{2 \cdot t_1}\right)}{t_1}\\ \mathbf{else}:\\ \;\;\;\;{\left(\frac{\left(A + C\right) - t_0}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \left(2 \cdot F\right)\right)}^{0.5}\\ \end{array} \]
(FPCore (A B C F)
 :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))))
(FPCore (A B C F)
 :precision binary64
 (let* ((t_0 (hypot B (- A C)))
        (t_1 (fma B B (* A (* C -4.0))))
        (t_2 (+ (pow B 2.0) (* C (* A -4.0)))))
   (if (<=
        (/
         (-
          (sqrt
           (*
            (* 2.0 (* t_2 F))
            (- (+ A C) (sqrt (+ (pow B 2.0) (pow (- A C) 2.0)))))))
         t_2)
        0.0)
     (/ (* (sqrt (* F (+ A (- C t_0)))) (- (sqrt (* 2.0 t_1)))) t_1)
     (pow (* (/ (- (+ A C) t_0) (fma A (* C -4.0) (* B B))) (* 2.0 F)) 0.5))))
double code(double A, double B, double C, double F) {
	return -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));
}
double code(double A, double B, double C, double F) {
	double t_0 = hypot(B, (A - C));
	double t_1 = fma(B, B, (A * (C * -4.0)));
	double t_2 = pow(B, 2.0) + (C * (A * -4.0));
	double tmp;
	if ((-sqrt(((2.0 * (t_2 * F)) * ((A + C) - sqrt((pow(B, 2.0) + pow((A - C), 2.0)))))) / t_2) <= 0.0) {
		tmp = (sqrt((F * (A + (C - t_0)))) * -sqrt((2.0 * t_1))) / t_1;
	} else {
		tmp = pow(((((A + C) - t_0) / fma(A, (C * -4.0), (B * B))) * (2.0 * F)), 0.5);
	}
	return tmp;
}
function code(A, B, C, F)
	return Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(Float64((B ^ 2.0) - Float64(Float64(4.0 * A) * C)) * F)) * Float64(Float64(A + C) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0))))))) / Float64((B ^ 2.0) - Float64(Float64(4.0 * A) * C)))
end
function code(A, B, C, F)
	t_0 = hypot(B, Float64(A - C))
	t_1 = fma(B, B, Float64(A * Float64(C * -4.0)))
	t_2 = Float64((B ^ 2.0) + Float64(C * Float64(A * -4.0)))
	tmp = 0.0
	if (Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_2 * F)) * Float64(Float64(A + C) - sqrt(Float64((B ^ 2.0) + (Float64(A - C) ^ 2.0))))))) / t_2) <= 0.0)
		tmp = Float64(Float64(sqrt(Float64(F * Float64(A + Float64(C - t_0)))) * Float64(-sqrt(Float64(2.0 * t_1)))) / t_1);
	else
		tmp = Float64(Float64(Float64(Float64(A + C) - t_0) / fma(A, Float64(C * -4.0), Float64(B * B))) * Float64(2.0 * F)) ^ 0.5;
	end
	return tmp
end
code[A_, B_, C_, F_] := N[((-N[Sqrt[N[(N[(2.0 * N[(N[(N[Power[B, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision] * 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]) / N[(N[Power[B, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
code[A_, B_, C_, F_] := Block[{t$95$0 = N[Sqrt[B ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]}, Block[{t$95$1 = N[(B * B + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[Power[B, 2.0], $MachinePrecision] + N[(C * N[(A * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$2 * F), $MachinePrecision]), $MachinePrecision] * N[(N[(A + C), $MachinePrecision] - N[Sqrt[N[(N[Power[B, 2.0], $MachinePrecision] + N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$2), $MachinePrecision], 0.0], N[(N[(N[Sqrt[N[(F * N[(A + N[(C - t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[N[(2.0 * t$95$1), $MachinePrecision]], $MachinePrecision])), $MachinePrecision] / t$95$1), $MachinePrecision], N[Power[N[(N[(N[(N[(A + C), $MachinePrecision] - t$95$0), $MachinePrecision] / N[(A * N[(C * -4.0), $MachinePrecision] + N[(B * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(2.0 * F), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]]]]
\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}
\begin{array}{l}
t_0 := \mathsf{hypot}\left(B, A - C\right)\\
t_1 := \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)\\
t_2 := {B}^{2} + C \cdot \left(A \cdot -4\right)\\
\mathbf{if}\;\frac{-\sqrt{\left(2 \cdot \left(t_2 \cdot F\right)\right) \cdot \left(\left(A + C\right) - \sqrt{{B}^{2} + {\left(A - C\right)}^{2}}\right)}}{t_2} \leq 0:\\
\;\;\;\;\frac{\sqrt{F \cdot \left(A + \left(C - t_0\right)\right)} \cdot \left(-\sqrt{2 \cdot t_1}\right)}{t_1}\\

\mathbf{else}:\\
\;\;\;\;{\left(\frac{\left(A + C\right) - t_0}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \left(2 \cdot F\right)\right)}^{0.5}\\


\end{array}

Error

Derivation

  1. Split input into 2 regimes
  2. if (/.f64 (neg.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) < 0.0

    1. Initial program 44.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. Simplified38.3

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right) \cdot \left(2 \cdot \left(F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}} \]
      Proof
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 (Rewrite<= metadata-eval (neg.f64 4)) C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 A (neg.f64 4)) C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 (Rewrite<= distribute-rgt-neg-in_binary64 (neg.f64 (*.f64 A 4))) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 (neg.f64 (Rewrite<= *-commutative_binary64 (*.f64 4 A))) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (Rewrite=> distribute-lft-neg-out_binary64 (neg.f64 (*.f64 (*.f64 4 A) C)))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (Rewrite<= fma-neg_binary64 (-.f64 (*.f64 B B) (*.f64 (*.f64 4 A) C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (Rewrite<= unpow2_binary64 (pow.f64 B 2)) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (Rewrite<= hypot-def_binary64 (sqrt.f64 (+.f64 (*.f64 B B) (*.f64 (-.f64 A C) (-.f64 A C)))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 38 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (sqrt.f64 (+.f64 (Rewrite<= unpow2_binary64 (pow.f64 B 2)) (*.f64 (-.f64 A C) (-.f64 A C))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (sqrt.f64 (+.f64 (pow.f64 B 2) (Rewrite<= unpow2_binary64 (pow.f64 (-.f64 A C) 2))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (sqrt.f64 (Rewrite<= +-commutative_binary64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (Rewrite=> sub-neg_binary64 (+.f64 C (neg.f64 (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (Rewrite<= associate-+l+_binary64 (+.f64 (+.f64 A C) (neg.f64 (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 14 points increase in error, 1 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (Rewrite<= sub-neg_binary64 (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) 2) (*.f64 F (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (Rewrite<= *-commutative_binary64 (*.f64 2 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))) (*.f64 F (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 (*.f64 2 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) F) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 3 points increase in error, 3 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (Rewrite<= associate-*r*_binary64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F))) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (Rewrite<= --rgt-identity_binary64 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (Rewrite<= sub0-neg_binary64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (*.f64 A (*.f64 (Rewrite<= metadata-eval (neg.f64 4)) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 A (neg.f64 4)) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (*.f64 (Rewrite<= distribute-rgt-neg-in_binary64 (neg.f64 (*.f64 A 4))) C))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (*.f64 (neg.f64 (Rewrite<= *-commutative_binary64 (*.f64 4 A))) C))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (Rewrite=> distribute-lft-neg-out_binary64 (neg.f64 (*.f64 (*.f64 4 A) C))))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (Rewrite<= fma-neg_binary64 (-.f64 (*.f64 B B) (*.f64 (*.f64 4 A) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (-.f64 (Rewrite<= unpow2_binary64 (pow.f64 B 2)) (*.f64 (*.f64 4 A) C))): 0 points increase in error, 0 points decrease in error
      (Rewrite=> div-sub_binary64 (-.f64 (/.f64 0 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) (/.f64 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))))): 0 points increase in error, 0 points decrease in error
      (-.f64 (/.f64 0 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) (/.f64 (Rewrite=> --rgt-identity_binary64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))): 0 points increase in error, 0 points decrease in error
      (Rewrite<= div-sub_binary64 (/.f64 (-.f64 0 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (Rewrite<= neg-sub0_binary64 (neg.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))): 0 points increase in error, 0 points decrease in error
    3. Applied egg-rr31.6

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

      \[\leadsto \frac{-\color{blue}{\sqrt{\left(\left(C - \mathsf{hypot}\left(B, A - C\right)\right) + A\right) \cdot F} \cdot \sqrt{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right) \cdot 2}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \]
      Proof
      (*.f64 (sqrt.f64 (*.f64 (+.f64 (-.f64 C (hypot.f64 B (-.f64 A C))) A) F)) (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2))): 0 points increase in error, 0 points decrease in error
      (*.f64 (sqrt.f64 (*.f64 (Rewrite<= associate--r-_binary64 (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A))) F)) (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2))): 0 points increase in error, 27 points decrease in error
      (*.f64 (sqrt.f64 (Rewrite<= *-commutative_binary64 (*.f64 F (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A))))) (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2))): 0 points increase in error, 0 points decrease in error
      (*.f64 (sqrt.f64 (*.f64 F (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A)))) (Rewrite<= unpow1/2_binary64 (pow.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2) 1/2))): 0 points increase in error, 0 points decrease in error
      (Rewrite<= *-commutative_binary64 (*.f64 (pow.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2) 1/2) (sqrt.f64 (*.f64 F (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A)))))): 0 points increase in error, 0 points decrease in error
      (*.f64 (Rewrite=> unpow1/2_binary64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2))) (sqrt.f64 (*.f64 F (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A))))): 0 points increase in error, 0 points decrease in error

    if 0.0 < (/.f64 (neg.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))

    1. Initial program 59.5

      \[\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. Simplified56.7

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right) \cdot \left(2 \cdot \left(F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}} \]
      Proof
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 (Rewrite<= metadata-eval (neg.f64 4)) C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 A (neg.f64 4)) C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 (Rewrite<= distribute-rgt-neg-in_binary64 (neg.f64 (*.f64 A 4))) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (*.f64 (neg.f64 (Rewrite<= *-commutative_binary64 (*.f64 4 A))) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (fma.f64 B B (Rewrite=> distribute-lft-neg-out_binary64 (neg.f64 (*.f64 (*.f64 4 A) C)))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (Rewrite<= fma-neg_binary64 (-.f64 (*.f64 B B) (*.f64 (*.f64 4 A) C))) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (Rewrite<= unpow2_binary64 (pow.f64 B 2)) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (Rewrite<= hypot-def_binary64 (sqrt.f64 (+.f64 (*.f64 B B) (*.f64 (-.f64 A C) (-.f64 A C)))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 38 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (sqrt.f64 (+.f64 (Rewrite<= unpow2_binary64 (pow.f64 B 2)) (*.f64 (-.f64 A C) (-.f64 A C))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (sqrt.f64 (+.f64 (pow.f64 B 2) (Rewrite<= unpow2_binary64 (pow.f64 (-.f64 A C) 2))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (-.f64 C (sqrt.f64 (Rewrite<= +-commutative_binary64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (+.f64 A (Rewrite=> sub-neg_binary64 (+.f64 C (neg.f64 (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (Rewrite<= associate-+l+_binary64 (+.f64 (+.f64 A C) (neg.f64 (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 14 points increase in error, 1 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) (*.f64 2 (*.f64 F (Rewrite<= sub-neg_binary64 (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) 2) (*.f64 F (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (Rewrite<= *-commutative_binary64 (*.f64 2 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))) (*.f64 F (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 (*.f64 2 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) F) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 3 points increase in error, 3 points decrease in error
      (/.f64 (neg.f64 (sqrt.f64 (*.f64 (Rewrite<= associate-*r*_binary64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F))) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (neg.f64 (Rewrite<= --rgt-identity_binary64 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (Rewrite<= sub0-neg_binary64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (*.f64 A (*.f64 (Rewrite<= metadata-eval (neg.f64 4)) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 A (neg.f64 4)) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (*.f64 (Rewrite<= distribute-rgt-neg-in_binary64 (neg.f64 (*.f64 A 4))) C))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (*.f64 (neg.f64 (Rewrite<= *-commutative_binary64 (*.f64 4 A))) C))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (fma.f64 B B (Rewrite=> distribute-lft-neg-out_binary64 (neg.f64 (*.f64 (*.f64 4 A) C))))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (Rewrite<= fma-neg_binary64 (-.f64 (*.f64 B B) (*.f64 (*.f64 4 A) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (-.f64 0 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0)) (-.f64 (Rewrite<= unpow2_binary64 (pow.f64 B 2)) (*.f64 (*.f64 4 A) C))): 0 points increase in error, 0 points decrease in error
      (Rewrite=> div-sub_binary64 (-.f64 (/.f64 0 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) (/.f64 (-.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))) 0) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))))): 0 points increase in error, 0 points decrease in error
      (-.f64 (/.f64 0 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))) (/.f64 (Rewrite=> --rgt-identity_binary64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))): 0 points increase in error, 0 points decrease in error
      (Rewrite<= div-sub_binary64 (/.f64 (-.f64 0 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)))): 0 points increase in error, 0 points decrease in error
      (/.f64 (Rewrite<= neg-sub0_binary64 (neg.f64 (sqrt.f64 (*.f64 (*.f64 2 (*.f64 (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C)) F)) (-.f64 (+.f64 A C) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2)))))))) (-.f64 (pow.f64 B 2) (*.f64 (*.f64 4 A) C))): 0 points increase in error, 0 points decrease in error
    3. Applied egg-rr59.5

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

      \[\leadsto \color{blue}{\sqrt{1 \cdot \frac{\left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right) \cdot \left(2 \cdot F\right)}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}} \]
      Proof
      (sqrt.f64 (*.f64 1 (/.f64 (*.f64 (-.f64 (+.f64 A C) (hypot.f64 B (-.f64 A C))) (*.f64 2 F)) (fma.f64 B B (*.f64 A (*.f64 -4 C)))))): 0 points increase in error, 0 points decrease in error
      (sqrt.f64 (*.f64 (Rewrite<= *-inverses_binary64 (/.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (fma.f64 B B (*.f64 A (*.f64 -4 C))))) (/.f64 (*.f64 (-.f64 (+.f64 A C) (hypot.f64 B (-.f64 A C))) (*.f64 2 F)) (fma.f64 B B (*.f64 A (*.f64 -4 C)))))): 77 points increase in error, 0 points decrease in error
      (sqrt.f64 (*.f64 (/.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))) (/.f64 (*.f64 (Rewrite<= associate-+r-_binary64 (+.f64 A (-.f64 C (hypot.f64 B (-.f64 A C))))) (*.f64 2 F)) (fma.f64 B B (*.f64 A (*.f64 -4 C)))))): 22 points increase in error, 10 points decrease in error
      (sqrt.f64 (*.f64 (/.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))) (/.f64 (*.f64 (Rewrite<= +-commutative_binary64 (+.f64 (-.f64 C (hypot.f64 B (-.f64 A C))) A)) (*.f64 2 F)) (fma.f64 B B (*.f64 A (*.f64 -4 C)))))): 0 points increase in error, 0 points decrease in error
      (sqrt.f64 (*.f64 (/.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (fma.f64 B B (*.f64 A (*.f64 -4 C)))) (/.f64 (*.f64 (Rewrite<= associate--r-_binary64 (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A))) (*.f64 2 F)) (fma.f64 B B (*.f64 A (*.f64 -4 C)))))): 10 points increase in error, 22 points decrease in error
      (sqrt.f64 (Rewrite<= times-frac_binary64 (/.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (*.f64 (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A)) (*.f64 2 F))) (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (fma.f64 B B (*.f64 A (*.f64 -4 C))))))): 41 points increase in error, 12 points decrease in error
      (sqrt.f64 (/.f64 (*.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) (*.f64 (-.f64 C (-.f64 (hypot.f64 B (-.f64 A C)) A)) (*.f64 2 F))) (Rewrite<= unpow2_binary64 (pow.f64 (fma.f64 B B (*.f64 A (*.f64 -4 C))) 2)))): 0 points increase in error, 0 points decrease in error
    5. Applied egg-rr52.7

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

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

Alternatives

Alternative 1
Error45.5
Cost34188
\[\begin{array}{l} t_0 := B \cdot B + -4 \cdot \left(A \cdot C\right)\\ t_1 := \left(A + C\right) - \mathsf{hypot}\left(A - C, B\right)\\ t_2 := \mathsf{hypot}\left(B, A - C\right)\\ t_3 := A \cdot \left(C \cdot -4\right)\\ t_4 := \mathsf{fma}\left(B, B, t_3\right)\\ \mathbf{if}\;C \leq -1.6 \cdot 10^{-226}:\\ \;\;\;\;\sqrt{\frac{F}{\frac{t_4}{2 \cdot \left(C + \left(A - t_2\right)\right)}}}\\ \mathbf{elif}\;C \leq -1.3 \cdot 10^{-281}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot t_1}}{t_0}\\ \mathbf{elif}\;C \leq -6.5 \cdot 10^{-291}:\\ \;\;\;\;\frac{\sqrt{t_4 \cdot t_1} \cdot \left(-\sqrt{2 \cdot F}\right)}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{\mathsf{hypot}\left(B, \sqrt{t_3}\right) \cdot \left(-\sqrt{\left(2 \cdot F\right) \cdot \left(A + \left(C - t_2\right)\right)}\right)}{t_4}\\ \end{array} \]
Alternative 2
Error48.3
Cost27916
\[\begin{array}{l} t_0 := -4 \cdot \left(A \cdot C\right)\\ t_1 := B \cdot B + t_0\\ t_2 := \mathsf{hypot}\left(B, A - C\right)\\ t_3 := \mathsf{hypot}\left(A - C, B\right)\\ t_4 := \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)\\ \mathbf{if}\;C \leq -1.6 \cdot 10^{-226}:\\ \;\;\;\;\sqrt{\frac{F}{\frac{t_4}{2 \cdot \left(C + \left(A - t_2\right)\right)}}}\\ \mathbf{elif}\;C \leq 6 \cdot 10^{-77}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_1\right)\right) \cdot \left(\left(A + C\right) - t_3\right)}}{t_1}\\ \mathbf{elif}\;C \leq 2.8 \cdot 10^{+136}:\\ \;\;\;\;\frac{\sqrt{F \cdot \left(A + \left(C - t_3\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(A, 4 \cdot C, B \cdot B\right)}}{t_0 - B \cdot B}\\ \mathbf{else}:\\ \;\;\;\;\sqrt[3]{{\left(\left(A + \left(C - t_2\right)\right) \cdot \frac{2 \cdot F}{t_4}\right)}^{1.5}}\\ \end{array} \]
Alternative 3
Error47.1
Cost21252
\[\begin{array}{l} t_0 := \mathsf{hypot}\left(B, A - C\right)\\ \mathbf{if}\;C \leq -4.7 \cdot 10^{-228}:\\ \;\;\;\;\sqrt{\frac{F}{\frac{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}{2 \cdot \left(C + \left(A - t_0\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{\left(F \cdot \mathsf{fma}\left(C, A \cdot -4, B \cdot B\right)\right) \cdot \left(2 \cdot \left(A + \left(C - t_0\right)\right)\right)}}{\left(4 \cdot A\right) \cdot C - B \cdot B}\\ \end{array} \]
Alternative 4
Error48.0
Cost20676
\[\begin{array}{l} t_0 := B \cdot B + -4 \cdot \left(A \cdot C\right)\\ \mathbf{if}\;C \leq -1 \cdot 10^{-184}:\\ \;\;\;\;{\left(\frac{\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \left(2 \cdot F\right)\right)}^{0.5}\\ \mathbf{else}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(A - C, B\right)\right)}}{t_0}\\ \end{array} \]
Alternative 5
Error48.3
Cost20612
\[\begin{array}{l} t_0 := B \cdot B + -4 \cdot \left(A \cdot C\right)\\ \mathbf{if}\;C \leq -1.6 \cdot 10^{-226}:\\ \;\;\;\;\sqrt{\frac{F}{\frac{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}{2 \cdot \left(C + \left(A - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_0\right)\right) \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(A - C, B\right)\right)}}{t_0}\\ \end{array} \]
Alternative 6
Error47.4
Cost15044
\[\begin{array}{l} t_0 := 4 \cdot \left(A \cdot C\right) - B \cdot B\\ t_1 := \left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\\ t_2 := B \cdot B + -4 \cdot \left(A \cdot C\right)\\ \mathbf{if}\;F \leq -1.55 \cdot 10^{-305}:\\ \;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(F \cdot t_2\right)\right) \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(A - C, B\right)\right)}}{t_2}\\ \mathbf{elif}\;F \leq 6.5 \cdot 10^{+58}:\\ \;\;\;\;\sqrt{\frac{1}{\frac{t_0}{t_1 \cdot \left(F \cdot -2\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{t_1}{\frac{t_0}{F \cdot -2}}}\\ \end{array} \]
Alternative 7
Error58.2
Cost14336
\[\sqrt{\frac{1}{\frac{4 \cdot \left(A \cdot C\right) - B \cdot B}{\left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right) \cdot \left(F \cdot -2\right)}}} \]
Alternative 8
Error57.3
Cost14208
\[\sqrt{\left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right) \cdot \left(F \cdot \frac{-2}{A \cdot \left(4 \cdot C\right) - B \cdot B}\right)} \]
Alternative 9
Error58.2
Cost14208
\[\sqrt{\frac{\left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right) \cdot \left(F \cdot -2\right)}{A \cdot \left(4 \cdot C\right) - B \cdot B}} \]

Error

Reproduce

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