?

Average Error: 26.9 → 22.9
Time: 2.4min
Precision: binary64
Cost: 83596

?

\[\left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]
\[\begin{array}{l} t_0 := \frac{M \cdot D}{\sqrt{8} \cdot d}\\ t_1 := 1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\\ t_2 := \sqrt{\frac{d}{\ell}}\\ t_3 := \sqrt{\frac{d}{h}} \cdot t_2\\ t_4 := {\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)}\\ t_5 := \left(t_4 \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot t_1\\ \mathbf{if}\;t_5 \leq 5 \cdot 10^{+293}:\\ \;\;\;\;\left(1 - t_0 \cdot \left(t_0 \cdot \frac{h}{\ell}\right)\right) \cdot t_3\\ \mathbf{elif}\;t_5 \leq \infty:\\ \;\;\;\;\left(t_4 \cdot \begin{array}{l} \mathbf{if}\;\frac{d}{\ell} \ne 0:\\ \;\;\;\;{\left(e^{-0.5 \cdot \left(\log \left(\frac{-1}{\ell}\right) + \log \left(-1 \cdot d\right)\right)}\right)}^{-1}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array}\right) \cdot t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{\left(\left(0.125 \cdot h\right) \cdot \frac{M \cdot D}{d}\right) \cdot \left(M \cdot D\right)}{d} - \ell}{\ell} \cdot \left(-t_3\right)\\ \end{array} \]
(FPCore (d h l M D)
 :precision binary64
 (*
  (* (pow (/ d h) (/ 1.0 2.0)) (pow (/ d l) (/ 1.0 2.0)))
  (- 1.0 (* (* (/ 1.0 2.0) (pow (/ (* M D) (* 2.0 d)) 2.0)) (/ h l)))))
(FPCore (d h l M D)
 :precision binary64
 (let* ((t_0 (/ (* M D) (* (sqrt 8.0) d)))
        (t_1
         (- 1.0 (* (* (/ 1.0 2.0) (pow (/ (* M D) (* 2.0 d)) 2.0)) (/ h l))))
        (t_2 (sqrt (/ d l)))
        (t_3 (* (sqrt (/ d h)) t_2))
        (t_4 (pow (/ d h) (/ 1.0 2.0)))
        (t_5 (* (* t_4 (pow (/ d l) (/ 1.0 2.0))) t_1)))
   (if (<= t_5 5e+293)
     (* (- 1.0 (* t_0 (* t_0 (/ h l)))) t_3)
     (if (<= t_5 INFINITY)
       (*
        (*
         t_4
         (if (!= (/ d l) 0.0)
           (pow (exp (* -0.5 (+ (log (/ -1.0 l)) (log (* -1.0 d))))) -1.0)
           t_2))
        t_1)
       (*
        (/ (- (/ (* (* (* 0.125 h) (/ (* M D) d)) (* M D)) d) l) l)
        (- t_3))))))
