
(FPCore (x y z t) :precision binary64 (+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))
double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y));
}
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 * 3.0d0))) + (t / ((z * 3.0d0) * y))
end function
public static double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y));
}
def code(x, y, z, t): return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y))
function code(x, y, z, t) return Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(t / Float64(Float64(z * 3.0) * y))) end
function tmp = code(x, y, z, t) tmp = (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y)); end
code[x_, y_, z_, t_] := N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t / N[(N[(z * 3.0), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 19 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))
double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y));
}
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 * 3.0d0))) + (t / ((z * 3.0d0) * y))
end function
public static double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y));
}
def code(x, y, z, t): return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y))
function code(x, y, z, t) return Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(t / Float64(Float64(z * 3.0) * y))) end
function tmp = code(x, y, z, t) tmp = (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y)); end
code[x_, y_, z_, t_] := N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t / N[(N[(z * 3.0), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y}
\end{array}
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (- x (/ y (* z 3.0)))))
(if (<= t -1e-49)
(+ t_1 (/ t (* z (* y 3.0))))
(if (<= t 1e-22)
(+ x (/ (- (/ t y) y) (* z 3.0)))
(+ t_1 (/ t (* y (* z 3.0))))))))
double code(double x, double y, double z, double t) {
double t_1 = x - (y / (z * 3.0));
double tmp;
if (t <= -1e-49) {
tmp = t_1 + (t / (z * (y * 3.0)));
} else if (t <= 1e-22) {
tmp = x + (((t / y) - y) / (z * 3.0));
} else {
tmp = t_1 + (t / (y * (z * 3.0)));
}
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 * 3.0d0))
if (t <= (-1d-49)) then
tmp = t_1 + (t / (z * (y * 3.0d0)))
else if (t <= 1d-22) then
tmp = x + (((t / y) - y) / (z * 3.0d0))
else
tmp = t_1 + (t / (y * (z * 3.0d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x - (y / (z * 3.0));
double tmp;
if (t <= -1e-49) {
tmp = t_1 + (t / (z * (y * 3.0)));
} else if (t <= 1e-22) {
tmp = x + (((t / y) - y) / (z * 3.0));
} else {
tmp = t_1 + (t / (y * (z * 3.0)));
}
return tmp;
}
def code(x, y, z, t): t_1 = x - (y / (z * 3.0)) tmp = 0 if t <= -1e-49: tmp = t_1 + (t / (z * (y * 3.0))) elif t <= 1e-22: tmp = x + (((t / y) - y) / (z * 3.0)) else: tmp = t_1 + (t / (y * (z * 3.0))) return tmp
function code(x, y, z, t) t_1 = Float64(x - Float64(y / Float64(z * 3.0))) tmp = 0.0 if (t <= -1e-49) tmp = Float64(t_1 + Float64(t / Float64(z * Float64(y * 3.0)))); elseif (t <= 1e-22) tmp = Float64(x + Float64(Float64(Float64(t / y) - y) / Float64(z * 3.0))); else tmp = Float64(t_1 + Float64(t / Float64(y * Float64(z * 3.0)))); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x - (y / (z * 3.0)); tmp = 0.0; if (t <= -1e-49) tmp = t_1 + (t / (z * (y * 3.0))); elseif (t <= 1e-22) tmp = x + (((t / y) - y) / (z * 3.0)); else tmp = t_1 + (t / (y * (z * 3.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1e-49], N[(t$95$1 + N[(t / N[(z * N[(y * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1e-22], N[(x + N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(t / N[(y * N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x - \frac{y}{z \cdot 3}\\
\mathbf{if}\;t \leq -1 \cdot 10^{-49}:\\
\;\;\;\;t_1 + \frac{t}{z \cdot \left(y \cdot 3\right)}\\
\mathbf{elif}\;t \leq 10^{-22}:\\
\;\;\;\;x + \frac{\frac{t}{y} - y}{z \cdot 3}\\
\mathbf{else}:\\
\;\;\;\;t_1 + \frac{t}{y \cdot \left(z \cdot 3\right)}\\
\end{array}
\end{array}
if t < -9.99999999999999936e-50Initial program 98.8%
associate-*l*98.9%
*-commutative98.9%
Simplified98.9%
if -9.99999999999999936e-50 < t < 1e-22Initial program 90.5%
associate-*l*90.6%
*-commutative90.6%
Simplified90.6%
*-commutative90.6%
associate-*l*90.5%
associate-+l-90.5%
*-commutative90.5%
associate-/r*99.8%
sub-div99.8%
Applied egg-rr99.8%
if 1e-22 < t Initial program 99.9%
Final simplification99.5%
(FPCore (x y z t)
:precision binary64
(if (<= y -0.0024)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y -1.6e-65)
(+ x (* t (/ 0.3333333333333333 (* y z))))
(if (<= y -2.4e-72)
(- x (* 0.3333333333333333 (/ y z)))
(if (<= y -9e-251)
(+ x (/ (* 0.3333333333333333 (/ t y)) z))
(if (<= y 9.5e+30)
(+ x (* t (/ (/ 0.3333333333333333 z) y)))
(- x (/ y (* z 3.0)))))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.0024) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= -1.6e-65) {
tmp = x + (t * (0.3333333333333333 / (y * z)));
} else if (y <= -2.4e-72) {
tmp = x - (0.3333333333333333 * (y / z));
} else if (y <= -9e-251) {
tmp = x + ((0.3333333333333333 * (t / y)) / z);
} else if (y <= 9.5e+30) {
tmp = x + (t * ((0.3333333333333333 / z) / y));
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-0.0024d0)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= (-1.6d-65)) then
tmp = x + (t * (0.3333333333333333d0 / (y * z)))
else if (y <= (-2.4d-72)) then
tmp = x - (0.3333333333333333d0 * (y / z))
else if (y <= (-9d-251)) then
tmp = x + ((0.3333333333333333d0 * (t / y)) / z)
else if (y <= 9.5d+30) then
tmp = x + (t * ((0.3333333333333333d0 / z) / y))
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.0024) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= -1.6e-65) {
tmp = x + (t * (0.3333333333333333 / (y * z)));
} else if (y <= -2.4e-72) {
tmp = x - (0.3333333333333333 * (y / z));
} else if (y <= -9e-251) {
tmp = x + ((0.3333333333333333 * (t / y)) / z);
} else if (y <= 9.5e+30) {
tmp = x + (t * ((0.3333333333333333 / z) / y));
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -0.0024: tmp = x + ((y * -0.3333333333333333) / z) elif y <= -1.6e-65: tmp = x + (t * (0.3333333333333333 / (y * z))) elif y <= -2.4e-72: tmp = x - (0.3333333333333333 * (y / z)) elif y <= -9e-251: tmp = x + ((0.3333333333333333 * (t / y)) / z) elif y <= 9.5e+30: tmp = x + (t * ((0.3333333333333333 / z) / y)) else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -0.0024) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= -1.6e-65) tmp = Float64(x + Float64(t * Float64(0.3333333333333333 / Float64(y * z)))); elseif (y <= -2.4e-72) tmp = Float64(x - Float64(0.3333333333333333 * Float64(y / z))); elseif (y <= -9e-251) tmp = Float64(x + Float64(Float64(0.3333333333333333 * Float64(t / y)) / z)); elseif (y <= 9.5e+30) tmp = Float64(x + Float64(t * Float64(Float64(0.3333333333333333 / z) / y))); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -0.0024) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= -1.6e-65) tmp = x + (t * (0.3333333333333333 / (y * z))); elseif (y <= -2.4e-72) tmp = x - (0.3333333333333333 * (y / z)); elseif (y <= -9e-251) tmp = x + ((0.3333333333333333 * (t / y)) / z); elseif (y <= 9.5e+30) tmp = x + (t * ((0.3333333333333333 / z) / y)); else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -0.0024], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.6e-65], N[(x + N[(t * N[(0.3333333333333333 / N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.4e-72], N[(x - N[(0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -9e-251], N[(x + N[(N[(0.3333333333333333 * N[(t / y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.5e+30], N[(x + N[(t * N[(N[(0.3333333333333333 / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -0.0024:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq -1.6 \cdot 10^{-65}:\\
\;\;\;\;x + t \cdot \frac{0.3333333333333333}{y \cdot z}\\
\mathbf{elif}\;y \leq -2.4 \cdot 10^{-72}:\\
\;\;\;\;x - 0.3333333333333333 \cdot \frac{y}{z}\\
\mathbf{elif}\;y \leq -9 \cdot 10^{-251}:\\
\;\;\;\;x + \frac{0.3333333333333333 \cdot \frac{t}{y}}{z}\\
\mathbf{elif}\;y \leq 9.5 \cdot 10^{+30}:\\
\;\;\;\;x + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -0.00239999999999999979Initial program 98.5%
Simplified99.8%
Taylor expanded in t around 0 94.2%
*-commutative94.2%
associate-*l/94.3%
associate-*r/94.2%
Simplified94.2%
Taylor expanded in y around 0 94.2%
associate-*r/94.3%
*-commutative94.3%
Simplified94.3%
if -0.00239999999999999979 < y < -1.6e-65Initial program 99.9%
Simplified80.9%
Taylor expanded in t around inf 87.1%
*-commutative87.1%
metadata-eval87.1%
times-frac87.1%
*-commutative87.1%
times-frac87.2%
associate-/r*87.2%
associate-*l/87.1%
associate-*r/87.1%
associate-/r*87.1%
associate-/l/87.1%
associate-/r*87.1%
*-commutative87.1%
associate-/r*87.1%
metadata-eval87.1%
Simplified87.1%
Taylor expanded in z around 0 87.1%
if -1.6e-65 < y < -2.4e-72Initial program 100.0%
associate-*l*100.0%
*-commutative100.0%
Simplified100.0%
Taylor expanded in t around 0 100.0%
if -2.4e-72 < y < -8.99999999999999956e-251Initial program 83.6%
Simplified95.9%
*-commutative95.9%
associate-*r/95.8%
Applied egg-rr95.8%
Taylor expanded in t around inf 95.8%
if -8.99999999999999956e-251 < y < 9.5000000000000003e30Initial program 96.6%
Simplified88.0%
Taylor expanded in t around inf 92.0%
*-commutative92.0%
metadata-eval92.0%
times-frac92.0%
*-commutative92.0%
times-frac92.1%
associate-/r*92.0%
associate-*l/92.0%
associate-*r/92.0%
associate-/r*92.1%
associate-/l/92.0%
associate-/r*92.1%
*-commutative92.1%
associate-/r*92.0%
metadata-eval92.0%
Simplified92.0%
if 9.5000000000000003e30 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 94.1%
metadata-eval94.1%
times-frac94.2%
*-un-lft-identity94.2%
*-commutative94.2%
Applied egg-rr94.2%
Final simplification93.4%
(FPCore (x y z t) :precision binary64 (if (or (<= t -2e-50) (not (<= t 6e-43))) (+ (- x (/ y (* z 3.0))) (/ t (* z (* y 3.0)))) (+ x (/ (- (/ t y) y) (* z 3.0)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((t <= -2e-50) || !(t <= 6e-43)) {
tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0)));
} else {
tmp = x + (((t / y) - y) / (z * 3.0));
}
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 <= (-2d-50)) .or. (.not. (t <= 6d-43))) then
tmp = (x - (y / (z * 3.0d0))) + (t / (z * (y * 3.0d0)))
else
tmp = x + (((t / y) - y) / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((t <= -2e-50) || !(t <= 6e-43)) {
tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0)));
} else {
tmp = x + (((t / y) - y) / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (t <= -2e-50) or not (t <= 6e-43): tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0))) else: tmp = x + (((t / y) - y) / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((t <= -2e-50) || !(t <= 6e-43)) tmp = Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(t / Float64(z * Float64(y * 3.0)))); else tmp = Float64(x + Float64(Float64(Float64(t / y) - y) / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((t <= -2e-50) || ~((t <= 6e-43))) tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0))); else tmp = x + (((t / y) - y) / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[t, -2e-50], N[Not[LessEqual[t, 6e-43]], $MachinePrecision]], N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t / N[(z * N[(y * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2 \cdot 10^{-50} \lor \neg \left(t \leq 6 \cdot 10^{-43}\right):\\
\;\;\;\;\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{z \cdot \left(y \cdot 3\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{\frac{t}{y} - y}{z \cdot 3}\\
\end{array}
\end{array}
if t < -2.00000000000000002e-50 or 6.00000000000000007e-43 < t Initial program 99.3%
associate-*l*99.3%
*-commutative99.3%
Simplified99.3%
if -2.00000000000000002e-50 < t < 6.00000000000000007e-43Initial program 90.2%
associate-*l*90.2%
*-commutative90.2%
Simplified90.2%
*-commutative90.2%
associate-*l*90.2%
associate-+l-90.2%
*-commutative90.2%
associate-/r*99.8%
sub-div99.8%
Applied egg-rr99.8%
Final simplification99.5%
(FPCore (x y z t) :precision binary64 (if (<= y 7.8e-180) (- (+ (/ (/ t z) (* y 3.0)) x) (* y (/ 0.3333333333333333 z))) (+ (- x (/ y (* z 3.0))) (/ t (* z (* y 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= 7.8e-180) {
tmp = (((t / z) / (y * 3.0)) + x) - (y * (0.3333333333333333 / z));
} else {
tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0)));
}
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 (y <= 7.8d-180) then
tmp = (((t / z) / (y * 3.0d0)) + x) - (y * (0.3333333333333333d0 / z))
else
tmp = (x - (y / (z * 3.0d0))) + (t / (z * (y * 3.0d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= 7.8e-180) {
tmp = (((t / z) / (y * 3.0)) + x) - (y * (0.3333333333333333 / z));
} else {
tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0)));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= 7.8e-180: tmp = (((t / z) / (y * 3.0)) + x) - (y * (0.3333333333333333 / z)) else: tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0))) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= 7.8e-180) tmp = Float64(Float64(Float64(Float64(t / z) / Float64(y * 3.0)) + x) - Float64(y * Float64(0.3333333333333333 / z))); else tmp = Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(t / Float64(z * Float64(y * 3.0)))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= 7.8e-180) tmp = (((t / z) / (y * 3.0)) + x) - (y * (0.3333333333333333 / z)); else tmp = (x - (y / (z * 3.0))) + (t / (z * (y * 3.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, 7.8e-180], N[(N[(N[(N[(t / z), $MachinePrecision] / N[(y * 3.0), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision] - N[(y * N[(0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t / N[(z * N[(y * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 7.8 \cdot 10^{-180}:\\
\;\;\;\;\left(\frac{\frac{t}{z}}{y \cdot 3} + x\right) - y \cdot \frac{0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{z \cdot \left(y \cdot 3\right)}\\
\end{array}
\end{array}
if y < 7.8000000000000005e-180Initial program 93.0%
associate-*l*93.0%
*-commutative93.0%
Simplified93.0%
+-commutative93.0%
*-commutative93.0%
associate-*l*93.0%
associate-+r-93.0%
associate-*l*93.0%
*-commutative93.0%
associate-/r*98.2%
div-inv98.2%
metadata-eval98.2%
div-inv98.2%
clear-num98.2%
Applied egg-rr98.2%
if 7.8000000000000005e-180 < y Initial program 99.8%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Final simplification98.8%
(FPCore (x y z t)
:precision binary64
(if (<= y -1.6e-13)
(/ (* y -0.3333333333333333) z)
(if (<= y -7.2e-130)
x
(if (<= y 3.6e+31)
(* 0.3333333333333333 (/ t (* y z)))
(* -0.3333333333333333 (/ y z))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.6e-13) {
tmp = (y * -0.3333333333333333) / z;
} else if (y <= -7.2e-130) {
tmp = x;
} else if (y <= 3.6e+31) {
tmp = 0.3333333333333333 * (t / (y * z));
} else {
tmp = -0.3333333333333333 * (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 (y <= (-1.6d-13)) then
tmp = (y * (-0.3333333333333333d0)) / z
else if (y <= (-7.2d-130)) then
tmp = x
else if (y <= 3.6d+31) then
tmp = 0.3333333333333333d0 * (t / (y * z))
else
tmp = (-0.3333333333333333d0) * (y / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.6e-13) {
tmp = (y * -0.3333333333333333) / z;
} else if (y <= -7.2e-130) {
tmp = x;
} else if (y <= 3.6e+31) {
tmp = 0.3333333333333333 * (t / (y * z));
} else {
tmp = -0.3333333333333333 * (y / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.6e-13: tmp = (y * -0.3333333333333333) / z elif y <= -7.2e-130: tmp = x elif y <= 3.6e+31: tmp = 0.3333333333333333 * (t / (y * z)) else: tmp = -0.3333333333333333 * (y / z) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.6e-13) tmp = Float64(Float64(y * -0.3333333333333333) / z); elseif (y <= -7.2e-130) tmp = x; elseif (y <= 3.6e+31) tmp = Float64(0.3333333333333333 * Float64(t / Float64(y * z))); else tmp = Float64(-0.3333333333333333 * Float64(y / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.6e-13) tmp = (y * -0.3333333333333333) / z; elseif (y <= -7.2e-130) tmp = x; elseif (y <= 3.6e+31) tmp = 0.3333333333333333 * (t / (y * z)); else tmp = -0.3333333333333333 * (y / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.6e-13], N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[y, -7.2e-130], x, If[LessEqual[y, 3.6e+31], N[(0.3333333333333333 * N[(t / N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.6 \cdot 10^{-13}:\\
\;\;\;\;\frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq -7.2 \cdot 10^{-130}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 3.6 \cdot 10^{+31}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{t}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\
\end{array}
\end{array}
if y < -1.6e-13Initial program 98.5%
associate-*l*98.5%
*-commutative98.5%
Simplified98.5%
*-commutative98.5%
associate-*l*98.5%
associate-+l-98.5%
*-commutative98.5%
associate-/r*99.8%
sub-div99.8%
Applied egg-rr99.8%
Taylor expanded in y around inf 58.4%
associate-*r/58.5%
Simplified58.5%
if -1.6e-13 < y < -7.2000000000000003e-130Initial program 96.4%
Simplified85.4%
Taylor expanded in x around inf 62.5%
if -7.2000000000000003e-130 < y < 3.59999999999999996e31Initial program 92.3%
associate-*l*92.4%
*-commutative92.4%
Simplified92.4%
*-commutative92.4%
associate-*l*92.3%
associate-+l-92.3%
*-commutative92.3%
associate-/r*90.1%
sub-div90.1%
Applied egg-rr90.1%
Taylor expanded in y around 0 68.4%
if 3.59999999999999996e31 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
*-commutative99.9%
associate-*l*99.9%
associate-+l-99.9%
*-commutative99.9%
associate-/r*99.9%
sub-div99.9%
Applied egg-rr99.9%
Taylor expanded in y around inf 66.4%
Final simplification65.3%
(FPCore (x y z t)
:precision binary64
(if (<= y -6.5e-14)
(/ (* y -0.3333333333333333) z)
(if (<= y -1.25e-129)
x
(if (<= y 4.6e+31)
(* 0.3333333333333333 (/ (/ t z) y))
(* -0.3333333333333333 (/ y z))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -6.5e-14) {
tmp = (y * -0.3333333333333333) / z;
} else if (y <= -1.25e-129) {
tmp = x;
} else if (y <= 4.6e+31) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = -0.3333333333333333 * (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 (y <= (-6.5d-14)) then
tmp = (y * (-0.3333333333333333d0)) / z
else if (y <= (-1.25d-129)) then
tmp = x
else if (y <= 4.6d+31) then
tmp = 0.3333333333333333d0 * ((t / z) / y)
else
tmp = (-0.3333333333333333d0) * (y / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -6.5e-14) {
tmp = (y * -0.3333333333333333) / z;
} else if (y <= -1.25e-129) {
tmp = x;
} else if (y <= 4.6e+31) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = -0.3333333333333333 * (y / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -6.5e-14: tmp = (y * -0.3333333333333333) / z elif y <= -1.25e-129: tmp = x elif y <= 4.6e+31: tmp = 0.3333333333333333 * ((t / z) / y) else: tmp = -0.3333333333333333 * (y / z) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -6.5e-14) tmp = Float64(Float64(y * -0.3333333333333333) / z); elseif (y <= -1.25e-129) tmp = x; elseif (y <= 4.6e+31) tmp = Float64(0.3333333333333333 * Float64(Float64(t / z) / y)); else tmp = Float64(-0.3333333333333333 * Float64(y / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -6.5e-14) tmp = (y * -0.3333333333333333) / z; elseif (y <= -1.25e-129) tmp = x; elseif (y <= 4.6e+31) tmp = 0.3333333333333333 * ((t / z) / y); else tmp = -0.3333333333333333 * (y / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -6.5e-14], N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[y, -1.25e-129], x, If[LessEqual[y, 4.6e+31], N[(0.3333333333333333 * N[(N[(t / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(-0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.5 \cdot 10^{-14}:\\
\;\;\;\;\frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq -1.25 \cdot 10^{-129}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 4.6 \cdot 10^{+31}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{\frac{t}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\
\end{array}
\end{array}
if y < -6.5000000000000001e-14Initial program 98.5%
associate-*l*98.5%
*-commutative98.5%
Simplified98.5%
*-commutative98.5%
associate-*l*98.5%
associate-+l-98.5%
*-commutative98.5%
associate-/r*99.8%
sub-div99.8%
Applied egg-rr99.8%
Taylor expanded in y around inf 58.4%
associate-*r/58.5%
Simplified58.5%
if -6.5000000000000001e-14 < y < -1.25000000000000007e-129Initial program 96.4%
Simplified85.4%
Taylor expanded in x around inf 62.5%
if -1.25000000000000007e-129 < y < 4.5999999999999999e31Initial program 92.3%
associate-*l*92.4%
*-commutative92.4%
Simplified92.4%
*-commutative92.4%
associate-*l*92.3%
associate-+l-92.3%
*-commutative92.3%
associate-/r*90.1%
sub-div90.1%
Applied egg-rr90.1%
Taylor expanded in y around 0 68.4%
expm1-log1p-u37.2%
expm1-udef29.5%
*-commutative29.5%
Applied egg-rr29.5%
expm1-def37.2%
expm1-log1p68.4%
associate-/r*72.4%
Simplified72.4%
if 4.5999999999999999e31 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
*-commutative99.9%
associate-*l*99.9%
associate-+l-99.9%
*-commutative99.9%
associate-/r*99.9%
sub-div99.9%
Applied egg-rr99.9%
Taylor expanded in y around inf 66.4%
Final simplification67.3%
(FPCore (x y z t)
:precision binary64
(if (<= y -0.00037)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 6.6e+30)
(+ x (* t (/ 0.3333333333333333 (* y z))))
(- x (/ y (* z 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.00037) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 6.6e+30) {
tmp = x + (t * (0.3333333333333333 / (y * z)));
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-0.00037d0)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 6.6d+30) then
tmp = x + (t * (0.3333333333333333d0 / (y * z)))
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.00037) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 6.6e+30) {
tmp = x + (t * (0.3333333333333333 / (y * z)));
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -0.00037: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 6.6e+30: tmp = x + (t * (0.3333333333333333 / (y * z))) else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -0.00037) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 6.6e+30) tmp = Float64(x + Float64(t * Float64(0.3333333333333333 / Float64(y * z)))); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -0.00037) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 6.6e+30) tmp = x + (t * (0.3333333333333333 / (y * z))); else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -0.00037], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.6e+30], N[(x + N[(t * N[(0.3333333333333333 / N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -0.00037:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 6.6 \cdot 10^{+30}:\\
\;\;\;\;x + t \cdot \frac{0.3333333333333333}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -3.6999999999999999e-4Initial program 98.5%
Simplified99.8%
Taylor expanded in t around 0 94.2%
*-commutative94.2%
associate-*l/94.3%
associate-*r/94.2%
Simplified94.2%
Taylor expanded in y around 0 94.2%
associate-*r/94.3%
*-commutative94.3%
Simplified94.3%
if -3.6999999999999999e-4 < y < 6.60000000000000053e30Initial program 93.0%
Simplified89.3%
Taylor expanded in t around inf 88.5%
*-commutative88.5%
metadata-eval88.5%
times-frac88.5%
*-commutative88.5%
times-frac88.6%
associate-/r*88.6%
associate-*l/88.6%
associate-*r/88.6%
associate-/r*88.6%
associate-/l/88.6%
associate-/r*88.6%
*-commutative88.6%
associate-/r*88.6%
metadata-eval88.6%
Simplified88.6%
Taylor expanded in z around 0 88.5%
if 6.60000000000000053e30 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 94.1%
metadata-eval94.1%
times-frac94.2%
*-un-lft-identity94.2%
*-commutative94.2%
Applied egg-rr94.2%
Final simplification90.8%
(FPCore (x y z t)
:precision binary64
(if (<= y -0.011)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 1.05e+31)
(+ x (* t (/ (/ 0.3333333333333333 z) y)))
(- x (/ y (* z 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.011) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 1.05e+31) {
tmp = x + (t * ((0.3333333333333333 / z) / y));
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-0.011d0)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 1.05d+31) then
tmp = x + (t * ((0.3333333333333333d0 / z) / y))
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.011) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 1.05e+31) {
tmp = x + (t * ((0.3333333333333333 / z) / y));
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -0.011: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 1.05e+31: tmp = x + (t * ((0.3333333333333333 / z) / y)) else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -0.011) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 1.05e+31) tmp = Float64(x + Float64(t * Float64(Float64(0.3333333333333333 / z) / y))); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -0.011) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 1.05e+31) tmp = x + (t * ((0.3333333333333333 / z) / y)); else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -0.011], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.05e+31], N[(x + N[(t * N[(N[(0.3333333333333333 / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -0.011:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 1.05 \cdot 10^{+31}:\\
\;\;\;\;x + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -0.010999999999999999Initial program 98.5%
Simplified99.8%
Taylor expanded in t around 0 94.2%
*-commutative94.2%
associate-*l/94.3%
associate-*r/94.2%
Simplified94.2%
Taylor expanded in y around 0 94.2%
associate-*r/94.3%
*-commutative94.3%
Simplified94.3%
if -0.010999999999999999 < y < 1.04999999999999989e31Initial program 93.0%
Simplified89.3%
Taylor expanded in t around inf 88.5%
*-commutative88.5%
metadata-eval88.5%
times-frac88.5%
*-commutative88.5%
times-frac88.6%
associate-/r*88.6%
associate-*l/88.6%
associate-*r/88.6%
associate-/r*88.6%
associate-/l/88.6%
associate-/r*88.6%
*-commutative88.6%
associate-/r*88.6%
metadata-eval88.6%
Simplified88.6%
if 1.04999999999999989e31 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 94.1%
metadata-eval94.1%
times-frac94.2%
*-un-lft-identity94.2%
*-commutative94.2%
Applied egg-rr94.2%
Final simplification90.8%
(FPCore (x y z t)
:precision binary64
(if (<= y -0.006)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 9.8e+30)
(+ x (/ (* t (/ 0.3333333333333333 z)) y))
(- x (/ y (* z 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.006) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 9.8e+30) {
tmp = x + ((t * (0.3333333333333333 / z)) / y);
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-0.006d0)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 9.8d+30) then
tmp = x + ((t * (0.3333333333333333d0 / z)) / y)
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.006) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 9.8e+30) {
tmp = x + ((t * (0.3333333333333333 / z)) / y);
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -0.006: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 9.8e+30: tmp = x + ((t * (0.3333333333333333 / z)) / y) else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -0.006) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 9.8e+30) tmp = Float64(x + Float64(Float64(t * Float64(0.3333333333333333 / z)) / y)); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -0.006) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 9.8e+30) tmp = x + ((t * (0.3333333333333333 / z)) / y); else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -0.006], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+30], N[(x + N[(N[(t * N[(0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -0.006:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 9.8 \cdot 10^{+30}:\\
\;\;\;\;x + \frac{t \cdot \frac{0.3333333333333333}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -0.0060000000000000001Initial program 98.5%
Simplified99.8%
Taylor expanded in t around 0 94.2%
*-commutative94.2%
associate-*l/94.3%
associate-*r/94.2%
Simplified94.2%
Taylor expanded in y around 0 94.2%
associate-*r/94.3%
*-commutative94.3%
Simplified94.3%
if -0.0060000000000000001 < y < 9.79999999999999969e30Initial program 93.0%
Simplified89.3%
Taylor expanded in t around inf 88.5%
*-commutative88.5%
metadata-eval88.5%
times-frac88.5%
*-commutative88.5%
times-frac88.6%
associate-/r*88.6%
associate-*l/88.6%
associate-*r/88.6%
associate-/r*88.6%
associate-/l/88.6%
associate-/r*88.6%
*-commutative88.6%
associate-/r*88.6%
metadata-eval88.6%
Simplified88.6%
associate-*r/93.6%
Applied egg-rr93.6%
if 9.79999999999999969e30 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 94.1%
metadata-eval94.1%
times-frac94.2%
*-un-lft-identity94.2%
*-commutative94.2%
Applied egg-rr94.2%
Final simplification93.9%
(FPCore (x y z t) :precision binary64 (if (<= y -0.0027) (+ x (/ (* y -0.3333333333333333) z)) (if (<= y 6.6e+30) (+ x (/ (/ (/ t 3.0) z) y)) (- x (/ y (* z 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.0027) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 6.6e+30) {
tmp = x + (((t / 3.0) / z) / y);
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-0.0027d0)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 6.6d+30) then
tmp = x + (((t / 3.0d0) / z) / y)
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -0.0027) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 6.6e+30) {
tmp = x + (((t / 3.0) / z) / y);
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -0.0027: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 6.6e+30: tmp = x + (((t / 3.0) / z) / y) else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -0.0027) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 6.6e+30) tmp = Float64(x + Float64(Float64(Float64(t / 3.0) / z) / y)); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -0.0027) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 6.6e+30) tmp = x + (((t / 3.0) / z) / y); else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -0.0027], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.6e+30], N[(x + N[(N[(N[(t / 3.0), $MachinePrecision] / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -0.0027:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 6.6 \cdot 10^{+30}:\\
\;\;\;\;x + \frac{\frac{\frac{t}{3}}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -0.0027000000000000001Initial program 98.5%
Simplified99.8%
Taylor expanded in t around 0 94.2%
*-commutative94.2%
associate-*l/94.3%
associate-*r/94.2%
Simplified94.2%
Taylor expanded in y around 0 94.2%
associate-*r/94.3%
*-commutative94.3%
Simplified94.3%
if -0.0027000000000000001 < y < 6.60000000000000053e30Initial program 93.0%
Simplified89.3%
Taylor expanded in t around inf 88.5%
*-commutative88.5%
metadata-eval88.5%
times-frac88.5%
*-commutative88.5%
times-frac88.6%
associate-/r*88.6%
associate-*l/88.6%
associate-*r/88.6%
associate-/r*88.6%
associate-/l/88.6%
associate-/r*88.6%
*-commutative88.6%
associate-/r*88.6%
metadata-eval88.6%
Simplified88.6%
associate-*r/93.6%
Applied egg-rr93.6%
clear-num93.5%
div-inv93.6%
metadata-eval93.6%
un-div-inv93.5%
Applied egg-rr93.5%
*-commutative93.5%
associate-/r*93.6%
Simplified93.6%
if 6.60000000000000053e30 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 94.1%
metadata-eval94.1%
times-frac94.2%
*-un-lft-identity94.2%
*-commutative94.2%
Applied egg-rr94.2%
Final simplification93.9%
(FPCore (x y z t) :precision binary64 (if (<= t -2.7e+164) (+ x (/ (/ (/ t 3.0) z) y)) (- x (* (/ 0.3333333333333333 z) (- y (/ t y))))))
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -2.7e+164) {
tmp = x + (((t / 3.0) / z) / y);
} else {
tmp = x - ((0.3333333333333333 / z) * (y - (t / y)));
}
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.7d+164)) then
tmp = x + (((t / 3.0d0) / z) / y)
else
tmp = x - ((0.3333333333333333d0 / z) * (y - (t / y)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -2.7e+164) {
tmp = x + (((t / 3.0) / z) / y);
} else {
tmp = x - ((0.3333333333333333 / z) * (y - (t / y)));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if t <= -2.7e+164: tmp = x + (((t / 3.0) / z) / y) else: tmp = x - ((0.3333333333333333 / z) * (y - (t / y))) return tmp
function code(x, y, z, t) tmp = 0.0 if (t <= -2.7e+164) tmp = Float64(x + Float64(Float64(Float64(t / 3.0) / z) / y)); else tmp = Float64(x - Float64(Float64(0.3333333333333333 / z) * Float64(y - Float64(t / y)))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (t <= -2.7e+164) tmp = x + (((t / 3.0) / z) / y); else tmp = x - ((0.3333333333333333 / z) * (y - (t / y))); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[t, -2.7e+164], N[(x + N[(N[(N[(t / 3.0), $MachinePrecision] / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x - N[(N[(0.3333333333333333 / z), $MachinePrecision] * N[(y - N[(t / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.7 \cdot 10^{+164}:\\
\;\;\;\;x + \frac{\frac{\frac{t}{3}}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{0.3333333333333333}{z} \cdot \left(y - \frac{t}{y}\right)\\
\end{array}
\end{array}
if t < -2.70000000000000006e164Initial program 97.7%
Simplified73.2%
Taylor expanded in t around inf 90.5%
*-commutative90.5%
metadata-eval90.5%
times-frac90.3%
*-commutative90.3%
times-frac90.4%
associate-/r*90.4%
associate-*l/90.5%
associate-*r/90.4%
associate-/r*90.3%
associate-/l/90.3%
associate-/r*90.3%
*-commutative90.3%
associate-/r*90.4%
metadata-eval90.4%
Simplified90.4%
associate-*r/92.4%
Applied egg-rr92.4%
clear-num92.3%
div-inv92.4%
metadata-eval92.4%
un-div-inv92.4%
Applied egg-rr92.4%
*-commutative92.4%
associate-/r*92.5%
Simplified92.5%
if -2.70000000000000006e164 < t Initial program 95.2%
Simplified96.7%
Final simplification96.1%
(FPCore (x y z t) :precision binary64 (if (<= t -3.7e+164) (+ x (/ (/ (/ t 3.0) z) y)) (+ x (/ (- (/ t y) y) (* z 3.0)))))
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -3.7e+164) {
tmp = x + (((t / 3.0) / z) / y);
} else {
tmp = x + (((t / y) - y) / (z * 3.0));
}
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 <= (-3.7d+164)) then
tmp = x + (((t / 3.0d0) / z) / y)
else
tmp = x + (((t / y) - y) / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -3.7e+164) {
tmp = x + (((t / 3.0) / z) / y);
} else {
tmp = x + (((t / y) - y) / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if t <= -3.7e+164: tmp = x + (((t / 3.0) / z) / y) else: tmp = x + (((t / y) - y) / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (t <= -3.7e+164) tmp = Float64(x + Float64(Float64(Float64(t / 3.0) / z) / y)); else tmp = Float64(x + Float64(Float64(Float64(t / y) - y) / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (t <= -3.7e+164) tmp = x + (((t / 3.0) / z) / y); else tmp = x + (((t / y) - y) / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[t, -3.7e+164], N[(x + N[(N[(N[(t / 3.0), $MachinePrecision] / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.7 \cdot 10^{+164}:\\
\;\;\;\;x + \frac{\frac{\frac{t}{3}}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{\frac{t}{y} - y}{z \cdot 3}\\
\end{array}
\end{array}
if t < -3.7000000000000001e164Initial program 97.7%
Simplified73.2%
Taylor expanded in t around inf 90.5%
*-commutative90.5%
metadata-eval90.5%
times-frac90.3%
*-commutative90.3%
times-frac90.4%
associate-/r*90.4%
associate-*l/90.5%
associate-*r/90.4%
associate-/r*90.3%
associate-/l/90.3%
associate-/r*90.3%
*-commutative90.3%
associate-/r*90.4%
metadata-eval90.4%
Simplified90.4%
associate-*r/92.4%
Applied egg-rr92.4%
clear-num92.3%
div-inv92.4%
metadata-eval92.4%
un-div-inv92.4%
Applied egg-rr92.4%
*-commutative92.4%
associate-/r*92.5%
Simplified92.5%
if -3.7000000000000001e164 < t Initial program 95.2%
associate-*l*95.2%
*-commutative95.2%
Simplified95.2%
*-commutative95.2%
associate-*l*95.2%
associate-+l-95.2%
*-commutative95.2%
associate-/r*96.8%
sub-div96.8%
Applied egg-rr96.8%
Final simplification96.2%
(FPCore (x y z t) :precision binary64 (if (or (<= y -1.25e-129) (not (<= y 2.4e-19))) (+ x (* y (/ -0.3333333333333333 z))) (* 0.3333333333333333 (/ (/ t z) y))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -1.25e-129) || !(y <= 2.4e-19)) {
tmp = x + (y * (-0.3333333333333333 / z));
} else {
tmp = 0.3333333333333333 * ((t / z) / y);
}
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 ((y <= (-1.25d-129)) .or. (.not. (y <= 2.4d-19))) then
tmp = x + (y * ((-0.3333333333333333d0) / z))
else
tmp = 0.3333333333333333d0 * ((t / z) / y)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -1.25e-129) || !(y <= 2.4e-19)) {
tmp = x + (y * (-0.3333333333333333 / z));
} else {
tmp = 0.3333333333333333 * ((t / z) / y);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -1.25e-129) or not (y <= 2.4e-19): tmp = x + (y * (-0.3333333333333333 / z)) else: tmp = 0.3333333333333333 * ((t / z) / y) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -1.25e-129) || !(y <= 2.4e-19)) tmp = Float64(x + Float64(y * Float64(-0.3333333333333333 / z))); else tmp = Float64(0.3333333333333333 * Float64(Float64(t / z) / y)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -1.25e-129) || ~((y <= 2.4e-19))) tmp = x + (y * (-0.3333333333333333 / z)); else tmp = 0.3333333333333333 * ((t / z) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -1.25e-129], N[Not[LessEqual[y, 2.4e-19]], $MachinePrecision]], N[(x + N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(0.3333333333333333 * N[(N[(t / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.25 \cdot 10^{-129} \lor \neg \left(y \leq 2.4 \cdot 10^{-19}\right):\\
\;\;\;\;x + y \cdot \frac{-0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{\frac{t}{z}}{y}\\
\end{array}
\end{array}
if y < -1.25000000000000007e-129 or 2.40000000000000023e-19 < y Initial program 98.7%
Simplified97.1%
Taylor expanded in t around 0 86.6%
*-commutative86.6%
associate-*l/86.5%
associate-*r/86.5%
Simplified86.5%
if -1.25000000000000007e-129 < y < 2.40000000000000023e-19Initial program 91.5%
associate-*l*91.6%
*-commutative91.6%
Simplified91.6%
*-commutative91.6%
associate-*l*91.5%
associate-+l-91.5%
*-commutative91.5%
associate-/r*89.1%
sub-div89.1%
Applied egg-rr89.1%
Taylor expanded in y around 0 71.9%
expm1-log1p-u39.2%
expm1-udef31.6%
*-commutative31.6%
Applied egg-rr31.6%
expm1-def39.2%
expm1-log1p71.9%
associate-/r*76.4%
Simplified76.4%
Final simplification81.9%
(FPCore (x y z t)
:precision binary64
(if (<= y -1.05e-129)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 4.2e-20)
(* 0.3333333333333333 (/ (/ t z) y))
(+ x (* y (/ -0.3333333333333333 z))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.05e-129) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 4.2e-20) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = x + (y * (-0.3333333333333333 / 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 (y <= (-1.05d-129)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 4.2d-20) then
tmp = 0.3333333333333333d0 * ((t / z) / y)
else
tmp = x + (y * ((-0.3333333333333333d0) / z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.05e-129) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 4.2e-20) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = x + (y * (-0.3333333333333333 / z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.05e-129: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 4.2e-20: tmp = 0.3333333333333333 * ((t / z) / y) else: tmp = x + (y * (-0.3333333333333333 / z)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.05e-129) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 4.2e-20) tmp = Float64(0.3333333333333333 * Float64(Float64(t / z) / y)); else tmp = Float64(x + Float64(y * Float64(-0.3333333333333333 / z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.05e-129) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 4.2e-20) tmp = 0.3333333333333333 * ((t / z) / y); else tmp = x + (y * (-0.3333333333333333 / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.05e-129], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.2e-20], N[(0.3333333333333333 * N[(N[(t / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.05 \cdot 10^{-129}:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 4.2 \cdot 10^{-20}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{\frac{t}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \frac{-0.3333333333333333}{z}\\
\end{array}
\end{array}
if y < -1.05e-129Initial program 97.8%
Simplified95.1%
Taylor expanded in t around 0 84.7%
*-commutative84.7%
associate-*l/84.8%
associate-*r/84.7%
Simplified84.7%
Taylor expanded in y around 0 84.7%
associate-*r/84.8%
*-commutative84.8%
Simplified84.8%
if -1.05e-129 < y < 4.1999999999999998e-20Initial program 91.5%
associate-*l*91.6%
*-commutative91.6%
Simplified91.6%
*-commutative91.6%
associate-*l*91.5%
associate-+l-91.5%
*-commutative91.5%
associate-/r*89.1%
sub-div89.1%
Applied egg-rr89.1%
Taylor expanded in y around 0 71.9%
expm1-log1p-u39.2%
expm1-udef31.6%
*-commutative31.6%
Applied egg-rr31.6%
expm1-def39.2%
expm1-log1p71.9%
associate-/r*76.4%
Simplified76.4%
if 4.1999999999999998e-20 < y Initial program 99.9%
Simplified99.7%
Taylor expanded in t around 0 89.0%
*-commutative89.0%
associate-*l/88.8%
associate-*r/88.8%
Simplified88.8%
Final simplification82.0%
(FPCore (x y z t)
:precision binary64
(if (<= y -5.4e-130)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 4.2e-20)
(* 0.3333333333333333 (/ (/ t z) y))
(- x (* 0.3333333333333333 (/ y z))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.4e-130) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 4.2e-20) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = x - (0.3333333333333333 * (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 (y <= (-5.4d-130)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 4.2d-20) then
tmp = 0.3333333333333333d0 * ((t / z) / y)
else
tmp = x - (0.3333333333333333d0 * (y / z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.4e-130) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 4.2e-20) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = x - (0.3333333333333333 * (y / z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -5.4e-130: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 4.2e-20: tmp = 0.3333333333333333 * ((t / z) / y) else: tmp = x - (0.3333333333333333 * (y / z)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -5.4e-130) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 4.2e-20) tmp = Float64(0.3333333333333333 * Float64(Float64(t / z) / y)); else tmp = Float64(x - Float64(0.3333333333333333 * Float64(y / z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -5.4e-130) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 4.2e-20) tmp = 0.3333333333333333 * ((t / z) / y); else tmp = x - (0.3333333333333333 * (y / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -5.4e-130], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.2e-20], N[(0.3333333333333333 * N[(N[(t / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x - N[(0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.4 \cdot 10^{-130}:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 4.2 \cdot 10^{-20}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{\frac{t}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - 0.3333333333333333 \cdot \frac{y}{z}\\
\end{array}
\end{array}
if y < -5.39999999999999982e-130Initial program 97.8%
Simplified95.1%
Taylor expanded in t around 0 84.7%
*-commutative84.7%
associate-*l/84.8%
associate-*r/84.7%
Simplified84.7%
Taylor expanded in y around 0 84.7%
associate-*r/84.8%
*-commutative84.8%
Simplified84.8%
if -5.39999999999999982e-130 < y < 4.1999999999999998e-20Initial program 91.5%
associate-*l*91.6%
*-commutative91.6%
Simplified91.6%
*-commutative91.6%
associate-*l*91.5%
associate-+l-91.5%
*-commutative91.5%
associate-/r*89.1%
sub-div89.1%
Applied egg-rr89.1%
Taylor expanded in y around 0 71.9%
expm1-log1p-u39.2%
expm1-udef31.6%
*-commutative31.6%
Applied egg-rr31.6%
expm1-def39.2%
expm1-log1p71.9%
associate-/r*76.4%
Simplified76.4%
if 4.1999999999999998e-20 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 89.0%
Final simplification82.0%
(FPCore (x y z t)
:precision binary64
(if (<= y -1.25e-129)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 2.4e-19)
(* 0.3333333333333333 (/ (/ t z) y))
(- x (/ y (* z 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.25e-129) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 2.4e-19) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-1.25d-129)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 2.4d-19) then
tmp = 0.3333333333333333d0 * ((t / z) / y)
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.25e-129) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 2.4e-19) {
tmp = 0.3333333333333333 * ((t / z) / y);
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.25e-129: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 2.4e-19: tmp = 0.3333333333333333 * ((t / z) / y) else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.25e-129) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 2.4e-19) tmp = Float64(0.3333333333333333 * Float64(Float64(t / z) / y)); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.25e-129) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 2.4e-19) tmp = 0.3333333333333333 * ((t / z) / y); else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.25e-129], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.4e-19], N[(0.3333333333333333 * N[(N[(t / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.25 \cdot 10^{-129}:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 2.4 \cdot 10^{-19}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{\frac{t}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -1.25000000000000007e-129Initial program 97.8%
Simplified95.1%
Taylor expanded in t around 0 84.7%
*-commutative84.7%
associate-*l/84.8%
associate-*r/84.7%
Simplified84.7%
Taylor expanded in y around 0 84.7%
associate-*r/84.8%
*-commutative84.8%
Simplified84.8%
if -1.25000000000000007e-129 < y < 2.40000000000000023e-19Initial program 91.5%
associate-*l*91.6%
*-commutative91.6%
Simplified91.6%
*-commutative91.6%
associate-*l*91.5%
associate-+l-91.5%
*-commutative91.5%
associate-/r*89.1%
sub-div89.1%
Applied egg-rr89.1%
Taylor expanded in y around 0 71.9%
expm1-log1p-u39.2%
expm1-udef31.6%
*-commutative31.6%
Applied egg-rr31.6%
expm1-def39.2%
expm1-log1p71.9%
associate-/r*76.4%
Simplified76.4%
if 2.40000000000000023e-19 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 89.0%
metadata-eval89.0%
times-frac89.0%
*-un-lft-identity89.0%
*-commutative89.0%
Applied egg-rr89.0%
Final simplification82.0%
(FPCore (x y z t)
:precision binary64
(if (<= y -1.24e-129)
(+ x (/ (* y -0.3333333333333333) z))
(if (<= y 2.7e-20)
(/ (* t (/ 0.3333333333333333 z)) y)
(- x (/ y (* z 3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.24e-129) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 2.7e-20) {
tmp = (t * (0.3333333333333333 / z)) / y;
} else {
tmp = x - (y / (z * 3.0));
}
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 (y <= (-1.24d-129)) then
tmp = x + ((y * (-0.3333333333333333d0)) / z)
else if (y <= 2.7d-20) then
tmp = (t * (0.3333333333333333d0 / z)) / y
else
tmp = x - (y / (z * 3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.24e-129) {
tmp = x + ((y * -0.3333333333333333) / z);
} else if (y <= 2.7e-20) {
tmp = (t * (0.3333333333333333 / z)) / y;
} else {
tmp = x - (y / (z * 3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.24e-129: tmp = x + ((y * -0.3333333333333333) / z) elif y <= 2.7e-20: tmp = (t * (0.3333333333333333 / z)) / y else: tmp = x - (y / (z * 3.0)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.24e-129) tmp = Float64(x + Float64(Float64(y * -0.3333333333333333) / z)); elseif (y <= 2.7e-20) tmp = Float64(Float64(t * Float64(0.3333333333333333 / z)) / y); else tmp = Float64(x - Float64(y / Float64(z * 3.0))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.24e-129) tmp = x + ((y * -0.3333333333333333) / z); elseif (y <= 2.7e-20) tmp = (t * (0.3333333333333333 / z)) / y; else tmp = x - (y / (z * 3.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.24e-129], N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.7e-20], N[(N[(t * N[(0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.24 \cdot 10^{-129}:\\
\;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 2.7 \cdot 10^{-20}:\\
\;\;\;\;\frac{t \cdot \frac{0.3333333333333333}{z}}{y}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{z \cdot 3}\\
\end{array}
\end{array}
if y < -1.24000000000000004e-129Initial program 97.8%
Simplified95.1%
Taylor expanded in t around 0 84.7%
*-commutative84.7%
associate-*l/84.8%
associate-*r/84.7%
Simplified84.7%
Taylor expanded in y around 0 84.7%
associate-*r/84.8%
*-commutative84.8%
Simplified84.8%
if -1.24000000000000004e-129 < y < 2.7e-20Initial program 91.5%
associate-*l*91.6%
*-commutative91.6%
Simplified91.6%
*-commutative91.6%
associate-*l*91.5%
associate-+l-91.5%
*-commutative91.5%
associate-/r*89.1%
sub-div89.1%
Applied egg-rr89.1%
Taylor expanded in y around 0 71.9%
*-commutative71.9%
associate-*l/71.9%
metadata-eval71.9%
div-inv72.0%
associate-/l/76.4%
associate-/l/76.3%
div-inv76.4%
*-commutative76.4%
associate-/r*76.4%
metadata-eval76.4%
Applied egg-rr76.4%
if 2.7e-20 < y Initial program 99.9%
associate-*l*99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in t around 0 89.0%
metadata-eval89.0%
times-frac89.0%
*-un-lft-identity89.0%
*-commutative89.0%
Applied egg-rr89.0%
Final simplification82.0%
(FPCore (x y z t) :precision binary64 (if (<= x -1.7e+56) x (if (<= x 6e+30) (* -0.3333333333333333 (/ y z)) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (x <= -1.7e+56) {
tmp = x;
} else if (x <= 6e+30) {
tmp = -0.3333333333333333 * (y / z);
} 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 (x <= (-1.7d+56)) then
tmp = x
else if (x <= 6d+30) then
tmp = (-0.3333333333333333d0) * (y / z)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (x <= -1.7e+56) {
tmp = x;
} else if (x <= 6e+30) {
tmp = -0.3333333333333333 * (y / z);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if x <= -1.7e+56: tmp = x elif x <= 6e+30: tmp = -0.3333333333333333 * (y / z) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (x <= -1.7e+56) tmp = x; elseif (x <= 6e+30) tmp = Float64(-0.3333333333333333 * Float64(y / z)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (x <= -1.7e+56) tmp = x; elseif (x <= 6e+30) tmp = -0.3333333333333333 * (y / z); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[x, -1.7e+56], x, If[LessEqual[x, 6e+30], N[(-0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.7 \cdot 10^{+56}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+30}:\\
\;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -1.7e56 or 5.99999999999999956e30 < x Initial program 93.6%
Simplified97.2%
Taylor expanded in x around inf 65.7%
if -1.7e56 < x < 5.99999999999999956e30Initial program 96.8%
associate-*l*96.8%
*-commutative96.8%
Simplified96.8%
*-commutative96.8%
associate-*l*96.8%
associate-+l-96.8%
*-commutative96.8%
associate-/r*91.2%
sub-div91.2%
Applied egg-rr91.2%
Taylor expanded in y around inf 39.3%
Final simplification49.8%
(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 95.5%
Simplified93.5%
Taylor expanded in x around inf 31.5%
Final simplification31.5%
(FPCore (x y z t) :precision binary64 (+ (- x (/ y (* z 3.0))) (/ (/ t (* z 3.0)) y)))
double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + ((t / (z * 3.0)) / y);
}
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 * 3.0d0))) + ((t / (z * 3.0d0)) / y)
end function
public static double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + ((t / (z * 3.0)) / y);
}
def code(x, y, z, t): return (x - (y / (z * 3.0))) + ((t / (z * 3.0)) / y)
function code(x, y, z, t) return Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(Float64(t / Float64(z * 3.0)) / y)) end
function tmp = code(x, y, z, t) tmp = (x - (y / (z * 3.0))) + ((t / (z * 3.0)) / y); end
code[x_, y_, z_, t_] := N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(t / N[(z * 3.0), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x - \frac{y}{z \cdot 3}\right) + \frac{\frac{t}{z \cdot 3}}{y}
\end{array}
herbie shell --seed 2023331
(FPCore (x y z t)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, H"
:precision binary64
:herbie-target
(+ (- x (/ y (* z 3.0))) (/ (/ t (* z 3.0)) y))
(+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))