
(FPCore (x y z t) :precision binary64 (/ (* x (- y z)) (- t z)))
double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = (x * (y - z)) / (t - z)
end function
public static double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
def code(x, y, z, t): return (x * (y - z)) / (t - z)
function code(x, y, z, t) return Float64(Float64(x * Float64(y - z)) / Float64(t - z)) end
function tmp = code(x, y, z, t) tmp = (x * (y - z)) / (t - z); end
code[x_, y_, z_, t_] := N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot \left(y - z\right)}{t - z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 17 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (/ (* x (- y z)) (- t z)))
double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = (x * (y - z)) / (t - z)
end function
public static double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
def code(x, y, z, t): return (x * (y - z)) / (t - z)
function code(x, y, z, t) return Float64(Float64(x * Float64(y - z)) / Float64(t - z)) end
function tmp = code(x, y, z, t) tmp = (x * (y - z)) / (t - z); end
code[x_, y_, z_, t_] := N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot \left(y - z\right)}{t - z}
\end{array}
(FPCore (x y z t) :precision binary64 (/ x (/ (- t z) (- y z))))
double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x / ((t - z) / (y - z))
end function
public static double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
def code(x, y, z, t): return x / ((t - z) / (y - z))
function code(x, y, z, t) return Float64(x / Float64(Float64(t - z) / Float64(y - z))) end
function tmp = code(x, y, z, t) tmp = x / ((t - z) / (y - z)); end
code[x_, y_, z_, t_] := N[(x / N[(N[(t - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\frac{t - z}{y - z}}
\end{array}
Initial program 84.8%
associate-/l*98.3%
Simplified98.3%
Final simplification98.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (/ (- y z) t))))
(if (<= z -4.1e+114)
x
(if (<= z -140000000.0)
t_1
(if (<= z -1.9e-21)
x
(if (<= z 2e-239)
t_1
(if (<= z 1.28e-95)
(* x (/ y (- t z)))
(if (<= z 8100000000.0) t_1 x))))))))
double code(double x, double y, double z, double t) {
double t_1 = x * ((y - z) / t);
double tmp;
if (z <= -4.1e+114) {
tmp = x;
} else if (z <= -140000000.0) {
tmp = t_1;
} else if (z <= -1.9e-21) {
tmp = x;
} else if (z <= 2e-239) {
tmp = t_1;
} else if (z <= 1.28e-95) {
tmp = x * (y / (t - z));
} else if (z <= 8100000000.0) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = x * ((y - z) / t)
if (z <= (-4.1d+114)) then
tmp = x
else if (z <= (-140000000.0d0)) then
tmp = t_1
else if (z <= (-1.9d-21)) then
tmp = x
else if (z <= 2d-239) then
tmp = t_1
else if (z <= 1.28d-95) then
tmp = x * (y / (t - z))
else if (z <= 8100000000.0d0) 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 t_1 = x * ((y - z) / t);
double tmp;
if (z <= -4.1e+114) {
tmp = x;
} else if (z <= -140000000.0) {
tmp = t_1;
} else if (z <= -1.9e-21) {
tmp = x;
} else if (z <= 2e-239) {
tmp = t_1;
} else if (z <= 1.28e-95) {
tmp = x * (y / (t - z));
} else if (z <= 8100000000.0) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): t_1 = x * ((y - z) / t) tmp = 0 if z <= -4.1e+114: tmp = x elif z <= -140000000.0: tmp = t_1 elif z <= -1.9e-21: tmp = x elif z <= 2e-239: tmp = t_1 elif z <= 1.28e-95: tmp = x * (y / (t - z)) elif z <= 8100000000.0: tmp = t_1 else: tmp = x return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(Float64(y - z) / t)) tmp = 0.0 if (z <= -4.1e+114) tmp = x; elseif (z <= -140000000.0) tmp = t_1; elseif (z <= -1.9e-21) tmp = x; elseif (z <= 2e-239) tmp = t_1; elseif (z <= 1.28e-95) tmp = Float64(x * Float64(y / Float64(t - z))); elseif (z <= 8100000000.0) tmp = t_1; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * ((y - z) / t); tmp = 0.0; if (z <= -4.1e+114) tmp = x; elseif (z <= -140000000.0) tmp = t_1; elseif (z <= -1.9e-21) tmp = x; elseif (z <= 2e-239) tmp = t_1; elseif (z <= 1.28e-95) tmp = x * (y / (t - z)); elseif (z <= 8100000000.0) tmp = t_1; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.1e+114], x, If[LessEqual[z, -140000000.0], t$95$1, If[LessEqual[z, -1.9e-21], x, If[LessEqual[z, 2e-239], t$95$1, If[LessEqual[z, 1.28e-95], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8100000000.0], t$95$1, x]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{y - z}{t}\\
\mathbf{if}\;z \leq -4.1 \cdot 10^{+114}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -140000000:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq -1.9 \cdot 10^{-21}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 2 \cdot 10^{-239}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 1.28 \cdot 10^{-95}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{elif}\;z \leq 8100000000:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -4.1000000000000001e114 or -1.4e8 < z < -1.8999999999999999e-21 or 8.1e9 < z Initial program 75.8%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 68.5%
if -4.1000000000000001e114 < z < -1.4e8 or -1.8999999999999999e-21 < z < 2.0000000000000002e-239 or 1.28000000000000005e-95 < z < 8.1e9Initial program 93.9%
associate-*r/96.8%
Simplified96.8%
Taylor expanded in t around inf 78.4%
if 2.0000000000000002e-239 < z < 1.28000000000000005e-95Initial program 90.4%
associate-*r/97.3%
Simplified97.3%
Taylor expanded in y around inf 80.4%
Final simplification74.0%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (/ (- y z) t))))
(if (<= z -1.55e+111)
x
(if (<= z -165000000.0)
t_1
(if (<= z -3.1e-21)
x
(if (<= z 1.9e-239)
(* (- y z) (/ x t))
(if (<= z 8.5e-94)
(* x (/ y (- t z)))
(if (<= z 5700000000.0) t_1 x))))))))
double code(double x, double y, double z, double t) {
double t_1 = x * ((y - z) / t);
double tmp;
if (z <= -1.55e+111) {
tmp = x;
} else if (z <= -165000000.0) {
tmp = t_1;
} else if (z <= -3.1e-21) {
tmp = x;
} else if (z <= 1.9e-239) {
tmp = (y - z) * (x / t);
} else if (z <= 8.5e-94) {
tmp = x * (y / (t - z));
} else if (z <= 5700000000.0) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = x * ((y - z) / t)
if (z <= (-1.55d+111)) then
tmp = x
else if (z <= (-165000000.0d0)) then
tmp = t_1
else if (z <= (-3.1d-21)) then
tmp = x
else if (z <= 1.9d-239) then
tmp = (y - z) * (x / t)
else if (z <= 8.5d-94) then
tmp = x * (y / (t - z))
else if (z <= 5700000000.0d0) 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 t_1 = x * ((y - z) / t);
double tmp;
if (z <= -1.55e+111) {
tmp = x;
} else if (z <= -165000000.0) {
tmp = t_1;
} else if (z <= -3.1e-21) {
tmp = x;
} else if (z <= 1.9e-239) {
tmp = (y - z) * (x / t);
} else if (z <= 8.5e-94) {
tmp = x * (y / (t - z));
} else if (z <= 5700000000.0) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): t_1 = x * ((y - z) / t) tmp = 0 if z <= -1.55e+111: tmp = x elif z <= -165000000.0: tmp = t_1 elif z <= -3.1e-21: tmp = x elif z <= 1.9e-239: tmp = (y - z) * (x / t) elif z <= 8.5e-94: tmp = x * (y / (t - z)) elif z <= 5700000000.0: tmp = t_1 else: tmp = x return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(Float64(y - z) / t)) tmp = 0.0 if (z <= -1.55e+111) tmp = x; elseif (z <= -165000000.0) tmp = t_1; elseif (z <= -3.1e-21) tmp = x; elseif (z <= 1.9e-239) tmp = Float64(Float64(y - z) * Float64(x / t)); elseif (z <= 8.5e-94) tmp = Float64(x * Float64(y / Float64(t - z))); elseif (z <= 5700000000.0) tmp = t_1; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * ((y - z) / t); tmp = 0.0; if (z <= -1.55e+111) tmp = x; elseif (z <= -165000000.0) tmp = t_1; elseif (z <= -3.1e-21) tmp = x; elseif (z <= 1.9e-239) tmp = (y - z) * (x / t); elseif (z <= 8.5e-94) tmp = x * (y / (t - z)); elseif (z <= 5700000000.0) tmp = t_1; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.55e+111], x, If[LessEqual[z, -165000000.0], t$95$1, If[LessEqual[z, -3.1e-21], x, If[LessEqual[z, 1.9e-239], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.5e-94], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5700000000.0], t$95$1, x]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{y - z}{t}\\
\mathbf{if}\;z \leq -1.55 \cdot 10^{+111}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -165000000:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq -3.1 \cdot 10^{-21}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 1.9 \cdot 10^{-239}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\mathbf{elif}\;z \leq 8.5 \cdot 10^{-94}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{elif}\;z \leq 5700000000:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.55e111 or -1.65e8 < z < -3.0999999999999998e-21 or 5.7e9 < z Initial program 75.8%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 68.5%
if -1.55e111 < z < -1.65e8 or 8.50000000000000003e-94 < z < 5.7e9Initial program 95.5%
associate-*r/99.7%
Simplified99.7%
Taylor expanded in t around inf 73.6%
if -3.0999999999999998e-21 < z < 1.9000000000000001e-239Initial program 92.7%
associate-*l/92.9%
Simplified92.9%
Taylor expanded in t around inf 82.4%
if 1.9000000000000001e-239 < z < 8.50000000000000003e-94Initial program 90.4%
associate-*r/97.3%
Simplified97.3%
Taylor expanded in y around inf 80.4%
Final simplification74.0%
(FPCore (x y z t)
:precision binary64
(if (<= z -1.15e+68)
x
(if (<= z -165000000.0)
(/ (* x (- z)) t)
(if (<= z -6.2e-18)
(/ z (/ z x))
(if (<= z 4.5e-156)
(/ (* x y) t)
(if (<= z 3.8e-120)
(* x (/ (- y) z))
(if (<= z 4100.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.15e+68) {
tmp = x;
} else if (z <= -165000000.0) {
tmp = (x * -z) / t;
} else if (z <= -6.2e-18) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = x * (-y / z);
} else if (z <= 4100.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-1.15d+68)) then
tmp = x
else if (z <= (-165000000.0d0)) then
tmp = (x * -z) / t
else if (z <= (-6.2d-18)) then
tmp = z / (z / x)
else if (z <= 4.5d-156) then
tmp = (x * y) / t
else if (z <= 3.8d-120) then
tmp = x * (-y / z)
else if (z <= 4100.0d0) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.15e+68) {
tmp = x;
} else if (z <= -165000000.0) {
tmp = (x * -z) / t;
} else if (z <= -6.2e-18) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = x * (-y / z);
} else if (z <= 4100.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1.15e+68: tmp = x elif z <= -165000000.0: tmp = (x * -z) / t elif z <= -6.2e-18: tmp = z / (z / x) elif z <= 4.5e-156: tmp = (x * y) / t elif z <= 3.8e-120: tmp = x * (-y / z) elif z <= 4100.0: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1.15e+68) tmp = x; elseif (z <= -165000000.0) tmp = Float64(Float64(x * Float64(-z)) / t); elseif (z <= -6.2e-18) tmp = Float64(z / Float64(z / x)); elseif (z <= 4.5e-156) tmp = Float64(Float64(x * y) / t); elseif (z <= 3.8e-120) tmp = Float64(x * Float64(Float64(-y) / z)); elseif (z <= 4100.0) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1.15e+68) tmp = x; elseif (z <= -165000000.0) tmp = (x * -z) / t; elseif (z <= -6.2e-18) tmp = z / (z / x); elseif (z <= 4.5e-156) tmp = (x * y) / t; elseif (z <= 3.8e-120) tmp = x * (-y / z); elseif (z <= 4100.0) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.15e+68], x, If[LessEqual[z, -165000000.0], N[(N[(x * (-z)), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, -6.2e-18], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(x * N[((-y) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4100.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.15 \cdot 10^{+68}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -165000000:\\
\;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\
\mathbf{elif}\;z \leq -6.2 \cdot 10^{-18}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\
\;\;\;\;\frac{x \cdot y}{t}\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\
\;\;\;\;x \cdot \frac{-y}{z}\\
\mathbf{elif}\;z \leq 4100:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.15e68 or 4100 < z Initial program 75.6%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 66.4%
if -1.15e68 < z < -1.65e8Initial program 93.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in t around inf 71.9%
Taylor expanded in y around 0 44.7%
mul-1-neg44.7%
Simplified44.7%
if -1.65e8 < z < -6.20000000000000014e-18Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around 0 84.1%
associate-*r/84.1%
neg-mul-184.1%
neg-sub084.1%
associate--r-84.1%
neg-sub084.1%
Simplified84.1%
Taylor expanded in x around 0 83.9%
associate-/l*83.9%
Simplified83.9%
Taylor expanded in z around inf 73.0%
if -6.20000000000000014e-18 < z < 4.49999999999999986e-156Initial program 92.4%
associate-*r/94.9%
Simplified94.9%
Taylor expanded in z around 0 77.1%
if 4.49999999999999986e-156 < z < 3.7999999999999997e-120Initial program 84.6%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in y around inf 68.6%
Taylor expanded in t around 0 53.1%
associate-*r/53.1%
neg-mul-153.1%
Simplified53.1%
if 3.7999999999999997e-120 < z < 4100Initial program 96.4%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in z around 0 58.7%
Final simplification67.0%
(FPCore (x y z t)
:precision binary64
(if (<= z -2.3e+69)
x
(if (<= z -180000000.0)
(* z (/ (- x) t))
(if (<= z -1.15e-17)
(/ z (/ z x))
(if (<= z 4.5e-156)
(/ (* x y) t)
(if (<= z 3.8e-120)
(* x (/ (- y) z))
(if (<= z 26500.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.3e+69) {
tmp = x;
} else if (z <= -180000000.0) {
tmp = z * (-x / t);
} else if (z <= -1.15e-17) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = x * (-y / z);
} else if (z <= 26500.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-2.3d+69)) then
tmp = x
else if (z <= (-180000000.0d0)) then
tmp = z * (-x / t)
else if (z <= (-1.15d-17)) then
tmp = z / (z / x)
else if (z <= 4.5d-156) then
tmp = (x * y) / t
else if (z <= 3.8d-120) then
tmp = x * (-y / z)
else if (z <= 26500.0d0) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.3e+69) {
tmp = x;
} else if (z <= -180000000.0) {
tmp = z * (-x / t);
} else if (z <= -1.15e-17) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = x * (-y / z);
} else if (z <= 26500.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -2.3e+69: tmp = x elif z <= -180000000.0: tmp = z * (-x / t) elif z <= -1.15e-17: tmp = z / (z / x) elif z <= 4.5e-156: tmp = (x * y) / t elif z <= 3.8e-120: tmp = x * (-y / z) elif z <= 26500.0: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -2.3e+69) tmp = x; elseif (z <= -180000000.0) tmp = Float64(z * Float64(Float64(-x) / t)); elseif (z <= -1.15e-17) tmp = Float64(z / Float64(z / x)); elseif (z <= 4.5e-156) tmp = Float64(Float64(x * y) / t); elseif (z <= 3.8e-120) tmp = Float64(x * Float64(Float64(-y) / z)); elseif (z <= 26500.0) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -2.3e+69) tmp = x; elseif (z <= -180000000.0) tmp = z * (-x / t); elseif (z <= -1.15e-17) tmp = z / (z / x); elseif (z <= 4.5e-156) tmp = (x * y) / t; elseif (z <= 3.8e-120) tmp = x * (-y / z); elseif (z <= 26500.0) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.3e+69], x, If[LessEqual[z, -180000000.0], N[(z * N[((-x) / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.15e-17], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(x * N[((-y) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 26500.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.3 \cdot 10^{+69}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -180000000:\\
\;\;\;\;z \cdot \frac{-x}{t}\\
\mathbf{elif}\;z \leq -1.15 \cdot 10^{-17}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\
\;\;\;\;\frac{x \cdot y}{t}\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\
\;\;\;\;x \cdot \frac{-y}{z}\\
\mathbf{elif}\;z \leq 26500:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -2.30000000000000017e69 or 26500 < z Initial program 75.6%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 66.4%
if -2.30000000000000017e69 < z < -1.8e8Initial program 93.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in t around inf 71.9%
Taylor expanded in y around 0 44.7%
mul-1-neg44.7%
distribute-neg-frac44.7%
distribute-lft-neg-out44.7%
associate-*r/44.9%
distribute-lft-neg-out44.9%
distribute-rgt-neg-in44.9%
Simplified44.9%
if -1.8e8 < z < -1.15000000000000004e-17Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around 0 84.1%
associate-*r/84.1%
neg-mul-184.1%
neg-sub084.1%
associate--r-84.1%
neg-sub084.1%
Simplified84.1%
Taylor expanded in x around 0 83.9%
associate-/l*83.9%
Simplified83.9%
Taylor expanded in z around inf 73.0%
if -1.15000000000000004e-17 < z < 4.49999999999999986e-156Initial program 92.4%
associate-*r/94.9%
Simplified94.9%
Taylor expanded in z around 0 77.1%
if 4.49999999999999986e-156 < z < 3.7999999999999997e-120Initial program 84.6%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in y around inf 68.6%
Taylor expanded in t around 0 53.1%
associate-*r/53.1%
neg-mul-153.1%
Simplified53.1%
if 3.7999999999999997e-120 < z < 26500Initial program 96.4%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in z around 0 58.7%
Final simplification67.0%
(FPCore (x y z t)
:precision binary64
(if (<= z -2.5e+68)
x
(if (<= z -165000000.0)
(/ x (/ (- t) z))
(if (<= z -5.2e-17)
(/ z (/ z x))
(if (<= z 4.5e-156)
(/ (* x y) t)
(if (<= z 3.8e-120)
(* x (/ (- y) z))
(if (<= z 56000.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.5e+68) {
tmp = x;
} else if (z <= -165000000.0) {
tmp = x / (-t / z);
} else if (z <= -5.2e-17) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = x * (-y / z);
} else if (z <= 56000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-2.5d+68)) then
tmp = x
else if (z <= (-165000000.0d0)) then
tmp = x / (-t / z)
else if (z <= (-5.2d-17)) then
tmp = z / (z / x)
else if (z <= 4.5d-156) then
tmp = (x * y) / t
else if (z <= 3.8d-120) then
tmp = x * (-y / z)
else if (z <= 56000.0d0) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.5e+68) {
tmp = x;
} else if (z <= -165000000.0) {
tmp = x / (-t / z);
} else if (z <= -5.2e-17) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = x * (-y / z);
} else if (z <= 56000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -2.5e+68: tmp = x elif z <= -165000000.0: tmp = x / (-t / z) elif z <= -5.2e-17: tmp = z / (z / x) elif z <= 4.5e-156: tmp = (x * y) / t elif z <= 3.8e-120: tmp = x * (-y / z) elif z <= 56000.0: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -2.5e+68) tmp = x; elseif (z <= -165000000.0) tmp = Float64(x / Float64(Float64(-t) / z)); elseif (z <= -5.2e-17) tmp = Float64(z / Float64(z / x)); elseif (z <= 4.5e-156) tmp = Float64(Float64(x * y) / t); elseif (z <= 3.8e-120) tmp = Float64(x * Float64(Float64(-y) / z)); elseif (z <= 56000.0) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -2.5e+68) tmp = x; elseif (z <= -165000000.0) tmp = x / (-t / z); elseif (z <= -5.2e-17) tmp = z / (z / x); elseif (z <= 4.5e-156) tmp = (x * y) / t; elseif (z <= 3.8e-120) tmp = x * (-y / z); elseif (z <= 56000.0) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.5e+68], x, If[LessEqual[z, -165000000.0], N[(x / N[((-t) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5.2e-17], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(x * N[((-y) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 56000.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{+68}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -165000000:\\
\;\;\;\;\frac{x}{\frac{-t}{z}}\\
\mathbf{elif}\;z \leq -5.2 \cdot 10^{-17}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\
\;\;\;\;\frac{x \cdot y}{t}\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\
\;\;\;\;x \cdot \frac{-y}{z}\\
\mathbf{elif}\;z \leq 56000:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -2.5000000000000002e68 or 56000 < z Initial program 75.6%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 66.4%
if -2.5000000000000002e68 < z < -1.65e8Initial program 93.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in t around inf 71.9%
Taylor expanded in y around 0 50.6%
associate-*r/50.6%
mul-1-neg50.6%
Simplified50.6%
if -1.65e8 < z < -5.20000000000000006e-17Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around 0 84.1%
associate-*r/84.1%
neg-mul-184.1%
neg-sub084.1%
associate--r-84.1%
neg-sub084.1%
Simplified84.1%
Taylor expanded in x around 0 83.9%
associate-/l*83.9%
Simplified83.9%
Taylor expanded in z around inf 73.0%
if -5.20000000000000006e-17 < z < 4.49999999999999986e-156Initial program 92.4%
associate-*r/94.9%
Simplified94.9%
Taylor expanded in z around 0 77.1%
if 4.49999999999999986e-156 < z < 3.7999999999999997e-120Initial program 84.6%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in y around inf 68.6%
Taylor expanded in t around 0 53.1%
associate-*r/53.1%
neg-mul-153.1%
Simplified53.1%
if 3.7999999999999997e-120 < z < 56000Initial program 96.4%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in z around 0 58.7%
Final simplification67.3%
(FPCore (x y z t)
:precision binary64
(if (<= z -5.8e+68)
x
(if (<= z -180000000.0)
(/ x (/ (- t) z))
(if (<= z -3.5e-16)
(/ z (/ z x))
(if (<= z 4.5e-156)
(/ (* x y) t)
(if (<= z 3.8e-120)
(/ y (/ (- z) x))
(if (<= z 820000000.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -5.8e+68) {
tmp = x;
} else if (z <= -180000000.0) {
tmp = x / (-t / z);
} else if (z <= -3.5e-16) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = y / (-z / x);
} else if (z <= 820000000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-5.8d+68)) then
tmp = x
else if (z <= (-180000000.0d0)) then
tmp = x / (-t / z)
else if (z <= (-3.5d-16)) then
tmp = z / (z / x)
else if (z <= 4.5d-156) then
tmp = (x * y) / t
else if (z <= 3.8d-120) then
tmp = y / (-z / x)
else if (z <= 820000000.0d0) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -5.8e+68) {
tmp = x;
} else if (z <= -180000000.0) {
tmp = x / (-t / z);
} else if (z <= -3.5e-16) {
tmp = z / (z / x);
} else if (z <= 4.5e-156) {
tmp = (x * y) / t;
} else if (z <= 3.8e-120) {
tmp = y / (-z / x);
} else if (z <= 820000000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -5.8e+68: tmp = x elif z <= -180000000.0: tmp = x / (-t / z) elif z <= -3.5e-16: tmp = z / (z / x) elif z <= 4.5e-156: tmp = (x * y) / t elif z <= 3.8e-120: tmp = y / (-z / x) elif z <= 820000000.0: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -5.8e+68) tmp = x; elseif (z <= -180000000.0) tmp = Float64(x / Float64(Float64(-t) / z)); elseif (z <= -3.5e-16) tmp = Float64(z / Float64(z / x)); elseif (z <= 4.5e-156) tmp = Float64(Float64(x * y) / t); elseif (z <= 3.8e-120) tmp = Float64(y / Float64(Float64(-z) / x)); elseif (z <= 820000000.0) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -5.8e+68) tmp = x; elseif (z <= -180000000.0) tmp = x / (-t / z); elseif (z <= -3.5e-16) tmp = z / (z / x); elseif (z <= 4.5e-156) tmp = (x * y) / t; elseif (z <= 3.8e-120) tmp = y / (-z / x); elseif (z <= 820000000.0) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -5.8e+68], x, If[LessEqual[z, -180000000.0], N[(x / N[((-t) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -3.5e-16], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(y / N[((-z) / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 820000000.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.8 \cdot 10^{+68}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -180000000:\\
\;\;\;\;\frac{x}{\frac{-t}{z}}\\
\mathbf{elif}\;z \leq -3.5 \cdot 10^{-16}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\
\;\;\;\;\frac{x \cdot y}{t}\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\
\;\;\;\;\frac{y}{\frac{-z}{x}}\\
\mathbf{elif}\;z \leq 820000000:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -5.80000000000000023e68 or 8.2e8 < z Initial program 75.6%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 66.4%
if -5.80000000000000023e68 < z < -1.8e8Initial program 93.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in t around inf 71.9%
Taylor expanded in y around 0 50.6%
associate-*r/50.6%
mul-1-neg50.6%
Simplified50.6%
if -1.8e8 < z < -3.50000000000000017e-16Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around 0 84.1%
associate-*r/84.1%
neg-mul-184.1%
neg-sub084.1%
associate--r-84.1%
neg-sub084.1%
Simplified84.1%
Taylor expanded in x around 0 83.9%
associate-/l*83.9%
Simplified83.9%
Taylor expanded in z around inf 73.0%
if -3.50000000000000017e-16 < z < 4.49999999999999986e-156Initial program 92.4%
associate-*r/94.9%
Simplified94.9%
Taylor expanded in z around 0 77.1%
if 4.49999999999999986e-156 < z < 3.7999999999999997e-120Initial program 84.6%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in y around inf 68.6%
Taylor expanded in t around 0 45.1%
mul-1-neg45.1%
associate-*r/53.0%
distribute-rgt-neg-in53.0%
distribute-neg-frac53.0%
Simplified53.0%
associate-*r/45.1%
frac-2neg45.1%
add-sqr-sqrt3.3%
sqrt-unprod4.4%
sqr-neg4.4%
sqrt-unprod1.0%
add-sqr-sqrt3.8%
distribute-rgt-neg-out3.8%
add-sqr-sqrt2.8%
sqrt-unprod36.6%
sqr-neg36.6%
sqrt-unprod41.8%
add-sqr-sqrt45.1%
Applied egg-rr45.1%
associate-/l*53.2%
Simplified53.2%
if 3.7999999999999997e-120 < z < 8.2e8Initial program 96.4%
associate-*r/99.6%
Simplified99.6%
Taylor expanded in z around 0 58.7%
Final simplification67.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (/ y (- t z)))))
(if (<= z -1.9e+145)
x
(if (<= z -39000000.0)
t_1
(if (<= z -4.5e-16) (/ z (/ z x)) (if (<= z 3.3e+24) t_1 x))))))
double code(double x, double y, double z, double t) {
double t_1 = x * (y / (t - z));
double tmp;
if (z <= -1.9e+145) {
tmp = x;
} else if (z <= -39000000.0) {
tmp = t_1;
} else if (z <= -4.5e-16) {
tmp = z / (z / x);
} else if (z <= 3.3e+24) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = x * (y / (t - z))
if (z <= (-1.9d+145)) then
tmp = x
else if (z <= (-39000000.0d0)) then
tmp = t_1
else if (z <= (-4.5d-16)) then
tmp = z / (z / x)
else if (z <= 3.3d+24) 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 t_1 = x * (y / (t - z));
double tmp;
if (z <= -1.9e+145) {
tmp = x;
} else if (z <= -39000000.0) {
tmp = t_1;
} else if (z <= -4.5e-16) {
tmp = z / (z / x);
} else if (z <= 3.3e+24) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): t_1 = x * (y / (t - z)) tmp = 0 if z <= -1.9e+145: tmp = x elif z <= -39000000.0: tmp = t_1 elif z <= -4.5e-16: tmp = z / (z / x) elif z <= 3.3e+24: tmp = t_1 else: tmp = x return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(y / Float64(t - z))) tmp = 0.0 if (z <= -1.9e+145) tmp = x; elseif (z <= -39000000.0) tmp = t_1; elseif (z <= -4.5e-16) tmp = Float64(z / Float64(z / x)); elseif (z <= 3.3e+24) tmp = t_1; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * (y / (t - z)); tmp = 0.0; if (z <= -1.9e+145) tmp = x; elseif (z <= -39000000.0) tmp = t_1; elseif (z <= -4.5e-16) tmp = z / (z / x); elseif (z <= 3.3e+24) tmp = t_1; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.9e+145], x, If[LessEqual[z, -39000000.0], t$95$1, If[LessEqual[z, -4.5e-16], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.3e+24], t$95$1, x]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{t - z}\\
\mathbf{if}\;z \leq -1.9 \cdot 10^{+145}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -39000000:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq -4.5 \cdot 10^{-16}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\
\mathbf{elif}\;z \leq 3.3 \cdot 10^{+24}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.90000000000000006e145 or 3.2999999999999999e24 < z Initial program 72.9%
associate-*r/99.9%
Simplified99.9%
Taylor expanded in z around inf 71.1%
if -1.90000000000000006e145 < z < -3.9e7 or -4.5000000000000002e-16 < z < 3.2999999999999999e24Initial program 92.8%
associate-*r/97.2%
Simplified97.2%
Taylor expanded in y around inf 70.8%
if -3.9e7 < z < -4.5000000000000002e-16Initial program 99.7%
associate-/l*100.0%
Simplified100.0%
Taylor expanded in y around 0 100.0%
associate-*r/100.0%
neg-mul-1100.0%
neg-sub0100.0%
associate--r-100.0%
neg-sub0100.0%
Simplified100.0%
Taylor expanded in x around 0 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 86.7%
Final simplification71.2%
(FPCore (x y z t)
:precision binary64
(if (<= t -1.18e+36)
(/ x (/ t (- y z)))
(if (<= t 1.56e-44)
(/ x (/ z (- z y)))
(if (<= t 4.2e+56)
(* x (/ y (- t z)))
(if (<= t 1.75e+152) (/ x (- 1.0 (/ t z))) (* (- y z) (/ x t)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -1.18e+36) {
tmp = x / (t / (y - z));
} else if (t <= 1.56e-44) {
tmp = x / (z / (z - y));
} else if (t <= 4.2e+56) {
tmp = x * (y / (t - z));
} else if (t <= 1.75e+152) {
tmp = x / (1.0 - (t / z));
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (t <= (-1.18d+36)) then
tmp = x / (t / (y - z))
else if (t <= 1.56d-44) then
tmp = x / (z / (z - y))
else if (t <= 4.2d+56) then
tmp = x * (y / (t - z))
else if (t <= 1.75d+152) then
tmp = x / (1.0d0 - (t / z))
else
tmp = (y - z) * (x / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -1.18e+36) {
tmp = x / (t / (y - z));
} else if (t <= 1.56e-44) {
tmp = x / (z / (z - y));
} else if (t <= 4.2e+56) {
tmp = x * (y / (t - z));
} else if (t <= 1.75e+152) {
tmp = x / (1.0 - (t / z));
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if t <= -1.18e+36: tmp = x / (t / (y - z)) elif t <= 1.56e-44: tmp = x / (z / (z - y)) elif t <= 4.2e+56: tmp = x * (y / (t - z)) elif t <= 1.75e+152: tmp = x / (1.0 - (t / z)) else: tmp = (y - z) * (x / t) return tmp
function code(x, y, z, t) tmp = 0.0 if (t <= -1.18e+36) tmp = Float64(x / Float64(t / Float64(y - z))); elseif (t <= 1.56e-44) tmp = Float64(x / Float64(z / Float64(z - y))); elseif (t <= 4.2e+56) tmp = Float64(x * Float64(y / Float64(t - z))); elseif (t <= 1.75e+152) tmp = Float64(x / Float64(1.0 - Float64(t / z))); else tmp = Float64(Float64(y - z) * Float64(x / t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (t <= -1.18e+36) tmp = x / (t / (y - z)); elseif (t <= 1.56e-44) tmp = x / (z / (z - y)); elseif (t <= 4.2e+56) tmp = x * (y / (t - z)); elseif (t <= 1.75e+152) tmp = x / (1.0 - (t / z)); else tmp = (y - z) * (x / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[t, -1.18e+36], N[(x / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.56e-44], N[(x / N[(z / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.2e+56], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.75e+152], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.18 \cdot 10^{+36}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\
\mathbf{elif}\;t \leq 1.56 \cdot 10^{-44}:\\
\;\;\;\;\frac{x}{\frac{z}{z - y}}\\
\mathbf{elif}\;t \leq 4.2 \cdot 10^{+56}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{elif}\;t \leq 1.75 \cdot 10^{+152}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\end{array}
\end{array}
if t < -1.17999999999999997e36Initial program 82.6%
associate-/l*98.3%
Simplified98.3%
Taylor expanded in t around inf 77.5%
if -1.17999999999999997e36 < t < 1.56e-44Initial program 83.8%
associate-/l*99.1%
Simplified99.1%
Taylor expanded in t around 0 83.5%
neg-mul-183.5%
distribute-neg-frac83.5%
Simplified83.5%
frac-2neg83.5%
div-inv83.3%
remove-double-neg83.3%
sub-neg83.3%
distribute-neg-in83.3%
remove-double-neg83.3%
Applied egg-rr83.3%
associate-*r/83.5%
*-rgt-identity83.5%
+-commutative83.5%
unsub-neg83.5%
Simplified83.5%
if 1.56e-44 < t < 4.20000000000000034e56Initial program 94.2%
associate-*r/99.7%
Simplified99.7%
Taylor expanded in y around inf 75.6%
if 4.20000000000000034e56 < t < 1.74999999999999991e152Initial program 83.4%
associate-/l*99.9%
Simplified99.9%
div-sub99.9%
Applied egg-rr99.9%
Taylor expanded in y around 0 72.2%
mul-1-neg72.2%
unsub-neg72.2%
Simplified72.2%
if 1.74999999999999991e152 < t Initial program 91.8%
associate-*l/94.6%
Simplified94.6%
Taylor expanded in t around inf 86.7%
Final simplification81.0%
(FPCore (x y z t)
:precision binary64
(if (<= t -4.6e+50)
(/ x (/ t (- y z)))
(if (<= t 2.7e-43)
(/ x (/ z (- z y)))
(if (<= t 3.2e+54)
(/ (* x y) (- t z))
(if (<= t 3.2e+152) (/ x (- 1.0 (/ t z))) (* (- y z) (/ x t)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -4.6e+50) {
tmp = x / (t / (y - z));
} else if (t <= 2.7e-43) {
tmp = x / (z / (z - y));
} else if (t <= 3.2e+54) {
tmp = (x * y) / (t - z);
} else if (t <= 3.2e+152) {
tmp = x / (1.0 - (t / z));
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (t <= (-4.6d+50)) then
tmp = x / (t / (y - z))
else if (t <= 2.7d-43) then
tmp = x / (z / (z - y))
else if (t <= 3.2d+54) then
tmp = (x * y) / (t - z)
else if (t <= 3.2d+152) then
tmp = x / (1.0d0 - (t / z))
else
tmp = (y - z) * (x / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -4.6e+50) {
tmp = x / (t / (y - z));
} else if (t <= 2.7e-43) {
tmp = x / (z / (z - y));
} else if (t <= 3.2e+54) {
tmp = (x * y) / (t - z);
} else if (t <= 3.2e+152) {
tmp = x / (1.0 - (t / z));
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if t <= -4.6e+50: tmp = x / (t / (y - z)) elif t <= 2.7e-43: tmp = x / (z / (z - y)) elif t <= 3.2e+54: tmp = (x * y) / (t - z) elif t <= 3.2e+152: tmp = x / (1.0 - (t / z)) else: tmp = (y - z) * (x / t) return tmp
function code(x, y, z, t) tmp = 0.0 if (t <= -4.6e+50) tmp = Float64(x / Float64(t / Float64(y - z))); elseif (t <= 2.7e-43) tmp = Float64(x / Float64(z / Float64(z - y))); elseif (t <= 3.2e+54) tmp = Float64(Float64(x * y) / Float64(t - z)); elseif (t <= 3.2e+152) tmp = Float64(x / Float64(1.0 - Float64(t / z))); else tmp = Float64(Float64(y - z) * Float64(x / t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (t <= -4.6e+50) tmp = x / (t / (y - z)); elseif (t <= 2.7e-43) tmp = x / (z / (z - y)); elseif (t <= 3.2e+54) tmp = (x * y) / (t - z); elseif (t <= 3.2e+152) tmp = x / (1.0 - (t / z)); else tmp = (y - z) * (x / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[t, -4.6e+50], N[(x / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.7e-43], N[(x / N[(z / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.2e+54], N[(N[(x * y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.2e+152], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.6 \cdot 10^{+50}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\
\mathbf{elif}\;t \leq 2.7 \cdot 10^{-43}:\\
\;\;\;\;\frac{x}{\frac{z}{z - y}}\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{+54}:\\
\;\;\;\;\frac{x \cdot y}{t - z}\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{+152}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\end{array}
\end{array}
if t < -4.59999999999999994e50Initial program 82.6%
associate-/l*98.3%
Simplified98.3%
Taylor expanded in t around inf 77.5%
if -4.59999999999999994e50 < t < 2.69999999999999991e-43Initial program 83.8%
associate-/l*99.1%
Simplified99.1%
Taylor expanded in t around 0 83.5%
neg-mul-183.5%
distribute-neg-frac83.5%
Simplified83.5%
frac-2neg83.5%
div-inv83.3%
remove-double-neg83.3%
sub-neg83.3%
distribute-neg-in83.3%
remove-double-neg83.3%
Applied egg-rr83.3%
associate-*r/83.5%
*-rgt-identity83.5%
+-commutative83.5%
unsub-neg83.5%
Simplified83.5%
if 2.69999999999999991e-43 < t < 3.2e54Initial program 94.2%
associate-*r/99.7%
Simplified99.7%
Taylor expanded in y around inf 76.0%
if 3.2e54 < t < 3.20000000000000005e152Initial program 83.4%
associate-/l*99.9%
Simplified99.9%
div-sub99.9%
Applied egg-rr99.9%
Taylor expanded in y around 0 72.2%
mul-1-neg72.2%
unsub-neg72.2%
Simplified72.2%
if 3.20000000000000005e152 < t Initial program 91.8%
associate-*l/94.6%
Simplified94.6%
Taylor expanded in t around inf 86.7%
Final simplification81.1%
(FPCore (x y z t)
:precision binary64
(if (<= t -3e+49)
(/ x (/ t (- y z)))
(if (<= t 2.45e-43)
(* x (/ (- z y) z))
(if (<= t 4.5e+54)
(/ (* x y) (- t z))
(if (<= t 4.7e+150) (/ x (- 1.0 (/ t z))) (* (- y z) (/ x t)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -3e+49) {
tmp = x / (t / (y - z));
} else if (t <= 2.45e-43) {
tmp = x * ((z - y) / z);
} else if (t <= 4.5e+54) {
tmp = (x * y) / (t - z);
} else if (t <= 4.7e+150) {
tmp = x / (1.0 - (t / z));
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (t <= (-3d+49)) then
tmp = x / (t / (y - z))
else if (t <= 2.45d-43) then
tmp = x * ((z - y) / z)
else if (t <= 4.5d+54) then
tmp = (x * y) / (t - z)
else if (t <= 4.7d+150) then
tmp = x / (1.0d0 - (t / z))
else
tmp = (y - z) * (x / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -3e+49) {
tmp = x / (t / (y - z));
} else if (t <= 2.45e-43) {
tmp = x * ((z - y) / z);
} else if (t <= 4.5e+54) {
tmp = (x * y) / (t - z);
} else if (t <= 4.7e+150) {
tmp = x / (1.0 - (t / z));
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if t <= -3e+49: tmp = x / (t / (y - z)) elif t <= 2.45e-43: tmp = x * ((z - y) / z) elif t <= 4.5e+54: tmp = (x * y) / (t - z) elif t <= 4.7e+150: tmp = x / (1.0 - (t / z)) else: tmp = (y - z) * (x / t) return tmp
function code(x, y, z, t) tmp = 0.0 if (t <= -3e+49) tmp = Float64(x / Float64(t / Float64(y - z))); elseif (t <= 2.45e-43) tmp = Float64(x * Float64(Float64(z - y) / z)); elseif (t <= 4.5e+54) tmp = Float64(Float64(x * y) / Float64(t - z)); elseif (t <= 4.7e+150) tmp = Float64(x / Float64(1.0 - Float64(t / z))); else tmp = Float64(Float64(y - z) * Float64(x / t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (t <= -3e+49) tmp = x / (t / (y - z)); elseif (t <= 2.45e-43) tmp = x * ((z - y) / z); elseif (t <= 4.5e+54) tmp = (x * y) / (t - z); elseif (t <= 4.7e+150) tmp = x / (1.0 - (t / z)); else tmp = (y - z) * (x / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[t, -3e+49], N[(x / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.45e-43], N[(x * N[(N[(z - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.5e+54], N[(N[(x * y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.7e+150], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3 \cdot 10^{+49}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\
\mathbf{elif}\;t \leq 2.45 \cdot 10^{-43}:\\
\;\;\;\;x \cdot \frac{z - y}{z}\\
\mathbf{elif}\;t \leq 4.5 \cdot 10^{+54}:\\
\;\;\;\;\frac{x \cdot y}{t - z}\\
\mathbf{elif}\;t \leq 4.7 \cdot 10^{+150}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\end{array}
\end{array}
if t < -3.0000000000000002e49Initial program 82.6%
associate-/l*98.3%
Simplified98.3%
Taylor expanded in t around inf 77.5%
if -3.0000000000000002e49 < t < 2.44999999999999994e-43Initial program 83.8%
associate-*r/99.2%
Simplified99.2%
Taylor expanded in t around 0 83.6%
associate-*r/83.6%
neg-mul-183.6%
neg-sub083.6%
associate--r-83.6%
neg-sub083.6%
Simplified83.6%
if 2.44999999999999994e-43 < t < 4.49999999999999984e54Initial program 94.2%
associate-*r/99.7%
Simplified99.7%
Taylor expanded in y around inf 76.0%
if 4.49999999999999984e54 < t < 4.70000000000000004e150Initial program 83.4%
associate-/l*99.9%
Simplified99.9%
div-sub99.9%
Applied egg-rr99.9%
Taylor expanded in y around 0 72.2%
mul-1-neg72.2%
unsub-neg72.2%
Simplified72.2%
if 4.70000000000000004e150 < t Initial program 91.8%
associate-*l/94.6%
Simplified94.6%
Taylor expanded in t around inf 86.7%
Final simplification81.1%
(FPCore (x y z t)
:precision binary64
(if (<= z -1.7e+68)
x
(if (<= z -170000000.0)
(/ (* x (- z)) t)
(if (<= z -4.5e-22) x (if (<= z 95000000.0) (* x (/ y t)) x)))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.7e+68) {
tmp = x;
} else if (z <= -170000000.0) {
tmp = (x * -z) / t;
} else if (z <= -4.5e-22) {
tmp = x;
} else if (z <= 95000000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-1.7d+68)) then
tmp = x
else if (z <= (-170000000.0d0)) then
tmp = (x * -z) / t
else if (z <= (-4.5d-22)) then
tmp = x
else if (z <= 95000000.0d0) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.7e+68) {
tmp = x;
} else if (z <= -170000000.0) {
tmp = (x * -z) / t;
} else if (z <= -4.5e-22) {
tmp = x;
} else if (z <= 95000000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1.7e+68: tmp = x elif z <= -170000000.0: tmp = (x * -z) / t elif z <= -4.5e-22: tmp = x elif z <= 95000000.0: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1.7e+68) tmp = x; elseif (z <= -170000000.0) tmp = Float64(Float64(x * Float64(-z)) / t); elseif (z <= -4.5e-22) tmp = x; elseif (z <= 95000000.0) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1.7e+68) tmp = x; elseif (z <= -170000000.0) tmp = (x * -z) / t; elseif (z <= -4.5e-22) tmp = x; elseif (z <= 95000000.0) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.7e+68], x, If[LessEqual[z, -170000000.0], N[(N[(x * (-z)), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, -4.5e-22], x, If[LessEqual[z, 95000000.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.7 \cdot 10^{+68}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -170000000:\\
\;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\
\mathbf{elif}\;z \leq -4.5 \cdot 10^{-22}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 95000000:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.70000000000000008e68 or -1.7e8 < z < -4.49999999999999987e-22 or 9.5e7 < z Initial program 77.2%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 66.5%
if -1.70000000000000008e68 < z < -1.7e8Initial program 93.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in t around inf 71.9%
Taylor expanded in y around 0 44.7%
mul-1-neg44.7%
Simplified44.7%
if -4.49999999999999987e-22 < z < 9.5e7Initial program 92.4%
associate-*r/96.4%
Simplified96.4%
Taylor expanded in z around 0 67.0%
Final simplification65.3%
(FPCore (x y z t) :precision binary64 (if (or (<= t -2.3e+40) (not (<= t 2.9e-43))) (* x (/ (- y z) t)) (- x (/ (* x y) z))))
double code(double x, double y, double z, double t) {
double tmp;
if ((t <= -2.3e+40) || !(t <= 2.9e-43)) {
tmp = x * ((y - z) / t);
} else {
tmp = x - ((x * y) / z);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if ((t <= (-2.3d+40)) .or. (.not. (t <= 2.9d-43))) then
tmp = x * ((y - z) / t)
else
tmp = x - ((x * y) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((t <= -2.3e+40) || !(t <= 2.9e-43)) {
tmp = x * ((y - z) / t);
} else {
tmp = x - ((x * y) / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (t <= -2.3e+40) or not (t <= 2.9e-43): tmp = x * ((y - z) / t) else: tmp = x - ((x * y) / z) return tmp
function code(x, y, z, t) tmp = 0.0 if ((t <= -2.3e+40) || !(t <= 2.9e-43)) tmp = Float64(x * Float64(Float64(y - z) / t)); else tmp = Float64(x - Float64(Float64(x * y) / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((t <= -2.3e+40) || ~((t <= 2.9e-43))) tmp = x * ((y - z) / t); else tmp = x - ((x * y) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[t, -2.3e+40], N[Not[LessEqual[t, 2.9e-43]], $MachinePrecision]], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x - N[(N[(x * y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.3 \cdot 10^{+40} \lor \neg \left(t \leq 2.9 \cdot 10^{-43}\right):\\
\;\;\;\;x \cdot \frac{y - z}{t}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{x \cdot y}{z}\\
\end{array}
\end{array}
if t < -2.29999999999999994e40 or 2.9000000000000001e-43 < t Initial program 86.0%
associate-*r/97.4%
Simplified97.4%
Taylor expanded in t around inf 74.2%
if -2.29999999999999994e40 < t < 2.9000000000000001e-43Initial program 83.8%
associate-/l*99.1%
Simplified99.1%
Taylor expanded in t around 0 83.5%
neg-mul-183.5%
distribute-neg-frac83.5%
Simplified83.5%
Taylor expanded in z around 0 77.5%
+-commutative77.5%
mul-1-neg77.5%
unsub-neg77.5%
Simplified77.5%
Final simplification75.9%
(FPCore (x y z t) :precision binary64 (if (or (<= z -3.9e-23) (not (<= z 230.0))) (/ x (- 1.0 (/ t z))) (* x (/ y (- t z)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -3.9e-23) || !(z <= 230.0)) {
tmp = x / (1.0 - (t / z));
} else {
tmp = x * (y / (t - z));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if ((z <= (-3.9d-23)) .or. (.not. (z <= 230.0d0))) then
tmp = x / (1.0d0 - (t / z))
else
tmp = x * (y / (t - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -3.9e-23) || !(z <= 230.0)) {
tmp = x / (1.0 - (t / z));
} else {
tmp = x * (y / (t - z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -3.9e-23) or not (z <= 230.0): tmp = x / (1.0 - (t / z)) else: tmp = x * (y / (t - z)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -3.9e-23) || !(z <= 230.0)) tmp = Float64(x / Float64(1.0 - Float64(t / z))); else tmp = Float64(x * Float64(y / Float64(t - z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -3.9e-23) || ~((z <= 230.0))) tmp = x / (1.0 - (t / z)); else tmp = x * (y / (t - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -3.9e-23], N[Not[LessEqual[z, 230.0]], $MachinePrecision]], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.9 \cdot 10^{-23} \lor \neg \left(z \leq 230\right):\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\end{array}
\end{array}
if z < -3.9e-23 or 230 < z Initial program 79.0%
associate-/l*99.9%
Simplified99.9%
div-sub99.9%
Applied egg-rr99.9%
Taylor expanded in y around 0 78.4%
mul-1-neg78.4%
unsub-neg78.4%
Simplified78.4%
if -3.9e-23 < z < 230Initial program 92.4%
associate-*r/96.4%
Simplified96.4%
Taylor expanded in y around inf 76.9%
Final simplification77.8%
(FPCore (x y z t) :precision binary64 (if (<= z -3.1e-21) x (if (<= z 7800000000.0) (* x (/ y t)) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -3.1e-21) {
tmp = x;
} else if (z <= 7800000000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-3.1d-21)) then
tmp = x
else if (z <= 7800000000.0d0) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -3.1e-21) {
tmp = x;
} else if (z <= 7800000000.0) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -3.1e-21: tmp = x elif z <= 7800000000.0: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -3.1e-21) tmp = x; elseif (z <= 7800000000.0) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -3.1e-21) tmp = x; elseif (z <= 7800000000.0) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -3.1e-21], x, If[LessEqual[z, 7800000000.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.1 \cdot 10^{-21}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 7800000000:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -3.0999999999999998e-21 or 7.8e9 < z Initial program 79.0%
associate-*r/99.8%
Simplified99.8%
Taylor expanded in z around inf 60.8%
if -3.0999999999999998e-21 < z < 7.8e9Initial program 92.4%
associate-*r/96.4%
Simplified96.4%
Taylor expanded in z around 0 67.0%
Final simplification63.5%
(FPCore (x y z t) :precision binary64 (* x (/ (- y z) (- t z))))
double code(double x, double y, double z, double t) {
return x * ((y - z) / (t - z));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x * ((y - z) / (t - z))
end function
public static double code(double x, double y, double z, double t) {
return x * ((y - z) / (t - z));
}
def code(x, y, z, t): return x * ((y - z) / (t - z))
function code(x, y, z, t) return Float64(x * Float64(Float64(y - z) / Float64(t - z))) end
function tmp = code(x, y, z, t) tmp = x * ((y - z) / (t - z)); end
code[x_, y_, z_, t_] := N[(x * N[(N[(y - z), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \frac{y - z}{t - z}
\end{array}
Initial program 84.8%
associate-*r/98.3%
Simplified98.3%
Final simplification98.3%
(FPCore (x y z t) :precision binary64 x)
double code(double x, double y, double z, double t) {
return x;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x
end function
public static double code(double x, double y, double z, double t) {
return x;
}
def code(x, y, z, t): return x
function code(x, y, z, t) return x end
function tmp = code(x, y, z, t) tmp = x; end
code[x_, y_, z_, t_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 84.8%
associate-*r/98.3%
Simplified98.3%
Taylor expanded in z around inf 40.2%
Final simplification40.2%
(FPCore (x y z t) :precision binary64 (/ x (/ (- t z) (- y z))))
double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x / ((t - z) / (y - z))
end function
public static double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
def code(x, y, z, t): return x / ((t - z) / (y - z))
function code(x, y, z, t) return Float64(x / Float64(Float64(t - z) / Float64(y - z))) end
function tmp = code(x, y, z, t) tmp = x / ((t - z) / (y - z)); end
code[x_, y_, z_, t_] := N[(x / N[(N[(t - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\frac{t - z}{y - z}}
\end{array}
herbie shell --seed 2023192
(FPCore (x y z t)
:name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
:precision binary64
:herbie-target
(/ x (/ (- t z) (- y z)))
(/ (* x (- y z)) (- t z)))