double code(double d, double h, double l, double M, double D) {
	return (pow((d / h), (1.0 / 2.0)) * pow((d / l), (1.0 / 2.0))) * (1.0 - (((1.0 / 2.0) * pow(((M * D) / (2.0 * d)), 2.0)) * (h / l)));
}
double code(double d, double h, double l, double M, double D) {
	double t_0 = (M * D) / (sqrt(8.0) * d);
	double t_1 = 1.0 - (((1.0 / 2.0) * pow(((M * D) / (2.0 * d)), 2.0)) * (h / l));
	double t_2 = sqrt((d / l));
	double t_3 = sqrt((d / h)) * t_2;
	double t_4 = pow((d / h), (1.0 / 2.0));
	double t_5 = (t_4 * pow((d / l), (1.0 / 2.0))) * t_1;
	double tmp;
	if (t_5 <= 5e+293) {
		tmp = (1.0 - (t_0 * (t_0 * (h / l)))) * t_3;
	} else if (t_5 <= ((double) INFINITY)) {
		double tmp_1;
		if ((d / l) != 0.0) {
			tmp_1 = pow(exp((-0.5 * (log((-1.0 / l)) + log((-1.0 * d))))), -1.0);
		} else {
			tmp_1 = t_2;
		}
		tmp = (t_4 * tmp_1) * t_1;
	} else {
		tmp = ((((((0.125 * h) * ((M * D) / d)) * (M * D)) / d) - l) / l) * -t_3;
	}
	return tmp;
}
public static double code(double d, double h, double l, double M, double D) {
	return (Math.pow((d / h), (1.0 / 2.0)) * Math.pow((d / l), (1.0 / 2.0))) * (1.0 - (((1.0 / 2.0) * Math.pow(((M * D) / (2.0 * d)), 2.0)) * (h / l)));
}
public static double code(double d, double h, double l, double M, double D) {
	double t_0 = (M * D) / (Math.sqrt(8.0) * d);
	double t_1 = 1.0 - (((1.0 / 2.0) * Math.pow(((M * D) / (2.0 * d)), 2.0)) * (h / l));
	double t_2 = Math.sqrt((d / l));
	double t_3 = Math.sqrt((d / h)) * t_2;
	double t_4 = Math.pow((d / h), (1.0 / 2.0));
	double t_5 = (t_4 * Math.pow((d / l), (1.0 / 2.0))) * t_1;
	double tmp;
	if (t_5 <= 5e+293) {
		tmp = (1.0 - (t_0 * (t_0 * (h / l)))) * t_3;
	} else if (t_5 <= Double.POSITIVE_INFINITY) {
		double tmp_1;
		if ((d / l) != 0.0) {
			tmp_1 = Math.pow(Math.exp((-0.5 * (Math.log((-1.0 / l)) + Math.log((-1.0 * d))))), -1.0);
		} else {
			tmp_1 = t_2;
		}
		tmp = (t_4 * tmp_1) * t_1;
	} else {
		tmp = ((((((0.125 * h) * ((M * D) / d)) * (M * D)) / d) - l) / l) * -t_3;
	}
	return tmp;
}
def code(d, h, l, M, D):
	return (math.pow((d / h), (1.0 / 2.0)) * math.pow((d / l), (1.0 / 2.0))) * (1.0 - (((1.0 / 2.0) * math.pow(((M * D) / (2.0 * d)), 2.0)) * (h / l)))
def code(d, h, l, M, D):
	t_0 = (M * D) / (math.sqrt(8.0) * d)
	t_1 = 1.0 - (((1.0 / 2.0) * math.pow(((M * D) / (2.0 * d)), 2.0)) * (h / l))
	t_2 = math.sqrt((d / l))
	t_3 = math.sqrt((d / h)) * t_2
	t_4 = math.pow((d / h), (1.0 / 2.0))
	t_5 = (t_4 * math.pow((d / l), (1.0 / 2.0))) * t_1
	tmp = 0
	if t_5 <= 5e+293:
		tmp = (1.0 - (t_0 * (t_0 * (h / l)))) * t_3
	elif t_5 <= math.inf:
		tmp_1 = 0
		if (d / l) != 0.0:
			tmp_1 = math.pow(math.exp((-0.5 * (math.log((-1.0 / l)) + math.log((-1.0 * d))))), -1.0)
		else:
			tmp_1 = t_2
		tmp = (t_4 * tmp_1) * t_1
	else:
		tmp = ((((((0.125 * h) * ((M * D) / d)) * (M * D)) / d) - l) / l) * -t_3
	return tmp
function code(d, h, l, M, D)
	return Float64(Float64((Float64(d / h) ^ Float64(1.0 / 2.0)) * (Float64(d / l) ^ Float64(1.0 / 2.0))) * Float64(1.0 - Float64(Float64(Float64(1.0 / 2.0) * (Float64(Float64(M * D) / Float64(2.0 * d)) ^ 2.0)) * Float64(h / l))))
