
(FPCore (x y z t) :precision binary64 (+ x (* (- y z) (- t x))))
double code(double x, double y, double z, double t) {
return x + ((y - z) * (t - 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 + ((y - z) * (t - x))
end function
public static double code(double x, double y, double z, double t) {
return x + ((y - z) * (t - x));
}
def code(x, y, z, t): return x + ((y - z) * (t - x))
function code(x, y, z, t) return Float64(x + Float64(Float64(y - z) * Float64(t - x))) end
function tmp = code(x, y, z, t) tmp = x + ((y - z) * (t - x)); end
code[x_, y_, z_, t_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \left(t - x\right)
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 16 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (+ x (* (- y z) (- t x))))
double code(double x, double y, double z, double t) {
return x + ((y - z) * (t - 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 + ((y - z) * (t - x))
end function
public static double code(double x, double y, double z, double t) {
return x + ((y - z) * (t - x));
}
def code(x, y, z, t): return x + ((y - z) * (t - x))
function code(x, y, z, t) return Float64(x + Float64(Float64(y - z) * Float64(t - x))) end
function tmp = code(x, y, z, t) tmp = x + ((y - z) * (t - x)); end
code[x_, y_, z_, t_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \left(t - x\right)
\end{array}
(FPCore (x y z t) :precision binary64 (fma (- y z) (- t x) x))
double code(double x, double y, double z, double t) {
return fma((y - z), (t - x), x);
}
function code(x, y, z, t) return fma(Float64(y - z), Float64(t - x), x) end
code[x_, y_, z_, t_] := N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(y - z, t - x, x\right)
\end{array}
Initial program 100.0%
+-commutative100.0%
fma-def100.0%
Simplified100.0%
Final simplification100.0%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* z (- t))) (t_2 (* x (+ z 1.0))))
(if (<= y -3.4e+208)
(* y t)
(if (<= y -1.02e+71)
(* y (- x))
(if (<= y -2.6e+60)
(* y t)
(if (<= y -950000.0)
t_1
(if (<= y -2.8e-13)
(* y t)
(if (<= y -2.65e-92)
t_2
(if (<= y -2.5e-187)
t_1
(if (<= y 1.05e+17) t_2 (* y t)))))))))))
double code(double x, double y, double z, double t) {
double t_1 = z * -t;
double t_2 = x * (z + 1.0);
double tmp;
if (y <= -3.4e+208) {
tmp = y * t;
} else if (y <= -1.02e+71) {
tmp = y * -x;
} else if (y <= -2.6e+60) {
tmp = y * t;
} else if (y <= -950000.0) {
tmp = t_1;
} else if (y <= -2.8e-13) {
tmp = y * t;
} else if (y <= -2.65e-92) {
tmp = t_2;
} else if (y <= -2.5e-187) {
tmp = t_1;
} else if (y <= 1.05e+17) {
tmp = t_2;
} else {
tmp = y * 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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = z * -t
t_2 = x * (z + 1.0d0)
if (y <= (-3.4d+208)) then
tmp = y * t
else if (y <= (-1.02d+71)) then
tmp = y * -x
else if (y <= (-2.6d+60)) then
tmp = y * t
else if (y <= (-950000.0d0)) then
tmp = t_1
else if (y <= (-2.8d-13)) then
tmp = y * t
else if (y <= (-2.65d-92)) then
tmp = t_2
else if (y <= (-2.5d-187)) then
tmp = t_1
else if (y <= 1.05d+17) then
tmp = t_2
else
tmp = y * t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = z * -t;
double t_2 = x * (z + 1.0);
double tmp;
if (y <= -3.4e+208) {
tmp = y * t;
} else if (y <= -1.02e+71) {
tmp = y * -x;
} else if (y <= -2.6e+60) {
tmp = y * t;
} else if (y <= -950000.0) {
tmp = t_1;
} else if (y <= -2.8e-13) {
tmp = y * t;
} else if (y <= -2.65e-92) {
tmp = t_2;
} else if (y <= -2.5e-187) {
tmp = t_1;
} else if (y <= 1.05e+17) {
tmp = t_2;
} else {
tmp = y * t;
}
return tmp;
}
def code(x, y, z, t): t_1 = z * -t t_2 = x * (z + 1.0) tmp = 0 if y <= -3.4e+208: tmp = y * t elif y <= -1.02e+71: tmp = y * -x elif y <= -2.6e+60: tmp = y * t elif y <= -950000.0: tmp = t_1 elif y <= -2.8e-13: tmp = y * t elif y <= -2.65e-92: tmp = t_2 elif y <= -2.5e-187: tmp = t_1 elif y <= 1.05e+17: tmp = t_2 else: tmp = y * t return tmp
function code(x, y, z, t) t_1 = Float64(z * Float64(-t)) t_2 = Float64(x * Float64(z + 1.0)) tmp = 0.0 if (y <= -3.4e+208) tmp = Float64(y * t); elseif (y <= -1.02e+71) tmp = Float64(y * Float64(-x)); elseif (y <= -2.6e+60) tmp = Float64(y * t); elseif (y <= -950000.0) tmp = t_1; elseif (y <= -2.8e-13) tmp = Float64(y * t); elseif (y <= -2.65e-92) tmp = t_2; elseif (y <= -2.5e-187) tmp = t_1; elseif (y <= 1.05e+17) tmp = t_2; else tmp = Float64(y * t); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = z * -t; t_2 = x * (z + 1.0); tmp = 0.0; if (y <= -3.4e+208) tmp = y * t; elseif (y <= -1.02e+71) tmp = y * -x; elseif (y <= -2.6e+60) tmp = y * t; elseif (y <= -950000.0) tmp = t_1; elseif (y <= -2.8e-13) tmp = y * t; elseif (y <= -2.65e-92) tmp = t_2; elseif (y <= -2.5e-187) tmp = t_1; elseif (y <= 1.05e+17) tmp = t_2; else tmp = y * t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(z * (-t)), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.4e+208], N[(y * t), $MachinePrecision], If[LessEqual[y, -1.02e+71], N[(y * (-x)), $MachinePrecision], If[LessEqual[y, -2.6e+60], N[(y * t), $MachinePrecision], If[LessEqual[y, -950000.0], t$95$1, If[LessEqual[y, -2.8e-13], N[(y * t), $MachinePrecision], If[LessEqual[y, -2.65e-92], t$95$2, If[LessEqual[y, -2.5e-187], t$95$1, If[LessEqual[y, 1.05e+17], t$95$2, N[(y * t), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \left(-t\right)\\
t_2 := x \cdot \left(z + 1\right)\\
\mathbf{if}\;y \leq -3.4 \cdot 10^{+208}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;y \leq -1.02 \cdot 10^{+71}:\\
\;\;\;\;y \cdot \left(-x\right)\\
\mathbf{elif}\;y \leq -2.6 \cdot 10^{+60}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;y \leq -950000:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -2.8 \cdot 10^{-13}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;y \leq -2.65 \cdot 10^{-92}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;y \leq -2.5 \cdot 10^{-187}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq 1.05 \cdot 10^{+17}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;y \cdot t\\
\end{array}
\end{array}
if y < -3.3999999999999998e208 or -1.02000000000000003e71 < y < -2.60000000000000008e60 or -9.5e5 < y < -2.8000000000000002e-13 or 1.05e17 < y Initial program 100.0%
sub-neg100.0%
distribute-lft-in95.2%
Applied egg-rr95.2%
Taylor expanded in y around inf 86.7%
Taylor expanded in x around 0 86.7%
+-commutative86.7%
fma-def88.0%
mul-1-neg88.0%
unsub-neg88.0%
*-commutative88.0%
Simplified88.0%
Taylor expanded in x around 0 53.5%
if -3.3999999999999998e208 < y < -1.02000000000000003e71Initial program 100.0%
Taylor expanded in x around inf 65.5%
mul-1-neg65.5%
unsub-neg65.5%
Simplified65.5%
Taylor expanded in y around inf 56.8%
mul-1-neg56.8%
Simplified56.8%
if -2.60000000000000008e60 < y < -9.5e5 or -2.65000000000000015e-92 < y < -2.4999999999999998e-187Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt54.6%
associate-*r*54.5%
fma-def54.5%
Applied egg-rr54.5%
Taylor expanded in x around 0 81.4%
*-commutative81.4%
Simplified81.4%
Taylor expanded in y around 0 71.9%
associate-*r*71.9%
mul-1-neg71.9%
Simplified71.9%
if -2.8000000000000002e-13 < y < -2.65000000000000015e-92 or -2.4999999999999998e-187 < y < 1.05e17Initial program 99.9%
Taylor expanded in x around inf 63.2%
mul-1-neg63.2%
unsub-neg63.2%
Simplified63.2%
Taylor expanded in y around 0 61.0%
+-commutative61.0%
Simplified61.0%
Final simplification59.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* y (- t x))) (t_2 (* x (+ z 1.0))) (t_3 (* z (- t))))
(if (<= y -3.8e+61)
t_1
(if (<= y -245000.0)
t_3
(if (<= y -4.1e-13)
(* y t)
(if (<= y -4.2e-93)
t_2
(if (<= y -4.8e-187) t_3 (if (<= y 8e-11) t_2 t_1))))))))
double code(double x, double y, double z, double t) {
double t_1 = y * (t - x);
double t_2 = x * (z + 1.0);
double t_3 = z * -t;
double tmp;
if (y <= -3.8e+61) {
tmp = t_1;
} else if (y <= -245000.0) {
tmp = t_3;
} else if (y <= -4.1e-13) {
tmp = y * t;
} else if (y <= -4.2e-93) {
tmp = t_2;
} else if (y <= -4.8e-187) {
tmp = t_3;
} else if (y <= 8e-11) {
tmp = t_2;
} 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) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = y * (t - x)
t_2 = x * (z + 1.0d0)
t_3 = z * -t
if (y <= (-3.8d+61)) then
tmp = t_1
else if (y <= (-245000.0d0)) then
tmp = t_3
else if (y <= (-4.1d-13)) then
tmp = y * t
else if (y <= (-4.2d-93)) then
tmp = t_2
else if (y <= (-4.8d-187)) then
tmp = t_3
else if (y <= 8d-11) then
tmp = t_2
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 * (t - x);
double t_2 = x * (z + 1.0);
double t_3 = z * -t;
double tmp;
if (y <= -3.8e+61) {
tmp = t_1;
} else if (y <= -245000.0) {
tmp = t_3;
} else if (y <= -4.1e-13) {
tmp = y * t;
} else if (y <= -4.2e-93) {
tmp = t_2;
} else if (y <= -4.8e-187) {
tmp = t_3;
} else if (y <= 8e-11) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = y * (t - x) t_2 = x * (z + 1.0) t_3 = z * -t tmp = 0 if y <= -3.8e+61: tmp = t_1 elif y <= -245000.0: tmp = t_3 elif y <= -4.1e-13: tmp = y * t elif y <= -4.2e-93: tmp = t_2 elif y <= -4.8e-187: tmp = t_3 elif y <= 8e-11: tmp = t_2 else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(y * Float64(t - x)) t_2 = Float64(x * Float64(z + 1.0)) t_3 = Float64(z * Float64(-t)) tmp = 0.0 if (y <= -3.8e+61) tmp = t_1; elseif (y <= -245000.0) tmp = t_3; elseif (y <= -4.1e-13) tmp = Float64(y * t); elseif (y <= -4.2e-93) tmp = t_2; elseif (y <= -4.8e-187) tmp = t_3; elseif (y <= 8e-11) tmp = t_2; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = y * (t - x); t_2 = x * (z + 1.0); t_3 = z * -t; tmp = 0.0; if (y <= -3.8e+61) tmp = t_1; elseif (y <= -245000.0) tmp = t_3; elseif (y <= -4.1e-13) tmp = y * t; elseif (y <= -4.2e-93) tmp = t_2; elseif (y <= -4.8e-187) tmp = t_3; elseif (y <= 8e-11) tmp = t_2; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(z * (-t)), $MachinePrecision]}, If[LessEqual[y, -3.8e+61], t$95$1, If[LessEqual[y, -245000.0], t$95$3, If[LessEqual[y, -4.1e-13], N[(y * t), $MachinePrecision], If[LessEqual[y, -4.2e-93], t$95$2, If[LessEqual[y, -4.8e-187], t$95$3, If[LessEqual[y, 8e-11], t$95$2, t$95$1]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(t - x\right)\\
t_2 := x \cdot \left(z + 1\right)\\
t_3 := z \cdot \left(-t\right)\\
\mathbf{if}\;y \leq -3.8 \cdot 10^{+61}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -245000:\\
\;\;\;\;t_3\\
\mathbf{elif}\;y \leq -4.1 \cdot 10^{-13}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;y \leq -4.2 \cdot 10^{-93}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;y \leq -4.8 \cdot 10^{-187}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;y \leq 8 \cdot 10^{-11}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -3.79999999999999995e61 or 7.99999999999999952e-11 < y Initial program 99.9%
sub-neg99.9%
distribute-lft-in94.1%
Applied egg-rr94.1%
Taylor expanded in y around inf 89.1%
Taylor expanded in x around 0 89.1%
+-commutative89.1%
fma-def91.6%
mul-1-neg91.6%
unsub-neg91.6%
*-commutative91.6%
Simplified91.6%
Taylor expanded in y around inf 83.8%
neg-mul-183.8%
sub-neg83.8%
Simplified83.8%
if -3.79999999999999995e61 < y < -245000 or -4.2000000000000002e-93 < y < -4.80000000000000027e-187Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt52.9%
associate-*r*52.8%
fma-def52.8%
Applied egg-rr52.8%
Taylor expanded in x around 0 78.8%
*-commutative78.8%
Simplified78.8%
Taylor expanded in y around 0 69.7%
associate-*r*69.7%
mul-1-neg69.7%
Simplified69.7%
if -245000 < y < -4.1000000000000002e-13Initial program 100.0%
sub-neg100.0%
distribute-lft-in100.0%
Applied egg-rr100.0%
Taylor expanded in y around inf 97.7%
Taylor expanded in x around 0 97.7%
+-commutative97.7%
fma-def97.7%
mul-1-neg97.7%
unsub-neg97.7%
*-commutative97.7%
Simplified97.7%
Taylor expanded in x around 0 91.4%
if -4.1000000000000002e-13 < y < -4.2000000000000002e-93 or -4.80000000000000027e-187 < y < 7.99999999999999952e-11Initial program 100.0%
Taylor expanded in x around inf 63.2%
mul-1-neg63.2%
unsub-neg63.2%
Simplified63.2%
Taylor expanded in y around 0 63.1%
+-commutative63.1%
Simplified63.1%
Final simplification74.1%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* z (- t))) (t_2 (* y (- x))))
(if (<= x -2.7e+86)
t_2
(if (<= x -1.55e-279)
(* y t)
(if (<= x 1.7e-303)
t_1
(if (<= x 1.95e-175)
(* y t)
(if (<= x 6.8e+31) t_1 (if (<= x 1.05e+210) (* z x) t_2))))))))
double code(double x, double y, double z, double t) {
double t_1 = z * -t;
double t_2 = y * -x;
double tmp;
if (x <= -2.7e+86) {
tmp = t_2;
} else if (x <= -1.55e-279) {
tmp = y * t;
} else if (x <= 1.7e-303) {
tmp = t_1;
} else if (x <= 1.95e-175) {
tmp = y * t;
} else if (x <= 6.8e+31) {
tmp = t_1;
} else if (x <= 1.05e+210) {
tmp = z * x;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = z * -t
t_2 = y * -x
if (x <= (-2.7d+86)) then
tmp = t_2
else if (x <= (-1.55d-279)) then
tmp = y * t
else if (x <= 1.7d-303) then
tmp = t_1
else if (x <= 1.95d-175) then
tmp = y * t
else if (x <= 6.8d+31) then
tmp = t_1
else if (x <= 1.05d+210) then
tmp = z * x
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = z * -t;
double t_2 = y * -x;
double tmp;
if (x <= -2.7e+86) {
tmp = t_2;
} else if (x <= -1.55e-279) {
tmp = y * t;
} else if (x <= 1.7e-303) {
tmp = t_1;
} else if (x <= 1.95e-175) {
tmp = y * t;
} else if (x <= 6.8e+31) {
tmp = t_1;
} else if (x <= 1.05e+210) {
tmp = z * x;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t): t_1 = z * -t t_2 = y * -x tmp = 0 if x <= -2.7e+86: tmp = t_2 elif x <= -1.55e-279: tmp = y * t elif x <= 1.7e-303: tmp = t_1 elif x <= 1.95e-175: tmp = y * t elif x <= 6.8e+31: tmp = t_1 elif x <= 1.05e+210: tmp = z * x else: tmp = t_2 return tmp
function code(x, y, z, t) t_1 = Float64(z * Float64(-t)) t_2 = Float64(y * Float64(-x)) tmp = 0.0 if (x <= -2.7e+86) tmp = t_2; elseif (x <= -1.55e-279) tmp = Float64(y * t); elseif (x <= 1.7e-303) tmp = t_1; elseif (x <= 1.95e-175) tmp = Float64(y * t); elseif (x <= 6.8e+31) tmp = t_1; elseif (x <= 1.05e+210) tmp = Float64(z * x); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = z * -t; t_2 = y * -x; tmp = 0.0; if (x <= -2.7e+86) tmp = t_2; elseif (x <= -1.55e-279) tmp = y * t; elseif (x <= 1.7e-303) tmp = t_1; elseif (x <= 1.95e-175) tmp = y * t; elseif (x <= 6.8e+31) tmp = t_1; elseif (x <= 1.05e+210) tmp = z * x; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(z * (-t)), $MachinePrecision]}, Block[{t$95$2 = N[(y * (-x)), $MachinePrecision]}, If[LessEqual[x, -2.7e+86], t$95$2, If[LessEqual[x, -1.55e-279], N[(y * t), $MachinePrecision], If[LessEqual[x, 1.7e-303], t$95$1, If[LessEqual[x, 1.95e-175], N[(y * t), $MachinePrecision], If[LessEqual[x, 6.8e+31], t$95$1, If[LessEqual[x, 1.05e+210], N[(z * x), $MachinePrecision], t$95$2]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \left(-t\right)\\
t_2 := y \cdot \left(-x\right)\\
\mathbf{if}\;x \leq -2.7 \cdot 10^{+86}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -1.55 \cdot 10^{-279}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;x \leq 1.7 \cdot 10^{-303}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 1.95 \cdot 10^{-175}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;x \leq 6.8 \cdot 10^{+31}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 1.05 \cdot 10^{+210}:\\
\;\;\;\;z \cdot x\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if x < -2.70000000000000018e86 or 1.0499999999999999e210 < x Initial program 100.0%
Taylor expanded in x around inf 95.6%
mul-1-neg95.6%
unsub-neg95.6%
Simplified95.6%
Taylor expanded in y around inf 46.0%
mul-1-neg46.0%
Simplified46.0%
if -2.70000000000000018e86 < x < -1.55e-279 or 1.7e-303 < x < 1.94999999999999999e-175Initial program 99.9%
sub-neg99.9%
distribute-lft-in100.0%
Applied egg-rr100.0%
Taylor expanded in y around inf 73.2%
Taylor expanded in x around 0 73.2%
+-commutative73.2%
fma-def73.2%
mul-1-neg73.2%
unsub-neg73.2%
*-commutative73.2%
Simplified73.2%
Taylor expanded in x around 0 49.8%
if -1.55e-279 < x < 1.7e-303 or 1.94999999999999999e-175 < x < 6.7999999999999996e31Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt35.2%
associate-*r*35.1%
fma-def35.1%
Applied egg-rr35.1%
Taylor expanded in x around 0 70.3%
*-commutative70.3%
Simplified70.3%
Taylor expanded in y around 0 56.2%
associate-*r*56.2%
mul-1-neg56.2%
Simplified56.2%
if 6.7999999999999996e31 < x < 1.0499999999999999e210Initial program 100.0%
Taylor expanded in x around inf 78.3%
mul-1-neg78.3%
unsub-neg78.3%
Simplified78.3%
Taylor expanded in z around inf 41.3%
Final simplification48.9%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* z (- t))))
(if (<= x -2.66e+82)
(* x (- 1.0 y))
(if (<= x -3.4e-279)
(* y t)
(if (<= x 4.3e-302)
t_1
(if (<= x 2.3e-175)
(* y t)
(if (<= x 1.2e-38) t_1 (* x (+ z 1.0)))))))))
double code(double x, double y, double z, double t) {
double t_1 = z * -t;
double tmp;
if (x <= -2.66e+82) {
tmp = x * (1.0 - y);
} else if (x <= -3.4e-279) {
tmp = y * t;
} else if (x <= 4.3e-302) {
tmp = t_1;
} else if (x <= 2.3e-175) {
tmp = y * t;
} else if (x <= 1.2e-38) {
tmp = t_1;
} else {
tmp = x * (z + 1.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 = z * -t
if (x <= (-2.66d+82)) then
tmp = x * (1.0d0 - y)
else if (x <= (-3.4d-279)) then
tmp = y * t
else if (x <= 4.3d-302) then
tmp = t_1
else if (x <= 2.3d-175) then
tmp = y * t
else if (x <= 1.2d-38) then
tmp = t_1
else
tmp = x * (z + 1.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = z * -t;
double tmp;
if (x <= -2.66e+82) {
tmp = x * (1.0 - y);
} else if (x <= -3.4e-279) {
tmp = y * t;
} else if (x <= 4.3e-302) {
tmp = t_1;
} else if (x <= 2.3e-175) {
tmp = y * t;
} else if (x <= 1.2e-38) {
tmp = t_1;
} else {
tmp = x * (z + 1.0);
}
return tmp;
}
def code(x, y, z, t): t_1 = z * -t tmp = 0 if x <= -2.66e+82: tmp = x * (1.0 - y) elif x <= -3.4e-279: tmp = y * t elif x <= 4.3e-302: tmp = t_1 elif x <= 2.3e-175: tmp = y * t elif x <= 1.2e-38: tmp = t_1 else: tmp = x * (z + 1.0) return tmp
function code(x, y, z, t) t_1 = Float64(z * Float64(-t)) tmp = 0.0 if (x <= -2.66e+82) tmp = Float64(x * Float64(1.0 - y)); elseif (x <= -3.4e-279) tmp = Float64(y * t); elseif (x <= 4.3e-302) tmp = t_1; elseif (x <= 2.3e-175) tmp = Float64(y * t); elseif (x <= 1.2e-38) tmp = t_1; else tmp = Float64(x * Float64(z + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = z * -t; tmp = 0.0; if (x <= -2.66e+82) tmp = x * (1.0 - y); elseif (x <= -3.4e-279) tmp = y * t; elseif (x <= 4.3e-302) tmp = t_1; elseif (x <= 2.3e-175) tmp = y * t; elseif (x <= 1.2e-38) tmp = t_1; else tmp = x * (z + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(z * (-t)), $MachinePrecision]}, If[LessEqual[x, -2.66e+82], N[(x * N[(1.0 - y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -3.4e-279], N[(y * t), $MachinePrecision], If[LessEqual[x, 4.3e-302], t$95$1, If[LessEqual[x, 2.3e-175], N[(y * t), $MachinePrecision], If[LessEqual[x, 1.2e-38], t$95$1, N[(x * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \left(-t\right)\\
\mathbf{if}\;x \leq -2.66 \cdot 10^{+82}:\\
\;\;\;\;x \cdot \left(1 - y\right)\\
\mathbf{elif}\;x \leq -3.4 \cdot 10^{-279}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;x \leq 4.3 \cdot 10^{-302}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 2.3 \cdot 10^{-175}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;x \leq 1.2 \cdot 10^{-38}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(z + 1\right)\\
\end{array}
\end{array}
if x < -2.6600000000000001e82Initial program 100.0%
Taylor expanded in x around inf 93.5%
mul-1-neg93.5%
unsub-neg93.5%
Simplified93.5%
Taylor expanded in z around 0 67.2%
if -2.6600000000000001e82 < x < -3.40000000000000015e-279 or 4.3000000000000002e-302 < x < 2.3e-175Initial program 99.9%
sub-neg99.9%
distribute-lft-in100.0%
Applied egg-rr100.0%
Taylor expanded in y around inf 73.2%
Taylor expanded in x around 0 73.2%
+-commutative73.2%
fma-def73.2%
mul-1-neg73.2%
unsub-neg73.2%
*-commutative73.2%
Simplified73.2%
Taylor expanded in x around 0 49.8%
if -3.40000000000000015e-279 < x < 4.3000000000000002e-302 or 2.3e-175 < x < 1.20000000000000011e-38Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt34.9%
associate-*r*34.9%
fma-def34.9%
Applied egg-rr34.9%
Taylor expanded in x around 0 76.9%
*-commutative76.9%
Simplified76.9%
Taylor expanded in y around 0 61.3%
associate-*r*61.3%
mul-1-neg61.3%
Simplified61.3%
if 1.20000000000000011e-38 < x Initial program 100.0%
Taylor expanded in x around inf 81.7%
mul-1-neg81.7%
unsub-neg81.7%
Simplified81.7%
Taylor expanded in y around 0 54.2%
+-commutative54.2%
Simplified54.2%
Final simplification55.8%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (+ z 1.0))) (t_2 (* y (- t x))))
(if (<= y -1.55e+71)
t_2
(if (<= y -8.5e-15)
(* (- y z) t)
(if (<= y -4.2e-93)
t_1
(if (<= y -2.4e-187) (* z (- t)) (if (<= y 6.4e-11) t_1 t_2)))))))
double code(double x, double y, double z, double t) {
double t_1 = x * (z + 1.0);
double t_2 = y * (t - x);
double tmp;
if (y <= -1.55e+71) {
tmp = t_2;
} else if (y <= -8.5e-15) {
tmp = (y - z) * t;
} else if (y <= -4.2e-93) {
tmp = t_1;
} else if (y <= -2.4e-187) {
tmp = z * -t;
} else if (y <= 6.4e-11) {
tmp = t_1;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = x * (z + 1.0d0)
t_2 = y * (t - x)
if (y <= (-1.55d+71)) then
tmp = t_2
else if (y <= (-8.5d-15)) then
tmp = (y - z) * t
else if (y <= (-4.2d-93)) then
tmp = t_1
else if (y <= (-2.4d-187)) then
tmp = z * -t
else if (y <= 6.4d-11) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x * (z + 1.0);
double t_2 = y * (t - x);
double tmp;
if (y <= -1.55e+71) {
tmp = t_2;
} else if (y <= -8.5e-15) {
tmp = (y - z) * t;
} else if (y <= -4.2e-93) {
tmp = t_1;
} else if (y <= -2.4e-187) {
tmp = z * -t;
} else if (y <= 6.4e-11) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t): t_1 = x * (z + 1.0) t_2 = y * (t - x) tmp = 0 if y <= -1.55e+71: tmp = t_2 elif y <= -8.5e-15: tmp = (y - z) * t elif y <= -4.2e-93: tmp = t_1 elif y <= -2.4e-187: tmp = z * -t elif y <= 6.4e-11: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(z + 1.0)) t_2 = Float64(y * Float64(t - x)) tmp = 0.0 if (y <= -1.55e+71) tmp = t_2; elseif (y <= -8.5e-15) tmp = Float64(Float64(y - z) * t); elseif (y <= -4.2e-93) tmp = t_1; elseif (y <= -2.4e-187) tmp = Float64(z * Float64(-t)); elseif (y <= 6.4e-11) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * (z + 1.0); t_2 = y * (t - x); tmp = 0.0; if (y <= -1.55e+71) tmp = t_2; elseif (y <= -8.5e-15) tmp = (y - z) * t; elseif (y <= -4.2e-93) tmp = t_1; elseif (y <= -2.4e-187) tmp = z * -t; elseif (y <= 6.4e-11) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.55e+71], t$95$2, If[LessEqual[y, -8.5e-15], N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[y, -4.2e-93], t$95$1, If[LessEqual[y, -2.4e-187], N[(z * (-t)), $MachinePrecision], If[LessEqual[y, 6.4e-11], t$95$1, t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(z + 1\right)\\
t_2 := y \cdot \left(t - x\right)\\
\mathbf{if}\;y \leq -1.55 \cdot 10^{+71}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;y \leq -8.5 \cdot 10^{-15}:\\
\;\;\;\;\left(y - z\right) \cdot t\\
\mathbf{elif}\;y \leq -4.2 \cdot 10^{-93}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -2.4 \cdot 10^{-187}:\\
\;\;\;\;z \cdot \left(-t\right)\\
\mathbf{elif}\;y \leq 6.4 \cdot 10^{-11}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if y < -1.55000000000000009e71 or 6.39999999999999987e-11 < y Initial program 99.9%
sub-neg99.9%
distribute-lft-in94.0%
Applied egg-rr94.0%
Taylor expanded in y around inf 88.9%
Taylor expanded in x around 0 88.9%
+-commutative88.9%
fma-def91.5%
mul-1-neg91.5%
unsub-neg91.5%
*-commutative91.5%
Simplified91.5%
Taylor expanded in y around inf 83.5%
neg-mul-183.5%
sub-neg83.5%
Simplified83.5%
if -1.55000000000000009e71 < y < -8.50000000000000007e-15Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt47.5%
associate-*r*47.5%
fma-def47.5%
Applied egg-rr47.5%
Taylor expanded in x around 0 84.7%
*-commutative84.7%
Simplified84.7%
if -8.50000000000000007e-15 < y < -4.2000000000000002e-93 or -2.40000000000000013e-187 < y < 6.39999999999999987e-11Initial program 100.0%
Taylor expanded in x around inf 63.2%
mul-1-neg63.2%
unsub-neg63.2%
Simplified63.2%
Taylor expanded in y around 0 63.1%
+-commutative63.1%
Simplified63.1%
if -4.2000000000000002e-93 < y < -2.40000000000000013e-187Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt58.5%
associate-*r*58.5%
fma-def58.5%
Applied egg-rr58.5%
Taylor expanded in x around 0 77.0%
*-commutative77.0%
Simplified77.0%
Taylor expanded in y around 0 77.1%
associate-*r*77.1%
mul-1-neg77.1%
Simplified77.1%
Final simplification75.2%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (+ z 1.0))) (t_2 (* y (- t x))))
(if (<= y -6.2e+71)
t_2
(if (<= y -5.8e-15)
(* (- y z) t)
(if (<= y -6.5e-90)
t_1
(if (<= y 6.7e-43) (- x (* z t)) (if (<= y 7.2e-11) t_1 t_2)))))))
double code(double x, double y, double z, double t) {
double t_1 = x * (z + 1.0);
double t_2 = y * (t - x);
double tmp;
if (y <= -6.2e+71) {
tmp = t_2;
} else if (y <= -5.8e-15) {
tmp = (y - z) * t;
} else if (y <= -6.5e-90) {
tmp = t_1;
} else if (y <= 6.7e-43) {
tmp = x - (z * t);
} else if (y <= 7.2e-11) {
tmp = t_1;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = x * (z + 1.0d0)
t_2 = y * (t - x)
if (y <= (-6.2d+71)) then
tmp = t_2
else if (y <= (-5.8d-15)) then
tmp = (y - z) * t
else if (y <= (-6.5d-90)) then
tmp = t_1
else if (y <= 6.7d-43) then
tmp = x - (z * t)
else if (y <= 7.2d-11) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x * (z + 1.0);
double t_2 = y * (t - x);
double tmp;
if (y <= -6.2e+71) {
tmp = t_2;
} else if (y <= -5.8e-15) {
tmp = (y - z) * t;
} else if (y <= -6.5e-90) {
tmp = t_1;
} else if (y <= 6.7e-43) {
tmp = x - (z * t);
} else if (y <= 7.2e-11) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t): t_1 = x * (z + 1.0) t_2 = y * (t - x) tmp = 0 if y <= -6.2e+71: tmp = t_2 elif y <= -5.8e-15: tmp = (y - z) * t elif y <= -6.5e-90: tmp = t_1 elif y <= 6.7e-43: tmp = x - (z * t) elif y <= 7.2e-11: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(z + 1.0)) t_2 = Float64(y * Float64(t - x)) tmp = 0.0 if (y <= -6.2e+71) tmp = t_2; elseif (y <= -5.8e-15) tmp = Float64(Float64(y - z) * t); elseif (y <= -6.5e-90) tmp = t_1; elseif (y <= 6.7e-43) tmp = Float64(x - Float64(z * t)); elseif (y <= 7.2e-11) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * (z + 1.0); t_2 = y * (t - x); tmp = 0.0; if (y <= -6.2e+71) tmp = t_2; elseif (y <= -5.8e-15) tmp = (y - z) * t; elseif (y <= -6.5e-90) tmp = t_1; elseif (y <= 6.7e-43) tmp = x - (z * t); elseif (y <= 7.2e-11) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.2e+71], t$95$2, If[LessEqual[y, -5.8e-15], N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[y, -6.5e-90], t$95$1, If[LessEqual[y, 6.7e-43], N[(x - N[(z * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.2e-11], t$95$1, t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(z + 1\right)\\
t_2 := y \cdot \left(t - x\right)\\
\mathbf{if}\;y \leq -6.2 \cdot 10^{+71}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;y \leq -5.8 \cdot 10^{-15}:\\
\;\;\;\;\left(y - z\right) \cdot t\\
\mathbf{elif}\;y \leq -6.5 \cdot 10^{-90}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq 6.7 \cdot 10^{-43}:\\
\;\;\;\;x - z \cdot t\\
\mathbf{elif}\;y \leq 7.2 \cdot 10^{-11}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if y < -6.20000000000000036e71 or 7.19999999999999969e-11 < y Initial program 99.9%
sub-neg99.9%
distribute-lft-in94.0%
Applied egg-rr94.0%
Taylor expanded in y around inf 88.9%
Taylor expanded in x around 0 88.9%
+-commutative88.9%
fma-def91.5%
mul-1-neg91.5%
unsub-neg91.5%
*-commutative91.5%
Simplified91.5%
Taylor expanded in y around inf 83.5%
neg-mul-183.5%
sub-neg83.5%
Simplified83.5%
if -6.20000000000000036e71 < y < -5.80000000000000037e-15Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt47.5%
associate-*r*47.5%
fma-def47.5%
Applied egg-rr47.5%
Taylor expanded in x around 0 84.7%
*-commutative84.7%
Simplified84.7%
if -5.80000000000000037e-15 < y < -6.4999999999999996e-90 or 6.6999999999999998e-43 < y < 7.19999999999999969e-11Initial program 100.0%
Taylor expanded in x around inf 74.7%
mul-1-neg74.7%
unsub-neg74.7%
Simplified74.7%
Taylor expanded in y around 0 74.5%
+-commutative74.5%
Simplified74.5%
if -6.4999999999999996e-90 < y < 6.6999999999999998e-43Initial program 100.0%
Taylor expanded in y around 0 97.9%
mul-1-neg97.9%
unsub-neg97.9%
Simplified97.9%
Taylor expanded in t around inf 73.7%
Final simplification79.2%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* y (- t x))))
(if (<= y -4.4e+70)
t_1
(if (<= y -8e-15)
(* (- y z) t)
(if (<= y -1.55e-92)
(* x (+ z 1.0))
(if (<= y 2.8e-236)
(- x (* z t))
(if (<= y 8e-11) (* z (- x t)) t_1)))))))
double code(double x, double y, double z, double t) {
double t_1 = y * (t - x);
double tmp;
if (y <= -4.4e+70) {
tmp = t_1;
} else if (y <= -8e-15) {
tmp = (y - z) * t;
} else if (y <= -1.55e-92) {
tmp = x * (z + 1.0);
} else if (y <= 2.8e-236) {
tmp = x - (z * t);
} else if (y <= 8e-11) {
tmp = z * (x - t);
} 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 * (t - x)
if (y <= (-4.4d+70)) then
tmp = t_1
else if (y <= (-8d-15)) then
tmp = (y - z) * t
else if (y <= (-1.55d-92)) then
tmp = x * (z + 1.0d0)
else if (y <= 2.8d-236) then
tmp = x - (z * t)
else if (y <= 8d-11) then
tmp = z * (x - t)
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 * (t - x);
double tmp;
if (y <= -4.4e+70) {
tmp = t_1;
} else if (y <= -8e-15) {
tmp = (y - z) * t;
} else if (y <= -1.55e-92) {
tmp = x * (z + 1.0);
} else if (y <= 2.8e-236) {
tmp = x - (z * t);
} else if (y <= 8e-11) {
tmp = z * (x - t);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = y * (t - x) tmp = 0 if y <= -4.4e+70: tmp = t_1 elif y <= -8e-15: tmp = (y - z) * t elif y <= -1.55e-92: tmp = x * (z + 1.0) elif y <= 2.8e-236: tmp = x - (z * t) elif y <= 8e-11: tmp = z * (x - t) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(y * Float64(t - x)) tmp = 0.0 if (y <= -4.4e+70) tmp = t_1; elseif (y <= -8e-15) tmp = Float64(Float64(y - z) * t); elseif (y <= -1.55e-92) tmp = Float64(x * Float64(z + 1.0)); elseif (y <= 2.8e-236) tmp = Float64(x - Float64(z * t)); elseif (y <= 8e-11) tmp = Float64(z * Float64(x - t)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = y * (t - x); tmp = 0.0; if (y <= -4.4e+70) tmp = t_1; elseif (y <= -8e-15) tmp = (y - z) * t; elseif (y <= -1.55e-92) tmp = x * (z + 1.0); elseif (y <= 2.8e-236) tmp = x - (z * t); elseif (y <= 8e-11) tmp = z * (x - t); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -4.4e+70], t$95$1, If[LessEqual[y, -8e-15], N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[y, -1.55e-92], N[(x * N[(z + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.8e-236], N[(x - N[(z * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8e-11], N[(z * N[(x - t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(t - x\right)\\
\mathbf{if}\;y \leq -4.4 \cdot 10^{+70}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -8 \cdot 10^{-15}:\\
\;\;\;\;\left(y - z\right) \cdot t\\
\mathbf{elif}\;y \leq -1.55 \cdot 10^{-92}:\\
\;\;\;\;x \cdot \left(z + 1\right)\\
\mathbf{elif}\;y \leq 2.8 \cdot 10^{-236}:\\
\;\;\;\;x - z \cdot t\\
\mathbf{elif}\;y \leq 8 \cdot 10^{-11}:\\
\;\;\;\;z \cdot \left(x - t\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -4.40000000000000001e70 or 7.99999999999999952e-11 < y Initial program 99.9%
sub-neg99.9%
distribute-lft-in94.0%
Applied egg-rr94.0%
Taylor expanded in y around inf 88.9%
Taylor expanded in x around 0 88.9%
+-commutative88.9%
fma-def91.5%
mul-1-neg91.5%
unsub-neg91.5%
*-commutative91.5%
Simplified91.5%
Taylor expanded in y around inf 83.5%
neg-mul-183.5%
sub-neg83.5%
Simplified83.5%
if -4.40000000000000001e70 < y < -8.0000000000000006e-15Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt47.5%
associate-*r*47.5%
fma-def47.5%
Applied egg-rr47.5%
Taylor expanded in x around 0 84.7%
*-commutative84.7%
Simplified84.7%
if -8.0000000000000006e-15 < y < -1.55e-92Initial program 100.0%
Taylor expanded in x around inf 67.6%
mul-1-neg67.6%
unsub-neg67.6%
Simplified67.6%
Taylor expanded in y around 0 67.4%
+-commutative67.4%
Simplified67.4%
if -1.55e-92 < y < 2.79999999999999986e-236Initial program 100.0%
Taylor expanded in y around 0 100.0%
mul-1-neg100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t around inf 86.2%
if 2.79999999999999986e-236 < y < 7.99999999999999952e-11Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt38.1%
associate-*r*38.2%
fma-def38.2%
Applied egg-rr38.2%
Taylor expanded in z around inf 75.0%
associate-*r*75.0%
neg-mul-175.0%
Simplified75.0%
Final simplification81.2%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* y (- t x))))
(if (<= y -6.4e+69)
t_1
(if (<= y -4.65e-32)
(+ x (* (- y z) t))
(if (<= y 4.2e-16) (- x (* z (- t x))) (+ x t_1))))))
double code(double x, double y, double z, double t) {
double t_1 = y * (t - x);
double tmp;
if (y <= -6.4e+69) {
tmp = t_1;
} else if (y <= -4.65e-32) {
tmp = x + ((y - z) * t);
} else if (y <= 4.2e-16) {
tmp = x - (z * (t - x));
} else {
tmp = x + 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 * (t - x)
if (y <= (-6.4d+69)) then
tmp = t_1
else if (y <= (-4.65d-32)) then
tmp = x + ((y - z) * t)
else if (y <= 4.2d-16) then
tmp = x - (z * (t - x))
else
tmp = x + t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = y * (t - x);
double tmp;
if (y <= -6.4e+69) {
tmp = t_1;
} else if (y <= -4.65e-32) {
tmp = x + ((y - z) * t);
} else if (y <= 4.2e-16) {
tmp = x - (z * (t - x));
} else {
tmp = x + t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = y * (t - x) tmp = 0 if y <= -6.4e+69: tmp = t_1 elif y <= -4.65e-32: tmp = x + ((y - z) * t) elif y <= 4.2e-16: tmp = x - (z * (t - x)) else: tmp = x + t_1 return tmp
function code(x, y, z, t) t_1 = Float64(y * Float64(t - x)) tmp = 0.0 if (y <= -6.4e+69) tmp = t_1; elseif (y <= -4.65e-32) tmp = Float64(x + Float64(Float64(y - z) * t)); elseif (y <= 4.2e-16) tmp = Float64(x - Float64(z * Float64(t - x))); else tmp = Float64(x + t_1); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = y * (t - x); tmp = 0.0; if (y <= -6.4e+69) tmp = t_1; elseif (y <= -4.65e-32) tmp = x + ((y - z) * t); elseif (y <= 4.2e-16) tmp = x - (z * (t - x)); else tmp = x + t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.4e+69], t$95$1, If[LessEqual[y, -4.65e-32], N[(x + N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.2e-16], N[(x - N[(z * N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + t$95$1), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(t - x\right)\\
\mathbf{if}\;y \leq -6.4 \cdot 10^{+69}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.65 \cdot 10^{-32}:\\
\;\;\;\;x + \left(y - z\right) \cdot t\\
\mathbf{elif}\;y \leq 4.2 \cdot 10^{-16}:\\
\;\;\;\;x - z \cdot \left(t - x\right)\\
\mathbf{else}:\\
\;\;\;\;x + t_1\\
\end{array}
\end{array}
if y < -6.3999999999999997e69Initial program 100.0%
sub-neg100.0%
distribute-lft-in94.3%
Applied egg-rr94.3%
Taylor expanded in y around inf 92.1%
Taylor expanded in x around 0 92.1%
+-commutative92.1%
fma-def95.9%
mul-1-neg95.9%
unsub-neg95.9%
*-commutative95.9%
Simplified95.9%
Taylor expanded in y around inf 92.2%
neg-mul-192.2%
sub-neg92.2%
Simplified92.2%
if -6.3999999999999997e69 < y < -4.64999999999999988e-32Initial program 100.0%
Taylor expanded in t around inf 86.1%
if -4.64999999999999988e-32 < y < 4.2000000000000002e-16Initial program 100.0%
Taylor expanded in y around 0 95.6%
mul-1-neg95.6%
unsub-neg95.6%
Simplified95.6%
if 4.2000000000000002e-16 < y Initial program 99.9%
Taylor expanded in y around inf 78.2%
*-commutative78.2%
Simplified78.2%
Final simplification89.4%
(FPCore (x y z t)
:precision binary64
(if (<= z -5.8e+28)
(* z x)
(if (<= z -2.35e-275)
(* y t)
(if (<= z 2.3e-213) x (if (<= z 31.0) (* y t) (* z x))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -5.8e+28) {
tmp = z * x;
} else if (z <= -2.35e-275) {
tmp = y * t;
} else if (z <= 2.3e-213) {
tmp = x;
} else if (z <= 31.0) {
tmp = y * t;
} else {
tmp = z * x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-5.8d+28)) then
tmp = z * x
else if (z <= (-2.35d-275)) then
tmp = y * t
else if (z <= 2.3d-213) then
tmp = x
else if (z <= 31.0d0) then
tmp = y * t
else
tmp = z * x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -5.8e+28) {
tmp = z * x;
} else if (z <= -2.35e-275) {
tmp = y * t;
} else if (z <= 2.3e-213) {
tmp = x;
} else if (z <= 31.0) {
tmp = y * t;
} else {
tmp = z * x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -5.8e+28: tmp = z * x elif z <= -2.35e-275: tmp = y * t elif z <= 2.3e-213: tmp = x elif z <= 31.0: tmp = y * t else: tmp = z * x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -5.8e+28) tmp = Float64(z * x); elseif (z <= -2.35e-275) tmp = Float64(y * t); elseif (z <= 2.3e-213) tmp = x; elseif (z <= 31.0) tmp = Float64(y * t); else tmp = Float64(z * x); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -5.8e+28) tmp = z * x; elseif (z <= -2.35e-275) tmp = y * t; elseif (z <= 2.3e-213) tmp = x; elseif (z <= 31.0) tmp = y * t; else tmp = z * x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -5.8e+28], N[(z * x), $MachinePrecision], If[LessEqual[z, -2.35e-275], N[(y * t), $MachinePrecision], If[LessEqual[z, 2.3e-213], x, If[LessEqual[z, 31.0], N[(y * t), $MachinePrecision], N[(z * x), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.8 \cdot 10^{+28}:\\
\;\;\;\;z \cdot x\\
\mathbf{elif}\;z \leq -2.35 \cdot 10^{-275}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;z \leq 2.3 \cdot 10^{-213}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 31:\\
\;\;\;\;y \cdot t\\
\mathbf{else}:\\
\;\;\;\;z \cdot x\\
\end{array}
\end{array}
if z < -5.8000000000000002e28 or 31 < z Initial program 100.0%
Taylor expanded in x around inf 50.6%
mul-1-neg50.6%
unsub-neg50.6%
Simplified50.6%
Taylor expanded in z around inf 40.3%
if -5.8000000000000002e28 < z < -2.3499999999999999e-275 or 2.30000000000000003e-213 < z < 31Initial program 99.9%
sub-neg99.9%
distribute-lft-in98.0%
Applied egg-rr98.0%
Taylor expanded in y around inf 89.4%
Taylor expanded in x around 0 89.4%
+-commutative89.4%
fma-def90.4%
mul-1-neg90.4%
unsub-neg90.4%
*-commutative90.4%
Simplified90.4%
Taylor expanded in x around 0 45.7%
if -2.3499999999999999e-275 < z < 2.30000000000000003e-213Initial program 99.9%
Taylor expanded in y around inf 99.9%
*-commutative99.9%
Simplified99.9%
Taylor expanded in y around 0 55.8%
Final simplification43.9%
(FPCore (x y z t) :precision binary64 (if (or (<= x -1.08e+37) (not (<= x 2.3e-36))) (* x (- 1.0 (- y z))) (* (- y z) t)))
double code(double x, double y, double z, double t) {
double tmp;
if ((x <= -1.08e+37) || !(x <= 2.3e-36)) {
tmp = x * (1.0 - (y - z));
} else {
tmp = (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 ((x <= (-1.08d+37)) .or. (.not. (x <= 2.3d-36))) then
tmp = x * (1.0d0 - (y - z))
else
tmp = (y - z) * t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((x <= -1.08e+37) || !(x <= 2.3e-36)) {
tmp = x * (1.0 - (y - z));
} else {
tmp = (y - z) * t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (x <= -1.08e+37) or not (x <= 2.3e-36): tmp = x * (1.0 - (y - z)) else: tmp = (y - z) * t return tmp
function code(x, y, z, t) tmp = 0.0 if ((x <= -1.08e+37) || !(x <= 2.3e-36)) tmp = Float64(x * Float64(1.0 - Float64(y - z))); else tmp = Float64(Float64(y - z) * t); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((x <= -1.08e+37) || ~((x <= 2.3e-36))) tmp = x * (1.0 - (y - z)); else tmp = (y - z) * t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[x, -1.08e+37], N[Not[LessEqual[x, 2.3e-36]], $MachinePrecision]], N[(x * N[(1.0 - N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.08 \cdot 10^{+37} \lor \neg \left(x \leq 2.3 \cdot 10^{-36}\right):\\
\;\;\;\;x \cdot \left(1 - \left(y - z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(y - z\right) \cdot t\\
\end{array}
\end{array}
if x < -1.08e37 or 2.29999999999999996e-36 < x Initial program 100.0%
Taylor expanded in x around inf 84.2%
mul-1-neg84.2%
unsub-neg84.2%
Simplified84.2%
if -1.08e37 < x < 2.29999999999999996e-36Initial program 100.0%
+-commutative100.0%
add-sqr-sqrt50.2%
associate-*r*50.1%
fma-def50.1%
Applied egg-rr50.1%
Taylor expanded in x around 0 78.1%
*-commutative78.1%
Simplified78.1%
Final simplification81.0%
(FPCore (x y z t) :precision binary64 (if (or (<= x -1.25e+43) (not (<= x 5.2e+32))) (* x (- 1.0 (- y z))) (+ x (* (- y z) t))))
double code(double x, double y, double z, double t) {
double tmp;
if ((x <= -1.25e+43) || !(x <= 5.2e+32)) {
tmp = x * (1.0 - (y - z));
} else {
tmp = x + ((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 ((x <= (-1.25d+43)) .or. (.not. (x <= 5.2d+32))) then
tmp = x * (1.0d0 - (y - z))
else
tmp = x + ((y - z) * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((x <= -1.25e+43) || !(x <= 5.2e+32)) {
tmp = x * (1.0 - (y - z));
} else {
tmp = x + ((y - z) * t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (x <= -1.25e+43) or not (x <= 5.2e+32): tmp = x * (1.0 - (y - z)) else: tmp = x + ((y - z) * t) return tmp
function code(x, y, z, t) tmp = 0.0 if ((x <= -1.25e+43) || !(x <= 5.2e+32)) tmp = Float64(x * Float64(1.0 - Float64(y - z))); else tmp = Float64(x + Float64(Float64(y - z) * t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((x <= -1.25e+43) || ~((x <= 5.2e+32))) tmp = x * (1.0 - (y - z)); else tmp = x + ((y - z) * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[x, -1.25e+43], N[Not[LessEqual[x, 5.2e+32]], $MachinePrecision]], N[(x * N[(1.0 - N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.25 \cdot 10^{+43} \lor \neg \left(x \leq 5.2 \cdot 10^{+32}\right):\\
\;\;\;\;x \cdot \left(1 - \left(y - z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(y - z\right) \cdot t\\
\end{array}
\end{array}
if x < -1.2500000000000001e43 or 5.2000000000000004e32 < x Initial program 100.0%
Taylor expanded in x around inf 87.1%
mul-1-neg87.1%
unsub-neg87.1%
Simplified87.1%
if -1.2500000000000001e43 < x < 5.2000000000000004e32Initial program 100.0%
Taylor expanded in t around inf 83.9%
Final simplification85.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* y (- x))))
(if (<= x -3.1e+82)
t_1
(if (<= x 4e-43) (* y t) (if (<= x 6.4e+208) (* z x) t_1)))))
double code(double x, double y, double z, double t) {
double t_1 = y * -x;
double tmp;
if (x <= -3.1e+82) {
tmp = t_1;
} else if (x <= 4e-43) {
tmp = y * t;
} else if (x <= 6.4e+208) {
tmp = z * x;
} 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 * -x
if (x <= (-3.1d+82)) then
tmp = t_1
else if (x <= 4d-43) then
tmp = y * t
else if (x <= 6.4d+208) then
tmp = z * x
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 * -x;
double tmp;
if (x <= -3.1e+82) {
tmp = t_1;
} else if (x <= 4e-43) {
tmp = y * t;
} else if (x <= 6.4e+208) {
tmp = z * x;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = y * -x tmp = 0 if x <= -3.1e+82: tmp = t_1 elif x <= 4e-43: tmp = y * t elif x <= 6.4e+208: tmp = z * x else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(y * Float64(-x)) tmp = 0.0 if (x <= -3.1e+82) tmp = t_1; elseif (x <= 4e-43) tmp = Float64(y * t); elseif (x <= 6.4e+208) tmp = Float64(z * x); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = y * -x; tmp = 0.0; if (x <= -3.1e+82) tmp = t_1; elseif (x <= 4e-43) tmp = y * t; elseif (x <= 6.4e+208) tmp = z * x; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y * (-x)), $MachinePrecision]}, If[LessEqual[x, -3.1e+82], t$95$1, If[LessEqual[x, 4e-43], N[(y * t), $MachinePrecision], If[LessEqual[x, 6.4e+208], N[(z * x), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(-x\right)\\
\mathbf{if}\;x \leq -3.1 \cdot 10^{+82}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 4 \cdot 10^{-43}:\\
\;\;\;\;y \cdot t\\
\mathbf{elif}\;x \leq 6.4 \cdot 10^{+208}:\\
\;\;\;\;z \cdot x\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if x < -3.10000000000000032e82 or 6.4000000000000002e208 < x Initial program 100.0%
Taylor expanded in x around inf 95.6%
mul-1-neg95.6%
unsub-neg95.6%
Simplified95.6%
Taylor expanded in y around inf 46.0%
mul-1-neg46.0%
Simplified46.0%
if -3.10000000000000032e82 < x < 4.00000000000000031e-43Initial program 100.0%
sub-neg100.0%
distribute-lft-in100.0%
Applied egg-rr100.0%
Taylor expanded in y around inf 65.4%
Taylor expanded in x around 0 65.3%
+-commutative65.3%
fma-def65.3%
mul-1-neg65.3%
unsub-neg65.3%
*-commutative65.3%
Simplified65.3%
Taylor expanded in x around 0 42.2%
if 4.00000000000000031e-43 < x < 6.4000000000000002e208Initial program 100.0%
Taylor expanded in x around inf 72.0%
mul-1-neg72.0%
unsub-neg72.0%
Simplified72.0%
Taylor expanded in z around inf 37.7%
Final simplification42.4%
(FPCore (x y z t) :precision binary64 (+ x (* (- y z) (- t x))))
double code(double x, double y, double z, double t) {
return x + ((y - z) * (t - 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 + ((y - z) * (t - x))
end function
public static double code(double x, double y, double z, double t) {
return x + ((y - z) * (t - x));
}
def code(x, y, z, t): return x + ((y - z) * (t - x))
function code(x, y, z, t) return Float64(x + Float64(Float64(y - z) * Float64(t - x))) end
function tmp = code(x, y, z, t) tmp = x + ((y - z) * (t - x)); end
code[x_, y_, z_, t_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \left(t - x\right)
\end{array}
Initial program 100.0%
Final simplification100.0%
(FPCore (x y z t) :precision binary64 (if (or (<= y -4.6e-65) (not (<= y 4.15e-13))) (* y t) x))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -4.6e-65) || !(y <= 4.15e-13)) {
tmp = y * t;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if ((y <= (-4.6d-65)) .or. (.not. (y <= 4.15d-13))) then
tmp = y * t
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -4.6e-65) || !(y <= 4.15e-13)) {
tmp = y * t;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -4.6e-65) or not (y <= 4.15e-13): tmp = y * t else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -4.6e-65) || !(y <= 4.15e-13)) tmp = Float64(y * t); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -4.6e-65) || ~((y <= 4.15e-13))) tmp = y * t; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -4.6e-65], N[Not[LessEqual[y, 4.15e-13]], $MachinePrecision]], N[(y * t), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.6 \cdot 10^{-65} \lor \neg \left(y \leq 4.15 \cdot 10^{-13}\right):\\
\;\;\;\;y \cdot t\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -4.5999999999999999e-65 or 4.14999999999999999e-13 < y Initial program 100.0%
sub-neg100.0%
distribute-lft-in94.8%
Applied egg-rr94.8%
Taylor expanded in y around inf 85.6%
Taylor expanded in x around 0 85.6%
+-commutative85.6%
fma-def87.6%
mul-1-neg87.6%
unsub-neg87.6%
*-commutative87.6%
Simplified87.6%
Taylor expanded in x around 0 45.0%
if -4.5999999999999999e-65 < y < 4.14999999999999999e-13Initial program 100.0%
Taylor expanded in y around inf 32.3%
*-commutative32.3%
Simplified32.3%
Taylor expanded in y around 0 29.2%
Final simplification38.6%
(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 100.0%
Taylor expanded in y around inf 59.0%
*-commutative59.0%
Simplified59.0%
Taylor expanded in y around 0 14.8%
Final simplification14.8%
(FPCore (x y z t) :precision binary64 (+ x (+ (* t (- y z)) (* (- x) (- y z)))))
double code(double x, double y, double z, double t) {
return x + ((t * (y - z)) + (-x * (y - z)));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x + ((t * (y - z)) + (-x * (y - z)))
end function
public static double code(double x, double y, double z, double t) {
return x + ((t * (y - z)) + (-x * (y - z)));
}
def code(x, y, z, t): return x + ((t * (y - z)) + (-x * (y - z)))
function code(x, y, z, t) return Float64(x + Float64(Float64(t * Float64(y - z)) + Float64(Float64(-x) * Float64(y - z)))) end
function tmp = code(x, y, z, t) tmp = x + ((t * (y - z)) + (-x * (y - z))); end
code[x_, y_, z_, t_] := N[(x + N[(N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision] + N[((-x) * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(t \cdot \left(y - z\right) + \left(-x\right) \cdot \left(y - z\right)\right)
\end{array}
herbie shell --seed 2023331
(FPCore (x y z t)
:name "Data.Metrics.Snapshot:quantile from metrics-0.3.0.2"
:precision binary64
:herbie-target
(+ x (+ (* t (- y z)) (* (- x) (- y z))))
(+ x (* (- y z) (- t x))))