
(FPCore (x y z t a b) :precision binary64 (+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = ((x - ((y - 1.0d0) * z)) - ((t - 1.0d0) * a)) + (((y + t) - 2.0d0) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
def code(x, y, z, t, a, b): return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x - Float64(Float64(y - 1.0) * z)) - Float64(Float64(t - 1.0) * a)) + Float64(Float64(Float64(y + t) - 2.0) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x - N[(N[(y - 1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - N[(N[(t - 1.0), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 23 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = ((x - ((y - 1.0d0) * z)) - ((t - 1.0d0) * a)) + (((y + t) - 2.0d0) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
def code(x, y, z, t, a, b): return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x - Float64(Float64(y - 1.0) * z)) - Float64(Float64(t - 1.0) * a)) + Float64(Float64(Float64(y + t) - 2.0) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x - N[(N[(y - 1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - N[(N[(t - 1.0), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b
\end{array}
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (- x (* (+ y -1.0) z))))
(if (<= (+ (+ t_1 (* a (- 1.0 t))) (* b (- (+ y t) 2.0))) INFINITY)
(- t_1 (- (* a (+ t -1.0)) (* b (+ t (+ y -2.0)))))
(* t (- b a)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x - ((y + -1.0) * z);
double tmp;
if (((t_1 + (a * (1.0 - t))) + (b * ((y + t) - 2.0))) <= ((double) INFINITY)) {
tmp = t_1 - ((a * (t + -1.0)) - (b * (t + (y + -2.0))));
} else {
tmp = t * (b - a);
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x - ((y + -1.0) * z);
double tmp;
if (((t_1 + (a * (1.0 - t))) + (b * ((y + t) - 2.0))) <= Double.POSITIVE_INFINITY) {
tmp = t_1 - ((a * (t + -1.0)) - (b * (t + (y + -2.0))));
} else {
tmp = t * (b - a);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x - ((y + -1.0) * z) tmp = 0 if ((t_1 + (a * (1.0 - t))) + (b * ((y + t) - 2.0))) <= math.inf: tmp = t_1 - ((a * (t + -1.0)) - (b * (t + (y + -2.0)))) else: tmp = t * (b - a) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x - Float64(Float64(y + -1.0) * z)) tmp = 0.0 if (Float64(Float64(t_1 + Float64(a * Float64(1.0 - t))) + Float64(b * Float64(Float64(y + t) - 2.0))) <= Inf) tmp = Float64(t_1 - Float64(Float64(a * Float64(t + -1.0)) - Float64(b * Float64(t + Float64(y + -2.0))))); else tmp = Float64(t * Float64(b - a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x - ((y + -1.0) * z); tmp = 0.0; if (((t_1 + (a * (1.0 - t))) + (b * ((y + t) - 2.0))) <= Inf) tmp = t_1 - ((a * (t + -1.0)) - (b * (t + (y + -2.0)))); else tmp = t * (b - a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(t$95$1 + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[(t$95$1 - N[(N[(a * N[(t + -1.0), $MachinePrecision]), $MachinePrecision] - N[(b * N[(t + N[(y + -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x - \left(y + -1\right) \cdot z\\
\mathbf{if}\;\left(t\_1 + a \cdot \left(1 - t\right)\right) + b \cdot \left(\left(y + t\right) - 2\right) \leq \infty:\\
\;\;\;\;t\_1 - \left(a \cdot \left(t + -1\right) - b \cdot \left(t + \left(y + -2\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(b - a\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) < +inf.0Initial program 100.0%
associate-+l-100.0%
sub-neg100.0%
metadata-eval100.0%
*-commutative100.0%
sub-neg100.0%
metadata-eval100.0%
sub-neg100.0%
metadata-eval100.0%
associate-+r+100.0%
+-commutative100.0%
associate-+l+100.0%
Applied egg-rr100.0%
if +inf.0 < (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) Initial program 0.0%
Taylor expanded in t around inf 78.0%
Final simplification99.2%
(FPCore (x y z t a b) :precision binary64 (fma (+ y (+ t -2.0)) b (- x (fma (+ y -1.0) z (* a (+ t -1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
return fma((y + (t + -2.0)), b, (x - fma((y + -1.0), z, (a * (t + -1.0)))));
}
function code(x, y, z, t, a, b) return fma(Float64(y + Float64(t + -2.0)), b, Float64(x - fma(Float64(y + -1.0), z, Float64(a * Float64(t + -1.0))))) end
code[x_, y_, z_, t_, a_, b_] := N[(N[(y + N[(t + -2.0), $MachinePrecision]), $MachinePrecision] * b + N[(x - N[(N[(y + -1.0), $MachinePrecision] * z + N[(a * N[(t + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, a \cdot \left(t + -1\right)\right)\right)
\end{array}
Initial program 96.5%
+-commutative96.5%
fma-define97.6%
associate--l+97.6%
sub-neg97.6%
metadata-eval97.6%
sub-neg97.6%
associate-+l-97.6%
fmm-def98.8%
sub-neg98.8%
metadata-eval98.8%
remove-double-neg98.8%
sub-neg98.8%
metadata-eval98.8%
Simplified98.8%
Final simplification98.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(+ (+ (- x (* (+ y -1.0) z)) (* a (- 1.0 t))) (* b (- (+ y t) 2.0)))))
(if (<= t_1 INFINITY) t_1 (* t (- b a)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x - ((y + -1.0) * z)) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = t * (b - a);
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x - ((y + -1.0) * z)) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = t * (b - a);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x - ((y + -1.0) * z)) + (a * (1.0 - t))) + (b * ((y + t) - 2.0)) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = t * (b - a) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x - Float64(Float64(y + -1.0) * z)) + Float64(a * Float64(1.0 - t))) + Float64(b * Float64(Float64(y + t) - 2.0))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(t * Float64(b - a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x - ((y + -1.0) * z)) + (a * (1.0 - t))) + (b * ((y + t) - 2.0)); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = t * (b - a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(x - \left(y + -1\right) \cdot z\right) + a \cdot \left(1 - t\right)\right) + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(b - a\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) < +inf.0Initial program 100.0%
if +inf.0 < (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) Initial program 0.0%
Taylor expanded in t around inf 78.0%
Final simplification99.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ (- x (* (+ y -1.0) z)) (* y b))))
(if (<= y -2.85e+57)
t_1
(if (<= y -1.4e-246)
(+ x (+ z (* a (- 1.0 t))))
(if (<= y 0.00055) (+ x (- z (* b (- 2.0 t)))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x - ((y + -1.0) * z)) + (y * b);
double tmp;
if (y <= -2.85e+57) {
tmp = t_1;
} else if (y <= -1.4e-246) {
tmp = x + (z + (a * (1.0 - t)));
} else if (y <= 0.00055) {
tmp = x + (z - (b * (2.0 - t)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (x - ((y + (-1.0d0)) * z)) + (y * b)
if (y <= (-2.85d+57)) then
tmp = t_1
else if (y <= (-1.4d-246)) then
tmp = x + (z + (a * (1.0d0 - t)))
else if (y <= 0.00055d0) then
tmp = x + (z - (b * (2.0d0 - t)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x - ((y + -1.0) * z)) + (y * b);
double tmp;
if (y <= -2.85e+57) {
tmp = t_1;
} else if (y <= -1.4e-246) {
tmp = x + (z + (a * (1.0 - t)));
} else if (y <= 0.00055) {
tmp = x + (z - (b * (2.0 - t)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x - ((y + -1.0) * z)) + (y * b) tmp = 0 if y <= -2.85e+57: tmp = t_1 elif y <= -1.4e-246: tmp = x + (z + (a * (1.0 - t))) elif y <= 0.00055: tmp = x + (z - (b * (2.0 - t))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x - Float64(Float64(y + -1.0) * z)) + Float64(y * b)) tmp = 0.0 if (y <= -2.85e+57) tmp = t_1; elseif (y <= -1.4e-246) tmp = Float64(x + Float64(z + Float64(a * Float64(1.0 - t)))); elseif (y <= 0.00055) tmp = Float64(x + Float64(z - Float64(b * Float64(2.0 - t)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x - ((y + -1.0) * z)) + (y * b); tmp = 0.0; if (y <= -2.85e+57) tmp = t_1; elseif (y <= -1.4e-246) tmp = x + (z + (a * (1.0 - t))); elseif (y <= 0.00055) tmp = x + (z - (b * (2.0 - t))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] + N[(y * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.85e+57], t$95$1, If[LessEqual[y, -1.4e-246], N[(x + N[(z + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 0.00055], N[(x + N[(z - N[(b * N[(2.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x - \left(y + -1\right) \cdot z\right) + y \cdot b\\
\mathbf{if}\;y \leq -2.85 \cdot 10^{+57}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.4 \cdot 10^{-246}:\\
\;\;\;\;x + \left(z + a \cdot \left(1 - t\right)\right)\\
\mathbf{elif}\;y \leq 0.00055:\\
\;\;\;\;x + \left(z - b \cdot \left(2 - t\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -2.8499999999999999e57 or 5.50000000000000033e-4 < y Initial program 93.1%
associate-+l-93.1%
sub-neg93.1%
metadata-eval93.1%
*-commutative93.1%
sub-neg93.1%
metadata-eval93.1%
sub-neg93.1%
metadata-eval93.1%
associate-+r+93.1%
+-commutative93.1%
associate-+l+93.1%
Applied egg-rr93.1%
Taylor expanded in y around inf 75.7%
mul-1-neg75.7%
distribute-rgt-neg-in75.7%
Simplified75.7%
if -2.8499999999999999e57 < y < -1.4e-246Initial program 100.0%
Taylor expanded in b around 0 79.3%
Taylor expanded in y around 0 77.8%
mul-1-neg77.8%
Simplified77.8%
if -1.4e-246 < y < 5.50000000000000033e-4Initial program 97.7%
associate-+l-97.8%
sub-neg97.8%
metadata-eval97.8%
*-commutative97.8%
sub-neg97.8%
metadata-eval97.8%
sub-neg97.8%
metadata-eval97.8%
associate-+r+97.8%
+-commutative97.8%
associate-+l+97.8%
Applied egg-rr97.8%
Taylor expanded in a around 0 73.2%
mul-1-neg73.2%
sub-neg73.2%
metadata-eval73.2%
associate-+r+73.2%
distribute-rgt-neg-in73.2%
associate-+r+73.2%
+-commutative73.2%
+-commutative73.2%
distribute-neg-in73.2%
metadata-eval73.2%
sub-neg73.2%
+-commutative73.2%
associate--r+73.2%
Simplified73.2%
Taylor expanded in y around 0 73.2%
+-commutative73.2%
neg-mul-173.2%
unsub-neg73.2%
Simplified73.2%
Final simplification75.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* a (- 1.0 t))))
(if (or (<= z -1550000000000.0) (not (<= z 5.2e-32)))
(+ x (- t_1 (* (+ y -1.0) z)))
(+ x (+ (* (+ y (+ t -2.0)) b) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = a * (1.0 - t);
double tmp;
if ((z <= -1550000000000.0) || !(z <= 5.2e-32)) {
tmp = x + (t_1 - ((y + -1.0) * z));
} else {
tmp = x + (((y + (t + -2.0)) * b) + t_1);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = a * (1.0d0 - t)
if ((z <= (-1550000000000.0d0)) .or. (.not. (z <= 5.2d-32))) then
tmp = x + (t_1 - ((y + (-1.0d0)) * z))
else
tmp = x + (((y + (t + (-2.0d0))) * b) + t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = a * (1.0 - t);
double tmp;
if ((z <= -1550000000000.0) || !(z <= 5.2e-32)) {
tmp = x + (t_1 - ((y + -1.0) * z));
} else {
tmp = x + (((y + (t + -2.0)) * b) + t_1);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = a * (1.0 - t) tmp = 0 if (z <= -1550000000000.0) or not (z <= 5.2e-32): tmp = x + (t_1 - ((y + -1.0) * z)) else: tmp = x + (((y + (t + -2.0)) * b) + t_1) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(a * Float64(1.0 - t)) tmp = 0.0 if ((z <= -1550000000000.0) || !(z <= 5.2e-32)) tmp = Float64(x + Float64(t_1 - Float64(Float64(y + -1.0) * z))); else tmp = Float64(x + Float64(Float64(Float64(y + Float64(t + -2.0)) * b) + t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = a * (1.0 - t); tmp = 0.0; if ((z <= -1550000000000.0) || ~((z <= 5.2e-32))) tmp = x + (t_1 - ((y + -1.0) * z)); else tmp = x + (((y + (t + -2.0)) * b) + t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[z, -1550000000000.0], N[Not[LessEqual[z, 5.2e-32]], $MachinePrecision]], N[(x + N[(t$95$1 - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(y + N[(t + -2.0), $MachinePrecision]), $MachinePrecision] * b), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
\mathbf{if}\;z \leq -1550000000000 \lor \neg \left(z \leq 5.2 \cdot 10^{-32}\right):\\
\;\;\;\;x + \left(t\_1 - \left(y + -1\right) \cdot z\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(\left(y + \left(t + -2\right)\right) \cdot b + t\_1\right)\\
\end{array}
\end{array}
if z < -1.55e12 or 5.1999999999999995e-32 < z Initial program 96.9%
Taylor expanded in b around 0 82.2%
if -1.55e12 < z < 5.1999999999999995e-32Initial program 96.1%
associate-+l-96.1%
sub-neg96.1%
metadata-eval96.1%
*-commutative96.1%
sub-neg96.1%
metadata-eval96.1%
sub-neg96.1%
metadata-eval96.1%
associate-+r+96.1%
+-commutative96.1%
associate-+l+96.1%
Applied egg-rr96.1%
Taylor expanded in z around 0 94.0%
associate--l+94.0%
sub-neg94.0%
+-commutative94.0%
metadata-eval94.0%
associate-+l+94.0%
sub-neg94.0%
metadata-eval94.0%
+-commutative94.0%
Simplified94.0%
Final simplification88.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* a (- 1.0 t))))
(if (<= z -2.4e+85)
(+ (+ x (* b (- (+ y t) 2.0))) (* z (- 1.0 y)))
(if (<= z 5.2e-32)
(+ x (+ (* (+ y (+ t -2.0)) b) t_1))
(+ x (- t_1 (* (+ y -1.0) z)))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = a * (1.0 - t);
double tmp;
if (z <= -2.4e+85) {
tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y));
} else if (z <= 5.2e-32) {
tmp = x + (((y + (t + -2.0)) * b) + t_1);
} else {
tmp = x + (t_1 - ((y + -1.0) * z));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = a * (1.0d0 - t)
if (z <= (-2.4d+85)) then
tmp = (x + (b * ((y + t) - 2.0d0))) + (z * (1.0d0 - y))
else if (z <= 5.2d-32) then
tmp = x + (((y + (t + (-2.0d0))) * b) + t_1)
else
tmp = x + (t_1 - ((y + (-1.0d0)) * z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = a * (1.0 - t);
double tmp;
if (z <= -2.4e+85) {
tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y));
} else if (z <= 5.2e-32) {
tmp = x + (((y + (t + -2.0)) * b) + t_1);
} else {
tmp = x + (t_1 - ((y + -1.0) * z));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = a * (1.0 - t) tmp = 0 if z <= -2.4e+85: tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y)) elif z <= 5.2e-32: tmp = x + (((y + (t + -2.0)) * b) + t_1) else: tmp = x + (t_1 - ((y + -1.0) * z)) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(a * Float64(1.0 - t)) tmp = 0.0 if (z <= -2.4e+85) tmp = Float64(Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))) + Float64(z * Float64(1.0 - y))); elseif (z <= 5.2e-32) tmp = Float64(x + Float64(Float64(Float64(y + Float64(t + -2.0)) * b) + t_1)); else tmp = Float64(x + Float64(t_1 - Float64(Float64(y + -1.0) * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = a * (1.0 - t); tmp = 0.0; if (z <= -2.4e+85) tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y)); elseif (z <= 5.2e-32) tmp = x + (((y + (t + -2.0)) * b) + t_1); else tmp = x + (t_1 - ((y + -1.0) * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.4e+85], N[(N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.2e-32], N[(x + N[(N[(N[(y + N[(t + -2.0), $MachinePrecision]), $MachinePrecision] * b), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision], N[(x + N[(t$95$1 - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
\mathbf{if}\;z \leq -2.4 \cdot 10^{+85}:\\
\;\;\;\;\left(x + b \cdot \left(\left(y + t\right) - 2\right)\right) + z \cdot \left(1 - y\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{-32}:\\
\;\;\;\;x + \left(\left(y + \left(t + -2\right)\right) \cdot b + t\_1\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(t\_1 - \left(y + -1\right) \cdot z\right)\\
\end{array}
\end{array}
if z < -2.39999999999999997e85Initial program 97.9%
Taylor expanded in a around 0 90.3%
if -2.39999999999999997e85 < z < 5.1999999999999995e-32Initial program 95.9%
associate-+l-95.9%
sub-neg95.9%
metadata-eval95.9%
*-commutative95.9%
sub-neg95.9%
metadata-eval95.9%
sub-neg95.9%
metadata-eval95.9%
associate-+r+95.9%
+-commutative95.9%
associate-+l+95.9%
Applied egg-rr95.9%
Taylor expanded in z around 0 92.0%
associate--l+92.0%
sub-neg92.0%
+-commutative92.0%
metadata-eval92.0%
associate-+l+92.0%
sub-neg92.0%
metadata-eval92.0%
+-commutative92.0%
Simplified92.0%
if 5.1999999999999995e-32 < z Initial program 96.7%
Taylor expanded in b around 0 84.2%
Final simplification89.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* y (- b z))))
(if (<= y -7.6e+55)
t_1
(if (<= y -3.5e-24)
(+ x (* a (- 1.0 t)))
(if (<= y 1.35e+65) (+ x (- z (* b (- 2.0 t)))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (b - z);
double tmp;
if (y <= -7.6e+55) {
tmp = t_1;
} else if (y <= -3.5e-24) {
tmp = x + (a * (1.0 - t));
} else if (y <= 1.35e+65) {
tmp = x + (z - (b * (2.0 - t)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = y * (b - z)
if (y <= (-7.6d+55)) then
tmp = t_1
else if (y <= (-3.5d-24)) then
tmp = x + (a * (1.0d0 - t))
else if (y <= 1.35d+65) then
tmp = x + (z - (b * (2.0d0 - t)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (b - z);
double tmp;
if (y <= -7.6e+55) {
tmp = t_1;
} else if (y <= -3.5e-24) {
tmp = x + (a * (1.0 - t));
} else if (y <= 1.35e+65) {
tmp = x + (z - (b * (2.0 - t)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = y * (b - z) tmp = 0 if y <= -7.6e+55: tmp = t_1 elif y <= -3.5e-24: tmp = x + (a * (1.0 - t)) elif y <= 1.35e+65: tmp = x + (z - (b * (2.0 - t))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(y * Float64(b - z)) tmp = 0.0 if (y <= -7.6e+55) tmp = t_1; elseif (y <= -3.5e-24) tmp = Float64(x + Float64(a * Float64(1.0 - t))); elseif (y <= 1.35e+65) tmp = Float64(x + Float64(z - Float64(b * Float64(2.0 - t)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = y * (b - z); tmp = 0.0; if (y <= -7.6e+55) tmp = t_1; elseif (y <= -3.5e-24) tmp = x + (a * (1.0 - t)); elseif (y <= 1.35e+65) tmp = x + (z - (b * (2.0 - t))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -7.6e+55], t$95$1, If[LessEqual[y, -3.5e-24], N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.35e+65], N[(x + N[(z - N[(b * N[(2.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(b - z\right)\\
\mathbf{if}\;y \leq -7.6 \cdot 10^{+55}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -3.5 \cdot 10^{-24}:\\
\;\;\;\;x + a \cdot \left(1 - t\right)\\
\mathbf{elif}\;y \leq 1.35 \cdot 10^{+65}:\\
\;\;\;\;x + \left(z - b \cdot \left(2 - t\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -7.5999999999999999e55 or 1.35000000000000009e65 < y Initial program 92.2%
Taylor expanded in y around inf 72.4%
if -7.5999999999999999e55 < y < -3.4999999999999996e-24Initial program 100.0%
Taylor expanded in b around 0 78.9%
Taylor expanded in a around inf 73.0%
if -3.4999999999999996e-24 < y < 1.35000000000000009e65Initial program 98.6%
associate-+l-98.6%
sub-neg98.6%
metadata-eval98.6%
*-commutative98.6%
sub-neg98.6%
metadata-eval98.6%
sub-neg98.6%
metadata-eval98.6%
associate-+r+98.6%
+-commutative98.6%
associate-+l+98.6%
Applied egg-rr98.6%
Taylor expanded in a around 0 72.1%
mul-1-neg72.1%
sub-neg72.1%
metadata-eval72.1%
associate-+r+72.1%
distribute-rgt-neg-in72.1%
associate-+r+72.1%
+-commutative72.1%
+-commutative72.1%
distribute-neg-in72.1%
metadata-eval72.1%
sub-neg72.1%
+-commutative72.1%
associate--r+72.1%
Simplified72.1%
Taylor expanded in y around 0 69.5%
+-commutative69.5%
neg-mul-169.5%
unsub-neg69.5%
Simplified69.5%
Final simplification70.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (- x (* (+ y -1.0) z))))
(if (<= z -1.8e+82)
t_1
(if (<= z -3.4e-72)
(- x (- (* t a) a))
(if (<= z 5.2e-32) (+ x (* b (- (+ y t) 2.0))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x - ((y + -1.0) * z);
double tmp;
if (z <= -1.8e+82) {
tmp = t_1;
} else if (z <= -3.4e-72) {
tmp = x - ((t * a) - a);
} else if (z <= 5.2e-32) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = x - ((y + (-1.0d0)) * z)
if (z <= (-1.8d+82)) then
tmp = t_1
else if (z <= (-3.4d-72)) then
tmp = x - ((t * a) - a)
else if (z <= 5.2d-32) then
tmp = x + (b * ((y + t) - 2.0d0))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x - ((y + -1.0) * z);
double tmp;
if (z <= -1.8e+82) {
tmp = t_1;
} else if (z <= -3.4e-72) {
tmp = x - ((t * a) - a);
} else if (z <= 5.2e-32) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x - ((y + -1.0) * z) tmp = 0 if z <= -1.8e+82: tmp = t_1 elif z <= -3.4e-72: tmp = x - ((t * a) - a) elif z <= 5.2e-32: tmp = x + (b * ((y + t) - 2.0)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x - Float64(Float64(y + -1.0) * z)) tmp = 0.0 if (z <= -1.8e+82) tmp = t_1; elseif (z <= -3.4e-72) tmp = Float64(x - Float64(Float64(t * a) - a)); elseif (z <= 5.2e-32) tmp = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x - ((y + -1.0) * z); tmp = 0.0; if (z <= -1.8e+82) tmp = t_1; elseif (z <= -3.4e-72) tmp = x - ((t * a) - a); elseif (z <= 5.2e-32) tmp = x + (b * ((y + t) - 2.0)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.8e+82], t$95$1, If[LessEqual[z, -3.4e-72], N[(x - N[(N[(t * a), $MachinePrecision] - a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.2e-32], N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x - \left(y + -1\right) \cdot z\\
\mathbf{if}\;z \leq -1.8 \cdot 10^{+82}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3.4 \cdot 10^{-72}:\\
\;\;\;\;x - \left(t \cdot a - a\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{-32}:\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.80000000000000007e82 or 5.1999999999999995e-32 < z Initial program 97.3%
Taylor expanded in b around 0 82.1%
Taylor expanded in a around 0 68.4%
if -1.80000000000000007e82 < z < -3.3999999999999998e-72Initial program 97.3%
Taylor expanded in b around 0 81.9%
Taylor expanded in a around inf 74.1%
Taylor expanded in t around 0 74.1%
if -3.3999999999999998e-72 < z < 5.1999999999999995e-32Initial program 95.3%
associate-+l-95.3%
sub-neg95.3%
metadata-eval95.3%
*-commutative95.3%
sub-neg95.3%
metadata-eval95.3%
sub-neg95.3%
metadata-eval95.3%
associate-+r+95.3%
+-commutative95.3%
associate-+l+95.3%
Applied egg-rr95.3%
Taylor expanded in a around 0 69.8%
mul-1-neg69.8%
sub-neg69.8%
metadata-eval69.8%
associate-+r+69.8%
distribute-rgt-neg-in69.8%
associate-+r+69.8%
+-commutative69.8%
+-commutative69.8%
distribute-neg-in69.8%
metadata-eval69.8%
sub-neg69.8%
+-commutative69.8%
associate--r+69.8%
Simplified69.8%
Taylor expanded in z around 0 68.2%
Final simplification69.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (- x (* (+ y -1.0) z))))
(if (<= z -5e+81)
t_1
(if (<= z -5.6e-71)
(+ x (* a (- 1.0 t)))
(if (<= z 5.2e-32) (+ x (* b (- (+ y t) 2.0))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x - ((y + -1.0) * z);
double tmp;
if (z <= -5e+81) {
tmp = t_1;
} else if (z <= -5.6e-71) {
tmp = x + (a * (1.0 - t));
} else if (z <= 5.2e-32) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = x - ((y + (-1.0d0)) * z)
if (z <= (-5d+81)) then
tmp = t_1
else if (z <= (-5.6d-71)) then
tmp = x + (a * (1.0d0 - t))
else if (z <= 5.2d-32) then
tmp = x + (b * ((y + t) - 2.0d0))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x - ((y + -1.0) * z);
double tmp;
if (z <= -5e+81) {
tmp = t_1;
} else if (z <= -5.6e-71) {
tmp = x + (a * (1.0 - t));
} else if (z <= 5.2e-32) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x - ((y + -1.0) * z) tmp = 0 if z <= -5e+81: tmp = t_1 elif z <= -5.6e-71: tmp = x + (a * (1.0 - t)) elif z <= 5.2e-32: tmp = x + (b * ((y + t) - 2.0)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x - Float64(Float64(y + -1.0) * z)) tmp = 0.0 if (z <= -5e+81) tmp = t_1; elseif (z <= -5.6e-71) tmp = Float64(x + Float64(a * Float64(1.0 - t))); elseif (z <= 5.2e-32) tmp = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x - ((y + -1.0) * z); tmp = 0.0; if (z <= -5e+81) tmp = t_1; elseif (z <= -5.6e-71) tmp = x + (a * (1.0 - t)); elseif (z <= 5.2e-32) tmp = x + (b * ((y + t) - 2.0)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5e+81], t$95$1, If[LessEqual[z, -5.6e-71], N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.2e-32], N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x - \left(y + -1\right) \cdot z\\
\mathbf{if}\;z \leq -5 \cdot 10^{+81}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -5.6 \cdot 10^{-71}:\\
\;\;\;\;x + a \cdot \left(1 - t\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{-32}:\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -4.9999999999999998e81 or 5.1999999999999995e-32 < z Initial program 97.3%
Taylor expanded in b around 0 82.1%
Taylor expanded in a around 0 68.4%
if -4.9999999999999998e81 < z < -5.60000000000000001e-71Initial program 97.3%
Taylor expanded in b around 0 81.9%
Taylor expanded in a around inf 74.1%
if -5.60000000000000001e-71 < z < 5.1999999999999995e-32Initial program 95.3%
associate-+l-95.3%
sub-neg95.3%
metadata-eval95.3%
*-commutative95.3%
sub-neg95.3%
metadata-eval95.3%
sub-neg95.3%
metadata-eval95.3%
associate-+r+95.3%
+-commutative95.3%
associate-+l+95.3%
Applied egg-rr95.3%
Taylor expanded in a around 0 69.8%
mul-1-neg69.8%
sub-neg69.8%
metadata-eval69.8%
associate-+r+69.8%
distribute-rgt-neg-in69.8%
associate-+r+69.8%
+-commutative69.8%
+-commutative69.8%
distribute-neg-in69.8%
metadata-eval69.8%
sub-neg69.8%
+-commutative69.8%
associate--r+69.8%
Simplified69.8%
Taylor expanded in z around 0 68.2%
Final simplification69.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -1.9e+83) (not (<= b 7e+101))) (+ x (* b (- (+ y t) 2.0))) (+ x (- (* a (- 1.0 t)) (* (+ y -1.0) z)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.9e+83) || !(b <= 7e+101)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = x + ((a * (1.0 - t)) - ((y + -1.0) * z));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((b <= (-1.9d+83)) .or. (.not. (b <= 7d+101))) then
tmp = x + (b * ((y + t) - 2.0d0))
else
tmp = x + ((a * (1.0d0 - t)) - ((y + (-1.0d0)) * z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.9e+83) || !(b <= 7e+101)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = x + ((a * (1.0 - t)) - ((y + -1.0) * z));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -1.9e+83) or not (b <= 7e+101): tmp = x + (b * ((y + t) - 2.0)) else: tmp = x + ((a * (1.0 - t)) - ((y + -1.0) * z)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -1.9e+83) || !(b <= 7e+101)) tmp = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))); else tmp = Float64(x + Float64(Float64(a * Float64(1.0 - t)) - Float64(Float64(y + -1.0) * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -1.9e+83) || ~((b <= 7e+101))) tmp = x + (b * ((y + t) - 2.0)); else tmp = x + ((a * (1.0 - t)) - ((y + -1.0) * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -1.9e+83], N[Not[LessEqual[b, 7e+101]], $MachinePrecision]], N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision] - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.9 \cdot 10^{+83} \lor \neg \left(b \leq 7 \cdot 10^{+101}\right):\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(a \cdot \left(1 - t\right) - \left(y + -1\right) \cdot z\right)\\
\end{array}
\end{array}
if b < -1.9000000000000001e83 or 7.00000000000000046e101 < b Initial program 91.7%
associate-+l-91.7%
sub-neg91.7%
metadata-eval91.7%
*-commutative91.7%
sub-neg91.7%
metadata-eval91.7%
sub-neg91.7%
metadata-eval91.7%
associate-+r+91.7%
+-commutative91.7%
associate-+l+91.7%
Applied egg-rr91.7%
Taylor expanded in a around 0 86.9%
mul-1-neg86.9%
sub-neg86.9%
metadata-eval86.9%
associate-+r+86.9%
distribute-rgt-neg-in86.9%
associate-+r+86.9%
+-commutative86.9%
+-commutative86.9%
distribute-neg-in86.9%
metadata-eval86.9%
sub-neg86.9%
+-commutative86.9%
associate--r+86.9%
Simplified86.9%
Taylor expanded in z around 0 80.2%
if -1.9000000000000001e83 < b < 7.00000000000000046e101Initial program 98.3%
Taylor expanded in b around 0 86.4%
Final simplification84.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* y (- b z))))
(if (<= y -2.3e+17)
t_1
(if (<= y 6.2e-120) (+ x a) (if (<= y 5.7e+66) (* t (- b a)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (b - z);
double tmp;
if (y <= -2.3e+17) {
tmp = t_1;
} else if (y <= 6.2e-120) {
tmp = x + a;
} else if (y <= 5.7e+66) {
tmp = t * (b - a);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = y * (b - z)
if (y <= (-2.3d+17)) then
tmp = t_1
else if (y <= 6.2d-120) then
tmp = x + a
else if (y <= 5.7d+66) then
tmp = t * (b - a)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (b - z);
double tmp;
if (y <= -2.3e+17) {
tmp = t_1;
} else if (y <= 6.2e-120) {
tmp = x + a;
} else if (y <= 5.7e+66) {
tmp = t * (b - a);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = y * (b - z) tmp = 0 if y <= -2.3e+17: tmp = t_1 elif y <= 6.2e-120: tmp = x + a elif y <= 5.7e+66: tmp = t * (b - a) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(y * Float64(b - z)) tmp = 0.0 if (y <= -2.3e+17) tmp = t_1; elseif (y <= 6.2e-120) tmp = Float64(x + a); elseif (y <= 5.7e+66) tmp = Float64(t * Float64(b - a)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = y * (b - z); tmp = 0.0; if (y <= -2.3e+17) tmp = t_1; elseif (y <= 6.2e-120) tmp = x + a; elseif (y <= 5.7e+66) tmp = t * (b - a); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.3e+17], t$95$1, If[LessEqual[y, 6.2e-120], N[(x + a), $MachinePrecision], If[LessEqual[y, 5.7e+66], N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(b - z\right)\\
\mathbf{if}\;y \leq -2.3 \cdot 10^{+17}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 6.2 \cdot 10^{-120}:\\
\;\;\;\;x + a\\
\mathbf{elif}\;y \leq 5.7 \cdot 10^{+66}:\\
\;\;\;\;t \cdot \left(b - a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -2.3e17 or 5.7000000000000003e66 < y Initial program 93.0%
Taylor expanded in y around inf 69.3%
if -2.3e17 < y < 6.20000000000000038e-120Initial program 99.1%
Taylor expanded in b around 0 72.4%
Taylor expanded in a around inf 55.2%
Taylor expanded in t around 0 41.2%
sub-neg41.2%
neg-mul-141.2%
remove-double-neg41.2%
+-commutative41.2%
Simplified41.2%
if 6.20000000000000038e-120 < y < 5.7000000000000003e66Initial program 97.6%
Taylor expanded in t around inf 43.5%
Final simplification52.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* t (- b a))))
(if (<= t -25500.0)
t_1
(if (<= t -1.85e-53) (* b (- y 2.0)) (if (<= t 4e+37) (+ x a) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = t * (b - a);
double tmp;
if (t <= -25500.0) {
tmp = t_1;
} else if (t <= -1.85e-53) {
tmp = b * (y - 2.0);
} else if (t <= 4e+37) {
tmp = x + a;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = t * (b - a)
if (t <= (-25500.0d0)) then
tmp = t_1
else if (t <= (-1.85d-53)) then
tmp = b * (y - 2.0d0)
else if (t <= 4d+37) then
tmp = x + a
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = t * (b - a);
double tmp;
if (t <= -25500.0) {
tmp = t_1;
} else if (t <= -1.85e-53) {
tmp = b * (y - 2.0);
} else if (t <= 4e+37) {
tmp = x + a;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = t * (b - a) tmp = 0 if t <= -25500.0: tmp = t_1 elif t <= -1.85e-53: tmp = b * (y - 2.0) elif t <= 4e+37: tmp = x + a else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(t * Float64(b - a)) tmp = 0.0 if (t <= -25500.0) tmp = t_1; elseif (t <= -1.85e-53) tmp = Float64(b * Float64(y - 2.0)); elseif (t <= 4e+37) tmp = Float64(x + a); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = t * (b - a); tmp = 0.0; if (t <= -25500.0) tmp = t_1; elseif (t <= -1.85e-53) tmp = b * (y - 2.0); elseif (t <= 4e+37) tmp = x + a; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -25500.0], t$95$1, If[LessEqual[t, -1.85e-53], N[(b * N[(y - 2.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4e+37], N[(x + a), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \left(b - a\right)\\
\mathbf{if}\;t \leq -25500:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.85 \cdot 10^{-53}:\\
\;\;\;\;b \cdot \left(y - 2\right)\\
\mathbf{elif}\;t \leq 4 \cdot 10^{+37}:\\
\;\;\;\;x + a\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -25500 or 3.99999999999999982e37 < t Initial program 92.2%
Taylor expanded in t around inf 63.9%
if -25500 < t < -1.84999999999999991e-53Initial program 99.9%
Taylor expanded in b around inf 60.0%
Taylor expanded in t around 0 56.0%
if -1.84999999999999991e-53 < t < 3.99999999999999982e37Initial program 99.3%
Taylor expanded in b around 0 76.1%
Taylor expanded in a around inf 43.3%
Taylor expanded in t around 0 41.9%
sub-neg41.9%
neg-mul-141.9%
remove-double-neg41.9%
+-commutative41.9%
Simplified41.9%
Final simplification51.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -1.25e+53) (not (<= b 2.6e+101))) (+ x (* b (- (+ y t) 2.0))) (- (+ x a) (* (+ y -1.0) z))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.25e+53) || !(b <= 2.6e+101)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = (x + a) - ((y + -1.0) * z);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((b <= (-1.25d+53)) .or. (.not. (b <= 2.6d+101))) then
tmp = x + (b * ((y + t) - 2.0d0))
else
tmp = (x + a) - ((y + (-1.0d0)) * z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.25e+53) || !(b <= 2.6e+101)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = (x + a) - ((y + -1.0) * z);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -1.25e+53) or not (b <= 2.6e+101): tmp = x + (b * ((y + t) - 2.0)) else: tmp = (x + a) - ((y + -1.0) * z) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -1.25e+53) || !(b <= 2.6e+101)) tmp = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))); else tmp = Float64(Float64(x + a) - Float64(Float64(y + -1.0) * z)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -1.25e+53) || ~((b <= 2.6e+101))) tmp = x + (b * ((y + t) - 2.0)); else tmp = (x + a) - ((y + -1.0) * z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -1.25e+53], N[Not[LessEqual[b, 2.6e+101]], $MachinePrecision]], N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + a), $MachinePrecision] - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.25 \cdot 10^{+53} \lor \neg \left(b \leq 2.6 \cdot 10^{+101}\right):\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + a\right) - \left(y + -1\right) \cdot z\\
\end{array}
\end{array}
if b < -1.2500000000000001e53 or 2.6e101 < b Initial program 92.7%
associate-+l-92.7%
sub-neg92.7%
metadata-eval92.7%
*-commutative92.7%
sub-neg92.7%
metadata-eval92.7%
sub-neg92.7%
metadata-eval92.7%
associate-+r+92.7%
+-commutative92.7%
associate-+l+92.7%
Applied egg-rr92.7%
Taylor expanded in a around 0 86.0%
mul-1-neg86.0%
sub-neg86.0%
metadata-eval86.0%
associate-+r+86.0%
distribute-rgt-neg-in86.0%
associate-+r+86.0%
+-commutative86.0%
+-commutative86.0%
distribute-neg-in86.0%
metadata-eval86.0%
sub-neg86.0%
+-commutative86.0%
associate--r+86.0%
Simplified86.0%
Taylor expanded in z around 0 76.8%
if -1.2500000000000001e53 < b < 2.6e101Initial program 98.2%
Taylor expanded in b around 0 87.8%
Taylor expanded in t around 0 69.6%
associate--r+69.6%
sub-neg69.6%
metadata-eval69.6%
sub-neg69.6%
neg-mul-169.6%
remove-double-neg69.6%
Simplified69.6%
Final simplification71.9%
(FPCore (x y z t a b) :precision binary64 (if (<= x -1.8e+96) x (if (<= x 5.4e-270) (* t b) (if (<= x 1.22e+47) (* -2.0 b) x))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= -1.8e+96) {
tmp = x;
} else if (x <= 5.4e-270) {
tmp = t * b;
} else if (x <= 1.22e+47) {
tmp = -2.0 * b;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (x <= (-1.8d+96)) then
tmp = x
else if (x <= 5.4d-270) then
tmp = t * b
else if (x <= 1.22d+47) then
tmp = (-2.0d0) * b
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= -1.8e+96) {
tmp = x;
} else if (x <= 5.4e-270) {
tmp = t * b;
} else if (x <= 1.22e+47) {
tmp = -2.0 * b;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= -1.8e+96: tmp = x elif x <= 5.4e-270: tmp = t * b elif x <= 1.22e+47: tmp = -2.0 * b else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= -1.8e+96) tmp = x; elseif (x <= 5.4e-270) tmp = Float64(t * b); elseif (x <= 1.22e+47) tmp = Float64(-2.0 * b); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (x <= -1.8e+96) tmp = x; elseif (x <= 5.4e-270) tmp = t * b; elseif (x <= 1.22e+47) tmp = -2.0 * b; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, -1.8e+96], x, If[LessEqual[x, 5.4e-270], N[(t * b), $MachinePrecision], If[LessEqual[x, 1.22e+47], N[(-2.0 * b), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.8 \cdot 10^{+96}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 5.4 \cdot 10^{-270}:\\
\;\;\;\;t \cdot b\\
\mathbf{elif}\;x \leq 1.22 \cdot 10^{+47}:\\
\;\;\;\;-2 \cdot b\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -1.80000000000000007e96 or 1.22e47 < x Initial program 97.0%
Taylor expanded in x around inf 41.3%
if -1.80000000000000007e96 < x < 5.40000000000000014e-270Initial program 96.7%
Taylor expanded in t around inf 31.8%
Taylor expanded in b around inf 19.3%
if 5.40000000000000014e-270 < x < 1.22e47Initial program 95.4%
Taylor expanded in b around inf 40.4%
Taylor expanded in y around 0 27.2%
Taylor expanded in t around 0 19.9%
*-commutative19.9%
Simplified19.9%
Final simplification28.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -3.6e+81) (not (<= z 3.6e+18))) (- x (* (+ y -1.0) z)) (+ x (* a (- 1.0 t)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -3.6e+81) || !(z <= 3.6e+18)) {
tmp = x - ((y + -1.0) * z);
} else {
tmp = x + (a * (1.0 - t));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((z <= (-3.6d+81)) .or. (.not. (z <= 3.6d+18))) then
tmp = x - ((y + (-1.0d0)) * z)
else
tmp = x + (a * (1.0d0 - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -3.6e+81) || !(z <= 3.6e+18)) {
tmp = x - ((y + -1.0) * z);
} else {
tmp = x + (a * (1.0 - t));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -3.6e+81) or not (z <= 3.6e+18): tmp = x - ((y + -1.0) * z) else: tmp = x + (a * (1.0 - t)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -3.6e+81) || !(z <= 3.6e+18)) tmp = Float64(x - Float64(Float64(y + -1.0) * z)); else tmp = Float64(x + Float64(a * Float64(1.0 - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -3.6e+81) || ~((z <= 3.6e+18))) tmp = x - ((y + -1.0) * z); else tmp = x + (a * (1.0 - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -3.6e+81], N[Not[LessEqual[z, 3.6e+18]], $MachinePrecision]], N[(x - N[(N[(y + -1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision], N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.6 \cdot 10^{+81} \lor \neg \left(z \leq 3.6 \cdot 10^{+18}\right):\\
\;\;\;\;x - \left(y + -1\right) \cdot z\\
\mathbf{else}:\\
\;\;\;\;x + a \cdot \left(1 - t\right)\\
\end{array}
\end{array}
if z < -3.60000000000000005e81 or 3.6e18 < z Initial program 97.0%
Taylor expanded in b around 0 81.3%
Taylor expanded in a around 0 71.0%
if -3.60000000000000005e81 < z < 3.6e18Initial program 96.1%
Taylor expanded in b around 0 63.5%
Taylor expanded in a around inf 58.5%
Final simplification63.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -1e+97) (not (<= z 1.2e+105))) (* z (- 1.0 y)) (+ x (* a (- 1.0 t)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1e+97) || !(z <= 1.2e+105)) {
tmp = z * (1.0 - y);
} else {
tmp = x + (a * (1.0 - t));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((z <= (-1d+97)) .or. (.not. (z <= 1.2d+105))) then
tmp = z * (1.0d0 - y)
else
tmp = x + (a * (1.0d0 - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1e+97) || !(z <= 1.2e+105)) {
tmp = z * (1.0 - y);
} else {
tmp = x + (a * (1.0 - t));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -1e+97) or not (z <= 1.2e+105): tmp = z * (1.0 - y) else: tmp = x + (a * (1.0 - t)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -1e+97) || !(z <= 1.2e+105)) tmp = Float64(z * Float64(1.0 - y)); else tmp = Float64(x + Float64(a * Float64(1.0 - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -1e+97) || ~((z <= 1.2e+105))) tmp = z * (1.0 - y); else tmp = x + (a * (1.0 - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1e+97], N[Not[LessEqual[z, 1.2e+105]], $MachinePrecision]], N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision], N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1 \cdot 10^{+97} \lor \neg \left(z \leq 1.2 \cdot 10^{+105}\right):\\
\;\;\;\;z \cdot \left(1 - y\right)\\
\mathbf{else}:\\
\;\;\;\;x + a \cdot \left(1 - t\right)\\
\end{array}
\end{array}
if z < -1.0000000000000001e97 or 1.19999999999999987e105 < z Initial program 96.3%
Taylor expanded in z around inf 69.6%
if -1.0000000000000001e97 < z < 1.19999999999999987e105Initial program 96.6%
Taylor expanded in b around 0 64.9%
Taylor expanded in a around inf 57.0%
Final simplification60.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -4.1e+17) (not (<= y 6.2e+64))) (* y (- b z)) (+ a (+ x z))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4.1e+17) || !(y <= 6.2e+64)) {
tmp = y * (b - z);
} else {
tmp = a + (x + z);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-4.1d+17)) .or. (.not. (y <= 6.2d+64))) then
tmp = y * (b - z)
else
tmp = a + (x + z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4.1e+17) || !(y <= 6.2e+64)) {
tmp = y * (b - z);
} else {
tmp = a + (x + z);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -4.1e+17) or not (y <= 6.2e+64): tmp = y * (b - z) else: tmp = a + (x + z) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -4.1e+17) || !(y <= 6.2e+64)) tmp = Float64(y * Float64(b - z)); else tmp = Float64(a + Float64(x + z)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -4.1e+17) || ~((y <= 6.2e+64))) tmp = y * (b - z); else tmp = a + (x + z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -4.1e+17], N[Not[LessEqual[y, 6.2e+64]], $MachinePrecision]], N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision], N[(a + N[(x + z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.1 \cdot 10^{+17} \lor \neg \left(y \leq 6.2 \cdot 10^{+64}\right):\\
\;\;\;\;y \cdot \left(b - z\right)\\
\mathbf{else}:\\
\;\;\;\;a + \left(x + z\right)\\
\end{array}
\end{array}
if y < -4.1e17 or 6.1999999999999998e64 < y Initial program 93.0%
Taylor expanded in y around inf 69.3%
if -4.1e17 < y < 6.1999999999999998e64Initial program 98.7%
Taylor expanded in b around 0 71.2%
Taylor expanded in t around 0 55.9%
associate--r+55.9%
sub-neg55.9%
metadata-eval55.9%
sub-neg55.9%
neg-mul-155.9%
remove-double-neg55.9%
Simplified55.9%
Taylor expanded in y around 0 54.2%
neg-mul-154.2%
associate--l+54.2%
sub-neg54.2%
remove-double-neg54.2%
Simplified54.2%
Final simplification60.1%
(FPCore (x y z t a b) :precision binary64 (if (<= y -5.3e+121) (* y b) (if (<= y 8e+73) (+ x a) (* y (- z)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -5.3e+121) {
tmp = y * b;
} else if (y <= 8e+73) {
tmp = x + a;
} else {
tmp = y * -z;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (y <= (-5.3d+121)) then
tmp = y * b
else if (y <= 8d+73) then
tmp = x + a
else
tmp = y * -z
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -5.3e+121) {
tmp = y * b;
} else if (y <= 8e+73) {
tmp = x + a;
} else {
tmp = y * -z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -5.3e+121: tmp = y * b elif y <= 8e+73: tmp = x + a else: tmp = y * -z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -5.3e+121) tmp = Float64(y * b); elseif (y <= 8e+73) tmp = Float64(x + a); else tmp = Float64(y * Float64(-z)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -5.3e+121) tmp = y * b; elseif (y <= 8e+73) tmp = x + a; else tmp = y * -z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -5.3e+121], N[(y * b), $MachinePrecision], If[LessEqual[y, 8e+73], N[(x + a), $MachinePrecision], N[(y * (-z)), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.3 \cdot 10^{+121}:\\
\;\;\;\;y \cdot b\\
\mathbf{elif}\;y \leq 8 \cdot 10^{+73}:\\
\;\;\;\;x + a\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(-z\right)\\
\end{array}
\end{array}
if y < -5.30000000000000009e121Initial program 92.9%
Taylor expanded in b around inf 44.3%
Taylor expanded in y around inf 42.0%
*-commutative42.0%
Simplified42.0%
if -5.30000000000000009e121 < y < 7.99999999999999986e73Initial program 98.8%
Taylor expanded in b around 0 71.7%
Taylor expanded in a around inf 52.5%
Taylor expanded in t around 0 37.0%
sub-neg37.0%
neg-mul-137.0%
remove-double-neg37.0%
+-commutative37.0%
Simplified37.0%
if 7.99999999999999986e73 < y Initial program 90.5%
Taylor expanded in z around inf 65.0%
Taylor expanded in y around inf 65.0%
associate-*r*65.0%
neg-mul-165.0%
Simplified65.0%
Final simplification42.4%
(FPCore (x y z t a b) :precision binary64 (if (<= t -6.8e+65) (* t b) (if (<= t 1.95e+38) (+ x a) (* t (- a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -6.8e+65) {
tmp = t * b;
} else if (t <= 1.95e+38) {
tmp = x + a;
} else {
tmp = t * -a;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (t <= (-6.8d+65)) then
tmp = t * b
else if (t <= 1.95d+38) then
tmp = x + a
else
tmp = t * -a
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -6.8e+65) {
tmp = t * b;
} else if (t <= 1.95e+38) {
tmp = x + a;
} else {
tmp = t * -a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -6.8e+65: tmp = t * b elif t <= 1.95e+38: tmp = x + a else: tmp = t * -a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -6.8e+65) tmp = Float64(t * b); elseif (t <= 1.95e+38) tmp = Float64(x + a); else tmp = Float64(t * Float64(-a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -6.8e+65) tmp = t * b; elseif (t <= 1.95e+38) tmp = x + a; else tmp = t * -a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -6.8e+65], N[(t * b), $MachinePrecision], If[LessEqual[t, 1.95e+38], N[(x + a), $MachinePrecision], N[(t * (-a)), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.8 \cdot 10^{+65}:\\
\;\;\;\;t \cdot b\\
\mathbf{elif}\;t \leq 1.95 \cdot 10^{+38}:\\
\;\;\;\;x + a\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(-a\right)\\
\end{array}
\end{array}
if t < -6.7999999999999999e65Initial program 92.1%
Taylor expanded in t around inf 69.9%
Taylor expanded in b around inf 41.8%
if -6.7999999999999999e65 < t < 1.95000000000000012e38Initial program 99.4%
Taylor expanded in b around 0 74.8%
Taylor expanded in a around inf 42.5%
Taylor expanded in t around 0 38.6%
sub-neg38.6%
neg-mul-138.6%
remove-double-neg38.6%
+-commutative38.6%
Simplified38.6%
if 1.95000000000000012e38 < t Initial program 89.8%
Taylor expanded in t around inf 66.3%
Taylor expanded in b around 0 44.4%
associate-*r*44.4%
neg-mul-144.4%
Simplified44.4%
Final simplification40.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -6.6e+60) (not (<= t 7.8e+207))) (* t b) (+ x a)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -6.6e+60) || !(t <= 7.8e+207)) {
tmp = t * b;
} else {
tmp = x + a;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((t <= (-6.6d+60)) .or. (.not. (t <= 7.8d+207))) then
tmp = t * b
else
tmp = x + a
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -6.6e+60) || !(t <= 7.8e+207)) {
tmp = t * b;
} else {
tmp = x + a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -6.6e+60) or not (t <= 7.8e+207): tmp = t * b else: tmp = x + a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -6.6e+60) || !(t <= 7.8e+207)) tmp = Float64(t * b); else tmp = Float64(x + a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -6.6e+60) || ~((t <= 7.8e+207))) tmp = t * b; else tmp = x + a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -6.6e+60], N[Not[LessEqual[t, 7.8e+207]], $MachinePrecision]], N[(t * b), $MachinePrecision], N[(x + a), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.6 \cdot 10^{+60} \lor \neg \left(t \leq 7.8 \cdot 10^{+207}\right):\\
\;\;\;\;t \cdot b\\
\mathbf{else}:\\
\;\;\;\;x + a\\
\end{array}
\end{array}
if t < -6.5999999999999995e60 or 7.79999999999999945e207 < t Initial program 88.5%
Taylor expanded in t around inf 73.3%
Taylor expanded in b around inf 40.0%
if -6.5999999999999995e60 < t < 7.79999999999999945e207Initial program 99.0%
Taylor expanded in b around 0 75.2%
Taylor expanded in a around inf 44.7%
Taylor expanded in t around 0 35.7%
sub-neg35.7%
neg-mul-135.7%
remove-double-neg35.7%
+-commutative35.7%
Simplified35.7%
Final simplification36.7%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -4.2e+18) (not (<= y 2.3e+138))) (* y b) x))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4.2e+18) || !(y <= 2.3e+138)) {
tmp = y * b;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-4.2d+18)) .or. (.not. (y <= 2.3d+138))) then
tmp = y * b
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4.2e+18) || !(y <= 2.3e+138)) {
tmp = y * b;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -4.2e+18) or not (y <= 2.3e+138): tmp = y * b else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -4.2e+18) || !(y <= 2.3e+138)) tmp = Float64(y * b); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -4.2e+18) || ~((y <= 2.3e+138))) tmp = y * b; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -4.2e+18], N[Not[LessEqual[y, 2.3e+138]], $MachinePrecision]], N[(y * b), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.2 \cdot 10^{+18} \lor \neg \left(y \leq 2.3 \cdot 10^{+138}\right):\\
\;\;\;\;y \cdot b\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -4.2e18 or 2.30000000000000008e138 < y Initial program 92.8%
Taylor expanded in b around inf 39.6%
Taylor expanded in y around inf 35.9%
*-commutative35.9%
Simplified35.9%
if -4.2e18 < y < 2.30000000000000008e138Initial program 98.2%
Taylor expanded in x around inf 22.2%
Final simplification26.6%
(FPCore (x y z t a b) :precision binary64 (if (<= z -5.5e+154) z (if (<= z 2.1e+48) x z)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -5.5e+154) {
tmp = z;
} else if (z <= 2.1e+48) {
tmp = x;
} else {
tmp = z;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (z <= (-5.5d+154)) then
tmp = z
else if (z <= 2.1d+48) then
tmp = x
else
tmp = z
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -5.5e+154) {
tmp = z;
} else if (z <= 2.1e+48) {
tmp = x;
} else {
tmp = z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -5.5e+154: tmp = z elif z <= 2.1e+48: tmp = x else: tmp = z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -5.5e+154) tmp = z; elseif (z <= 2.1e+48) tmp = x; else tmp = z; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -5.5e+154) tmp = z; elseif (z <= 2.1e+48) tmp = x; else tmp = z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -5.5e+154], z, If[LessEqual[z, 2.1e+48], x, z]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.5 \cdot 10^{+154}:\\
\;\;\;\;z\\
\mathbf{elif}\;z \leq 2.1 \cdot 10^{+48}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;z\\
\end{array}
\end{array}
if z < -5.5000000000000006e154 or 2.0999999999999998e48 < z Initial program 95.9%
Taylor expanded in z around inf 64.6%
Taylor expanded in y around 0 32.1%
if -5.5000000000000006e154 < z < 2.0999999999999998e48Initial program 96.7%
Taylor expanded in x around inf 23.6%
(FPCore (x y z t a b) :precision binary64 x)
double code(double x, double y, double z, double t, double a, double b) {
return x;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x;
}
def code(x, y, z, t, a, b): return x
function code(x, y, z, t, a, b) return x end
function tmp = code(x, y, z, t, a, b) tmp = x; end
code[x_, y_, z_, t_, a_, b_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 96.5%
Taylor expanded in x around inf 18.4%
herbie shell --seed 2024170
(FPCore (x y z t a b)
:name "Statistics.Distribution.Beta:$centropy from math-functions-0.1.5.2"
:precision binary64
(+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))