end
function code(d, h, l, M, D)
	t_0 = Float64(Float64(M * D) / Float64(sqrt(8.0) * d))
	t_1 = Float64(1.0 - Float64(Float64(Float64(1.0 / 2.0) * (Float64(Float64(M * D) / Float64(2.0 * d)) ^ 2.0)) * Float64(h / l)))
	t_2 = sqrt(Float64(d / l))
	t_3 = Float64(sqrt(Float64(d / h)) * t_2)
	t_4 = Float64(d / h) ^ Float64(1.0 / 2.0)
	t_5 = Float64(Float64(t_4 * (Float64(d / l) ^ Float64(1.0 / 2.0))) * t_1)
	tmp = 0.0
	if (t_5 <= 5e+293)
		tmp = Float64(Float64(1.0 - Float64(t_0 * Float64(t_0 * Float64(h / l)))) * t_3);
	elseif (t_5 <= Inf)
		tmp_1 = 0.0
		if (Float64(d / l) != 0.0)
			tmp_1 = exp(Float64(-0.5 * Float64(log(Float64(-1.0 / l)) + log(Float64(-1.0 * d))))) ^ -1.0;
		else
			tmp_1 = t_2;
		end
		tmp = Float64(Float64(t_4 * tmp_1) * t_1);
	else
		tmp = Float64(Float64(Float64(Float64(Float64(Float64(Float64(0.125 * h) * Float64(Float64(M * D) / d)) * Float64(M * D)) / d) - l) / l) * Float64(-t_3));
	end
	return tmp
end
function tmp = code(d, h, l, M, D)
	tmp = (((d / h) ^ (1.0 / 2.0)) * ((d / l) ^ (1.0 / 2.0))) * (1.0 - (((1.0 / 2.0) * (((M * D) / (2.0 * d)) ^ 2.0)) * (h / l)));
end
function tmp_3 = code(d, h, l, M, D)
	t_0 = (M * D) / (sqrt(8.0) * d);
	t_1 = 1.0 - (((1.0 / 2.0) * (((M * D) / (2.0 * d)) ^ 2.0)) * (h / l));
	t_2 = sqrt((d / l));
	t_3 = sqrt((d / h)) * t_2;
	t_4 = (d / h) ^ (1.0 / 2.0);
	t_5 = (t_4 * ((d / l) ^ (1.0 / 2.0))) * t_1;
	tmp = 0.0;
	if (t_5 <= 5e+293)
		tmp = (1.0 - (t_0 * (t_0 * (h / l)))) * t_3;
	elseif (t_5 <= Inf)
		tmp_2 = 0.0;
		if ((d / l) ~= 0.0)
			tmp_2 = exp((-0.5 * (log((-1.0 / l)) + log((-1.0 * d))))) ^ -1.0;
		else
			tmp_2 = t_2;
		end
		tmp = (t_4 * tmp_2) * t_1;
	else
		tmp = ((((((0.125 * h) * ((M * D) / d)) * (M * D)) / d) - l) / l) * -t_3;
	end
	tmp_3 = tmp;
