
(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 (* (- y z) (/ (- t x) (- a z))))) (t_2 (/ z (- t x))))
(if (or (<= t_1 -1e-285) (not (<= t_1 0.0)))
(fma (- t x) (/ (- y z) (- a z)) x)
(+ (- t (/ y t_2)) (/ a t_2)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double t_2 = z / (t - x);
double tmp;
if ((t_1 <= -1e-285) || !(t_1 <= 0.0)) {
tmp = fma((t - x), ((y - z) / (a - z)), x);
} else {
tmp = (t - (y / t_2)) + (a / t_2);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) t_2 = Float64(z / Float64(t - x)) tmp = 0.0 if ((t_1 <= -1e-285) || !(t_1 <= 0.0)) tmp = fma(Float64(t - x), Float64(Float64(y - z) / Float64(a - z)), x); else tmp = Float64(Float64(t - Float64(y / t_2)) + Float64(a / t_2)); end return 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]}, Block[{t$95$2 = N[(z / N[(t - x), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -1e-285], 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[(N[(t - N[(y / t$95$2), $MachinePrecision]), $MachinePrecision] + N[(a / t$95$2), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
t_2 := \frac{z}{t - x}\\
\mathbf{if}\;t_1 \leq -1 \cdot 10^{-285} \lor \neg \left(t_1 \leq 0\right):\\
\;\;\;\;\mathsf{fma}\left(t - x, \frac{y - z}{a - z}, x\right)\\
\mathbf{else}:\\
\;\;\;\;\left(t - \frac{y}{t_2}\right) + \frac{a}{t_2}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -1.00000000000000007e-285 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 91.8%
+-commutative91.8%
associate-*r/78.7%
*-commutative78.7%
associate-*r/96.7%
fma-def96.7%
Simplified96.7%
if -1.00000000000000007e-285 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 4.0%
clear-num3.9%
un-div-inv4.1%
Applied egg-rr4.1%
Taylor expanded in z around inf 99.7%
sub-neg99.7%
+-commutative99.7%
mul-1-neg99.7%
unsub-neg99.7%
associate-/l*99.8%
mul-1-neg99.8%
remove-double-neg99.8%
associate-/l*99.8%
Simplified99.8%
Final simplification96.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (or (<= t_1 -1e-285) (not (<= t_1 1e-256)))
(+ x (/ (- y z) (/ (- a z) (- t x))))
(- t (/ (+ (* y (- t x)) (* 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 <= -1e-285) || !(t_1 <= 1e-256)) {
tmp = x + ((y - z) / ((a - z) / (t - x)));
} else {
tmp = t - (((y * (t - x)) + (a * (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) :: t_1
real(8) :: tmp
t_1 = x + ((y - z) * ((t - x) / (a - z)))
if ((t_1 <= (-1d-285)) .or. (.not. (t_1 <= 1d-256))) then
tmp = x + ((y - z) / ((a - z) / (t - x)))
else
tmp = t - (((y * (t - x)) + (a * (x - t))) / 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 + ((y - z) * ((t - x) / (a - z)));
double tmp;
if ((t_1 <= -1e-285) || !(t_1 <= 1e-256)) {
tmp = x + ((y - z) / ((a - z) / (t - x)));
} else {
tmp = t - (((y * (t - x)) + (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 <= -1e-285) or not (t_1 <= 1e-256): tmp = x + ((y - z) / ((a - z) / (t - x))) else: tmp = t - (((y * (t - x)) + (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 <= -1e-285) || !(t_1 <= 1e-256)) tmp = Float64(x + Float64(Float64(y - z) / Float64(Float64(a - z) / Float64(t - x)))); else tmp = Float64(t - Float64(Float64(Float64(y * Float64(t - x)) + Float64(a * 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 <= -1e-285) || ~((t_1 <= 1e-256))) tmp = x + ((y - z) / ((a - z) / (t - x))); else tmp = t - (((y * (t - x)) + (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[Or[LessEqual[t$95$1, -1e-285], N[Not[LessEqual[t$95$1, 1e-256]], $MachinePrecision]], N[(x + N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t - N[(N[(N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision] + N[(a * N[(x - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $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 -1 \cdot 10^{-285} \lor \neg \left(t_1 \leq 10^{-256}\right):\\
\;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\
\mathbf{else}:\\
\;\;\;\;t - \frac{y \cdot \left(t - x\right) + a \cdot \left(x - t\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -1.00000000000000007e-285 or 9.99999999999999977e-257 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 92.5%
clear-num92.4%
un-div-inv92.8%
Applied egg-rr92.8%
if -1.00000000000000007e-285 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 9.99999999999999977e-257Initial program 8.0%
Taylor expanded in z around -inf 94.6%
Final simplification93.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (or (<= t_1 -1e-285) (not (<= t_1 1e-256)))
t_1
(+ t (/ (* (- t x) (- a y)) 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 <= -1e-285) || !(t_1 <= 1e-256)) {
tmp = t_1;
} else {
tmp = t + (((t - x) * (a - y)) / 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 + ((y - z) * ((t - x) / (a - z)))
if ((t_1 <= (-1d-285)) .or. (.not. (t_1 <= 1d-256))) then
tmp = t_1
else
tmp = t + (((t - x) * (a - y)) / 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 + ((y - z) * ((t - x) / (a - z)));
double tmp;
if ((t_1 <= -1e-285) || !(t_1 <= 1e-256)) {
tmp = t_1;
} else {
tmp = t + (((t - x) * (a - y)) / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if (t_1 <= -1e-285) or not (t_1 <= 1e-256): tmp = t_1 else: tmp = t + (((t - x) * (a - y)) / 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 <= -1e-285) || !(t_1 <= 1e-256)) tmp = t_1; else tmp = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / 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 <= -1e-285) || ~((t_1 <= 1e-256))) tmp = t_1; else tmp = t + (((t - x) * (a - y)) / 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[Or[LessEqual[t$95$1, -1e-285], N[Not[LessEqual[t$95$1, 1e-256]], $MachinePrecision]], t$95$1, N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $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 -1 \cdot 10^{-285} \lor \neg \left(t_1 \leq 10^{-256}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -1.00000000000000007e-285 or 9.99999999999999977e-257 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 92.5%
if -1.00000000000000007e-285 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 9.99999999999999977e-257Initial program 8.0%
Taylor expanded in z around inf 94.6%
+-commutative94.6%
associate--l+94.6%
associate-*r/94.6%
associate-*r/94.6%
div-sub94.6%
distribute-lft-out--94.6%
mul-1-neg94.6%
distribute-neg-frac94.6%
unsub-neg94.6%
distribute-rgt-out--94.5%
Simplified94.5%
Final simplification92.7%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
(if (or (<= t_1 -1e-285) (not (<= t_1 1e-256)))
(+ x (/ (- y z) (/ (- a z) (- t x))))
(+ t (/ (* (- t x) (- a y)) 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 <= -1e-285) || !(t_1 <= 1e-256)) {
tmp = x + ((y - z) / ((a - z) / (t - x)));
} else {
tmp = t + (((t - x) * (a - y)) / 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 + ((y - z) * ((t - x) / (a - z)))
if ((t_1 <= (-1d-285)) .or. (.not. (t_1 <= 1d-256))) then
tmp = x + ((y - z) / ((a - z) / (t - x)))
else
tmp = t + (((t - x) * (a - y)) / 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 + ((y - z) * ((t - x) / (a - z)));
double tmp;
if ((t_1 <= -1e-285) || !(t_1 <= 1e-256)) {
tmp = x + ((y - z) / ((a - z) / (t - x)));
} else {
tmp = t + (((t - x) * (a - y)) / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) * ((t - x) / (a - z))) tmp = 0 if (t_1 <= -1e-285) or not (t_1 <= 1e-256): tmp = x + ((y - z) / ((a - z) / (t - x))) else: tmp = t + (((t - x) * (a - y)) / 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 <= -1e-285) || !(t_1 <= 1e-256)) tmp = Float64(x + Float64(Float64(y - z) / Float64(Float64(a - z) / Float64(t - x)))); else tmp = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / 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 <= -1e-285) || ~((t_1 <= 1e-256))) tmp = x + ((y - z) / ((a - z) / (t - x))); else tmp = t + (((t - x) * (a - y)) / 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[Or[LessEqual[t$95$1, -1e-285], N[Not[LessEqual[t$95$1, 1e-256]], $MachinePrecision]], N[(x + N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $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 -1 \cdot 10^{-285} \lor \neg \left(t_1 \leq 10^{-256}\right):\\
\;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\
\mathbf{else}:\\
\;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -1.00000000000000007e-285 or 9.99999999999999977e-257 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 92.5%
clear-num92.4%
un-div-inv92.8%
Applied egg-rr92.8%
if -1.00000000000000007e-285 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 9.99999999999999977e-257Initial program 8.0%
Taylor expanded in z around inf 94.6%
+-commutative94.6%
associate--l+94.6%
associate-*r/94.6%
associate-*r/94.6%
div-sub94.6%
distribute-lft-out--94.6%
mul-1-neg94.6%
distribute-neg-frac94.6%
unsub-neg94.6%
distribute-rgt-out--94.5%
Simplified94.5%
Final simplification93.0%
(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 -4.5e+216)
t_2
(if (<= x -1.9e+152)
(/ (- y a) (/ z x))
(if (<= x -2.2e+81)
(* y (- (/ x (- a z))))
(if (<= x 1.05e-113)
t_1
(if (<= x 2.1e-82)
(- x (/ y (/ a x)))
(if (<= x 9e+50) 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 * (1.0 - (y / a));
double tmp;
if (x <= -4.5e+216) {
tmp = t_2;
} else if (x <= -1.9e+152) {
tmp = (y - a) / (z / x);
} else if (x <= -2.2e+81) {
tmp = y * -(x / (a - z));
} else if (x <= 1.05e-113) {
tmp = t_1;
} else if (x <= 2.1e-82) {
tmp = x - (y / (a / x));
} else if (x <= 9e+50) {
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 * (1.0d0 - (y / a))
if (x <= (-4.5d+216)) then
tmp = t_2
else if (x <= (-1.9d+152)) then
tmp = (y - a) / (z / x)
else if (x <= (-2.2d+81)) then
tmp = y * -(x / (a - z))
else if (x <= 1.05d-113) then
tmp = t_1
else if (x <= 2.1d-82) then
tmp = x - (y / (a / x))
else if (x <= 9d+50) 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 * (1.0 - (y / a));
double tmp;
if (x <= -4.5e+216) {
tmp = t_2;
} else if (x <= -1.9e+152) {
tmp = (y - a) / (z / x);
} else if (x <= -2.2e+81) {
tmp = y * -(x / (a - z));
} else if (x <= 1.05e-113) {
tmp = t_1;
} else if (x <= 2.1e-82) {
tmp = x - (y / (a / x));
} else if (x <= 9e+50) {
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 * (1.0 - (y / a)) tmp = 0 if x <= -4.5e+216: tmp = t_2 elif x <= -1.9e+152: tmp = (y - a) / (z / x) elif x <= -2.2e+81: tmp = y * -(x / (a - z)) elif x <= 1.05e-113: tmp = t_1 elif x <= 2.1e-82: tmp = x - (y / (a / x)) elif x <= 9e+50: 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(1.0 - Float64(y / a))) tmp = 0.0 if (x <= -4.5e+216) tmp = t_2; elseif (x <= -1.9e+152) tmp = Float64(Float64(y - a) / Float64(z / x)); elseif (x <= -2.2e+81) tmp = Float64(y * Float64(-Float64(x / Float64(a - z)))); elseif (x <= 1.05e-113) tmp = t_1; elseif (x <= 2.1e-82) tmp = Float64(x - Float64(y / Float64(a / x))); elseif (x <= 9e+50) 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 * (1.0 - (y / a)); tmp = 0.0; if (x <= -4.5e+216) tmp = t_2; elseif (x <= -1.9e+152) tmp = (y - a) / (z / x); elseif (x <= -2.2e+81) tmp = y * -(x / (a - z)); elseif (x <= 1.05e-113) tmp = t_1; elseif (x <= 2.1e-82) tmp = x - (y / (a / x)); elseif (x <= 9e+50) 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[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -4.5e+216], t$95$2, If[LessEqual[x, -1.9e+152], N[(N[(y - a), $MachinePrecision] / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -2.2e+81], N[(y * (-N[(x / N[(a - z), $MachinePrecision]), $MachinePrecision])), $MachinePrecision], If[LessEqual[x, 1.05e-113], t$95$1, If[LessEqual[x, 2.1e-82], N[(x - N[(y / N[(a / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 9e+50], t$95$1, t$95$2]]]]]]]]
\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 -4.5 \cdot 10^{+216}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -1.9 \cdot 10^{+152}:\\
\;\;\;\;\frac{y - a}{\frac{z}{x}}\\
\mathbf{elif}\;x \leq -2.2 \cdot 10^{+81}:\\
\;\;\;\;y \cdot \left(-\frac{x}{a - z}\right)\\
\mathbf{elif}\;x \leq 1.05 \cdot 10^{-113}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{-82}:\\
\;\;\;\;x - \frac{y}{\frac{a}{x}}\\
\mathbf{elif}\;x \leq 9 \cdot 10^{+50}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if x < -4.50000000000000025e216 or 9.00000000000000027e50 < x Initial program 86.2%
Taylor expanded in z around 0 57.2%
Taylor expanded in x around inf 67.6%
*-commutative67.6%
mul-1-neg67.6%
unsub-neg67.6%
Simplified67.6%
if -4.50000000000000025e216 < x < -1.9e152Initial program 55.2%
Taylor expanded in z around inf 84.9%
+-commutative84.9%
associate--l+84.9%
associate-*r/84.9%
associate-*r/84.9%
div-sub85.2%
distribute-lft-out--85.2%
mul-1-neg85.2%
distribute-neg-frac85.2%
unsub-neg85.2%
distribute-rgt-out--85.2%
Simplified85.2%
Taylor expanded in t around 0 85.2%
associate-/l*85.4%
Simplified85.4%
if -1.9e152 < x < -2.19999999999999987e81Initial program 84.8%
Taylor expanded in y around inf 62.7%
Taylor expanded in t around 0 62.2%
neg-mul-162.2%
distribute-neg-frac62.2%
Simplified62.2%
if -2.19999999999999987e81 < x < 1.05e-113 or 2.1e-82 < x < 9.00000000000000027e50Initial program 85.2%
Taylor expanded in t around inf 74.3%
div-sub74.3%
Simplified74.3%
if 1.05e-113 < x < 2.1e-82Initial program 100.0%
Taylor expanded in z around 0 85.6%
Taylor expanded in t around 0 83.4%
+-commutative83.4%
mul-1-neg83.4%
unsub-neg83.4%
associate-/l*83.6%
Simplified83.6%
Final simplification72.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 -4.2e+212)
t_2
(if (<= x -3e+154)
(/ (- y a) (/ z x))
(if (<= x -1.15e+80)
(* (- t x) (/ y (- a z)))
(if (<= x 1.05e-113)
t_1
(if (<= x 2.1e-82)
(- x (/ y (/ a x)))
(if (<= x 6.2e+50) 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 * (1.0 - (y / a));
double tmp;
if (x <= -4.2e+212) {
tmp = t_2;
} else if (x <= -3e+154) {
tmp = (y - a) / (z / x);
} else if (x <= -1.15e+80) {
tmp = (t - x) * (y / (a - z));
} else if (x <= 1.05e-113) {
tmp = t_1;
} else if (x <= 2.1e-82) {
tmp = x - (y / (a / x));
} else if (x <= 6.2e+50) {
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 * (1.0d0 - (y / a))
if (x <= (-4.2d+212)) then
tmp = t_2
else if (x <= (-3d+154)) then
tmp = (y - a) / (z / x)
else if (x <= (-1.15d+80)) then
tmp = (t - x) * (y / (a - z))
else if (x <= 1.05d-113) then
tmp = t_1
else if (x <= 2.1d-82) then
tmp = x - (y / (a / x))
else if (x <= 6.2d+50) 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 * (1.0 - (y / a));
double tmp;
if (x <= -4.2e+212) {
tmp = t_2;
} else if (x <= -3e+154) {
tmp = (y - a) / (z / x);
} else if (x <= -1.15e+80) {
tmp = (t - x) * (y / (a - z));
} else if (x <= 1.05e-113) {
tmp = t_1;
} else if (x <= 2.1e-82) {
tmp = x - (y / (a / x));
} else if (x <= 6.2e+50) {
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 * (1.0 - (y / a)) tmp = 0 if x <= -4.2e+212: tmp = t_2 elif x <= -3e+154: tmp = (y - a) / (z / x) elif x <= -1.15e+80: tmp = (t - x) * (y / (a - z)) elif x <= 1.05e-113: tmp = t_1 elif x <= 2.1e-82: tmp = x - (y / (a / x)) elif x <= 6.2e+50: 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(1.0 - Float64(y / a))) tmp = 0.0 if (x <= -4.2e+212) tmp = t_2; elseif (x <= -3e+154) tmp = Float64(Float64(y - a) / Float64(z / x)); elseif (x <= -1.15e+80) tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z))); elseif (x <= 1.05e-113) tmp = t_1; elseif (x <= 2.1e-82) tmp = Float64(x - Float64(y / Float64(a / x))); elseif (x <= 6.2e+50) 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 * (1.0 - (y / a)); tmp = 0.0; if (x <= -4.2e+212) tmp = t_2; elseif (x <= -3e+154) tmp = (y - a) / (z / x); elseif (x <= -1.15e+80) tmp = (t - x) * (y / (a - z)); elseif (x <= 1.05e-113) tmp = t_1; elseif (x <= 2.1e-82) tmp = x - (y / (a / x)); elseif (x <= 6.2e+50) 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[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -4.2e+212], t$95$2, If[LessEqual[x, -3e+154], N[(N[(y - a), $MachinePrecision] / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -1.15e+80], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.05e-113], t$95$1, If[LessEqual[x, 2.1e-82], N[(x - N[(y / N[(a / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 6.2e+50], t$95$1, t$95$2]]]]]]]]
\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 -4.2 \cdot 10^{+212}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -3 \cdot 10^{+154}:\\
\;\;\;\;\frac{y - a}{\frac{z}{x}}\\
\mathbf{elif}\;x \leq -1.15 \cdot 10^{+80}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\
\mathbf{elif}\;x \leq 1.05 \cdot 10^{-113}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{-82}:\\
\;\;\;\;x - \frac{y}{\frac{a}{x}}\\
\mathbf{elif}\;x \leq 6.2 \cdot 10^{+50}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if x < -4.2e212 or 6.20000000000000006e50 < x Initial program 86.2%
Taylor expanded in z around 0 57.2%
Taylor expanded in x around inf 67.6%
*-commutative67.6%
mul-1-neg67.6%
unsub-neg67.6%
Simplified67.6%
if -4.2e212 < x < -3.00000000000000026e154Initial program 55.2%
Taylor expanded in z around inf 84.9%
+-commutative84.9%
associate--l+84.9%
associate-*r/84.9%
associate-*r/84.9%
div-sub85.2%
distribute-lft-out--85.2%
mul-1-neg85.2%
distribute-neg-frac85.2%
unsub-neg85.2%
distribute-rgt-out--85.2%
Simplified85.2%
Taylor expanded in t around 0 85.2%
associate-/l*85.4%
Simplified85.4%
if -3.00000000000000026e154 < x < -1.15000000000000002e80Initial program 84.8%
clear-num84.8%
un-div-inv84.8%
Applied egg-rr84.8%
Taylor expanded in y around inf 62.7%
div-sub62.7%
associate-*l/55.7%
associate-*r/62.8%
*-commutative62.8%
Simplified62.8%
if -1.15000000000000002e80 < x < 1.05e-113 or 2.1e-82 < x < 6.20000000000000006e50Initial program 85.2%
Taylor expanded in t around inf 74.3%
div-sub74.3%
Simplified74.3%
if 1.05e-113 < x < 2.1e-82Initial program 100.0%
Taylor expanded in z around 0 85.6%
Taylor expanded in t around 0 83.4%
+-commutative83.4%
mul-1-neg83.4%
unsub-neg83.4%
associate-/l*83.6%
Simplified83.6%
Final simplification72.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* y t) a))))
(if (<= z -1.12e+196)
t
(if (<= z -2.9e-270)
t_1
(if (<= z 3.3e-252)
(* y (/ (- t x) a))
(if (<= z 3.1e-203)
t_1
(if (<= z 4.5e-150)
(* x (- 1.0 (/ y a)))
(if (<= z 1.3e-69) t_1 t))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y * t) / a);
double tmp;
if (z <= -1.12e+196) {
tmp = t;
} else if (z <= -2.9e-270) {
tmp = t_1;
} else if (z <= 3.3e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 3.1e-203) {
tmp = t_1;
} else if (z <= 4.5e-150) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.3e-69) {
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 = x + ((y * t) / a)
if (z <= (-1.12d+196)) then
tmp = t
else if (z <= (-2.9d-270)) then
tmp = t_1
else if (z <= 3.3d-252) then
tmp = y * ((t - x) / a)
else if (z <= 3.1d-203) then
tmp = t_1
else if (z <= 4.5d-150) then
tmp = x * (1.0d0 - (y / a))
else if (z <= 1.3d-69) 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 = x + ((y * t) / a);
double tmp;
if (z <= -1.12e+196) {
tmp = t;
} else if (z <= -2.9e-270) {
tmp = t_1;
} else if (z <= 3.3e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 3.1e-203) {
tmp = t_1;
} else if (z <= 4.5e-150) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.3e-69) {
tmp = t_1;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y * t) / a) tmp = 0 if z <= -1.12e+196: tmp = t elif z <= -2.9e-270: tmp = t_1 elif z <= 3.3e-252: tmp = y * ((t - x) / a) elif z <= 3.1e-203: tmp = t_1 elif z <= 4.5e-150: tmp = x * (1.0 - (y / a)) elif z <= 1.3e-69: tmp = t_1 else: tmp = t return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y * t) / a)) tmp = 0.0 if (z <= -1.12e+196) tmp = t; elseif (z <= -2.9e-270) tmp = t_1; elseif (z <= 3.3e-252) tmp = Float64(y * Float64(Float64(t - x) / a)); elseif (z <= 3.1e-203) tmp = t_1; elseif (z <= 4.5e-150) tmp = Float64(x * Float64(1.0 - Float64(y / a))); elseif (z <= 1.3e-69) tmp = t_1; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y * t) / a); tmp = 0.0; if (z <= -1.12e+196) tmp = t; elseif (z <= -2.9e-270) tmp = t_1; elseif (z <= 3.3e-252) tmp = y * ((t - x) / a); elseif (z <= 3.1e-203) tmp = t_1; elseif (z <= 4.5e-150) tmp = x * (1.0 - (y / a)); elseif (z <= 1.3e-69) tmp = t_1; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y * t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.12e+196], t, If[LessEqual[z, -2.9e-270], t$95$1, If[LessEqual[z, 3.3e-252], N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.1e-203], t$95$1, If[LessEqual[z, 4.5e-150], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.3e-69], t$95$1, t]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y \cdot t}{a}\\
\mathbf{if}\;z \leq -1.12 \cdot 10^{+196}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq -2.9 \cdot 10^{-270}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 3.3 \cdot 10^{-252}:\\
\;\;\;\;y \cdot \frac{t - x}{a}\\
\mathbf{elif}\;z \leq 3.1 \cdot 10^{-203}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{-150}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{elif}\;z \leq 1.3 \cdot 10^{-69}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -1.1199999999999999e196 or 1.3000000000000001e-69 < z Initial program 70.0%
Taylor expanded in z around inf 50.4%
if -1.1199999999999999e196 < z < -2.89999999999999983e-270 or 3.30000000000000009e-252 < z < 3.09999999999999977e-203 or 4.5000000000000002e-150 < z < 1.3000000000000001e-69Initial program 91.2%
Taylor expanded in z around 0 55.7%
Taylor expanded in t around inf 55.2%
if -2.89999999999999983e-270 < z < 3.30000000000000009e-252Initial program 94.7%
Taylor expanded in y around inf 79.6%
Taylor expanded in a around inf 79.6%
if 3.09999999999999977e-203 < z < 4.5000000000000002e-150Initial program 93.4%
Taylor expanded in z around 0 62.6%
Taylor expanded in x around inf 68.3%
*-commutative68.3%
mul-1-neg68.3%
unsub-neg68.3%
Simplified68.3%
Final simplification56.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* y t) a))) (t_2 (- t (/ y (/ z t)))))
(if (<= z -3.5e+149)
t_2
(if (<= z -2.6e-270)
t_1
(if (<= z 2.4e-252)
(* y (/ (- t x) a))
(if (<= z 1.7e-190)
t_1
(if (<= z 4.2e-144)
(* x (- 1.0 (/ y a)))
(if (<= z 1.8e-69) t_1 t_2))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y * t) / a);
double t_2 = t - (y / (z / t));
double tmp;
if (z <= -3.5e+149) {
tmp = t_2;
} else if (z <= -2.6e-270) {
tmp = t_1;
} else if (z <= 2.4e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 1.7e-190) {
tmp = t_1;
} else if (z <= 4.2e-144) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.8e-69) {
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 = x + ((y * t) / a)
t_2 = t - (y / (z / t))
if (z <= (-3.5d+149)) then
tmp = t_2
else if (z <= (-2.6d-270)) then
tmp = t_1
else if (z <= 2.4d-252) then
tmp = y * ((t - x) / a)
else if (z <= 1.7d-190) then
tmp = t_1
else if (z <= 4.2d-144) then
tmp = x * (1.0d0 - (y / a))
else if (z <= 1.8d-69) 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 = x + ((y * t) / a);
double t_2 = t - (y / (z / t));
double tmp;
if (z <= -3.5e+149) {
tmp = t_2;
} else if (z <= -2.6e-270) {
tmp = t_1;
} else if (z <= 2.4e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 1.7e-190) {
tmp = t_1;
} else if (z <= 4.2e-144) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.8e-69) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y * t) / a) t_2 = t - (y / (z / t)) tmp = 0 if z <= -3.5e+149: tmp = t_2 elif z <= -2.6e-270: tmp = t_1 elif z <= 2.4e-252: tmp = y * ((t - x) / a) elif z <= 1.7e-190: tmp = t_1 elif z <= 4.2e-144: tmp = x * (1.0 - (y / a)) elif z <= 1.8e-69: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y * t) / a)) t_2 = Float64(t - Float64(y / Float64(z / t))) tmp = 0.0 if (z <= -3.5e+149) tmp = t_2; elseif (z <= -2.6e-270) tmp = t_1; elseif (z <= 2.4e-252) tmp = Float64(y * Float64(Float64(t - x) / a)); elseif (z <= 1.7e-190) tmp = t_1; elseif (z <= 4.2e-144) tmp = Float64(x * Float64(1.0 - Float64(y / a))); elseif (z <= 1.8e-69) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y * t) / a); t_2 = t - (y / (z / t)); tmp = 0.0; if (z <= -3.5e+149) tmp = t_2; elseif (z <= -2.6e-270) tmp = t_1; elseif (z <= 2.4e-252) tmp = y * ((t - x) / a); elseif (z <= 1.7e-190) tmp = t_1; elseif (z <= 4.2e-144) tmp = x * (1.0 - (y / a)); elseif (z <= 1.8e-69) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y * t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t - N[(y / N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.5e+149], t$95$2, If[LessEqual[z, -2.6e-270], t$95$1, If[LessEqual[z, 2.4e-252], N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.7e-190], t$95$1, If[LessEqual[z, 4.2e-144], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.8e-69], t$95$1, t$95$2]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y \cdot t}{a}\\
t_2 := t - \frac{y}{\frac{z}{t}}\\
\mathbf{if}\;z \leq -3.5 \cdot 10^{+149}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;z \leq -2.6 \cdot 10^{-270}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{-252}:\\
\;\;\;\;y \cdot \frac{t - x}{a}\\
\mathbf{elif}\;z \leq 1.7 \cdot 10^{-190}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 4.2 \cdot 10^{-144}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{elif}\;z \leq 1.8 \cdot 10^{-69}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if z < -3.50000000000000011e149 or 1.80000000000000009e-69 < z Initial program 71.9%
Taylor expanded in x around 0 47.1%
associate-/l*68.5%
Simplified68.5%
Taylor expanded in a around 0 45.5%
associate-*r/45.5%
mul-1-neg45.5%
Simplified45.5%
Taylor expanded in y around 0 55.3%
+-commutative55.3%
mul-1-neg55.3%
unsub-neg55.3%
associate-/l*60.3%
Simplified60.3%
if -3.50000000000000011e149 < z < -2.6000000000000002e-270 or 2.4000000000000002e-252 < z < 1.69999999999999991e-190 or 4.2000000000000002e-144 < z < 1.80000000000000009e-69Initial program 91.2%
Taylor expanded in z around 0 57.1%
Taylor expanded in t around inf 55.9%
if -2.6000000000000002e-270 < z < 2.4000000000000002e-252Initial program 94.7%
Taylor expanded in y around inf 79.6%
Taylor expanded in a around inf 79.6%
if 1.69999999999999991e-190 < z < 4.2000000000000002e-144Initial program 93.4%
Taylor expanded in z around 0 62.6%
Taylor expanded in x around inf 68.3%
*-commutative68.3%
mul-1-neg68.3%
unsub-neg68.3%
Simplified68.3%
Final simplification60.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* y t) a))))
(if (<= z -3.5e+149)
(- t (/ y (/ z t)))
(if (<= z -1.25e-269)
t_1
(if (<= z 2.6e-252)
(* y (/ (- t x) a))
(if (<= z 1.45e-207)
t_1
(if (<= z 2.7e-154)
(* x (- 1.0 (/ y a)))
(if (<= z 1.6e-69) t_1 (/ t (/ z (- z y)))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y * t) / a);
double tmp;
if (z <= -3.5e+149) {
tmp = t - (y / (z / t));
} else if (z <= -1.25e-269) {
tmp = t_1;
} else if (z <= 2.6e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 1.45e-207) {
tmp = t_1;
} else if (z <= 2.7e-154) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.6e-69) {
tmp = t_1;
} else {
tmp = t / (z / (z - 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) :: t_1
real(8) :: tmp
t_1 = x + ((y * t) / a)
if (z <= (-3.5d+149)) then
tmp = t - (y / (z / t))
else if (z <= (-1.25d-269)) then
tmp = t_1
else if (z <= 2.6d-252) then
tmp = y * ((t - x) / a)
else if (z <= 1.45d-207) then
tmp = t_1
else if (z <= 2.7d-154) then
tmp = x * (1.0d0 - (y / a))
else if (z <= 1.6d-69) then
tmp = t_1
else
tmp = t / (z / (z - y))
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 * t) / a);
double tmp;
if (z <= -3.5e+149) {
tmp = t - (y / (z / t));
} else if (z <= -1.25e-269) {
tmp = t_1;
} else if (z <= 2.6e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 1.45e-207) {
tmp = t_1;
} else if (z <= 2.7e-154) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.6e-69) {
tmp = t_1;
} else {
tmp = t / (z / (z - y));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y * t) / a) tmp = 0 if z <= -3.5e+149: tmp = t - (y / (z / t)) elif z <= -1.25e-269: tmp = t_1 elif z <= 2.6e-252: tmp = y * ((t - x) / a) elif z <= 1.45e-207: tmp = t_1 elif z <= 2.7e-154: tmp = x * (1.0 - (y / a)) elif z <= 1.6e-69: tmp = t_1 else: tmp = t / (z / (z - y)) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y * t) / a)) tmp = 0.0 if (z <= -3.5e+149) tmp = Float64(t - Float64(y / Float64(z / t))); elseif (z <= -1.25e-269) tmp = t_1; elseif (z <= 2.6e-252) tmp = Float64(y * Float64(Float64(t - x) / a)); elseif (z <= 1.45e-207) tmp = t_1; elseif (z <= 2.7e-154) tmp = Float64(x * Float64(1.0 - Float64(y / a))); elseif (z <= 1.6e-69) tmp = t_1; else tmp = Float64(t / Float64(z / Float64(z - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y * t) / a); tmp = 0.0; if (z <= -3.5e+149) tmp = t - (y / (z / t)); elseif (z <= -1.25e-269) tmp = t_1; elseif (z <= 2.6e-252) tmp = y * ((t - x) / a); elseif (z <= 1.45e-207) tmp = t_1; elseif (z <= 2.7e-154) tmp = x * (1.0 - (y / a)); elseif (z <= 1.6e-69) tmp = t_1; else tmp = t / (z / (z - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y * t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.5e+149], N[(t - N[(y / N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.25e-269], t$95$1, If[LessEqual[z, 2.6e-252], N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.45e-207], t$95$1, If[LessEqual[z, 2.7e-154], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.6e-69], t$95$1, N[(t / N[(z / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y \cdot t}{a}\\
\mathbf{if}\;z \leq -3.5 \cdot 10^{+149}:\\
\;\;\;\;t - \frac{y}{\frac{z}{t}}\\
\mathbf{elif}\;z \leq -1.25 \cdot 10^{-269}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 2.6 \cdot 10^{-252}:\\
\;\;\;\;y \cdot \frac{t - x}{a}\\
\mathbf{elif}\;z \leq 1.45 \cdot 10^{-207}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 2.7 \cdot 10^{-154}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{elif}\;z \leq 1.6 \cdot 10^{-69}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{\frac{z}{z - y}}\\
\end{array}
\end{array}
if z < -3.50000000000000011e149Initial program 79.4%
Taylor expanded in x around 0 45.3%
associate-/l*74.2%
Simplified74.2%
Taylor expanded in a around 0 45.8%
associate-*r/45.8%
mul-1-neg45.8%
Simplified45.8%
Taylor expanded in y around 0 59.1%
+-commutative59.1%
mul-1-neg59.1%
unsub-neg59.1%
associate-/l*71.8%
Simplified71.8%
if -3.50000000000000011e149 < z < -1.24999999999999995e-269 or 2.5999999999999999e-252 < z < 1.45000000000000006e-207 or 2.69999999999999989e-154 < z < 1.59999999999999999e-69Initial program 91.2%
Taylor expanded in z around 0 57.1%
Taylor expanded in t around inf 55.9%
if -1.24999999999999995e-269 < z < 2.5999999999999999e-252Initial program 94.7%
Taylor expanded in y around inf 79.6%
Taylor expanded in a around inf 79.6%
if 1.45000000000000006e-207 < z < 2.69999999999999989e-154Initial program 93.4%
Taylor expanded in z around 0 62.6%
Taylor expanded in x around inf 68.3%
*-commutative68.3%
mul-1-neg68.3%
unsub-neg68.3%
Simplified68.3%
if 1.59999999999999999e-69 < z Initial program 69.5%
Taylor expanded in x around 0 47.7%
associate-/l*66.7%
Simplified66.7%
Taylor expanded in a around 0 45.4%
associate-*r/45.4%
mul-1-neg45.4%
Simplified45.4%
Taylor expanded in t around inf 45.4%
associate-/l*57.5%
Simplified57.5%
Final simplification60.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* y t) a))))
(if (<= z -6e+27)
(/ t (/ (- z a) z))
(if (<= z -2.6e-270)
t_1
(if (<= z 3e-252)
(* y (/ (- t x) a))
(if (<= z 4.2e-209)
t_1
(if (<= z 2.6e-154)
(* x (- 1.0 (/ y a)))
(if (<= z 1.75e-69) t_1 (/ t (/ z (- z y)))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y * t) / a);
double tmp;
if (z <= -6e+27) {
tmp = t / ((z - a) / z);
} else if (z <= -2.6e-270) {
tmp = t_1;
} else if (z <= 3e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 4.2e-209) {
tmp = t_1;
} else if (z <= 2.6e-154) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.75e-69) {
tmp = t_1;
} else {
tmp = t / (z / (z - 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) :: t_1
real(8) :: tmp
t_1 = x + ((y * t) / a)
if (z <= (-6d+27)) then
tmp = t / ((z - a) / z)
else if (z <= (-2.6d-270)) then
tmp = t_1
else if (z <= 3d-252) then
tmp = y * ((t - x) / a)
else if (z <= 4.2d-209) then
tmp = t_1
else if (z <= 2.6d-154) then
tmp = x * (1.0d0 - (y / a))
else if (z <= 1.75d-69) then
tmp = t_1
else
tmp = t / (z / (z - y))
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 * t) / a);
double tmp;
if (z <= -6e+27) {
tmp = t / ((z - a) / z);
} else if (z <= -2.6e-270) {
tmp = t_1;
} else if (z <= 3e-252) {
tmp = y * ((t - x) / a);
} else if (z <= 4.2e-209) {
tmp = t_1;
} else if (z <= 2.6e-154) {
tmp = x * (1.0 - (y / a));
} else if (z <= 1.75e-69) {
tmp = t_1;
} else {
tmp = t / (z / (z - y));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y * t) / a) tmp = 0 if z <= -6e+27: tmp = t / ((z - a) / z) elif z <= -2.6e-270: tmp = t_1 elif z <= 3e-252: tmp = y * ((t - x) / a) elif z <= 4.2e-209: tmp = t_1 elif z <= 2.6e-154: tmp = x * (1.0 - (y / a)) elif z <= 1.75e-69: tmp = t_1 else: tmp = t / (z / (z - y)) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y * t) / a)) tmp = 0.0 if (z <= -6e+27) tmp = Float64(t / Float64(Float64(z - a) / z)); elseif (z <= -2.6e-270) tmp = t_1; elseif (z <= 3e-252) tmp = Float64(y * Float64(Float64(t - x) / a)); elseif (z <= 4.2e-209) tmp = t_1; elseif (z <= 2.6e-154) tmp = Float64(x * Float64(1.0 - Float64(y / a))); elseif (z <= 1.75e-69) tmp = t_1; else tmp = Float64(t / Float64(z / Float64(z - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y * t) / a); tmp = 0.0; if (z <= -6e+27) tmp = t / ((z - a) / z); elseif (z <= -2.6e-270) tmp = t_1; elseif (z <= 3e-252) tmp = y * ((t - x) / a); elseif (z <= 4.2e-209) tmp = t_1; elseif (z <= 2.6e-154) tmp = x * (1.0 - (y / a)); elseif (z <= 1.75e-69) tmp = t_1; else tmp = t / (z / (z - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y * t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -6e+27], N[(t / N[(N[(z - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2.6e-270], t$95$1, If[LessEqual[z, 3e-252], N[(y * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.2e-209], t$95$1, If[LessEqual[z, 2.6e-154], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.75e-69], t$95$1, N[(t / N[(z / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y \cdot t}{a}\\
\mathbf{if}\;z \leq -6 \cdot 10^{+27}:\\
\;\;\;\;\frac{t}{\frac{z - a}{z}}\\
\mathbf{elif}\;z \leq -2.6 \cdot 10^{-270}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 3 \cdot 10^{-252}:\\
\;\;\;\;y \cdot \frac{t - x}{a}\\
\mathbf{elif}\;z \leq 4.2 \cdot 10^{-209}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 2.6 \cdot 10^{-154}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{elif}\;z \leq 1.75 \cdot 10^{-69}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{\frac{z}{z - y}}\\
\end{array}
\end{array}
if z < -5.99999999999999953e27Initial program 83.0%
Taylor expanded in x around 0 41.2%
associate-/l*64.2%
Simplified64.2%
Taylor expanded in y around 0 52.7%
associate-*r/52.7%
neg-mul-152.7%
Simplified52.7%
if -5.99999999999999953e27 < z < -2.6000000000000002e-270 or 2.99999999999999995e-252 < z < 4.19999999999999991e-209 or 2.6e-154 < z < 1.7500000000000001e-69Initial program 91.9%
Taylor expanded in z around 0 63.4%
Taylor expanded in t around inf 60.8%
if -2.6000000000000002e-270 < z < 2.99999999999999995e-252Initial program 94.7%
Taylor expanded in y around inf 79.6%
Taylor expanded in a around inf 79.6%
if 4.19999999999999991e-209 < z < 2.6e-154Initial program 93.4%
Taylor expanded in z around 0 62.6%
Taylor expanded in x around inf 68.3%
*-commutative68.3%
mul-1-neg68.3%
unsub-neg68.3%
Simplified68.3%
if 1.7500000000000001e-69 < z Initial program 69.5%
Taylor expanded in x around 0 47.7%
associate-/l*66.7%
Simplified66.7%
Taylor expanded in a around 0 45.4%
associate-*r/45.4%
mul-1-neg45.4%
Simplified45.4%
Taylor expanded in t around inf 45.4%
associate-/l*57.5%
Simplified57.5%
Final simplification60.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (- y z) (/ (- a z) t)))))
(if (<= a -4.5e-40)
t_1
(if (<= a 6.4e-125)
(+ t (/ (* y (- x t)) z))
(if (or (<= a 1.15e+70) (not (<= a 2.8e+105)))
t_1
(+ x (/ y (/ a (- t x)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) / ((a - z) / t));
double tmp;
if (a <= -4.5e-40) {
tmp = t_1;
} else if (a <= 6.4e-125) {
tmp = t + ((y * (x - t)) / z);
} else if ((a <= 1.15e+70) || !(a <= 2.8e+105)) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = x + ((y - z) / ((a - z) / t))
if (a <= (-4.5d-40)) then
tmp = t_1
else if (a <= 6.4d-125) then
tmp = t + ((y * (x - t)) / z)
else if ((a <= 1.15d+70) .or. (.not. (a <= 2.8d+105))) then
tmp = t_1
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 t_1 = x + ((y - z) / ((a - z) / t));
double tmp;
if (a <= -4.5e-40) {
tmp = t_1;
} else if (a <= 6.4e-125) {
tmp = t + ((y * (x - t)) / z);
} else if ((a <= 1.15e+70) || !(a <= 2.8e+105)) {
tmp = t_1;
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) / ((a - z) / t)) tmp = 0 if a <= -4.5e-40: tmp = t_1 elif a <= 6.4e-125: tmp = t + ((y * (x - t)) / z) elif (a <= 1.15e+70) or not (a <= 2.8e+105): tmp = t_1 else: tmp = x + (y / (a / (t - x))) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) / Float64(Float64(a - z) / t))) tmp = 0.0 if (a <= -4.5e-40) tmp = t_1; elseif (a <= 6.4e-125) tmp = Float64(t + Float64(Float64(y * Float64(x - t)) / z)); elseif ((a <= 1.15e+70) || !(a <= 2.8e+105)) tmp = t_1; else tmp = Float64(x + Float64(y / Float64(a / Float64(t - x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - z) / ((a - z) / t)); tmp = 0.0; if (a <= -4.5e-40) tmp = t_1; elseif (a <= 6.4e-125) tmp = t + ((y * (x - t)) / z); elseif ((a <= 1.15e+70) || ~((a <= 2.8e+105))) tmp = t_1; else tmp = x + (y / (a / (t - x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -4.5e-40], t$95$1, If[LessEqual[a, 6.4e-125], N[(t + N[(N[(y * N[(x - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[a, 1.15e+70], N[Not[LessEqual[a, 2.8e+105]], $MachinePrecision]], t$95$1, N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y - z}{\frac{a - z}{t}}\\
\mathbf{if}\;a \leq -4.5 \cdot 10^{-40}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq 6.4 \cdot 10^{-125}:\\
\;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\
\mathbf{elif}\;a \leq 1.15 \cdot 10^{+70} \lor \neg \left(a \leq 2.8 \cdot 10^{+105}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if a < -4.5000000000000001e-40 or 6.3999999999999997e-125 < a < 1.14999999999999997e70 or 2.8000000000000001e105 < a Initial program 89.4%
clear-num89.3%
un-div-inv89.4%
Applied egg-rr89.4%
Taylor expanded in t around inf 77.6%
if -4.5000000000000001e-40 < a < 6.3999999999999997e-125Initial program 73.0%
Taylor expanded in z around inf 84.7%
+-commutative84.7%
associate--l+84.7%
associate-*r/84.7%
associate-*r/84.7%
div-sub84.7%
distribute-lft-out--84.7%
mul-1-neg84.7%
distribute-neg-frac84.7%
unsub-neg84.7%
distribute-rgt-out--84.7%
Simplified84.7%
Taylor expanded in y around inf 80.2%
if 1.14999999999999997e70 < a < 2.8000000000000001e105Initial program 99.6%
clear-num99.8%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in z around 0 60.9%
+-commutative60.9%
associate-/l*99.8%
Simplified99.8%
Final simplification79.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (- y z) (/ (- a z) t)))))
(if (<= a -8.2e-37)
t_1
(if (<= a 3e-126)
(+ t (/ (* (- t x) (- a y)) z))
(if (or (<= a 9.2e+69) (not (<= a 7e+105)))
t_1
(+ x (/ y (/ a (- t x)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) / ((a - z) / t));
double tmp;
if (a <= -8.2e-37) {
tmp = t_1;
} else if (a <= 3e-126) {
tmp = t + (((t - x) * (a - y)) / z);
} else if ((a <= 9.2e+69) || !(a <= 7e+105)) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = x + ((y - z) / ((a - z) / t))
if (a <= (-8.2d-37)) then
tmp = t_1
else if (a <= 3d-126) then
tmp = t + (((t - x) * (a - y)) / z)
else if ((a <= 9.2d+69) .or. (.not. (a <= 7d+105))) then
tmp = t_1
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 t_1 = x + ((y - z) / ((a - z) / t));
double tmp;
if (a <= -8.2e-37) {
tmp = t_1;
} else if (a <= 3e-126) {
tmp = t + (((t - x) * (a - y)) / z);
} else if ((a <= 9.2e+69) || !(a <= 7e+105)) {
tmp = t_1;
} else {
tmp = x + (y / (a / (t - x)));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) / ((a - z) / t)) tmp = 0 if a <= -8.2e-37: tmp = t_1 elif a <= 3e-126: tmp = t + (((t - x) * (a - y)) / z) elif (a <= 9.2e+69) or not (a <= 7e+105): tmp = t_1 else: tmp = x + (y / (a / (t - x))) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) / Float64(Float64(a - z) / t))) tmp = 0.0 if (a <= -8.2e-37) tmp = t_1; elseif (a <= 3e-126) tmp = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / z)); elseif ((a <= 9.2e+69) || !(a <= 7e+105)) tmp = t_1; else tmp = Float64(x + Float64(y / Float64(a / Float64(t - x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - z) / ((a - z) / t)); tmp = 0.0; if (a <= -8.2e-37) tmp = t_1; elseif (a <= 3e-126) tmp = t + (((t - x) * (a - y)) / z); elseif ((a <= 9.2e+69) || ~((a <= 7e+105))) tmp = t_1; else tmp = x + (y / (a / (t - x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -8.2e-37], t$95$1, If[LessEqual[a, 3e-126], N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[a, 9.2e+69], N[Not[LessEqual[a, 7e+105]], $MachinePrecision]], t$95$1, N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y - z}{\frac{a - z}{t}}\\
\mathbf{if}\;a \leq -8.2 \cdot 10^{-37}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq 3 \cdot 10^{-126}:\\
\;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\
\mathbf{elif}\;a \leq 9.2 \cdot 10^{+69} \lor \neg \left(a \leq 7 \cdot 10^{+105}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if a < -8.1999999999999996e-37 or 3.0000000000000002e-126 < a < 9.20000000000000067e69 or 6.99999999999999982e105 < a Initial program 89.4%
clear-num89.3%
un-div-inv89.4%
Applied egg-rr89.4%
Taylor expanded in t around inf 77.6%
if -8.1999999999999996e-37 < a < 3.0000000000000002e-126Initial program 73.0%
Taylor expanded in z around inf 84.7%
+-commutative84.7%
associate--l+84.7%
associate-*r/84.7%
associate-*r/84.7%
div-sub84.7%
distribute-lft-out--84.7%
mul-1-neg84.7%
distribute-neg-frac84.7%
unsub-neg84.7%
distribute-rgt-out--84.7%
Simplified84.7%
if 9.20000000000000067e69 < a < 6.99999999999999982e105Initial program 99.6%
clear-num99.8%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in z around 0 60.9%
+-commutative60.9%
associate-/l*99.8%
Simplified99.8%
Final simplification80.5%
(FPCore (x y z t a)
:precision binary64
(if (or (<= z -118.0)
(not (or (<= z -5.4e-74) (and (not (<= z -7.4e-91)) (<= z 8.2e-38)))))
(* 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 <= -118.0) || !((z <= -5.4e-74) || (!(z <= -7.4e-91) && (z <= 8.2e-38)))) {
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 <= (-118.0d0)) .or. (.not. (z <= (-5.4d-74)) .or. (.not. (z <= (-7.4d-91))) .and. (z <= 8.2d-38))) 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 <= -118.0) || !((z <= -5.4e-74) || (!(z <= -7.4e-91) && (z <= 8.2e-38)))) {
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 <= -118.0) or not ((z <= -5.4e-74) or (not (z <= -7.4e-91) and (z <= 8.2e-38))): 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 <= -118.0) || !((z <= -5.4e-74) || (!(z <= -7.4e-91) && (z <= 8.2e-38)))) 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 <= -118.0) || ~(((z <= -5.4e-74) || (~((z <= -7.4e-91)) && (z <= 8.2e-38))))) 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, -118.0], N[Not[Or[LessEqual[z, -5.4e-74], And[N[Not[LessEqual[z, -7.4e-91]], $MachinePrecision], LessEqual[z, 8.2e-38]]]], $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 -118 \lor \neg \left(z \leq -5.4 \cdot 10^{-74} \lor \neg \left(z \leq -7.4 \cdot 10^{-91}\right) \land z \leq 8.2 \cdot 10^{-38}\right):\\
\;\;\;\;t \cdot \frac{y - z}{a - z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\
\end{array}
\end{array}
if z < -118 or -5.40000000000000036e-74 < z < -7.4000000000000004e-91 or 8.1999999999999996e-38 < z Initial program 75.2%
Taylor expanded in t around inf 66.6%
div-sub66.6%
Simplified66.6%
if -118 < z < -5.40000000000000036e-74 or -7.4000000000000004e-91 < z < 8.1999999999999996e-38Initial program 93.2%
clear-num93.2%
un-div-inv93.7%
Applied egg-rr93.7%
Taylor expanded in z around 0 70.2%
+-commutative70.2%
associate-/l*78.2%
Simplified78.2%
Final simplification72.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (- 1.0 (/ y a)))))
(if (<= z -1.45e+159)
t
(if (<= z 1.15e-236)
t_1
(if (<= z 2.45e-189) (* y (/ t (- a z))) (if (<= z 8.8e-37) t_1 t))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (y / a));
double tmp;
if (z <= -1.45e+159) {
tmp = t;
} else if (z <= 1.15e-236) {
tmp = t_1;
} else if (z <= 2.45e-189) {
tmp = y * (t / (a - z));
} else if (z <= 8.8e-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 = x * (1.0d0 - (y / a))
if (z <= (-1.45d+159)) then
tmp = t
else if (z <= 1.15d-236) then
tmp = t_1
else if (z <= 2.45d-189) then
tmp = y * (t / (a - z))
else if (z <= 8.8d-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 = x * (1.0 - (y / a));
double tmp;
if (z <= -1.45e+159) {
tmp = t;
} else if (z <= 1.15e-236) {
tmp = t_1;
} else if (z <= 2.45e-189) {
tmp = y * (t / (a - z));
} else if (z <= 8.8e-37) {
tmp = t_1;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (1.0 - (y / a)) tmp = 0 if z <= -1.45e+159: tmp = t elif z <= 1.15e-236: tmp = t_1 elif z <= 2.45e-189: tmp = y * (t / (a - z)) elif z <= 8.8e-37: tmp = t_1 else: tmp = t return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(1.0 - Float64(y / a))) tmp = 0.0 if (z <= -1.45e+159) tmp = t; elseif (z <= 1.15e-236) tmp = t_1; elseif (z <= 2.45e-189) tmp = Float64(y * Float64(t / Float64(a - z))); elseif (z <= 8.8e-37) tmp = t_1; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (1.0 - (y / a)); tmp = 0.0; if (z <= -1.45e+159) tmp = t; elseif (z <= 1.15e-236) tmp = t_1; elseif (z <= 2.45e-189) tmp = y * (t / (a - z)); elseif (z <= 8.8e-37) tmp = t_1; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.45e+159], t, If[LessEqual[z, 1.15e-236], t$95$1, If[LessEqual[z, 2.45e-189], N[(y * N[(t / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.8e-37], t$95$1, t]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{if}\;z \leq -1.45 \cdot 10^{+159}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq 1.15 \cdot 10^{-236}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 2.45 \cdot 10^{-189}:\\
\;\;\;\;y \cdot \frac{t}{a - z}\\
\mathbf{elif}\;z \leq 8.8 \cdot 10^{-37}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -1.45000000000000007e159 or 8.80000000000000008e-37 < z Initial program 70.8%
Taylor expanded in z around inf 51.5%
if -1.45000000000000007e159 < z < 1.15000000000000003e-236 or 2.4499999999999999e-189 < z < 8.80000000000000008e-37Initial program 91.1%
Taylor expanded in z around 0 60.7%
Taylor expanded in x around inf 52.2%
*-commutative52.2%
mul-1-neg52.2%
unsub-neg52.2%
Simplified52.2%
if 1.15000000000000003e-236 < z < 2.4499999999999999e-189Initial program 100.0%
Taylor expanded in y around inf 78.6%
Taylor expanded in t around inf 68.4%
Final simplification52.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ y (/ a (- t x))))))
(if (<= a -6.6e-40)
t_1
(if (<= a 4.6e-139)
(+ t (/ (* y (- x t)) z))
(if (<= a 1.85e+68) (* t (/ (- y z) (- a z))) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y / (a / (t - x)));
double tmp;
if (a <= -6.6e-40) {
tmp = t_1;
} else if (a <= 4.6e-139) {
tmp = t + ((y * (x - t)) / z);
} else if (a <= 1.85e+68) {
tmp = t * ((y - z) / (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 + (y / (a / (t - x)))
if (a <= (-6.6d-40)) then
tmp = t_1
else if (a <= 4.6d-139) then
tmp = t + ((y * (x - t)) / z)
else if (a <= 1.85d+68) then
tmp = t * ((y - z) / (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 + (y / (a / (t - x)));
double tmp;
if (a <= -6.6e-40) {
tmp = t_1;
} else if (a <= 4.6e-139) {
tmp = t + ((y * (x - t)) / z);
} else if (a <= 1.85e+68) {
tmp = t * ((y - z) / (a - z));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (y / (a / (t - x))) tmp = 0 if a <= -6.6e-40: tmp = t_1 elif a <= 4.6e-139: tmp = t + ((y * (x - t)) / z) elif a <= 1.85e+68: tmp = t * ((y - z) / (a - z)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(y / Float64(a / Float64(t - x)))) tmp = 0.0 if (a <= -6.6e-40) tmp = t_1; elseif (a <= 4.6e-139) tmp = Float64(t + Float64(Float64(y * Float64(x - t)) / z)); elseif (a <= 1.85e+68) tmp = Float64(t * Float64(Float64(y - z) / Float64(a - z))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (y / (a / (t - x))); tmp = 0.0; if (a <= -6.6e-40) tmp = t_1; elseif (a <= 4.6e-139) tmp = t + ((y * (x - t)) / z); elseif (a <= 1.85e+68) tmp = t * ((y - z) / (a - z)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -6.6e-40], t$95$1, If[LessEqual[a, 4.6e-139], N[(t + N[(N[(y * N[(x - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.85e+68], N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y}{\frac{a}{t - x}}\\
\mathbf{if}\;a \leq -6.6 \cdot 10^{-40}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq 4.6 \cdot 10^{-139}:\\
\;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\
\mathbf{elif}\;a \leq 1.85 \cdot 10^{+68}:\\
\;\;\;\;t \cdot \frac{y - z}{a - z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if a < -6.59999999999999986e-40 or 1.84999999999999999e68 < a Initial program 94.0%
clear-num93.9%
un-div-inv93.9%
Applied egg-rr93.9%
Taylor expanded in z around 0 58.2%
+-commutative58.2%
associate-/l*77.1%
Simplified77.1%
if -6.59999999999999986e-40 < a < 4.60000000000000025e-139Initial program 73.9%
Taylor expanded in z around inf 84.5%
+-commutative84.5%
associate--l+84.5%
associate-*r/84.5%
associate-*r/84.5%
div-sub84.5%
distribute-lft-out--84.5%
mul-1-neg84.5%
distribute-neg-frac84.5%
unsub-neg84.5%
distribute-rgt-out--84.5%
Simplified84.5%
Taylor expanded in y around inf 80.0%
if 4.60000000000000025e-139 < a < 1.84999999999999999e68Initial program 80.3%
Taylor expanded in t around inf 62.9%
div-sub62.9%
Simplified62.9%
Final simplification74.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ y (/ a (- t x))))))
(if (<= a -9e-37)
t_1
(if (<= a 5.8e-136)
(+ t (/ (* y (- x t)) z))
(if (<= a 2.6e+69) (/ t (/ (- a z) (- y z))) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y / (a / (t - x)));
double tmp;
if (a <= -9e-37) {
tmp = t_1;
} else if (a <= 5.8e-136) {
tmp = t + ((y * (x - t)) / z);
} else if (a <= 2.6e+69) {
tmp = t / ((a - z) / (y - 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 + (y / (a / (t - x)))
if (a <= (-9d-37)) then
tmp = t_1
else if (a <= 5.8d-136) then
tmp = t + ((y * (x - t)) / z)
else if (a <= 2.6d+69) then
tmp = t / ((a - z) / (y - 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 + (y / (a / (t - x)));
double tmp;
if (a <= -9e-37) {
tmp = t_1;
} else if (a <= 5.8e-136) {
tmp = t + ((y * (x - t)) / z);
} else if (a <= 2.6e+69) {
tmp = t / ((a - z) / (y - z));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (y / (a / (t - x))) tmp = 0 if a <= -9e-37: tmp = t_1 elif a <= 5.8e-136: tmp = t + ((y * (x - t)) / z) elif a <= 2.6e+69: tmp = t / ((a - z) / (y - z)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(y / Float64(a / Float64(t - x)))) tmp = 0.0 if (a <= -9e-37) tmp = t_1; elseif (a <= 5.8e-136) tmp = Float64(t + Float64(Float64(y * Float64(x - t)) / z)); elseif (a <= 2.6e+69) tmp = Float64(t / Float64(Float64(a - z) / Float64(y - z))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (y / (a / (t - x))); tmp = 0.0; if (a <= -9e-37) tmp = t_1; elseif (a <= 5.8e-136) tmp = t + ((y * (x - t)) / z); elseif (a <= 2.6e+69) tmp = t / ((a - z) / (y - z)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y / N[(a / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -9e-37], t$95$1, If[LessEqual[a, 5.8e-136], N[(t + N[(N[(y * N[(x - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.6e+69], N[(t / N[(N[(a - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y}{\frac{a}{t - x}}\\
\mathbf{if}\;a \leq -9 \cdot 10^{-37}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq 5.8 \cdot 10^{-136}:\\
\;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\
\mathbf{elif}\;a \leq 2.6 \cdot 10^{+69}:\\
\;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if a < -9.00000000000000081e-37 or 2.6000000000000002e69 < a Initial program 94.0%
clear-num93.9%
un-div-inv93.9%
Applied egg-rr93.9%
Taylor expanded in z around 0 58.2%
+-commutative58.2%
associate-/l*77.1%
Simplified77.1%
if -9.00000000000000081e-37 < a < 5.79999999999999989e-136Initial program 73.9%
Taylor expanded in z around inf 84.5%
+-commutative84.5%
associate--l+84.5%
associate-*r/84.5%
associate-*r/84.5%
div-sub84.5%
distribute-lft-out--84.5%
mul-1-neg84.5%
distribute-neg-frac84.5%
unsub-neg84.5%
distribute-rgt-out--84.5%
Simplified84.5%
Taylor expanded in y around inf 80.0%
if 5.79999999999999989e-136 < a < 2.6000000000000002e69Initial program 80.3%
Taylor expanded in x around 0 55.3%
associate-/l*62.9%
Simplified62.9%
Final simplification74.8%
(FPCore (x y z t a)
:precision binary64
(if (<= z -3.5e+149)
t
(if (<= z -2.95e-269)
x
(if (<= z 5.9e-291) (* y (/ t a)) (if (<= z 2.1e-77) x t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -3.5e+149) {
tmp = t;
} else if (z <= -2.95e-269) {
tmp = x;
} else if (z <= 5.9e-291) {
tmp = y * (t / a);
} else if (z <= 2.1e-77) {
tmp = x;
} 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 <= (-3.5d+149)) then
tmp = t
else if (z <= (-2.95d-269)) then
tmp = x
else if (z <= 5.9d-291) then
tmp = y * (t / a)
else if (z <= 2.1d-77) then
tmp = x
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 <= -3.5e+149) {
tmp = t;
} else if (z <= -2.95e-269) {
tmp = x;
} else if (z <= 5.9e-291) {
tmp = y * (t / a);
} else if (z <= 2.1e-77) {
tmp = x;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -3.5e+149: tmp = t elif z <= -2.95e-269: tmp = x elif z <= 5.9e-291: tmp = y * (t / a) elif z <= 2.1e-77: tmp = x else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -3.5e+149) tmp = t; elseif (z <= -2.95e-269) tmp = x; elseif (z <= 5.9e-291) tmp = Float64(y * Float64(t / a)); elseif (z <= 2.1e-77) tmp = x; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -3.5e+149) tmp = t; elseif (z <= -2.95e-269) tmp = x; elseif (z <= 5.9e-291) tmp = y * (t / a); elseif (z <= 2.1e-77) tmp = x; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -3.5e+149], t, If[LessEqual[z, -2.95e-269], x, If[LessEqual[z, 5.9e-291], N[(y * N[(t / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.1e-77], x, t]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.5 \cdot 10^{+149}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq -2.95 \cdot 10^{-269}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 5.9 \cdot 10^{-291}:\\
\;\;\;\;y \cdot \frac{t}{a}\\
\mathbf{elif}\;z \leq 2.1 \cdot 10^{-77}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -3.50000000000000011e149 or 2.10000000000000015e-77 < z Initial program 72.7%
Taylor expanded in z around inf 48.5%
if -3.50000000000000011e149 < z < -2.95e-269 or 5.89999999999999972e-291 < z < 2.10000000000000015e-77Initial program 91.7%
Taylor expanded in a around inf 37.4%
if -2.95e-269 < z < 5.89999999999999972e-291Initial program 92.3%
Taylor expanded in x around 0 40.4%
associate-/l*54.8%
Simplified54.8%
Taylor expanded in z around 0 50.8%
associate-/r/54.7%
Applied egg-rr54.7%
Final simplification42.6%
(FPCore (x y z t a)
:precision binary64
(if (<= z -7e+149)
t
(if (<= z -4.5e-268)
x
(if (<= z 2.7e-291) (/ y (/ a t)) (if (<= z 2.1e-77) x t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -7e+149) {
tmp = t;
} else if (z <= -4.5e-268) {
tmp = x;
} else if (z <= 2.7e-291) {
tmp = y / (a / t);
} else if (z <= 2.1e-77) {
tmp = x;
} 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 <= (-7d+149)) then
tmp = t
else if (z <= (-4.5d-268)) then
tmp = x
else if (z <= 2.7d-291) then
tmp = y / (a / t)
else if (z <= 2.1d-77) then
tmp = x
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 <= -7e+149) {
tmp = t;
} else if (z <= -4.5e-268) {
tmp = x;
} else if (z <= 2.7e-291) {
tmp = y / (a / t);
} else if (z <= 2.1e-77) {
tmp = x;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -7e+149: tmp = t elif z <= -4.5e-268: tmp = x elif z <= 2.7e-291: tmp = y / (a / t) elif z <= 2.1e-77: tmp = x else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -7e+149) tmp = t; elseif (z <= -4.5e-268) tmp = x; elseif (z <= 2.7e-291) tmp = Float64(y / Float64(a / t)); elseif (z <= 2.1e-77) tmp = x; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -7e+149) tmp = t; elseif (z <= -4.5e-268) tmp = x; elseif (z <= 2.7e-291) tmp = y / (a / t); elseif (z <= 2.1e-77) tmp = x; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -7e+149], t, If[LessEqual[z, -4.5e-268], x, If[LessEqual[z, 2.7e-291], N[(y / N[(a / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.1e-77], x, t]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7 \cdot 10^{+149}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq -4.5 \cdot 10^{-268}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 2.7 \cdot 10^{-291}:\\
\;\;\;\;\frac{y}{\frac{a}{t}}\\
\mathbf{elif}\;z \leq 2.1 \cdot 10^{-77}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -7.00000000000000023e149 or 2.10000000000000015e-77 < z Initial program 72.7%
Taylor expanded in z around inf 48.5%
if -7.00000000000000023e149 < z < -4.5000000000000001e-268 or 2.69999999999999992e-291 < z < 2.10000000000000015e-77Initial program 91.7%
Taylor expanded in a around inf 37.4%
if -4.5000000000000001e-268 < z < 2.69999999999999992e-291Initial program 92.3%
Taylor expanded in x around 0 40.4%
associate-/l*54.8%
Simplified54.8%
Taylor expanded in z around 0 36.4%
associate-/l*54.8%
Simplified54.8%
Final simplification42.6%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.45e+159) t (if (<= z 1.12e-37) (* x (- 1.0 (/ y a))) t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.45e+159) {
tmp = t;
} else if (z <= 1.12e-37) {
tmp = x * (1.0 - (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.45d+159)) then
tmp = t
else if (z <= 1.12d-37) then
tmp = x * (1.0d0 - (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.45e+159) {
tmp = t;
} else if (z <= 1.12e-37) {
tmp = x * (1.0 - (y / a));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.45e+159: tmp = t elif z <= 1.12e-37: tmp = x * (1.0 - (y / a)) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.45e+159) tmp = t; elseif (z <= 1.12e-37) tmp = Float64(x * Float64(1.0 - 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.45e+159) tmp = t; elseif (z <= 1.12e-37) tmp = x * (1.0 - (y / a)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.45e+159], t, If[LessEqual[z, 1.12e-37], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.45 \cdot 10^{+159}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq 1.12 \cdot 10^{-37}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -1.45000000000000007e159 or 1.12e-37 < z Initial program 70.8%
Taylor expanded in z around inf 51.5%
if -1.45000000000000007e159 < z < 1.12e-37Initial program 91.6%
Taylor expanded in z around 0 60.6%
Taylor expanded in x around inf 50.2%
*-commutative50.2%
mul-1-neg50.2%
unsub-neg50.2%
Simplified50.2%
Final simplification50.6%
(FPCore (x y z t a) :precision binary64 (if (<= z -3.5e+149) t (if (<= z 2.05e-77) x t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -3.5e+149) {
tmp = t;
} else if (z <= 2.05e-77) {
tmp = x;
} 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 <= (-3.5d+149)) then
tmp = t
else if (z <= 2.05d-77) then
tmp = x
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 <= -3.5e+149) {
tmp = t;
} else if (z <= 2.05e-77) {
tmp = x;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -3.5e+149: tmp = t elif z <= 2.05e-77: tmp = x else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -3.5e+149) tmp = t; elseif (z <= 2.05e-77) tmp = x; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -3.5e+149) tmp = t; elseif (z <= 2.05e-77) tmp = x; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -3.5e+149], t, If[LessEqual[z, 2.05e-77], x, t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.5 \cdot 10^{+149}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq 2.05 \cdot 10^{-77}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -3.50000000000000011e149 or 2.04999999999999981e-77 < z Initial program 72.7%
Taylor expanded in z around inf 48.5%
if -3.50000000000000011e149 < z < 2.04999999999999981e-77Initial program 91.7%
Taylor expanded in a around inf 35.3%
Final simplification40.4%
(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 84.3%
Taylor expanded in z around inf 23.8%
Final simplification23.8%
herbie shell --seed 2023238
(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)))))