Average Error: 26.2 → 15.4
Time: 52.0s
Precision: binary64
Cost: 33928
\[\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 := 1 + {\left(\left(M \cdot \left(0.5 \cdot \frac{D}{d}\right)\right) \cdot \sqrt{\frac{h}{\ell}}\right)}^{2} \cdot -0.5\\ t_1 := \sqrt{-d}\\ \mathbf{if}\;h \leq -4.7 \cdot 10^{-14}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \frac{t_1}{\sqrt{-\ell}}\right) \cdot t_0\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;t_0 \cdot \left(\frac{t_1}{\sqrt{-h}} \cdot \sqrt{\frac{d}{\ell}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\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
         (+ 1.0 (* (pow (* (* M (* 0.5 (/ D d))) (sqrt (/ h l))) 2.0) -0.5)))
        (t_1 (sqrt (- d))))
   (if (<= h -4.7e-14)
     (* (* (sqrt (/ d h)) (/ t_1 (sqrt (- l)))) t_0)
     (if (<= h -5e-310)
       (* t_0 (* (/ t_1 (sqrt (- h))) (sqrt (/ d l))))
       (*
        (/ d (* (sqrt h) (sqrt l)))
        (+ 1.0 (* -0.5 (* h (* (/ (pow (/ M (/ d D)) 2.0) l) 0.25)))))))))
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 = 1.0 + (pow(((M * (0.5 * (D / d))) * sqrt((h / l))), 2.0) * -0.5);
	double t_1 = sqrt(-d);
	double tmp;
	if (h <= -4.7e-14) {
		tmp = (sqrt((d / h)) * (t_1 / sqrt(-l))) * t_0;
	} else if (h <= -5e-310) {
		tmp = t_0 * ((t_1 / sqrt(-h)) * sqrt((d / l)));
	} else {
		tmp = (d / (sqrt(h) * sqrt(l))) * (1.0 + (-0.5 * (h * ((pow((M / (d / D)), 2.0) / l) * 0.25))));
	}
	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) :: tmp
    t_0 = 1.0d0 + ((((m * (0.5d0 * (d_1 / d))) * sqrt((h / l))) ** 2.0d0) * (-0.5d0))
    t_1 = sqrt(-d)
    if (h <= (-4.7d-14)) then
        tmp = (sqrt((d / h)) * (t_1 / sqrt(-l))) * t_0
    else if (h <= (-5d-310)) then
        tmp = t_0 * ((t_1 / sqrt(-h)) * sqrt((d / l)))
    else
        tmp = (d / (sqrt(h) * sqrt(l))) * (1.0d0 + ((-0.5d0) * (h * ((((m / (d / d_1)) ** 2.0d0) / l) * 0.25d0))))
    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 = 1.0 + (Math.pow(((M * (0.5 * (D / d))) * Math.sqrt((h / l))), 2.0) * -0.5);
	double t_1 = Math.sqrt(-d);
	double tmp;
	if (h <= -4.7e-14) {
		tmp = (Math.sqrt((d / h)) * (t_1 / Math.sqrt(-l))) * t_0;
	} else if (h <= -5e-310) {
		tmp = t_0 * ((t_1 / Math.sqrt(-h)) * Math.sqrt((d / l)));
	} else {
		tmp = (d / (Math.sqrt(h) * Math.sqrt(l))) * (1.0 + (-0.5 * (h * ((Math.pow((M / (d / D)), 2.0) / l) * 0.25))));
	}
	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 = 1.0 + (math.pow(((M * (0.5 * (D / d))) * math.sqrt((h / l))), 2.0) * -0.5)
	t_1 = math.sqrt(-d)
	tmp = 0
	if h <= -4.7e-14:
		tmp = (math.sqrt((d / h)) * (t_1 / math.sqrt(-l))) * t_0
	elif h <= -5e-310:
		tmp = t_0 * ((t_1 / math.sqrt(-h)) * math.sqrt((d / l)))
	else:
		tmp = (d / (math.sqrt(h) * math.sqrt(l))) * (1.0 + (-0.5 * (h * ((math.pow((M / (d / D)), 2.0) / l) * 0.25))))
	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(1.0 + Float64((Float64(Float64(M * Float64(0.5 * Float64(D / d))) * sqrt(Float64(h / l))) ^ 2.0) * -0.5))
	t_1 = sqrt(Float64(-d))
	tmp = 0.0
	if (h <= -4.7e-14)
		tmp = Float64(Float64(sqrt(Float64(d / h)) * Float64(t_1 / sqrt(Float64(-l)))) * t_0);
	elseif (h <= -5e-310)
		tmp = Float64(t_0 * Float64(Float64(t_1 / sqrt(Float64(-h))) * sqrt(Float64(d / l))));
	else
		tmp = Float64(Float64(d / Float64(sqrt(h) * sqrt(l))) * Float64(1.0 + Float64(-0.5 * Float64(h * Float64(Float64((Float64(M / Float64(d / D)) ^ 2.0) / l) * 0.25)))));
	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 = 1.0 + ((((M * (0.5 * (D / d))) * sqrt((h / l))) ^ 2.0) * -0.5);
	t_1 = sqrt(-d);
	tmp = 0.0;
	if (h <= -4.7e-14)
		tmp = (sqrt((d / h)) * (t_1 / sqrt(-l))) * t_0;
	elseif (h <= -5e-310)
		tmp = t_0 * ((t_1 / sqrt(-h)) * sqrt((d / l)));
	else
		tmp = (d / (sqrt(h) * sqrt(l))) * (1.0 + (-0.5 * (h * ((((M / (d / D)) ^ 2.0) / l) * 0.25))));
	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[(1.0 + N[(N[Power[N[(N[(M * N[(0.5 * N[(D / d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(h / l), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[Sqrt[(-d)], $MachinePrecision]}, If[LessEqual[h, -4.7e-14], N[(N[(N[Sqrt[N[(d / h), $MachinePrecision]], $MachinePrecision] * N[(t$95$1 / N[Sqrt[(-l)], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * t$95$0), $MachinePrecision], If[LessEqual[h, -5e-310], N[(t$95$0 * N[(N[(t$95$1 / N[Sqrt[(-h)], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(d / l), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(d / N[(N[Sqrt[h], $MachinePrecision] * N[Sqrt[l], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(-0.5 * N[(h * N[(N[(N[Power[N[(M / N[(d / D), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] / l), $MachinePrecision] * 0.25), $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 := 1 + {\left(\left(M \cdot \left(0.5 \cdot \frac{D}{d}\right)\right) \cdot \sqrt{\frac{h}{\ell}}\right)}^{2} \cdot -0.5\\
t_1 := \sqrt{-d}\\
\mathbf{if}\;h \leq -4.7 \cdot 10^{-14}:\\
\;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \frac{t_1}{\sqrt{-\ell}}\right) \cdot t_0\\

\mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\
\;\;\;\;t_0 \cdot \left(\frac{t_1}{\sqrt{-h}} \cdot \sqrt{\frac{d}{\ell}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\


\end{array}

Error

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Split input into 3 regimes
  2. if h < -4.7000000000000002e-14

    1. Initial program 24.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. Simplified24.7

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

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

      metadata-eval [=>]24.8

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

      unpow1/2 [=>]24.8

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

      metadata-eval [=>]24.8

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

      unpow1/2 [=>]24.8

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

      associate-*l* [=>]24.8

      \[ \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \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 [=>]24.8

      \[ \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \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) \]

      times-frac [=>]24.7

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

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

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

    if -4.7000000000000002e-14 < h < -4.999999999999985e-310

    1. Initial program 27.6

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

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

      [Start]27.6

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

      metadata-eval [=>]27.6

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

      unpow1/2 [=>]27.6

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

      metadata-eval [=>]27.6

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

      unpow1/2 [=>]27.6

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

      associate-*l* [=>]27.7

      \[ \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \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 [=>]27.7

      \[ \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \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) \]

      times-frac [=>]28.5

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

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

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

    if -4.999999999999985e-310 < h

    1. Initial program 26.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. Simplified26.7

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

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

      metadata-eval [=>]26.3

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

      unpow1/2 [=>]26.3

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

      metadata-eval [=>]26.3

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

      unpow1/2 [=>]26.3

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

      associate-*l* [=>]26.3

      \[ \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \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 [=>]26.3

      \[ \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \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) \]

      times-frac [=>]26.7

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

      \[\leadsto \left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 - 0.5 \cdot \color{blue}{\left(e^{\mathsf{log1p}\left({\left(M \cdot \left(0.5 \cdot \frac{D}{d}\right)\right)}^{2} \cdot \frac{h}{\ell}\right)} - 1\right)}\right) \]
    4. Simplified25.9

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

      [Start]27.2

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

      expm1-def [=>]27.2

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

      expm1-log1p [=>]26.7

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

      associate-*r/ [=>]26.2

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

      associate-*l/ [<=]25.9

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

      *-commutative [=>]25.9

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

      *-commutative [=>]25.9

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

      associate-*r* [=>]25.9

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

      \[\leadsto \color{blue}{\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} + \frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(\left(-0.5 \cdot h\right) \cdot \frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\frac{\ell}{0.25}}\right)} \]
    6. Simplified13.5

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

      [Start]13.4

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

      *-rgt-identity [<=]13.4

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

      distribute-lft-in [<=]13.4

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

      associate-*l* [=>]13.5

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

      associate-/r/ [=>]13.5

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

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

Alternatives

Alternative 1
Error16.7
Cost33796
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{-h}\\ t_2 := \sqrt{\frac{d}{\ell}}\\ t_3 := \sqrt{-\ell}\\ \mathbf{if}\;h \leq -1.32 \cdot 10^{+140}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot t_2\right) \cdot \left(1 - 0.5 \cdot {\left(\left(M \cdot \left(0.5 \cdot \frac{D}{d}\right)\right) \cdot \frac{t_1}{t_3}\right)}^{2}\right)\\ \mathbf{elif}\;h \leq -9.5 \cdot 10^{-17}:\\ \;\;\;\;\left(\frac{t_0}{t_3} \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left(0.5 \cdot {\left(\frac{M \cdot D}{d \cdot 2}\right)}^{2}\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{t_1} \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 2
Error17.1
Cost33796
\[\begin{array}{l} t_0 := \sqrt{-d}\\ \mathbf{if}\;h \leq -9.5 \cdot 10^{-17}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \frac{t_0}{\sqrt{-\ell}}\right) \cdot \left(1 + {\left(\left(M \cdot \left(0.5 \cdot \frac{D}{d}\right)\right) \cdot \sqrt{\frac{h}{\ell}}\right)}^{2} \cdot -0.5\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 3
Error17.0
Cost27724
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \frac{t_0}{\sqrt{-\ell}}\\ t_2 := \sqrt{\frac{d}{h}}\\ t_3 := \sqrt{\frac{d}{\ell}}\\ \mathbf{if}\;h \leq -1.65 \cdot 10^{+141}:\\ \;\;\;\;\left(t_2 \cdot t_3\right) \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -3.1 \cdot 10^{+90}:\\ \;\;\;\;\left(t_2 \cdot t_1\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -4.3 \cdot 10^{-17}:\\ \;\;\;\;\left(t_1 \cdot {\left(\frac{d}{h}\right)}^{0.5}\right) \cdot \left(1 - \frac{h}{\ell} \cdot \left(0.5 \cdot {\left(\frac{M \cdot D}{d \cdot 2}\right)}^{2}\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_3\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 4
Error18.1
Cost27664
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{\frac{d}{h}}\\ t_2 := \sqrt{\frac{d}{\ell}}\\ t_3 := t_1 \cdot t_2\\ \mathbf{if}\;h \leq -3.3 \cdot 10^{+141}:\\ \;\;\;\;t_3 \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -9.2 \cdot 10^{+30}:\\ \;\;\;\;\left(t_1 \cdot \frac{t_0}{\sqrt{-\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -1.05 \cdot 10^{-91}:\\ \;\;\;\;\frac{D}{\frac{\frac{d}{M}}{M \cdot D}} \cdot \left(\sqrt{\frac{h}{{\ell}^{3}}} \cdot 0.125\right) - d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;h \leq -2.3 \cdot 10^{-130}:\\ \;\;\;\;\left(1 + {\left(\left(M \cdot \left(0.5 \cdot \frac{D}{d}\right)\right) \cdot \sqrt{\frac{h}{\ell}}\right)}^{2} \cdot -0.5\right) \cdot t_3\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 5
Error17.0
Cost27660
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{\frac{d}{h}}\\ t_2 := t_1 \cdot \frac{t_0}{\sqrt{-\ell}}\\ t_3 := \sqrt{\frac{d}{\ell}}\\ \mathbf{if}\;h \leq -1 \cdot 10^{+141}:\\ \;\;\;\;\left(t_1 \cdot t_3\right) \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -1 \cdot 10^{+100}:\\ \;\;\;\;t_2 \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -4.7 \cdot 10^{-17}:\\ \;\;\;\;t_2 \cdot \left(1 + -0.5 \cdot \left(\frac{h}{\ell} \cdot {\left(\frac{D}{d} \cdot \frac{M}{2}\right)}^{2}\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_3\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 6
Error17.0
Cost27660
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{-\ell}\\ t_2 := \sqrt{\frac{d}{h}}\\ t_3 := \sqrt{\frac{d}{\ell}}\\ \mathbf{if}\;h \leq -3.6 \cdot 10^{+142}:\\ \;\;\;\;\left(t_2 \cdot t_3\right) \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -4.8 \cdot 10^{+89}:\\ \;\;\;\;\left(t_2 \cdot \frac{t_0}{t_1}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -6.2 \cdot 10^{-17}:\\ \;\;\;\;\frac{t_2 \cdot \left(1 + \frac{h}{\ell} \cdot \left(-0.5 \cdot {\left(\frac{0.5}{d} \cdot \left(M \cdot D\right)\right)}^{2}\right)\right)}{\frac{t_1}{t_0}}\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_3\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 7
Error19.4
Cost21844
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{\frac{d}{h}}\\ t_2 := \sqrt{\frac{d}{\ell}}\\ t_3 := t_1 \cdot t_2\\ \mathbf{if}\;h \leq -1.3 \cdot 10^{+143}:\\ \;\;\;\;t_3 \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -9 \cdot 10^{+31}:\\ \;\;\;\;\left(t_1 \cdot \frac{t_0}{\sqrt{-\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -1.05 \cdot 10^{-91}:\\ \;\;\;\;\frac{D}{\frac{\frac{d}{M}}{M \cdot D}} \cdot \left(\sqrt{\frac{h}{{\ell}^{3}}} \cdot 0.125\right) - d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;h \leq -6.5 \cdot 10^{-122}:\\ \;\;\;\;t_3 \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{M} \cdot \left(d \cdot \frac{\ell}{h \cdot M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \left(0.25 \cdot \frac{D}{\frac{\frac{d \cdot d}{\frac{M \cdot M}{\frac{\ell}{h}}}}{D}}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 8
Error19.2
Cost21844
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{\frac{d}{h}}\\ t_2 := \sqrt{\frac{d}{\ell}}\\ t_3 := t_1 \cdot t_2\\ \mathbf{if}\;h \leq -1.36 \cdot 10^{+141}:\\ \;\;\;\;t_3 \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -9.2 \cdot 10^{+30}:\\ \;\;\;\;\left(t_1 \cdot \frac{t_0}{\sqrt{-\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -2.4 \cdot 10^{-93}:\\ \;\;\;\;\frac{D}{\frac{\frac{d}{M}}{M \cdot D}} \cdot \left(\sqrt{\frac{h}{{\ell}^{3}}} \cdot 0.125\right) - d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;h \leq -1.45 \cdot 10^{-122}:\\ \;\;\;\;t_3 \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{M} \cdot \left(d \cdot \frac{\ell}{h \cdot M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_2\right) \cdot \left(1 + 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(\left(\frac{h}{\ell} \cdot \left(M \cdot M\right)\right) \cdot -0.25\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 9
Error18.2
Cost21844
\[\begin{array}{l} t_0 := \sqrt{-d}\\ t_1 := \sqrt{\frac{d}{h}}\\ t_2 := \sqrt{\frac{d}{\ell}}\\ t_3 := t_1 \cdot t_2\\ \mathbf{if}\;h \leq -5.5 \cdot 10^{+140}:\\ \;\;\;\;t_3 \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -1.55 \cdot 10^{+30}:\\ \;\;\;\;\left(t_1 \cdot \frac{t_0}{\sqrt{-\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -1.65 \cdot 10^{-88}:\\ \;\;\;\;\frac{D}{\frac{\frac{d}{M}}{M \cdot D}} \cdot \left(\sqrt{\frac{h}{{\ell}^{3}}} \cdot 0.125\right) - d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;h \leq -5.7 \cdot 10^{-120}:\\ \;\;\;\;t_3 \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{M} \cdot \left(d \cdot \frac{\ell}{h \cdot M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(\frac{t_0}{\sqrt{-h}} \cdot t_2\right) \cdot \left(1 - 0.5 \cdot \left(\left(\frac{D}{d} \cdot \frac{D}{d}\right) \cdot \left(0.25 \cdot \frac{h \cdot M}{\frac{\ell}{M}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 10
Error18.4
Cost21448
\[\begin{array}{l} t_0 := \sqrt{\frac{d}{h}}\\ t_1 := \sqrt{\frac{d}{\ell}}\\ \mathbf{if}\;h \leq -3.9 \cdot 10^{+141}:\\ \;\;\;\;\left(t_0 \cdot t_1\right) \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -3.5 \cdot 10^{+31}:\\ \;\;\;\;\left(t_0 \cdot \frac{\sqrt{-d}}{\sqrt{-\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{h} \cdot \left(\frac{\ell}{M} \cdot \frac{d}{M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;h \leq -3.4 \cdot 10^{-32}:\\ \;\;\;\;\left(1 + -0.5 \cdot \left(\frac{h}{\ell} \cdot {\left(\frac{D}{d} \cdot \frac{M}{2}\right)}^{2}\right)\right) \cdot \left(t_1 \cdot \frac{1}{\sqrt{\frac{h}{d}}}\right)\\ \mathbf{elif}\;h \leq -9.8 \cdot 10^{-150}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\frac{\sqrt{\frac{d}{\frac{-\ell}{d}}}}{\sqrt{-h}}\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 11
Error19.1
Cost21264
\[\begin{array}{l} t_0 := \sqrt{\frac{d}{h}}\\ \mathbf{if}\;d \leq -9.5 \cdot 10^{+60}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{elif}\;d \leq -1.05 \cdot 10^{-113}:\\ \;\;\;\;\left(t_0 \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{\ell}{h \cdot M} \cdot \frac{d \cdot d}{M}}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;d \leq -3.2 \cdot 10^{-297}:\\ \;\;\;\;\left(\sqrt{\frac{h}{{\ell}^{3}}} \cdot 0.125\right) \cdot \left(\left(M \cdot M\right) \cdot \frac{D}{\frac{d}{D}}\right) - d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;d \leq 1.8 \cdot 10^{-293}:\\ \;\;\;\;\frac{t_0 \cdot \left(1 + \frac{h}{\ell} \cdot \left(-0.5 \cdot {\left(\frac{0.5}{d} \cdot \left(M \cdot D\right)\right)}^{2}\right)\right)}{\sqrt{\frac{\ell}{d}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 12
Error19.1
Cost21136
\[\begin{array}{l} \mathbf{if}\;d \leq -9.5 \cdot 10^{+60}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{elif}\;d \leq -5.5 \cdot 10^{-113}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{\ell}{h \cdot M} \cdot \frac{d \cdot d}{M}}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;d \leq -4.4 \cdot 10^{-297}:\\ \;\;\;\;\left(\sqrt{\frac{h}{{\ell}^{3}}} \cdot 0.125\right) \cdot \left(\left(M \cdot M\right) \cdot \frac{D}{\frac{d}{D}}\right) - d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{elif}\;d \leq 1.8 \cdot 10^{-293}:\\ \;\;\;\;\sqrt{\frac{d}{h} \cdot \frac{d}{\ell}} \cdot \mathsf{fma}\left({\left(\frac{0.5 \cdot \left(M \cdot D\right)}{d}\right)}^{2}, \frac{h \cdot -0.5}{\ell}, 1\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 13
Error18.9
Cost21004
\[\begin{array}{l} t_0 := \left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;d \leq -9.5 \cdot 10^{+60}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;d \leq -3.3 \cdot 10^{-106}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{\ell}{h \cdot M} \cdot \frac{d \cdot d}{M}}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;d \leq 1.8 \cdot 10^{-293}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 14
Error17.5
Cost20872
\[\begin{array}{l} \mathbf{if}\;h \leq -9.2 \cdot 10^{-17}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 + -0.5 \cdot \left(h \cdot \frac{{\left(0.5 \cdot \left(M \cdot \frac{D}{d}\right)\right)}^{2}}{\ell}\right)\right)\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}} \cdot \left(1 + -0.5 \cdot \left(h \cdot \left(\frac{{\left(\frac{M}{\frac{d}{D}}\right)}^{2}}{\ell} \cdot 0.25\right)\right)\right)\\ \end{array} \]
Alternative 15
Error22.0
Cost14920
\[\begin{array}{l} t_0 := \left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;d \leq -9.5 \cdot 10^{+60}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;d \leq -1.06 \cdot 10^{-111}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{d}{M} \cdot \left(d \cdot \frac{\ell}{h \cdot M}\right)}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;d \leq 3.7 \cdot 10^{-308}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}}\\ \end{array} \]
Alternative 16
Error22.0
Cost14920
\[\begin{array}{l} t_0 := \left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{if}\;d \leq -9.5 \cdot 10^{+60}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;d \leq -7.2 \cdot 10^{-108}:\\ \;\;\;\;\left(\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\right) \cdot \left(1 + 0.5 \cdot \left(\frac{D}{\frac{\frac{\ell}{h \cdot M} \cdot \frac{d \cdot d}{M}}{D}} \cdot -0.25\right)\right)\\ \mathbf{elif}\;d \leq 1.4 \cdot 10^{-307}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}}\\ \end{array} \]
Alternative 17
Error23.2
Cost13384
\[\begin{array}{l} \mathbf{if}\;h \leq -1.95 \cdot 10^{+154}:\\ \;\;\;\;\sqrt{\frac{d}{h} \cdot \frac{d}{\ell}}\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}}\\ \end{array} \]
Alternative 18
Error22.7
Cost13384
\[\begin{array}{l} \mathbf{if}\;h \leq -9 \cdot 10^{+151}:\\ \;\;\;\;\sqrt{\frac{d}{h}} \cdot \sqrt{\frac{d}{\ell}}\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h} \cdot \sqrt{\ell}}\\ \end{array} \]
Alternative 19
Error27.5
Cost7176
\[\begin{array}{l} \mathbf{if}\;h \leq -4.2 \cdot 10^{+154}:\\ \;\;\;\;\sqrt{\frac{d}{h} \cdot \frac{d}{\ell}}\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(-d\right) \cdot \sqrt{\frac{1}{h \cdot \ell}}\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \end{array} \]
Alternative 20
Error27.4
Cost7176
\[\begin{array}{l} t_0 := \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \mathbf{if}\;h \leq -2.6 \cdot 10^{+159}:\\ \;\;\;\;\sqrt{\frac{d}{h} \cdot \frac{d}{\ell}}\\ \mathbf{elif}\;h \leq -5 \cdot 10^{-310}:\\ \;\;\;\;\left(-d\right) \cdot t_0\\ \mathbf{else}:\\ \;\;\;\;d \cdot t_0\\ \end{array} \]
Alternative 21
Error33.1
Cost6980
\[\begin{array}{l} \mathbf{if}\;h \leq -1.8 \cdot 10^{-307}:\\ \;\;\;\;\sqrt{\frac{d}{h} \cdot \frac{d}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{d}{\sqrt{h \cdot \ell}}\\ \end{array} \]
Alternative 22
Error33.1
Cost6980
\[\begin{array}{l} \mathbf{if}\;h \leq -1.8 \cdot 10^{-307}:\\ \;\;\;\;\sqrt{\frac{d}{h} \cdot \frac{d}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;d \cdot \sqrt{\frac{\frac{1}{\ell}}{h}}\\ \end{array} \]
Alternative 23
Error44.1
Cost6720
\[\frac{d}{\sqrt{h \cdot \ell}} \]

Error

Reproduce

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