
(FPCore (c0 w h D d M) :precision binary64 (let* ((t_0 (/ (* c0 (* d d)) (* (* w h) (* D D))))) (* (/ c0 (* 2.0 w)) (+ t_0 (sqrt (- (* t_0 t_0) (* M M)))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (c0 * (d * d)) / ((w * h) * (D * D));
return (c0 / (2.0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (M * M))));
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
t_0 = (c0 * (d_1 * d_1)) / ((w * h) * (d * d))
code = (c0 / (2.0d0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (m * m))))
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (c0 * (d * d)) / ((w * h) * (D * D));
return (c0 / (2.0 * w)) * (t_0 + Math.sqrt(((t_0 * t_0) - (M * M))));
}
def code(c0, w, h, D, d, M): t_0 = (c0 * (d * d)) / ((w * h) * (D * D)) return (c0 / (2.0 * w)) * (t_0 + math.sqrt(((t_0 * t_0) - (M * M))))
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(c0 * Float64(d * d)) / Float64(Float64(w * h) * Float64(D * D))) return Float64(Float64(c0 / Float64(2.0 * w)) * Float64(t_0 + sqrt(Float64(Float64(t_0 * t_0) - Float64(M * M))))) end
function tmp = code(c0, w, h, D, d, M) t_0 = (c0 * (d * d)) / ((w * h) * (D * D)); tmp = (c0 / (2.0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (M * M)))); end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(c0 * N[(d * d), $MachinePrecision]), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] * N[(D * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(N[(c0 / N[(2.0 * w), $MachinePrecision]), $MachinePrecision] * N[(t$95$0 + N[Sqrt[N[(N[(t$95$0 * t$95$0), $MachinePrecision] - N[(M * M), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}\\
\frac{c0}{2 \cdot w} \cdot \left(t\_0 + \sqrt{t\_0 \cdot t\_0 - M \cdot M}\right)
\end{array}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 12 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (c0 w h D d M) :precision binary64 (let* ((t_0 (/ (* c0 (* d d)) (* (* w h) (* D D))))) (* (/ c0 (* 2.0 w)) (+ t_0 (sqrt (- (* t_0 t_0) (* M M)))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (c0 * (d * d)) / ((w * h) * (D * D));
return (c0 / (2.0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (M * M))));
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
t_0 = (c0 * (d_1 * d_1)) / ((w * h) * (d * d))
code = (c0 / (2.0d0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (m * m))))
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (c0 * (d * d)) / ((w * h) * (D * D));
return (c0 / (2.0 * w)) * (t_0 + Math.sqrt(((t_0 * t_0) - (M * M))));
}
def code(c0, w, h, D, d, M): t_0 = (c0 * (d * d)) / ((w * h) * (D * D)) return (c0 / (2.0 * w)) * (t_0 + math.sqrt(((t_0 * t_0) - (M * M))))
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(c0 * Float64(d * d)) / Float64(Float64(w * h) * Float64(D * D))) return Float64(Float64(c0 / Float64(2.0 * w)) * Float64(t_0 + sqrt(Float64(Float64(t_0 * t_0) - Float64(M * M))))) end
function tmp = code(c0, w, h, D, d, M) t_0 = (c0 * (d * d)) / ((w * h) * (D * D)); tmp = (c0 / (2.0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (M * M)))); end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(c0 * N[(d * d), $MachinePrecision]), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] * N[(D * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(N[(c0 / N[(2.0 * w), $MachinePrecision]), $MachinePrecision] * N[(t$95$0 + N[Sqrt[N[(N[(t$95$0 * t$95$0), $MachinePrecision] - N[(M * M), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}\\
\frac{c0}{2 \cdot w} \cdot \left(t\_0 + \sqrt{t\_0 \cdot t\_0 - M \cdot M}\right)
\end{array}
\end{array}
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (* c0 (* d d)) (* (* w h) (* D D)))))
(if (<=
(* (/ c0 (* 2.0 w)) (+ t_0 (sqrt (- (* t_0 t_0) (* M M)))))
INFINITY)
(/ (/ (* d (/ c0 (* w h))) D) (* w (/ D (* c0 d))))
(/ (* (/ h d) (* -0.25 (* (* M (* D M)) (- 0.0 D)))) d))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (c0 * (d * d)) / ((w * h) * (D * D));
double tmp;
if (((c0 / (2.0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (M * M))))) <= ((double) INFINITY)) {
tmp = ((d * (c0 / (w * h))) / D) / (w * (D / (c0 * d)));
} else {
tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d;
}
return tmp;
}
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = (c0 * (d * d)) / ((w * h) * (D * D));
double tmp;
if (((c0 / (2.0 * w)) * (t_0 + Math.sqrt(((t_0 * t_0) - (M * M))))) <= Double.POSITIVE_INFINITY) {
tmp = ((d * (c0 / (w * h))) / D) / (w * (D / (c0 * d)));
} else {
tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d;
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = (c0 * (d * d)) / ((w * h) * (D * D)) tmp = 0 if ((c0 / (2.0 * w)) * (t_0 + math.sqrt(((t_0 * t_0) - (M * M))))) <= math.inf: tmp = ((d * (c0 / (w * h))) / D) / (w * (D / (c0 * d))) else: tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(c0 * Float64(d * d)) / Float64(Float64(w * h) * Float64(D * D))) tmp = 0.0 if (Float64(Float64(c0 / Float64(2.0 * w)) * Float64(t_0 + sqrt(Float64(Float64(t_0 * t_0) - Float64(M * M))))) <= Inf) tmp = Float64(Float64(Float64(d * Float64(c0 / Float64(w * h))) / D) / Float64(w * Float64(D / Float64(c0 * d)))); else tmp = Float64(Float64(Float64(h / d) * Float64(-0.25 * Float64(Float64(M * Float64(D * M)) * Float64(0.0 - D)))) / d); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = (c0 * (d * d)) / ((w * h) * (D * D)); tmp = 0.0; if (((c0 / (2.0 * w)) * (t_0 + sqrt(((t_0 * t_0) - (M * M))))) <= Inf) tmp = ((d * (c0 / (w * h))) / D) / (w * (D / (c0 * d))); else tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d; end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(c0 * N[(d * d), $MachinePrecision]), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] * N[(D * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(c0 / N[(2.0 * w), $MachinePrecision]), $MachinePrecision] * N[(t$95$0 + N[Sqrt[N[(N[(t$95$0 * t$95$0), $MachinePrecision] - N[(M * M), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[(N[(N[(d * N[(c0 / N[(w * h), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / D), $MachinePrecision] / N[(w * N[(D / N[(c0 * d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(h / d), $MachinePrecision] * N[(-0.25 * N[(N[(M * N[(D * M), $MachinePrecision]), $MachinePrecision] * N[(0.0 - D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{c0 \cdot \left(d \cdot d\right)}{\left(w \cdot h\right) \cdot \left(D \cdot D\right)}\\
\mathbf{if}\;\frac{c0}{2 \cdot w} \cdot \left(t\_0 + \sqrt{t\_0 \cdot t\_0 - M \cdot M}\right) \leq \infty:\\
\;\;\;\;\frac{\frac{d \cdot \frac{c0}{w \cdot h}}{D}}{w \cdot \frac{D}{c0 \cdot d}}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{h}{d} \cdot \left(-0.25 \cdot \left(\left(M \cdot \left(D \cdot M\right)\right) \cdot \left(0 - D\right)\right)\right)}{d}\\
\end{array}
\end{array}
if (*.f64 (/.f64 c0 (*.f64 #s(literal 2 binary64) w)) (+.f64 (/.f64 (*.f64 c0 (*.f64 d d)) (*.f64 (*.f64 w h) (*.f64 D D))) (sqrt.f64 (-.f64 (*.f64 (/.f64 (*.f64 c0 (*.f64 d d)) (*.f64 (*.f64 w h) (*.f64 D D))) (/.f64 (*.f64 c0 (*.f64 d d)) (*.f64 (*.f64 w h) (*.f64 D D)))) (*.f64 M M))))) < +inf.0Initial program 69.8%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6453.5%
Simplified53.5%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6472.9%
Applied egg-rr72.9%
associate-/r*N/A
div-invN/A
*-commutativeN/A
times-fracN/A
associate-*r/N/A
*-lowering-*.f64N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6479.0%
Applied egg-rr79.0%
clear-numN/A
associate-*r/N/A
frac-timesN/A
*-lft-identityN/A
/-lowering-/.f64N/A
un-div-invN/A
/-lowering-/.f64N/A
div-invN/A
clear-numN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6480.3%
Applied egg-rr80.3%
if +inf.0 < (*.f64 (/.f64 c0 (*.f64 #s(literal 2 binary64) w)) (+.f64 (/.f64 (*.f64 c0 (*.f64 d d)) (*.f64 (*.f64 w h) (*.f64 D D))) (sqrt.f64 (-.f64 (*.f64 (/.f64 (*.f64 c0 (*.f64 d d)) (*.f64 (*.f64 w h) (*.f64 D D))) (/.f64 (*.f64 c0 (*.f64 d d)) (*.f64 (*.f64 w h) (*.f64 D D)))) (*.f64 M M))))) Initial program 0.0%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified16.4%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6453.2%
Simplified53.2%
associate-/r*N/A
frac-2negN/A
/-lowering-/.f64N/A
Applied egg-rr62.1%
Final simplification67.4%
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d))
(t_1 (/ (* c0 d) D)))
(if (<= w -1.6e+117)
(/ (* (/ h d) (* -0.25 (* (* M (* D M)) (- 0.0 D)))) d)
(if (<= w -1.7e+44)
(* t_1 (/ (* c0 d) (* w (* (* w h) D))))
(if (<= w -6.8e-130)
t_0
(if (<= w -1.26e-228)
(* t_1 (* (/ d (* w h)) (/ (/ c0 D) w)))
(if (<= w 9e-190)
t_0
(if (<= w 3.9e+126)
(* t_1 (/ (/ (/ d D) w) (/ (* w h) c0)))
(* (/ h d) (/ (* M (* 0.25 (* D (* D M)))) d))))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double tmp;
if (w <= -1.6e+117) {
tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d;
} else if (w <= -1.7e+44) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -6.8e-130) {
tmp = t_0;
} else if (w <= -1.26e-228) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 9e-190) {
tmp = t_0;
} else if (w <= 3.9e+126) {
tmp = t_1 * (((d / D) / w) / ((w * h) / c0));
} else {
tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d);
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
t_1 = (c0 * d_1) / d
if (w <= (-1.6d+117)) then
tmp = ((h / d_1) * ((-0.25d0) * ((m * (d * m)) * (0.0d0 - d)))) / d_1
else if (w <= (-1.7d+44)) then
tmp = t_1 * ((c0 * d_1) / (w * ((w * h) * d)))
else if (w <= (-6.8d-130)) then
tmp = t_0
else if (w <= (-1.26d-228)) then
tmp = t_1 * ((d_1 / (w * h)) * ((c0 / d) / w))
else if (w <= 9d-190) then
tmp = t_0
else if (w <= 3.9d+126) then
tmp = t_1 * (((d_1 / d) / w) / ((w * h) / c0))
else
tmp = (h / d_1) * ((m * (0.25d0 * (d * (d * m)))) / d_1)
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double tmp;
if (w <= -1.6e+117) {
tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d;
} else if (w <= -1.7e+44) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -6.8e-130) {
tmp = t_0;
} else if (w <= -1.26e-228) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 9e-190) {
tmp = t_0;
} else if (w <= 3.9e+126) {
tmp = t_1 * (((d / D) / w) / ((w * h) / c0));
} else {
tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d);
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d t_1 = (c0 * d) / D tmp = 0 if w <= -1.6e+117: tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d elif w <= -1.7e+44: tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))) elif w <= -6.8e-130: tmp = t_0 elif w <= -1.26e-228: tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)) elif w <= 9e-190: tmp = t_0 elif w <= 3.9e+126: tmp = t_1 * (((d / D) / w) / ((w * h) / c0)) else: tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d) return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d) t_1 = Float64(Float64(c0 * d) / D) tmp = 0.0 if (w <= -1.6e+117) tmp = Float64(Float64(Float64(h / d) * Float64(-0.25 * Float64(Float64(M * Float64(D * M)) * Float64(0.0 - D)))) / d); elseif (w <= -1.7e+44) tmp = Float64(t_1 * Float64(Float64(c0 * d) / Float64(w * Float64(Float64(w * h) * D)))); elseif (w <= -6.8e-130) tmp = t_0; elseif (w <= -1.26e-228) tmp = Float64(t_1 * Float64(Float64(d / Float64(w * h)) * Float64(Float64(c0 / D) / w))); elseif (w <= 9e-190) tmp = t_0; elseif (w <= 3.9e+126) tmp = Float64(t_1 * Float64(Float64(Float64(d / D) / w) / Float64(Float64(w * h) / c0))); else tmp = Float64(Float64(h / d) * Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d)); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; t_1 = (c0 * d) / D; tmp = 0.0; if (w <= -1.6e+117) tmp = ((h / d) * (-0.25 * ((M * (D * M)) * (0.0 - D)))) / d; elseif (w <= -1.7e+44) tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))); elseif (w <= -6.8e-130) tmp = t_0; elseif (w <= -1.26e-228) tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)); elseif (w <= 9e-190) tmp = t_0; elseif (w <= 3.9e+126) tmp = t_1 * (((d / D) / w) / ((w * h) / c0)); else tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d); end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]}, Block[{t$95$1 = N[(N[(c0 * d), $MachinePrecision] / D), $MachinePrecision]}, If[LessEqual[w, -1.6e+117], N[(N[(N[(h / d), $MachinePrecision] * N[(-0.25 * N[(N[(M * N[(D * M), $MachinePrecision]), $MachinePrecision] * N[(0.0 - D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision], If[LessEqual[w, -1.7e+44], N[(t$95$1 * N[(N[(c0 * d), $MachinePrecision] / N[(w * N[(N[(w * h), $MachinePrecision] * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -6.8e-130], t$95$0, If[LessEqual[w, -1.26e-228], N[(t$95$1 * N[(N[(d / N[(w * h), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 / D), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, 9e-190], t$95$0, If[LessEqual[w, 3.9e+126], N[(t$95$1 * N[(N[(N[(d / D), $MachinePrecision] / w), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] / c0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(h / d), $MachinePrecision] * N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
t_1 := \frac{c0 \cdot d}{D}\\
\mathbf{if}\;w \leq -1.6 \cdot 10^{+117}:\\
\;\;\;\;\frac{\frac{h}{d} \cdot \left(-0.25 \cdot \left(\left(M \cdot \left(D \cdot M\right)\right) \cdot \left(0 - D\right)\right)\right)}{d}\\
\mathbf{elif}\;w \leq -1.7 \cdot 10^{+44}:\\
\;\;\;\;t\_1 \cdot \frac{c0 \cdot d}{w \cdot \left(\left(w \cdot h\right) \cdot D\right)}\\
\mathbf{elif}\;w \leq -6.8 \cdot 10^{-130}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq -1.26 \cdot 10^{-228}:\\
\;\;\;\;t\_1 \cdot \left(\frac{d}{w \cdot h} \cdot \frac{\frac{c0}{D}}{w}\right)\\
\mathbf{elif}\;w \leq 9 \cdot 10^{-190}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq 3.9 \cdot 10^{+126}:\\
\;\;\;\;t\_1 \cdot \frac{\frac{\frac{d}{D}}{w}}{\frac{w \cdot h}{c0}}\\
\mathbf{else}:\\
\;\;\;\;\frac{h}{d} \cdot \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\end{array}
\end{array}
if w < -1.60000000000000002e117Initial program 3.7%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified13.8%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.1%
Simplified57.1%
associate-/r*N/A
frac-2negN/A
/-lowering-/.f64N/A
Applied egg-rr70.3%
if -1.60000000000000002e117 < w < -1.7e44Initial program 44.2%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.6%
Simplified38.6%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6475.4%
Applied egg-rr75.4%
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6479.9%
Applied egg-rr79.9%
if -1.7e44 < w < -6.8000000000000001e-130 or -1.25999999999999997e-228 < w < 9.00000000000000042e-190Initial program 15.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6444.0%
Simplified44.0%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified62.0%
if -6.8000000000000001e-130 < w < -1.25999999999999997e-228Initial program 52.5%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.2%
Simplified52.2%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6469.3%
Applied egg-rr69.3%
associate-/r*N/A
associate-/l*N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6476.6%
Applied egg-rr76.6%
if 9.00000000000000042e-190 < w < 3.89999999999999993e126Initial program 21.1%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6426.0%
Simplified26.0%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6449.6%
Applied egg-rr49.6%
associate-/r*N/A
div-invN/A
*-commutativeN/A
times-fracN/A
associate-*r/N/A
*-lowering-*.f64N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6452.8%
Applied egg-rr52.8%
associate-*l/N/A
/-lowering-/.f64N/A
associate-*r/N/A
div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6452.9%
Applied egg-rr52.9%
if 3.89999999999999993e126 < w Initial program 13.1%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified29.7%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6467.2%
Simplified67.2%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6468.2%
Applied egg-rr68.2%
Final simplification64.3%
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d))
(t_1 (/ (* c0 d) D))
(t_2 (/ (* M (* 0.25 (* D (* D M)))) d)))
(if (<= w -1.4e+117)
(* h (/ t_2 d))
(if (<= w -7.7e+43)
(* t_1 (/ (* c0 d) (* w (* (* w h) D))))
(if (<= w -1e-130)
t_0
(if (<= w -3e-229)
(* t_1 (* (/ d (* w h)) (/ (/ c0 D) w)))
(if (<= w 2.5e-189)
t_0
(if (<= w 3.2e+125)
(* t_1 (/ (/ (/ d D) w) (/ (* w h) c0)))
(* (/ h d) t_2)))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -1.4e+117) {
tmp = h * (t_2 / d);
} else if (w <= -7.7e+43) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -1e-130) {
tmp = t_0;
} else if (w <= -3e-229) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 2.5e-189) {
tmp = t_0;
} else if (w <= 3.2e+125) {
tmp = t_1 * (((d / D) / w) / ((w * h) / c0));
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
t_1 = (c0 * d_1) / d
t_2 = (m * (0.25d0 * (d * (d * m)))) / d_1
if (w <= (-1.4d+117)) then
tmp = h * (t_2 / d_1)
else if (w <= (-7.7d+43)) then
tmp = t_1 * ((c0 * d_1) / (w * ((w * h) * d)))
else if (w <= (-1d-130)) then
tmp = t_0
else if (w <= (-3d-229)) then
tmp = t_1 * ((d_1 / (w * h)) * ((c0 / d) / w))
else if (w <= 2.5d-189) then
tmp = t_0
else if (w <= 3.2d+125) then
tmp = t_1 * (((d_1 / d) / w) / ((w * h) / c0))
else
tmp = (h / d_1) * t_2
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -1.4e+117) {
tmp = h * (t_2 / d);
} else if (w <= -7.7e+43) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -1e-130) {
tmp = t_0;
} else if (w <= -3e-229) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 2.5e-189) {
tmp = t_0;
} else if (w <= 3.2e+125) {
tmp = t_1 * (((d / D) / w) / ((w * h) / c0));
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d t_1 = (c0 * d) / D t_2 = (M * (0.25 * (D * (D * M)))) / d tmp = 0 if w <= -1.4e+117: tmp = h * (t_2 / d) elif w <= -7.7e+43: tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))) elif w <= -1e-130: tmp = t_0 elif w <= -3e-229: tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)) elif w <= 2.5e-189: tmp = t_0 elif w <= 3.2e+125: tmp = t_1 * (((d / D) / w) / ((w * h) / c0)) else: tmp = (h / d) * t_2 return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d) t_1 = Float64(Float64(c0 * d) / D) t_2 = Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d) tmp = 0.0 if (w <= -1.4e+117) tmp = Float64(h * Float64(t_2 / d)); elseif (w <= -7.7e+43) tmp = Float64(t_1 * Float64(Float64(c0 * d) / Float64(w * Float64(Float64(w * h) * D)))); elseif (w <= -1e-130) tmp = t_0; elseif (w <= -3e-229) tmp = Float64(t_1 * Float64(Float64(d / Float64(w * h)) * Float64(Float64(c0 / D) / w))); elseif (w <= 2.5e-189) tmp = t_0; elseif (w <= 3.2e+125) tmp = Float64(t_1 * Float64(Float64(Float64(d / D) / w) / Float64(Float64(w * h) / c0))); else tmp = Float64(Float64(h / d) * t_2); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; t_1 = (c0 * d) / D; t_2 = (M * (0.25 * (D * (D * M)))) / d; tmp = 0.0; if (w <= -1.4e+117) tmp = h * (t_2 / d); elseif (w <= -7.7e+43) tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))); elseif (w <= -1e-130) tmp = t_0; elseif (w <= -3e-229) tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)); elseif (w <= 2.5e-189) tmp = t_0; elseif (w <= 3.2e+125) tmp = t_1 * (((d / D) / w) / ((w * h) / c0)); else tmp = (h / d) * t_2; end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]}, Block[{t$95$1 = N[(N[(c0 * d), $MachinePrecision] / D), $MachinePrecision]}, Block[{t$95$2 = N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]}, If[LessEqual[w, -1.4e+117], N[(h * N[(t$95$2 / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -7.7e+43], N[(t$95$1 * N[(N[(c0 * d), $MachinePrecision] / N[(w * N[(N[(w * h), $MachinePrecision] * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -1e-130], t$95$0, If[LessEqual[w, -3e-229], N[(t$95$1 * N[(N[(d / N[(w * h), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 / D), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, 2.5e-189], t$95$0, If[LessEqual[w, 3.2e+125], N[(t$95$1 * N[(N[(N[(d / D), $MachinePrecision] / w), $MachinePrecision] / N[(N[(w * h), $MachinePrecision] / c0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(h / d), $MachinePrecision] * t$95$2), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
t_1 := \frac{c0 \cdot d}{D}\\
t_2 := \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{if}\;w \leq -1.4 \cdot 10^{+117}:\\
\;\;\;\;h \cdot \frac{t\_2}{d}\\
\mathbf{elif}\;w \leq -7.7 \cdot 10^{+43}:\\
\;\;\;\;t\_1 \cdot \frac{c0 \cdot d}{w \cdot \left(\left(w \cdot h\right) \cdot D\right)}\\
\mathbf{elif}\;w \leq -1 \cdot 10^{-130}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq -3 \cdot 10^{-229}:\\
\;\;\;\;t\_1 \cdot \left(\frac{d}{w \cdot h} \cdot \frac{\frac{c0}{D}}{w}\right)\\
\mathbf{elif}\;w \leq 2.5 \cdot 10^{-189}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq 3.2 \cdot 10^{+125}:\\
\;\;\;\;t\_1 \cdot \frac{\frac{\frac{d}{D}}{w}}{\frac{w \cdot h}{c0}}\\
\mathbf{else}:\\
\;\;\;\;\frac{h}{d} \cdot t\_2\\
\end{array}
\end{array}
if w < -1.39999999999999999e117Initial program 3.7%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified13.8%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.1%
Simplified57.1%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6467.4%
Applied egg-rr67.4%
if -1.39999999999999999e117 < w < -7.6999999999999996e43Initial program 44.2%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.6%
Simplified38.6%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6475.4%
Applied egg-rr75.4%
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6479.9%
Applied egg-rr79.9%
if -7.6999999999999996e43 < w < -1.0000000000000001e-130 or -3.00000000000000002e-229 < w < 2.4999999999999999e-189Initial program 15.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6444.0%
Simplified44.0%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified62.0%
if -1.0000000000000001e-130 < w < -3.00000000000000002e-229Initial program 52.5%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.2%
Simplified52.2%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6469.3%
Applied egg-rr69.3%
associate-/r*N/A
associate-/l*N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6476.6%
Applied egg-rr76.6%
if 2.4999999999999999e-189 < w < 3.19999999999999983e125Initial program 21.1%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6426.0%
Simplified26.0%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6449.6%
Applied egg-rr49.6%
associate-/r*N/A
div-invN/A
*-commutativeN/A
times-fracN/A
associate-*r/N/A
*-lowering-*.f64N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6452.8%
Applied egg-rr52.8%
associate-*l/N/A
/-lowering-/.f64N/A
associate-*r/N/A
div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6452.9%
Applied egg-rr52.9%
if 3.19999999999999983e125 < w Initial program 13.1%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified29.7%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6467.2%
Simplified67.2%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6468.2%
Applied egg-rr68.2%
Final simplification63.9%
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d))
(t_1 (/ (* c0 d) D))
(t_2 (/ (* M (* 0.25 (* D (* D M)))) d)))
(if (<= w -2.6e+117)
(* h (/ t_2 d))
(if (<= w -1.7e+44)
(* t_1 (/ (* c0 d) (* w (* (* w h) D))))
(if (<= w -5.6e-131)
t_0
(if (<= w -2e-228)
(* t_1 (* (/ d (* w h)) (/ (/ c0 D) w)))
(if (<= w 8.5e-189)
t_0
(if (<= w 1e+127)
(* t_1 (/ (/ (* c0 (/ d D)) (* w h)) w))
(* (/ h d) t_2)))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -2.6e+117) {
tmp = h * (t_2 / d);
} else if (w <= -1.7e+44) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -5.6e-131) {
tmp = t_0;
} else if (w <= -2e-228) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 8.5e-189) {
tmp = t_0;
} else if (w <= 1e+127) {
tmp = t_1 * (((c0 * (d / D)) / (w * h)) / w);
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
t_1 = (c0 * d_1) / d
t_2 = (m * (0.25d0 * (d * (d * m)))) / d_1
if (w <= (-2.6d+117)) then
tmp = h * (t_2 / d_1)
else if (w <= (-1.7d+44)) then
tmp = t_1 * ((c0 * d_1) / (w * ((w * h) * d)))
else if (w <= (-5.6d-131)) then
tmp = t_0
else if (w <= (-2d-228)) then
tmp = t_1 * ((d_1 / (w * h)) * ((c0 / d) / w))
else if (w <= 8.5d-189) then
tmp = t_0
else if (w <= 1d+127) then
tmp = t_1 * (((c0 * (d_1 / d)) / (w * h)) / w)
else
tmp = (h / d_1) * t_2
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -2.6e+117) {
tmp = h * (t_2 / d);
} else if (w <= -1.7e+44) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -5.6e-131) {
tmp = t_0;
} else if (w <= -2e-228) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 8.5e-189) {
tmp = t_0;
} else if (w <= 1e+127) {
tmp = t_1 * (((c0 * (d / D)) / (w * h)) / w);
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d t_1 = (c0 * d) / D t_2 = (M * (0.25 * (D * (D * M)))) / d tmp = 0 if w <= -2.6e+117: tmp = h * (t_2 / d) elif w <= -1.7e+44: tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))) elif w <= -5.6e-131: tmp = t_0 elif w <= -2e-228: tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)) elif w <= 8.5e-189: tmp = t_0 elif w <= 1e+127: tmp = t_1 * (((c0 * (d / D)) / (w * h)) / w) else: tmp = (h / d) * t_2 return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d) t_1 = Float64(Float64(c0 * d) / D) t_2 = Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d) tmp = 0.0 if (w <= -2.6e+117) tmp = Float64(h * Float64(t_2 / d)); elseif (w <= -1.7e+44) tmp = Float64(t_1 * Float64(Float64(c0 * d) / Float64(w * Float64(Float64(w * h) * D)))); elseif (w <= -5.6e-131) tmp = t_0; elseif (w <= -2e-228) tmp = Float64(t_1 * Float64(Float64(d / Float64(w * h)) * Float64(Float64(c0 / D) / w))); elseif (w <= 8.5e-189) tmp = t_0; elseif (w <= 1e+127) tmp = Float64(t_1 * Float64(Float64(Float64(c0 * Float64(d / D)) / Float64(w * h)) / w)); else tmp = Float64(Float64(h / d) * t_2); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; t_1 = (c0 * d) / D; t_2 = (M * (0.25 * (D * (D * M)))) / d; tmp = 0.0; if (w <= -2.6e+117) tmp = h * (t_2 / d); elseif (w <= -1.7e+44) tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))); elseif (w <= -5.6e-131) tmp = t_0; elseif (w <= -2e-228) tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)); elseif (w <= 8.5e-189) tmp = t_0; elseif (w <= 1e+127) tmp = t_1 * (((c0 * (d / D)) / (w * h)) / w); else tmp = (h / d) * t_2; end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]}, Block[{t$95$1 = N[(N[(c0 * d), $MachinePrecision] / D), $MachinePrecision]}, Block[{t$95$2 = N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]}, If[LessEqual[w, -2.6e+117], N[(h * N[(t$95$2 / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -1.7e+44], N[(t$95$1 * N[(N[(c0 * d), $MachinePrecision] / N[(w * N[(N[(w * h), $MachinePrecision] * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -5.6e-131], t$95$0, If[LessEqual[w, -2e-228], N[(t$95$1 * N[(N[(d / N[(w * h), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 / D), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, 8.5e-189], t$95$0, If[LessEqual[w, 1e+127], N[(t$95$1 * N[(N[(N[(c0 * N[(d / D), $MachinePrecision]), $MachinePrecision] / N[(w * h), $MachinePrecision]), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision], N[(N[(h / d), $MachinePrecision] * t$95$2), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
t_1 := \frac{c0 \cdot d}{D}\\
t_2 := \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{if}\;w \leq -2.6 \cdot 10^{+117}:\\
\;\;\;\;h \cdot \frac{t\_2}{d}\\
\mathbf{elif}\;w \leq -1.7 \cdot 10^{+44}:\\
\;\;\;\;t\_1 \cdot \frac{c0 \cdot d}{w \cdot \left(\left(w \cdot h\right) \cdot D\right)}\\
\mathbf{elif}\;w \leq -5.6 \cdot 10^{-131}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq -2 \cdot 10^{-228}:\\
\;\;\;\;t\_1 \cdot \left(\frac{d}{w \cdot h} \cdot \frac{\frac{c0}{D}}{w}\right)\\
\mathbf{elif}\;w \leq 8.5 \cdot 10^{-189}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq 10^{+127}:\\
\;\;\;\;t\_1 \cdot \frac{\frac{c0 \cdot \frac{d}{D}}{w \cdot h}}{w}\\
\mathbf{else}:\\
\;\;\;\;\frac{h}{d} \cdot t\_2\\
\end{array}
\end{array}
if w < -2.5999999999999999e117Initial program 3.7%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified13.8%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.1%
Simplified57.1%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6467.4%
Applied egg-rr67.4%
if -2.5999999999999999e117 < w < -1.7e44Initial program 44.2%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.6%
Simplified38.6%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6475.4%
Applied egg-rr75.4%
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6479.9%
Applied egg-rr79.9%
if -1.7e44 < w < -5.5999999999999999e-131 or -2.00000000000000007e-228 < w < 8.50000000000000068e-189Initial program 15.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6444.0%
Simplified44.0%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified62.0%
if -5.5999999999999999e-131 < w < -2.00000000000000007e-228Initial program 52.5%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.2%
Simplified52.2%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6469.3%
Applied egg-rr69.3%
associate-/r*N/A
associate-/l*N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6476.6%
Applied egg-rr76.6%
if 8.50000000000000068e-189 < w < 9.99999999999999955e126Initial program 21.1%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6426.0%
Simplified26.0%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6449.6%
Applied egg-rr49.6%
associate-/r*N/A
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f6451.3%
Applied egg-rr51.3%
if 9.99999999999999955e126 < w Initial program 13.1%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified29.7%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6467.2%
Simplified67.2%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6468.2%
Applied egg-rr68.2%
Final simplification63.6%
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d))
(t_1 (/ (* c0 d) D))
(t_2 (/ (* M (* 0.25 (* D (* D M)))) d)))
(if (<= w -2.1e+117)
(* h (/ t_2 d))
(if (<= w -1.48e+44)
(* t_1 (/ (* c0 d) (* w (* (* w h) D))))
(if (<= w -6.2e-132)
t_0
(if (<= w -4.1e-230)
(* t_1 (* (/ d (* w h)) (/ (/ c0 D) w)))
(if (<= w 4.1e-191)
t_0
(if (<= w 1.8e+126)
(* t_1 (/ (* c0 d) (* D (* w (* w h)))))
(* (/ h d) t_2)))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -2.1e+117) {
tmp = h * (t_2 / d);
} else if (w <= -1.48e+44) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -6.2e-132) {
tmp = t_0;
} else if (w <= -4.1e-230) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 4.1e-191) {
tmp = t_0;
} else if (w <= 1.8e+126) {
tmp = t_1 * ((c0 * d) / (D * (w * (w * h))));
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
t_1 = (c0 * d_1) / d
t_2 = (m * (0.25d0 * (d * (d * m)))) / d_1
if (w <= (-2.1d+117)) then
tmp = h * (t_2 / d_1)
else if (w <= (-1.48d+44)) then
tmp = t_1 * ((c0 * d_1) / (w * ((w * h) * d)))
else if (w <= (-6.2d-132)) then
tmp = t_0
else if (w <= (-4.1d-230)) then
tmp = t_1 * ((d_1 / (w * h)) * ((c0 / d) / w))
else if (w <= 4.1d-191) then
tmp = t_0
else if (w <= 1.8d+126) then
tmp = t_1 * ((c0 * d_1) / (d * (w * (w * h))))
else
tmp = (h / d_1) * t_2
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -2.1e+117) {
tmp = h * (t_2 / d);
} else if (w <= -1.48e+44) {
tmp = t_1 * ((c0 * d) / (w * ((w * h) * D)));
} else if (w <= -6.2e-132) {
tmp = t_0;
} else if (w <= -4.1e-230) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 4.1e-191) {
tmp = t_0;
} else if (w <= 1.8e+126) {
tmp = t_1 * ((c0 * d) / (D * (w * (w * h))));
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d t_1 = (c0 * d) / D t_2 = (M * (0.25 * (D * (D * M)))) / d tmp = 0 if w <= -2.1e+117: tmp = h * (t_2 / d) elif w <= -1.48e+44: tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))) elif w <= -6.2e-132: tmp = t_0 elif w <= -4.1e-230: tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)) elif w <= 4.1e-191: tmp = t_0 elif w <= 1.8e+126: tmp = t_1 * ((c0 * d) / (D * (w * (w * h)))) else: tmp = (h / d) * t_2 return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d) t_1 = Float64(Float64(c0 * d) / D) t_2 = Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d) tmp = 0.0 if (w <= -2.1e+117) tmp = Float64(h * Float64(t_2 / d)); elseif (w <= -1.48e+44) tmp = Float64(t_1 * Float64(Float64(c0 * d) / Float64(w * Float64(Float64(w * h) * D)))); elseif (w <= -6.2e-132) tmp = t_0; elseif (w <= -4.1e-230) tmp = Float64(t_1 * Float64(Float64(d / Float64(w * h)) * Float64(Float64(c0 / D) / w))); elseif (w <= 4.1e-191) tmp = t_0; elseif (w <= 1.8e+126) tmp = Float64(t_1 * Float64(Float64(c0 * d) / Float64(D * Float64(w * Float64(w * h))))); else tmp = Float64(Float64(h / d) * t_2); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; t_1 = (c0 * d) / D; t_2 = (M * (0.25 * (D * (D * M)))) / d; tmp = 0.0; if (w <= -2.1e+117) tmp = h * (t_2 / d); elseif (w <= -1.48e+44) tmp = t_1 * ((c0 * d) / (w * ((w * h) * D))); elseif (w <= -6.2e-132) tmp = t_0; elseif (w <= -4.1e-230) tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)); elseif (w <= 4.1e-191) tmp = t_0; elseif (w <= 1.8e+126) tmp = t_1 * ((c0 * d) / (D * (w * (w * h)))); else tmp = (h / d) * t_2; end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]}, Block[{t$95$1 = N[(N[(c0 * d), $MachinePrecision] / D), $MachinePrecision]}, Block[{t$95$2 = N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]}, If[LessEqual[w, -2.1e+117], N[(h * N[(t$95$2 / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -1.48e+44], N[(t$95$1 * N[(N[(c0 * d), $MachinePrecision] / N[(w * N[(N[(w * h), $MachinePrecision] * D), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -6.2e-132], t$95$0, If[LessEqual[w, -4.1e-230], N[(t$95$1 * N[(N[(d / N[(w * h), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 / D), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, 4.1e-191], t$95$0, If[LessEqual[w, 1.8e+126], N[(t$95$1 * N[(N[(c0 * d), $MachinePrecision] / N[(D * N[(w * N[(w * h), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(h / d), $MachinePrecision] * t$95$2), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
t_1 := \frac{c0 \cdot d}{D}\\
t_2 := \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{if}\;w \leq -2.1 \cdot 10^{+117}:\\
\;\;\;\;h \cdot \frac{t\_2}{d}\\
\mathbf{elif}\;w \leq -1.48 \cdot 10^{+44}:\\
\;\;\;\;t\_1 \cdot \frac{c0 \cdot d}{w \cdot \left(\left(w \cdot h\right) \cdot D\right)}\\
\mathbf{elif}\;w \leq -6.2 \cdot 10^{-132}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq -4.1 \cdot 10^{-230}:\\
\;\;\;\;t\_1 \cdot \left(\frac{d}{w \cdot h} \cdot \frac{\frac{c0}{D}}{w}\right)\\
\mathbf{elif}\;w \leq 4.1 \cdot 10^{-191}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq 1.8 \cdot 10^{+126}:\\
\;\;\;\;t\_1 \cdot \frac{c0 \cdot d}{D \cdot \left(w \cdot \left(w \cdot h\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{h}{d} \cdot t\_2\\
\end{array}
\end{array}
if w < -2.1000000000000001e117Initial program 3.7%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified13.8%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.1%
Simplified57.1%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6467.4%
Applied egg-rr67.4%
if -2.1000000000000001e117 < w < -1.48e44Initial program 44.2%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.6%
Simplified38.6%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6475.4%
Applied egg-rr75.4%
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6479.9%
Applied egg-rr79.9%
if -1.48e44 < w < -6.20000000000000016e-132 or -4.1000000000000002e-230 < w < 4.1000000000000002e-191Initial program 15.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6444.0%
Simplified44.0%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified62.0%
if -6.20000000000000016e-132 < w < -4.1000000000000002e-230Initial program 52.5%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.2%
Simplified52.2%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6469.3%
Applied egg-rr69.3%
associate-/r*N/A
associate-/l*N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6476.6%
Applied egg-rr76.6%
if 4.1000000000000002e-191 < w < 1.8e126Initial program 21.1%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6426.0%
Simplified26.0%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6449.6%
Applied egg-rr49.6%
if 1.8e126 < w Initial program 13.1%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified29.7%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6467.2%
Simplified67.2%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6468.2%
Applied egg-rr68.2%
Final simplification63.2%
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d))
(t_1 (/ (* c0 d) D))
(t_2 (* t_1 (/ (* c0 d) (* D (* w (* w h))))))
(t_3 (/ (* M (* 0.25 (* D (* D M)))) d)))
(if (<= w -1.18e+111)
(* h (/ t_3 d))
(if (<= w -2.15e+43)
t_2
(if (<= w -3.4e-130)
t_0
(if (<= w -3e-230)
(* t_1 (* (/ d (* w h)) (/ (/ c0 D) w)))
(if (<= w 9.8e-189)
t_0
(if (<= w 1.9e+126) t_2 (* (/ h d) t_3)))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = t_1 * ((c0 * d) / (D * (w * (w * h))));
double t_3 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -1.18e+111) {
tmp = h * (t_3 / d);
} else if (w <= -2.15e+43) {
tmp = t_2;
} else if (w <= -3.4e-130) {
tmp = t_0;
} else if (w <= -3e-230) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 9.8e-189) {
tmp = t_0;
} else if (w <= 1.9e+126) {
tmp = t_2;
} else {
tmp = (h / d) * t_3;
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_0 = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
t_1 = (c0 * d_1) / d
t_2 = t_1 * ((c0 * d_1) / (d * (w * (w * h))))
t_3 = (m * (0.25d0 * (d * (d * m)))) / d_1
if (w <= (-1.18d+111)) then
tmp = h * (t_3 / d_1)
else if (w <= (-2.15d+43)) then
tmp = t_2
else if (w <= (-3.4d-130)) then
tmp = t_0
else if (w <= (-3d-230)) then
tmp = t_1 * ((d_1 / (w * h)) * ((c0 / d) / w))
else if (w <= 9.8d-189) then
tmp = t_0
else if (w <= 1.9d+126) then
tmp = t_2
else
tmp = (h / d_1) * t_3
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = (c0 * d) / D;
double t_2 = t_1 * ((c0 * d) / (D * (w * (w * h))));
double t_3 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -1.18e+111) {
tmp = h * (t_3 / d);
} else if (w <= -2.15e+43) {
tmp = t_2;
} else if (w <= -3.4e-130) {
tmp = t_0;
} else if (w <= -3e-230) {
tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w));
} else if (w <= 9.8e-189) {
tmp = t_0;
} else if (w <= 1.9e+126) {
tmp = t_2;
} else {
tmp = (h / d) * t_3;
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d t_1 = (c0 * d) / D t_2 = t_1 * ((c0 * d) / (D * (w * (w * h)))) t_3 = (M * (0.25 * (D * (D * M)))) / d tmp = 0 if w <= -1.18e+111: tmp = h * (t_3 / d) elif w <= -2.15e+43: tmp = t_2 elif w <= -3.4e-130: tmp = t_0 elif w <= -3e-230: tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)) elif w <= 9.8e-189: tmp = t_0 elif w <= 1.9e+126: tmp = t_2 else: tmp = (h / d) * t_3 return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d) t_1 = Float64(Float64(c0 * d) / D) t_2 = Float64(t_1 * Float64(Float64(c0 * d) / Float64(D * Float64(w * Float64(w * h))))) t_3 = Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d) tmp = 0.0 if (w <= -1.18e+111) tmp = Float64(h * Float64(t_3 / d)); elseif (w <= -2.15e+43) tmp = t_2; elseif (w <= -3.4e-130) tmp = t_0; elseif (w <= -3e-230) tmp = Float64(t_1 * Float64(Float64(d / Float64(w * h)) * Float64(Float64(c0 / D) / w))); elseif (w <= 9.8e-189) tmp = t_0; elseif (w <= 1.9e+126) tmp = t_2; else tmp = Float64(Float64(h / d) * t_3); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; t_1 = (c0 * d) / D; t_2 = t_1 * ((c0 * d) / (D * (w * (w * h)))); t_3 = (M * (0.25 * (D * (D * M)))) / d; tmp = 0.0; if (w <= -1.18e+111) tmp = h * (t_3 / d); elseif (w <= -2.15e+43) tmp = t_2; elseif (w <= -3.4e-130) tmp = t_0; elseif (w <= -3e-230) tmp = t_1 * ((d / (w * h)) * ((c0 / D) / w)); elseif (w <= 9.8e-189) tmp = t_0; elseif (w <= 1.9e+126) tmp = t_2; else tmp = (h / d) * t_3; end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]}, Block[{t$95$1 = N[(N[(c0 * d), $MachinePrecision] / D), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 * N[(N[(c0 * d), $MachinePrecision] / N[(D * N[(w * N[(w * h), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]}, If[LessEqual[w, -1.18e+111], N[(h * N[(t$95$3 / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -2.15e+43], t$95$2, If[LessEqual[w, -3.4e-130], t$95$0, If[LessEqual[w, -3e-230], N[(t$95$1 * N[(N[(d / N[(w * h), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 / D), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, 9.8e-189], t$95$0, If[LessEqual[w, 1.9e+126], t$95$2, N[(N[(h / d), $MachinePrecision] * t$95$3), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
t_1 := \frac{c0 \cdot d}{D}\\
t_2 := t\_1 \cdot \frac{c0 \cdot d}{D \cdot \left(w \cdot \left(w \cdot h\right)\right)}\\
t_3 := \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{if}\;w \leq -1.18 \cdot 10^{+111}:\\
\;\;\;\;h \cdot \frac{t\_3}{d}\\
\mathbf{elif}\;w \leq -2.15 \cdot 10^{+43}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;w \leq -3.4 \cdot 10^{-130}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq -3 \cdot 10^{-230}:\\
\;\;\;\;t\_1 \cdot \left(\frac{d}{w \cdot h} \cdot \frac{\frac{c0}{D}}{w}\right)\\
\mathbf{elif}\;w \leq 9.8 \cdot 10^{-189}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq 1.9 \cdot 10^{+126}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{h}{d} \cdot t\_3\\
\end{array}
\end{array}
if w < -1.1799999999999999e111Initial program 6.3%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified12.5%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6455.1%
Simplified55.1%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6464.5%
Applied egg-rr64.5%
if -1.1799999999999999e111 < w < -2.15e43 or 9.7999999999999994e-189 < w < 1.90000000000000008e126Initial program 25.8%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6429.8%
Simplified29.8%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6456.0%
Applied egg-rr56.0%
if -2.15e43 < w < -3.40000000000000005e-130 or -3e-230 < w < 9.7999999999999994e-189Initial program 15.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6444.0%
Simplified44.0%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified62.0%
if -3.40000000000000005e-130 < w < -3e-230Initial program 52.5%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.2%
Simplified52.2%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6469.3%
Applied egg-rr69.3%
associate-/r*N/A
associate-/l*N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6476.6%
Applied egg-rr76.6%
if 1.90000000000000008e126 < w Initial program 13.1%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified29.7%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6467.2%
Simplified67.2%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6468.2%
Applied egg-rr68.2%
Final simplification62.9%
(FPCore (c0 w h D d M)
:precision binary64
(let* ((t_0 (/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d))
(t_1 (* (/ (* c0 d) D) (* (/ d (* w h)) (/ (/ c0 D) w))))
(t_2 (/ (* M (* 0.25 (* D (* D M)))) d)))
(if (<= w -3.4e+109)
(* h (/ t_2 d))
(if (<= w -2.5e+44)
t_1
(if (<= w -5e-131)
t_0
(if (<= w -8.2e-231)
t_1
(if (<= w 3.1e-189)
t_0
(if (<= w 2.45e+126) t_1 (* (/ h d) t_2)))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = ((c0 * d) / D) * ((d / (w * h)) * ((c0 / D) / w));
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -3.4e+109) {
tmp = h * (t_2 / d);
} else if (w <= -2.5e+44) {
tmp = t_1;
} else if (w <= -5e-131) {
tmp = t_0;
} else if (w <= -8.2e-231) {
tmp = t_1;
} else if (w <= 3.1e-189) {
tmp = t_0;
} else if (w <= 2.45e+126) {
tmp = t_1;
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
t_1 = ((c0 * d_1) / d) * ((d_1 / (w * h)) * ((c0 / d) / w))
t_2 = (m * (0.25d0 * (d * (d * m)))) / d_1
if (w <= (-3.4d+109)) then
tmp = h * (t_2 / d_1)
else if (w <= (-2.5d+44)) then
tmp = t_1
else if (w <= (-5d-131)) then
tmp = t_0
else if (w <= (-8.2d-231)) then
tmp = t_1
else if (w <= 3.1d-189) then
tmp = t_0
else if (w <= 2.45d+126) then
tmp = t_1
else
tmp = (h / d_1) * t_2
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
double t_1 = ((c0 * d) / D) * ((d / (w * h)) * ((c0 / D) / w));
double t_2 = (M * (0.25 * (D * (D * M)))) / d;
double tmp;
if (w <= -3.4e+109) {
tmp = h * (t_2 / d);
} else if (w <= -2.5e+44) {
tmp = t_1;
} else if (w <= -5e-131) {
tmp = t_0;
} else if (w <= -8.2e-231) {
tmp = t_1;
} else if (w <= 3.1e-189) {
tmp = t_0;
} else if (w <= 2.45e+126) {
tmp = t_1;
} else {
tmp = (h / d) * t_2;
}
return tmp;
}
def code(c0, w, h, D, d, M): t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d t_1 = ((c0 * d) / D) * ((d / (w * h)) * ((c0 / D) / w)) t_2 = (M * (0.25 * (D * (D * M)))) / d tmp = 0 if w <= -3.4e+109: tmp = h * (t_2 / d) elif w <= -2.5e+44: tmp = t_1 elif w <= -5e-131: tmp = t_0 elif w <= -8.2e-231: tmp = t_1 elif w <= 3.1e-189: tmp = t_0 elif w <= 2.45e+126: tmp = t_1 else: tmp = (h / d) * t_2 return tmp
function code(c0, w, h, D, d, M) t_0 = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d) t_1 = Float64(Float64(Float64(c0 * d) / D) * Float64(Float64(d / Float64(w * h)) * Float64(Float64(c0 / D) / w))) t_2 = Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d) tmp = 0.0 if (w <= -3.4e+109) tmp = Float64(h * Float64(t_2 / d)); elseif (w <= -2.5e+44) tmp = t_1; elseif (w <= -5e-131) tmp = t_0; elseif (w <= -8.2e-231) tmp = t_1; elseif (w <= 3.1e-189) tmp = t_0; elseif (w <= 2.45e+126) tmp = t_1; else tmp = Float64(Float64(h / d) * t_2); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) t_0 = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; t_1 = ((c0 * d) / D) * ((d / (w * h)) * ((c0 / D) / w)); t_2 = (M * (0.25 * (D * (D * M)))) / d; tmp = 0.0; if (w <= -3.4e+109) tmp = h * (t_2 / d); elseif (w <= -2.5e+44) tmp = t_1; elseif (w <= -5e-131) tmp = t_0; elseif (w <= -8.2e-231) tmp = t_1; elseif (w <= 3.1e-189) tmp = t_0; elseif (w <= 2.45e+126) tmp = t_1; else tmp = (h / d) * t_2; end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := Block[{t$95$0 = N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]}, Block[{t$95$1 = N[(N[(N[(c0 * d), $MachinePrecision] / D), $MachinePrecision] * N[(N[(d / N[(w * h), $MachinePrecision]), $MachinePrecision] * N[(N[(c0 / D), $MachinePrecision] / w), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]}, If[LessEqual[w, -3.4e+109], N[(h * N[(t$95$2 / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[w, -2.5e+44], t$95$1, If[LessEqual[w, -5e-131], t$95$0, If[LessEqual[w, -8.2e-231], t$95$1, If[LessEqual[w, 3.1e-189], t$95$0, If[LessEqual[w, 2.45e+126], t$95$1, N[(N[(h / d), $MachinePrecision] * t$95$2), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
t_1 := \frac{c0 \cdot d}{D} \cdot \left(\frac{d}{w \cdot h} \cdot \frac{\frac{c0}{D}}{w}\right)\\
t_2 := \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{if}\;w \leq -3.4 \cdot 10^{+109}:\\
\;\;\;\;h \cdot \frac{t\_2}{d}\\
\mathbf{elif}\;w \leq -2.5 \cdot 10^{+44}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;w \leq -5 \cdot 10^{-131}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq -8.2 \cdot 10^{-231}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;w \leq 3.1 \cdot 10^{-189}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;w \leq 2.45 \cdot 10^{+126}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\frac{h}{d} \cdot t\_2\\
\end{array}
\end{array}
if w < -3.40000000000000006e109Initial program 6.3%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified12.5%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6455.1%
Simplified55.1%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6464.5%
Applied egg-rr64.5%
if -3.40000000000000006e109 < w < -2.4999999999999998e44 or -5.0000000000000004e-131 < w < -8.2000000000000003e-231 or 3.1e-189 < w < 2.45e126Initial program 32.7%
Taylor expanded in c0 around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6435.6%
Simplified35.6%
unswap-sqrN/A
associate-*l*N/A
times-fracN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6459.5%
Applied egg-rr59.5%
associate-/r*N/A
associate-/l*N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6460.2%
Applied egg-rr60.2%
if -2.4999999999999998e44 < w < -5.0000000000000004e-131 or -8.2000000000000003e-231 < w < 3.1e-189Initial program 15.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6444.0%
Simplified44.0%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified62.0%
if 2.45e126 < w Initial program 13.1%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified29.7%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6467.2%
Simplified67.2%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6468.2%
Applied egg-rr68.2%
Final simplification62.5%
(FPCore (c0 w h D d M)
:precision binary64
(if (<= h -1.85e-125)
(* (/ h d) (/ (* M (* 0.25 (* D (* D M)))) d))
(if (<= h 5.2e-109)
(/ (/ (* D (* 0.25 (* D (* h (* M M))))) d) d)
(* 0.25 (* D (* D (* M (/ (/ (* h M) d) d))))))))
double code(double c0, double w, double h, double D, double d, double M) {
double tmp;
if (h <= -1.85e-125) {
tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d);
} else if (h <= 5.2e-109) {
tmp = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
} else {
tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: tmp
if (h <= (-1.85d-125)) then
tmp = (h / d_1) * ((m * (0.25d0 * (d * (d * m)))) / d_1)
else if (h <= 5.2d-109) then
tmp = ((d * (0.25d0 * (d * (h * (m * m))))) / d_1) / d_1
else
tmp = 0.25d0 * (d * (d * (m * (((h * m) / d_1) / d_1))))
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double tmp;
if (h <= -1.85e-125) {
tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d);
} else if (h <= 5.2e-109) {
tmp = ((D * (0.25 * (D * (h * (M * M))))) / d) / d;
} else {
tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
return tmp;
}
def code(c0, w, h, D, d, M): tmp = 0 if h <= -1.85e-125: tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d) elif h <= 5.2e-109: tmp = ((D * (0.25 * (D * (h * (M * M))))) / d) / d else: tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))) return tmp
function code(c0, w, h, D, d, M) tmp = 0.0 if (h <= -1.85e-125) tmp = Float64(Float64(h / d) * Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d)); elseif (h <= 5.2e-109) tmp = Float64(Float64(Float64(D * Float64(0.25 * Float64(D * Float64(h * Float64(M * M))))) / d) / d); else tmp = Float64(0.25 * Float64(D * Float64(D * Float64(M * Float64(Float64(Float64(h * M) / d) / d))))); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) tmp = 0.0; if (h <= -1.85e-125) tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d); elseif (h <= 5.2e-109) tmp = ((D * (0.25 * (D * (h * (M * M))))) / d) / d; else tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))); end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := If[LessEqual[h, -1.85e-125], N[(N[(h / d), $MachinePrecision] * N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision], If[LessEqual[h, 5.2e-109], N[(N[(N[(D * N[(0.25 * N[(D * N[(h * N[(M * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision], N[(0.25 * N[(D * N[(D * N[(M * N[(N[(N[(h * M), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;h \leq -1.85 \cdot 10^{-125}:\\
\;\;\;\;\frac{h}{d} \cdot \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{elif}\;h \leq 5.2 \cdot 10^{-109}:\\
\;\;\;\;\frac{\frac{D \cdot \left(0.25 \cdot \left(D \cdot \left(h \cdot \left(M \cdot M\right)\right)\right)\right)}{d}}{d}\\
\mathbf{else}:\\
\;\;\;\;0.25 \cdot \left(D \cdot \left(D \cdot \left(M \cdot \frac{\frac{h \cdot M}{d}}{d}\right)\right)\right)\\
\end{array}
\end{array}
if h < -1.85e-125Initial program 19.3%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified9.0%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6443.8%
Simplified43.8%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6453.0%
Applied egg-rr53.0%
if -1.85e-125 < h < 5.1999999999999997e-109Initial program 16.6%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified15.6%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6439.7%
Simplified39.7%
Taylor expanded in h around 0
associate-*r/N/A
unpow2N/A
associate-/r*N/A
/-lowering-/.f64N/A
Simplified53.5%
if 5.1999999999999997e-109 < h Initial program 26.5%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified17.0%
+-rgt-identityN/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
Applied egg-rr28.2%
Taylor expanded in c0 around 0
associate-/l*N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
associate-/l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-/r*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f6457.3%
Simplified57.3%
Final simplification54.5%
(FPCore (c0 w h D d M) :precision binary64 (if (<= h -1.42e-282) (* h (/ (/ (* M (* 0.25 (* D (* D M)))) d) d)) (* 0.25 (* D (* D (* M (/ (/ (* h M) d) d)))))))
double code(double c0, double w, double h, double D, double d, double M) {
double tmp;
if (h <= -1.42e-282) {
tmp = h * (((M * (0.25 * (D * (D * M)))) / d) / d);
} else {
tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: tmp
if (h <= (-1.42d-282)) then
tmp = h * (((m * (0.25d0 * (d * (d * m)))) / d_1) / d_1)
else
tmp = 0.25d0 * (d * (d * (m * (((h * m) / d_1) / d_1))))
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double tmp;
if (h <= -1.42e-282) {
tmp = h * (((M * (0.25 * (D * (D * M)))) / d) / d);
} else {
tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
return tmp;
}
def code(c0, w, h, D, d, M): tmp = 0 if h <= -1.42e-282: tmp = h * (((M * (0.25 * (D * (D * M)))) / d) / d) else: tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))) return tmp
function code(c0, w, h, D, d, M) tmp = 0.0 if (h <= -1.42e-282) tmp = Float64(h * Float64(Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d) / d)); else tmp = Float64(0.25 * Float64(D * Float64(D * Float64(M * Float64(Float64(Float64(h * M) / d) / d))))); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) tmp = 0.0; if (h <= -1.42e-282) tmp = h * (((M * (0.25 * (D * (D * M)))) / d) / d); else tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))); end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := If[LessEqual[h, -1.42e-282], N[(h * N[(N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision], N[(0.25 * N[(D * N[(D * N[(M * N[(N[(N[(h * M), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;h \leq -1.42 \cdot 10^{-282}:\\
\;\;\;\;h \cdot \frac{\frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}}{d}\\
\mathbf{else}:\\
\;\;\;\;0.25 \cdot \left(D \cdot \left(D \cdot \left(M \cdot \frac{\frac{h \cdot M}{d}}{d}\right)\right)\right)\\
\end{array}
\end{array}
if h < -1.42e-282Initial program 18.0%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified11.3%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6442.7%
Simplified42.7%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6450.6%
Applied egg-rr50.6%
if -1.42e-282 < h Initial program 22.6%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified16.9%
+-rgt-identityN/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
Applied egg-rr24.2%
Taylor expanded in c0 around 0
associate-/l*N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
associate-/l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-/r*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f6451.5%
Simplified51.5%
Final simplification51.1%
(FPCore (c0 w h D d M) :precision binary64 (if (<= h -8e-179) (* (/ h d) (/ (* M (* 0.25 (* D (* D M)))) d)) (* 0.25 (* D (* D (* M (/ (/ (* h M) d) d)))))))
double code(double c0, double w, double h, double D, double d, double M) {
double tmp;
if (h <= -8e-179) {
tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d);
} else {
tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
return tmp;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
real(8) :: tmp
if (h <= (-8d-179)) then
tmp = (h / d_1) * ((m * (0.25d0 * (d * (d * m)))) / d_1)
else
tmp = 0.25d0 * (d * (d * (m * (((h * m) / d_1) / d_1))))
end if
code = tmp
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
double tmp;
if (h <= -8e-179) {
tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d);
} else {
tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
return tmp;
}
def code(c0, w, h, D, d, M): tmp = 0 if h <= -8e-179: tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d) else: tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))) return tmp
function code(c0, w, h, D, d, M) tmp = 0.0 if (h <= -8e-179) tmp = Float64(Float64(h / d) * Float64(Float64(M * Float64(0.25 * Float64(D * Float64(D * M)))) / d)); else tmp = Float64(0.25 * Float64(D * Float64(D * Float64(M * Float64(Float64(Float64(h * M) / d) / d))))); end return tmp end
function tmp_2 = code(c0, w, h, D, d, M) tmp = 0.0; if (h <= -8e-179) tmp = (h / d) * ((M * (0.25 * (D * (D * M)))) / d); else tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))); end tmp_2 = tmp; end
code[c0_, w_, h_, D_, d_, M_] := If[LessEqual[h, -8e-179], N[(N[(h / d), $MachinePrecision] * N[(N[(M * N[(0.25 * N[(D * N[(D * M), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision], N[(0.25 * N[(D * N[(D * N[(M * N[(N[(N[(h * M), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;h \leq -8 \cdot 10^{-179}:\\
\;\;\;\;\frac{h}{d} \cdot \frac{M \cdot \left(0.25 \cdot \left(D \cdot \left(D \cdot M\right)\right)\right)}{d}\\
\mathbf{else}:\\
\;\;\;\;0.25 \cdot \left(D \cdot \left(D \cdot \left(M \cdot \frac{\frac{h \cdot M}{d}}{d}\right)\right)\right)\\
\end{array}
\end{array}
if h < -8.0000000000000002e-179Initial program 19.6%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified9.9%
Taylor expanded in c0 around 0
associate-*r/N/A
/-lowering-/.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6442.6%
Simplified42.6%
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
/-lowering-/.f6451.4%
Applied egg-rr51.4%
if -8.0000000000000002e-179 < h Initial program 20.8%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified16.3%
+-rgt-identityN/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
Applied egg-rr22.8%
Taylor expanded in c0 around 0
associate-/l*N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
associate-/l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-/r*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f6450.4%
Simplified50.4%
Final simplification50.7%
(FPCore (c0 w h D d M) :precision binary64 (* 0.25 (* D (* D (* M (/ (/ (* h M) d) d))))))
double code(double c0, double w, double h, double D, double d, double M) {
return 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
code = 0.25d0 * (d * (d * (m * (((h * m) / d_1) / d_1))))
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
return 0.25 * (D * (D * (M * (((h * M) / d) / d))));
}
def code(c0, w, h, D, d, M): return 0.25 * (D * (D * (M * (((h * M) / d) / d))))
function code(c0, w, h, D, d, M) return Float64(0.25 * Float64(D * Float64(D * Float64(M * Float64(Float64(Float64(h * M) / d) / d))))) end
function tmp = code(c0, w, h, D, d, M) tmp = 0.25 * (D * (D * (M * (((h * M) / d) / d)))); end
code[c0_, w_, h_, D_, d_, M_] := N[(0.25 * N[(D * N[(D * N[(M * N[(N[(N[(h * M), $MachinePrecision] / d), $MachinePrecision] / d), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
0.25 \cdot \left(D \cdot \left(D \cdot \left(M \cdot \frac{\frac{h \cdot M}{d}}{d}\right)\right)\right)
\end{array}
Initial program 20.4%
Taylor expanded in c0 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-commutativeN/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
metadata-evalN/A
metadata-evalN/A
Simplified14.2%
+-rgt-identityN/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
Applied egg-rr20.1%
Taylor expanded in c0 around 0
associate-/l*N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
associate-/l*N/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-/r*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f6447.7%
Simplified47.7%
Final simplification47.7%
(FPCore (c0 w h D d M) :precision binary64 0.0)
double code(double c0, double w, double h, double D, double d, double M) {
return 0.0;
}
real(8) function code(c0, w, h, d, d_1, m)
real(8), intent (in) :: c0
real(8), intent (in) :: w
real(8), intent (in) :: h
real(8), intent (in) :: d
real(8), intent (in) :: d_1
real(8), intent (in) :: m
code = 0.0d0
end function
public static double code(double c0, double w, double h, double D, double d, double M) {
return 0.0;
}
def code(c0, w, h, D, d, M): return 0.0
function code(c0, w, h, D, d, M) return 0.0 end
function tmp = code(c0, w, h, D, d, M) tmp = 0.0; end
code[c0_, w_, h_, D_, d_, M_] := 0.0
\begin{array}{l}
\\
0
\end{array}
Initial program 20.4%
Taylor expanded in c0 around -inf
associate-/l*N/A
distribute-lft1-inN/A
metadata-evalN/A
mul0-lftN/A
div0N/A
mul0-rgtN/A
metadata-eval36.1%
Simplified36.1%
herbie shell --seed 2024191
(FPCore (c0 w h D d M)
:name "Henrywood and Agarwal, Equation (13)"
:precision binary64
(* (/ c0 (* 2.0 w)) (+ (/ (* c0 (* d d)) (* (* w h) (* D D))) (sqrt (- (* (/ (* c0 (* d d)) (* (* w h) (* D D))) (/ (* c0 (* d d)) (* (* w h) (* D D)))) (* M M))))))