?

Average Error: 92.94% → 37.22%
Time: 44.2s
Precision: binary64
Cost: 27920

?

\[\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} \]
(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}

Error?

Derivation?

  1. Split input into 5 regimes
  2. if d < -2.2999999999999999e229

    1. Initial program 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) \]
    2. Simplified100

      \[\leadsto \color{blue}{\frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{D \cdot \left(h \cdot D\right)}, \sqrt{\mathsf{fma}\left(\frac{c0}{w \cdot h}, \left(\frac{d}{D} \cdot {\left(\frac{d}{D}\right)}^{3}\right) \cdot \frac{c0}{w \cdot h}, -M \cdot M\right)}\right)} \]
      Proof

      [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) \]
    3. Taylor expanded in c0 around -inf 100

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\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)} \]
    4. Simplified50.21

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{\frac{w \cdot \left(M \cdot \left(M \cdot h\right)\right)}{{\left(\frac{d}{D}\right)}^{2}}}{c0}, c0 \cdot 0\right)} \]
      Proof

      [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)} \]
    5. Applied egg-rr45.33

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(\frac{w \cdot M}{d} \cdot D\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}}{c0}, c0 \cdot 0\right) \]
    6. Simplified39.95

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(D \cdot \frac{w}{\frac{d}{M}}\right) \cdot \left(\frac{M \cdot h}{d} \cdot D\right)}}{c0}, c0 \cdot 0\right) \]
      Proof

      [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) \]
    7. Applied egg-rr36.16

      \[\leadsto \color{blue}{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} \]
    8. Simplified26.83

      \[\leadsto \color{blue}{\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), 0\right)} \]
      Proof

      [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) \]
    9. Applied egg-rr35.81

      \[\leadsto \color{blue}{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)} \]
    10. Simplified36.23

      \[\leadsto \color{blue}{h \cdot \left(\left(\frac{M}{d} \cdot \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)} \]
      Proof

      [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.1999999999999998e164

    1. Initial program 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) \]
    2. Simplified100

      \[\leadsto \color{blue}{\frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{D \cdot \left(h \cdot D\right)}, \sqrt{\mathsf{fma}\left(\frac{c0}{w \cdot h}, \left(\frac{d}{D} \cdot {\left(\frac{d}{D}\right)}^{3}\right) \cdot \frac{c0}{w \cdot h}, -M \cdot M\right)}\right)} \]
      Proof

      [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) \]
    3. Taylor expanded in c0 around -inf 100

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\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)} \]
    4. Simplified54.54

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{\frac{w \cdot \left(M \cdot \left(M \cdot h\right)\right)}{{\left(\frac{d}{D}\right)}^{2}}}{c0}, c0 \cdot 0\right)} \]
      Proof

      [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)} \]
    5. Applied egg-rr50.37

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(\frac{w \cdot M}{d} \cdot D\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}}{c0}, c0 \cdot 0\right) \]
    6. Simplified46.05

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(D \cdot \frac{w}{\frac{d}{M}}\right) \cdot \left(\frac{M \cdot h}{d} \cdot D\right)}}{c0}, c0 \cdot 0\right) \]
      Proof

      [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) \]
    7. Taylor expanded in c0 around 0 54.77

      \[\leadsto \color{blue}{0.25 \cdot \frac{{D}^{2} \cdot \left({M}^{2} \cdot h\right)}{{d}^{2}}} \]
    8. Simplified34.95

      \[\leadsto \color{blue}{\frac{0.25}{d} \cdot \frac{h \cdot \left(\left(D \cdot M\right) \cdot \left(D \cdot M\right)\right)}{d}} \]
      Proof

      [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.15000000000000004e27

    1. Initial program 87.77

      \[\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) \]
    2. Taylor expanded in c0 around -inf 89.81

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\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)} \]
    3. Simplified67.21

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{D \cdot D}{c0 \cdot \left(d \cdot d\right)} \cdot \left(w \cdot \left(M \cdot \left(M \cdot h\right)\right)\right), c0 \cdot 0\right)} \]
      Proof

      [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)} \]
    4. Taylor expanded in c0 around 0 55.84

      \[\leadsto \color{blue}{0.25 \cdot \frac{{D}^{2} \cdot \left(h \cdot {M}^{2}\right)}{{d}^{2}}} \]
    5. Simplified47.58

      \[\leadsto \color{blue}{0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)} \]
      Proof

      [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) \]
    6. Taylor expanded in h around 0 47.58

      \[\leadsto 0.25 \cdot \left(\left(D \cdot \frac{\frac{D}{d}}{d}\right) \cdot \color{blue}{\left({M}^{2} \cdot h\right)}\right) \]
    7. Simplified43.14

      \[\leadsto 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) \]
      Proof

      [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) \]
    8. Applied egg-rr38.62

      \[\leadsto 0.25 \cdot \color{blue}{\left(-\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(M \cdot h\right)\right)\right)\right)} \]

    if -2.69999999999999992e-210 < d < 6e-230

    1. Initial program 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) \]
    2. Simplified98.49

      \[\leadsto \color{blue}{\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}, \frac{c0}{w \cdot h} \cdot \frac{d \cdot d}{D \cdot D}, -M \cdot M\right)}\right)} \]
      Proof

      [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) \]
    3. Applied egg-rr64.1

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(1, \mathsf{hypot}\left(\frac{c0}{h} \cdot \frac{{\left(\frac{d}{D}\right)}^{2}}{w}, M\right), \frac{c0}{h} \cdot \frac{{\left(\frac{d}{D}\right)}^{2}}{w}\right)} \]

    if 2.15000000000000004e27 < d

    1. Initial program 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) \]
    2. Simplified98.44

      \[\leadsto \color{blue}{\frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(d \cdot d, \frac{\frac{c0}{w}}{D \cdot \left(h \cdot D\right)}, \sqrt{\mathsf{fma}\left(\frac{c0}{w \cdot h}, \left(\frac{d}{D} \cdot {\left(\frac{d}{D}\right)}^{3}\right) \cdot \frac{c0}{w \cdot h}, -M \cdot M\right)}\right)} \]
      Proof

      [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) \]
    3. Taylor expanded in c0 around -inf 94.58

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\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)} \]
    4. Simplified52.29

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \color{blue}{\mathsf{fma}\left(0.5, \frac{\frac{w \cdot \left(M \cdot \left(M \cdot h\right)\right)}{{\left(\frac{d}{D}\right)}^{2}}}{c0}, c0 \cdot 0\right)} \]
      Proof

      [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)} \]
    5. Applied egg-rr47.45

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(\frac{w \cdot M}{d} \cdot D\right) \cdot \frac{M \cdot h}{\frac{d}{D}}}}{c0}, c0 \cdot 0\right) \]
    6. Simplified44.33

      \[\leadsto \frac{c0}{2 \cdot w} \cdot \mathsf{fma}\left(0.5, \frac{\color{blue}{\left(D \cdot \frac{w}{\frac{d}{M}}\right) \cdot \left(\frac{M \cdot h}{d} \cdot D\right)}}{c0}, c0 \cdot 0\right) \]
      Proof

      [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) \]
    7. Applied egg-rr42.23

      \[\leadsto \color{blue}{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} \]
    8. Simplified32.44

      \[\leadsto \color{blue}{\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), 0\right)} \]
      Proof

      [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) \]
  3. Recombined 5 regimes into one program.
  4. Final simplification37.22

    \[\leadsto \begin{array}{l} \mathbf{if}\;d \leq -2.3 \cdot 10^{+229}:\\ \;\;\;\;h \cdot \left(\left(\frac{M}{d} \cdot \left(\left(D \cdot \left(\frac{M}{d} \cdot D\right)\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}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{elif}\;d \leq 6 \cdot 10^{-230}:\\ \;\;\;\;\frac{c0}{w \cdot 2} \cdot \mathsf{fma}\left(1, \mathsf{hypot}\left(\frac{c0}{h} \cdot \frac{{\left(\frac{d}{D}\right)}^{2}}{w}, M\right), \frac{c0}{h} \cdot \frac{{\left(\frac{d}{D}\right)}^{2}}{w}\right)\\ \mathbf{elif}\;d \leq 2.15 \cdot 10^{+27}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \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(\left(\frac{M}{d} \cdot D\right) \cdot w\right)\right)\right), 0\right)\\ \end{array} \]