end
code[d_, h_, l_, M_, D_] := N[(N[(N[Power[N[(d / h), $MachinePrecision], N[(1.0 / 2.0), $MachinePrecision]], $MachinePrecision] * N[Power[N[(d / l), $MachinePrecision], N[(1.0 / 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[(1.0 - N[(N[(N[(1.0 / 2.0), $MachinePrecision] * N[Power[N[(N[(M * D), $MachinePrecision] / N[(2.0 * d), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(h / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
code[d_, h_, l_, M_, D_] := Block[{t$95$0 = N[(N[(M * D), $MachinePrecision] / N[(N[Sqrt[8.0], $MachinePrecision] * d), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(1.0 - N[(N[(N[(1.0 / 2.0), $MachinePrecision] * N[Power[N[(N[(M * D), $MachinePrecision] / N[(2.0 * d), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(h / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Sqrt[N[(d / l), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[(N[Sqrt[N[(d / h), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision]}, Block[{t$95$4 = N[Power[N[(d / h), $MachinePrecision], N[(1.0 / 2.0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$5 = N[(N[(t$95$4 * N[Power[N[(d / l), $MachinePrecision], N[(1.0 / 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]}, If[LessEqual[t$95$5, 5e+293], N[(N[(1.0 - N[(t$95$0 * N[(t$95$0 * N[(h / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * t$95$3), $MachinePrecision], If[LessEqual[t$95$5, Infinity], N[(N[(t$95$4 * If[Unequal[N[(d / l), $MachinePrecision], 0.0], N[Power[N[Exp[N[(-0.5 * N[(N[Log[N[(-1.0 / l), $MachinePrecision]], $MachinePrecision] + N[Log[N[(-1.0 * d), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], -1.0], $MachinePrecision], t$95$2]), $MachinePrecision] * t$95$1), $MachinePrecision], N[(N[(N[(N[(N[(N[(N[(0.125 * h), $MachinePrecision] * N[(N[(M * D), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision] * N[(M * D), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] - l), $MachinePrecision] / l), $MachinePrecision] * (-t$95$3)), $MachinePrecision]]]]]]]]]
\left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right)
\begin{array}{l}
t_0 := \frac{M \cdot D}{\sqrt{8} \cdot d}\\
t_1 := 1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\\
t_2 := \sqrt{\frac{d}{\ell}}\\
t_3 := \sqrt{\frac{d}{h}} \cdot t_2\\
t_4 := {\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)}\\
t_5 := \left(t_4 \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot t_1\\
\mathbf{if}\;t_5 \leq 5 \cdot 10^{+293}:\\
\;\;\;\;\left(1 - t_0 \cdot \left(t_0 \cdot \frac{h}{\ell}\right)\right) \cdot t_3\\

\mathbf{elif}\;t_5 \leq \infty:\\
\;\;\;\;\left(t_4 \cdot \begin{array}{l}
\mathbf{if}\;\frac{d}{\ell} \ne 0:\\
\;\;\;\;{\left(e^{-0.5 \cdot \left(\log \left(\frac{-1}{\ell}\right) + \log \left(-1 \cdot d\right)\right)}\right)}^{-1}\\

\mathbf{else}:\\
\;\;\;\;t_2\\


\end{array}\right) \cdot t_1\\

\mathbf{else}:\\
\;\;\;\;\frac{\frac{\left(\left(0.125 \cdot h\right) \cdot \frac{M \cdot D}{d}\right) \cdot \left(M \cdot D\right)}{d} - \ell}{\ell} \cdot \left(-t_3\right)\\


\end{array}

Error?

Derivation?

  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (pow.f64 (/.f64 d h) (/.f64 1 2)) (pow.f64 (/.f64 d l) (/.f64 1 2))) (-.f64 1 (*.f64 (*.f64 (/.f64 1 2) (pow.f64 (/.f64 (*.f64 M D) (*.f64 2 d)) 2)) (/.f64 h l)))) < 5.00000000000000033e293

    1. Initial program 12.3

      \[\left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]
    2. Applied egg-rr12.4

      \[\leadsto \color{blue}{\left(1 - \frac{h}{\ell} \cdot {\left(\frac{\frac{M \cdot D}{d}}{\sqrt{8}}\right)}^{2}\right) \cdot \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right)} \]
    3. Applied egg-rr10.3

      \[\leadsto \left(1 - \color{blue}{\frac{M \cdot D}{\sqrt{8} \cdot d} \cdot \left(\frac{M \cdot D}{\sqrt{8} \cdot d} \cdot \frac{h}{\ell}\right)}\right) \cdot \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \]

    if 5.00000000000000033e293 < (*.f64 (*.f64 (pow.f64 (/.f64 d h) (/.f64 1 2)) (pow.f64 (/.f64 d l) (/.f64 1 2))) (-.f64 1 (*.f64 (*.f64 (/.f64 1 2) (pow.f64 (/.f64 (*.f64 M D) (*.f64 2 d)) 2)) (/.f64 h l)))) < +inf.0

    1. Initial program 63.2

      \[\left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]
    2. Applied egg-rr63.2

      \[\leadsto \left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot \color{blue}{\begin{array}{l} \color{blue}{\mathbf{if}\;\frac{d}{\ell} \ne 0:\\ \;\;\;\;{\left({\left(\frac{d}{\ell}\right)}^{-0.5}\right)}^{-1}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{d}{\ell}}\\ } \end{array}}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]
    3. Taylor expanded in l around -inf 56.8

      \[\leadsto \left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot \begin{array}{l} \mathbf{if}\;\frac{d}{\ell} \ne 0:\\ \;\;\;\;{\color{blue}{\left(e^{-0.5 \cdot \left(\log \left(\frac{-1}{\ell}\right) + \log \left(-1 \cdot d\right)\right)}\right)}}^{-1}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{d}{\ell}}\\ \end{array}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]

    if +inf.0 < (*.f64 (*.f64 (pow.f64 (/.f64 d h) (/.f64 1 2)) (pow.f64 (/.f64 d l) (/.f64 1 2))) (-.f64 1 (*.f64 (*.f64 (/.f64 1 2) (pow.f64 (/.f64 (*.f64 M D) (*.f64 2 d)) 2)) (/.f64 h l))))

    1. Initial program 64.0

      \[\left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]
    2. Simplified64.0

      \[\leadsto \color{blue}{\mathsf{fma}\left({\left(\frac{\frac{D \cdot M}{d}}{\sqrt{8}}\right)}^{2}, \frac{h}{\ell}, -1\right) \cdot \left(-\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right)} \]
      Proof
    3. Applied egg-rr57.1

      \[\leadsto \color{blue}{\frac{\left(0.125 \cdot {\left(\frac{M \cdot D}{d}\right)}^{2}\right) \cdot h - \ell}{\ell}} \cdot \left(-\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \]
    4. Applied egg-rr55.7

      \[\leadsto \frac{\color{blue}{\frac{\left(h \cdot 0.125\right) \cdot \left(\frac{M \cdot D}{d} \cdot \left(M \cdot D\right)\right)}{d}} - \ell}{\ell} \cdot \left(-\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \]
    5. Applied egg-rr53.3

      \[\leadsto \frac{\frac{\color{blue}{\left(\left(0.125 \cdot h\right) \cdot \frac{M \cdot D}{d}\right) \cdot \left(M \cdot D\right)}}{d} - \ell}{\ell} \cdot \left(-\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \]
  3. Recombined 3 regimes into one program.

Alternatives

Alternative 1
Error24.0
Cost63304
\[\begin{array}{l} t_0 := \frac{M \cdot D}{d}\\ t_1 := \left({\left(\frac{d}{h}\right)}^{\left(\frac{1}{2}\right)} \cdot {\left(\frac{d}{\ell}\right)}^{\left(\frac{1}{2}\right)}\right) \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right)\\ t_2 := -\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\\ t_3 := \frac{\frac{\left(\left(0.125 \cdot h\right) \cdot t_0\right) \cdot \left(M \cdot D\right)}{d} - \ell}{\ell} \cdot t_2\\ \mathbf{if}\;t_1 \leq -1 \cdot 10^{+247}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;t_1 \leq 5 \cdot 10^{+68}:\\ \;\;\;\;\left(\left(0.125 \cdot {t_0}^{2}\right) \cdot \frac{h}{\ell} - 1\right) \cdot t_2\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \]
Alternative 2
Error25.2
Cost28236
\[\begin{array}{l} t_0 := \sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\\ t_1 := -t_0\\ t_2 := \frac{M \cdot D}{\sqrt{8} \cdot d}\\ t_3 := \left(1 - t_2 \cdot \left(t_2 \cdot \frac{h}{\ell}\right)\right) \cdot t_0\\ \mathbf{if}\;M \cdot D \leq -1 \cdot 10^{-202}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;M \cdot D \leq 5 \cdot 10^{-46}:\\ \;\;\;\;\frac{\frac{\frac{\left(M \cdot D\right) \cdot M}{d} \cdot \left(D \cdot \left(0.125 \cdot h\right)\right)}{d} - \ell}{\ell} \cdot t_1\\ \mathbf{elif}\;M \cdot D \leq 2 \cdot 10^{+258}:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{\left(\left(0.125 \cdot h\right) \cdot \frac{M \cdot D}{d}\right) \cdot \left(M \cdot D\right)}{d} - \ell}{\ell} \cdot t_1\\ \end{array} \]
Alternative 3
Error27.0
Cost14592
\[\frac{\frac{\left(h \cdot 0.125\right) \cdot \left(\frac{M \cdot D}{d} \cdot \left(M \cdot D\right)\right)}{d} - \ell}{\ell} \cdot \left(-\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \]
Alternative 4
Error26.1
Cost14592
\[\frac{\frac{\left(\left(0.125 \cdot h\right) \cdot \frac{M \cdot D}{d}\right) \cdot \left(M \cdot D\right)}{d} - \ell}{\ell} \cdot \left(-\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \]
Alternative 5
Error32.2
Cost13248
\[\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}} \]

Error

Reproduce?

herbie shell --seed 2023033 
(FPCore (d h l M D)
  :name "Henrywood and Agarwal, Equation (12)"
  :precision binary64
  (* (* (pow (/ d h) (/ 1.0 2.0)) (pow (/ d l) (/ 1.0 2.0))) (- 1.0 (* (* (/ 1.0 2.0) (pow (/ (* M D) (* 2.0 d)) 2.0)) (/ h l)))))