?

Average Error: 26.2 → 18.3
Time: 50.6s
Precision: binary64
Cost: 27980

?

\[\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 := {\left(D \cdot \frac{M}{d}\right)}^{2}\\ t_1 := {\left(\frac{d}{\ell}\right)}^{0.5}\\ t_2 := {\left(\frac{d}{h}\right)}^{0.5}\\ t_3 := {\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}\\ \mathbf{if}\;h \leq -3.4 \cdot 10^{+166}:\\ \;\;\;\;\left(t_2 \cdot t_1\right) \cdot \left(1 - \frac{h}{\frac{\ell}{0.5 \cdot \left(0.25 \cdot t_0\right)}}\right)\\ \mathbf{elif}\;h \leq 5 \cdot 10^{-309}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{t_3}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;h \leq 3.1 \cdot 10^{-95}:\\ \;\;\;\;\left({d}^{0.5} \cdot \left({\left(\frac{1}{h}\right)}^{0.5} \cdot t_1\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left(t_0 \cdot 0.125\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left({\left(d + d\right)}^{0.5} \cdot {\left(\frac{0.5}{\ell}\right)}^{0.5}\right) \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{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 (pow (* D (/ M d)) 2.0))
        (t_1 (pow (/ d l) 0.5))
        (t_2 (pow (/ d h) 0.5))
        (t_3 (pow (* (/ 0.5 d) (* D M)) 2.0)))
   (if (<= h -3.4e+166)
     (* (* t_2 t_1) (- 1.0 (/ h (/ l (* 0.5 (* 0.25 t_0))))))
     (if (<= h 5e-309)
       (* (* (sqrt (/ 1.0 (* l h))) (- d)) (- 1.0 (* 0.5 (/ t_3 (/ l h)))))
       (if (<= h 3.1e-95)
         (*
          (* (pow d 0.5) (* (pow (/ 1.0 h) 0.5) t_1))
          (- 1.0 (* (/ h l) (* t_0 0.125))))
         (*
          (* (* (pow (+ d d) 0.5) (pow (/ 0.5 l) 0.5)) t_2)
          (- 1.0 (* 0.5 (/ h (/ 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 = pow((D * (M / d)), 2.0);
	double t_1 = pow((d / l), 0.5);
	double t_2 = pow((d / h), 0.5);
	double t_3 = pow(((0.5 / d) * (D * M)), 2.0);
	double tmp;
	if (h <= -3.4e+166) {
		tmp = (t_2 * t_1) * (1.0 - (h / (l / (0.5 * (0.25 * t_0)))));
	} else if (h <= 5e-309) {
		tmp = (sqrt((1.0 / (l * h))) * -d) * (1.0 - (0.5 * (t_3 / (l / h))));
	} else if (h <= 3.1e-95) {
		tmp = (pow(d, 0.5) * (pow((1.0 / h), 0.5) * t_1)) * (1.0 - ((h / l) * (t_0 * 0.125)));
	} else {
		tmp = ((pow((d + d), 0.5) * pow((0.5 / l), 0.5)) * t_2) * (1.0 - (0.5 * (h / (l / t_3))));
	}
	return tmp;
}
real(8) function code(d, h, l, m, d_1)
    real(8), intent (in) :: d
    real(8), intent (in) :: h
    real(8), intent (in) :: l
    real(8), intent (in) :: m
    real(8), intent (in) :: d_1
    code = (((d / h) ** (1.0d0 / 2.0d0)) * ((d / l) ** (1.0d0 / 2.0d0))) * (1.0d0 - (((1.0d0 / 2.0d0) * (((m * d_1) / (2.0d0 * d)) ** 2.0d0)) * (h / l)))
end function
real(8) function code(d, h, l, m, d_1)
    real(8), intent (in) :: d
    real(8), intent (in) :: h
    real(8), intent (in) :: l
    real(8), intent (in) :: m
    real(8), intent (in) :: d_1
    real(8) :: t_0
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_0 = (d_1 * (m / d)) ** 2.0d0
    t_1 = (d / l) ** 0.5d0
    t_2 = (d / h) ** 0.5d0
    t_3 = ((0.5d0 / d) * (d_1 * m)) ** 2.0d0
    if (h <= (-3.4d+166)) then
        tmp = (t_2 * t_1) * (1.0d0 - (h / (l / (0.5d0 * (0.25d0 * t_0)))))
    else if (h <= 5d-309) then
        tmp = (sqrt((1.0d0 / (l * h))) * -d) * (1.0d0 - (0.5d0 * (t_3 / (l / h))))
    else if (h <= 3.1d-95) then
        tmp = ((d ** 0.5d0) * (((1.0d0 / h) ** 0.5d0) * t_1)) * (1.0d0 - ((h / l) * (t_0 * 0.125d0)))
    else
        tmp = ((((d + d) ** 0.5d0) * ((0.5d0 / l) ** 0.5d0)) * t_2) * (1.0d0 - (0.5d0 * (h / (l / t_3))))
    end if
    code = tmp
end function
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 = Math.pow((D * (M / d)), 2.0);
	double t_1 = Math.pow((d / l), 0.5);
	double t_2 = Math.pow((d / h), 0.5);
	double t_3 = Math.pow(((0.5 / d) * (D * M)), 2.0);
	double tmp;
	if (h <= -3.4e+166) {
		tmp = (t_2 * t_1) * (1.0 - (h / (l / (0.5 * (0.25 * t_0)))));
	} else if (h <= 5e-309) {
		tmp = (Math.sqrt((1.0 / (l * h))) * -d) * (1.0 - (0.5 * (t_3 / (l / h))));
	} else if (h <= 3.1e-95) {
		tmp = (Math.pow(d, 0.5) * (Math.pow((1.0 / h), 0.5) * t_1)) * (1.0 - ((h / l) * (t_0 * 0.125)));
	} else {
		tmp = ((Math.pow((d + d), 0.5) * Math.pow((0.5 / l), 0.5)) * t_2) * (1.0 - (0.5 * (h / (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 = math.pow((D * (M / d)), 2.0)
	t_1 = math.pow((d / l), 0.5)
	t_2 = math.pow((d / h), 0.5)
	t_3 = math.pow(((0.5 / d) * (D * M)), 2.0)
	tmp = 0
	if h <= -3.4e+166:
		tmp = (t_2 * t_1) * (1.0 - (h / (l / (0.5 * (0.25 * t_0)))))
	elif h <= 5e-309:
		tmp = (math.sqrt((1.0 / (l * h))) * -d) * (1.0 - (0.5 * (t_3 / (l / h))))
	elif h <= 3.1e-95:
		tmp = (math.pow(d, 0.5) * (math.pow((1.0 / h), 0.5) * t_1)) * (1.0 - ((h / l) * (t_0 * 0.125)))
	else:
		tmp = ((math.pow((d + d), 0.5) * math.pow((0.5 / l), 0.5)) * t_2) * (1.0 - (0.5 * (h / (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(D * Float64(M / d)) ^ 2.0
	t_1 = Float64(d / l) ^ 0.5
	t_2 = Float64(d / h) ^ 0.5
	t_3 = Float64(Float64(0.5 / d) * Float64(D * M)) ^ 2.0
	tmp = 0.0
	if (h <= -3.4e+166)
		tmp = Float64(Float64(t_2 * t_1) * Float64(1.0 - Float64(h / Float64(l / Float64(0.5 * Float64(0.25 * t_0))))));
	elseif (h <= 5e-309)
		tmp = Float64(Float64(sqrt(Float64(1.0 / Float64(l * h))) * Float64(-d)) * Float64(1.0 - Float64(0.5 * Float64(t_3 / Float64(l / h)))));
	elseif (h <= 3.1e-95)
		tmp = Float64(Float64((d ^ 0.5) * Float64((Float64(1.0 / h) ^ 0.5) * t_1)) * Float64(1.0 - Float64(Float64(h / l) * Float64(t_0 * 0.125))));
	else
		tmp = Float64(Float64(Float64((Float64(d + d) ^ 0.5) * (Float64(0.5 / l) ^ 0.5)) * t_2) * Float64(1.0 - Float64(0.5 * Float64(h / Float64(l / 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_2 = code(d, h, l, M, D)
	t_0 = (D * (M / d)) ^ 2.0;
	t_1 = (d / l) ^ 0.5;
	t_2 = (d / h) ^ 0.5;
	t_3 = ((0.5 / d) * (D * M)) ^ 2.0;
	tmp = 0.0;
	if (h <= -3.4e+166)
		tmp = (t_2 * t_1) * (1.0 - (h / (l / (0.5 * (0.25 * t_0)))));
	elseif (h <= 5e-309)
		tmp = (sqrt((1.0 / (l * h))) * -d) * (1.0 - (0.5 * (t_3 / (l / h))));
	elseif (h <= 3.1e-95)
		tmp = ((d ^ 0.5) * (((1.0 / h) ^ 0.5) * t_1)) * (1.0 - ((h / l) * (t_0 * 0.125)));
	else
		tmp = ((((d + d) ^ 0.5) * ((0.5 / l) ^ 0.5)) * t_2) * (1.0 - (0.5 * (h / (l / t_3))));
	end
	tmp_2 = 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[Power[N[(D * N[(M / d), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$1 = N[Power[N[(d / l), $MachinePrecision], 0.5], $MachinePrecision]}, Block[{t$95$2 = N[Power[N[(d / h), $MachinePrecision], 0.5], $MachinePrecision]}, Block[{t$95$3 = N[Power[N[(N[(0.5 / d), $MachinePrecision] * N[(D * M), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]}, If[LessEqual[h, -3.4e+166], N[(N[(t$95$2 * t$95$1), $MachinePrecision] * N[(1.0 - N[(h / N[(l / N[(0.5 * N[(0.25 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[h, 5e-309], N[(N[(N[Sqrt[N[(1.0 / N[(l * h), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-d)), $MachinePrecision] * N[(1.0 - N[(0.5 * N[(t$95$3 / N[(l / h), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[h, 3.1e-95], N[(N[(N[Power[d, 0.5], $MachinePrecision] * N[(N[Power[N[(1.0 / h), $MachinePrecision], 0.5], $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision] * N[(1.0 - N[(N[(h / l), $MachinePrecision] * N[(t$95$0 * 0.125), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Power[N[(d + d), $MachinePrecision], 0.5], $MachinePrecision] * N[Power[N[(0.5 / l), $MachinePrecision], 0.5], $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(1.0 - N[(0.5 * N[(h / N[(l / t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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 := {\left(D \cdot \frac{M}{d}\right)}^{2}\\
t_1 := {\left(\frac{d}{\ell}\right)}^{0.5}\\
t_2 := {\left(\frac{d}{h}\right)}^{0.5}\\
t_3 := {\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}\\
\mathbf{if}\;h \leq -3.4 \cdot 10^{+166}:\\
\;\;\;\;\left(t_2 \cdot t_1\right) \cdot \left(1 - \frac{h}{\frac{\ell}{0.5 \cdot \left(0.25 \cdot t_0\right)}}\right)\\

\mathbf{elif}\;h \leq 5 \cdot 10^{-309}:\\
\;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{t_3}{\frac{\ell}{h}}\right)\\

\mathbf{elif}\;h \leq 3.1 \cdot 10^{-95}:\\
\;\;\;\;\left({d}^{0.5} \cdot \left({\left(\frac{1}{h}\right)}^{0.5} \cdot t_1\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left(t_0 \cdot 0.125\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left({\left(d + d\right)}^{0.5} \cdot {\left(\frac{0.5}{\ell}\right)}^{0.5}\right) \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{t_3}}\right)\\


\end{array}

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation?

  1. Split input into 4 regimes
  2. if h < -3.4e166

    1. Initial program 30.8

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

      \[\leadsto \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 - \color{blue}{\frac{h}{\frac{\ell}{0.5 \cdot \left(0.25 \cdot {\left(D \cdot \frac{M}{d}\right)}^{2}\right)}}}\right) \]

    if -3.4e166 < h < 4.9999999999999995e-309

    1. Initial program 24.7

      \[\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. Simplified34.5

      \[\leadsto \color{blue}{{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \frac{\frac{D}{d}}{2}\right)}^{2} \cdot \frac{h}{\ell}\right)\right)} \]
      Proof

      [Start]24.7

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

      exponential.json-simplify-27 [=>]33.9

      \[ \color{blue}{{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{\left(\frac{1}{2}\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) \]

      metadata-eval [=>]33.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{\color{blue}{0.5}} \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]

      rational.json-simplify-2 [=>]33.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{h}{\ell} \cdot \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right)}\right) \]

      rational.json-simplify-43 [=>]33.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{1}{2} \cdot \left({\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2} \cdot \frac{h}{\ell}\right)}\right) \]

      metadata-eval [=>]33.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{0.5} \cdot \left({\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-2 [=>]33.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(\frac{\color{blue}{D \cdot M}}{2 \cdot d}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-49 [=>]34.5

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\color{blue}{\left(M \cdot \frac{D}{2 \cdot d}\right)}}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-2 [=>]34.5

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \frac{D}{\color{blue}{d \cdot 2}}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-46 [=>]34.5

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \color{blue}{\frac{\frac{D}{d}}{2}}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]
    3. Applied egg-rr33.9

      \[\leadsto {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \color{blue}{\frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}}\right) \]
    4. Taylor expanded in d around -inf 19.3

      \[\leadsto \color{blue}{\left(-1 \cdot \left(d \cdot \sqrt{\frac{1}{\ell \cdot h}}\right)\right)} \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right) \]
    5. Simplified19.3

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

      [Start]19.3

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

      rational.json-simplify-2 [=>]19.3

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

      rational.json-simplify-43 [=>]19.3

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

      rational.json-simplify-8 [<=]19.3

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

    if 4.9999999999999995e-309 < h < 3.09999999999999992e-95

    1. Initial program 31.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. Simplified39.6

      \[\leadsto \color{blue}{{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \left(0.5 \cdot {\left(D \cdot \frac{M}{d \cdot 2}\right)}^{2}\right) \cdot \frac{h}{\ell}\right)} \]
      Proof

      [Start]31.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) \]

      exponential.json-simplify-27 [=>]38.9

      \[ \color{blue}{{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{\left(\frac{1}{2}\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) \]

      metadata-eval [=>]38.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{\color{blue}{0.5}} \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]

      metadata-eval [=>]38.9

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \left(\color{blue}{0.5} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]

      rational.json-simplify-49 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \left(0.5 \cdot {\color{blue}{\left(D \cdot \frac{M}{2 \cdot d}\right)}}^{2}\right) \cdot \frac{h}{\ell}\right) \]

      rational.json-simplify-2 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \left(0.5 \cdot {\left(D \cdot \frac{M}{\color{blue}{d \cdot 2}}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]
    3. Applied egg-rr39.6

      \[\leadsto {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\left({\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \left(0.5 \cdot \frac{h}{\ell}\right) + 0\right)}\right) \]
    4. Simplified39.6

      \[\leadsto {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)}\right) \]
      Proof

      [Start]39.6

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

      rational.json-simplify-4 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{{\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \left(0.5 \cdot \frac{h}{\ell}\right)}\right) \]

      rational.json-simplify-2 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \color{blue}{\left(\frac{h}{\ell} \cdot 0.5\right)}\right) \]

      metadata-eval [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \left(\frac{h}{\ell} \cdot \color{blue}{\frac{2}{4}}\right)\right) \]

      rational.json-simplify-49 [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \color{blue}{\frac{2 \cdot \frac{h}{\ell}}{4}}\right) \]

      metadata-eval [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \frac{2 \cdot \frac{h}{\ell}}{\color{blue}{\frac{2}{0.5}}}\right) \]

      rational.json-simplify-61 [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2} \cdot \color{blue}{\frac{0.5}{\frac{2}{2 \cdot \frac{h}{\ell}}}}\right) \]

      rational.json-simplify-49 [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{0.5 \cdot {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}{\frac{2}{2 \cdot \frac{h}{\ell}}}}\right) \]

      rational.json-simplify-61 [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{2 \cdot \frac{h}{\ell}}{\frac{2}{0.5 \cdot {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}}}\right) \]

      rational.json-simplify-49 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{h}{\ell} \cdot \frac{2}{\frac{2}{0.5 \cdot {\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}}}\right) \]

      rational.json-simplify-46 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{2}{\color{blue}{\frac{\frac{2}{0.5}}{{\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}}}\right) \]

      metadata-eval [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{2}{\frac{\color{blue}{4}}{{\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}}\right) \]

      rational.json-simplify-61 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \color{blue}{\frac{{\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}{\frac{4}{2}}}\right) \]

      metadata-eval [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{{\left(D \cdot \left(0.5 \cdot \frac{M}{d}\right)\right)}^{2}}{\color{blue}{2}}\right) \]

      rational.json-simplify-43 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{{\color{blue}{\left(0.5 \cdot \left(\frac{M}{d} \cdot D\right)\right)}}^{2}}{2}\right) \]

      rational.json-simplify-2 [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{{\left(0.5 \cdot \color{blue}{\left(D \cdot \frac{M}{d}\right)}\right)}^{2}}{2}\right) \]

      exponential.json-simplify-26 [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{\color{blue}{{0.5}^{2} \cdot {\left(D \cdot \frac{M}{d}\right)}^{2}}}{2}\right) \]

      metadata-eval [=>]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{\color{blue}{0.25} \cdot {\left(D \cdot \frac{M}{d}\right)}^{2}}{2}\right) \]

      metadata-eval [<=]39.6

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot \frac{\color{blue}{\frac{2}{8}} \cdot {\left(D \cdot \frac{M}{d}\right)}^{2}}{2}\right) \]
    5. Applied egg-rr17.4

      \[\leadsto \color{blue}{\left({d}^{0.5} \cdot \left({\left(\frac{1}{h}\right)}^{0.5} \cdot {\left(\frac{d}{\ell}\right)}^{0.5}\right)\right)} \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)\right) \]

    if 3.09999999999999992e-95 < h

    1. Initial program 23.9

      \[\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. Simplified34.2

      \[\leadsto \color{blue}{{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \frac{\frac{D}{d}}{2}\right)}^{2} \cdot \frac{h}{\ell}\right)\right)} \]
      Proof

      [Start]23.9

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

      exponential.json-simplify-27 [=>]34.2

      \[ \color{blue}{{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{\left(\frac{1}{2}\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) \]

      metadata-eval [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{\color{blue}{0.5}} \cdot \left(1 - \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right) \]

      rational.json-simplify-2 [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{h}{\ell} \cdot \left(\frac{1}{2} \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right)}\right) \]

      rational.json-simplify-43 [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{\frac{1}{2} \cdot \left({\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2} \cdot \frac{h}{\ell}\right)}\right) \]

      metadata-eval [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \color{blue}{0.5} \cdot \left({\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-2 [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(\frac{\color{blue}{D \cdot M}}{2 \cdot d}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-49 [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\color{blue}{\left(M \cdot \frac{D}{2 \cdot d}\right)}}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-2 [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \frac{D}{\color{blue}{d \cdot 2}}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]

      rational.json-simplify-46 [=>]34.2

      \[ {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \color{blue}{\frac{\frac{D}{d}}{2}}\right)}^{2} \cdot \frac{h}{\ell}\right)\right) \]
    3. Applied egg-rr23.9

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

      \[\leadsto \left({\left(\frac{d}{\ell}\right)}^{0.5} \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - 0.5 \cdot \color{blue}{\frac{h}{\frac{\ell}{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}}}\right) \]
    5. Applied egg-rr15.2

      \[\leadsto \left(\color{blue}{\left({\left(d + d\right)}^{0.5} \cdot {\left(\frac{0.5}{\ell}\right)}^{0.5}\right)} \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}}\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification18.3

    \[\leadsto \begin{array}{l} \mathbf{if}\;h \leq -3.4 \cdot 10^{+166}:\\ \;\;\;\;\left({\left(\frac{d}{h}\right)}^{0.5} \cdot {\left(\frac{d}{\ell}\right)}^{0.5}\right) \cdot \left(1 - \frac{h}{\frac{\ell}{0.5 \cdot \left(0.25 \cdot {\left(D \cdot \frac{M}{d}\right)}^{2}\right)}}\right)\\ \mathbf{elif}\;h \leq 5 \cdot 10^{-309}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;h \leq 3.1 \cdot 10^{-95}:\\ \;\;\;\;\left({d}^{0.5} \cdot \left({\left(\frac{1}{h}\right)}^{0.5} \cdot {\left(\frac{d}{\ell}\right)}^{0.5}\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left({\left(d + d\right)}^{0.5} \cdot {\left(\frac{0.5}{\ell}\right)}^{0.5}\right) \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}}\right)\\ \end{array} \]

Alternatives

Alternative 1
Error19.9
Cost104592
\[\begin{array}{l} t_0 := 1 - \left(0.5 \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\\ t_1 := {\left(\frac{d}{\ell}\right)}^{0.5}\\ t_2 := {\left(\frac{d}{h}\right)}^{0.5}\\ t_3 := \left(t_2 \cdot t_1\right) \cdot t_0\\ t_4 := \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;t_3 \leq -\infty:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot d\right) \cdot \left(1 - 0.125 \cdot \frac{h \cdot {\left(D \cdot M\right)}^{2}}{\ell \cdot {d}^{2}}\right)\\ \mathbf{elif}\;t_3 \leq -5 \cdot 10^{-97}:\\ \;\;\;\;\left(t_2 \cdot {\left(d \cdot \frac{1}{\ell}\right)}^{0.5}\right) \cdot t_0\\ \mathbf{elif}\;t_3 \leq 5 \cdot 10^{-267}:\\ \;\;\;\;t_4 \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot \left(D \cdot \frac{M}{d}\right)\right)}^{2}}{\ell}\right)\right)\right)\\ \mathbf{elif}\;t_3 \leq 2 \cdot 10^{+272}:\\ \;\;\;\;\left(t_1 \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}}\right)\\ \mathbf{else}:\\ \;\;\;\;d \cdot \left(-t_4\right)\\ \end{array} \]
Alternative 2
Error20.1
Cost27724
\[\begin{array}{l} t_0 := D \cdot \frac{M}{d}\\ t_1 := {t_0}^{2}\\ t_2 := {\left(\frac{d}{\ell}\right)}^{0.5}\\ \mathbf{if}\;h \leq -3.4 \cdot 10^{+166}:\\ \;\;\;\;\left({\left(\frac{d}{h}\right)}^{0.5} \cdot t_2\right) \cdot \left(1 - \frac{h}{\frac{\ell}{0.5 \cdot \left(0.25 \cdot t_1\right)}}\right)\\ \mathbf{elif}\;h \leq 5 \cdot 10^{-309}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;h \leq 1.1 \cdot 10^{-45}:\\ \;\;\;\;\left({d}^{0.5} \cdot \left({\left(\frac{1}{h}\right)}^{0.5} \cdot t_2\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left(t_1 \cdot 0.125\right)\right)\\ \mathbf{elif}\;h \leq 8.5 \cdot 10^{+229}:\\ \;\;\;\;\sqrt{\frac{1}{h \cdot \ell}} \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_0\right)}^{2}}{\ell}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left({\left(\frac{1}{\ell}\right)}^{0.5} \cdot {\left(d \cdot \frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - \frac{{\left(D \cdot \left(M \cdot \frac{0.5}{d}\right)\right)}^{2}}{\ell} \cdot \left(0.5 \cdot h\right)\right)\\ \end{array} \]
Alternative 3
Error21.7
Cost21652
\[\begin{array}{l} t_0 := {\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}\\ t_1 := D \cdot \frac{M}{d}\\ t_2 := \sqrt{\frac{1}{\ell \cdot h}}\\ t_3 := \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;d \leq -1.1 \cdot 10^{+158}:\\ \;\;\;\;\left(t_2 \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{t_0}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;d \leq -9.2 \cdot 10^{-272}:\\ \;\;\;\;\left({\left(\frac{d}{\ell}\right)}^{0.5} \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{t_0}}\right)\\ \mathbf{elif}\;d \leq 6.5 \cdot 10^{-162}:\\ \;\;\;\;t_3 \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_1\right)}^{2}}{\ell}\right)\right)\right)\\ \mathbf{elif}\;d \leq 7.5 \cdot 10^{-61}:\\ \;\;\;\;\left(t_2 \cdot d\right) \cdot \left(1 - 0.125 \cdot \frac{h \cdot {\left(D \cdot M\right)}^{2}}{\ell \cdot {d}^{2}}\right)\\ \mathbf{elif}\;d \leq 1.5 \cdot 10^{+119}:\\ \;\;\;\;\left({\left(\frac{1}{h}\right)}^{0.5} \cdot {\left(d \cdot \frac{d}{\ell}\right)}^{0.5}\right) \cdot \left(1 - \frac{{\left(D \cdot \left(M \cdot \frac{0.5}{d}\right)\right)}^{2}}{\ell} \cdot \left(0.5 \cdot h\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(d \cdot t_3\right) \cdot \left(1 - h \cdot \left({t_1}^{2} \cdot \left(0.5 \cdot \frac{0.25}{\ell}\right)\right)\right)\\ \end{array} \]
Alternative 4
Error22.1
Cost21652
\[\begin{array}{l} t_0 := \sqrt{\frac{1}{h \cdot \ell}}\\ t_1 := \sqrt{\frac{1}{\ell \cdot h}}\\ t_2 := D \cdot \frac{M}{d}\\ \mathbf{if}\;d \leq -4.6 \cdot 10^{+39}:\\ \;\;\;\;\left(t_1 \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;d \leq -9.2 \cdot 10^{-272}:\\ \;\;\;\;\left({\left(d \cdot \frac{1}{h}\right)}^{0.5} \cdot {\left(\frac{d}{\ell}\right)}^{0.5}\right) \cdot \left(1 - \left(0.5 \cdot {\left(\frac{M \cdot D}{2 \cdot d}\right)}^{2}\right) \cdot \frac{h}{\ell}\right)\\ \mathbf{elif}\;d \leq 6.8 \cdot 10^{-162}:\\ \;\;\;\;t_0 \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_2\right)}^{2}}{\ell}\right)\right)\right)\\ \mathbf{elif}\;d \leq 2.25 \cdot 10^{-60}:\\ \;\;\;\;\left(t_1 \cdot d\right) \cdot \left(1 - 0.125 \cdot \frac{h \cdot {\left(D \cdot M\right)}^{2}}{\ell \cdot {d}^{2}}\right)\\ \mathbf{elif}\;d \leq 2.1 \cdot 10^{+115}:\\ \;\;\;\;\left({\left(\frac{1}{h}\right)}^{0.5} \cdot {\left(d \cdot \frac{d}{\ell}\right)}^{0.5}\right) \cdot \left(1 - \frac{{\left(D \cdot \left(M \cdot \frac{0.5}{d}\right)\right)}^{2}}{\ell} \cdot \left(0.5 \cdot h\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(d \cdot t_0\right) \cdot \left(1 - h \cdot \left({t_2}^{2} \cdot \left(0.5 \cdot \frac{0.25}{\ell}\right)\right)\right)\\ \end{array} \]
Alternative 5
Error24.3
Cost21392
\[\begin{array}{l} t_0 := D \cdot \frac{M}{d}\\ t_1 := {\left(\frac{d}{\ell}\right)}^{0.5} \cdot {\left(\frac{d}{h}\right)}^{0.5}\\ t_2 := \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;\ell \leq -1.3 \cdot 10^{+211}:\\ \;\;\;\;d \cdot \left(-t_2\right)\\ \mathbf{elif}\;\ell \leq -3.5 \cdot 10^{+55}:\\ \;\;\;\;t_1 \cdot \left(1 - \frac{h}{\ell} \cdot \left({t_0}^{2} \cdot 0.125\right)\right)\\ \mathbf{elif}\;\ell \leq -2.8 \cdot 10^{-153}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;\ell \leq 4 \cdot 10^{-42}:\\ \;\;\;\;t_1 \cdot \left(1 - 0.5 \cdot \left({\left(M \cdot \frac{\frac{D}{d}}{2}\right)}^{2} \cdot \frac{h}{\ell}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t_2 \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_0\right)}^{2}}{\ell}\right)\right)\right)\\ \end{array} \]
Alternative 6
Error22.9
Cost21392
\[\begin{array}{l} t_0 := D \cdot \frac{M}{d}\\ t_1 := {\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}\\ t_2 := {\left(\frac{d}{\ell}\right)}^{0.5} \cdot {\left(\frac{d}{h}\right)}^{0.5}\\ t_3 := \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;\ell \leq -2.5 \cdot 10^{+212}:\\ \;\;\;\;d \cdot \left(-t_3\right)\\ \mathbf{elif}\;\ell \leq -3.6 \cdot 10^{+55}:\\ \;\;\;\;t_2 \cdot \left(1 - \frac{h}{\ell} \cdot \left({t_0}^{2} \cdot 0.125\right)\right)\\ \mathbf{elif}\;\ell \leq -1.25 \cdot 10^{-149}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{t_1}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;\ell \leq 6.6 \cdot 10^{-229}:\\ \;\;\;\;t_2 \cdot \left(1 - 0.5 \cdot \frac{h}{\frac{\ell}{t_1}}\right)\\ \mathbf{else}:\\ \;\;\;\;t_3 \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_0\right)}^{2}}{\ell}\right)\right)\right)\\ \end{array} \]
Alternative 7
Error23.3
Cost21264
\[\begin{array}{l} t_0 := D \cdot \frac{M}{d}\\ t_1 := \left({\left(\frac{d}{\ell}\right)}^{0.5} \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({t_0}^{2} \cdot 0.125\right)\right)\\ t_2 := \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;\ell \leq -4.6 \cdot 10^{+208}:\\ \;\;\;\;d \cdot \left(-t_2\right)\\ \mathbf{elif}\;\ell \leq -3.5 \cdot 10^{+55}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;\ell \leq -1.7 \cdot 10^{-153}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;\ell \leq 2 \cdot 10^{-288}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2 \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_0\right)}^{2}}{\ell}\right)\right)\right)\\ \end{array} \]
Alternative 8
Error22.7
Cost14800
\[\begin{array}{l} t_0 := D \cdot \frac{M}{d}\\ t_1 := {t_0}^{2} \cdot 0.125\\ \mathbf{if}\;h \leq -1.05 \cdot 10^{+169}:\\ \;\;\;\;{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\frac{\ell}{t_1}}\right)\\ \mathbf{elif}\;h \leq -2 \cdot 10^{-310}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(\frac{D \cdot M}{d}\right)}^{2} \cdot 0.125\right)\right)\\ \mathbf{elif}\;h \leq 8.5 \cdot 10^{+229}:\\ \;\;\;\;\sqrt{\frac{1}{h \cdot \ell}} \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_0\right)}^{2}}{\ell}\right)\right)\right)\\ \mathbf{elif}\;h \leq 2.9 \cdot 10^{+273}:\\ \;\;\;\;{\left(\frac{\frac{d}{\ell}}{\frac{h}{d}}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot t_1\right)\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{h}}{\ell}}\\ \end{array} \]
Alternative 9
Error22.6
Cost14800
\[\begin{array}{l} t_0 := D \cdot \frac{M}{d}\\ t_1 := {t_0}^{2} \cdot 0.125\\ \mathbf{if}\;h \leq -3.25 \cdot 10^{+168}:\\ \;\;\;\;{\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\frac{\ell}{t_1}}\right)\\ \mathbf{elif}\;h \leq -2 \cdot 10^{-310}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot \left(-d\right)\right) \cdot \left(1 - 0.5 \cdot \frac{{\left(\frac{0.5}{d} \cdot \left(D \cdot M\right)\right)}^{2}}{\frac{\ell}{h}}\right)\\ \mathbf{elif}\;h \leq 1.15 \cdot 10^{+230}:\\ \;\;\;\;\sqrt{\frac{1}{h \cdot \ell}} \cdot \left(d \cdot \left(1 - h \cdot \left(0.5 \cdot \frac{{\left(0.5 \cdot t_0\right)}^{2}}{\ell}\right)\right)\right)\\ \mathbf{elif}\;h \leq 3.15 \cdot 10^{+273}:\\ \;\;\;\;{\left(\frac{\frac{d}{\ell}}{\frac{h}{d}}\right)}^{0.5} \cdot \left(1 - \frac{h}{\ell} \cdot t_1\right)\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{h}}{\ell}}\\ \end{array} \]
Alternative 10
Error24.3
Cost14668
\[\begin{array}{l} t_0 := 1 - \frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)\\ t_1 := \sqrt{\frac{1}{\ell \cdot h}}\\ t_2 := {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot t_0\\ \mathbf{if}\;h \leq -3.9 \cdot 10^{+214}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;h \leq -2 \cdot 10^{-310}:\\ \;\;\;\;\left(t_1 \cdot \left(-d\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(\frac{D \cdot M}{d}\right)}^{2} \cdot 0.125\right)\right)\\ \mathbf{elif}\;h \leq 3.2 \cdot 10^{+177}:\\ \;\;\;\;\left(t_1 \cdot d\right) \cdot t_0\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 11
Error24.3
Cost14668
\[\begin{array}{l} t_0 := 1 - \frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)\\ t_1 := \sqrt{\frac{1}{\ell \cdot h}}\\ t_2 := {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5}\\ \mathbf{if}\;h \leq -1.5 \cdot 10^{+215}:\\ \;\;\;\;t_2 \cdot t_0\\ \mathbf{elif}\;h \leq -2 \cdot 10^{-310}:\\ \;\;\;\;\left(t_1 \cdot \left(-d\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(\frac{D \cdot M}{d}\right)}^{2} \cdot 0.125\right)\right)\\ \mathbf{elif}\;h \leq 3.4 \cdot 10^{+177}:\\ \;\;\;\;\left(t_1 \cdot d\right) \cdot t_0\\ \mathbf{else}:\\ \;\;\;\;t_2 \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(\frac{M}{\frac{d}{D}}\right)}^{2} \cdot 0.125\right)\right)\\ \end{array} \]
Alternative 12
Error22.7
Cost14668
\[\begin{array}{l} t_0 := \sqrt{\frac{1}{\ell \cdot h}}\\ t_1 := {\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\\ t_2 := {\left(\frac{d}{h} \cdot \frac{d}{\ell}\right)}^{0.5} \cdot \left(1 - \frac{h}{\frac{\ell}{t_1}}\right)\\ \mathbf{if}\;h \leq -7 \cdot 10^{+168}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;h \leq -2 \cdot 10^{-310}:\\ \;\;\;\;\left(t_0 \cdot \left(-d\right)\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(\frac{D \cdot M}{d}\right)}^{2} \cdot 0.125\right)\right)\\ \mathbf{elif}\;h \leq 3.2 \cdot 10^{+130}:\\ \;\;\;\;\left(t_0 \cdot d\right) \cdot \left(1 - \frac{h}{\ell} \cdot t_1\right)\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 13
Error25.5
Cost14536
\[\begin{array}{l} t_0 := 1 - \frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)\\ \mathbf{if}\;h \leq -6 \cdot 10^{-309}:\\ \;\;\;\;d \cdot \left(\sqrt{\frac{\frac{1}{h}}{\ell}} \cdot \left({\left(\frac{D}{\frac{d}{M}}\right)}^{2} \cdot \left(0.125 \cdot \frac{h}{\ell}\right) + -1\right)\right)\\ \mathbf{elif}\;h \leq 2 \cdot 10^{+217}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot d\right) \cdot t_0\\ \mathbf{else}:\\ \;\;\;\;{\left(d \cdot \frac{\frac{d}{\ell}}{h}\right)}^{0.5} \cdot t_0\\ \end{array} \]
Alternative 14
Error25.3
Cost14472
\[\begin{array}{l} \mathbf{if}\;\ell \leq -7.6 \cdot 10^{-230}:\\ \;\;\;\;d \cdot \left(\sqrt{\frac{\frac{1}{h}}{\ell}} \cdot \left({\left(\frac{D}{\frac{d}{M}}\right)}^{2} \cdot \left(0.125 \cdot \frac{h}{\ell}\right) + -1\right)\right)\\ \mathbf{elif}\;\ell \leq 5.5 \cdot 10^{-119}:\\ \;\;\;\;\sqrt{\frac{\frac{0.5}{h}}{\ell} \cdot 2} \cdot d\\ \mathbf{else}:\\ \;\;\;\;\left(\sqrt{\frac{1}{\ell \cdot h}} \cdot d\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left({\left(D \cdot \frac{M}{d}\right)}^{2} \cdot 0.125\right)\right)\\ \end{array} \]
Alternative 15
Error26.3
Cost14340
\[\begin{array}{l} \mathbf{if}\;\ell \leq -8.6 \cdot 10^{-229}:\\ \;\;\;\;d \cdot \left(\sqrt{\frac{\frac{1}{h}}{\ell}} \cdot \left({\left(\frac{D}{\frac{d}{M}}\right)}^{2} \cdot \left(0.125 \cdot \frac{h}{\ell}\right) + -1\right)\right)\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \end{array} \]
Alternative 16
Error27.4
Cost7044
\[\begin{array}{l} \mathbf{if}\;\ell \leq -7.6 \cdot 10^{-230}:\\ \;\;\;\;d \cdot \left(-\sqrt{\frac{1}{h \cdot \ell}}\right)\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \end{array} \]
Alternative 17
Error27.2
Cost7044
\[\begin{array}{l} \mathbf{if}\;\ell \leq -7.6 \cdot 10^{-230}:\\ \;\;\;\;\sqrt{\frac{\frac{1}{h}}{\ell}} \cdot \left(-d\right)\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \end{array} \]
Alternative 18
Error43.6
Cost6848
\[d \cdot \sqrt{\frac{\frac{1}{h}}{\ell}} \]
Alternative 19
Error43.6
Cost6848
\[d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}} \]

Error

Reproduce?

herbie shell --seed 2023075 
(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)))))