| Alternative 1 | |
|---|---|
| Error | 37.66% |
| Cost | 14672 |
(FPCore (c0 w h D d M)
:precision binary64
(*
(/ c0 (* 2.0 w))
(+
(/ (* c0 (* d d)) (* (* w h) (* D D)))
(sqrt
(-
(*
(/ (* c0 (* d d)) (* (* w h) (* D D)))
(/ (* c0 (* d d)) (* (* w h) (* D D))))
(* M M))))))(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (* (/ M d) D))
(t_1 (* (* (/ D (- d)) (* (/ D d) (* M (* h M)))) -0.25))
(t_2 (* (/ c0 h) (/ (pow (/ d D) 2.0) w))))
(if (<= d -2.3e+229)
(* h (* (* (/ M d) (* (* D t_0) w)) (* c0 (/ 0.25 (* w c0)))))
(if (<= d -5.2e+164)
(* (/ 0.25 d) (/ (* h (* (* M D) (* M D))) d))
(if (<= d -2.7e-210)
t_1
(if (<= d 6e-230)
(* (/ c0 (* w 2.0)) (fma 1.0 (hypot t_2 M) t_2))
(if (<= d 2.15e+27)
t_1
(fma
c0
(* (/ 0.5 w) (* (/ 0.5 c0) (* (* D (* h (/ M d))) (* t_0 w))))
0.0))))))))double code(double c0, double w, double h, double D, double d, double M) {
return (c0 / (2.0 * w)) * (((c0 * (d * d)) / ((w * h) * (D * D))) + sqrt(((((c0 * (d * d)) / ((w * h) * (D * D))) * ((c0 * (d * d)) / ((w * h) * (D * D)))) - (M * M))));
}
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (M / d) * D;
double t_1 = ((D / -d) * ((D / d) * (M * (h * M)))) * -0.25;
double t_2 = (c0 / h) * (pow((d / D), 2.0) / w);
double tmp;
if (d <= -2.3e+229) {
tmp = h * (((M / d) * ((D * t_0) * w)) * (c0 * (0.25 / (w * c0))));
} else if (d <= -5.2e+164) {
tmp = (0.25 / d) * ((h * ((M * D) * (M * D))) / d);
} else if (d <= -2.7e-210) {
tmp = t_1;
} else if (d <= 6e-230) {
tmp = (c0 / (w * 2.0)) * fma(1.0, hypot(t_2, M), t_2);
} else if (d <= 2.15e+27) {
tmp = t_1;
} else {
tmp = fma(c0, ((0.5 / w) * ((0.5 / c0) * ((D * (h * (M / d))) * (t_0 * w)))), 0.0);
}
return tmp;
}
function code(c0, w, h, D, d, M) return Float64(Float64(c0 / Float64(2.0 * w)) * Float64(Float64(Float64(c0 * Float64(d * d)) / Float64(Float64(w * h) * Float64(D * D))) + sqrt(Float64(Float64(Float64(Float64(c0 * Float64(d * d)) / Float64(Float64(w * h) * Float64(D * D))) * Float64(Float64(c0 * Float64(d * d)) / Float64(Float64(w * h) * Float64(D * D)))) - Float64(M * M))))) end
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(M / d) * D) t_1 = Float64(Float64(Float64(D / Float64(-d)) * Float64(Float64(D / d) * Float64(M * Float64(h * M)))) * -0.25) t_2 = Float64(Float64(c0 / h) * Float64((Float64(d / D) ^ 2.0) / w)) tmp = 0.0 if (d <= -2.3e+229) tmp = Float64(h * Float64(Float64(Float64(M / d) * Float64(Float64(D * t_0) * w)) * Float64(c0 * Float64(0.25 / Float64(w * c0))))); elseif (d <= -5.2e+164) tmp = Float64(Float64(0.25 / d) * Float64(Float64(h * Float64(Float64(M * D) * Float64(M * D))) / d)); elseif (d <= -2.7e-210) tmp = t_1; elseif (d <= 6e-230) tmp = Float64(Float64(c0 / Float64(w * 2.0)) * fma(1.0, hypot(t_2, M), t_2)); elseif (d <= 2.15e+27) tmp = t_1; else tmp = fma(c0, Float64(Float64(0.5 / w) * Float64(Float64(0.5 / c0) * Float64(Float64(D * Float64(h * Float64(M / d))) * Float64(t_0 * w)))), 0.0); end return tmp end
code[c0_, w_, h_, D_, d_, M_] := N[(N[(c0 / N[(2.0 * w), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(c0 * N[(d * d), $MachinePrecision]), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] * N[(D * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[Sqrt[N[(N[(N[(N[(c0 * N[(d * d), $MachinePrecision]), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] * N[(D * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 * N[(d * d), $MachinePrecision]), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] * N[(D * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(M * M), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(M / d), $MachinePrecision] * D), $MachinePrecision]}, Block[{t$95$1 = N[(N[(N[(D / (-d)), $MachinePrecision] * N[(N[(D / d), $MachinePrecision] * N[(M * N[(h * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -0.25), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c0 / h), $MachinePrecision] * N[(N[Power[N[(d / D), $MachinePrecision], 2.0], $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[d, -2.3e+229], N[(h * N[(N[(N[(M / d), $MachinePrecision] * N[(N[(D * t$95$0), $MachinePrecision] * w), $MachinePrecision]), $MachinePrecision] * N[(c0 * N[(0.25 / N[(w * c0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[d, -5.2e+164], N[(N[(0.25 / d), $MachinePrecision] * N[(N[(h * N[(N[(M * D), $MachinePrecision] * N[(M * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[d, -2.7e-210], t$95$1, If[LessEqual[d, 6e-230], N[(N[(c0 / N[(w * 2.0), $MachinePrecision]), $MachinePrecision] * N[(1.0 * N[Sqrt[t$95$2 ^ 2 + M ^ 2], $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision], If[LessEqual[d, 2.15e+27], t$95$1, N[(c0 * N[(N[(0.5 / w), $MachinePrecision] * N[(N[(0.5 / c0), $MachinePrecision] * N[(N[(D * N[(h * N[(M / d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(t$95$0 * w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 0.0), $MachinePrecision]]]]]]]]]
\frac{c0}{2 \cdot w} \cdot \left(\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\begin{array}{l}
t_0 := \frac{M}{d} \cdot D\\
t_1 := \left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\
t_2 := \frac{c0}{h} \cdot \frac{{\left(\frac{d}{D}\right)}^{2}}{w}\\
\mathbf{if}\;d \leq -2.3 \cdot 10^{+229}:\\
\;\;\;\;h \cdot \left(\left(\frac{M}{d} \cdot \left(\left(D \cdot t_0\right) \cdot w\right)\right) \cdot \left(c0 \cdot \frac{0.25}{w \cdot c0}\right)\right)\\
\mathbf{elif}\;d \leq -5.2 \cdot 10^{+164}:\\
\;\;\;\;\frac{0.25}{d} \cdot \frac{h \cdot \left(\left(M \cdot D\right) \cdot \left(M \cdot D\right)\right)}{d}\\
\mathbf{elif}\;d \leq -2.7 \cdot 10^{-210}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;d \leq 6 \cdot 10^{-230}:\\
\;\;\;\;\frac{c0}{w \cdot 2} \cdot \mathsf{fma}\left(1, \mathsf{hypot}\left(t_2, M\right), t_2\right)\\
\mathbf{elif}\;d \leq 2.15 \cdot 10^{+27}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right) \cdot \left(t_0 \cdot w\right)\right)\right), 0\right)\\
\end{array}
if d < -2.2999999999999999e229Initial program 100
Simplified100
[Start]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
|---|---|
associate-*l/ [<=]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \left(d \cdot d\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
*-commutative [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\left(d \cdot d\right) \cdot \frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
fma-def [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(d \cdot d, \frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)}
\] |
associate-*l* [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{c0}{\color{blue}{w \cdot \left(h \cdot \left(D \cdot D\right)\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
associate-/r* [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \color{blue}{\frac{\frac{c0}{w}}{h \cdot \left(D \cdot D\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
associate-*r* [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{\color{blue}{\left(h \cdot D\right) \cdot D}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
*-commutative [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{\color{blue}{D \cdot \left(h \cdot D\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
Taylor expanded in c0 around -inf 100
Simplified50.21
[Start]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(0.5 \cdot \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0} + -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)
\] |
|---|---|
fma-def [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0}, -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)}
\] |
Applied egg-rr45.33
Simplified39.95
[Start]45.33 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(\frac{w \cdot M}{d} \cdot D\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
|---|---|
*-commutative [=>]45.33 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(D \cdot \frac{w \cdot M}{d}\right)} \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
associate-/l* [=>]39.44 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(D \cdot \color{blue}{\frac{w}{\frac{d}{M}}}\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
associate-/r/ [=>]39.95 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(D \cdot \frac{w}{\frac{d}{M}}\right) \cdot \color{blue}{\left(\frac{M \cdot h}{d} \cdot D\right)}}{c0}, c0 \cdot 0\right)
\] |
Applied egg-rr36.16
Simplified26.83
[Start]36.16 | \[ c0 \cdot \left(\frac{0.5}{w} \cdot \frac{0.5}{\frac{c0}{\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)}}\right) + \frac{c0 \cdot 0.5}{w} \cdot 0
\] |
|---|---|
fma-def [=>]36.16 | \[ \color{blue}{\mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \frac{0.5}{\frac{c0}{\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)}}, \frac{c0 \cdot 0.5}{w} \cdot 0\right)}
\] |
associate-/r/ [=>]36.11 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \color{blue}{\left(\frac{0.5}{c0} \cdot \left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)\right)\right)}, \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
associate-*r* [=>]35.34 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \color{blue}{\left(\left(\left(h \cdot \frac{M}{d}\right) \cdot D\right) \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)}\right), \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
*-commutative [<=]35.34 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\color{blue}{\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right)} \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)\right), \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
*-commutative [=>]35.34 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right) \cdot \left(w \cdot \color{blue}{\left(D \cdot \frac{M}{d}\right)}\right)\right)\right), \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
mul0-rgt [=>]26.83 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right) \cdot \left(w \cdot \left(D \cdot \frac{M}{d}\right)\right)\right)\right), \color{blue}{0}\right)
\] |
Applied egg-rr35.81
Simplified36.23
[Start]35.81 | \[ 0 + c0 \cdot \left(\left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right) \cdot \frac{0.25}{w \cdot c0}\right)
\] |
|---|---|
+-lft-identity [=>]35.81 | \[ \color{blue}{c0 \cdot \left(\left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right) \cdot \frac{0.25}{w \cdot c0}\right)}
\] |
*-commutative [<=]35.81 | \[ \color{blue}{\left(\left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right) \cdot \frac{0.25}{w \cdot c0}\right) \cdot c0}
\] |
associate-*l* [=>]35.25 | \[ \color{blue}{\left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right) \cdot \left(\frac{0.25}{w \cdot c0} \cdot c0\right)}
\] |
*-commutative [<=]35.25 | \[ \left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right) \cdot \color{blue}{\left(c0 \cdot \frac{0.25}{w \cdot c0}\right)}
\] |
associate-*l* [=>]35.95 | \[ \color{blue}{\left(h \cdot \left(\frac{M}{d} \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right)\right)} \cdot \left(c0 \cdot \frac{0.25}{w \cdot c0}\right)
\] |
associate-*l* [=>]36.82 | \[ \color{blue}{h \cdot \left(\left(\frac{M}{d} \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right) \cdot \left(c0 \cdot \frac{0.25}{w \cdot c0}\right)\right)}
\] |
associate-*r* [=>]35.99 | \[ h \cdot \left(\left(\frac{M}{d} \cdot \left(D \cdot \color{blue}{\left(\left(D \cdot \frac{M}{d}\right) \cdot w\right)}\right)\right) \cdot \left(c0 \cdot \frac{0.25}{w \cdot c0}\right)\right)
\] |
associate-*r* [=>]36.23 | \[ h \cdot \left(\left(\frac{M}{d} \cdot \color{blue}{\left(\left(D \cdot \left(D \cdot \frac{M}{d}\right)\right) \cdot w\right)}\right) \cdot \left(c0 \cdot \frac{0.25}{w \cdot c0}\right)\right)
\] |
if -2.2999999999999999e229 < d < -5.1999999999999998e164Initial program 100
Simplified100
[Start]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
|---|---|
associate-*l/ [<=]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \left(d \cdot d\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
*-commutative [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\left(d \cdot d\right) \cdot \frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
fma-def [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(d \cdot d, \frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)}
\] |
associate-*l* [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{c0}{\color{blue}{w \cdot \left(h \cdot \left(D \cdot D\right)\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
associate-/r* [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \color{blue}{\frac{\frac{c0}{w}}{h \cdot \left(D \cdot D\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
associate-*r* [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{\color{blue}{\left(h \cdot D\right) \cdot D}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
*-commutative [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{\color{blue}{D \cdot \left(h \cdot D\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
Taylor expanded in c0 around -inf 100
Simplified54.54
[Start]100 | \[ \frac{c0}{2 \cdot w} \cdot \left(0.5 \cdot \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0} + -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)
\] |
|---|---|
fma-def [=>]100 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0}, -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)}
\] |
Applied egg-rr50.37
Simplified46.05
[Start]50.37 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(\frac{w \cdot M}{d} \cdot D\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
|---|---|
*-commutative [=>]50.37 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(D \cdot \frac{w \cdot M}{d}\right)} \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
associate-/l* [=>]45.8 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(D \cdot \color{blue}{\frac{w}{\frac{d}{M}}}\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
associate-/r/ [=>]46.05 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(D \cdot \frac{w}{\frac{d}{M}}\right) \cdot \color{blue}{\left(\frac{M \cdot h}{d} \cdot D\right)}}{c0}, c0 \cdot 0\right)
\] |
Taylor expanded in c0 around 0 54.77
Simplified34.95
[Start]54.77 | \[ 0.25 \cdot \frac{{D}^{2} \cdot \left({M}^{2} \cdot h\right)}{{d}^{2}}
\] |
|---|---|
associate-*r/ [=>]54.77 | \[ \color{blue}{\frac{0.25 \cdot \left({D}^{2} \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2}}}
\] |
unpow2 [=>]54.77 | \[ \frac{0.25 \cdot \left({D}^{2} \cdot \left({M}^{2} \cdot h\right)\right)}{\color{blue}{d \cdot d}}
\] |
times-frac [=>]51.31 | \[ \color{blue}{\frac{0.25}{d} \cdot \frac{{D}^{2} \cdot \left({M}^{2} \cdot h\right)}{d}}
\] |
associate-*r* [=>]50.66 | \[ \frac{0.25}{d} \cdot \frac{\color{blue}{\left({D}^{2} \cdot {M}^{2}\right) \cdot h}}{d}
\] |
*-commutative [=>]50.66 | \[ \frac{0.25}{d} \cdot \frac{\color{blue}{h \cdot \left({D}^{2} \cdot {M}^{2}\right)}}{d}
\] |
unpow2 [=>]50.66 | \[ \frac{0.25}{d} \cdot \frac{h \cdot \left(\color{blue}{\left(D \cdot D\right)} \cdot {M}^{2}\right)}{d}
\] |
unpow2 [=>]50.66 | \[ \frac{0.25}{d} \cdot \frac{h \cdot \left(\left(D \cdot D\right) \cdot \color{blue}{\left(M \cdot M\right)}\right)}{d}
\] |
unswap-sqr [=>]34.95 | \[ \frac{0.25}{d} \cdot \frac{h \cdot \color{blue}{\left(\left(D \cdot M\right) \cdot \left(D \cdot M\right)\right)}}{d}
\] |
if -5.1999999999999998e164 < d < -2.69999999999999992e-210 or 6e-230 < d < 2.15000000000000004e27Initial program 87.77
Taylor expanded in c0 around -inf 89.81
Simplified67.21
[Start]89.81 | \[ \frac{c0}{2 \cdot w} \cdot \left(0.5 \cdot \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0} + -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)
\] |
|---|---|
fma-def [=>]89.81 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0}, -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)}
\] |
Taylor expanded in c0 around 0 55.84
Simplified47.58
[Start]55.84 | \[ 0.25 \cdot \frac{{D}^{2} \cdot \left(h \cdot {M}^{2}\right)}{{d}^{2}}
\] |
|---|---|
*-commutative [=>]55.84 | \[ 0.25 \cdot \frac{{D}^{2} \cdot \color{blue}{\left({M}^{2} \cdot h\right)}}{{d}^{2}}
\] |
associate-/l* [=>]55.54 | \[ 0.25 \cdot \color{blue}{\frac{{D}^{2}}{\frac{{d}^{2}}{{M}^{2} \cdot h}}}
\] |
unpow2 [=>]55.54 | \[ 0.25 \cdot \frac{\color{blue}{D \cdot D}}{\frac{{d}^{2}}{{M}^{2} \cdot h}}
\] |
unpow2 [=>]55.54 | \[ 0.25 \cdot \frac{D \cdot D}{\frac{\color{blue}{d \cdot d}}{{M}^{2} \cdot h}}
\] |
unpow2 [=>]55.54 | \[ 0.25 \cdot \frac{D \cdot D}{\frac{d \cdot d}{\color{blue}{\left(M \cdot M\right)} \cdot h}}
\] |
associate-*r* [<=]52.58 | \[ 0.25 \cdot \frac{D \cdot D}{\frac{d \cdot d}{\color{blue}{M \cdot \left(M \cdot h\right)}}}
\] |
associate-/r/ [=>]52.83 | \[ 0.25 \cdot \color{blue}{\left(\frac{D \cdot D}{d \cdot d} \cdot \left(M \cdot \left(M \cdot h\right)\right)\right)}
\] |
associate-*r/ [<=]49.68 | \[ 0.25 \cdot \left(\color{blue}{\left(D \cdot \frac{D}{d \cdot d}\right)} \cdot \left(M \cdot \left(M \cdot h\right)\right)\right)
\] |
associate-/r* [=>]43.14 | \[ 0.25 \cdot \left(\left(D \cdot \color{blue}{\frac{\frac{D}{d}}{d}}\right) \cdot \left(M \cdot \left(M \cdot h\right)\right)\right)
\] |
*-commutative [=>]43.14 | \[ 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \color{blue}{\left(\left(M \cdot h\right) \cdot M\right)}\right)
\] |
*-commutative [=>]43.14 | \[ 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \left(\color{blue}{\left(h \cdot M\right)} \cdot M\right)\right)
\] |
associate-*r* [<=]47.58 | \[ 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \color{blue}{\left(h \cdot \left(M \cdot M\right)\right)}\right)
\] |
Taylor expanded in h around 0 47.58
Simplified43.14
[Start]47.58 | \[ 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \left({M}^{2} \cdot h\right)\right)
\] |
|---|---|
unpow2 [=>]47.58 | \[ 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \left(\color{blue}{\left(M \cdot M\right)} \cdot h\right)\right)
\] |
associate-*l* [=>]43.14 | \[ 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \color{blue}{\left(M \cdot \left(M \cdot h\right)\right)}\right)
\] |
Applied egg-rr38.62
if -2.69999999999999992e-210 < d < 6e-230Initial program 98.96
Simplified98.49
[Start]98.96 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
|---|---|
times-frac [=>]99.29 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D}} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
fma-neg [=>]99.29 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D} + \sqrt{\color{blue}{\mathsf{fma}\left(\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}, \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}, -M \cdot M\right)}}\right)
\] |
times-frac [=>]99.29 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D} + \sqrt{\mathsf{fma}\left(\color{blue}{\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D}}, \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}, -M \cdot M\right)}\right)
\] |
times-frac [=>]98.49 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D} + \sqrt{\mathsf{fma}\left(\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D}, \color{blue}{\frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D}}, -M \cdot M\right)}\right)
\] |
Applied egg-rr64.1
if 2.15000000000000004e27 < d Initial program 95.32
Simplified98.44
[Start]95.32 | \[ \frac{c0}{2 \cdot w} \cdot \left(\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
|---|---|
associate-*l/ [<=]95.68 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \left(d \cdot d\right)} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
*-commutative [=>]95.68 | \[ \frac{c0}{2 \cdot w} \cdot \left(\color{blue}{\left(d \cdot d\right) \cdot \frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}} + \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
fma-def [=>]96.55 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(d \cdot d, \frac{c0}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)}
\] |
associate-*l* [=>]97.03 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{c0}{\color{blue}{w \cdot \left(h \cdot \left(D \cdot D\right)\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
associate-/r* [=>]97.14 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \color{blue}{\frac{\frac{c0}{w}}{h \cdot \left(D \cdot D\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
associate-*r* [=>]97.21 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{\color{blue}{\left(h \cdot D\right) \cdot D}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
*-commutative [=>]97.21 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{\color{blue}{D \cdot \left(h \cdot D\right)}}, \sqrt{\frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} \cdot \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)} - M \cdot M}\right)
\] |
Taylor expanded in c0 around -inf 94.58
Simplified52.29
[Start]94.58 | \[ \frac{c0}{2 \cdot w} \cdot \left(0.5 \cdot \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0} + -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)
\] |
|---|---|
fma-def [=>]94.58 | \[ \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{{D}^{2} \cdot \left(w \cdot \left({M}^{2} \cdot h\right)\right)}{{d}^{2} \cdot c0}, -1 \cdot \left(\left(\frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)} + -1 \cdot \frac{{d}^{2}}{{D}^{2} \cdot \left(w \cdot h\right)}\right) \cdot c0\right)\right)}
\] |
Applied egg-rr47.45
Simplified44.33
[Start]47.45 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(\frac{w \cdot M}{d} \cdot D\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
|---|---|
*-commutative [=>]47.45 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(D \cdot \frac{w \cdot M}{d}\right)} \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
associate-/l* [=>]44.09 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(D \cdot \color{blue}{\frac{w}{\frac{d}{M}}}\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}{c0}, c0 \cdot 0\right)
\] |
associate-/r/ [=>]44.33 | \[ \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\left(D \cdot \frac{w}{\frac{d}{M}}\right) \cdot \color{blue}{\left(\frac{M \cdot h}{d} \cdot D\right)}}{c0}, c0 \cdot 0\right)
\] |
Applied egg-rr42.23
Simplified32.44
[Start]42.23 | \[ c0 \cdot \left(\frac{0.5}{w} \cdot \frac{0.5}{\frac{c0}{\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)}}\right) + \frac{c0 \cdot 0.5}{w} \cdot 0
\] |
|---|---|
fma-def [=>]42.23 | \[ \color{blue}{\mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \frac{0.5}{\frac{c0}{\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)}}, \frac{c0 \cdot 0.5}{w} \cdot 0\right)}
\] |
associate-/r/ [=>]42.18 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \color{blue}{\left(\frac{0.5}{c0} \cdot \left(\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)\right)\right)}, \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
associate-*r* [=>]40.7 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \color{blue}{\left(\left(\left(h \cdot \frac{M}{d}\right) \cdot D\right) \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)}\right), \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
*-commutative [<=]40.7 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\color{blue}{\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right)} \cdot \left(w \cdot \left(\frac{M}{d} \cdot D\right)\right)\right)\right), \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
*-commutative [=>]40.7 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right) \cdot \left(w \cdot \color{blue}{\left(D \cdot \frac{M}{d}\right)}\right)\right)\right), \frac{c0 \cdot 0.5}{w} \cdot 0\right)
\] |
mul0-rgt [=>]32.44 | \[ \mathsf{fma}\left(c0, \frac{0.5}{w} \cdot \left(\frac{0.5}{c0} \cdot \left(\left(D \cdot \left(h \cdot \frac{M}{d}\right)\right) \cdot \left(w \cdot \left(D \cdot \frac{M}{d}\right)\right)\right)\right), \color{blue}{0}\right)
\] |
Final simplification37.22
| Alternative 1 | |
|---|---|
| Error | 37.66% |
| Cost | 14672 |
| Alternative 2 | |
|---|---|
| Error | 31.98% |
| Cost | 13572 |
| Alternative 3 | |
|---|---|
| Error | 36.42% |
| Cost | 8396 |
| Alternative 4 | |
|---|---|
| Error | 36.28% |
| Cost | 2260 |
| Alternative 5 | |
|---|---|
| Error | 37.19% |
| Cost | 2000 |
| Alternative 6 | |
|---|---|
| Error | 37.27% |
| Cost | 2000 |
| Alternative 7 | |
|---|---|
| Error | 36.55% |
| Cost | 1996 |
| Alternative 8 | |
|---|---|
| Error | 37.2% |
| Cost | 1741 |
| Alternative 9 | |
|---|---|
| Error | 36.61% |
| Cost | 1604 |
| Alternative 10 | |
|---|---|
| Error | 35.59% |
| Cost | 1545 |
| Alternative 11 | |
|---|---|
| Error | 39.87% |
| Cost | 1480 |
| Alternative 12 | |
|---|---|
| Error | 41.24% |
| Cost | 1220 |
| Alternative 13 | |
|---|---|
| Error | 42.55% |
| Cost | 960 |
| Alternative 14 | |
|---|---|
| Error | 40.73% |
| Cost | 960 |
| Alternative 15 | |
|---|---|
| Error | 49.62% |
| Cost | 64 |
herbie shell --seed 2023121
(FPCore (c0 w h D d M)
:name "Henrywood and Agarwal, Equation (13)"
:precision binary64
(* (/ c0 (* 2.0 w)) (+ (/ (* c0 (* d d)) (* (* w h) (* D D))) (sqrt (- (* (/ (* c0 (* d d)) (* (* w h) (* D D))) (/ (* c0 (* d d)) (* (* w h) (* D D)))) (* M M))))))