
(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))) (/ t (* y (* z 3.0)))))) (if (<= t_1 4e+289) t_1 (+ x (* -0.3333333333333333 (/ (- y (/ t y)) z))))))
double code(double x, double y, double z, double t) {
double t_1 = (x - (y / (z * 3.0))) + (t / (y * (z * 3.0)));
double tmp;
if (t_1 <= 4e+289) {
tmp = t_1;
} else {
tmp = x + (-0.3333333333333333 * ((y - (t / 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) :: t_1
real(8) :: tmp
t_1 = (x - (y / (z * 3.0d0))) + (t / (y * (z * 3.0d0)))
if (t_1 <= 4d+289) then
tmp = t_1
else
tmp = x + ((-0.3333333333333333d0) * ((y - (t / y)) / z))
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))) + (t / (y * (z * 3.0)));
double tmp;
if (t_1 <= 4e+289) {
tmp = t_1;
} else {
tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z));
}
return tmp;
}
def code(x, y, z, t): t_1 = (x - (y / (z * 3.0))) + (t / (y * (z * 3.0))) tmp = 0 if t_1 <= 4e+289: tmp = t_1 else: tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z)) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(t / Float64(y * Float64(z * 3.0)))) tmp = 0.0 if (t_1 <= 4e+289) tmp = t_1; else tmp = Float64(x + Float64(-0.3333333333333333 * Float64(Float64(y - Float64(t / y)) / z))); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (x - (y / (z * 3.0))) + (t / (y * (z * 3.0))); tmp = 0.0; if (t_1 <= 4e+289) tmp = t_1; else tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t / N[(y * N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 4e+289], t$95$1, N[(x + N[(-0.3333333333333333 * N[(N[(y - N[(t / y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{y \cdot \left(z \cdot 3\right)}\\
\mathbf{if}\;t\_1 \leq 4 \cdot 10^{+289}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x + -0.3333333333333333 \cdot \frac{y - \frac{t}{y}}{z}\\
\end{array}
\end{array}
if (+.f64 (-.f64 x (/.f64 y (*.f64 z #s(literal 3 binary64)))) (/.f64 t (*.f64 (*.f64 z #s(literal 3 binary64)) y))) < 4.0000000000000002e289Initial program 98.3%
if 4.0000000000000002e289 < (+.f64 (-.f64 x (/.f64 y (*.f64 z #s(literal 3 binary64)))) (/.f64 t (*.f64 (*.f64 z #s(literal 3 binary64)) y))) Initial program 87.2%
sub-neg87.2%
associate-+l+87.2%
remove-double-neg87.2%
distribute-frac-neg87.2%
sub-neg87.2%
distribute-frac-neg87.2%
neg-mul-187.2%
*-commutative87.2%
associate-/l*87.2%
*-commutative87.2%
neg-mul-187.2%
times-frac97.6%
distribute-lft-out--99.8%
*-commutative99.8%
associate-/r*99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in z around 0 100.0%
Final simplification98.6%
(FPCore (x y z t) :precision binary64 (if (or (<= (* z 3.0) -2e+16) (not (<= (* z 3.0) 5e+90))) (- x (/ (* y 0.3333333333333333) z)) (* 0.3333333333333333 (/ (- (/ t y) y) z))))
double code(double x, double y, double z, double t) {
double tmp;
if (((z * 3.0) <= -2e+16) || !((z * 3.0) <= 5e+90)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = 0.3333333333333333 * (((t / y) - 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 (((z * 3.0d0) <= (-2d+16)) .or. (.not. ((z * 3.0d0) <= 5d+90))) then
tmp = x - ((y * 0.3333333333333333d0) / z)
else
tmp = 0.3333333333333333d0 * (((t / y) - y) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (((z * 3.0) <= -2e+16) || !((z * 3.0) <= 5e+90)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = 0.3333333333333333 * (((t / y) - y) / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if ((z * 3.0) <= -2e+16) or not ((z * 3.0) <= 5e+90): tmp = x - ((y * 0.3333333333333333) / z) else: tmp = 0.3333333333333333 * (((t / y) - y) / z) return tmp
function code(x, y, z, t) tmp = 0.0 if ((Float64(z * 3.0) <= -2e+16) || !(Float64(z * 3.0) <= 5e+90)) tmp = Float64(x - Float64(Float64(y * 0.3333333333333333) / z)); else tmp = Float64(0.3333333333333333 * Float64(Float64(Float64(t / y) - y) / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (((z * 3.0) <= -2e+16) || ~(((z * 3.0) <= 5e+90))) tmp = x - ((y * 0.3333333333333333) / z); else tmp = 0.3333333333333333 * (((t / y) - y) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[N[(z * 3.0), $MachinePrecision], -2e+16], N[Not[LessEqual[N[(z * 3.0), $MachinePrecision], 5e+90]], $MachinePrecision]], N[(x - N[(N[(y * 0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(0.3333333333333333 * N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \cdot 3 \leq -2 \cdot 10^{+16} \lor \neg \left(z \cdot 3 \leq 5 \cdot 10^{+90}\right):\\
\;\;\;\;x - \frac{y \cdot 0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{\frac{t}{y} - y}{z}\\
\end{array}
\end{array}
if (*.f64 z #s(literal 3 binary64)) < -2e16 or 5.0000000000000004e90 < (*.f64 z #s(literal 3 binary64)) Initial program 98.8%
sub-neg98.8%
associate-+l+98.8%
distribute-frac-neg98.8%
neg-mul-198.8%
*-commutative98.8%
times-frac98.9%
fma-define98.9%
metadata-eval98.9%
associate-*l*98.8%
*-commutative98.8%
Simplified98.8%
Taylor expanded in t around 0 81.1%
metadata-eval81.1%
cancel-sign-sub-inv81.1%
associate-*r/81.2%
*-commutative81.2%
Simplified81.2%
if -2e16 < (*.f64 z #s(literal 3 binary64)) < 5.0000000000000004e90Initial program 94.3%
Taylor expanded in z around 0 90.0%
distribute-lft-out--90.0%
associate-/l*90.1%
Applied egg-rr90.1%
Final simplification86.0%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (/ (/ y -3.0) z)))
(if (<= y -1.06e+105)
t_1
(if (<= y -2.65e-135)
x
(if (<= y 6.9e+72) (* t (/ (/ 0.3333333333333333 y) z)) t_1)))))
double code(double x, double y, double z, double t) {
double t_1 = (y / -3.0) / z;
double tmp;
if (y <= -1.06e+105) {
tmp = t_1;
} else if (y <= -2.65e-135) {
tmp = x;
} else if (y <= 6.9e+72) {
tmp = t * ((0.3333333333333333 / y) / z);
} else {
tmp = t_1;
}
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 = (y / (-3.0d0)) / z
if (y <= (-1.06d+105)) then
tmp = t_1
else if (y <= (-2.65d-135)) then
tmp = x
else if (y <= 6.9d+72) then
tmp = t * ((0.3333333333333333d0 / y) / z)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (y / -3.0) / z;
double tmp;
if (y <= -1.06e+105) {
tmp = t_1;
} else if (y <= -2.65e-135) {
tmp = x;
} else if (y <= 6.9e+72) {
tmp = t * ((0.3333333333333333 / y) / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (y / -3.0) / z tmp = 0 if y <= -1.06e+105: tmp = t_1 elif y <= -2.65e-135: tmp = x elif y <= 6.9e+72: tmp = t * ((0.3333333333333333 / y) / z) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y / -3.0) / z) tmp = 0.0 if (y <= -1.06e+105) tmp = t_1; elseif (y <= -2.65e-135) tmp = x; elseif (y <= 6.9e+72) tmp = Float64(t * Float64(Float64(0.3333333333333333 / y) / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y / -3.0) / z; tmp = 0.0; if (y <= -1.06e+105) tmp = t_1; elseif (y <= -2.65e-135) tmp = x; elseif (y <= 6.9e+72) tmp = t * ((0.3333333333333333 / y) / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y / -3.0), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[y, -1.06e+105], t$95$1, If[LessEqual[y, -2.65e-135], x, If[LessEqual[y, 6.9e+72], N[(t * N[(N[(0.3333333333333333 / y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{y}{-3}}{z}\\
\mathbf{if}\;y \leq -1.06 \cdot 10^{+105}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -2.65 \cdot 10^{-135}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 6.9 \cdot 10^{+72}:\\
\;\;\;\;t \cdot \frac{\frac{0.3333333333333333}{y}}{z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.06e105 or 6.90000000000000034e72 < y Initial program 98.6%
sub-neg98.6%
associate-+l+98.6%
distribute-frac-neg98.6%
neg-mul-198.6%
*-commutative98.6%
times-frac98.6%
fma-define98.6%
metadata-eval98.6%
associate-*l*98.6%
*-commutative98.6%
Simplified98.6%
Taylor expanded in t around 0 99.6%
metadata-eval99.6%
cancel-sign-sub-inv99.6%
associate-*r/99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in x around 0 75.1%
associate-*r/75.1%
metadata-eval75.1%
distribute-lft-neg-in75.1%
add-sqr-sqrt30.7%
sqrt-unprod27.1%
sqr-neg27.1%
sqrt-unprod1.0%
add-sqr-sqrt1.6%
frac-2neg1.6%
clear-num1.6%
frac-2neg1.6%
metadata-eval1.6%
distribute-frac-neg21.6%
metadata-eval1.6%
distribute-neg-frac1.6%
clear-num1.6%
distribute-neg-frac1.6%
distribute-lft-neg-in1.6%
metadata-eval1.6%
associate-*r/1.6%
Applied egg-rr1.6%
add-sqr-sqrt0.7%
sqrt-unprod36.9%
sqr-neg36.9%
sqrt-unprod41.5%
add-sqr-sqrt75.1%
metadata-eval75.1%
times-frac75.0%
*-un-lft-identity75.0%
associate-/r*75.2%
Applied egg-rr75.2%
if -1.06e105 < y < -2.65e-135Initial program 98.0%
sub-neg98.0%
associate-+l+98.0%
distribute-frac-neg98.0%
neg-mul-198.0%
*-commutative98.0%
times-frac97.9%
fma-define97.9%
metadata-eval97.9%
associate-*l*97.9%
*-commutative97.9%
Simplified97.9%
Taylor expanded in x around inf 55.1%
if -2.65e-135 < y < 6.90000000000000034e72Initial program 93.4%
Taylor expanded in z around 0 71.7%
Taylor expanded in t around inf 67.9%
associate-*r/67.9%
*-commutative67.9%
associate-*r/67.9%
associate-/r*67.9%
Simplified67.9%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (/ (/ y -3.0) z)))
(if (<= y -9e+104)
t_1
(if (<= y -4.75e-135)
x
(if (<= y 6.9e+72) (* 0.3333333333333333 (/ t (* y z))) t_1)))))
double code(double x, double y, double z, double t) {
double t_1 = (y / -3.0) / z;
double tmp;
if (y <= -9e+104) {
tmp = t_1;
} else if (y <= -4.75e-135) {
tmp = x;
} else if (y <= 6.9e+72) {
tmp = 0.3333333333333333 * (t / (y * z));
} else {
tmp = t_1;
}
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 = (y / (-3.0d0)) / z
if (y <= (-9d+104)) then
tmp = t_1
else if (y <= (-4.75d-135)) then
tmp = x
else if (y <= 6.9d+72) then
tmp = 0.3333333333333333d0 * (t / (y * z))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (y / -3.0) / z;
double tmp;
if (y <= -9e+104) {
tmp = t_1;
} else if (y <= -4.75e-135) {
tmp = x;
} else if (y <= 6.9e+72) {
tmp = 0.3333333333333333 * (t / (y * z));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (y / -3.0) / z tmp = 0 if y <= -9e+104: tmp = t_1 elif y <= -4.75e-135: tmp = x elif y <= 6.9e+72: tmp = 0.3333333333333333 * (t / (y * z)) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y / -3.0) / z) tmp = 0.0 if (y <= -9e+104) tmp = t_1; elseif (y <= -4.75e-135) tmp = x; elseif (y <= 6.9e+72) tmp = Float64(0.3333333333333333 * Float64(t / Float64(y * z))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y / -3.0) / z; tmp = 0.0; if (y <= -9e+104) tmp = t_1; elseif (y <= -4.75e-135) tmp = x; elseif (y <= 6.9e+72) tmp = 0.3333333333333333 * (t / (y * z)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y / -3.0), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[y, -9e+104], t$95$1, If[LessEqual[y, -4.75e-135], x, If[LessEqual[y, 6.9e+72], N[(0.3333333333333333 * N[(t / N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{y}{-3}}{z}\\
\mathbf{if}\;y \leq -9 \cdot 10^{+104}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -4.75 \cdot 10^{-135}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 6.9 \cdot 10^{+72}:\\
\;\;\;\;0.3333333333333333 \cdot \frac{t}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -8.9999999999999997e104 or 6.90000000000000034e72 < y Initial program 98.6%
sub-neg98.6%
associate-+l+98.6%
distribute-frac-neg98.6%
neg-mul-198.6%
*-commutative98.6%
times-frac98.6%
fma-define98.6%
metadata-eval98.6%
associate-*l*98.6%
*-commutative98.6%
Simplified98.6%
Taylor expanded in t around 0 99.6%
metadata-eval99.6%
cancel-sign-sub-inv99.6%
associate-*r/99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in x around 0 75.1%
associate-*r/75.1%
metadata-eval75.1%
distribute-lft-neg-in75.1%
add-sqr-sqrt30.7%
sqrt-unprod27.1%
sqr-neg27.1%
sqrt-unprod1.0%
add-sqr-sqrt1.6%
frac-2neg1.6%
clear-num1.6%
frac-2neg1.6%
metadata-eval1.6%
distribute-frac-neg21.6%
metadata-eval1.6%
distribute-neg-frac1.6%
clear-num1.6%
distribute-neg-frac1.6%
distribute-lft-neg-in1.6%
metadata-eval1.6%
associate-*r/1.6%
Applied egg-rr1.6%
add-sqr-sqrt0.7%
sqrt-unprod36.9%
sqr-neg36.9%
sqrt-unprod41.5%
add-sqr-sqrt75.1%
metadata-eval75.1%
times-frac75.0%
*-un-lft-identity75.0%
associate-/r*75.2%
Applied egg-rr75.2%
if -8.9999999999999997e104 < y < -4.75000000000000004e-135Initial program 98.0%
sub-neg98.0%
associate-+l+98.0%
distribute-frac-neg98.0%
neg-mul-198.0%
*-commutative98.0%
times-frac97.9%
fma-define97.9%
metadata-eval97.9%
associate-*l*97.9%
*-commutative97.9%
Simplified97.9%
Taylor expanded in x around inf 55.1%
if -4.75000000000000004e-135 < y < 6.90000000000000034e72Initial program 93.4%
Taylor expanded in z around 0 71.7%
Taylor expanded in t around inf 67.9%
(FPCore (x y z t) :precision binary64 (if (<= (* z 3.0) 1e-220) (+ x (* -0.3333333333333333 (/ (- y (/ t y)) z))) (+ (/ y (* z -3.0)) (+ x (/ t (* z (* y 3.0)))))))
double code(double x, double y, double z, double t) {
double tmp;
if ((z * 3.0) <= 1e-220) {
tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z));
} else {
tmp = (y / (z * -3.0)) + (x + (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 ((z * 3.0d0) <= 1d-220) then
tmp = x + ((-0.3333333333333333d0) * ((y - (t / y)) / z))
else
tmp = (y / (z * (-3.0d0))) + (x + (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 ((z * 3.0) <= 1e-220) {
tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z));
} else {
tmp = (y / (z * -3.0)) + (x + (t / (z * (y * 3.0))));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z * 3.0) <= 1e-220: tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z)) else: tmp = (y / (z * -3.0)) + (x + (t / (z * (y * 3.0)))) return tmp
function code(x, y, z, t) tmp = 0.0 if (Float64(z * 3.0) <= 1e-220) tmp = Float64(x + Float64(-0.3333333333333333 * Float64(Float64(y - Float64(t / y)) / z))); else tmp = Float64(Float64(y / Float64(z * -3.0)) + Float64(x + Float64(t / Float64(z * Float64(y * 3.0))))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z * 3.0) <= 1e-220) tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z)); else tmp = (y / (z * -3.0)) + (x + (t / (z * (y * 3.0)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[N[(z * 3.0), $MachinePrecision], 1e-220], N[(x + N[(-0.3333333333333333 * N[(N[(y - N[(t / y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y / N[(z * -3.0), $MachinePrecision]), $MachinePrecision] + N[(x + N[(t / N[(z * N[(y * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \cdot 3 \leq 10^{-220}:\\
\;\;\;\;x + -0.3333333333333333 \cdot \frac{y - \frac{t}{y}}{z}\\
\mathbf{else}:\\
\;\;\;\;\frac{y}{z \cdot -3} + \left(x + \frac{t}{z \cdot \left(y \cdot 3\right)}\right)\\
\end{array}
\end{array}
if (*.f64 z #s(literal 3 binary64)) < 9.99999999999999992e-221Initial program 94.3%
sub-neg94.3%
associate-+l+94.3%
remove-double-neg94.3%
distribute-frac-neg94.3%
sub-neg94.3%
distribute-frac-neg94.3%
neg-mul-194.3%
*-commutative94.3%
associate-/l*94.3%
*-commutative94.3%
neg-mul-194.3%
times-frac97.2%
distribute-lft-out--97.8%
*-commutative97.8%
associate-/r*97.9%
metadata-eval97.9%
Simplified97.9%
Taylor expanded in z around 0 97.9%
if 9.99999999999999992e-221 < (*.f64 z #s(literal 3 binary64)) Initial program 99.7%
+-commutative99.7%
associate-+r-99.7%
sub-neg99.7%
associate-*l*99.7%
*-commutative99.7%
distribute-frac-neg299.7%
distribute-rgt-neg-in99.7%
metadata-eval99.7%
Simplified99.7%
Final simplification98.6%
(FPCore (x y z t) :precision binary64 (if (or (<= y -7e+52) (not (<= y 6.9e+72))) (- x (/ (* y 0.3333333333333333) z)) (- x (* -0.3333333333333333 (/ (/ t z) y)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -7e+52) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x - (-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 <= (-7d+52)) .or. (.not. (y <= 6.9d+72))) then
tmp = x - ((y * 0.3333333333333333d0) / z)
else
tmp = x - ((-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 <= -7e+52) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x - (-0.3333333333333333 * ((t / z) / y));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -7e+52) or not (y <= 6.9e+72): tmp = x - ((y * 0.3333333333333333) / z) else: tmp = x - (-0.3333333333333333 * ((t / z) / y)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -7e+52) || !(y <= 6.9e+72)) tmp = Float64(x - Float64(Float64(y * 0.3333333333333333) / z)); else tmp = Float64(x - 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 <= -7e+52) || ~((y <= 6.9e+72))) tmp = x - ((y * 0.3333333333333333) / z); else tmp = x - (-0.3333333333333333 * ((t / z) / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -7e+52], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x - N[(N[(y * 0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x - N[(-0.3333333333333333 * N[(N[(t / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -7 \cdot 10^{+52} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x - \frac{y \cdot 0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;x - -0.3333333333333333 \cdot \frac{\frac{t}{z}}{y}\\
\end{array}
\end{array}
if y < -7e52 or 6.90000000000000034e72 < y Initial program 98.7%
sub-neg98.7%
associate-+l+98.7%
distribute-frac-neg98.7%
neg-mul-198.7%
*-commutative98.7%
times-frac98.7%
fma-define98.7%
metadata-eval98.7%
associate-*l*98.7%
*-commutative98.7%
Simplified98.7%
Taylor expanded in t around 0 98.8%
metadata-eval98.8%
cancel-sign-sub-inv98.8%
associate-*r/98.9%
*-commutative98.9%
Simplified98.9%
if -7e52 < y < 6.90000000000000034e72Initial program 94.5%
sub-neg94.5%
associate-+l+94.5%
remove-double-neg94.5%
distribute-frac-neg94.5%
sub-neg94.5%
distribute-frac-neg94.5%
neg-mul-194.5%
*-commutative94.5%
associate-/l*94.4%
*-commutative94.4%
neg-mul-194.4%
times-frac93.1%
distribute-lft-out--93.1%
*-commutative93.1%
associate-/r*93.1%
metadata-eval93.1%
Simplified93.1%
Taylor expanded in z around 0 93.1%
Taylor expanded in y around 0 89.3%
associate-*r/89.3%
neg-mul-189.3%
*-commutative89.3%
associate-/r*91.4%
distribute-frac-neg91.4%
distribute-neg-frac291.4%
Simplified91.4%
Final simplification94.7%
(FPCore (x y z t) :precision binary64 (if (or (<= y -3.8e+52) (not (<= y 6.9e+72))) (- x (/ (* y 0.3333333333333333) z)) (- x (/ -0.3333333333333333 (/ y (/ t z))))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -3.8e+52) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x - (-0.3333333333333333 / (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 ((y <= (-3.8d+52)) .or. (.not. (y <= 6.9d+72))) then
tmp = x - ((y * 0.3333333333333333d0) / z)
else
tmp = x - ((-0.3333333333333333d0) / (y / (t / z)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -3.8e+52) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x - (-0.3333333333333333 / (y / (t / z)));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -3.8e+52) or not (y <= 6.9e+72): tmp = x - ((y * 0.3333333333333333) / z) else: tmp = x - (-0.3333333333333333 / (y / (t / z))) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -3.8e+52) || !(y <= 6.9e+72)) tmp = Float64(x - Float64(Float64(y * 0.3333333333333333) / z)); else tmp = Float64(x - Float64(-0.3333333333333333 / Float64(y / Float64(t / z)))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -3.8e+52) || ~((y <= 6.9e+72))) tmp = x - ((y * 0.3333333333333333) / z); else tmp = x - (-0.3333333333333333 / (y / (t / z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -3.8e+52], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x - N[(N[(y * 0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x - N[(-0.3333333333333333 / N[(y / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.8 \cdot 10^{+52} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x - \frac{y \cdot 0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{-0.3333333333333333}{\frac{y}{\frac{t}{z}}}\\
\end{array}
\end{array}
if y < -3.8e52 or 6.90000000000000034e72 < y Initial program 98.7%
sub-neg98.7%
associate-+l+98.7%
distribute-frac-neg98.7%
neg-mul-198.7%
*-commutative98.7%
times-frac98.7%
fma-define98.7%
metadata-eval98.7%
associate-*l*98.7%
*-commutative98.7%
Simplified98.7%
Taylor expanded in t around 0 98.8%
metadata-eval98.8%
cancel-sign-sub-inv98.8%
associate-*r/98.9%
*-commutative98.9%
Simplified98.9%
if -3.8e52 < y < 6.90000000000000034e72Initial program 94.5%
sub-neg94.5%
associate-+l+94.5%
remove-double-neg94.5%
distribute-frac-neg94.5%
sub-neg94.5%
distribute-frac-neg94.5%
neg-mul-194.5%
*-commutative94.5%
associate-/l*94.4%
*-commutative94.4%
neg-mul-194.4%
times-frac93.1%
distribute-lft-out--93.1%
*-commutative93.1%
associate-/r*93.1%
metadata-eval93.1%
Simplified93.1%
Taylor expanded in z around 0 93.1%
Taylor expanded in y around 0 89.3%
associate-*r/89.3%
neg-mul-189.3%
*-commutative89.3%
associate-/r*91.4%
distribute-frac-neg91.4%
distribute-neg-frac291.4%
Simplified91.4%
*-commutative91.4%
frac-2neg91.4%
distribute-frac-neg91.4%
add-sqr-sqrt45.5%
sqrt-unprod56.3%
sqr-neg56.3%
sqrt-unprod18.6%
add-sqr-sqrt29.8%
frac-2neg29.8%
distribute-neg-frac29.8%
frac-2neg29.8%
cancel-sign-sub-inv29.8%
*-commutative29.8%
clear-num29.8%
un-div-inv29.8%
add-sqr-sqrt11.2%
sqrt-unprod51.6%
Applied egg-rr91.4%
Final simplification94.7%
(FPCore (x y z t) :precision binary64 (if (or (<= y -6.5e+52) (not (<= y 6.9e+72))) (- x (/ (* y 0.3333333333333333) z)) (+ x (/ (/ 0.3333333333333333 y) (/ z t)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -6.5e+52) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x + ((0.3333333333333333 / y) / (z / 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 ((y <= (-6.5d+52)) .or. (.not. (y <= 6.9d+72))) then
tmp = x - ((y * 0.3333333333333333d0) / z)
else
tmp = x + ((0.3333333333333333d0 / y) / (z / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -6.5e+52) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x + ((0.3333333333333333 / y) / (z / t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -6.5e+52) or not (y <= 6.9e+72): tmp = x - ((y * 0.3333333333333333) / z) else: tmp = x + ((0.3333333333333333 / y) / (z / t)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -6.5e+52) || !(y <= 6.9e+72)) tmp = Float64(x - Float64(Float64(y * 0.3333333333333333) / z)); else tmp = Float64(x + Float64(Float64(0.3333333333333333 / y) / Float64(z / t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -6.5e+52) || ~((y <= 6.9e+72))) tmp = x - ((y * 0.3333333333333333) / z); else tmp = x + ((0.3333333333333333 / y) / (z / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -6.5e+52], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x - N[(N[(y * 0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(0.3333333333333333 / y), $MachinePrecision] / N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.5 \cdot 10^{+52} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x - \frac{y \cdot 0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{\frac{0.3333333333333333}{y}}{\frac{z}{t}}\\
\end{array}
\end{array}
if y < -6.49999999999999996e52 or 6.90000000000000034e72 < y Initial program 98.7%
sub-neg98.7%
associate-+l+98.7%
distribute-frac-neg98.7%
neg-mul-198.7%
*-commutative98.7%
times-frac98.7%
fma-define98.7%
metadata-eval98.7%
associate-*l*98.7%
*-commutative98.7%
Simplified98.7%
Taylor expanded in t around 0 98.8%
metadata-eval98.8%
cancel-sign-sub-inv98.8%
associate-*r/98.9%
*-commutative98.9%
Simplified98.9%
if -6.49999999999999996e52 < y < 6.90000000000000034e72Initial program 94.5%
sub-neg94.5%
associate-+l+94.5%
remove-double-neg94.5%
distribute-frac-neg94.5%
sub-neg94.5%
distribute-frac-neg94.5%
neg-mul-194.5%
*-commutative94.5%
associate-/l*94.4%
*-commutative94.4%
neg-mul-194.4%
times-frac93.1%
distribute-lft-out--93.1%
*-commutative93.1%
associate-/r*93.1%
metadata-eval93.1%
Simplified93.1%
Taylor expanded in z around 0 93.1%
Taylor expanded in y around 0 89.3%
associate-*r/89.3%
neg-mul-189.3%
*-commutative89.3%
associate-/r*91.4%
distribute-frac-neg91.4%
distribute-neg-frac291.4%
Simplified91.4%
*-commutative91.4%
frac-2neg91.4%
distribute-frac-neg91.4%
add-sqr-sqrt45.5%
sqrt-unprod56.3%
sqr-neg56.3%
sqrt-unprod18.6%
add-sqr-sqrt29.8%
frac-2neg29.8%
distribute-neg-frac29.8%
frac-2neg29.8%
cancel-sign-sub-inv29.8%
*-commutative29.8%
clear-num29.8%
un-div-inv29.8%
add-sqr-sqrt11.2%
sqrt-unprod51.6%
Applied egg-rr91.4%
sub-neg91.4%
distribute-neg-frac91.4%
metadata-eval91.4%
associate-/r/87.4%
Simplified87.4%
frac-2neg87.4%
metadata-eval87.4%
div-inv87.4%
associate-*l/89.3%
distribute-neg-frac289.3%
Applied egg-rr89.3%
associate-*r/89.4%
metadata-eval89.4%
distribute-frac-neg289.4%
associate-*r/90.6%
distribute-neg-frac290.6%
associate-/r*90.6%
metadata-eval90.6%
distribute-neg-frac90.6%
metadata-eval90.6%
associate-*r/90.5%
distribute-neg-frac90.5%
associate-*r/90.6%
metadata-eval90.6%
distribute-frac-neg290.6%
distribute-frac-neg290.6%
remove-double-neg90.6%
Simplified90.6%
Final simplification94.3%
(FPCore (x y z t) :precision binary64 (if (or (<= y -4.2e-7) (not (<= y 6.9e+72))) (- x (/ (* y 0.3333333333333333) z)) (+ x (* 0.3333333333333333 (/ t (* y z))))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -4.2e-7) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x + (0.3333333333333333 * (t / (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 <= (-4.2d-7)) .or. (.not. (y <= 6.9d+72))) then
tmp = x - ((y * 0.3333333333333333d0) / z)
else
tmp = x + (0.3333333333333333d0 * (t / (y * z)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -4.2e-7) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = x + (0.3333333333333333 * (t / (y * z)));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -4.2e-7) or not (y <= 6.9e+72): tmp = x - ((y * 0.3333333333333333) / z) else: tmp = x + (0.3333333333333333 * (t / (y * z))) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -4.2e-7) || !(y <= 6.9e+72)) tmp = Float64(x - Float64(Float64(y * 0.3333333333333333) / z)); else tmp = Float64(x + Float64(0.3333333333333333 * Float64(t / Float64(y * z)))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -4.2e-7) || ~((y <= 6.9e+72))) tmp = x - ((y * 0.3333333333333333) / z); else tmp = x + (0.3333333333333333 * (t / (y * z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -4.2e-7], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x - N[(N[(y * 0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x + N[(0.3333333333333333 * N[(t / N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.2 \cdot 10^{-7} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x - \frac{y \cdot 0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;x + 0.3333333333333333 \cdot \frac{t}{y \cdot z}\\
\end{array}
\end{array}
if y < -4.2e-7 or 6.90000000000000034e72 < y Initial program 98.0%
sub-neg98.0%
associate-+l+98.0%
distribute-frac-neg98.0%
neg-mul-198.0%
*-commutative98.0%
times-frac98.1%
fma-define98.1%
metadata-eval98.1%
associate-*l*98.1%
*-commutative98.1%
Simplified98.1%
Taylor expanded in t around 0 97.4%
metadata-eval97.4%
cancel-sign-sub-inv97.4%
associate-*r/97.5%
*-commutative97.5%
Simplified97.5%
if -4.2e-7 < y < 6.90000000000000034e72Initial program 94.7%
sub-neg94.7%
associate-+l+94.7%
remove-double-neg94.7%
distribute-frac-neg94.7%
sub-neg94.7%
distribute-frac-neg94.7%
neg-mul-194.7%
*-commutative94.7%
associate-/l*94.7%
*-commutative94.7%
neg-mul-194.7%
times-frac92.4%
distribute-lft-out--92.4%
*-commutative92.4%
associate-/r*92.4%
metadata-eval92.4%
Simplified92.4%
Taylor expanded in y around 0 90.2%
Final simplification93.8%
(FPCore (x y z t) :precision binary64 (if (or (<= y -3.3e-135) (not (<= y 6.9e+72))) (- x (/ (* y 0.3333333333333333) z)) (* t (/ (/ 0.3333333333333333 y) z))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -3.3e-135) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = t * ((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 <= (-3.3d-135)) .or. (.not. (y <= 6.9d+72))) then
tmp = x - ((y * 0.3333333333333333d0) / z)
else
tmp = t * ((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 <= -3.3e-135) || !(y <= 6.9e+72)) {
tmp = x - ((y * 0.3333333333333333) / z);
} else {
tmp = t * ((0.3333333333333333 / y) / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -3.3e-135) or not (y <= 6.9e+72): tmp = x - ((y * 0.3333333333333333) / z) else: tmp = t * ((0.3333333333333333 / y) / z) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -3.3e-135) || !(y <= 6.9e+72)) tmp = Float64(x - Float64(Float64(y * 0.3333333333333333) / z)); else tmp = Float64(t * Float64(Float64(0.3333333333333333 / y) / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -3.3e-135) || ~((y <= 6.9e+72))) tmp = x - ((y * 0.3333333333333333) / z); else tmp = t * ((0.3333333333333333 / y) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -3.3e-135], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x - N[(N[(y * 0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(0.3333333333333333 / y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.3 \cdot 10^{-135} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x - \frac{y \cdot 0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{\frac{0.3333333333333333}{y}}{z}\\
\end{array}
\end{array}
if y < -3.2999999999999999e-135 or 6.90000000000000034e72 < y Initial program 98.4%
sub-neg98.4%
associate-+l+98.4%
distribute-frac-neg98.4%
neg-mul-198.4%
*-commutative98.4%
times-frac98.4%
fma-define98.4%
metadata-eval98.4%
associate-*l*98.4%
*-commutative98.4%
Simplified98.4%
Taylor expanded in t around 0 90.3%
metadata-eval90.3%
cancel-sign-sub-inv90.3%
associate-*r/90.3%
*-commutative90.3%
Simplified90.3%
if -3.2999999999999999e-135 < y < 6.90000000000000034e72Initial program 93.4%
Taylor expanded in z around 0 71.7%
Taylor expanded in t around inf 67.9%
associate-*r/67.9%
*-commutative67.9%
associate-*r/67.9%
associate-/r*67.9%
Simplified67.9%
Final simplification81.2%
(FPCore (x y z t) :precision binary64 (if (or (<= y -5.3e-135) (not (<= y 6.9e+72))) (- x (* 0.3333333333333333 (/ y z))) (* t (/ (/ 0.3333333333333333 y) z))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -5.3e-135) || !(y <= 6.9e+72)) {
tmp = x - (0.3333333333333333 * (y / z));
} else {
tmp = t * ((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.3d-135)) .or. (.not. (y <= 6.9d+72))) then
tmp = x - (0.3333333333333333d0 * (y / z))
else
tmp = t * ((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.3e-135) || !(y <= 6.9e+72)) {
tmp = x - (0.3333333333333333 * (y / z));
} else {
tmp = t * ((0.3333333333333333 / y) / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -5.3e-135) or not (y <= 6.9e+72): tmp = x - (0.3333333333333333 * (y / z)) else: tmp = t * ((0.3333333333333333 / y) / z) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -5.3e-135) || !(y <= 6.9e+72)) tmp = Float64(x - Float64(0.3333333333333333 * Float64(y / z))); else tmp = Float64(t * Float64(Float64(0.3333333333333333 / y) / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -5.3e-135) || ~((y <= 6.9e+72))) tmp = x - (0.3333333333333333 * (y / z)); else tmp = t * ((0.3333333333333333 / y) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -5.3e-135], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x - N[(0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(0.3333333333333333 / y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.3 \cdot 10^{-135} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x - 0.3333333333333333 \cdot \frac{y}{z}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{\frac{0.3333333333333333}{y}}{z}\\
\end{array}
\end{array}
if y < -5.3e-135 or 6.90000000000000034e72 < y Initial program 98.4%
Taylor expanded in t around 0 90.3%
if -5.3e-135 < y < 6.90000000000000034e72Initial program 93.4%
Taylor expanded in z around 0 71.7%
Taylor expanded in t around inf 67.9%
associate-*r/67.9%
*-commutative67.9%
associate-*r/67.9%
associate-/r*67.9%
Simplified67.9%
Final simplification81.2%
(FPCore (x y z t) :precision binary64 (if (or (<= y -2.65e-135) (not (<= y 6.9e+72))) (+ x (* y (/ -0.3333333333333333 z))) (* t (/ (/ 0.3333333333333333 y) z))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -2.65e-135) || !(y <= 6.9e+72)) {
tmp = x + (y * (-0.3333333333333333 / z));
} else {
tmp = t * ((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 <= (-2.65d-135)) .or. (.not. (y <= 6.9d+72))) then
tmp = x + (y * ((-0.3333333333333333d0) / z))
else
tmp = t * ((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 <= -2.65e-135) || !(y <= 6.9e+72)) {
tmp = x + (y * (-0.3333333333333333 / z));
} else {
tmp = t * ((0.3333333333333333 / y) / z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -2.65e-135) or not (y <= 6.9e+72): tmp = x + (y * (-0.3333333333333333 / z)) else: tmp = t * ((0.3333333333333333 / y) / z) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -2.65e-135) || !(y <= 6.9e+72)) tmp = Float64(x + Float64(y * Float64(-0.3333333333333333 / z))); else tmp = Float64(t * Float64(Float64(0.3333333333333333 / y) / z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -2.65e-135) || ~((y <= 6.9e+72))) tmp = x + (y * (-0.3333333333333333 / z)); else tmp = t * ((0.3333333333333333 / y) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -2.65e-135], N[Not[LessEqual[y, 6.9e+72]], $MachinePrecision]], N[(x + N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(0.3333333333333333 / y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.65 \cdot 10^{-135} \lor \neg \left(y \leq 6.9 \cdot 10^{+72}\right):\\
\;\;\;\;x + y \cdot \frac{-0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{\frac{0.3333333333333333}{y}}{z}\\
\end{array}
\end{array}
if y < -2.65e-135 or 6.90000000000000034e72 < y Initial program 98.4%
sub-neg98.4%
associate-+l+98.4%
remove-double-neg98.4%
distribute-frac-neg98.4%
sub-neg98.4%
distribute-frac-neg98.4%
neg-mul-198.4%
*-commutative98.4%
associate-/l*98.3%
*-commutative98.3%
neg-mul-198.3%
times-frac98.4%
distribute-lft-out--99.1%
*-commutative99.1%
associate-/r*99.0%
metadata-eval99.0%
Simplified99.0%
Taylor expanded in y around inf 90.2%
if -2.65e-135 < y < 6.90000000000000034e72Initial program 93.4%
Taylor expanded in z around 0 71.7%
Taylor expanded in t around inf 67.9%
associate-*r/67.9%
*-commutative67.9%
associate-*r/67.9%
associate-/r*67.9%
Simplified67.9%
Final simplification81.1%
(FPCore (x y z t)
:precision binary64
(if (<= y -5.5e-135)
(+ x (* y (/ -0.3333333333333333 z)))
(if (<= y 6.9e+72)
(* t (/ (/ 0.3333333333333333 y) z))
(+ x (/ y (* z -3.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.5e-135) {
tmp = x + (y * (-0.3333333333333333 / z));
} else if (y <= 6.9e+72) {
tmp = 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 <= (-5.5d-135)) then
tmp = x + (y * ((-0.3333333333333333d0) / z))
else if (y <= 6.9d+72) then
tmp = 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 <= -5.5e-135) {
tmp = x + (y * (-0.3333333333333333 / z));
} else if (y <= 6.9e+72) {
tmp = t * ((0.3333333333333333 / y) / z);
} else {
tmp = x + (y / (z * -3.0));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -5.5e-135: tmp = x + (y * (-0.3333333333333333 / z)) elif y <= 6.9e+72: tmp = 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 <= -5.5e-135) tmp = Float64(x + Float64(y * Float64(-0.3333333333333333 / z))); elseif (y <= 6.9e+72) tmp = Float64(t * Float64(Float64(0.3333333333333333 / 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 <= -5.5e-135) tmp = x + (y * (-0.3333333333333333 / z)); elseif (y <= 6.9e+72) tmp = 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, -5.5e-135], N[(x + N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.9e+72], N[(t * N[(N[(0.3333333333333333 / y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / N[(z * -3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.5 \cdot 10^{-135}:\\
\;\;\;\;x + y \cdot \frac{-0.3333333333333333}{z}\\
\mathbf{elif}\;y \leq 6.9 \cdot 10^{+72}:\\
\;\;\;\;t \cdot \frac{\frac{0.3333333333333333}{y}}{z}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{z \cdot -3}\\
\end{array}
\end{array}
if y < -5.4999999999999999e-135Initial program 98.7%
sub-neg98.7%
associate-+l+98.7%
remove-double-neg98.7%
distribute-frac-neg98.7%
sub-neg98.7%
distribute-frac-neg98.7%
neg-mul-198.7%
*-commutative98.7%
associate-/l*98.6%
*-commutative98.6%
neg-mul-198.6%
times-frac98.8%
distribute-lft-out--98.8%
*-commutative98.8%
associate-/r*98.8%
metadata-eval98.8%
Simplified98.8%
Taylor expanded in y around inf 85.6%
if -5.4999999999999999e-135 < y < 6.90000000000000034e72Initial program 93.4%
Taylor expanded in z around 0 71.7%
Taylor expanded in t around inf 67.9%
associate-*r/67.9%
*-commutative67.9%
associate-*r/67.9%
associate-/r*67.9%
Simplified67.9%
if 6.90000000000000034e72 < y Initial program 97.7%
sub-neg97.7%
associate-+l+97.7%
remove-double-neg97.7%
distribute-frac-neg97.7%
sub-neg97.7%
distribute-frac-neg97.7%
neg-mul-197.7%
*-commutative97.7%
associate-/l*97.6%
*-commutative97.6%
neg-mul-197.6%
times-frac97.6%
distribute-lft-out--99.6%
*-commutative99.6%
associate-/r*99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in y around inf 99.7%
*-commutative99.7%
metadata-eval99.7%
times-frac99.7%
*-rgt-identity99.7%
Simplified99.7%
Final simplification81.2%
(FPCore (x y z t) :precision binary64 (+ (+ (/ 1.0 (* y (/ (* z 3.0) t))) x) (/ y (* z -3.0))))
double code(double x, double y, double z, double t) {
return ((1.0 / (y * ((z * 3.0) / t))) + x) + (y / (z * -3.0));
}
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 = ((1.0d0 / (y * ((z * 3.0d0) / t))) + x) + (y / (z * (-3.0d0)))
end function
public static double code(double x, double y, double z, double t) {
return ((1.0 / (y * ((z * 3.0) / t))) + x) + (y / (z * -3.0));
}
def code(x, y, z, t): return ((1.0 / (y * ((z * 3.0) / t))) + x) + (y / (z * -3.0))
function code(x, y, z, t) return Float64(Float64(Float64(1.0 / Float64(y * Float64(Float64(z * 3.0) / t))) + x) + Float64(y / Float64(z * -3.0))) end
function tmp = code(x, y, z, t) tmp = ((1.0 / (y * ((z * 3.0) / t))) + x) + (y / (z * -3.0)); end
code[x_, y_, z_, t_] := N[(N[(N[(1.0 / N[(y * N[(N[(z * 3.0), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision] + N[(y / N[(z * -3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\frac{1}{y \cdot \frac{z \cdot 3}{t}} + x\right) + \frac{y}{z \cdot -3}
\end{array}
Initial program 96.4%
+-commutative96.4%
associate-+r-96.4%
sub-neg96.4%
associate-*l*96.4%
*-commutative96.4%
distribute-frac-neg296.4%
distribute-rgt-neg-in96.4%
metadata-eval96.4%
Simplified96.4%
clear-num96.3%
inv-pow96.3%
*-commutative96.3%
associate-*l*96.3%
*-commutative96.3%
Applied egg-rr96.3%
unpow-196.3%
associate-/l*97.1%
Simplified97.1%
(FPCore (x y z t) :precision binary64 (if (<= x -1.4e+67) x (if (<= x 9.5e-10) (/ (/ y -3.0) z) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (x <= -1.4e+67) {
tmp = x;
} else if (x <= 9.5e-10) {
tmp = (y / -3.0) / 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.4d+67)) then
tmp = x
else if (x <= 9.5d-10) then
tmp = (y / (-3.0d0)) / 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.4e+67) {
tmp = x;
} else if (x <= 9.5e-10) {
tmp = (y / -3.0) / z;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if x <= -1.4e+67: tmp = x elif x <= 9.5e-10: tmp = (y / -3.0) / z else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (x <= -1.4e+67) tmp = x; elseif (x <= 9.5e-10) tmp = Float64(Float64(y / -3.0) / z); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (x <= -1.4e+67) tmp = x; elseif (x <= 9.5e-10) tmp = (y / -3.0) / z; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[x, -1.4e+67], x, If[LessEqual[x, 9.5e-10], N[(N[(y / -3.0), $MachinePrecision] / z), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.4 \cdot 10^{+67}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 9.5 \cdot 10^{-10}:\\
\;\;\;\;\frac{\frac{y}{-3}}{z}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -1.3999999999999999e67 or 9.50000000000000028e-10 < x Initial program 96.7%
sub-neg96.7%
associate-+l+96.7%
distribute-frac-neg96.7%
neg-mul-196.7%
*-commutative96.7%
times-frac96.7%
fma-define96.7%
metadata-eval96.7%
associate-*l*96.7%
*-commutative96.7%
Simplified96.7%
Taylor expanded in x around inf 52.8%
if -1.3999999999999999e67 < x < 9.50000000000000028e-10Initial program 96.1%
sub-neg96.1%
associate-+l+96.1%
distribute-frac-neg96.1%
neg-mul-196.1%
*-commutative96.1%
times-frac96.1%
fma-define96.0%
metadata-eval96.0%
associate-*l*96.0%
*-commutative96.0%
Simplified96.0%
Taylor expanded in t around 0 56.8%
metadata-eval56.8%
cancel-sign-sub-inv56.8%
associate-*r/56.9%
*-commutative56.9%
Simplified56.9%
Taylor expanded in x around 0 47.6%
associate-*r/47.7%
metadata-eval47.7%
distribute-lft-neg-in47.7%
add-sqr-sqrt18.4%
sqrt-unprod18.8%
sqr-neg18.8%
sqrt-unprod0.9%
add-sqr-sqrt1.9%
frac-2neg1.9%
clear-num1.9%
frac-2neg1.9%
metadata-eval1.9%
distribute-frac-neg21.9%
metadata-eval1.9%
distribute-neg-frac1.9%
clear-num1.9%
distribute-neg-frac1.9%
distribute-lft-neg-in1.9%
metadata-eval1.9%
associate-*r/1.9%
Applied egg-rr1.9%
add-sqr-sqrt1.0%
sqrt-unprod23.6%
sqr-neg23.6%
sqrt-unprod25.6%
add-sqr-sqrt47.6%
metadata-eval47.6%
times-frac47.6%
*-un-lft-identity47.6%
associate-/r*47.7%
Applied egg-rr47.7%
(FPCore (x y z t) :precision binary64 (if (<= x -1.65e+66) x (if (<= x 9.5e-10) (/ (* y -0.3333333333333333) z) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (x <= -1.65e+66) {
tmp = x;
} else if (x <= 9.5e-10) {
tmp = (y * -0.3333333333333333) / 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.65d+66)) then
tmp = x
else if (x <= 9.5d-10) then
tmp = (y * (-0.3333333333333333d0)) / 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.65e+66) {
tmp = x;
} else if (x <= 9.5e-10) {
tmp = (y * -0.3333333333333333) / z;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if x <= -1.65e+66: tmp = x elif x <= 9.5e-10: tmp = (y * -0.3333333333333333) / z else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (x <= -1.65e+66) tmp = x; elseif (x <= 9.5e-10) tmp = Float64(Float64(y * -0.3333333333333333) / z); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (x <= -1.65e+66) tmp = x; elseif (x <= 9.5e-10) tmp = (y * -0.3333333333333333) / z; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[x, -1.65e+66], x, If[LessEqual[x, 9.5e-10], N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.65 \cdot 10^{+66}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 9.5 \cdot 10^{-10}:\\
\;\;\;\;\frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -1.6500000000000001e66 or 9.50000000000000028e-10 < x Initial program 96.7%
sub-neg96.7%
associate-+l+96.7%
distribute-frac-neg96.7%
neg-mul-196.7%
*-commutative96.7%
times-frac96.7%
fma-define96.7%
metadata-eval96.7%
associate-*l*96.7%
*-commutative96.7%
Simplified96.7%
Taylor expanded in x around inf 52.8%
if -1.6500000000000001e66 < x < 9.50000000000000028e-10Initial program 96.1%
sub-neg96.1%
associate-+l+96.1%
distribute-frac-neg96.1%
neg-mul-196.1%
*-commutative96.1%
times-frac96.1%
fma-define96.0%
metadata-eval96.0%
associate-*l*96.0%
*-commutative96.0%
Simplified96.0%
Taylor expanded in t around 0 56.8%
metadata-eval56.8%
cancel-sign-sub-inv56.8%
associate-*r/56.9%
*-commutative56.9%
Simplified56.9%
Taylor expanded in x around 0 47.6%
*-commutative47.6%
associate-*l/47.7%
Simplified47.7%
(FPCore (x y z t) :precision binary64 (if (<= x -6.7e+69) x (if (<= x 4.6e-10) (* -0.3333333333333333 (/ y z)) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (x <= -6.7e+69) {
tmp = x;
} else if (x <= 4.6e-10) {
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 <= (-6.7d+69)) then
tmp = x
else if (x <= 4.6d-10) 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 <= -6.7e+69) {
tmp = x;
} else if (x <= 4.6e-10) {
tmp = -0.3333333333333333 * (y / z);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if x <= -6.7e+69: tmp = x elif x <= 4.6e-10: tmp = -0.3333333333333333 * (y / z) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (x <= -6.7e+69) tmp = x; elseif (x <= 4.6e-10) 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 <= -6.7e+69) tmp = x; elseif (x <= 4.6e-10) tmp = -0.3333333333333333 * (y / z); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[x, -6.7e+69], x, If[LessEqual[x, 4.6e-10], N[(-0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -6.7 \cdot 10^{+69}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 4.6 \cdot 10^{-10}:\\
\;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -6.7000000000000001e69 or 4.60000000000000014e-10 < x Initial program 96.7%
sub-neg96.7%
associate-+l+96.7%
distribute-frac-neg96.7%
neg-mul-196.7%
*-commutative96.7%
times-frac96.7%
fma-define96.7%
metadata-eval96.7%
associate-*l*96.7%
*-commutative96.7%
Simplified96.7%
Taylor expanded in x around inf 52.8%
if -6.7000000000000001e69 < x < 4.60000000000000014e-10Initial program 96.1%
sub-neg96.1%
associate-+l+96.1%
distribute-frac-neg96.1%
neg-mul-196.1%
*-commutative96.1%
times-frac96.1%
fma-define96.0%
metadata-eval96.0%
associate-*l*96.0%
*-commutative96.0%
Simplified96.0%
Taylor expanded in t around 0 56.8%
metadata-eval56.8%
cancel-sign-sub-inv56.8%
associate-*r/56.9%
*-commutative56.9%
Simplified56.9%
Taylor expanded in x around 0 47.6%
(FPCore (x y z t) :precision binary64 (+ x (* -0.3333333333333333 (/ (- y (/ t y)) z))))
double code(double x, double y, double z, double t) {
return x + (-0.3333333333333333 * ((y - (t / 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 + ((-0.3333333333333333d0) * ((y - (t / y)) / z))
end function
public static double code(double x, double y, double z, double t) {
return x + (-0.3333333333333333 * ((y - (t / y)) / z));
}
def code(x, y, z, t): return x + (-0.3333333333333333 * ((y - (t / y)) / z))
function code(x, y, z, t) return Float64(x + Float64(-0.3333333333333333 * Float64(Float64(y - Float64(t / y)) / z))) end
function tmp = code(x, y, z, t) tmp = x + (-0.3333333333333333 * ((y - (t / y)) / z)); end
code[x_, y_, z_, t_] := N[(x + N[(-0.3333333333333333 * N[(N[(y - N[(t / y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + -0.3333333333333333 \cdot \frac{y - \frac{t}{y}}{z}
\end{array}
Initial program 96.4%
sub-neg96.4%
associate-+l+96.4%
remove-double-neg96.4%
distribute-frac-neg96.4%
sub-neg96.4%
distribute-frac-neg96.4%
neg-mul-196.4%
*-commutative96.4%
associate-/l*96.3%
*-commutative96.3%
neg-mul-196.3%
times-frac95.6%
distribute-lft-out--96.0%
*-commutative96.0%
associate-/r*96.0%
metadata-eval96.0%
Simplified96.0%
Taylor expanded in z around 0 96.1%
(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 96.4%
sub-neg96.4%
associate-+l+96.4%
distribute-frac-neg96.4%
neg-mul-196.4%
*-commutative96.4%
times-frac96.4%
fma-define96.4%
metadata-eval96.4%
associate-*l*96.3%
*-commutative96.3%
Simplified96.3%
Taylor expanded in x around inf 30.3%
(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 2024180
(FPCore (x y z t)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, H"
:precision binary64
:alt
(! :herbie-platform default (+ (- x (/ y (* z 3))) (/ (/ t (* z 3)) y)))
(+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))