Alternatives

Alternative 1
Error37.66%
Cost14672
\[\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 := {\left(\frac{d}{D}\right)}^{2}\\ \mathbf{if}\;d \leq -1.6 \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 -2.9 \cdot 10^{+165}:\\ \;\;\;\;\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 -9.5 \cdot 10^{-201}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;d \leq 6 \cdot 10^{-230}:\\ \;\;\;\;\frac{\frac{\frac{c0}{w}}{h} \cdot \left(t_2 + t_2\right)}{2 \cdot \frac{w}{c0}}\\ \mathbf{elif}\;d \leq 1.85 \cdot 10^{+31}:\\ \;\;\;\;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} \]
Alternative 2
Error31.98%
Cost13572
\[\begin{array}{l} \mathbf{if}\;h \leq 2 \cdot 10^{-286}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{else}:\\ \;\;\;\;0.25 \cdot {\left(\frac{D}{d} \cdot \left(M \cdot \sqrt{h}\right)\right)}^{2}\\ \end{array} \]
Alternative 3
Error36.42%
Cost8396
\[\begin{array}{l} t_0 := \frac{M}{d} \cdot D\\ \mathbf{if}\;d \leq -1.55 \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 -6 \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 1.52 \cdot 10^{+29}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \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} \]
Alternative 4
Error36.28%
Cost2260
\[\begin{array}{l} t_0 := \frac{M}{d} \cdot D\\ t_1 := \frac{0.25}{w \cdot c0}\\ t_2 := h \cdot \frac{M}{d}\\ t_3 := \frac{0.25}{d} \cdot \frac{h \cdot \left(\left(M \cdot D\right) \cdot \left(M \cdot D\right)\right)}{d}\\ \mathbf{if}\;d \leq -3.25 \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 t_1\right)\right)\\ \mathbf{elif}\;d \leq -5.8 \cdot 10^{+164}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;d \leq 3.4 \cdot 10^{+18}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{elif}\;d \leq 1.3 \cdot 10^{+203}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;d \leq 3.1 \cdot 10^{+240}:\\ \;\;\;\;c0 \cdot \left(t_1 \cdot \left(t_2 \cdot \left(D \cdot \left(D \cdot \left(\frac{M}{d} \cdot w\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{c0}{\frac{w \cdot 2}{\frac{0.5}{\frac{c0}{t_2 \cdot \left(D \cdot \left(t_0 \cdot w\right)\right)}}}}\\ \end{array} \]
Alternative 5
Error37.19%
Cost2000
\[\begin{array}{l} t_0 := h \cdot \left(\left(\frac{M}{d} \cdot \left(\left(D \cdot \left(\frac{M}{d} \cdot D\right)\right) \cdot w\right)\right) \cdot \left(c0 \cdot \frac{0.25}{w \cdot c0}\right)\right)\\ t_1 := \frac{0.25}{d} \cdot \frac{h \cdot \left(\left(M \cdot D\right) \cdot \left(M \cdot D\right)\right)}{d}\\ \mathbf{if}\;d \leq -1.85 \cdot 10^{+229}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;d \leq -5 \cdot 10^{+165}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;d \leq 3.1 \cdot 10^{+18}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{elif}\;d \leq 1.3 \cdot 10^{+203}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_0\\ \end{array} \]
Alternative 6
Error37.27%
Cost2000
\[\begin{array}{l} t_0 := \frac{0.25}{w \cdot c0}\\ t_1 := \frac{0.25}{d} \cdot \frac{h \cdot \left(\left(M \cdot D\right) \cdot \left(M \cdot D\right)\right)}{d}\\ \mathbf{if}\;d \leq -9 \cdot 10^{+228}:\\ \;\;\;\;h \cdot \left(\left(\frac{M}{d} \cdot \left(\left(D \cdot \left(\frac{M}{d} \cdot D\right)\right) \cdot w\right)\right) \cdot \left(c0 \cdot t_0\right)\right)\\ \mathbf{elif}\;d \leq -4.6 \cdot 10^{+165}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;d \leq 1.8 \cdot 10^{+18}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{elif}\;d \leq 1.3 \cdot 10^{+203}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;c0 \cdot \left(t_0 \cdot \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)\right)\\ \end{array} \]
Alternative 7
Error36.55%
Cost1996
\[\begin{array}{l} t_0 := \frac{M}{d} \cdot D\\ \mathbf{if}\;d \leq -3.5 \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 -1 \cdot 10^{+165}:\\ \;\;\;\;\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 5 \cdot 10^{+38}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{c0 \cdot \frac{0.5}{\frac{c0}{\left(h \cdot \frac{M}{d}\right) \cdot \left(D \cdot \left(t_0 \cdot w\right)\right)}}}{w}}{2}\\ \end{array} \]
Alternative 8
Error37.2%
Cost1741
\[\begin{array}{l} t_0 := M \cdot \left(h \cdot M\right)\\ \mathbf{if}\;d \cdot d \leq 10^{-45}:\\ \;\;\;\;0.25 \cdot \frac{t_0}{\frac{d}{D} \cdot \frac{d}{D}}\\ \mathbf{elif}\;d \cdot d \leq 2 \cdot 10^{+187} \lor \neg \left(d \cdot d \leq 4 \cdot 10^{+302}\right):\\ \;\;\;\;\frac{0.25}{d} \cdot \frac{h \cdot \left(\left(M \cdot D\right) \cdot \left(M \cdot D\right)\right)}{d}\\ \mathbf{else}:\\ \;\;\;\;0.25 \cdot \left(t_0 \cdot \frac{D}{d \cdot \frac{d}{D}}\right)\\ \end{array} \]
Alternative 9
Error36.61%
Cost1604
\[\begin{array}{l} \mathbf{if}\;M \leq 1.18 \cdot 10^{+142}:\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{else}:\\ \;\;\;\;c0 \cdot \left(h \cdot \left(\frac{0.25}{w \cdot c0} \cdot \left(\frac{M}{d} \cdot \left(D \cdot \frac{D}{\frac{\frac{d}{M}}{w}}\right)\right)\right)\right)\\ \end{array} \]
Alternative 10
Error35.59%
Cost1545
\[\begin{array}{l} \mathbf{if}\;d \cdot d \leq 10^{-45} \lor \neg \left(d \cdot d \leq 2 \cdot 10^{+187}\right):\\ \;\;\;\;\left(\frac{D}{-d} \cdot \left(\frac{D}{d} \cdot \left(M \cdot \left(h \cdot M\right)\right)\right)\right) \cdot -0.25\\ \mathbf{else}:\\ \;\;\;\;\frac{0.25}{d} \cdot \frac{h \cdot \left(\left(M \cdot D\right) \cdot \left(M \cdot D\right)\right)}{d}\\ \end{array} \]
Alternative 11
Error39.87%
Cost1480
\[\begin{array}{l} t_0 := M \cdot \left(h \cdot M\right)\\ \mathbf{if}\;D \cdot D \leq 10^{-321}:\\ \;\;\;\;0.25 \cdot \left(t_0 \cdot \left(D \cdot \frac{\frac{D}{d}}{d}\right)\right)\\ \mathbf{elif}\;D \cdot D \leq 5 \cdot 10^{+280}:\\ \;\;\;\;0.25 \cdot \frac{\frac{D}{\frac{d}{D}}}{\frac{d}{t_0}}\\ \mathbf{else}:\\ \;\;\;\;0.25 \cdot \frac{t_0}{\frac{d}{D} \cdot \frac{d}{D}}\\ \end{array} \]
Alternative 12
Error41.24%
Cost1220
\[\begin{array}{l} t_0 := M \cdot \left(h \cdot M\right)\\ \mathbf{if}\;D \cdot D \leq 5 \cdot 10^{-307}:\\ \;\;\;\;0.25 \cdot \left(t_0 \cdot \left(D \cdot \frac{\frac{D}{d}}{d}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;0.25 \cdot \frac{t_0 \cdot \frac{D}{\frac{d}{D}}}{d}\\ \end{array} \]
Alternative 13
Error42.55%
Cost960
\[0.25 \cdot \left(\left(M \cdot \left(h \cdot M\right)\right) \cdot \left(D \cdot \frac{\frac{D}{d}}{d}\right)\right) \]
Alternative 14
Error40.73%
Cost960
\[0.25 \cdot \frac{M \cdot \left(h \cdot M\right)}{\frac{d}{D} \cdot \frac{d}{D}} \]
Alternative 15
Error49.62%
Cost64
\[0 \]

Error

Reproduce?

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))))))