
(FPCore (x y z t a) :precision binary64 (+ x (* (- y z) (/ (- t x) (- a z)))))
double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + ((y - z) * ((t - x) / (a - z)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
def code(x, y, z, t, a): return x + ((y - z) * ((t - x) / (a - z)))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) end
function tmp = code(x, y, z, t, a) tmp = x + ((y - z) * ((t - x) / (a - z))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \frac{t - x}{a - z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 21 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (* (- y z) (/ (- t x) (- a z)))))
double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + ((y - z) * ((t - x) / (a - z)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
def code(x, y, z, t, a): return x + ((y - z) * ((t - x) / (a - z)))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) end
function tmp = code(x, y, z, t, a) tmp = x + ((y - z) * ((t - x) / (a - z))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \frac{t - x}{a - z}
\end{array}
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (cbrt (- a z)))
(t_2 (/ (- t x) (- a z)))
(t_3 (+ x (* (- y z) t_2)))
(t_4 (* x (- (+ 1.0 (/ z (- a z))) (/ y (- a z))))))
(if (<= t_3 (- INFINITY))
(+ x (/ (/ (* (- y z) (- t x)) (pow t_1 2.0)) t_1))
(if (<= t_3 -5e+58)
(+ t_4 (/ 1.0 (/ (/ (- a z) t) (- y z))))
(if (<= t_3 -1e-254)
(+ t_4 (/ (* (- y z) t) (- a z)))
(if (<= t_3 0.0)
(+ t (* (- y a) (/ (- x t) z)))
(fma (- y z) t_2 x)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = cbrt((a - z));
double t_2 = (t - x) / (a - z);
double t_3 = x + ((y - z) * t_2);
double t_4 = x * ((1.0 + (z / (a - z))) - (y / (a - z)));
double tmp;
if (t_3 <= -((double) INFINITY)) {
tmp = x + ((((y - z) * (t - x)) / pow(t_1, 2.0)) / t_1);
} else if (t_3 <= -5e+58) {
tmp = t_4 + (1.0 / (((a - z) / t) / (y - z)));
} else if (t_3 <= -1e-254) {
tmp = t_4 + (((y - z) * t) / (a - z));
} else if (t_3 <= 0.0) {
tmp = t + ((y - a) * ((x - t) / z));
} else {
tmp = fma((y - z), t_2, x);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = cbrt(Float64(a - z)) t_2 = Float64(Float64(t - x) / Float64(a - z)) t_3 = Float64(x + Float64(Float64(y - z) * t_2)) t_4 = Float64(x * Float64(Float64(1.0 + Float64(z / Float64(a - z))) - Float64(y / Float64(a - z)))) tmp = 0.0 if (t_3 <= Float64(-Inf)) tmp = Float64(x + Float64(Float64(Float64(Float64(y - z) * Float64(t - x)) / (t_1 ^ 2.0)) / t_1)); elseif (t_3 <= -5e+58) tmp = Float64(t_4 + Float64(1.0 / Float64(Float64(Float64(a - z) / t) / Float64(y - z)))); elseif (t_3 <= -1e-254) tmp = Float64(t_4 + Float64(Float64(Float64(y - z) * t) / Float64(a - z))); elseif (t_3 <= 0.0) tmp = Float64(t + Float64(Float64(y - a) * Float64(Float64(x - t) / z))); else tmp = fma(Float64(y - z), t_2, x); end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[Power[N[(a - z), $MachinePrecision], 1/3], $MachinePrecision]}, Block[{t$95$2 = N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x + N[(N[(y - z), $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(x * N[(N[(1.0 + N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$3, (-Infinity)], N[(x + N[(N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[Power[t$95$1, 2.0], $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, -5e+58], N[(t$95$4 + N[(1.0 / N[(N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, -1e-254], N[(t$95$4 + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 0.0], N[(t + N[(N[(y - a), $MachinePrecision] * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * t$95$2 + x), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \sqrt[3]{a - z}\\
t_2 := \frac{t - x}{a - z}\\
t_3 := x + \left(y - z\right) \cdot t_2\\
t_4 := x \cdot \left(\left(1 + \frac{z}{a - z}\right) - \frac{y}{a - z}\right)\\
\mathbf{if}\;t_3 \leq -\infty:\\
\;\;\;\;x + \frac{\frac{\left(y - z\right) \cdot \left(t - x\right)}{{t_1}^{2}}}{t_1}\\
\mathbf{elif}\;t_3 \leq -5 \cdot 10^{+58}:\\
\;\;\;\;t_4 + \frac{1}{\frac{\frac{a - z}{t}}{y - z}}\\
\mathbf{elif}\;t_3 \leq -1 \cdot 10^{-254}:\\
\;\;\;\;t_4 + \frac{\left(y - z\right) \cdot t}{a - z}\\
\mathbf{elif}\;t_3 \leq 0:\\
\;\;\;\;t + \left(y - a\right) \cdot \frac{x - t}{z}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y - z, t_2, x\right)\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0Initial program 70.1%
associate-*r/99.9%
add-cube-cbrt99.4%
associate-/r*99.3%
pow299.3%
Applied egg-rr99.3%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.99999999999999986e58Initial program 98.4%
Taylor expanded in x around -inf 67.3%
clear-num67.3%
inv-pow67.3%
Applied egg-rr67.3%
unpow-167.3%
associate-/r*98.6%
Simplified98.6%
if -4.99999999999999986e58 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -9.9999999999999991e-255Initial program 84.0%
Taylor expanded in x around -inf 99.8%
if -9.9999999999999991e-255 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.7%
clear-num3.6%
associate-/r/3.6%
Applied egg-rr3.6%
Taylor expanded in z around inf 87.7%
associate--l+87.7%
associate-*r/87.7%
associate-*r/87.7%
div-sub87.7%
distribute-lft-out--87.7%
associate-*r/87.7%
mul-1-neg87.7%
unsub-neg87.7%
distribute-rgt-out--87.9%
Simplified87.9%
*-commutative87.9%
*-un-lft-identity87.9%
times-frac99.8%
Applied egg-rr99.8%
if 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 94.3%
+-commutative94.3%
fma-def94.3%
Simplified94.3%
Final simplification97.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (- (+ 1.0 (/ z (- a z))) (/ y (- a z)))))
(t_2 (+ t_1 (/ (* (- y z) t) (- a z))))
(t_3 (/ (- t x) (- a z)))
(t_4 (+ x (* (- y z) t_3))))
(if (<= t_4 (- INFINITY))
t_2
(if (<= t_4 -5e+58)
(+ t_1 (/ 1.0 (/ (/ (- a z) t) (- y z))))
(if (<= t_4 -1e-254)
t_2
(if (<= t_4 0.0)
(+ t (* (- y a) (/ (- x t) z)))
(fma (- y z) t_3 x)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * ((1.0 + (z / (a - z))) - (y / (a - z)));
double t_2 = t_1 + (((y - z) * t) / (a - z));
double t_3 = (t - x) / (a - z);
double t_4 = x + ((y - z) * t_3);
double tmp;
if (t_4 <= -((double) INFINITY)) {
tmp = t_2;
} else if (t_4 <= -5e+58) {
tmp = t_1 + (1.0 / (((a - z) / t) / (y - z)));
} else if (t_4 <= -1e-254) {
tmp = t_2;
} else if (t_4 <= 0.0) {
tmp = t + ((y - a) * ((x - t) / z));
} else {
tmp = fma((y - z), t_3, x);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(x * Float64(Float64(1.0 + Float64(z / Float64(a - z))) - Float64(y / Float64(a - z)))) t_2 = Float64(t_1 + Float64(Float64(Float64(y - z) * t) / Float64(a - z))) t_3 = Float64(Float64(t - x) / Float64(a - z)) t_4 = Float64(x + Float64(Float64(y - z) * t_3)) tmp = 0.0 if (t_4 <= Float64(-Inf)) tmp = t_2; elseif (t_4 <= -5e+58) tmp = Float64(t_1 + Float64(1.0 / Float64(Float64(Float64(a - z) / t) / Float64(y - z)))); elseif (t_4 <= -1e-254) tmp = t_2; elseif (t_4 <= 0.0) tmp = Float64(t + Float64(Float64(y - a) * Float64(Float64(x - t) / z))); else tmp = fma(Float64(y - z), t_3, x); end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(N[(1.0 + N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(x + N[(N[(y - z), $MachinePrecision] * t$95$3), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$4, (-Infinity)], t$95$2, If[LessEqual[t$95$4, -5e+58], N[(t$95$1 + N[(1.0 / N[(N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, -1e-254], t$95$2, If[LessEqual[t$95$4, 0.0], N[(t + N[(N[(y - a), $MachinePrecision] * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * t$95$3 + x), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(\left(1 + \frac{z}{a - z}\right) - \frac{y}{a - z}\right)\\
t_2 := t_1 + \frac{\left(y - z\right) \cdot t}{a - z}\\
t_3 := \frac{t - x}{a - z}\\
t_4 := x + \left(y - z\right) \cdot t_3\\
\mathbf{if}\;t_4 \leq -\infty:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_4 \leq -5 \cdot 10^{+58}:\\
\;\;\;\;t_1 + \frac{1}{\frac{\frac{a - z}{t}}{y - z}}\\
\mathbf{elif}\;t_4 \leq -1 \cdot 10^{-254}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_4 \leq 0:\\
\;\;\;\;t + \left(y - a\right) \cdot \frac{x - t}{z}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y - z, t_3, x\right)\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0 or -4.99999999999999986e58 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -9.9999999999999991e-255Initial program 78.4%
Taylor expanded in x around -inf 96.6%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.99999999999999986e58Initial program 98.4%
Taylor expanded in x around -inf 67.3%
clear-num67.3%
inv-pow67.3%
Applied egg-rr67.3%
unpow-167.3%
associate-/r*98.6%
Simplified98.6%
if -9.9999999999999991e-255 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.7%
clear-num3.6%
associate-/r/3.6%
Applied egg-rr3.6%
Taylor expanded in z around inf 87.7%
associate--l+87.7%
associate-*r/87.7%
associate-*r/87.7%
div-sub87.7%
distribute-lft-out--87.7%
associate-*r/87.7%
mul-1-neg87.7%
unsub-neg87.7%
distribute-rgt-out--87.9%
Simplified87.9%
*-commutative87.9%
*-un-lft-identity87.9%
times-frac99.8%
Applied egg-rr99.8%
if 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 94.3%
+-commutative94.3%
fma-def94.3%
Simplified94.3%
Final simplification96.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1
(+
(* x (- (+ 1.0 (/ z (- a z))) (/ y (- a z))))
(/ (* (- y z) t) (- a z))))
(t_2 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (<= t_2 (- INFINITY))
t_1
(if (<= t_2 -5e+58)
t_2
(if (<= t_2 -1e-254)
t_1
(if (<= t_2 0.0) (+ t (* (- y a) (/ (- x t) z))) t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (x * ((1.0 + (z / (a - z))) - (y / (a - z)))) + (((y - z) * t) / (a - z));
double t_2 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = t_1;
} else if (t_2 <= -5e+58) {
tmp = t_2;
} else if (t_2 <= -1e-254) {
tmp = t_1;
} else if (t_2 <= 0.0) {
tmp = t + ((y - a) * ((x - t) / z));
} else {
tmp = t_2;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (x * ((1.0 + (z / (a - z))) - (y / (a - z)))) + (((y - z) * t) / (a - z));
double t_2 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_2 <= -Double.POSITIVE_INFINITY) {
tmp = t_1;
} else if (t_2 <= -5e+58) {
tmp = t_2;
} else if (t_2 <= -1e-254) {
tmp = t_1;
} else if (t_2 <= 0.0) {
tmp = t + ((y - a) * ((x - t) / z));
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (x * ((1.0 + (z / (a - z))) - (y / (a - z)))) + (((y - z) * t) / (a - z)) t_2 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if t_2 <= -math.inf: tmp = t_1 elif t_2 <= -5e+58: tmp = t_2 elif t_2 <= -1e-254: tmp = t_1 elif t_2 <= 0.0: tmp = t + ((y - a) * ((x - t) / z)) else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(x * Float64(Float64(1.0 + Float64(z / Float64(a - z))) - Float64(y / Float64(a - z)))) + Float64(Float64(Float64(y - z) * t) / Float64(a - z))) t_2 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = t_1; elseif (t_2 <= -5e+58) tmp = t_2; elseif (t_2 <= -1e-254) tmp = t_1; elseif (t_2 <= 0.0) tmp = Float64(t + Float64(Float64(y - a) * Float64(Float64(x - t) / z))); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (x * ((1.0 + (z / (a - z))) - (y / (a - z)))) + (((y - z) * t) / (a - z)); t_2 = x + ((y - z) * ((t - x) / (a - z))); tmp = 0.0; if (t_2 <= -Inf) tmp = t_1; elseif (t_2 <= -5e+58) tmp = t_2; elseif (t_2 <= -1e-254) tmp = t_1; elseif (t_2 <= 0.0) tmp = t + ((y - a) * ((x - t) / z)); else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(x * N[(N[(1.0 + N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, -5e+58], t$95$2, If[LessEqual[t$95$2, -1e-254], t$95$1, If[LessEqual[t$95$2, 0.0], N[(t + N[(N[(y - a), $MachinePrecision] * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(\left(1 + \frac{z}{a - z}\right) - \frac{y}{a - z}\right) + \frac{\left(y - z\right) \cdot t}{a - z}\\
t_2 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{if}\;t_2 \leq -\infty:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t_2 \leq -5 \cdot 10^{+58}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_2 \leq -1 \cdot 10^{-254}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t_2 \leq 0:\\
\;\;\;\;t + \left(y - a\right) \cdot \frac{x - t}{z}\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0 or -4.99999999999999986e58 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -9.9999999999999991e-255Initial program 78.4%
Taylor expanded in x around -inf 96.6%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.99999999999999986e58 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 95.7%
if -9.9999999999999991e-255 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.7%
clear-num3.6%
associate-/r/3.6%
Applied egg-rr3.6%
Taylor expanded in z around inf 87.7%
associate--l+87.7%
associate-*r/87.7%
associate-*r/87.7%
div-sub87.7%
distribute-lft-out--87.7%
associate-*r/87.7%
mul-1-neg87.7%
unsub-neg87.7%
distribute-rgt-out--87.9%
Simplified87.9%
*-commutative87.9%
*-un-lft-identity87.9%
times-frac99.8%
Applied egg-rr99.8%
Final simplification96.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (- (+ 1.0 (/ z (- a z))) (/ y (- a z)))))
(t_2 (+ t_1 (/ (* (- y z) t) (- a z))))
(t_3 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (<= t_3 (- INFINITY))
t_2
(if (<= t_3 -5e+58)
(+ t_1 (/ 1.0 (/ (/ (- a z) t) (- y z))))
(if (<= t_3 -1e-254)
t_2
(if (<= t_3 0.0) (+ t (* (- y a) (/ (- x t) z))) t_3))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * ((1.0 + (z / (a - z))) - (y / (a - z)));
double t_2 = t_1 + (((y - z) * t) / (a - z));
double t_3 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_3 <= -((double) INFINITY)) {
tmp = t_2;
} else if (t_3 <= -5e+58) {
tmp = t_1 + (1.0 / (((a - z) / t) / (y - z)));
} else if (t_3 <= -1e-254) {
tmp = t_2;
} else if (t_3 <= 0.0) {
tmp = t + ((y - a) * ((x - t) / z));
} else {
tmp = t_3;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * ((1.0 + (z / (a - z))) - (y / (a - z)));
double t_2 = t_1 + (((y - z) * t) / (a - z));
double t_3 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_3 <= -Double.POSITIVE_INFINITY) {
tmp = t_2;
} else if (t_3 <= -5e+58) {
tmp = t_1 + (1.0 / (((a - z) / t) / (y - z)));
} else if (t_3 <= -1e-254) {
tmp = t_2;
} else if (t_3 <= 0.0) {
tmp = t + ((y - a) * ((x - t) / z));
} else {
tmp = t_3;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * ((1.0 + (z / (a - z))) - (y / (a - z))) t_2 = t_1 + (((y - z) * t) / (a - z)) t_3 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if t_3 <= -math.inf: tmp = t_2 elif t_3 <= -5e+58: tmp = t_1 + (1.0 / (((a - z) / t) / (y - z))) elif t_3 <= -1e-254: tmp = t_2 elif t_3 <= 0.0: tmp = t + ((y - a) * ((x - t) / z)) else: tmp = t_3 return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(Float64(1.0 + Float64(z / Float64(a - z))) - Float64(y / Float64(a - z)))) t_2 = Float64(t_1 + Float64(Float64(Float64(y - z) * t) / Float64(a - z))) t_3 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) tmp = 0.0 if (t_3 <= Float64(-Inf)) tmp = t_2; elseif (t_3 <= -5e+58) tmp = Float64(t_1 + Float64(1.0 / Float64(Float64(Float64(a - z) / t) / Float64(y - z)))); elseif (t_3 <= -1e-254) tmp = t_2; elseif (t_3 <= 0.0) tmp = Float64(t + Float64(Float64(y - a) * Float64(Float64(x - t) / z))); else tmp = t_3; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * ((1.0 + (z / (a - z))) - (y / (a - z))); t_2 = t_1 + (((y - z) * t) / (a - z)); t_3 = x + ((y - z) * ((t - x) / (a - z))); tmp = 0.0; if (t_3 <= -Inf) tmp = t_2; elseif (t_3 <= -5e+58) tmp = t_1 + (1.0 / (((a - z) / t) / (y - z))); elseif (t_3 <= -1e-254) tmp = t_2; elseif (t_3 <= 0.0) tmp = t + ((y - a) * ((x - t) / z)); else tmp = t_3; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(N[(1.0 + N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$3, (-Infinity)], t$95$2, If[LessEqual[t$95$3, -5e+58], N[(t$95$1 + N[(1.0 / N[(N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, -1e-254], t$95$2, If[LessEqual[t$95$3, 0.0], N[(t + N[(N[(y - a), $MachinePrecision] * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$3]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(\left(1 + \frac{z}{a - z}\right) - \frac{y}{a - z}\right)\\
t_2 := t_1 + \frac{\left(y - z\right) \cdot t}{a - z}\\
t_3 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{if}\;t_3 \leq -\infty:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_3 \leq -5 \cdot 10^{+58}:\\
\;\;\;\;t_1 + \frac{1}{\frac{\frac{a - z}{t}}{y - z}}\\
\mathbf{elif}\;t_3 \leq -1 \cdot 10^{-254}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_3 \leq 0:\\
\;\;\;\;t + \left(y - a\right) \cdot \frac{x - t}{z}\\
\mathbf{else}:\\
\;\;\;\;t_3\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0 or -4.99999999999999986e58 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -9.9999999999999991e-255Initial program 78.4%
Taylor expanded in x around -inf 96.6%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.99999999999999986e58Initial program 98.4%
Taylor expanded in x around -inf 67.3%
clear-num67.3%
inv-pow67.3%
Applied egg-rr67.3%
unpow-167.3%
associate-/r*98.6%
Simplified98.6%
if -9.9999999999999991e-255 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.7%
clear-num3.6%
associate-/r/3.6%
Applied egg-rr3.6%
Taylor expanded in z around inf 87.7%
associate--l+87.7%
associate-*r/87.7%
associate-*r/87.7%
div-sub87.7%
distribute-lft-out--87.7%
associate-*r/87.7%
mul-1-neg87.7%
unsub-neg87.7%
distribute-rgt-out--87.9%
Simplified87.9%
*-commutative87.9%
*-un-lft-identity87.9%
times-frac99.8%
Applied egg-rr99.8%
if 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 94.3%
Final simplification96.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (<= t_1 (- INFINITY))
(* (- t x) (/ y (- a z)))
(if (or (<= t_1 -5e-236) (not (<= t_1 0.0)))
t_1
(- t (* (- t x) (/ (- y a) z)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = (t - x) * (y / (a - z));
} else if ((t_1 <= -5e-236) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t - ((t - x) * ((y - a) / z));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_1 <= -Double.POSITIVE_INFINITY) {
tmp = (t - x) * (y / (a - z));
} else if ((t_1 <= -5e-236) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t - ((t - x) * ((y - a) / z));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if t_1 <= -math.inf: tmp = (t - x) * (y / (a - z)) elif (t_1 <= -5e-236) or not (t_1 <= 0.0): tmp = t_1 else: tmp = t - ((t - x) * ((y - a) / z)) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z))); elseif ((t_1 <= -5e-236) || !(t_1 <= 0.0)) tmp = t_1; else tmp = Float64(t - Float64(Float64(t - x) * Float64(Float64(y - a) / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - z) * ((t - x) / (a - z))); tmp = 0.0; if (t_1 <= -Inf) tmp = (t - x) * (y / (a - z)); elseif ((t_1 <= -5e-236) || ~((t_1 <= 0.0))) tmp = t_1; else tmp = t - ((t - x) * ((y - a) / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[t$95$1, -5e-236], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], t$95$1, N[(t - N[(N[(t - x), $MachinePrecision] * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{if}\;t_1 \leq -\infty:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\
\mathbf{elif}\;t_1 \leq -5 \cdot 10^{-236} \lor \neg \left(t_1 \leq 0\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t - \left(t - x\right) \cdot \frac{y - a}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0Initial program 70.1%
Taylor expanded in y around inf 69.2%
div-sub69.6%
associate-*r/87.3%
associate-/l*69.6%
associate-/r/87.4%
Simplified87.4%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.9999999999999998e-236 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 94.4%
if -4.9999999999999998e-236 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.9%
clear-num3.8%
associate-/r/3.8%
Applied egg-rr3.8%
Taylor expanded in z around inf 88.4%
associate--l+88.4%
associate-*r/88.4%
associate-*r/88.4%
div-sub88.4%
distribute-lft-out--88.4%
associate-*r/88.4%
mul-1-neg88.4%
unsub-neg88.4%
distribute-rgt-out--88.6%
Simplified88.6%
Taylor expanded in t around inf 88.6%
+-commutative88.6%
mul-1-neg88.6%
sub-neg88.6%
associate-/l*88.6%
associate-/l*96.8%
div-sub96.8%
associate-/r/97.0%
*-commutative97.0%
associate-*r/88.6%
*-commutative88.6%
associate-*r/96.9%
Simplified96.9%
Final simplification94.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (<= t_1 (- INFINITY))
(* (- t x) (/ y (- a z)))
(if (or (<= t_1 -5e-236) (not (<= t_1 0.0)))
t_1
(- t (* (- t x) (/ 1.0 (/ z (- y a)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = (t - x) * (y / (a - z));
} else if ((t_1 <= -5e-236) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t - ((t - x) * (1.0 / (z / (y - a))));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_1 <= -Double.POSITIVE_INFINITY) {
tmp = (t - x) * (y / (a - z));
} else if ((t_1 <= -5e-236) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t - ((t - x) * (1.0 / (z / (y - a))));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if t_1 <= -math.inf: tmp = (t - x) * (y / (a - z)) elif (t_1 <= -5e-236) or not (t_1 <= 0.0): tmp = t_1 else: tmp = t - ((t - x) * (1.0 / (z / (y - a)))) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z))); elseif ((t_1 <= -5e-236) || !(t_1 <= 0.0)) tmp = t_1; else tmp = Float64(t - Float64(Float64(t - x) * Float64(1.0 / Float64(z / Float64(y - a))))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - z) * ((t - x) / (a - z))); tmp = 0.0; if (t_1 <= -Inf) tmp = (t - x) * (y / (a - z)); elseif ((t_1 <= -5e-236) || ~((t_1 <= 0.0))) tmp = t_1; else tmp = t - ((t - x) * (1.0 / (z / (y - a)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[t$95$1, -5e-236], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], t$95$1, N[(t - N[(N[(t - x), $MachinePrecision] * N[(1.0 / N[(z / N[(y - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{if}\;t_1 \leq -\infty:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\
\mathbf{elif}\;t_1 \leq -5 \cdot 10^{-236} \lor \neg \left(t_1 \leq 0\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t - \left(t - x\right) \cdot \frac{1}{\frac{z}{y - a}}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0Initial program 70.1%
Taylor expanded in y around inf 69.2%
div-sub69.6%
associate-*r/87.3%
associate-/l*69.6%
associate-/r/87.4%
Simplified87.4%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.9999999999999998e-236 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 94.4%
if -4.9999999999999998e-236 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.9%
clear-num3.8%
associate-/r/3.8%
Applied egg-rr3.8%
Taylor expanded in z around inf 88.4%
associate--l+88.4%
associate-*r/88.4%
associate-*r/88.4%
div-sub88.4%
distribute-lft-out--88.4%
associate-*r/88.4%
mul-1-neg88.4%
unsub-neg88.4%
distribute-rgt-out--88.6%
Simplified88.6%
associate-/l*96.8%
div-inv96.9%
Applied egg-rr96.9%
Final simplification94.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (<= t_1 (- INFINITY))
(* (- t x) (/ y (- a z)))
(if (or (<= t_1 -5e-236) (not (<= t_1 0.0)))
t_1
(+ t (* (- y a) (/ (- x t) z)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = (t - x) * (y / (a - z));
} else if ((t_1 <= -5e-236) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t + ((y - a) * ((x - t) / z));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double tmp;
if (t_1 <= -Double.POSITIVE_INFINITY) {
tmp = (t - x) * (y / (a - z));
} else if ((t_1 <= -5e-236) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t + ((y - a) * ((x - t) / z));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if t_1 <= -math.inf: tmp = (t - x) * (y / (a - z)) elif (t_1 <= -5e-236) or not (t_1 <= 0.0): tmp = t_1 else: tmp = t + ((y - a) * ((x - t) / z)) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z))); elseif ((t_1 <= -5e-236) || !(t_1 <= 0.0)) tmp = t_1; else tmp = Float64(t + Float64(Float64(y - a) * Float64(Float64(x - t) / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - z) * ((t - x) / (a - z))); tmp = 0.0; if (t_1 <= -Inf) tmp = (t - x) * (y / (a - z)); elseif ((t_1 <= -5e-236) || ~((t_1 <= 0.0))) tmp = t_1; else tmp = t + ((y - a) * ((x - t) / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[t$95$1, -5e-236], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], t$95$1, N[(t + N[(N[(y - a), $MachinePrecision] * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{if}\;t_1 \leq -\infty:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\
\mathbf{elif}\;t_1 \leq -5 \cdot 10^{-236} \lor \neg \left(t_1 \leq 0\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t + \left(y - a\right) \cdot \frac{x - t}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -inf.0Initial program 70.1%
Taylor expanded in y around inf 69.2%
div-sub69.6%
associate-*r/87.3%
associate-/l*69.6%
associate-/r/87.4%
Simplified87.4%
if -inf.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.9999999999999998e-236 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 94.4%
if -4.9999999999999998e-236 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.9%
clear-num3.8%
associate-/r/3.8%
Applied egg-rr3.8%
Taylor expanded in z around inf 88.4%
associate--l+88.4%
associate-*r/88.4%
associate-*r/88.4%
div-sub88.4%
distribute-lft-out--88.4%
associate-*r/88.4%
mul-1-neg88.4%
unsub-neg88.4%
distribute-rgt-out--88.6%
Simplified88.6%
*-commutative88.6%
*-un-lft-identity88.6%
times-frac97.0%
Applied egg-rr97.0%
Final simplification94.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* (- t x) (/ y a))))
(if (<= z -1.8e+107)
t
(if (<= z -3.4e-151)
x
(if (<= z 1.26e-169)
t_1
(if (<= z 7e-113) (+ x t) (if (<= z 1.06e-37) t_1 t)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (t - x) * (y / a);
double tmp;
if (z <= -1.8e+107) {
tmp = t;
} else if (z <= -3.4e-151) {
tmp = x;
} else if (z <= 1.26e-169) {
tmp = t_1;
} else if (z <= 7e-113) {
tmp = x + t;
} else if (z <= 1.06e-37) {
tmp = t_1;
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = (t - x) * (y / a)
if (z <= (-1.8d+107)) then
tmp = t
else if (z <= (-3.4d-151)) then
tmp = x
else if (z <= 1.26d-169) then
tmp = t_1
else if (z <= 7d-113) then
tmp = x + t
else if (z <= 1.06d-37) then
tmp = t_1
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (t - x) * (y / a);
double tmp;
if (z <= -1.8e+107) {
tmp = t;
} else if (z <= -3.4e-151) {
tmp = x;
} else if (z <= 1.26e-169) {
tmp = t_1;
} else if (z <= 7e-113) {
tmp = x + t;
} else if (z <= 1.06e-37) {
tmp = t_1;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (t - x) * (y / a) tmp = 0 if z <= -1.8e+107: tmp = t elif z <= -3.4e-151: tmp = x elif z <= 1.26e-169: tmp = t_1 elif z <= 7e-113: tmp = x + t elif z <= 1.06e-37: tmp = t_1 else: tmp = t return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(t - x) * Float64(y / a)) tmp = 0.0 if (z <= -1.8e+107) tmp = t; elseif (z <= -3.4e-151) tmp = x; elseif (z <= 1.26e-169) tmp = t_1; elseif (z <= 7e-113) tmp = Float64(x + t); elseif (z <= 1.06e-37) tmp = t_1; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (t - x) * (y / a); tmp = 0.0; if (z <= -1.8e+107) tmp = t; elseif (z <= -3.4e-151) tmp = x; elseif (z <= 1.26e-169) tmp = t_1; elseif (z <= 7e-113) tmp = x + t; elseif (z <= 1.06e-37) tmp = t_1; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(t - x), $MachinePrecision] * N[(y / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.8e+107], t, If[LessEqual[z, -3.4e-151], x, If[LessEqual[z, 1.26e-169], t$95$1, If[LessEqual[z, 7e-113], N[(x + t), $MachinePrecision], If[LessEqual[z, 1.06e-37], t$95$1, t]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(t - x\right) \cdot \frac{y}{a}\\
\mathbf{if}\;z \leq -1.8 \cdot 10^{+107}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq -3.4 \cdot 10^{-151}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 1.26 \cdot 10^{-169}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 7 \cdot 10^{-113}:\\
\;\;\;\;x + t\\
\mathbf{elif}\;z \leq 1.06 \cdot 10^{-37}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -1.7999999999999999e107 or 1.06000000000000003e-37 < z Initial program 67.2%
Taylor expanded in z around inf 54.6%
if -1.7999999999999999e107 < z < -3.4000000000000003e-151Initial program 92.4%
Taylor expanded in a around inf 42.9%
if -3.4000000000000003e-151 < z < 1.26e-169 or 7.00000000000000057e-113 < z < 1.06000000000000003e-37Initial program 89.5%
Taylor expanded in y around inf 57.5%
div-sub60.0%
associate-*r/63.2%
associate-/l*60.1%
associate-/r/64.3%
Simplified64.3%
Taylor expanded in a around inf 51.7%
if 1.26e-169 < z < 7.00000000000000057e-113Initial program 85.2%
+-commutative85.2%
fma-def85.1%
Simplified85.1%
Taylor expanded in t around inf 71.0%
Taylor expanded in z around inf 57.5%
Final simplification51.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ a (- t x))) (t_2 (- t (* (- t x) (/ y z)))))
(if (<= z -6.6e+104)
t_2
(if (<= z -2.4e+18)
(- x (/ z t_1))
(if (or (<= z -1.85e-12) (not (<= z 3.65e-115)))
t_2
(+ x (/ y t_1)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = a / (t - x);
double t_2 = t - ((t - x) * (y / z));
double tmp;
if (z <= -6.6e+104) {
tmp = t_2;
} else if (z <= -2.4e+18) {
tmp = x - (z / t_1);
} else if ((z <= -1.85e-12) || !(z <= 3.65e-115)) {
tmp = t_2;
} else {
tmp = x + (y / t_1);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = a / (t - x)
t_2 = t - ((t - x) * (y / z))
if (z <= (-6.6d+104)) then
tmp = t_2
else if (z <= (-2.4d+18)) then
tmp = x - (z / t_1)
else if ((z <= (-1.85d-12)) .or. (.not. (z <= 3.65d-115))) then
tmp = t_2
else
tmp = x + (y / t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = a / (t - x);
double t_2 = t - ((t - x) * (y / z));
double tmp;
if (z <= -6.6e+104) {
tmp = t_2;
} else if (z <= -2.4e+18) {
tmp = x - (z / t_1);
} else if ((z <= -1.85e-12) || !(z <= 3.65e-115)) {
tmp = t_2;
} else {
tmp = x + (y / t_1);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = a / (t - x) t_2 = t - ((t - x) * (y / z)) tmp = 0 if z <= -6.6e+104: tmp = t_2 elif z <= -2.4e+18: tmp = x - (z / t_1) elif (z <= -1.85e-12) or not (z <= 3.65e-115): tmp = t_2 else: tmp = x + (y / t_1) return tmp
function code(x, y, z, t, a) t_1 = Float64(a / Float64(t - x)) t_2 = Float64(t - Float64(Float64(t - x) * Float64(y / z))) tmp = 0.0 if (z <= -6.6e+104) tmp = t_2; elseif (z <= -2.4e+18) tmp = Float64(x - Float64(z / t_1)); elseif ((z <= -1.85e-12) || !(z <= 3.65e-115)) tmp = t_2; else tmp = Float64(x + Float64(y / t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = a / (t - x); t_2 = t - ((t - x) * (y / z)); tmp = 0.0; if (z <= -6.6e+104) tmp = t_2; elseif (z <= -2.4e+18) tmp = x - (z / t_1); elseif ((z <= -1.85e-12) || ~((z <= 3.65e-115))) tmp = t_2; else tmp = x + (y / t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t - N[(N[(t - x), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -6.6e+104], t$95$2, If[LessEqual[z, -2.4e+18], N[(x - N[(z / t$95$1), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, -1.85e-12], N[Not[LessEqual[z, 3.65e-115]], $MachinePrecision]], t$95$2, N[(x + N[(y / t$95$1), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{a}{t - x}\\
t_2 := t - \left(t - x\right) \cdot \frac{y}{z}\\
\mathbf{if}\;z \leq -6.6 \cdot 10^{+104}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;z \leq -2.4 \cdot 10^{+18}:\\
\;\;\;\;x - \frac{z}{t_1}\\
\mathbf{elif}\;z \leq -1.85 \cdot 10^{-12} \lor \neg \left(z \leq 3.65 \cdot 10^{-115}\right):\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{t_1}\\
\end{array}
\end{array}
if z < -6.59999999999999969e104 or -2.4e18 < z < -1.84999999999999999e-12 or 3.64999999999999982e-115 < z Initial program 71.6%
clear-num70.7%
associate-/r/71.4%
Applied egg-rr71.4%
Taylor expanded in z around inf 69.7%
associate--l+69.7%
associate-*r/69.7%
associate-*r/69.7%
div-sub69.7%
distribute-lft-out--69.7%
associate-*r/69.7%
mul-1-neg69.7%
unsub-neg69.7%
distribute-rgt-out--70.6%
Simplified70.6%
Taylor expanded in t around inf 70.6%
+-commutative70.6%
mul-1-neg70.6%
sub-neg70.6%
associate-/l*75.6%
associate-/l*79.7%
div-sub80.5%
associate-/r/79.7%
*-commutative79.7%
associate-*r/70.6%
*-commutative70.6%
associate-*r/80.5%
Simplified80.5%
Taylor expanded in y around inf 73.3%
if -6.59999999999999969e104 < z < -2.4e18Initial program 83.8%
Taylor expanded in y around 0 54.2%
mul-1-neg54.2%
unsub-neg54.2%
associate-/l*65.4%
associate-/r/65.5%
Simplified65.5%
Taylor expanded in a around inf 57.9%
mul-1-neg57.9%
unsub-neg57.9%
associate-/l*63.7%
Simplified63.7%
if -1.84999999999999999e-12 < z < 3.64999999999999982e-115Initial program 90.6%
Taylor expanded in z around 0 78.5%
associate-/l*78.6%
Simplified78.6%
Final simplification74.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* t (/ (- y z) (- a z)))) (t_2 (+ x (/ t (/ a y)))))
(if (<= a -1.05e+140)
t_2
(if (<= a -1.05e-124)
t_1
(if (<= a -8e-224)
(* (- t x) (/ y (- a z)))
(if (<= a 2.4e+74) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t * ((y - z) / (a - z));
double t_2 = x + (t / (a / y));
double tmp;
if (a <= -1.05e+140) {
tmp = t_2;
} else if (a <= -1.05e-124) {
tmp = t_1;
} else if (a <= -8e-224) {
tmp = (t - x) * (y / (a - z));
} else if (a <= 2.4e+74) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = t * ((y - z) / (a - z))
t_2 = x + (t / (a / y))
if (a <= (-1.05d+140)) then
tmp = t_2
else if (a <= (-1.05d-124)) then
tmp = t_1
else if (a <= (-8d-224)) then
tmp = (t - x) * (y / (a - z))
else if (a <= 2.4d+74) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = t * ((y - z) / (a - z));
double t_2 = x + (t / (a / y));
double tmp;
if (a <= -1.05e+140) {
tmp = t_2;
} else if (a <= -1.05e-124) {
tmp = t_1;
} else if (a <= -8e-224) {
tmp = (t - x) * (y / (a - z));
} else if (a <= 2.4e+74) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t * ((y - z) / (a - z)) t_2 = x + (t / (a / y)) tmp = 0 if a <= -1.05e+140: tmp = t_2 elif a <= -1.05e-124: tmp = t_1 elif a <= -8e-224: tmp = (t - x) * (y / (a - z)) elif a <= 2.4e+74: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z))) t_2 = Float64(x + Float64(t / Float64(a / y))) tmp = 0.0 if (a <= -1.05e+140) tmp = t_2; elseif (a <= -1.05e-124) tmp = t_1; elseif (a <= -8e-224) tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z))); elseif (a <= 2.4e+74) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t * ((y - z) / (a - z)); t_2 = x + (t / (a / y)); tmp = 0.0; if (a <= -1.05e+140) tmp = t_2; elseif (a <= -1.05e-124) tmp = t_1; elseif (a <= -8e-224) tmp = (t - x) * (y / (a - z)); elseif (a <= 2.4e+74) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.05e+140], t$95$2, If[LessEqual[a, -1.05e-124], t$95$1, If[LessEqual[a, -8e-224], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.4e+74], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
t_2 := x + \frac{t}{\frac{a}{y}}\\
\mathbf{if}\;a \leq -1.05 \cdot 10^{+140}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;a \leq -1.05 \cdot 10^{-124}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq -8 \cdot 10^{-224}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\
\mathbf{elif}\;a \leq 2.4 \cdot 10^{+74}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if a < -1.0500000000000001e140 or 2.40000000000000008e74 < a Initial program 91.2%
+-commutative91.2%
fma-def91.6%
Simplified91.6%
Taylor expanded in t around inf 83.6%
Taylor expanded in z around 0 65.6%
associate-/l*69.4%
Simplified69.4%
if -1.0500000000000001e140 < a < -1.05e-124 or -8.0000000000000002e-224 < a < 2.40000000000000008e74Initial program 75.7%
Taylor expanded in x around 0 48.7%
associate-/l*65.2%
Simplified65.2%
div-inv65.1%
clear-num65.2%
Applied egg-rr65.2%
if -1.05e-124 < a < -8.0000000000000002e-224Initial program 73.3%
Taylor expanded in y around inf 75.0%
div-sub75.0%
associate-*r/74.9%
associate-/l*74.9%
associate-/r/74.9%
Simplified74.9%
Final simplification67.5%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -3e-13) (not (<= z 3.65e-115))) (- t (* (- t x) (/ (- y a) z))) (+ x (/ y (/ a (- t x))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -3e-13) || !(z <= 3.65e-115)) {
tmp = t - ((t - x) * ((y - a) / z));
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((z <= (-3d-13)) .or. (.not. (z <= 3.65d-115))) then
tmp = t - ((t - x) * ((y - a) / z))
else
tmp = x + (y / (a / (t - x)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -3e-13) || !(z <= 3.65e-115)) {
tmp = t - ((t - x) * ((y - a) / z));
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -3e-13) or not (z <= 3.65e-115): tmp = t - ((t - x) * ((y - a) / z)) else: tmp = x + (y / (a / (t - x))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -3e-13) || !(z <= 3.65e-115)) tmp = Float64(t - Float64(Float64(t - x) * Float64(Float64(y - a) / z))); else tmp = Float64(x + Float64(y / Float64(a / Float64(t - x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -3e-13) || ~((z <= 3.65e-115))) tmp = t - ((t - x) * ((y - a) / z)); else tmp = x + (y / (a / (t - x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -3e-13], N[Not[LessEqual[z, 3.65e-115]], $MachinePrecision]], N[(t - N[(N[(t - x), $MachinePrecision] * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3 \cdot 10^{-13} \lor \neg \left(z \leq 3.65 \cdot 10^{-115}\right):\\
\;\;\;\;t - \left(t - x\right) \cdot \frac{y - a}{z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if z < -2.99999999999999984e-13 or 3.64999999999999982e-115 < z Initial program 72.8%
clear-num72.0%
associate-/r/72.7%
Applied egg-rr72.7%
Taylor expanded in z around inf 67.0%
associate--l+67.0%
associate-*r/67.0%
associate-*r/67.0%
div-sub67.0%
distribute-lft-out--67.0%
associate-*r/67.0%
mul-1-neg67.0%
unsub-neg67.0%
distribute-rgt-out--67.9%
Simplified67.9%
Taylor expanded in t around inf 67.2%
+-commutative67.2%
mul-1-neg67.2%
sub-neg67.2%
associate-/l*71.6%
associate-/l*75.3%
div-sub76.6%
associate-/r/76.0%
*-commutative76.0%
associate-*r/67.9%
*-commutative67.9%
associate-*r/76.7%
Simplified76.7%
if -2.99999999999999984e-13 < z < 3.64999999999999982e-115Initial program 90.6%
Taylor expanded in z around 0 78.5%
associate-/l*78.6%
Simplified78.6%
Final simplification77.5%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -1.9e-12) (not (<= z 6.4e-114))) (* t (/ (- y z) (- a z))) (+ x (/ t (/ a y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1.9e-12) || !(z <= 6.4e-114)) {
tmp = t * ((y - z) / (a - z));
} else {
tmp = x + (t / (a / y));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((z <= (-1.9d-12)) .or. (.not. (z <= 6.4d-114))) then
tmp = t * ((y - z) / (a - z))
else
tmp = x + (t / (a / y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1.9e-12) || !(z <= 6.4e-114)) {
tmp = t * ((y - z) / (a - z));
} else {
tmp = x + (t / (a / y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -1.9e-12) or not (z <= 6.4e-114): tmp = t * ((y - z) / (a - z)) else: tmp = x + (t / (a / y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -1.9e-12) || !(z <= 6.4e-114)) tmp = Float64(t * Float64(Float64(y - z) / Float64(a - z))); else tmp = Float64(x + Float64(t / Float64(a / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -1.9e-12) || ~((z <= 6.4e-114))) tmp = t * ((y - z) / (a - z)); else tmp = x + (t / (a / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -1.9e-12], N[Not[LessEqual[z, 6.4e-114]], $MachinePrecision]], N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{-12} \lor \neg \left(z \leq 6.4 \cdot 10^{-114}\right):\\
\;\;\;\;t \cdot \frac{y - z}{a - z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\
\end{array}
\end{array}
if z < -1.89999999999999998e-12 or 6.4000000000000003e-114 < z Initial program 72.7%
Taylor expanded in x around 0 41.5%
associate-/l*61.9%
Simplified61.9%
div-inv61.9%
clear-num61.9%
Applied egg-rr61.9%
if -1.89999999999999998e-12 < z < 6.4000000000000003e-114Initial program 90.7%
+-commutative90.7%
fma-def90.7%
Simplified90.7%
Taylor expanded in t around inf 66.9%
Taylor expanded in z around 0 62.8%
associate-/l*65.5%
Simplified65.5%
Final simplification63.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -6.5e+39) (not (<= z 1.8e-113))) (* t (/ (- y z) (- a z))) (+ x (/ y (/ a (- t x))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -6.5e+39) || !(z <= 1.8e-113)) {
tmp = t * ((y - z) / (a - z));
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((z <= (-6.5d+39)) .or. (.not. (z <= 1.8d-113))) then
tmp = t * ((y - z) / (a - z))
else
tmp = x + (y / (a / (t - x)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -6.5e+39) || !(z <= 1.8e-113)) {
tmp = t * ((y - z) / (a - z));
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -6.5e+39) or not (z <= 1.8e-113): tmp = t * ((y - z) / (a - z)) else: tmp = x + (y / (a / (t - x))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -6.5e+39) || !(z <= 1.8e-113)) tmp = Float64(t * Float64(Float64(y - z) / Float64(a - z))); else tmp = Float64(x + Float64(y / Float64(a / Float64(t - x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -6.5e+39) || ~((z <= 1.8e-113))) tmp = t * ((y - z) / (a - z)); else tmp = x + (y / (a / (t - x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -6.5e+39], N[Not[LessEqual[z, 1.8e-113]], $MachinePrecision]], N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.5 \cdot 10^{+39} \lor \neg \left(z \leq 1.8 \cdot 10^{-113}\right):\\
\;\;\;\;t \cdot \frac{y - z}{a - z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if z < -6.5000000000000001e39 or 1.79999999999999987e-113 < z Initial program 70.9%
Taylor expanded in x around 0 41.2%
associate-/l*62.9%
Simplified62.9%
div-inv62.9%
clear-num62.9%
Applied egg-rr62.9%
if -6.5000000000000001e39 < z < 1.79999999999999987e-113Initial program 91.4%
Taylor expanded in z around 0 76.1%
associate-/l*76.2%
Simplified76.2%
Final simplification68.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -9.6e-14) (not (<= z 3.65e-115))) (- t (* (- t x) (/ y z))) (+ x (/ y (/ a (- t x))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -9.6e-14) || !(z <= 3.65e-115)) {
tmp = t - ((t - x) * (y / z));
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((z <= (-9.6d-14)) .or. (.not. (z <= 3.65d-115))) then
tmp = t - ((t - x) * (y / z))
else
tmp = x + (y / (a / (t - x)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -9.6e-14) || !(z <= 3.65e-115)) {
tmp = t - ((t - x) * (y / z));
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -9.6e-14) or not (z <= 3.65e-115): tmp = t - ((t - x) * (y / z)) else: tmp = x + (y / (a / (t - x))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -9.6e-14) || !(z <= 3.65e-115)) tmp = Float64(t - Float64(Float64(t - x) * Float64(y / z))); else tmp = Float64(x + Float64(y / Float64(a / Float64(t - x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -9.6e-14) || ~((z <= 3.65e-115))) tmp = t - ((t - x) * (y / z)); else tmp = x + (y / (a / (t - x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -9.6e-14], N[Not[LessEqual[z, 3.65e-115]], $MachinePrecision]], N[(t - N[(N[(t - x), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -9.6 \cdot 10^{-14} \lor \neg \left(z \leq 3.65 \cdot 10^{-115}\right):\\
\;\;\;\;t - \left(t - x\right) \cdot \frac{y}{z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if z < -9.599999999999999e-14 or 3.64999999999999982e-115 < z Initial program 72.8%
clear-num72.0%
associate-/r/72.7%
Applied egg-rr72.7%
Taylor expanded in z around inf 67.0%
associate--l+67.0%
associate-*r/67.0%
associate-*r/67.0%
div-sub67.0%
distribute-lft-out--67.0%
associate-*r/67.0%
mul-1-neg67.0%
unsub-neg67.0%
distribute-rgt-out--67.9%
Simplified67.9%
Taylor expanded in t around inf 67.2%
+-commutative67.2%
mul-1-neg67.2%
sub-neg67.2%
associate-/l*71.6%
associate-/l*75.3%
div-sub76.6%
associate-/r/76.0%
*-commutative76.0%
associate-*r/67.9%
*-commutative67.9%
associate-*r/76.7%
Simplified76.7%
Taylor expanded in y around inf 69.4%
if -9.599999999999999e-14 < z < 3.64999999999999982e-115Initial program 90.6%
Taylor expanded in z around 0 78.5%
associate-/l*78.6%
Simplified78.6%
Final simplification73.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -1e+106) (not (<= z 3.7e-36))) (* (/ z (- a z)) (- t)) (+ x (/ t (/ a y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1e+106) || !(z <= 3.7e-36)) {
tmp = (z / (a - z)) * -t;
} else {
tmp = x + (t / (a / y));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((z <= (-1d+106)) .or. (.not. (z <= 3.7d-36))) then
tmp = (z / (a - z)) * -t
else
tmp = x + (t / (a / y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1e+106) || !(z <= 3.7e-36)) {
tmp = (z / (a - z)) * -t;
} else {
tmp = x + (t / (a / y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -1e+106) or not (z <= 3.7e-36): tmp = (z / (a - z)) * -t else: tmp = x + (t / (a / y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -1e+106) || !(z <= 3.7e-36)) tmp = Float64(Float64(z / Float64(a - z)) * Float64(-t)); else tmp = Float64(x + Float64(t / Float64(a / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -1e+106) || ~((z <= 3.7e-36))) tmp = (z / (a - z)) * -t; else tmp = x + (t / (a / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -1e+106], N[Not[LessEqual[z, 3.7e-36]], $MachinePrecision]], N[(N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision] * (-t)), $MachinePrecision], N[(x + N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1 \cdot 10^{+106} \lor \neg \left(z \leq 3.7 \cdot 10^{-36}\right):\\
\;\;\;\;\frac{z}{a - z} \cdot \left(-t\right)\\
\mathbf{else}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\
\end{array}
\end{array}
if z < -1.00000000000000009e106 or 3.70000000000000002e-36 < z Initial program 67.5%
Taylor expanded in x around 0 40.4%
associate-/l*67.3%
Simplified67.3%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
associate-*r/59.7%
Simplified59.7%
if -1.00000000000000009e106 < z < 3.70000000000000002e-36Initial program 89.6%
+-commutative89.6%
fma-def89.5%
Simplified89.5%
Taylor expanded in t around inf 65.8%
Taylor expanded in z around 0 56.1%
associate-/l*57.9%
Simplified57.9%
Final simplification58.7%
(FPCore (x y z t a) :precision binary64 (if (<= z -2.25e+105) (/ (- t) (+ -1.0 (/ a z))) (if (<= z 5.7e-36) (+ x (/ t (/ a y))) (* (/ z (- a z)) (- t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.25e+105) {
tmp = -t / (-1.0 + (a / z));
} else if (z <= 5.7e-36) {
tmp = x + (t / (a / y));
} else {
tmp = (z / (a - z)) * -t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-2.25d+105)) then
tmp = -t / ((-1.0d0) + (a / z))
else if (z <= 5.7d-36) then
tmp = x + (t / (a / y))
else
tmp = (z / (a - z)) * -t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.25e+105) {
tmp = -t / (-1.0 + (a / z));
} else if (z <= 5.7e-36) {
tmp = x + (t / (a / y));
} else {
tmp = (z / (a - z)) * -t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -2.25e+105: tmp = -t / (-1.0 + (a / z)) elif z <= 5.7e-36: tmp = x + (t / (a / y)) else: tmp = (z / (a - z)) * -t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -2.25e+105) tmp = Float64(Float64(-t) / Float64(-1.0 + Float64(a / z))); elseif (z <= 5.7e-36) tmp = Float64(x + Float64(t / Float64(a / y))); else tmp = Float64(Float64(z / Float64(a - z)) * Float64(-t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -2.25e+105) tmp = -t / (-1.0 + (a / z)); elseif (z <= 5.7e-36) tmp = x + (t / (a / y)); else tmp = (z / (a - z)) * -t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -2.25e+105], N[((-t) / N[(-1.0 + N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.7e-36], N[(x + N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision] * (-t)), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.25 \cdot 10^{+105}:\\
\;\;\;\;\frac{-t}{-1 + \frac{a}{z}}\\
\mathbf{elif}\;z \leq 5.7 \cdot 10^{-36}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{a - z} \cdot \left(-t\right)\\
\end{array}
\end{array}
if z < -2.2500000000000001e105Initial program 61.7%
Taylor expanded in x around 0 43.6%
associate-/l*67.3%
Simplified67.3%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
associate-/l*55.1%
distribute-neg-frac55.1%
div-sub55.1%
sub-neg55.1%
*-inverses55.1%
metadata-eval55.1%
Simplified55.1%
if -2.2500000000000001e105 < z < 5.6999999999999999e-36Initial program 89.6%
+-commutative89.6%
fma-def89.5%
Simplified89.5%
Taylor expanded in t around inf 65.8%
Taylor expanded in z around 0 56.1%
associate-/l*57.9%
Simplified57.9%
if 5.6999999999999999e-36 < z Initial program 71.9%
Taylor expanded in x around 0 37.9%
associate-/l*67.2%
Simplified67.2%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
associate-*r/63.3%
Simplified63.3%
Final simplification58.7%
(FPCore (x y z t a) :precision binary64 (if (<= z -6.6e+104) (/ (- t) (/ z (- y z))) (if (<= z 5.7e-36) (+ x (/ t (/ a y))) (* (/ z (- a z)) (- t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -6.6e+104) {
tmp = -t / (z / (y - z));
} else if (z <= 5.7e-36) {
tmp = x + (t / (a / y));
} else {
tmp = (z / (a - z)) * -t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-6.6d+104)) then
tmp = -t / (z / (y - z))
else if (z <= 5.7d-36) then
tmp = x + (t / (a / y))
else
tmp = (z / (a - z)) * -t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -6.6e+104) {
tmp = -t / (z / (y - z));
} else if (z <= 5.7e-36) {
tmp = x + (t / (a / y));
} else {
tmp = (z / (a - z)) * -t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -6.6e+104: tmp = -t / (z / (y - z)) elif z <= 5.7e-36: tmp = x + (t / (a / y)) else: tmp = (z / (a - z)) * -t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -6.6e+104) tmp = Float64(Float64(-t) / Float64(z / Float64(y - z))); elseif (z <= 5.7e-36) tmp = Float64(x + Float64(t / Float64(a / y))); else tmp = Float64(Float64(z / Float64(a - z)) * Float64(-t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -6.6e+104) tmp = -t / (z / (y - z)); elseif (z <= 5.7e-36) tmp = x + (t / (a / y)); else tmp = (z / (a - z)) * -t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -6.6e+104], N[((-t) / N[(z / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.7e-36], N[(x + N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision] * (-t)), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.6 \cdot 10^{+104}:\\
\;\;\;\;\frac{-t}{\frac{z}{y - z}}\\
\mathbf{elif}\;z \leq 5.7 \cdot 10^{-36}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{a - z} \cdot \left(-t\right)\\
\end{array}
\end{array}
if z < -6.59999999999999969e104Initial program 61.7%
Taylor expanded in x around 0 43.6%
associate-/l*67.3%
Simplified67.3%
Taylor expanded in a around 0 39.7%
mul-1-neg39.7%
associate-/l*60.9%
distribute-neg-frac60.9%
Simplified60.9%
if -6.59999999999999969e104 < z < 5.6999999999999999e-36Initial program 89.6%
+-commutative89.6%
fma-def89.5%
Simplified89.5%
Taylor expanded in t around inf 65.8%
Taylor expanded in z around 0 56.1%
associate-/l*57.9%
Simplified57.9%
if 5.6999999999999999e-36 < z Initial program 71.9%
Taylor expanded in x around 0 37.9%
associate-/l*67.2%
Simplified67.2%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
associate-*r/63.3%
Simplified63.3%
Final simplification59.8%
(FPCore (x y z t a) :precision binary64 (if (<= z -7.2e+105) t (if (<= z 1.05e-29) (+ x (/ t (/ a y))) t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -7.2e+105) {
tmp = t;
} else if (z <= 1.05e-29) {
tmp = x + (t / (a / y));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-7.2d+105)) then
tmp = t
else if (z <= 1.05d-29) then
tmp = x + (t / (a / y))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -7.2e+105) {
tmp = t;
} else if (z <= 1.05e-29) {
tmp = x + (t / (a / y));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -7.2e+105: tmp = t elif z <= 1.05e-29: tmp = x + (t / (a / y)) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -7.2e+105) tmp = t; elseif (z <= 1.05e-29) tmp = Float64(x + Float64(t / Float64(a / y))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -7.2e+105) tmp = t; elseif (z <= 1.05e-29) tmp = x + (t / (a / y)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -7.2e+105], t, If[LessEqual[z, 1.05e-29], N[(x + N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.2 \cdot 10^{+105}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq 1.05 \cdot 10^{-29}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -7.1999999999999998e105 or 1.04999999999999995e-29 < z Initial program 66.9%
Taylor expanded in z around inf 55.6%
if -7.1999999999999998e105 < z < 1.04999999999999995e-29Initial program 89.7%
+-commutative89.7%
fma-def89.6%
Simplified89.6%
Taylor expanded in t around inf 66.3%
Taylor expanded in z around 0 56.0%
associate-/l*57.9%
Simplified57.9%
Final simplification56.9%
(FPCore (x y z t a) :precision binary64 (if (<= a -9e+132) x (if (<= a 0.0036) t x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -9e+132) {
tmp = x;
} else if (a <= 0.0036) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-9d+132)) then
tmp = x
else if (a <= 0.0036d0) then
tmp = t
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -9e+132) {
tmp = x;
} else if (a <= 0.0036) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -9e+132: tmp = x elif a <= 0.0036: tmp = t else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -9e+132) tmp = x; elseif (a <= 0.0036) tmp = t; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -9e+132) tmp = x; elseif (a <= 0.0036) tmp = t; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -9e+132], x, If[LessEqual[a, 0.0036], t, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -9 \cdot 10^{+132}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 0.0036:\\
\;\;\;\;t\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -8.99999999999999944e132 or 0.0035999999999999999 < a Initial program 88.8%
Taylor expanded in a around inf 55.9%
if -8.99999999999999944e132 < a < 0.0035999999999999999Initial program 75.1%
Taylor expanded in z around inf 37.3%
Final simplification43.9%
(FPCore (x y z t a) :precision binary64 (if (<= a -2.2e+54) (+ x t) (if (<= a 0.0033) t x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -2.2e+54) {
tmp = x + t;
} else if (a <= 0.0033) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-2.2d+54)) then
tmp = x + t
else if (a <= 0.0033d0) then
tmp = t
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -2.2e+54) {
tmp = x + t;
} else if (a <= 0.0033) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -2.2e+54: tmp = x + t elif a <= 0.0033: tmp = t else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -2.2e+54) tmp = Float64(x + t); elseif (a <= 0.0033) tmp = t; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -2.2e+54) tmp = x + t; elseif (a <= 0.0033) tmp = t; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -2.2e+54], N[(x + t), $MachinePrecision], If[LessEqual[a, 0.0033], t, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.2 \cdot 10^{+54}:\\
\;\;\;\;x + t\\
\mathbf{elif}\;a \leq 0.0033:\\
\;\;\;\;t\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -2.1999999999999999e54Initial program 85.8%
+-commutative85.8%
fma-def86.5%
Simplified86.5%
Taylor expanded in t around inf 74.0%
Taylor expanded in z around inf 49.8%
if -2.1999999999999999e54 < a < 0.0033Initial program 74.6%
Taylor expanded in z around inf 36.6%
if 0.0033 < a Initial program 88.0%
Taylor expanded in a around inf 57.2%
Final simplification44.1%
(FPCore (x y z t a) :precision binary64 t)
double code(double x, double y, double z, double t, double a) {
return t;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = t
end function
public static double code(double x, double y, double z, double t, double a) {
return t;
}
def code(x, y, z, t, a): return t
function code(x, y, z, t, a) return t end
function tmp = code(x, y, z, t, a) tmp = t; end
code[x_, y_, z_, t_, a_] := t
\begin{array}{l}
\\
t
\end{array}
Initial program 80.0%
Taylor expanded in z around inf 28.4%
Final simplification28.4%
herbie shell --seed 2024017
(FPCore (x y z t a)
:name "Numeric.Signal:interpolate from hsignal-0.2.7.1"
:precision binary64
(+ x (* (- y z) (/ (- t x) (- a z)))))