
(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 (+ x (* (- z y) (/ (- t x) (- z a))))))
(if (or (<= t_1 -5e-306) (not (<= t_1 0.0)))
(fma (- t x) (/ (- y z) (- a z)) x)
(+ t (/ (* x (- y a)) z)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) * ((t - x) / (z - a)));
double tmp;
if ((t_1 <= -5e-306) || !(t_1 <= 0.0)) {
tmp = fma((t - x), ((y - z) / (a - z)), x);
} else {
tmp = t + ((x * (y - a)) / z);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - y) * Float64(Float64(t - x) / Float64(z - a)))) tmp = 0.0 if ((t_1 <= -5e-306) || !(t_1 <= 0.0)) tmp = fma(Float64(t - x), Float64(Float64(y - z) / Float64(a - z)), x); else tmp = Float64(t + Float64(Float64(x * Float64(y - a)) / z)); end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(z - y), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -5e-306], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(t + N[(N[(x * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(z - y\right) \cdot \frac{t - x}{z - a}\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{-306} \lor \neg \left(t\_1 \leq 0\right):\\
\;\;\;\;\mathsf{fma}\left(t - x, \frac{y - z}{a - z}, x\right)\\
\mathbf{else}:\\
\;\;\;\;t + \frac{x \cdot \left(y - a\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.99999999999999998e-306 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 85.5%
+-commutative85.5%
remove-double-neg85.5%
unsub-neg85.5%
*-commutative85.5%
associate-*l/75.3%
associate-/l*92.4%
fma-neg92.4%
remove-double-neg92.4%
Simplified92.4%
if -4.99999999999999998e-306 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 3.0%
Taylor expanded in z around inf 87.5%
associate--l+87.5%
associate-*r/87.5%
associate-*r/87.5%
mul-1-neg87.5%
div-sub87.5%
mul-1-neg87.5%
distribute-lft-out--87.5%
associate-*r/87.5%
mul-1-neg87.5%
unsub-neg87.5%
distribute-rgt-out--87.5%
Simplified87.5%
Taylor expanded in t around 0 87.5%
associate-*r/87.5%
associate-*r*87.5%
mul-1-neg87.5%
Simplified87.5%
Final simplification91.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- z y) (/ (- t x) (- z a))))))
(if (or (<= t_1 -5e-249) (not (<= t_1 0.0)))
t_1
(+ t (/ (* x (- y a)) z)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) * ((t - x) / (z - a)));
double tmp;
if ((t_1 <= -5e-249) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t + ((x * (y - a)) / z);
}
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 = x + ((z - y) * ((t - x) / (z - a)))
if ((t_1 <= (-5d-249)) .or. (.not. (t_1 <= 0.0d0))) then
tmp = t_1
else
tmp = t + ((x * (y - a)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) * ((t - x) / (z - a)));
double tmp;
if ((t_1 <= -5e-249) || !(t_1 <= 0.0)) {
tmp = t_1;
} else {
tmp = t + ((x * (y - a)) / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - y) * ((t - x) / (z - a))) tmp = 0 if (t_1 <= -5e-249) or not (t_1 <= 0.0): tmp = t_1 else: tmp = t + ((x * (y - a)) / z) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - y) * Float64(Float64(t - x) / Float64(z - a)))) tmp = 0.0 if ((t_1 <= -5e-249) || !(t_1 <= 0.0)) tmp = t_1; else tmp = Float64(t + Float64(Float64(x * Float64(y - a)) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - y) * ((t - x) / (z - a))); tmp = 0.0; if ((t_1 <= -5e-249) || ~((t_1 <= 0.0))) tmp = t_1; else tmp = t + ((x * (y - a)) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(z - y), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -5e-249], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], t$95$1, N[(t + N[(N[(x * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(z - y\right) \cdot \frac{t - x}{z - a}\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{-249} \lor \neg \left(t\_1 \leq 0\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t + \frac{x \cdot \left(y - a\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.9999999999999999e-249 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 87.2%
if -4.9999999999999999e-249 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 8.4%
Taylor expanded in z around inf 82.2%
associate--l+82.2%
associate-*r/82.2%
associate-*r/82.2%
mul-1-neg82.2%
div-sub82.2%
mul-1-neg82.2%
distribute-lft-out--82.2%
associate-*r/82.2%
mul-1-neg82.2%
unsub-neg82.2%
distribute-rgt-out--82.2%
Simplified82.2%
Taylor expanded in t around 0 82.2%
associate-*r/82.2%
associate-*r*82.2%
mul-1-neg82.2%
Simplified82.2%
Final simplification86.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- z y) (/ (- t x) (- z a))))))
(if (or (<= t_1 -5e-249) (not (<= t_1 0.0)))
(- x (/ (- y z) (/ (- a z) (- x t))))
(+ t (/ (* x (- y a)) z)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) * ((t - x) / (z - a)));
double tmp;
if ((t_1 <= -5e-249) || !(t_1 <= 0.0)) {
tmp = x - ((y - z) / ((a - z) / (x - t)));
} else {
tmp = t + ((x * (y - a)) / z);
}
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 = x + ((z - y) * ((t - x) / (z - a)))
if ((t_1 <= (-5d-249)) .or. (.not. (t_1 <= 0.0d0))) then
tmp = x - ((y - z) / ((a - z) / (x - t)))
else
tmp = t + ((x * (y - a)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) * ((t - x) / (z - a)));
double tmp;
if ((t_1 <= -5e-249) || !(t_1 <= 0.0)) {
tmp = x - ((y - z) / ((a - z) / (x - t)));
} else {
tmp = t + ((x * (y - a)) / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - y) * ((t - x) / (z - a))) tmp = 0 if (t_1 <= -5e-249) or not (t_1 <= 0.0): tmp = x - ((y - z) / ((a - z) / (x - t))) else: tmp = t + ((x * (y - a)) / z) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - y) * Float64(Float64(t - x) / Float64(z - a)))) tmp = 0.0 if ((t_1 <= -5e-249) || !(t_1 <= 0.0)) tmp = Float64(x - Float64(Float64(y - z) / Float64(Float64(a - z) / Float64(x - t)))); else tmp = Float64(t + Float64(Float64(x * Float64(y - a)) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - y) * ((t - x) / (z - a))); tmp = 0.0; if ((t_1 <= -5e-249) || ~((t_1 <= 0.0))) tmp = x - ((y - z) / ((a - z) / (x - t))); else tmp = t + ((x * (y - a)) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(z - y), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -5e-249], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], N[(x - N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / N[(x - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + N[(N[(x * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(z - y\right) \cdot \frac{t - x}{z - a}\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{-249} \lor \neg \left(t\_1 \leq 0\right):\\
\;\;\;\;x - \frac{y - z}{\frac{a - z}{x - t}}\\
\mathbf{else}:\\
\;\;\;\;t + \frac{x \cdot \left(y - a\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.9999999999999999e-249 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 87.2%
clear-num87.2%
un-div-inv87.6%
Applied egg-rr87.6%
if -4.9999999999999999e-249 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 8.4%
Taylor expanded in z around inf 82.2%
associate--l+82.2%
associate-*r/82.2%
associate-*r/82.2%
mul-1-neg82.2%
div-sub82.2%
mul-1-neg82.2%
distribute-lft-out--82.2%
associate-*r/82.2%
mul-1-neg82.2%
unsub-neg82.2%
distribute-rgt-out--82.2%
Simplified82.2%
Taylor expanded in t around 0 82.2%
associate-*r/82.2%
associate-*r*82.2%
mul-1-neg82.2%
Simplified82.2%
Final simplification86.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- t x) a))) (t_2 (* x (+ (/ z a) 1.0))))
(if (<= a -4.1e+160)
t_2
(if (<= a -5.8e-75)
t_1
(if (<= a -1.35e-181)
t
(if (<= a 1.48e-213)
(* x (/ y z))
(if (<= a 6.2e-138)
t
(if (<= a 2.9e+17)
(* x (/ (- y a) z))
(if (<= a 1.5e+176) t_1 t_2)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((t - x) / a);
double t_2 = x * ((z / a) + 1.0);
double tmp;
if (a <= -4.1e+160) {
tmp = t_2;
} else if (a <= -5.8e-75) {
tmp = t_1;
} else if (a <= -1.35e-181) {
tmp = t;
} else if (a <= 1.48e-213) {
tmp = x * (y / z);
} else if (a <= 6.2e-138) {
tmp = t;
} else if (a <= 2.9e+17) {
tmp = x * ((y - a) / z);
} else if (a <= 1.5e+176) {
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 = y * ((t - x) / a)
t_2 = x * ((z / a) + 1.0d0)
if (a <= (-4.1d+160)) then
tmp = t_2
else if (a <= (-5.8d-75)) then
tmp = t_1
else if (a <= (-1.35d-181)) then
tmp = t
else if (a <= 1.48d-213) then
tmp = x * (y / z)
else if (a <= 6.2d-138) then
tmp = t
else if (a <= 2.9d+17) then
tmp = x * ((y - a) / z)
else if (a <= 1.5d+176) 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 = y * ((t - x) / a);
double t_2 = x * ((z / a) + 1.0);
double tmp;
if (a <= -4.1e+160) {
tmp = t_2;
} else if (a <= -5.8e-75) {
tmp = t_1;
} else if (a <= -1.35e-181) {
tmp = t;
} else if (a <= 1.48e-213) {
tmp = x * (y / z);
} else if (a <= 6.2e-138) {
tmp = t;
} else if (a <= 2.9e+17) {
tmp = x * ((y - a) / z);
} else if (a <= 1.5e+176) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((t - x) / a) t_2 = x * ((z / a) + 1.0) tmp = 0 if a <= -4.1e+160: tmp = t_2 elif a <= -5.8e-75: tmp = t_1 elif a <= -1.35e-181: tmp = t elif a <= 1.48e-213: tmp = x * (y / z) elif a <= 6.2e-138: tmp = t elif a <= 2.9e+17: tmp = x * ((y - a) / z) elif a <= 1.5e+176: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(t - x) / a)) t_2 = Float64(x * Float64(Float64(z / a) + 1.0)) tmp = 0.0 if (a <= -4.1e+160) tmp = t_2; elseif (a <= -5.8e-75) tmp = t_1; elseif (a <= -1.35e-181) tmp = t; elseif (a <= 1.48e-213) tmp = Float64(x * Float64(y / z)); elseif (a <= 6.2e-138) tmp = t; elseif (a <= 2.9e+17) tmp = Float64(x * Float64(Float64(y - a) / z)); elseif (a <= 1.5e+176) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((t - x) / a); t_2 = x * ((z / a) + 1.0); tmp = 0.0; if (a <= -4.1e+160) tmp = t_2; elseif (a <= -5.8e-75) tmp = t_1; elseif (a <= -1.35e-181) tmp = t; elseif (a <= 1.48e-213) tmp = x * (y / z); elseif (a <= 6.2e-138) tmp = t; elseif (a <= 2.9e+17) tmp = x * ((y - a) / z); elseif (a <= 1.5e+176) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(z / a), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -4.1e+160], t$95$2, If[LessEqual[a, -5.8e-75], t$95$1, If[LessEqual[a, -1.35e-181], t, If[LessEqual[a, 1.48e-213], N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 6.2e-138], t, If[LessEqual[a, 2.9e+17], N[(x * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.5e+176], t$95$1, t$95$2]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{t - x}{a}\\
t_2 := x \cdot \left(\frac{z}{a} + 1\right)\\
\mathbf{if}\;a \leq -4.1 \cdot 10^{+160}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq -5.8 \cdot 10^{-75}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -1.35 \cdot 10^{-181}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 1.48 \cdot 10^{-213}:\\
\;\;\;\;x \cdot \frac{y}{z}\\
\mathbf{elif}\;a \leq 6.2 \cdot 10^{-138}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 2.9 \cdot 10^{+17}:\\
\;\;\;\;x \cdot \frac{y - a}{z}\\
\mathbf{elif}\;a \leq 1.5 \cdot 10^{+176}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -4.09999999999999998e160 or 1.5e176 < a Initial program 91.2%
Taylor expanded in x around -inf 72.8%
mul-1-neg72.8%
*-commutative72.8%
distribute-rgt-neg-in72.8%
Simplified72.8%
Taylor expanded in y around 0 67.5%
Taylor expanded in z around 0 65.2%
if -4.09999999999999998e160 < a < -5.8000000000000003e-75 or 2.9e17 < a < 1.5e176Initial program 87.2%
Taylor expanded in z around 0 60.2%
Taylor expanded in y around inf 47.4%
div-sub47.4%
Simplified47.4%
if -5.8000000000000003e-75 < a < -1.35e-181 or 1.4800000000000001e-213 < a < 6.1999999999999996e-138Initial program 46.2%
Taylor expanded in z around inf 54.6%
if -1.35e-181 < a < 1.4800000000000001e-213Initial program 65.3%
Taylor expanded in x around -inf 59.0%
mul-1-neg59.0%
*-commutative59.0%
distribute-rgt-neg-in59.0%
Simplified59.0%
Taylor expanded in z around -inf 50.7%
Taylor expanded in y around inf 50.7%
associate-/l*54.5%
Simplified54.5%
if 6.1999999999999996e-138 < a < 2.9e17Initial program 58.5%
Taylor expanded in x around -inf 40.7%
mul-1-neg40.7%
*-commutative40.7%
distribute-rgt-neg-in40.7%
Simplified40.7%
Taylor expanded in z around -inf 30.0%
associate-/l*39.0%
Simplified39.0%
Final simplification53.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* t (/ y a)))))
(if (<= a -6.1e+54)
t_1
(if (<= a -1.08e-74)
(* y (/ (- t x) a))
(if (<= a -5e-182)
t
(if (<= a 3.2e-214)
(* y (/ (- x t) z))
(if (<= a 1.16e-139)
t
(if (<= a 1.8e-15) (* x (/ (- y a) z)) t_1))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (t * (y / a));
double tmp;
if (a <= -6.1e+54) {
tmp = t_1;
} else if (a <= -1.08e-74) {
tmp = y * ((t - x) / a);
} else if (a <= -5e-182) {
tmp = t;
} else if (a <= 3.2e-214) {
tmp = y * ((x - t) / z);
} else if (a <= 1.16e-139) {
tmp = t;
} else if (a <= 1.8e-15) {
tmp = x * ((y - a) / z);
} else {
tmp = 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) :: tmp
t_1 = x + (t * (y / a))
if (a <= (-6.1d+54)) then
tmp = t_1
else if (a <= (-1.08d-74)) then
tmp = y * ((t - x) / a)
else if (a <= (-5d-182)) then
tmp = t
else if (a <= 3.2d-214) then
tmp = y * ((x - t) / z)
else if (a <= 1.16d-139) then
tmp = t
else if (a <= 1.8d-15) then
tmp = x * ((y - a) / z)
else
tmp = 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 = x + (t * (y / a));
double tmp;
if (a <= -6.1e+54) {
tmp = t_1;
} else if (a <= -1.08e-74) {
tmp = y * ((t - x) / a);
} else if (a <= -5e-182) {
tmp = t;
} else if (a <= 3.2e-214) {
tmp = y * ((x - t) / z);
} else if (a <= 1.16e-139) {
tmp = t;
} else if (a <= 1.8e-15) {
tmp = x * ((y - a) / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (t * (y / a)) tmp = 0 if a <= -6.1e+54: tmp = t_1 elif a <= -1.08e-74: tmp = y * ((t - x) / a) elif a <= -5e-182: tmp = t elif a <= 3.2e-214: tmp = y * ((x - t) / z) elif a <= 1.16e-139: tmp = t elif a <= 1.8e-15: tmp = x * ((y - a) / z) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(t * Float64(y / a))) tmp = 0.0 if (a <= -6.1e+54) tmp = t_1; elseif (a <= -1.08e-74) tmp = Float64(y * Float64(Float64(t - x) / a)); elseif (a <= -5e-182) tmp = t; elseif (a <= 3.2e-214) tmp = Float64(y * Float64(Float64(x - t) / z)); elseif (a <= 1.16e-139) tmp = t; elseif (a <= 1.8e-15) tmp = Float64(x * Float64(Float64(y - a) / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (t * (y / a)); tmp = 0.0; if (a <= -6.1e+54) tmp = t_1; elseif (a <= -1.08e-74) tmp = y * ((t - x) / a); elseif (a <= -5e-182) tmp = t; elseif (a <= 3.2e-214) tmp = y * ((x - t) / z); elseif (a <= 1.16e-139) tmp = t; elseif (a <= 1.8e-15) tmp = x * ((y - a) / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -6.1e+54], t$95$1, If[LessEqual[a, -1.08e-74], N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -5e-182], t, If[LessEqual[a, 3.2e-214], N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.16e-139], t, If[LessEqual[a, 1.8e-15], N[(x * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + t \cdot \frac{y}{a}\\
\mathbf{if}\;a \leq -6.1 \cdot 10^{+54}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -1.08 \cdot 10^{-74}:\\
\;\;\;\;y \cdot \frac{t - x}{a}\\
\mathbf{elif}\;a \leq -5 \cdot 10^{-182}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 3.2 \cdot 10^{-214}:\\
\;\;\;\;y \cdot \frac{x - t}{z}\\
\mathbf{elif}\;a \leq 1.16 \cdot 10^{-139}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 1.8 \cdot 10^{-15}:\\
\;\;\;\;x \cdot \frac{y - a}{z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -6.0999999999999998e54 or 1.8000000000000001e-15 < a Initial program 89.9%
Taylor expanded in z around 0 64.7%
associate-/l*72.0%
Simplified72.0%
Taylor expanded in t around inf 61.7%
associate-/l*62.9%
Simplified62.9%
if -6.0999999999999998e54 < a < -1.0799999999999999e-74Initial program 82.4%
Taylor expanded in z around 0 61.6%
Taylor expanded in y around inf 56.8%
div-sub56.8%
Simplified56.8%
if -1.0799999999999999e-74 < a < -5.00000000000000024e-182 or 3.20000000000000013e-214 < a < 1.15999999999999999e-139Initial program 46.2%
Taylor expanded in z around inf 54.6%
if -5.00000000000000024e-182 < a < 3.20000000000000013e-214Initial program 65.3%
Taylor expanded in z around inf 86.7%
associate--l+86.7%
associate-*r/86.7%
associate-*r/86.7%
mul-1-neg86.7%
div-sub86.7%
mul-1-neg86.7%
distribute-lft-out--86.7%
associate-*r/86.7%
mul-1-neg86.7%
unsub-neg86.7%
distribute-rgt-out--86.7%
Simplified86.7%
Taylor expanded in y around -inf 57.6%
mul-1-neg57.6%
associate-/l*58.3%
Simplified58.3%
if 1.15999999999999999e-139 < a < 1.8000000000000001e-15Initial program 55.9%
Taylor expanded in x around -inf 39.0%
mul-1-neg39.0%
*-commutative39.0%
distribute-rgt-neg-in39.0%
Simplified39.0%
Taylor expanded in z around -inf 30.4%
associate-/l*40.8%
Simplified40.8%
Final simplification58.1%
(FPCore (x y z t a)
:precision binary64
(if (<= a -1.3e+41)
(* x (- 1.0 (/ y a)))
(if (<= a -6.4e-76)
(* y (/ (- t x) a))
(if (<= a -1.28e-189)
t
(if (<= a 1.1e-212)
(* y (/ (- x t) z))
(if (<= a 1.45e-136)
t
(if (<= a 1e-13) (* x (/ (- y a) z)) (+ x (* t (/ y a))))))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.3e+41) {
tmp = x * (1.0 - (y / a));
} else if (a <= -6.4e-76) {
tmp = y * ((t - x) / a);
} else if (a <= -1.28e-189) {
tmp = t;
} else if (a <= 1.1e-212) {
tmp = y * ((x - t) / z);
} else if (a <= 1.45e-136) {
tmp = t;
} else if (a <= 1e-13) {
tmp = x * ((y - a) / z);
} else {
tmp = x + (t * (y / a));
}
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 <= (-1.3d+41)) then
tmp = x * (1.0d0 - (y / a))
else if (a <= (-6.4d-76)) then
tmp = y * ((t - x) / a)
else if (a <= (-1.28d-189)) then
tmp = t
else if (a <= 1.1d-212) then
tmp = y * ((x - t) / z)
else if (a <= 1.45d-136) then
tmp = t
else if (a <= 1d-13) then
tmp = x * ((y - a) / z)
else
tmp = x + (t * (y / a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.3e+41) {
tmp = x * (1.0 - (y / a));
} else if (a <= -6.4e-76) {
tmp = y * ((t - x) / a);
} else if (a <= -1.28e-189) {
tmp = t;
} else if (a <= 1.1e-212) {
tmp = y * ((x - t) / z);
} else if (a <= 1.45e-136) {
tmp = t;
} else if (a <= 1e-13) {
tmp = x * ((y - a) / z);
} else {
tmp = x + (t * (y / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.3e+41: tmp = x * (1.0 - (y / a)) elif a <= -6.4e-76: tmp = y * ((t - x) / a) elif a <= -1.28e-189: tmp = t elif a <= 1.1e-212: tmp = y * ((x - t) / z) elif a <= 1.45e-136: tmp = t elif a <= 1e-13: tmp = x * ((y - a) / z) else: tmp = x + (t * (y / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.3e+41) tmp = Float64(x * Float64(1.0 - Float64(y / a))); elseif (a <= -6.4e-76) tmp = Float64(y * Float64(Float64(t - x) / a)); elseif (a <= -1.28e-189) tmp = t; elseif (a <= 1.1e-212) tmp = Float64(y * Float64(Float64(x - t) / z)); elseif (a <= 1.45e-136) tmp = t; elseif (a <= 1e-13) tmp = Float64(x * Float64(Float64(y - a) / z)); else tmp = Float64(x + Float64(t * Float64(y / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -1.3e+41) tmp = x * (1.0 - (y / a)); elseif (a <= -6.4e-76) tmp = y * ((t - x) / a); elseif (a <= -1.28e-189) tmp = t; elseif (a <= 1.1e-212) tmp = y * ((x - t) / z); elseif (a <= 1.45e-136) tmp = t; elseif (a <= 1e-13) tmp = x * ((y - a) / z); else tmp = x + (t * (y / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.3e+41], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -6.4e-76], N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -1.28e-189], t, If[LessEqual[a, 1.1e-212], N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.45e-136], t, If[LessEqual[a, 1e-13], N[(x * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.3 \cdot 10^{+41}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{elif}\;a \leq -6.4 \cdot 10^{-76}:\\
\;\;\;\;y \cdot \frac{t - x}{a}\\
\mathbf{elif}\;a \leq -1.28 \cdot 10^{-189}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 1.1 \cdot 10^{-212}:\\
\;\;\;\;y \cdot \frac{x - t}{z}\\
\mathbf{elif}\;a \leq 1.45 \cdot 10^{-136}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 10^{-13}:\\
\;\;\;\;x \cdot \frac{y - a}{z}\\
\mathbf{else}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\
\end{array}
\end{array}
if a < -1.3e41Initial program 86.5%
Taylor expanded in z around 0 60.4%
Taylor expanded in x around inf 59.9%
mul-1-neg59.9%
Simplified59.9%
if -1.3e41 < a < -6.3999999999999995e-76Initial program 80.3%
Taylor expanded in z around 0 57.0%
Taylor expanded in y around inf 57.0%
div-sub57.0%
Simplified57.0%
if -6.3999999999999995e-76 < a < -1.28e-189 or 1.10000000000000002e-212 < a < 1.44999999999999997e-136Initial program 46.2%
Taylor expanded in z around inf 54.6%
if -1.28e-189 < a < 1.10000000000000002e-212Initial program 65.3%
Taylor expanded in z around inf 86.7%
associate--l+86.7%
associate-*r/86.7%
associate-*r/86.7%
mul-1-neg86.7%
div-sub86.7%
mul-1-neg86.7%
distribute-lft-out--86.7%
associate-*r/86.7%
mul-1-neg86.7%
unsub-neg86.7%
distribute-rgt-out--86.7%
Simplified86.7%
Taylor expanded in y around -inf 57.6%
mul-1-neg57.6%
associate-/l*58.3%
Simplified58.3%
if 1.44999999999999997e-136 < a < 1e-13Initial program 55.9%
Taylor expanded in x around -inf 39.0%
mul-1-neg39.0%
*-commutative39.0%
distribute-rgt-neg-in39.0%
Simplified39.0%
Taylor expanded in z around -inf 30.4%
associate-/l*40.8%
Simplified40.8%
if 1e-13 < a Initial program 93.3%
Taylor expanded in z around 0 69.9%
associate-/l*76.9%
Simplified76.9%
Taylor expanded in t around inf 64.5%
associate-/l*66.1%
Simplified66.1%
Final simplification58.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- t x) (- a z)))) (t_2 (* t (/ (- y z) (- a z)))))
(if (<= x -6e+107)
(* x (- 1.0 (/ y a)))
(if (<= x -1.76e-50)
t_1
(if (<= x 4.1e-43)
t_2
(if (<= x 7.5e+55)
t_1
(if (<= x 2.9e+68)
t_2
(if (<= x 1e+200) (- x (* y (/ x a))) (* (- y a) (/ x z))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((t - x) / (a - z));
double t_2 = t * ((y - z) / (a - z));
double tmp;
if (x <= -6e+107) {
tmp = x * (1.0 - (y / a));
} else if (x <= -1.76e-50) {
tmp = t_1;
} else if (x <= 4.1e-43) {
tmp = t_2;
} else if (x <= 7.5e+55) {
tmp = t_1;
} else if (x <= 2.9e+68) {
tmp = t_2;
} else if (x <= 1e+200) {
tmp = x - (y * (x / a));
} else {
tmp = (y - a) * (x / z);
}
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 = y * ((t - x) / (a - z))
t_2 = t * ((y - z) / (a - z))
if (x <= (-6d+107)) then
tmp = x * (1.0d0 - (y / a))
else if (x <= (-1.76d-50)) then
tmp = t_1
else if (x <= 4.1d-43) then
tmp = t_2
else if (x <= 7.5d+55) then
tmp = t_1
else if (x <= 2.9d+68) then
tmp = t_2
else if (x <= 1d+200) then
tmp = x - (y * (x / a))
else
tmp = (y - a) * (x / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((t - x) / (a - z));
double t_2 = t * ((y - z) / (a - z));
double tmp;
if (x <= -6e+107) {
tmp = x * (1.0 - (y / a));
} else if (x <= -1.76e-50) {
tmp = t_1;
} else if (x <= 4.1e-43) {
tmp = t_2;
} else if (x <= 7.5e+55) {
tmp = t_1;
} else if (x <= 2.9e+68) {
tmp = t_2;
} else if (x <= 1e+200) {
tmp = x - (y * (x / a));
} else {
tmp = (y - a) * (x / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((t - x) / (a - z)) t_2 = t * ((y - z) / (a - z)) tmp = 0 if x <= -6e+107: tmp = x * (1.0 - (y / a)) elif x <= -1.76e-50: tmp = t_1 elif x <= 4.1e-43: tmp = t_2 elif x <= 7.5e+55: tmp = t_1 elif x <= 2.9e+68: tmp = t_2 elif x <= 1e+200: tmp = x - (y * (x / a)) else: tmp = (y - a) * (x / z) return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(t - x) / Float64(a - z))) t_2 = Float64(t * Float64(Float64(y - z) / Float64(a - z))) tmp = 0.0 if (x <= -6e+107) tmp = Float64(x * Float64(1.0 - Float64(y / a))); elseif (x <= -1.76e-50) tmp = t_1; elseif (x <= 4.1e-43) tmp = t_2; elseif (x <= 7.5e+55) tmp = t_1; elseif (x <= 2.9e+68) tmp = t_2; elseif (x <= 1e+200) tmp = Float64(x - Float64(y * Float64(x / a))); else tmp = Float64(Float64(y - a) * Float64(x / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((t - x) / (a - z)); t_2 = t * ((y - z) / (a - z)); tmp = 0.0; if (x <= -6e+107) tmp = x * (1.0 - (y / a)); elseif (x <= -1.76e-50) tmp = t_1; elseif (x <= 4.1e-43) tmp = t_2; elseif (x <= 7.5e+55) tmp = t_1; elseif (x <= 2.9e+68) tmp = t_2; elseif (x <= 1e+200) tmp = x - (y * (x / a)); else tmp = (y - a) * (x / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6e+107], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -1.76e-50], t$95$1, If[LessEqual[x, 4.1e-43], t$95$2, If[LessEqual[x, 7.5e+55], t$95$1, If[LessEqual[x, 2.9e+68], t$95$2, If[LessEqual[x, 1e+200], N[(x - N[(y * N[(x / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - a), $MachinePrecision] * N[(x / z), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{t - x}{a - z}\\
t_2 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;x \leq -6 \cdot 10^{+107}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{elif}\;x \leq -1.76 \cdot 10^{-50}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 4.1 \cdot 10^{-43}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq 7.5 \cdot 10^{+55}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 2.9 \cdot 10^{+68}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq 10^{+200}:\\
\;\;\;\;x - y \cdot \frac{x}{a}\\
\mathbf{else}:\\
\;\;\;\;\left(y - a\right) \cdot \frac{x}{z}\\
\end{array}
\end{array}
if x < -6.00000000000000046e107Initial program 68.0%
Taylor expanded in z around 0 55.2%
Taylor expanded in x around inf 64.9%
mul-1-neg64.9%
Simplified64.9%
if -6.00000000000000046e107 < x < -1.76e-50 or 4.0999999999999998e-43 < x < 7.50000000000000014e55Initial program 83.7%
Taylor expanded in y around inf 59.3%
div-sub59.3%
Simplified59.3%
if -1.76e-50 < x < 4.0999999999999998e-43 or 7.50000000000000014e55 < x < 2.90000000000000011e68Initial program 80.2%
Taylor expanded in x around 0 65.9%
associate-/l*77.4%
Simplified77.4%
if 2.90000000000000011e68 < x < 9.9999999999999997e199Initial program 76.8%
Taylor expanded in z around 0 43.6%
associate-/l*61.2%
Simplified61.2%
Taylor expanded in t around 0 60.8%
neg-mul-160.8%
distribute-neg-frac260.8%
Simplified60.8%
if 9.9999999999999997e199 < x Initial program 45.6%
Taylor expanded in z around inf 57.3%
associate--l+57.3%
associate-*r/57.3%
associate-*r/57.3%
mul-1-neg57.3%
div-sub57.3%
mul-1-neg57.3%
distribute-lft-out--57.3%
associate-*r/57.3%
mul-1-neg57.3%
unsub-neg57.3%
distribute-rgt-out--62.3%
Simplified62.3%
Taylor expanded in t around 0 42.5%
*-commutative42.5%
associate-*r/66.3%
*-commutative66.3%
Simplified66.3%
Final simplification68.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* t (/ (- y z) (- a z)))))
(if (<= z -8.6e+175)
(* x (/ (- y a) z))
(if (<= z -1.25e+87)
t_1
(if (<= z -3350000000.0)
(* y (/ (- t x) (- a z)))
(if (or (<= z -1.65e-19) (not (<= z 3.9e+21)))
t_1
(+ x (/ (* y (- t x)) a))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t * ((y - z) / (a - z));
double tmp;
if (z <= -8.6e+175) {
tmp = x * ((y - a) / z);
} else if (z <= -1.25e+87) {
tmp = t_1;
} else if (z <= -3350000000.0) {
tmp = y * ((t - x) / (a - z));
} else if ((z <= -1.65e-19) || !(z <= 3.9e+21)) {
tmp = t_1;
} else {
tmp = x + ((y * (t - x)) / a);
}
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 * ((y - z) / (a - z))
if (z <= (-8.6d+175)) then
tmp = x * ((y - a) / z)
else if (z <= (-1.25d+87)) then
tmp = t_1
else if (z <= (-3350000000.0d0)) then
tmp = y * ((t - x) / (a - z))
else if ((z <= (-1.65d-19)) .or. (.not. (z <= 3.9d+21))) then
tmp = t_1
else
tmp = x + ((y * (t - x)) / a)
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 tmp;
if (z <= -8.6e+175) {
tmp = x * ((y - a) / z);
} else if (z <= -1.25e+87) {
tmp = t_1;
} else if (z <= -3350000000.0) {
tmp = y * ((t - x) / (a - z));
} else if ((z <= -1.65e-19) || !(z <= 3.9e+21)) {
tmp = t_1;
} else {
tmp = x + ((y * (t - x)) / a);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t * ((y - z) / (a - z)) tmp = 0 if z <= -8.6e+175: tmp = x * ((y - a) / z) elif z <= -1.25e+87: tmp = t_1 elif z <= -3350000000.0: tmp = y * ((t - x) / (a - z)) elif (z <= -1.65e-19) or not (z <= 3.9e+21): tmp = t_1 else: tmp = x + ((y * (t - x)) / a) return tmp
function code(x, y, z, t, a) t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z))) tmp = 0.0 if (z <= -8.6e+175) tmp = Float64(x * Float64(Float64(y - a) / z)); elseif (z <= -1.25e+87) tmp = t_1; elseif (z <= -3350000000.0) tmp = Float64(y * Float64(Float64(t - x) / Float64(a - z))); elseif ((z <= -1.65e-19) || !(z <= 3.9e+21)) tmp = t_1; else tmp = Float64(x + Float64(Float64(y * Float64(t - x)) / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t * ((y - z) / (a - z)); tmp = 0.0; if (z <= -8.6e+175) tmp = x * ((y - a) / z); elseif (z <= -1.25e+87) tmp = t_1; elseif (z <= -3350000000.0) tmp = y * ((t - x) / (a - z)); elseif ((z <= -1.65e-19) || ~((z <= 3.9e+21))) tmp = t_1; else tmp = x + ((y * (t - x)) / a); 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]}, If[LessEqual[z, -8.6e+175], N[(x * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.25e+87], t$95$1, If[LessEqual[z, -3350000000.0], N[(y * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, -1.65e-19], N[Not[LessEqual[z, 3.9e+21]], $MachinePrecision]], t$95$1, N[(x + N[(N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;z \leq -8.6 \cdot 10^{+175}:\\
\;\;\;\;x \cdot \frac{y - a}{z}\\
\mathbf{elif}\;z \leq -1.25 \cdot 10^{+87}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3350000000:\\
\;\;\;\;y \cdot \frac{t - x}{a - z}\\
\mathbf{elif}\;z \leq -1.65 \cdot 10^{-19} \lor \neg \left(z \leq 3.9 \cdot 10^{+21}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y \cdot \left(t - x\right)}{a}\\
\end{array}
\end{array}
if z < -8.59999999999999967e175Initial program 45.6%
Taylor expanded in x around -inf 36.1%
mul-1-neg36.1%
*-commutative36.1%
distribute-rgt-neg-in36.1%
Simplified36.1%
Taylor expanded in z around -inf 41.2%
associate-/l*55.1%
Simplified55.1%
if -8.59999999999999967e175 < z < -1.24999999999999995e87 or -3.35e9 < z < -1.6499999999999999e-19 or 3.9e21 < z Initial program 62.0%
Taylor expanded in x around 0 41.1%
associate-/l*62.3%
Simplified62.3%
if -1.24999999999999995e87 < z < -3.35e9Initial program 87.1%
Taylor expanded in y around inf 59.5%
div-sub59.5%
Simplified59.5%
if -1.6499999999999999e-19 < z < 3.9e21Initial program 88.8%
Taylor expanded in z around 0 79.4%
Final simplification69.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (/ y z))))
(if (<= a -2e+25)
x
(if (<= a -8.5e-184)
t
(if (<= a 1.26e-211)
t_1
(if (<= a 7e-133)
t
(if (<= a 7.5e-12) t_1 (* x (+ (/ z a) 1.0)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (y / z);
double tmp;
if (a <= -2e+25) {
tmp = x;
} else if (a <= -8.5e-184) {
tmp = t;
} else if (a <= 1.26e-211) {
tmp = t_1;
} else if (a <= 7e-133) {
tmp = t;
} else if (a <= 7.5e-12) {
tmp = t_1;
} else {
tmp = x * ((z / a) + 1.0);
}
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 = x * (y / z)
if (a <= (-2d+25)) then
tmp = x
else if (a <= (-8.5d-184)) then
tmp = t
else if (a <= 1.26d-211) then
tmp = t_1
else if (a <= 7d-133) then
tmp = t
else if (a <= 7.5d-12) then
tmp = t_1
else
tmp = x * ((z / a) + 1.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * (y / z);
double tmp;
if (a <= -2e+25) {
tmp = x;
} else if (a <= -8.5e-184) {
tmp = t;
} else if (a <= 1.26e-211) {
tmp = t_1;
} else if (a <= 7e-133) {
tmp = t;
} else if (a <= 7.5e-12) {
tmp = t_1;
} else {
tmp = x * ((z / a) + 1.0);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (y / z) tmp = 0 if a <= -2e+25: tmp = x elif a <= -8.5e-184: tmp = t elif a <= 1.26e-211: tmp = t_1 elif a <= 7e-133: tmp = t elif a <= 7.5e-12: tmp = t_1 else: tmp = x * ((z / a) + 1.0) return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(y / z)) tmp = 0.0 if (a <= -2e+25) tmp = x; elseif (a <= -8.5e-184) tmp = t; elseif (a <= 1.26e-211) tmp = t_1; elseif (a <= 7e-133) tmp = t; elseif (a <= 7.5e-12) tmp = t_1; else tmp = Float64(x * Float64(Float64(z / a) + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (y / z); tmp = 0.0; if (a <= -2e+25) tmp = x; elseif (a <= -8.5e-184) tmp = t; elseif (a <= 1.26e-211) tmp = t_1; elseif (a <= 7e-133) tmp = t; elseif (a <= 7.5e-12) tmp = t_1; else tmp = x * ((z / a) + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2e+25], x, If[LessEqual[a, -8.5e-184], t, If[LessEqual[a, 1.26e-211], t$95$1, If[LessEqual[a, 7e-133], t, If[LessEqual[a, 7.5e-12], t$95$1, N[(x * N[(N[(z / a), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{z}\\
\mathbf{if}\;a \leq -2 \cdot 10^{+25}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq -8.5 \cdot 10^{-184}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 1.26 \cdot 10^{-211}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 7 \cdot 10^{-133}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 7.5 \cdot 10^{-12}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\frac{z}{a} + 1\right)\\
\end{array}
\end{array}
if a < -2.00000000000000018e25Initial program 85.7%
Taylor expanded in a around inf 44.4%
if -2.00000000000000018e25 < a < -8.50000000000000036e-184 or 1.26000000000000009e-211 < a < 7.00000000000000006e-133Initial program 58.3%
Taylor expanded in z around inf 46.7%
if -8.50000000000000036e-184 < a < 1.26000000000000009e-211 or 7.00000000000000006e-133 < a < 7.5e-12Initial program 62.7%
Taylor expanded in x around -inf 50.8%
mul-1-neg50.8%
*-commutative50.8%
distribute-rgt-neg-in50.8%
Simplified50.8%
Taylor expanded in z around -inf 43.6%
Taylor expanded in y around inf 41.4%
associate-/l*47.8%
Simplified47.8%
if 7.5e-12 < a Initial program 93.3%
Taylor expanded in x around -inf 59.7%
mul-1-neg59.7%
*-commutative59.7%
distribute-rgt-neg-in59.7%
Simplified59.7%
Taylor expanded in y around 0 47.5%
Taylor expanded in z around 0 45.3%
Final simplification46.1%
(FPCore (x y z t a)
:precision binary64
(if (<= a -9.6e+23)
x
(if (<= a -1.05e-188)
t
(if (<= a 1.65e-214)
(* x (/ y z))
(if (<= a 5.5e-136)
t
(if (<= a 7e+18) (* x (/ (- y a) z)) (* x (+ (/ z a) 1.0))))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -9.6e+23) {
tmp = x;
} else if (a <= -1.05e-188) {
tmp = t;
} else if (a <= 1.65e-214) {
tmp = x * (y / z);
} else if (a <= 5.5e-136) {
tmp = t;
} else if (a <= 7e+18) {
tmp = x * ((y - a) / z);
} else {
tmp = x * ((z / a) + 1.0);
}
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 <= (-9.6d+23)) then
tmp = x
else if (a <= (-1.05d-188)) then
tmp = t
else if (a <= 1.65d-214) then
tmp = x * (y / z)
else if (a <= 5.5d-136) then
tmp = t
else if (a <= 7d+18) then
tmp = x * ((y - a) / z)
else
tmp = x * ((z / a) + 1.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -9.6e+23) {
tmp = x;
} else if (a <= -1.05e-188) {
tmp = t;
} else if (a <= 1.65e-214) {
tmp = x * (y / z);
} else if (a <= 5.5e-136) {
tmp = t;
} else if (a <= 7e+18) {
tmp = x * ((y - a) / z);
} else {
tmp = x * ((z / a) + 1.0);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -9.6e+23: tmp = x elif a <= -1.05e-188: tmp = t elif a <= 1.65e-214: tmp = x * (y / z) elif a <= 5.5e-136: tmp = t elif a <= 7e+18: tmp = x * ((y - a) / z) else: tmp = x * ((z / a) + 1.0) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -9.6e+23) tmp = x; elseif (a <= -1.05e-188) tmp = t; elseif (a <= 1.65e-214) tmp = Float64(x * Float64(y / z)); elseif (a <= 5.5e-136) tmp = t; elseif (a <= 7e+18) tmp = Float64(x * Float64(Float64(y - a) / z)); else tmp = Float64(x * Float64(Float64(z / a) + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -9.6e+23) tmp = x; elseif (a <= -1.05e-188) tmp = t; elseif (a <= 1.65e-214) tmp = x * (y / z); elseif (a <= 5.5e-136) tmp = t; elseif (a <= 7e+18) tmp = x * ((y - a) / z); else tmp = x * ((z / a) + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -9.6e+23], x, If[LessEqual[a, -1.05e-188], t, If[LessEqual[a, 1.65e-214], N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 5.5e-136], t, If[LessEqual[a, 7e+18], N[(x * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(z / a), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -9.6 \cdot 10^{+23}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq -1.05 \cdot 10^{-188}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 1.65 \cdot 10^{-214}:\\
\;\;\;\;x \cdot \frac{y}{z}\\
\mathbf{elif}\;a \leq 5.5 \cdot 10^{-136}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 7 \cdot 10^{+18}:\\
\;\;\;\;x \cdot \frac{y - a}{z}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\frac{z}{a} + 1\right)\\
\end{array}
\end{array}
if a < -9.6e23Initial program 85.7%
Taylor expanded in a around inf 44.4%
if -9.6e23 < a < -1.05e-188 or 1.6499999999999999e-214 < a < 5.4999999999999999e-136Initial program 59.4%
Taylor expanded in z around inf 47.5%
if -1.05e-188 < a < 1.6499999999999999e-214Initial program 65.3%
Taylor expanded in x around -inf 59.0%
mul-1-neg59.0%
*-commutative59.0%
distribute-rgt-neg-in59.0%
Simplified59.0%
Taylor expanded in z around -inf 50.7%
Taylor expanded in y around inf 50.7%
associate-/l*54.5%
Simplified54.5%
if 5.4999999999999999e-136 < a < 7e18Initial program 59.9%
Taylor expanded in x around -inf 39.4%
mul-1-neg39.4%
*-commutative39.4%
distribute-rgt-neg-in39.4%
Simplified39.4%
Taylor expanded in z around -inf 29.2%
associate-/l*41.0%
Simplified41.0%
if 7e18 < a Initial program 94.3%
Taylor expanded in x around -inf 61.1%
mul-1-neg61.1%
*-commutative61.1%
distribute-rgt-neg-in61.1%
Simplified61.1%
Taylor expanded in y around 0 49.0%
Taylor expanded in z around 0 46.7%
Final simplification46.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* t (/ (- y z) (- a z)))) (t_2 (* x (- 1.0 (/ y a)))))
(if (<= x -1.2e+69)
t_2
(if (<= x -6e-34)
t_1
(if (<= x -1.32e-55)
t_2
(if (<= x 2.9e+19)
t_1
(if (<= x 1e+200) (- x (* y (/ x a))) (* (- y a) (/ x z)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t * ((y - z) / (a - z));
double t_2 = x * (1.0 - (y / a));
double tmp;
if (x <= -1.2e+69) {
tmp = t_2;
} else if (x <= -6e-34) {
tmp = t_1;
} else if (x <= -1.32e-55) {
tmp = t_2;
} else if (x <= 2.9e+19) {
tmp = t_1;
} else if (x <= 1e+200) {
tmp = x - (y * (x / a));
} else {
tmp = (y - a) * (x / z);
}
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 * (1.0d0 - (y / a))
if (x <= (-1.2d+69)) then
tmp = t_2
else if (x <= (-6d-34)) then
tmp = t_1
else if (x <= (-1.32d-55)) then
tmp = t_2
else if (x <= 2.9d+19) then
tmp = t_1
else if (x <= 1d+200) then
tmp = x - (y * (x / a))
else
tmp = (y - a) * (x / z)
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 * (1.0 - (y / a));
double tmp;
if (x <= -1.2e+69) {
tmp = t_2;
} else if (x <= -6e-34) {
tmp = t_1;
} else if (x <= -1.32e-55) {
tmp = t_2;
} else if (x <= 2.9e+19) {
tmp = t_1;
} else if (x <= 1e+200) {
tmp = x - (y * (x / a));
} else {
tmp = (y - a) * (x / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t * ((y - z) / (a - z)) t_2 = x * (1.0 - (y / a)) tmp = 0 if x <= -1.2e+69: tmp = t_2 elif x <= -6e-34: tmp = t_1 elif x <= -1.32e-55: tmp = t_2 elif x <= 2.9e+19: tmp = t_1 elif x <= 1e+200: tmp = x - (y * (x / a)) else: tmp = (y - a) * (x / z) 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(1.0 - Float64(y / a))) tmp = 0.0 if (x <= -1.2e+69) tmp = t_2; elseif (x <= -6e-34) tmp = t_1; elseif (x <= -1.32e-55) tmp = t_2; elseif (x <= 2.9e+19) tmp = t_1; elseif (x <= 1e+200) tmp = Float64(x - Float64(y * Float64(x / a))); else tmp = Float64(Float64(y - a) * Float64(x / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t * ((y - z) / (a - z)); t_2 = x * (1.0 - (y / a)); tmp = 0.0; if (x <= -1.2e+69) tmp = t_2; elseif (x <= -6e-34) tmp = t_1; elseif (x <= -1.32e-55) tmp = t_2; elseif (x <= 2.9e+19) tmp = t_1; elseif (x <= 1e+200) tmp = x - (y * (x / a)); else tmp = (y - a) * (x / z); 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[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.2e+69], t$95$2, If[LessEqual[x, -6e-34], t$95$1, If[LessEqual[x, -1.32e-55], t$95$2, If[LessEqual[x, 2.9e+19], t$95$1, If[LessEqual[x, 1e+200], N[(x - N[(y * N[(x / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - a), $MachinePrecision] * N[(x / z), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
t_2 := x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{if}\;x \leq -1.2 \cdot 10^{+69}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -6 \cdot 10^{-34}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq -1.32 \cdot 10^{-55}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq 2.9 \cdot 10^{+19}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 10^{+200}:\\
\;\;\;\;x - y \cdot \frac{x}{a}\\
\mathbf{else}:\\
\;\;\;\;\left(y - a\right) \cdot \frac{x}{z}\\
\end{array}
\end{array}
if x < -1.2000000000000001e69 or -6e-34 < x < -1.31999999999999993e-55Initial program 72.2%
Taylor expanded in z around 0 56.4%
Taylor expanded in x around inf 64.5%
mul-1-neg64.5%
Simplified64.5%
if -1.2000000000000001e69 < x < -6e-34 or -1.31999999999999993e-55 < x < 2.9e19Initial program 80.8%
Taylor expanded in x around 0 59.6%
associate-/l*71.1%
Simplified71.1%
if 2.9e19 < x < 9.9999999999999997e199Initial program 78.9%
Taylor expanded in z around 0 42.2%
associate-/l*54.3%
Simplified54.3%
Taylor expanded in t around 0 53.6%
neg-mul-153.6%
distribute-neg-frac253.6%
Simplified53.6%
if 9.9999999999999997e199 < x Initial program 45.6%
Taylor expanded in z around inf 57.3%
associate--l+57.3%
associate-*r/57.3%
associate-*r/57.3%
mul-1-neg57.3%
div-sub57.3%
mul-1-neg57.3%
distribute-lft-out--57.3%
associate-*r/57.3%
mul-1-neg57.3%
unsub-neg57.3%
distribute-rgt-out--62.3%
Simplified62.3%
Taylor expanded in t around 0 42.5%
*-commutative42.5%
associate-*r/66.3%
*-commutative66.3%
Simplified66.3%
Final simplification66.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (/ y z))))
(if (<= a -1.3e+23)
x
(if (<= a -5e-190)
t
(if (<= a 1.65e-214)
t_1
(if (<= a 3.8e-133) t (if (<= a 3.9e-13) t_1 x)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (y / z);
double tmp;
if (a <= -1.3e+23) {
tmp = x;
} else if (a <= -5e-190) {
tmp = t;
} else if (a <= 1.65e-214) {
tmp = t_1;
} else if (a <= 3.8e-133) {
tmp = t;
} else if (a <= 3.9e-13) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = x * (y / z)
if (a <= (-1.3d+23)) then
tmp = x
else if (a <= (-5d-190)) then
tmp = t
else if (a <= 1.65d-214) then
tmp = t_1
else if (a <= 3.8d-133) then
tmp = t
else if (a <= 3.9d-13) then
tmp = t_1
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * (y / z);
double tmp;
if (a <= -1.3e+23) {
tmp = x;
} else if (a <= -5e-190) {
tmp = t;
} else if (a <= 1.65e-214) {
tmp = t_1;
} else if (a <= 3.8e-133) {
tmp = t;
} else if (a <= 3.9e-13) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (y / z) tmp = 0 if a <= -1.3e+23: tmp = x elif a <= -5e-190: tmp = t elif a <= 1.65e-214: tmp = t_1 elif a <= 3.8e-133: tmp = t elif a <= 3.9e-13: tmp = t_1 else: tmp = x return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(y / z)) tmp = 0.0 if (a <= -1.3e+23) tmp = x; elseif (a <= -5e-190) tmp = t; elseif (a <= 1.65e-214) tmp = t_1; elseif (a <= 3.8e-133) tmp = t; elseif (a <= 3.9e-13) tmp = t_1; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (y / z); tmp = 0.0; if (a <= -1.3e+23) tmp = x; elseif (a <= -5e-190) tmp = t; elseif (a <= 1.65e-214) tmp = t_1; elseif (a <= 3.8e-133) tmp = t; elseif (a <= 3.9e-13) tmp = t_1; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.3e+23], x, If[LessEqual[a, -5e-190], t, If[LessEqual[a, 1.65e-214], t$95$1, If[LessEqual[a, 3.8e-133], t, If[LessEqual[a, 3.9e-13], t$95$1, x]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{z}\\
\mathbf{if}\;a \leq -1.3 \cdot 10^{+23}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq -5 \cdot 10^{-190}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 1.65 \cdot 10^{-214}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 3.8 \cdot 10^{-133}:\\
\;\;\;\;t\\
\mathbf{elif}\;a \leq 3.9 \cdot 10^{-13}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -1.29999999999999996e23 or 3.90000000000000004e-13 < a Initial program 89.7%
Taylor expanded in a around inf 44.8%
if -1.29999999999999996e23 < a < -5.00000000000000034e-190 or 1.6499999999999999e-214 < a < 3.8000000000000003e-133Initial program 58.3%
Taylor expanded in z around inf 46.7%
if -5.00000000000000034e-190 < a < 1.6499999999999999e-214 or 3.8000000000000003e-133 < a < 3.90000000000000004e-13Initial program 62.7%
Taylor expanded in x around -inf 50.8%
mul-1-neg50.8%
*-commutative50.8%
distribute-rgt-neg-in50.8%
Simplified50.8%
Taylor expanded in z around -inf 43.6%
Taylor expanded in y around inf 41.4%
associate-/l*47.8%
Simplified47.8%
Final simplification46.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* t (/ (- y z) (- a z)))) (t_2 (+ x (* y (/ (- t x) a)))))
(if (<= a -3e+16)
t_2
(if (<= a -3.9e-192)
t_1
(if (<= a -2.4e-222)
(* (- y a) (/ x z))
(if (<= a 10000000.0) 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 + (y * ((t - x) / a));
double tmp;
if (a <= -3e+16) {
tmp = t_2;
} else if (a <= -3.9e-192) {
tmp = t_1;
} else if (a <= -2.4e-222) {
tmp = (y - a) * (x / z);
} else if (a <= 10000000.0) {
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 + (y * ((t - x) / a))
if (a <= (-3d+16)) then
tmp = t_2
else if (a <= (-3.9d-192)) then
tmp = t_1
else if (a <= (-2.4d-222)) then
tmp = (y - a) * (x / z)
else if (a <= 10000000.0d0) 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 + (y * ((t - x) / a));
double tmp;
if (a <= -3e+16) {
tmp = t_2;
} else if (a <= -3.9e-192) {
tmp = t_1;
} else if (a <= -2.4e-222) {
tmp = (y - a) * (x / z);
} else if (a <= 10000000.0) {
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 + (y * ((t - x) / a)) tmp = 0 if a <= -3e+16: tmp = t_2 elif a <= -3.9e-192: tmp = t_1 elif a <= -2.4e-222: tmp = (y - a) * (x / z) elif a <= 10000000.0: 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(y * Float64(Float64(t - x) / a))) tmp = 0.0 if (a <= -3e+16) tmp = t_2; elseif (a <= -3.9e-192) tmp = t_1; elseif (a <= -2.4e-222) tmp = Float64(Float64(y - a) * Float64(x / z)); elseif (a <= 10000000.0) 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 + (y * ((t - x) / a)); tmp = 0.0; if (a <= -3e+16) tmp = t_2; elseif (a <= -3.9e-192) tmp = t_1; elseif (a <= -2.4e-222) tmp = (y - a) * (x / z); elseif (a <= 10000000.0) 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[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3e+16], t$95$2, If[LessEqual[a, -3.9e-192], t$95$1, If[LessEqual[a, -2.4e-222], N[(N[(y - a), $MachinePrecision] * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 10000000.0], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
t_2 := x + y \cdot \frac{t - x}{a}\\
\mathbf{if}\;a \leq -3 \cdot 10^{+16}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq -3.9 \cdot 10^{-192}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -2.4 \cdot 10^{-222}:\\
\;\;\;\;\left(y - a\right) \cdot \frac{x}{z}\\
\mathbf{elif}\;a \leq 10000000:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -3e16 or 1e7 < a Initial program 90.4%
Taylor expanded in z around 0 67.1%
associate-/l*74.0%
Simplified74.0%
if -3e16 < a < -3.9000000000000003e-192 or -2.39999999999999993e-222 < a < 1e7Initial program 60.5%
Taylor expanded in x around 0 46.0%
associate-/l*59.6%
Simplified59.6%
if -3.9000000000000003e-192 < a < -2.39999999999999993e-222Initial program 56.7%
Taylor expanded in z around inf 90.4%
associate--l+90.4%
associate-*r/90.4%
associate-*r/90.4%
mul-1-neg90.4%
div-sub90.4%
mul-1-neg90.4%
distribute-lft-out--90.4%
associate-*r/90.4%
mul-1-neg90.4%
unsub-neg90.4%
distribute-rgt-out--90.4%
Simplified90.4%
Taylor expanded in t around 0 68.4%
*-commutative68.4%
associate-*r/78.0%
*-commutative78.0%
Simplified78.0%
Final simplification67.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ t (* y (/ (- x t) z)))) (t_2 (+ x (* y (/ (- t x) a)))))
(if (<= a -2.3e-22)
t_2
(if (<= a 3.4e-133)
t_1
(if (<= a 2.1e-89)
(/ (* y (- t x)) (- a z))
(if (<= a 140000000.0) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t + (y * ((x - t) / z));
double t_2 = x + (y * ((t - x) / a));
double tmp;
if (a <= -2.3e-22) {
tmp = t_2;
} else if (a <= 3.4e-133) {
tmp = t_1;
} else if (a <= 2.1e-89) {
tmp = (y * (t - x)) / (a - z);
} else if (a <= 140000000.0) {
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 * ((x - t) / z))
t_2 = x + (y * ((t - x) / a))
if (a <= (-2.3d-22)) then
tmp = t_2
else if (a <= 3.4d-133) then
tmp = t_1
else if (a <= 2.1d-89) then
tmp = (y * (t - x)) / (a - z)
else if (a <= 140000000.0d0) 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 * ((x - t) / z));
double t_2 = x + (y * ((t - x) / a));
double tmp;
if (a <= -2.3e-22) {
tmp = t_2;
} else if (a <= 3.4e-133) {
tmp = t_1;
} else if (a <= 2.1e-89) {
tmp = (y * (t - x)) / (a - z);
} else if (a <= 140000000.0) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t + (y * ((x - t) / z)) t_2 = x + (y * ((t - x) / a)) tmp = 0 if a <= -2.3e-22: tmp = t_2 elif a <= 3.4e-133: tmp = t_1 elif a <= 2.1e-89: tmp = (y * (t - x)) / (a - z) elif a <= 140000000.0: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(t + Float64(y * Float64(Float64(x - t) / z))) t_2 = Float64(x + Float64(y * Float64(Float64(t - x) / a))) tmp = 0.0 if (a <= -2.3e-22) tmp = t_2; elseif (a <= 3.4e-133) tmp = t_1; elseif (a <= 2.1e-89) tmp = Float64(Float64(y * Float64(t - x)) / Float64(a - z)); elseif (a <= 140000000.0) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t + (y * ((x - t) / z)); t_2 = x + (y * ((t - x) / a)); tmp = 0.0; if (a <= -2.3e-22) tmp = t_2; elseif (a <= 3.4e-133) tmp = t_1; elseif (a <= 2.1e-89) tmp = (y * (t - x)) / (a - z); elseif (a <= 140000000.0) 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[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.3e-22], t$95$2, If[LessEqual[a, 3.4e-133], t$95$1, If[LessEqual[a, 2.1e-89], N[(N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 140000000.0], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t + y \cdot \frac{x - t}{z}\\
t_2 := x + y \cdot \frac{t - x}{a}\\
\mathbf{if}\;a \leq -2.3 \cdot 10^{-22}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq 3.4 \cdot 10^{-133}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 2.1 \cdot 10^{-89}:\\
\;\;\;\;\frac{y \cdot \left(t - x\right)}{a - z}\\
\mathbf{elif}\;a \leq 140000000:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -2.2999999999999998e-22 or 1.4e8 < a Initial program 89.5%
Taylor expanded in z around 0 66.7%
associate-/l*73.2%
Simplified73.2%
if -2.2999999999999998e-22 < a < 3.40000000000000006e-133 or 2.1000000000000001e-89 < a < 1.4e8Initial program 59.7%
Taylor expanded in z around inf 75.8%
associate--l+75.8%
associate-*r/75.8%
associate-*r/75.8%
mul-1-neg75.8%
div-sub75.8%
mul-1-neg75.8%
distribute-lft-out--75.8%
associate-*r/75.8%
mul-1-neg75.8%
unsub-neg75.8%
distribute-rgt-out--75.8%
Simplified75.8%
Taylor expanded in y around inf 71.3%
associate-/l*76.4%
Simplified76.4%
if 3.40000000000000006e-133 < a < 2.1000000000000001e-89Initial program 57.0%
Taylor expanded in y around -inf 70.3%
Final simplification74.5%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.75e+130)
(+ t (/ (* x (- y a)) z))
(if (<= z -1.5e+23)
(* y (/ (- t x) (- a z)))
(if (<= z 165.0) (+ x (/ (* y (- t x)) a)) (+ t (* y (/ (- x t) z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.75e+130) {
tmp = t + ((x * (y - a)) / z);
} else if (z <= -1.5e+23) {
tmp = y * ((t - x) / (a - z));
} else if (z <= 165.0) {
tmp = x + ((y * (t - x)) / a);
} else {
tmp = t + (y * ((x - t) / z));
}
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.75d+130)) then
tmp = t + ((x * (y - a)) / z)
else if (z <= (-1.5d+23)) then
tmp = y * ((t - x) / (a - z))
else if (z <= 165.0d0) then
tmp = x + ((y * (t - x)) / a)
else
tmp = t + (y * ((x - t) / z))
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.75e+130) {
tmp = t + ((x * (y - a)) / z);
} else if (z <= -1.5e+23) {
tmp = y * ((t - x) / (a - z));
} else if (z <= 165.0) {
tmp = x + ((y * (t - x)) / a);
} else {
tmp = t + (y * ((x - t) / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.75e+130: tmp = t + ((x * (y - a)) / z) elif z <= -1.5e+23: tmp = y * ((t - x) / (a - z)) elif z <= 165.0: tmp = x + ((y * (t - x)) / a) else: tmp = t + (y * ((x - t) / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.75e+130) tmp = Float64(t + Float64(Float64(x * Float64(y - a)) / z)); elseif (z <= -1.5e+23) tmp = Float64(y * Float64(Float64(t - x) / Float64(a - z))); elseif (z <= 165.0) tmp = Float64(x + Float64(Float64(y * Float64(t - x)) / a)); else tmp = Float64(t + Float64(y * Float64(Float64(x - t) / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.75e+130) tmp = t + ((x * (y - a)) / z); elseif (z <= -1.5e+23) tmp = y * ((t - x) / (a - z)); elseif (z <= 165.0) tmp = x + ((y * (t - x)) / a); else tmp = t + (y * ((x - t) / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.75e+130], N[(t + N[(N[(x * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.5e+23], N[(y * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 165.0], N[(x + N[(N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(t + N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.75 \cdot 10^{+130}:\\
\;\;\;\;t + \frac{x \cdot \left(y - a\right)}{z}\\
\mathbf{elif}\;z \leq -1.5 \cdot 10^{+23}:\\
\;\;\;\;y \cdot \frac{t - x}{a - z}\\
\mathbf{elif}\;z \leq 165:\\
\;\;\;\;x + \frac{y \cdot \left(t - x\right)}{a}\\
\mathbf{else}:\\
\;\;\;\;t + y \cdot \frac{x - t}{z}\\
\end{array}
\end{array}
if z < -1.75e130Initial program 48.6%
Taylor expanded in z around inf 73.1%
associate--l+73.1%
associate-*r/73.1%
associate-*r/73.1%
mul-1-neg73.1%
div-sub73.1%
mul-1-neg73.1%
distribute-lft-out--73.1%
associate-*r/73.1%
mul-1-neg73.1%
unsub-neg73.1%
distribute-rgt-out--73.1%
Simplified73.1%
Taylor expanded in t around 0 80.5%
associate-*r/80.5%
associate-*r*80.5%
mul-1-neg80.5%
Simplified80.5%
if -1.75e130 < z < -1.5e23Initial program 88.4%
Taylor expanded in y around inf 56.8%
div-sub56.8%
Simplified56.8%
if -1.5e23 < z < 165Initial program 88.9%
Taylor expanded in z around 0 79.0%
if 165 < z Initial program 60.2%
Taylor expanded in z around inf 61.4%
associate--l+61.4%
associate-*r/61.4%
associate-*r/61.4%
mul-1-neg61.4%
div-sub61.4%
mul-1-neg61.4%
distribute-lft-out--61.4%
associate-*r/61.4%
mul-1-neg61.4%
unsub-neg61.4%
distribute-rgt-out--61.4%
Simplified61.4%
Taylor expanded in y around inf 60.1%
associate-/l*64.0%
Simplified64.0%
Final simplification73.2%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.05e+177) (* x (/ (- y a) z)) (if (<= z -2.9e+91) t (if (<= z 3.5e+76) (+ x (* t (/ y a))) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.05e+177) {
tmp = x * ((y - a) / z);
} else if (z <= -2.9e+91) {
tmp = t;
} else if (z <= 3.5e+76) {
tmp = x + (t * (y / a));
} 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 <= (-1.05d+177)) then
tmp = x * ((y - a) / z)
else if (z <= (-2.9d+91)) then
tmp = t
else if (z <= 3.5d+76) then
tmp = x + (t * (y / a))
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 <= -1.05e+177) {
tmp = x * ((y - a) / z);
} else if (z <= -2.9e+91) {
tmp = t;
} else if (z <= 3.5e+76) {
tmp = x + (t * (y / a));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.05e+177: tmp = x * ((y - a) / z) elif z <= -2.9e+91: tmp = t elif z <= 3.5e+76: tmp = x + (t * (y / a)) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.05e+177) tmp = Float64(x * Float64(Float64(y - a) / z)); elseif (z <= -2.9e+91) tmp = t; elseif (z <= 3.5e+76) tmp = Float64(x + Float64(t * Float64(y / a))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.05e+177) tmp = x * ((y - a) / z); elseif (z <= -2.9e+91) tmp = t; elseif (z <= 3.5e+76) tmp = x + (t * (y / a)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.05e+177], N[(x * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2.9e+91], t, If[LessEqual[z, 3.5e+76], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.05 \cdot 10^{+177}:\\
\;\;\;\;x \cdot \frac{y - a}{z}\\
\mathbf{elif}\;z \leq -2.9 \cdot 10^{+91}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq 3.5 \cdot 10^{+76}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -1.05000000000000006e177Initial program 45.6%
Taylor expanded in x around -inf 36.1%
mul-1-neg36.1%
*-commutative36.1%
distribute-rgt-neg-in36.1%
Simplified36.1%
Taylor expanded in z around -inf 41.2%
associate-/l*55.1%
Simplified55.1%
if -1.05000000000000006e177 < z < -2.90000000000000014e91 or 3.5e76 < z Initial program 55.6%
Taylor expanded in z around inf 53.8%
if -2.90000000000000014e91 < z < 3.5e76Initial program 87.8%
Taylor expanded in z around 0 66.0%
associate-/l*67.8%
Simplified67.8%
Taylor expanded in t around inf 55.4%
associate-/l*57.5%
Simplified57.5%
Final simplification56.3%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.25e+101)
(+ t (/ (* x (- y a)) z))
(if (<= z 1.95e+43)
(+ x (* (- t x) (/ (- y z) a)))
(+ t (* y (/ (- x t) z))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.25e+101) {
tmp = t + ((x * (y - a)) / z);
} else if (z <= 1.95e+43) {
tmp = x + ((t - x) * ((y - z) / a));
} else {
tmp = t + (y * ((x - t) / z));
}
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.25d+101)) then
tmp = t + ((x * (y - a)) / z)
else if (z <= 1.95d+43) then
tmp = x + ((t - x) * ((y - z) / a))
else
tmp = t + (y * ((x - t) / z))
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.25e+101) {
tmp = t + ((x * (y - a)) / z);
} else if (z <= 1.95e+43) {
tmp = x + ((t - x) * ((y - z) / a));
} else {
tmp = t + (y * ((x - t) / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.25e+101: tmp = t + ((x * (y - a)) / z) elif z <= 1.95e+43: tmp = x + ((t - x) * ((y - z) / a)) else: tmp = t + (y * ((x - t) / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.25e+101) tmp = Float64(t + Float64(Float64(x * Float64(y - a)) / z)); elseif (z <= 1.95e+43) tmp = Float64(x + Float64(Float64(t - x) * Float64(Float64(y - z) / a))); else tmp = Float64(t + Float64(y * Float64(Float64(x - t) / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.25e+101) tmp = t + ((x * (y - a)) / z); elseif (z <= 1.95e+43) tmp = x + ((t - x) * ((y - z) / a)); else tmp = t + (y * ((x - t) / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.25e+101], N[(t + N[(N[(x * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.95e+43], N[(x + N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.25 \cdot 10^{+101}:\\
\;\;\;\;t + \frac{x \cdot \left(y - a\right)}{z}\\
\mathbf{elif}\;z \leq 1.95 \cdot 10^{+43}:\\
\;\;\;\;x + \left(t - x\right) \cdot \frac{y - z}{a}\\
\mathbf{else}:\\
\;\;\;\;t + y \cdot \frac{x - t}{z}\\
\end{array}
\end{array}
if z < -1.24999999999999997e101Initial program 49.8%
Taylor expanded in z around inf 71.4%
associate--l+71.4%
associate-*r/71.4%
associate-*r/71.4%
mul-1-neg71.4%
div-sub71.4%
mul-1-neg71.4%
distribute-lft-out--71.4%
associate-*r/71.4%
mul-1-neg71.4%
unsub-neg71.4%
distribute-rgt-out--71.4%
Simplified71.4%
Taylor expanded in t around 0 78.6%
associate-*r/78.6%
associate-*r*78.6%
mul-1-neg78.6%
Simplified78.6%
if -1.24999999999999997e101 < z < 1.95e43Initial program 88.3%
Taylor expanded in a around inf 71.8%
associate-/l*77.1%
Simplified77.1%
if 1.95e43 < z Initial program 56.4%
Taylor expanded in z around inf 63.2%
associate--l+63.2%
associate-*r/63.2%
associate-*r/63.2%
mul-1-neg63.2%
div-sub63.2%
mul-1-neg63.2%
distribute-lft-out--63.2%
associate-*r/63.2%
mul-1-neg63.2%
unsub-neg63.2%
distribute-rgt-out--63.3%
Simplified63.3%
Taylor expanded in y around inf 63.7%
associate-/l*68.3%
Simplified68.3%
Final simplification75.4%
(FPCore (x y z t a)
:precision binary64
(if (<= a -1.4e-22)
(+ x (* (- t x) (/ (- y z) a)))
(if (<= a 12500.0)
(+ t (/ (* (- t x) (- a y)) z))
(+ x (/ (- y z) (/ a (- t x)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.4e-22) {
tmp = x + ((t - x) * ((y - z) / a));
} else if (a <= 12500.0) {
tmp = t + (((t - x) * (a - y)) / z);
} else {
tmp = x + ((y - z) / (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 (a <= (-1.4d-22)) then
tmp = x + ((t - x) * ((y - z) / a))
else if (a <= 12500.0d0) then
tmp = t + (((t - x) * (a - y)) / z)
else
tmp = x + ((y - z) / (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 (a <= -1.4e-22) {
tmp = x + ((t - x) * ((y - z) / a));
} else if (a <= 12500.0) {
tmp = t + (((t - x) * (a - y)) / z);
} else {
tmp = x + ((y - z) / (a / (t - x)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.4e-22: tmp = x + ((t - x) * ((y - z) / a)) elif a <= 12500.0: tmp = t + (((t - x) * (a - y)) / z) else: tmp = x + ((y - z) / (a / (t - x))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.4e-22) tmp = Float64(x + Float64(Float64(t - x) * Float64(Float64(y - z) / a))); elseif (a <= 12500.0) tmp = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / z)); else tmp = Float64(x + Float64(Float64(y - z) / Float64(a / Float64(t - x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -1.4e-22) tmp = x + ((t - x) * ((y - z) / a)); elseif (a <= 12500.0) tmp = t + (((t - x) * (a - y)) / z); else tmp = x + ((y - z) / (a / (t - x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.4e-22], N[(x + N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 12500.0], N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - z), $MachinePrecision] / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.4 \cdot 10^{-22}:\\
\;\;\;\;x + \left(t - x\right) \cdot \frac{y - z}{a}\\
\mathbf{elif}\;a \leq 12500:\\
\;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y - z}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if a < -1.39999999999999997e-22Initial program 84.8%
Taylor expanded in a around inf 68.7%
associate-/l*78.0%
Simplified78.0%
if -1.39999999999999997e-22 < a < 12500Initial program 59.5%
Taylor expanded in z around inf 73.5%
associate--l+73.5%
associate-*r/73.5%
associate-*r/73.5%
mul-1-neg73.5%
div-sub73.5%
mul-1-neg73.5%
distribute-lft-out--73.5%
associate-*r/73.5%
mul-1-neg73.5%
unsub-neg73.5%
distribute-rgt-out--73.5%
Simplified73.5%
if 12500 < a Initial program 94.4%
clear-num94.4%
un-div-inv94.5%
Applied egg-rr94.5%
Taylor expanded in a around inf 82.2%
Final simplification77.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -1.7e-22) (not (<= a 5.6e+15))) (+ x (* y (/ (- t x) a))) (+ t (* y (/ (- x t) z)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.7e-22) || !(a <= 5.6e+15)) {
tmp = x + (y * ((t - x) / a));
} else {
tmp = t + (y * ((x - t) / z));
}
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 <= (-1.7d-22)) .or. (.not. (a <= 5.6d+15))) then
tmp = x + (y * ((t - x) / a))
else
tmp = t + (y * ((x - t) / z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.7e-22) || !(a <= 5.6e+15)) {
tmp = x + (y * ((t - x) / a));
} else {
tmp = t + (y * ((x - t) / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -1.7e-22) or not (a <= 5.6e+15): tmp = x + (y * ((t - x) / a)) else: tmp = t + (y * ((x - t) / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -1.7e-22) || !(a <= 5.6e+15)) tmp = Float64(x + Float64(y * Float64(Float64(t - x) / a))); else tmp = Float64(t + Float64(y * Float64(Float64(x - t) / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -1.7e-22) || ~((a <= 5.6e+15))) tmp = x + (y * ((t - x) / a)); else tmp = t + (y * ((x - t) / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -1.7e-22], N[Not[LessEqual[a, 5.6e+15]], $MachinePrecision]], N[(x + N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.7 \cdot 10^{-22} \lor \neg \left(a \leq 5.6 \cdot 10^{+15}\right):\\
\;\;\;\;x + y \cdot \frac{t - x}{a}\\
\mathbf{else}:\\
\;\;\;\;t + y \cdot \frac{x - t}{z}\\
\end{array}
\end{array}
if a < -1.6999999999999999e-22 or 5.6e15 < a Initial program 89.5%
Taylor expanded in z around 0 66.7%
associate-/l*73.2%
Simplified73.2%
if -1.6999999999999999e-22 < a < 5.6e15Initial program 59.5%
Taylor expanded in z around inf 73.5%
associate--l+73.5%
associate-*r/73.5%
associate-*r/73.5%
mul-1-neg73.5%
div-sub73.5%
mul-1-neg73.5%
distribute-lft-out--73.5%
associate-*r/73.5%
mul-1-neg73.5%
unsub-neg73.5%
distribute-rgt-out--73.5%
Simplified73.5%
Taylor expanded in y around inf 68.5%
associate-/l*72.4%
Simplified72.4%
Final simplification72.9%
(FPCore (x y z t a) :precision binary64 (if (<= a -5.3e+20) x (if (<= a 22000000000000.0) t x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -5.3e+20) {
tmp = x;
} else if (a <= 22000000000000.0) {
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 <= (-5.3d+20)) then
tmp = x
else if (a <= 22000000000000.0d0) 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 <= -5.3e+20) {
tmp = x;
} else if (a <= 22000000000000.0) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -5.3e+20: tmp = x elif a <= 22000000000000.0: tmp = t else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -5.3e+20) tmp = x; elseif (a <= 22000000000000.0) tmp = t; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -5.3e+20) tmp = x; elseif (a <= 22000000000000.0) tmp = t; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -5.3e+20], x, If[LessEqual[a, 22000000000000.0], t, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.3 \cdot 10^{+20}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 22000000000000:\\
\;\;\;\;t\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -5.3e20 or 2.2e13 < a Initial program 90.2%
Taylor expanded in a around inf 45.1%
if -5.3e20 < a < 2.2e13Initial program 60.8%
Taylor expanded in z around inf 38.5%
Final simplification41.8%
(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 75.5%
Taylor expanded in z around inf 23.7%
Final simplification23.7%
herbie shell --seed 2024055
(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)))))