| Alternative 1 | |
|---|---|
| Error | 71.89% |
| Cost | 34660 |
(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 (* A (* C -4.0)))
(t_1 (fma B B t_0))
(t_2 (hypot B (sqrt t_0)))
(t_3 (fma B B (* C (* A -4.0))))
(t_4 (hypot B (- A C)))
(t_5 (sqrt (* F (- (+ A C) t_4))))
(t_6 (- (sqrt 2.0)))
(t_7 (/ t_6 t_2)))
(if (<= A -6.8e+176)
(* t_5 (- (sqrt (/ 2.0 (fma B B (* (* A C) -4.0))))))
(if (<= A -5.5e-44)
(* (sqrt (* -2.0 (* (* F t_1) (- (- t_4 C) A)))) (/ 1.0 (- t_1)))
(if (<= A -4e-85)
(* t_5 (/ (sqrt 2.0) B))
(if (<= A -1.6e-140)
(* (sqrt (* F (* A 2.0))) t_7)
(if (<= A -5.8e-167)
(* t_5 (/ t_6 B))
(if (<= A -4.6e-303)
(/ (- (sqrt (* t_1 (* (+ A (- C t_4)) (* F 2.0))))) t_1)
(if (<= A 7.8e-177)
(* t_5 (* (sqrt 2.0) (/ -1.0 t_2)))
(if (<= A 5.3e-102)
(/
(sqrt
(* 2.0 (* (* F t_3) (+ A (fma -0.5 (/ (* B B) C) A)))))
(- t_3))
(if (<= A 1.7e+92)
(* t_5 (/ t_6 (hypot B (* (sqrt (* C -4.0)) (sqrt A)))))
(*
t_7
(sqrt
(*
F
(fma -0.5 (/ B (/ (- A C) B)) (* C 2.0))))))))))))))))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 = A * (C * -4.0);
double t_1 = fma(B, B, t_0);
double t_2 = hypot(B, sqrt(t_0));
double t_3 = fma(B, B, (C * (A * -4.0)));
double t_4 = hypot(B, (A - C));
double t_5 = sqrt((F * ((A + C) - t_4)));
double t_6 = -sqrt(2.0);
double t_7 = t_6 / t_2;
double tmp;
if (A <= -6.8e+176) {
tmp = t_5 * -sqrt((2.0 / fma(B, B, ((A * C) * -4.0))));
} else if (A <= -5.5e-44) {
tmp = sqrt((-2.0 * ((F * t_1) * ((t_4 - C) - A)))) * (1.0 / -t_1);
} else if (A <= -4e-85) {
tmp = t_5 * (sqrt(2.0) / B);
} else if (A <= -1.6e-140) {
tmp = sqrt((F * (A * 2.0))) * t_7;
} else if (A <= -5.8e-167) {
tmp = t_5 * (t_6 / B);
} else if (A <= -4.6e-303) {
tmp = -sqrt((t_1 * ((A + (C - t_4)) * (F * 2.0)))) / t_1;
} else if (A <= 7.8e-177) {
tmp = t_5 * (sqrt(2.0) * (-1.0 / t_2));
} else if (A <= 5.3e-102) {
tmp = sqrt((2.0 * ((F * t_3) * (A + fma(-0.5, ((B * B) / C), A))))) / -t_3;
} else if (A <= 1.7e+92) {
tmp = t_5 * (t_6 / hypot(B, (sqrt((C * -4.0)) * sqrt(A))));
} else {
tmp = t_7 * sqrt((F * fma(-0.5, (B / ((A - C) / B)), (C * 2.0))));
}
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 = Float64(A * Float64(C * -4.0)) t_1 = fma(B, B, t_0) t_2 = hypot(B, sqrt(t_0)) t_3 = fma(B, B, Float64(C * Float64(A * -4.0))) t_4 = hypot(B, Float64(A - C)) t_5 = sqrt(Float64(F * Float64(Float64(A + C) - t_4))) t_6 = Float64(-sqrt(2.0)) t_7 = Float64(t_6 / t_2) tmp = 0.0 if (A <= -6.8e+176) tmp = Float64(t_5 * Float64(-sqrt(Float64(2.0 / fma(B, B, Float64(Float64(A * C) * -4.0)))))); elseif (A <= -5.5e-44) tmp = Float64(sqrt(Float64(-2.0 * Float64(Float64(F * t_1) * Float64(Float64(t_4 - C) - A)))) * Float64(1.0 / Float64(-t_1))); elseif (A <= -4e-85) tmp = Float64(t_5 * Float64(sqrt(2.0) / B)); elseif (A <= -1.6e-140) tmp = Float64(sqrt(Float64(F * Float64(A * 2.0))) * t_7); elseif (A <= -5.8e-167) tmp = Float64(t_5 * Float64(t_6 / B)); elseif (A <= -4.6e-303) tmp = Float64(Float64(-sqrt(Float64(t_1 * Float64(Float64(A + Float64(C - t_4)) * Float64(F * 2.0))))) / t_1); elseif (A <= 7.8e-177) tmp = Float64(t_5 * Float64(sqrt(2.0) * Float64(-1.0 / t_2))); elseif (A <= 5.3e-102) tmp = Float64(sqrt(Float64(2.0 * Float64(Float64(F * t_3) * Float64(A + fma(-0.5, Float64(Float64(B * B) / C), A))))) / Float64(-t_3)); elseif (A <= 1.7e+92) tmp = Float64(t_5 * Float64(t_6 / hypot(B, Float64(sqrt(Float64(C * -4.0)) * sqrt(A))))); else tmp = Float64(t_7 * sqrt(Float64(F * fma(-0.5, Float64(B / Float64(Float64(A - C) / B)), Float64(C * 2.0))))); 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[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(B * B + t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[Sqrt[B ^ 2 + N[Sqrt[t$95$0], $MachinePrecision] ^ 2], $MachinePrecision]}, Block[{t$95$3 = N[(B * B + N[(C * N[(A * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[Sqrt[B ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]}, Block[{t$95$5 = N[Sqrt[N[(F * N[(N[(A + C), $MachinePrecision] - t$95$4), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$6 = (-N[Sqrt[2.0], $MachinePrecision])}, Block[{t$95$7 = N[(t$95$6 / t$95$2), $MachinePrecision]}, If[LessEqual[A, -6.8e+176], N[(t$95$5 * (-N[Sqrt[N[(2.0 / N[(B * B + N[(N[(A * C), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision], If[LessEqual[A, -5.5e-44], N[(N[Sqrt[N[(-2.0 * N[(N[(F * t$95$1), $MachinePrecision] * N[(N[(t$95$4 - C), $MachinePrecision] - A), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(1.0 / (-t$95$1)), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -4e-85], N[(t$95$5 * N[(N[Sqrt[2.0], $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -1.6e-140], N[(N[Sqrt[N[(F * N[(A * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * t$95$7), $MachinePrecision], If[LessEqual[A, -5.8e-167], N[(t$95$5 * N[(t$95$6 / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -4.6e-303], N[((-N[Sqrt[N[(t$95$1 * N[(N[(A + N[(C - t$95$4), $MachinePrecision]), $MachinePrecision] * N[(F * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], If[LessEqual[A, 7.8e-177], N[(t$95$5 * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 5.3e-102], N[(N[Sqrt[N[(2.0 * N[(N[(F * t$95$3), $MachinePrecision] * N[(A + N[(-0.5 * N[(N[(B * B), $MachinePrecision] / C), $MachinePrecision] + A), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / (-t$95$3)), $MachinePrecision], If[LessEqual[A, 1.7e+92], N[(t$95$5 * N[(t$95$6 / N[Sqrt[B ^ 2 + N[(N[Sqrt[N[(C * -4.0), $MachinePrecision]], $MachinePrecision] * N[Sqrt[A], $MachinePrecision]), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$7 * N[Sqrt[N[(F * N[(-0.5 * N[(B / N[(N[(A - C), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision] + N[(C * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $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 := A \cdot \left(C \cdot -4\right)\\
t_1 := \mathsf{fma}\left(B, B, t_0\right)\\
t_2 := \mathsf{hypot}\left(B, \sqrt{t_0}\right)\\
t_3 := \mathsf{fma}\left(B, B, C \cdot \left(A \cdot -4\right)\right)\\
t_4 := \mathsf{hypot}\left(B, A - C\right)\\
t_5 := \sqrt{F \cdot \left(\left(A + C\right) - t_4\right)}\\
t_6 := -\sqrt{2}\\
t_7 := \frac{t_6}{t_2}\\
\mathbf{if}\;A \leq -6.8 \cdot 10^{+176}:\\
\;\;\;\;t_5 \cdot \left(-\sqrt{\frac{2}{\mathsf{fma}\left(B, B, \left(A \cdot C\right) \cdot -4\right)}}\right)\\
\mathbf{elif}\;A \leq -5.5 \cdot 10^{-44}:\\
\;\;\;\;\sqrt{-2 \cdot \left(\left(F \cdot t_1\right) \cdot \left(\left(t_4 - C\right) - A\right)\right)} \cdot \frac{1}{-t_1}\\
\mathbf{elif}\;A \leq -4 \cdot 10^{-85}:\\
\;\;\;\;t_5 \cdot \frac{\sqrt{2}}{B}\\
\mathbf{elif}\;A \leq -1.6 \cdot 10^{-140}:\\
\;\;\;\;\sqrt{F \cdot \left(A \cdot 2\right)} \cdot t_7\\
\mathbf{elif}\;A \leq -5.8 \cdot 10^{-167}:\\
\;\;\;\;t_5 \cdot \frac{t_6}{B}\\
\mathbf{elif}\;A \leq -4.6 \cdot 10^{-303}:\\
\;\;\;\;\frac{-\sqrt{t_1 \cdot \left(\left(A + \left(C - t_4\right)\right) \cdot \left(F \cdot 2\right)\right)}}{t_1}\\
\mathbf{elif}\;A \leq 7.8 \cdot 10^{-177}:\\
\;\;\;\;t_5 \cdot \left(\sqrt{2} \cdot \frac{-1}{t_2}\right)\\
\mathbf{elif}\;A \leq 5.3 \cdot 10^{-102}:\\
\;\;\;\;\frac{\sqrt{2 \cdot \left(\left(F \cdot t_3\right) \cdot \left(A + \mathsf{fma}\left(-0.5, \frac{B \cdot B}{C}, A\right)\right)\right)}}{-t_3}\\
\mathbf{elif}\;A \leq 1.7 \cdot 10^{+92}:\\
\;\;\;\;t_5 \cdot \frac{t_6}{\mathsf{hypot}\left(B, \sqrt{C \cdot -4} \cdot \sqrt{A}\right)}\\
\mathbf{else}:\\
\;\;\;\;t_7 \cdot \sqrt{F \cdot \mathsf{fma}\left(-0.5, \frac{B}{\frac{A - C}{B}}, C \cdot 2\right)}\\
\end{array}
if A < -6.80000000000000028e176Initial program 100
Simplified83.19
[Start]100 | \[ \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}
\] |
|---|
Applied egg-rr82.01
Simplified82.01
[Start]82.01 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]82.01 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]82.01 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr82.03
Simplified82.02
[Start]82.03 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]82.03 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]82.02 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]82.02 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Applied egg-rr80.3
Simplified79.65
[Start]80.3 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
associate-*l/ [=>]80.3 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}\right)
\] |
*-inverses [=>]79.65 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2} \cdot \color{blue}{1}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
*-commutative [=>]79.65 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{1 \cdot \sqrt{2}}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
Applied egg-rr95.67
Simplified80.87
[Start]95.67 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\left(e^{\mathsf{log1p}\left(\sqrt{\frac{2}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)} - 1\right)\right)
\] |
|---|---|
expm1-def [=>]80.97 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{\frac{2}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)\right)}\right)
\] |
expm1-log1p [=>]80.87 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\sqrt{\frac{2}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}\right)
\] |
associate-*r* [=>]80.87 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\sqrt{\frac{2}{\mathsf{fma}\left(B, B, \color{blue}{\left(A \cdot C\right) \cdot -4}\right)}}\right)
\] |
if -6.80000000000000028e176 < A < -5.49999999999999993e-44Initial program 67.29
Simplified62.86
[Start]67.29 | \[ \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}
\] |
|---|
Applied egg-rr62.57
if -5.49999999999999993e-44 < A < -3.9999999999999999e-85Initial program 70.6
Simplified67.06
[Start]70.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}
\] |
|---|
Applied egg-rr71.82
Simplified71.82
[Start]71.82 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]71.82 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]71.82 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr74.34
Simplified74.32
[Start]74.34 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]74.34 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]74.32 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]74.32 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Taylor expanded in B around -inf 86.28
Simplified86.28
[Start]86.28 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(--1 \cdot \frac{\sqrt{2}}{B}\right)
\] |
|---|---|
mul-1-neg [=>]86.28 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\left(-\frac{\sqrt{2}}{B}\right)}\right)
\] |
if -3.9999999999999999e-85 < A < -1.6000000000000001e-140Initial program 79.27
Simplified74.93
[Start]79.27 | \[ \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}
\] |
|---|
Applied egg-rr73.75
Simplified73.75
[Start]73.75 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]73.75 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]73.75 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr76.51
Simplified76.33
[Start]76.51 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]76.51 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]76.33 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]76.33 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Applied egg-rr76.02
Simplified76.02
[Start]76.02 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
associate-*l/ [=>]76.02 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}\right)
\] |
*-inverses [=>]76.02 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2} \cdot \color{blue}{1}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
*-commutative [=>]76.02 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{1 \cdot \sqrt{2}}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
Taylor expanded in A around -inf 79.23
Simplified79.23
[Start]79.23 | \[ \sqrt{F \cdot \left(2 \cdot A\right)} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
*-commutative [=>]79.23 | \[ \sqrt{F \cdot \color{blue}{\left(A \cdot 2\right)}} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
if -1.6000000000000001e-140 < A < -5.80000000000000005e-167Initial program 77.22
Simplified71.45
[Start]77.22 | \[ \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}
\] |
|---|
Applied egg-rr73.46
Simplified73.46
[Start]73.46 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]73.46 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]73.46 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr75.77
Simplified75.74
[Start]75.77 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]75.77 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]75.74 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]75.74 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Taylor expanded in B around inf 75.27
if -5.80000000000000005e-167 < A < -4.59999999999999991e-303Initial program 75.91
Simplified70.94
[Start]75.91 | \[ \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}
\] |
|---|
if -4.59999999999999991e-303 < A < 7.80000000000000028e-177Initial program 76.73
Simplified70.57
[Start]76.73 | \[ \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}
\] |
|---|
Applied egg-rr62.11
Simplified62.11
[Start]62.11 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]62.11 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]62.11 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr62.23
Simplified61.99
[Start]62.23 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]62.23 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]61.99 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]61.99 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Applied egg-rr55.85
Simplified55.85
[Start]55.85 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
associate-*l/ [=>]55.85 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}\right)
\] |
*-inverses [=>]55.85 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2} \cdot \color{blue}{1}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
*-commutative [=>]55.85 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{1 \cdot \sqrt{2}}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
Applied egg-rr55.89
if 7.80000000000000028e-177 < A < 5.3000000000000003e-102Initial program 76.65
Simplified69.72
[Start]76.65 | \[ \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}
\] |
|---|
Taylor expanded in C around inf 85.58
Simplified85.58
[Start]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + -0.5 \cdot \frac{\left({B}^{2} + {A}^{2}\right) - {\left(-1 \cdot A\right)}^{2}}{C}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
|---|---|
associate-*r/ [=>]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + \color{blue}{\frac{-0.5 \cdot \left(\left({B}^{2} + {A}^{2}\right) - {\left(-1 \cdot A\right)}^{2}\right)}{C}}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
associate-/l* [=>]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + \color{blue}{\frac{-0.5}{\frac{C}{\left({B}^{2} + {A}^{2}\right) - {\left(-1 \cdot A\right)}^{2}}}}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
associate--l+ [=>]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + \frac{-0.5}{\frac{C}{\color{blue}{{B}^{2} + \left({A}^{2} - {\left(-1 \cdot A\right)}^{2}\right)}}}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
unpow2 [=>]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + \frac{-0.5}{\frac{C}{\color{blue}{B \cdot B} + \left({A}^{2} - {\left(-1 \cdot A\right)}^{2}\right)}}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
unpow2 [=>]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + \frac{-0.5}{\frac{C}{B \cdot B + \left(\color{blue}{A \cdot A} - {\left(-1 \cdot A\right)}^{2}\right)}}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
mul-1-neg [=>]85.58 | \[ \frac{-\sqrt{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right) \cdot \left(\left(A + \left(A + \frac{-0.5}{\frac{C}{B \cdot B + \left(A \cdot A - {\color{blue}{\left(-A\right)}}^{2}\right)}}\right)\right) \cdot \left(2 \cdot F\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}
\] |
Applied egg-rr85.83
Simplified85.83
[Start]85.83 | \[ 0 - \frac{\sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \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)}
\] |
|---|---|
sub0-neg [=>]85.83 | \[ \color{blue}{-\frac{\sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \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)}}
\] |
mul-1-neg [<=]85.83 | \[ \color{blue}{-1 \cdot \frac{\sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \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)}}
\] |
metadata-eval [<=]85.83 | \[ \color{blue}{\frac{1}{-1}} \cdot \frac{\sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \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)}
\] |
times-frac [<=]85.83 | \[ \color{blue}{\frac{1 \cdot \sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)\right)}}{-1 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}
\] |
neg-mul-1 [<=]85.83 | \[ \frac{1 \cdot \sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)\right)}}{\color{blue}{-\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}
\] |
*-lft-identity [=>]85.83 | \[ \frac{\color{blue}{\sqrt{\left(A + \left(A + -0.5 \cdot \frac{\mathsf{fma}\left(B, B, A \cdot A - A \cdot A\right)}{C}\right)\right) \cdot \left(\left(2 \cdot F\right) \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)}
\] |
if 5.3000000000000003e-102 < A < 1.6999999999999999e92Initial program 80.72
Simplified76.18
[Start]80.72 | \[ \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}
\] |
|---|
Applied egg-rr73.33
Simplified73.33
[Start]73.33 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]73.33 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]73.33 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr73.26
Simplified73.24
[Start]73.26 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]73.26 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]73.24 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]73.24 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Applied egg-rr71.92
Simplified71.88
[Start]71.92 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
associate-*l/ [=>]71.92 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}\right)
\] |
*-inverses [=>]71.88 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2} \cdot \color{blue}{1}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
*-commutative [=>]71.88 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{1 \cdot \sqrt{2}}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
Applied egg-rr71.78
if 1.6999999999999999e92 < A Initial program 98.61
Simplified93.31
[Start]98.61 | \[ \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}
\] |
|---|
Applied egg-rr96.68
Simplified96.68
[Start]96.68 | \[ \frac{-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)} \cdot \sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
|---|---|
*-commutative [=>]96.68 | \[ \frac{-\color{blue}{\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
*-commutative [=>]96.68 | \[ \frac{-\sqrt{F \cdot \left(A + \left(C - \mathsf{hypot}\left(B, A - C\right)\right)\right)} \cdot \sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \color{blue}{\left(C \cdot -4\right)}\right)}}{\mathsf{fma}\left(B, B, A \cdot \left(-4 \cdot C\right)\right)}
\] |
Applied egg-rr96.68
Simplified96.68
[Start]96.68 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right) \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
|---|---|
distribute-lft-neg-out [=>]96.68 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \color{blue}{\left(-\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot \frac{1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)}
\] |
associate-*r/ [=>]96.68 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)} \cdot 1}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}\right)
\] |
*-rgt-identity [=>]96.68 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{\sqrt{2 \cdot \mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}}}{\mathsf{fma}\left(B, B, A \cdot \left(C \cdot -4\right)\right)}\right)
\] |
Applied egg-rr93.58
Simplified92.97
[Start]93.58 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
associate-*l/ [=>]93.58 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\color{blue}{\frac{\sqrt{2} \cdot \frac{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}}\right)
\] |
*-inverses [=>]92.97 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\sqrt{2} \cdot \color{blue}{1}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
*-commutative [=>]92.97 | \[ \sqrt{F \cdot \left(\left(A + C\right) - \mathsf{hypot}\left(B, A - C\right)\right)} \cdot \left(-\frac{\color{blue}{1 \cdot \sqrt{2}}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
Taylor expanded in B around 0 80.66
Simplified78.16
[Start]80.66 | \[ \sqrt{F \cdot \left(-0.5 \cdot \frac{{B}^{2}}{A - C} + 2 \cdot C\right)} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
|---|---|
fma-def [=>]80.66 | \[ \sqrt{F \cdot \color{blue}{\mathsf{fma}\left(-0.5, \frac{{B}^{2}}{A - C}, 2 \cdot C\right)}} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
unpow2 [=>]80.66 | \[ \sqrt{F \cdot \mathsf{fma}\left(-0.5, \frac{\color{blue}{B \cdot B}}{A - C}, 2 \cdot C\right)} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
associate-/l* [=>]78.16 | \[ \sqrt{F \cdot \mathsf{fma}\left(-0.5, \color{blue}{\frac{B}{\frac{A - C}{B}}}, 2 \cdot C\right)} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
*-commutative [=>]78.16 | \[ \sqrt{F \cdot \mathsf{fma}\left(-0.5, \frac{B}{\frac{A - C}{B}}, \color{blue}{C \cdot 2}\right)} \cdot \left(-\frac{1 \cdot \sqrt{2}}{\mathsf{hypot}\left(B, \sqrt{A \cdot \left(C \cdot -4\right)}\right)}\right)
\] |
Final simplification72.14
| Alternative 1 | |
|---|---|
| Error | 71.89% |
| Cost | 34660 |
| Alternative 2 | |
|---|---|
| Error | 70.49% |
| Cost | 34532 |
| Alternative 3 | |
|---|---|
| Error | 70.65% |
| Cost | 28576 |
| Alternative 4 | |
|---|---|
| Error | 70.79% |
| Cost | 28576 |
| Alternative 5 | |
|---|---|
| Error | 71.04% |
| Cost | 28248 |
| Alternative 6 | |
|---|---|
| Error | 61.93% |
| Cost | 27720 |
| Alternative 7 | |
|---|---|
| Error | 62.97% |
| Cost | 27208 |
| Alternative 8 | |
|---|---|
| Error | 63.47% |
| Cost | 21832 |
| Alternative 9 | |
|---|---|
| Error | 64.18% |
| Cost | 21528 |
| Alternative 10 | |
|---|---|
| Error | 64.25% |
| Cost | 21528 |
| Alternative 11 | |
|---|---|
| Error | 64.18% |
| Cost | 21268 |
| Alternative 12 | |
|---|---|
| Error | 64.21% |
| Cost | 20952 |
| Alternative 13 | |
|---|---|
| Error | 73.77% |
| Cost | 20556 |
| Alternative 14 | |
|---|---|
| Error | 76.21% |
| Cost | 15236 |
| Alternative 15 | |
|---|---|
| Error | 81.55% |
| Cost | 14872 |
| Alternative 16 | |
|---|---|
| Error | 82.12% |
| Cost | 14744 |
| Alternative 17 | |
|---|---|
| Error | 81.68% |
| Cost | 14744 |
| Alternative 18 | |
|---|---|
| Error | 84.3% |
| Cost | 14233 |
| Alternative 19 | |
|---|---|
| Error | 86.19% |
| Cost | 8844 |
| Alternative 20 | |
|---|---|
| Error | 87.85% |
| Cost | 8716 |
| Alternative 21 | |
|---|---|
| Error | 91.9% |
| Cost | 8452 |
| Alternative 22 | |
|---|---|
| Error | 87.88% |
| Cost | 8452 |
| Alternative 23 | |
|---|---|
| Error | 95.06% |
| Cost | 6980 |
| Alternative 24 | |
|---|---|
| Error | 95.46% |
| Cost | 6976 |
| Alternative 25 | |
|---|---|
| Error | 96.9% |
| Cost | 6848 |
herbie shell --seed 2023121
(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))))