
(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 24 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 (* z (- 1.0 y))) (* a (- 1.0 t))) (* b (- (+ y t) 2.0)))))
(if (<= t_1 INFINITY) t_1 (* y (- b z)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = y * (b - z);
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = y * (b - z);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0)) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = y * (b - z) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x + Float64(z * Float64(1.0 - y))) + 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(y * Float64(b - z)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0)); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = y * (b - z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x + N[(z * N[(1.0 - y), $MachinePrecision]), $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[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(x + z \cdot \left(1 - y\right)\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}:\\
\;\;\;\;y \cdot \left(b - z\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 y around inf 62.0%
Final simplification98.1%
(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 94.9%
+-commutative94.9%
fma-define97.7%
associate--l+97.7%
sub-neg97.7%
metadata-eval97.7%
sub-neg97.7%
associate-+l-97.7%
fmm-def97.7%
sub-neg97.7%
metadata-eval97.7%
remove-double-neg97.7%
sub-neg97.7%
metadata-eval97.7%
Simplified97.7%
Final simplification97.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* b (- (+ y t) 2.0))))
(if (<= b -3.7e+102)
t_1
(if (<= b 2.3e-228)
(+ x (* a (- 1.0 t)))
(if (<= b 1.26e-169)
(* z (- 1.0 y))
(if (<= b 3.8e+32) (+ a (+ x z)) t_1))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = b * ((y + t) - 2.0);
double tmp;
if (b <= -3.7e+102) {
tmp = t_1;
} else if (b <= 2.3e-228) {
tmp = x + (a * (1.0 - t));
} else if (b <= 1.26e-169) {
tmp = z * (1.0 - y);
} else if (b <= 3.8e+32) {
tmp = a + (x + z);
} 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 = b * ((y + t) - 2.0d0)
if (b <= (-3.7d+102)) then
tmp = t_1
else if (b <= 2.3d-228) then
tmp = x + (a * (1.0d0 - t))
else if (b <= 1.26d-169) then
tmp = z * (1.0d0 - y)
else if (b <= 3.8d+32) then
tmp = a + (x + z)
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 = b * ((y + t) - 2.0);
double tmp;
if (b <= -3.7e+102) {
tmp = t_1;
} else if (b <= 2.3e-228) {
tmp = x + (a * (1.0 - t));
} else if (b <= 1.26e-169) {
tmp = z * (1.0 - y);
} else if (b <= 3.8e+32) {
tmp = a + (x + z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = b * ((y + t) - 2.0) tmp = 0 if b <= -3.7e+102: tmp = t_1 elif b <= 2.3e-228: tmp = x + (a * (1.0 - t)) elif b <= 1.26e-169: tmp = z * (1.0 - y) elif b <= 3.8e+32: tmp = a + (x + z) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(b * Float64(Float64(y + t) - 2.0)) tmp = 0.0 if (b <= -3.7e+102) tmp = t_1; elseif (b <= 2.3e-228) tmp = Float64(x + Float64(a * Float64(1.0 - t))); elseif (b <= 1.26e-169) tmp = Float64(z * Float64(1.0 - y)); elseif (b <= 3.8e+32) tmp = Float64(a + Float64(x + z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = b * ((y + t) - 2.0); tmp = 0.0; if (b <= -3.7e+102) tmp = t_1; elseif (b <= 2.3e-228) tmp = x + (a * (1.0 - t)); elseif (b <= 1.26e-169) tmp = z * (1.0 - y); elseif (b <= 3.8e+32) tmp = a + (x + z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -3.7e+102], t$95$1, If[LessEqual[b, 2.3e-228], N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.26e-169], N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3.8e+32], N[(a + N[(x + z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{if}\;b \leq -3.7 \cdot 10^{+102}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 2.3 \cdot 10^{-228}:\\
\;\;\;\;x + a \cdot \left(1 - t\right)\\
\mathbf{elif}\;b \leq 1.26 \cdot 10^{-169}:\\
\;\;\;\;z \cdot \left(1 - y\right)\\
\mathbf{elif}\;b \leq 3.8 \cdot 10^{+32}:\\
\;\;\;\;a + \left(x + z\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -3.70000000000000023e102 or 3.8000000000000003e32 < b Initial program 87.0%
Taylor expanded in b around inf 76.2%
if -3.70000000000000023e102 < b < 2.2999999999999999e-228Initial program 99.0%
Taylor expanded in b around 0 89.4%
Taylor expanded in a around inf 54.3%
if 2.2999999999999999e-228 < b < 1.26e-169Initial program 100.0%
Taylor expanded in z around inf 73.6%
if 1.26e-169 < b < 3.8000000000000003e32Initial program 100.0%
Taylor expanded in b around 0 81.6%
Taylor expanded in y around 0 66.9%
+-commutative66.9%
sub-neg66.9%
metadata-eval66.9%
neg-mul-166.9%
unsub-neg66.9%
Simplified66.9%
Taylor expanded in t around 0 53.9%
neg-mul-153.9%
sub-neg53.9%
remove-double-neg53.9%
+-commutative53.9%
Simplified53.9%
Final simplification63.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ a (+ x z))) (t_2 (* y (- b z))))
(if (<= y -7e+92)
t_2
(if (<= y 1.05e-182)
t_1
(if (<= y 5e-90) (* t (- b a)) (if (<= y 135000000000.0) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = a + (x + z);
double t_2 = y * (b - z);
double tmp;
if (y <= -7e+92) {
tmp = t_2;
} else if (y <= 1.05e-182) {
tmp = t_1;
} else if (y <= 5e-90) {
tmp = t * (b - a);
} else if (y <= 135000000000.0) {
tmp = t_1;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = a + (x + z)
t_2 = y * (b - z)
if (y <= (-7d+92)) then
tmp = t_2
else if (y <= 1.05d-182) then
tmp = t_1
else if (y <= 5d-90) then
tmp = t * (b - a)
else if (y <= 135000000000.0d0) 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 a, double b) {
double t_1 = a + (x + z);
double t_2 = y * (b - z);
double tmp;
if (y <= -7e+92) {
tmp = t_2;
} else if (y <= 1.05e-182) {
tmp = t_1;
} else if (y <= 5e-90) {
tmp = t * (b - a);
} else if (y <= 135000000000.0) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = a + (x + z) t_2 = y * (b - z) tmp = 0 if y <= -7e+92: tmp = t_2 elif y <= 1.05e-182: tmp = t_1 elif y <= 5e-90: tmp = t * (b - a) elif y <= 135000000000.0: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(a + Float64(x + z)) t_2 = Float64(y * Float64(b - z)) tmp = 0.0 if (y <= -7e+92) tmp = t_2; elseif (y <= 1.05e-182) tmp = t_1; elseif (y <= 5e-90) tmp = Float64(t * Float64(b - a)); elseif (y <= 135000000000.0) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = a + (x + z); t_2 = y * (b - z); tmp = 0.0; if (y <= -7e+92) tmp = t_2; elseif (y <= 1.05e-182) tmp = t_1; elseif (y <= 5e-90) tmp = t * (b - a); elseif (y <= 135000000000.0) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a + N[(x + z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -7e+92], t$95$2, If[LessEqual[y, 1.05e-182], t$95$1, If[LessEqual[y, 5e-90], N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 135000000000.0], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a + \left(x + z\right)\\
t_2 := y \cdot \left(b - z\right)\\
\mathbf{if}\;y \leq -7 \cdot 10^{+92}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 1.05 \cdot 10^{-182}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 5 \cdot 10^{-90}:\\
\;\;\;\;t \cdot \left(b - a\right)\\
\mathbf{elif}\;y \leq 135000000000:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -6.99999999999999972e92 or 1.35e11 < y Initial program 92.2%
Taylor expanded in y around inf 72.8%
if -6.99999999999999972e92 < y < 1.05e-182 or 5.00000000000000019e-90 < y < 1.35e11Initial program 97.7%
Taylor expanded in b around 0 70.2%
Taylor expanded in y around 0 67.7%
+-commutative67.7%
sub-neg67.7%
metadata-eval67.7%
neg-mul-167.7%
unsub-neg67.7%
Simplified67.7%
Taylor expanded in t around 0 52.0%
neg-mul-152.0%
sub-neg52.0%
remove-double-neg52.0%
+-commutative52.0%
Simplified52.0%
if 1.05e-182 < y < 5.00000000000000019e-90Initial program 92.0%
Taylor expanded in t around inf 61.2%
Final simplification61.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* t (- b a))) (t_2 (* y (- b z))))
(if (<= y -6.3e+92)
t_2
(if (<= y -5.2e-290)
t_1
(if (<= y 6.2e-183) (+ x z) (if (<= y 3.3e+44) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = t * (b - a);
double t_2 = y * (b - z);
double tmp;
if (y <= -6.3e+92) {
tmp = t_2;
} else if (y <= -5.2e-290) {
tmp = t_1;
} else if (y <= 6.2e-183) {
tmp = x + z;
} else if (y <= 3.3e+44) {
tmp = t_1;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = t * (b - a)
t_2 = y * (b - z)
if (y <= (-6.3d+92)) then
tmp = t_2
else if (y <= (-5.2d-290)) then
tmp = t_1
else if (y <= 6.2d-183) then
tmp = x + z
else if (y <= 3.3d+44) 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 a, double b) {
double t_1 = t * (b - a);
double t_2 = y * (b - z);
double tmp;
if (y <= -6.3e+92) {
tmp = t_2;
} else if (y <= -5.2e-290) {
tmp = t_1;
} else if (y <= 6.2e-183) {
tmp = x + z;
} else if (y <= 3.3e+44) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = t * (b - a) t_2 = y * (b - z) tmp = 0 if y <= -6.3e+92: tmp = t_2 elif y <= -5.2e-290: tmp = t_1 elif y <= 6.2e-183: tmp = x + z elif y <= 3.3e+44: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(t * Float64(b - a)) t_2 = Float64(y * Float64(b - z)) tmp = 0.0 if (y <= -6.3e+92) tmp = t_2; elseif (y <= -5.2e-290) tmp = t_1; elseif (y <= 6.2e-183) tmp = Float64(x + z); elseif (y <= 3.3e+44) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = t * (b - a); t_2 = y * (b - z); tmp = 0.0; if (y <= -6.3e+92) tmp = t_2; elseif (y <= -5.2e-290) tmp = t_1; elseif (y <= 6.2e-183) tmp = x + z; elseif (y <= 3.3e+44) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.3e+92], t$95$2, If[LessEqual[y, -5.2e-290], t$95$1, If[LessEqual[y, 6.2e-183], N[(x + z), $MachinePrecision], If[LessEqual[y, 3.3e+44], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \left(b - a\right)\\
t_2 := y \cdot \left(b - z\right)\\
\mathbf{if}\;y \leq -6.3 \cdot 10^{+92}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -5.2 \cdot 10^{-290}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 6.2 \cdot 10^{-183}:\\
\;\;\;\;x + z\\
\mathbf{elif}\;y \leq 3.3 \cdot 10^{+44}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -6.2999999999999999e92 or 3.30000000000000013e44 < y Initial program 91.7%
Taylor expanded in y around inf 75.2%
if -6.2999999999999999e92 < y < -5.20000000000000002e-290 or 6.19999999999999999e-183 < y < 3.30000000000000013e44Initial program 96.0%
Taylor expanded in t around inf 43.3%
if -5.20000000000000002e-290 < y < 6.19999999999999999e-183Initial program 100.0%
Taylor expanded in b around 0 74.9%
Taylor expanded in y around 0 74.9%
+-commutative74.9%
sub-neg74.9%
metadata-eval74.9%
neg-mul-174.9%
unsub-neg74.9%
Simplified74.9%
Taylor expanded in a around 0 57.4%
+-commutative57.4%
Simplified57.4%
Final simplification57.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* a (- 1.0 t))))
(if (<= a -5.8e+45)
t_1
(if (<= a -6.5e-102)
(+ x z)
(if (<= a -2.1e-288)
(* b (- t 2.0))
(if (<= a 2.05e+92) (+ x z) 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 (a <= -5.8e+45) {
tmp = t_1;
} else if (a <= -6.5e-102) {
tmp = x + z;
} else if (a <= -2.1e-288) {
tmp = b * (t - 2.0);
} else if (a <= 2.05e+92) {
tmp = x + z;
} 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 = a * (1.0d0 - t)
if (a <= (-5.8d+45)) then
tmp = t_1
else if (a <= (-6.5d-102)) then
tmp = x + z
else if (a <= (-2.1d-288)) then
tmp = b * (t - 2.0d0)
else if (a <= 2.05d+92) then
tmp = x + z
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 = a * (1.0 - t);
double tmp;
if (a <= -5.8e+45) {
tmp = t_1;
} else if (a <= -6.5e-102) {
tmp = x + z;
} else if (a <= -2.1e-288) {
tmp = b * (t - 2.0);
} else if (a <= 2.05e+92) {
tmp = x + z;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = a * (1.0 - t) tmp = 0 if a <= -5.8e+45: tmp = t_1 elif a <= -6.5e-102: tmp = x + z elif a <= -2.1e-288: tmp = b * (t - 2.0) elif a <= 2.05e+92: tmp = x + z else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(a * Float64(1.0 - t)) tmp = 0.0 if (a <= -5.8e+45) tmp = t_1; elseif (a <= -6.5e-102) tmp = Float64(x + z); elseif (a <= -2.1e-288) tmp = Float64(b * Float64(t - 2.0)); elseif (a <= 2.05e+92) tmp = Float64(x + z); else tmp = 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 (a <= -5.8e+45) tmp = t_1; elseif (a <= -6.5e-102) tmp = x + z; elseif (a <= -2.1e-288) tmp = b * (t - 2.0); elseif (a <= 2.05e+92) tmp = x + z; else tmp = 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[LessEqual[a, -5.8e+45], t$95$1, If[LessEqual[a, -6.5e-102], N[(x + z), $MachinePrecision], If[LessEqual[a, -2.1e-288], N[(b * N[(t - 2.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.05e+92], N[(x + z), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
\mathbf{if}\;a \leq -5.8 \cdot 10^{+45}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -6.5 \cdot 10^{-102}:\\
\;\;\;\;x + z\\
\mathbf{elif}\;a \leq -2.1 \cdot 10^{-288}:\\
\;\;\;\;b \cdot \left(t - 2\right)\\
\mathbf{elif}\;a \leq 2.05 \cdot 10^{+92}:\\
\;\;\;\;x + z\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -5.7999999999999994e45 or 2.05000000000000012e92 < a Initial program 91.8%
Taylor expanded in a around inf 65.0%
if -5.7999999999999994e45 < a < -6.5000000000000003e-102 or -2.09999999999999996e-288 < a < 2.05000000000000012e92Initial program 96.7%
Taylor expanded in b around 0 65.7%
Taylor expanded in y around 0 44.6%
+-commutative44.6%
sub-neg44.6%
metadata-eval44.6%
neg-mul-144.6%
unsub-neg44.6%
Simplified44.6%
Taylor expanded in a around 0 38.7%
+-commutative38.7%
Simplified38.7%
if -6.5000000000000003e-102 < a < -2.09999999999999996e-288Initial program 97.4%
Taylor expanded in b around inf 61.5%
Taylor expanded in y around 0 43.0%
Final simplification49.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= a -1.45e+47) (not (<= a 1.96e+74))) (- x (+ (* a (+ t -1.0)) (* z (+ y -1.0)))) (+ (+ x (* b (- (+ y t) 2.0))) (* z (- 1.0 y)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((a <= -1.45e+47) || !(a <= 1.96e+74)) {
tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0)));
} else {
tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y));
}
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 ((a <= (-1.45d+47)) .or. (.not. (a <= 1.96d+74))) then
tmp = x - ((a * (t + (-1.0d0))) + (z * (y + (-1.0d0))))
else
tmp = (x + (b * ((y + t) - 2.0d0))) + (z * (1.0d0 - y))
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 ((a <= -1.45e+47) || !(a <= 1.96e+74)) {
tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0)));
} else {
tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (a <= -1.45e+47) or not (a <= 1.96e+74): tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0))) else: tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((a <= -1.45e+47) || !(a <= 1.96e+74)) tmp = Float64(x - Float64(Float64(a * Float64(t + -1.0)) + Float64(z * Float64(y + -1.0)))); else tmp = Float64(Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))) + Float64(z * Float64(1.0 - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((a <= -1.45e+47) || ~((a <= 1.96e+74))) tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0))); else tmp = (x + (b * ((y + t) - 2.0))) + (z * (1.0 - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[a, -1.45e+47], N[Not[LessEqual[a, 1.96e+74]], $MachinePrecision]], N[(x - N[(N[(a * N[(t + -1.0), $MachinePrecision]), $MachinePrecision] + N[(z * N[(y + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.45 \cdot 10^{+47} \lor \neg \left(a \leq 1.96 \cdot 10^{+74}\right):\\
\;\;\;\;x - \left(a \cdot \left(t + -1\right) + z \cdot \left(y + -1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + b \cdot \left(\left(y + t\right) - 2\right)\right) + z \cdot \left(1 - y\right)\\
\end{array}
\end{array}
if a < -1.4499999999999999e47 or 1.96e74 < a Initial program 92.2%
Taylor expanded in b around 0 85.1%
if -1.4499999999999999e47 < a < 1.96e74Initial program 96.8%
Taylor expanded in a around 0 92.0%
Final simplification89.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -6.2e+59)
(- x (+ (* a (+ t -1.0)) (* z (+ y -1.0))))
(if (<= z 1.2e+80)
(+ (+ x (* b (- (+ y t) 2.0))) (* a (- 1.0 t)))
(+ (+ x (* t b)) (* z (- 1.0 y))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -6.2e+59) {
tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0)));
} else if (z <= 1.2e+80) {
tmp = (x + (b * ((y + t) - 2.0))) + (a * (1.0 - t));
} else {
tmp = (x + (t * b)) + (z * (1.0 - y));
}
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 <= (-6.2d+59)) then
tmp = x - ((a * (t + (-1.0d0))) + (z * (y + (-1.0d0))))
else if (z <= 1.2d+80) then
tmp = (x + (b * ((y + t) - 2.0d0))) + (a * (1.0d0 - t))
else
tmp = (x + (t * b)) + (z * (1.0d0 - y))
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 <= -6.2e+59) {
tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0)));
} else if (z <= 1.2e+80) {
tmp = (x + (b * ((y + t) - 2.0))) + (a * (1.0 - t));
} else {
tmp = (x + (t * b)) + (z * (1.0 - y));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -6.2e+59: tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0))) elif z <= 1.2e+80: tmp = (x + (b * ((y + t) - 2.0))) + (a * (1.0 - t)) else: tmp = (x + (t * b)) + (z * (1.0 - y)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -6.2e+59) tmp = Float64(x - Float64(Float64(a * Float64(t + -1.0)) + Float64(z * Float64(y + -1.0)))); elseif (z <= 1.2e+80) tmp = Float64(Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))) + Float64(a * Float64(1.0 - t))); else tmp = Float64(Float64(x + Float64(t * b)) + Float64(z * Float64(1.0 - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -6.2e+59) tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0))); elseif (z <= 1.2e+80) tmp = (x + (b * ((y + t) - 2.0))) + (a * (1.0 - t)); else tmp = (x + (t * b)) + (z * (1.0 - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -6.2e+59], N[(x - N[(N[(a * N[(t + -1.0), $MachinePrecision]), $MachinePrecision] + N[(z * N[(y + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.2e+80], N[(N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + N[(t * b), $MachinePrecision]), $MachinePrecision] + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.2 \cdot 10^{+59}:\\
\;\;\;\;x - \left(a \cdot \left(t + -1\right) + z \cdot \left(y + -1\right)\right)\\
\mathbf{elif}\;z \leq 1.2 \cdot 10^{+80}:\\
\;\;\;\;\left(x + b \cdot \left(\left(y + t\right) - 2\right)\right) + a \cdot \left(1 - t\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + t \cdot b\right) + z \cdot \left(1 - y\right)\\
\end{array}
\end{array}
if z < -6.20000000000000029e59Initial program 89.1%
Taylor expanded in b around 0 78.6%
if -6.20000000000000029e59 < z < 1.1999999999999999e80Initial program 100.0%
Taylor expanded in z around 0 91.9%
if 1.1999999999999999e80 < z Initial program 89.3%
Taylor expanded in a around 0 83.7%
Taylor expanded in t around inf 87.2%
Final simplification87.5%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* y (- b z))))
(if (<= y -7.2e+92)
t_1
(if (<= y -2.4e-137)
(+ x (+ z (* a (- 1.0 t))))
(if (<= y 4e+17) (+ x (+ z (* (+ t -2.0) b))) 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.2e+92) {
tmp = t_1;
} else if (y <= -2.4e-137) {
tmp = x + (z + (a * (1.0 - t)));
} else if (y <= 4e+17) {
tmp = x + (z + ((t + -2.0) * b));
} 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.2d+92)) then
tmp = t_1
else if (y <= (-2.4d-137)) then
tmp = x + (z + (a * (1.0d0 - t)))
else if (y <= 4d+17) then
tmp = x + (z + ((t + (-2.0d0)) * b))
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.2e+92) {
tmp = t_1;
} else if (y <= -2.4e-137) {
tmp = x + (z + (a * (1.0 - t)));
} else if (y <= 4e+17) {
tmp = x + (z + ((t + -2.0) * b));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = y * (b - z) tmp = 0 if y <= -7.2e+92: tmp = t_1 elif y <= -2.4e-137: tmp = x + (z + (a * (1.0 - t))) elif y <= 4e+17: tmp = x + (z + ((t + -2.0) * b)) 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.2e+92) tmp = t_1; elseif (y <= -2.4e-137) tmp = Float64(x + Float64(z + Float64(a * Float64(1.0 - t)))); elseif (y <= 4e+17) tmp = Float64(x + Float64(z + Float64(Float64(t + -2.0) * b))); 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.2e+92) tmp = t_1; elseif (y <= -2.4e-137) tmp = x + (z + (a * (1.0 - t))); elseif (y <= 4e+17) tmp = x + (z + ((t + -2.0) * b)); 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.2e+92], t$95$1, If[LessEqual[y, -2.4e-137], N[(x + N[(z + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4e+17], N[(x + N[(z + N[(N[(t + -2.0), $MachinePrecision] * b), $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.2 \cdot 10^{+92}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -2.4 \cdot 10^{-137}:\\
\;\;\;\;x + \left(z + a \cdot \left(1 - t\right)\right)\\
\mathbf{elif}\;y \leq 4 \cdot 10^{+17}:\\
\;\;\;\;x + \left(z + \left(t + -2\right) \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -7.2e92 or 4e17 < y Initial program 92.1%
Taylor expanded in y around inf 73.5%
if -7.2e92 < y < -2.4e-137Initial program 97.7%
Taylor expanded in b around 0 75.1%
Taylor expanded in y around 0 71.0%
+-commutative71.0%
sub-neg71.0%
metadata-eval71.0%
neg-mul-171.0%
unsub-neg71.0%
Simplified71.0%
if -2.4e-137 < y < 4e17Initial program 96.4%
Taylor expanded in a around 0 77.1%
Taylor expanded in y around 0 75.4%
associate--l+75.4%
sub-neg75.4%
metadata-eval75.4%
neg-mul-175.4%
Simplified75.4%
Final simplification73.9%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ x (* b (- (+ y t) 2.0)))))
(if (<= b -3.9e-25)
t_1
(if (<= b -8e-167)
(- x (- (* t a) z))
(if (<= b 1.4e+54) (+ x (* z (- 1.0 y))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + (b * ((y + t) - 2.0));
double tmp;
if (b <= -3.9e-25) {
tmp = t_1;
} else if (b <= -8e-167) {
tmp = x - ((t * a) - z);
} else if (b <= 1.4e+54) {
tmp = x + (z * (1.0 - y));
} 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 + (b * ((y + t) - 2.0d0))
if (b <= (-3.9d-25)) then
tmp = t_1
else if (b <= (-8d-167)) then
tmp = x - ((t * a) - z)
else if (b <= 1.4d+54) then
tmp = x + (z * (1.0d0 - y))
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 + (b * ((y + t) - 2.0));
double tmp;
if (b <= -3.9e-25) {
tmp = t_1;
} else if (b <= -8e-167) {
tmp = x - ((t * a) - z);
} else if (b <= 1.4e+54) {
tmp = x + (z * (1.0 - y));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (b * ((y + t) - 2.0)) tmp = 0 if b <= -3.9e-25: tmp = t_1 elif b <= -8e-167: tmp = x - ((t * a) - z) elif b <= 1.4e+54: tmp = x + (z * (1.0 - y)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))) tmp = 0.0 if (b <= -3.9e-25) tmp = t_1; elseif (b <= -8e-167) tmp = Float64(x - Float64(Float64(t * a) - z)); elseif (b <= 1.4e+54) tmp = Float64(x + Float64(z * Float64(1.0 - y))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x + (b * ((y + t) - 2.0)); tmp = 0.0; if (b <= -3.9e-25) tmp = t_1; elseif (b <= -8e-167) tmp = x - ((t * a) - z); elseif (b <= 1.4e+54) tmp = x + (z * (1.0 - y)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -3.9e-25], t$95$1, If[LessEqual[b, -8e-167], N[(x - N[(N[(t * a), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.4e+54], N[(x + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{if}\;b \leq -3.9 \cdot 10^{-25}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq -8 \cdot 10^{-167}:\\
\;\;\;\;x - \left(t \cdot a - z\right)\\
\mathbf{elif}\;b \leq 1.4 \cdot 10^{+54}:\\
\;\;\;\;x + z \cdot \left(1 - y\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -3.9e-25 or 1.40000000000000008e54 < b Initial program 89.2%
Taylor expanded in a around 0 80.2%
Taylor expanded in z around 0 69.8%
if -3.9e-25 < b < -8.00000000000000002e-167Initial program 100.0%
Taylor expanded in b around 0 96.3%
Taylor expanded in y around 0 84.3%
+-commutative84.3%
sub-neg84.3%
metadata-eval84.3%
neg-mul-184.3%
unsub-neg84.3%
Simplified84.3%
Taylor expanded in t around inf 76.2%
*-commutative76.2%
Simplified76.2%
if -8.00000000000000002e-167 < b < 1.40000000000000008e54Initial program 100.0%
Taylor expanded in a around 0 68.0%
Taylor expanded in b around 0 60.8%
Final simplification66.5%
(FPCore (x y z t a b)
:precision binary64
(if (<= t -8.2e+43)
(* t b)
(if (<= t -8e-219)
(* y b)
(if (<= t 7.8e-100) a (if (<= t 2.1e+70) z (* t b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -8.2e+43) {
tmp = t * b;
} else if (t <= -8e-219) {
tmp = y * b;
} else if (t <= 7.8e-100) {
tmp = a;
} else if (t <= 2.1e+70) {
tmp = z;
} else {
tmp = t * b;
}
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 <= (-8.2d+43)) then
tmp = t * b
else if (t <= (-8d-219)) then
tmp = y * b
else if (t <= 7.8d-100) then
tmp = a
else if (t <= 2.1d+70) then
tmp = z
else
tmp = t * b
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 <= -8.2e+43) {
tmp = t * b;
} else if (t <= -8e-219) {
tmp = y * b;
} else if (t <= 7.8e-100) {
tmp = a;
} else if (t <= 2.1e+70) {
tmp = z;
} else {
tmp = t * b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -8.2e+43: tmp = t * b elif t <= -8e-219: tmp = y * b elif t <= 7.8e-100: tmp = a elif t <= 2.1e+70: tmp = z else: tmp = t * b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -8.2e+43) tmp = Float64(t * b); elseif (t <= -8e-219) tmp = Float64(y * b); elseif (t <= 7.8e-100) tmp = a; elseif (t <= 2.1e+70) tmp = z; else tmp = Float64(t * b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -8.2e+43) tmp = t * b; elseif (t <= -8e-219) tmp = y * b; elseif (t <= 7.8e-100) tmp = a; elseif (t <= 2.1e+70) tmp = z; else tmp = t * b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -8.2e+43], N[(t * b), $MachinePrecision], If[LessEqual[t, -8e-219], N[(y * b), $MachinePrecision], If[LessEqual[t, 7.8e-100], a, If[LessEqual[t, 2.1e+70], z, N[(t * b), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.2 \cdot 10^{+43}:\\
\;\;\;\;t \cdot b\\
\mathbf{elif}\;t \leq -8 \cdot 10^{-219}:\\
\;\;\;\;y \cdot b\\
\mathbf{elif}\;t \leq 7.8 \cdot 10^{-100}:\\
\;\;\;\;a\\
\mathbf{elif}\;t \leq 2.1 \cdot 10^{+70}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;t \cdot b\\
\end{array}
\end{array}
if t < -8.2000000000000001e43 or 2.10000000000000008e70 < t Initial program 92.9%
Taylor expanded in t around inf 68.2%
Taylor expanded in b around inf 37.9%
if -8.2000000000000001e43 < t < -8.0000000000000003e-219Initial program 98.0%
Taylor expanded in a around 0 84.8%
Taylor expanded in z around 0 53.0%
Taylor expanded in y around inf 21.2%
*-commutative34.4%
Simplified21.2%
if -8.0000000000000003e-219 < t < 7.79999999999999955e-100Initial program 96.6%
Taylor expanded in a around inf 30.9%
Taylor expanded in t around 0 30.9%
if 7.79999999999999955e-100 < t < 2.10000000000000008e70Initial program 94.3%
Taylor expanded in z around inf 54.3%
Taylor expanded in y around 0 34.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -5.5e+121) (not (<= b 5.5e+114))) (+ x (* b (- (+ y t) 2.0))) (- x (+ (* a (+ t -1.0)) (* z (+ y -1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -5.5e+121) || !(b <= 5.5e+114)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0)));
}
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 <= (-5.5d+121)) .or. (.not. (b <= 5.5d+114))) then
tmp = x + (b * ((y + t) - 2.0d0))
else
tmp = x - ((a * (t + (-1.0d0))) + (z * (y + (-1.0d0))))
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 <= -5.5e+121) || !(b <= 5.5e+114)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -5.5e+121) or not (b <= 5.5e+114): tmp = x + (b * ((y + t) - 2.0)) else: tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -5.5e+121) || !(b <= 5.5e+114)) tmp = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))); else tmp = Float64(x - Float64(Float64(a * Float64(t + -1.0)) + Float64(z * Float64(y + -1.0)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -5.5e+121) || ~((b <= 5.5e+114))) tmp = x + (b * ((y + t) - 2.0)); else tmp = x - ((a * (t + -1.0)) + (z * (y + -1.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -5.5e+121], N[Not[LessEqual[b, 5.5e+114]], $MachinePrecision]], N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(N[(a * N[(t + -1.0), $MachinePrecision]), $MachinePrecision] + N[(z * N[(y + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -5.5 \cdot 10^{+121} \lor \neg \left(b \leq 5.5 \cdot 10^{+114}\right):\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;x - \left(a \cdot \left(t + -1\right) + z \cdot \left(y + -1\right)\right)\\
\end{array}
\end{array}
if b < -5.4999999999999998e121 or 5.5000000000000001e114 < b Initial program 88.8%
Taylor expanded in a around 0 84.9%
Taylor expanded in z around 0 82.9%
if -5.4999999999999998e121 < b < 5.5000000000000001e114Initial program 97.7%
Taylor expanded in b around 0 86.4%
Final simplification85.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* a (- 1.0 t))))
(if (<= a -1.9e+106)
(+ (* y b) t_1)
(if (<= a 1.27e+73) (+ (+ x (* t b)) (* z (- 1.0 y))) (+ x (+ z 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 (a <= -1.9e+106) {
tmp = (y * b) + t_1;
} else if (a <= 1.27e+73) {
tmp = (x + (t * b)) + (z * (1.0 - y));
} else {
tmp = x + (z + 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 (a <= (-1.9d+106)) then
tmp = (y * b) + t_1
else if (a <= 1.27d+73) then
tmp = (x + (t * b)) + (z * (1.0d0 - y))
else
tmp = x + (z + 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 (a <= -1.9e+106) {
tmp = (y * b) + t_1;
} else if (a <= 1.27e+73) {
tmp = (x + (t * b)) + (z * (1.0 - y));
} else {
tmp = x + (z + t_1);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = a * (1.0 - t) tmp = 0 if a <= -1.9e+106: tmp = (y * b) + t_1 elif a <= 1.27e+73: tmp = (x + (t * b)) + (z * (1.0 - y)) else: tmp = x + (z + t_1) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(a * Float64(1.0 - t)) tmp = 0.0 if (a <= -1.9e+106) tmp = Float64(Float64(y * b) + t_1); elseif (a <= 1.27e+73) tmp = Float64(Float64(x + Float64(t * b)) + Float64(z * Float64(1.0 - y))); else tmp = Float64(x + Float64(z + 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 (a <= -1.9e+106) tmp = (y * b) + t_1; elseif (a <= 1.27e+73) tmp = (x + (t * b)) + (z * (1.0 - y)); else tmp = x + (z + 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[LessEqual[a, -1.9e+106], N[(N[(y * b), $MachinePrecision] + t$95$1), $MachinePrecision], If[LessEqual[a, 1.27e+73], N[(N[(x + N[(t * b), $MachinePrecision]), $MachinePrecision] + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
\mathbf{if}\;a \leq -1.9 \cdot 10^{+106}:\\
\;\;\;\;y \cdot b + t\_1\\
\mathbf{elif}\;a \leq 1.27 \cdot 10^{+73}:\\
\;\;\;\;\left(x + t \cdot b\right) + z \cdot \left(1 - y\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(z + t\_1\right)\\
\end{array}
\end{array}
if a < -1.8999999999999999e106Initial program 89.4%
Taylor expanded in z around 0 78.9%
Taylor expanded in y around inf 73.0%
*-commutative73.0%
Simplified73.0%
if -1.8999999999999999e106 < a < 1.2700000000000001e73Initial program 96.8%
Taylor expanded in a around 0 90.9%
Taylor expanded in t around inf 73.9%
if 1.2700000000000001e73 < a Initial program 94.2%
Taylor expanded in b around 0 87.1%
Taylor expanded in y around 0 77.9%
+-commutative77.9%
sub-neg77.9%
metadata-eval77.9%
neg-mul-177.9%
unsub-neg77.9%
Simplified77.9%
Final simplification74.5%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* t (- b a))))
(if (<= t -17000000000000.0)
t_1
(if (<= t 5.5e-88) (* b (- y 2.0)) (if (<= t 2.05e+17) (+ x z) 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 <= -17000000000000.0) {
tmp = t_1;
} else if (t <= 5.5e-88) {
tmp = b * (y - 2.0);
} else if (t <= 2.05e+17) {
tmp = x + z;
} 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 <= (-17000000000000.0d0)) then
tmp = t_1
else if (t <= 5.5d-88) then
tmp = b * (y - 2.0d0)
else if (t <= 2.05d+17) then
tmp = x + z
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 <= -17000000000000.0) {
tmp = t_1;
} else if (t <= 5.5e-88) {
tmp = b * (y - 2.0);
} else if (t <= 2.05e+17) {
tmp = x + z;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = t * (b - a) tmp = 0 if t <= -17000000000000.0: tmp = t_1 elif t <= 5.5e-88: tmp = b * (y - 2.0) elif t <= 2.05e+17: tmp = x + z 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 <= -17000000000000.0) tmp = t_1; elseif (t <= 5.5e-88) tmp = Float64(b * Float64(y - 2.0)); elseif (t <= 2.05e+17) tmp = Float64(x + z); 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 <= -17000000000000.0) tmp = t_1; elseif (t <= 5.5e-88) tmp = b * (y - 2.0); elseif (t <= 2.05e+17) tmp = x + z; 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, -17000000000000.0], t$95$1, If[LessEqual[t, 5.5e-88], N[(b * N[(y - 2.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.05e+17], N[(x + z), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \left(b - a\right)\\
\mathbf{if}\;t \leq -17000000000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 5.5 \cdot 10^{-88}:\\
\;\;\;\;b \cdot \left(y - 2\right)\\
\mathbf{elif}\;t \leq 2.05 \cdot 10^{+17}:\\
\;\;\;\;x + z\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -1.7e13 or 2.05e17 < t Initial program 93.9%
Taylor expanded in t around inf 64.7%
if -1.7e13 < t < 5.49999999999999971e-88Initial program 96.2%
Taylor expanded in b around inf 33.8%
Taylor expanded in t around 0 33.5%
if 5.49999999999999971e-88 < t < 2.05e17Initial program 95.2%
Taylor expanded in b around 0 88.5%
Taylor expanded in y around 0 61.8%
+-commutative61.8%
sub-neg61.8%
metadata-eval61.8%
neg-mul-161.8%
unsub-neg61.8%
Simplified61.8%
Taylor expanded in a around 0 52.7%
+-commutative52.7%
Simplified52.7%
Final simplification51.0%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -4e+105) (not (<= b 6.4e+28))) (+ x (* b (- (+ y t) 2.0))) (+ x (+ z (* a (- 1.0 t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -4e+105) || !(b <= 6.4e+28)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = x + (z + (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 ((b <= (-4d+105)) .or. (.not. (b <= 6.4d+28))) then
tmp = x + (b * ((y + t) - 2.0d0))
else
tmp = x + (z + (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 ((b <= -4e+105) || !(b <= 6.4e+28)) {
tmp = x + (b * ((y + t) - 2.0));
} else {
tmp = x + (z + (a * (1.0 - t)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -4e+105) or not (b <= 6.4e+28): tmp = x + (b * ((y + t) - 2.0)) else: tmp = x + (z + (a * (1.0 - t))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -4e+105) || !(b <= 6.4e+28)) tmp = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0))); else tmp = Float64(x + Float64(z + Float64(a * Float64(1.0 - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -4e+105) || ~((b <= 6.4e+28))) tmp = x + (b * ((y + t) - 2.0)); else tmp = x + (z + (a * (1.0 - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -4e+105], N[Not[LessEqual[b, 6.4e+28]], $MachinePrecision]], N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(z + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -4 \cdot 10^{+105} \lor \neg \left(b \leq 6.4 \cdot 10^{+28}\right):\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(z + a \cdot \left(1 - t\right)\right)\\
\end{array}
\end{array}
if b < -3.9999999999999998e105 or 6.4000000000000001e28 < b Initial program 87.1%
Taylor expanded in a around 0 82.8%
Taylor expanded in z around 0 78.2%
if -3.9999999999999998e105 < b < 6.4000000000000001e28Initial program 99.4%
Taylor expanded in b around 0 88.1%
Taylor expanded in y around 0 65.1%
+-commutative65.1%
sub-neg65.1%
metadata-eval65.1%
neg-mul-165.1%
unsub-neg65.1%
Simplified65.1%
Final simplification69.9%
(FPCore (x y z t a b) :precision binary64 (if (<= t -2.2e-10) (* t b) (if (<= t 9e-100) a (if (<= t 2.25e+70) z (* t b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -2.2e-10) {
tmp = t * b;
} else if (t <= 9e-100) {
tmp = a;
} else if (t <= 2.25e+70) {
tmp = z;
} else {
tmp = t * b;
}
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 <= (-2.2d-10)) then
tmp = t * b
else if (t <= 9d-100) then
tmp = a
else if (t <= 2.25d+70) then
tmp = z
else
tmp = t * b
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 <= -2.2e-10) {
tmp = t * b;
} else if (t <= 9e-100) {
tmp = a;
} else if (t <= 2.25e+70) {
tmp = z;
} else {
tmp = t * b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -2.2e-10: tmp = t * b elif t <= 9e-100: tmp = a elif t <= 2.25e+70: tmp = z else: tmp = t * b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -2.2e-10) tmp = Float64(t * b); elseif (t <= 9e-100) tmp = a; elseif (t <= 2.25e+70) tmp = z; else tmp = Float64(t * b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -2.2e-10) tmp = t * b; elseif (t <= 9e-100) tmp = a; elseif (t <= 2.25e+70) tmp = z; else tmp = t * b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -2.2e-10], N[(t * b), $MachinePrecision], If[LessEqual[t, 9e-100], a, If[LessEqual[t, 2.25e+70], z, N[(t * b), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.2 \cdot 10^{-10}:\\
\;\;\;\;t \cdot b\\
\mathbf{elif}\;t \leq 9 \cdot 10^{-100}:\\
\;\;\;\;a\\
\mathbf{elif}\;t \leq 2.25 \cdot 10^{+70}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;t \cdot b\\
\end{array}
\end{array}
if t < -2.1999999999999999e-10 or 2.25e70 < t Initial program 93.6%
Taylor expanded in t around inf 63.9%
Taylor expanded in b around inf 35.1%
if -2.1999999999999999e-10 < t < 9.0000000000000002e-100Initial program 96.9%
Taylor expanded in a around inf 24.1%
Taylor expanded in t around 0 24.1%
if 9.0000000000000002e-100 < t < 2.25e70Initial program 94.3%
Taylor expanded in z around inf 54.3%
Taylor expanded in y around 0 34.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -1.6e+120) (not (<= b 6.5e+58))) (* b (- (+ y t) 2.0)) (+ x (* z (- 1.0 y)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.6e+120) || !(b <= 6.5e+58)) {
tmp = b * ((y + t) - 2.0);
} else {
tmp = x + (z * (1.0 - y));
}
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.6d+120)) .or. (.not. (b <= 6.5d+58))) then
tmp = b * ((y + t) - 2.0d0)
else
tmp = x + (z * (1.0d0 - y))
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.6e+120) || !(b <= 6.5e+58)) {
tmp = b * ((y + t) - 2.0);
} else {
tmp = x + (z * (1.0 - y));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -1.6e+120) or not (b <= 6.5e+58): tmp = b * ((y + t) - 2.0) else: tmp = x + (z * (1.0 - y)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -1.6e+120) || !(b <= 6.5e+58)) tmp = Float64(b * Float64(Float64(y + t) - 2.0)); else tmp = Float64(x + Float64(z * Float64(1.0 - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -1.6e+120) || ~((b <= 6.5e+58))) tmp = b * ((y + t) - 2.0); else tmp = x + (z * (1.0 - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -1.6e+120], N[Not[LessEqual[b, 6.5e+58]], $MachinePrecision]], N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision], N[(x + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.6 \cdot 10^{+120} \lor \neg \left(b \leq 6.5 \cdot 10^{+58}\right):\\
\;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{else}:\\
\;\;\;\;x + z \cdot \left(1 - y\right)\\
\end{array}
\end{array}
if b < -1.59999999999999991e120 or 6.49999999999999998e58 < b Initial program 87.4%
Taylor expanded in b around inf 78.3%
if -1.59999999999999991e120 < b < 6.49999999999999998e58Initial program 98.8%
Taylor expanded in a around 0 67.7%
Taylor expanded in b around 0 56.4%
Final simplification63.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= a -1.2e+45) (not (<= a 4.1e+95))) (* a (- 1.0 t)) (+ x z)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((a <= -1.2e+45) || !(a <= 4.1e+95)) {
tmp = a * (1.0 - t);
} else {
tmp = 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 ((a <= (-1.2d+45)) .or. (.not. (a <= 4.1d+95))) then
tmp = a * (1.0d0 - t)
else
tmp = 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 ((a <= -1.2e+45) || !(a <= 4.1e+95)) {
tmp = a * (1.0 - t);
} else {
tmp = x + z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (a <= -1.2e+45) or not (a <= 4.1e+95): tmp = a * (1.0 - t) else: tmp = x + z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((a <= -1.2e+45) || !(a <= 4.1e+95)) tmp = Float64(a * Float64(1.0 - t)); else tmp = Float64(x + z); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((a <= -1.2e+45) || ~((a <= 4.1e+95))) tmp = a * (1.0 - t); else tmp = x + z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[a, -1.2e+45], N[Not[LessEqual[a, 4.1e+95]], $MachinePrecision]], N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision], N[(x + z), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.2 \cdot 10^{+45} \lor \neg \left(a \leq 4.1 \cdot 10^{+95}\right):\\
\;\;\;\;a \cdot \left(1 - t\right)\\
\mathbf{else}:\\
\;\;\;\;x + z\\
\end{array}
\end{array}
if a < -1.19999999999999995e45 or 4.09999999999999986e95 < a Initial program 91.8%
Taylor expanded in a around inf 65.0%
if -1.19999999999999995e45 < a < 4.09999999999999986e95Initial program 96.9%
Taylor expanded in b around 0 59.6%
Taylor expanded in y around 0 36.9%
+-commutative36.9%
sub-neg36.9%
metadata-eval36.9%
neg-mul-136.9%
unsub-neg36.9%
Simplified36.9%
Taylor expanded in a around 0 32.5%
+-commutative32.5%
Simplified32.5%
Final simplification44.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -6.5e+92) (not (<= y 1050.0))) (* y (- z)) (+ x z)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -6.5e+92) || !(y <= 1050.0)) {
tmp = y * -z;
} else {
tmp = 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 <= (-6.5d+92)) .or. (.not. (y <= 1050.0d0))) then
tmp = y * -z
else
tmp = 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 <= -6.5e+92) || !(y <= 1050.0)) {
tmp = y * -z;
} else {
tmp = x + z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -6.5e+92) or not (y <= 1050.0): tmp = y * -z else: tmp = x + z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -6.5e+92) || !(y <= 1050.0)) tmp = Float64(y * Float64(-z)); else tmp = Float64(x + z); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -6.5e+92) || ~((y <= 1050.0))) tmp = y * -z; else tmp = x + z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -6.5e+92], N[Not[LessEqual[y, 1050.0]], $MachinePrecision]], N[(y * (-z)), $MachinePrecision], N[(x + z), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.5 \cdot 10^{+92} \lor \neg \left(y \leq 1050\right):\\
\;\;\;\;y \cdot \left(-z\right)\\
\mathbf{else}:\\
\;\;\;\;x + z\\
\end{array}
\end{array}
if y < -6.49999999999999999e92 or 1050 < y Initial program 92.2%
Taylor expanded in z around inf 45.5%
Taylor expanded in y around inf 45.5%
mul-1-neg45.5%
distribute-lft-neg-out45.5%
*-commutative45.5%
Simplified45.5%
if -6.49999999999999999e92 < y < 1050Initial program 96.7%
Taylor expanded in b around 0 67.9%
Taylor expanded in y around 0 65.8%
+-commutative65.8%
sub-neg65.8%
metadata-eval65.8%
neg-mul-165.8%
unsub-neg65.8%
Simplified65.8%
Taylor expanded in a around 0 36.4%
+-commutative36.4%
Simplified36.4%
Final simplification40.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= a -8.4e+39) (not (<= a 4e+108))) (* a (- t)) (+ x z)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((a <= -8.4e+39) || !(a <= 4e+108)) {
tmp = a * -t;
} else {
tmp = 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 ((a <= (-8.4d+39)) .or. (.not. (a <= 4d+108))) then
tmp = a * -t
else
tmp = 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 ((a <= -8.4e+39) || !(a <= 4e+108)) {
tmp = a * -t;
} else {
tmp = x + z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (a <= -8.4e+39) or not (a <= 4e+108): tmp = a * -t else: tmp = x + z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((a <= -8.4e+39) || !(a <= 4e+108)) tmp = Float64(a * Float64(-t)); else tmp = Float64(x + z); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((a <= -8.4e+39) || ~((a <= 4e+108))) tmp = a * -t; else tmp = x + z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[a, -8.4e+39], N[Not[LessEqual[a, 4e+108]], $MachinePrecision]], N[(a * (-t)), $MachinePrecision], N[(x + z), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -8.4 \cdot 10^{+39} \lor \neg \left(a \leq 4 \cdot 10^{+108}\right):\\
\;\;\;\;a \cdot \left(-t\right)\\
\mathbf{else}:\\
\;\;\;\;x + z\\
\end{array}
\end{array}
if a < -8.3999999999999994e39 or 4.0000000000000001e108 < a Initial program 92.5%
Taylor expanded in t around inf 50.9%
Taylor expanded in b around 0 44.7%
mul-1-neg44.7%
distribute-lft-neg-out44.7%
*-commutative44.7%
Simplified44.7%
if -8.3999999999999994e39 < a < 4.0000000000000001e108Initial program 96.3%
Taylor expanded in b around 0 60.6%
Taylor expanded in y around 0 37.9%
+-commutative37.9%
sub-neg37.9%
metadata-eval37.9%
neg-mul-137.9%
unsub-neg37.9%
Simplified37.9%
Taylor expanded in a around 0 32.4%
+-commutative32.4%
Simplified32.4%
Final simplification36.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -1.15e+103) (not (<= b 2.15e+42))) (* t b) (+ x z)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.15e+103) || !(b <= 2.15e+42)) {
tmp = t * b;
} else {
tmp = 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 ((b <= (-1.15d+103)) .or. (.not. (b <= 2.15d+42))) then
tmp = t * b
else
tmp = 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 ((b <= -1.15e+103) || !(b <= 2.15e+42)) {
tmp = t * b;
} else {
tmp = x + z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -1.15e+103) or not (b <= 2.15e+42): tmp = t * b else: tmp = x + z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -1.15e+103) || !(b <= 2.15e+42)) tmp = Float64(t * b); else tmp = Float64(x + z); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -1.15e+103) || ~((b <= 2.15e+42))) tmp = t * b; else tmp = x + z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -1.15e+103], N[Not[LessEqual[b, 2.15e+42]], $MachinePrecision]], N[(t * b), $MachinePrecision], N[(x + z), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.15 \cdot 10^{+103} \lor \neg \left(b \leq 2.15 \cdot 10^{+42}\right):\\
\;\;\;\;t \cdot b\\
\mathbf{else}:\\
\;\;\;\;x + z\\
\end{array}
\end{array}
if b < -1.15000000000000004e103 or 2.1499999999999999e42 < b Initial program 86.8%
Taylor expanded in t around inf 48.2%
Taylor expanded in b around inf 41.5%
if -1.15000000000000004e103 < b < 2.1499999999999999e42Initial program 99.4%
Taylor expanded in b around 0 87.7%
Taylor expanded in y around 0 65.0%
+-commutative65.0%
sub-neg65.0%
metadata-eval65.0%
neg-mul-165.0%
unsub-neg65.0%
Simplified65.0%
Taylor expanded in a around 0 32.5%
+-commutative32.5%
Simplified32.5%
Final simplification35.7%
(FPCore (x y z t a b) :precision binary64 (if (<= z -8.2e+64) z (if (<= z 2.3e+91) x z)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -8.2e+64) {
tmp = z;
} else if (z <= 2.3e+91) {
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 <= (-8.2d+64)) then
tmp = z
else if (z <= 2.3d+91) 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 <= -8.2e+64) {
tmp = z;
} else if (z <= 2.3e+91) {
tmp = x;
} else {
tmp = z;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -8.2e+64: tmp = z elif z <= 2.3e+91: tmp = x else: tmp = z return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -8.2e+64) tmp = z; elseif (z <= 2.3e+91) tmp = x; else tmp = z; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -8.2e+64) tmp = z; elseif (z <= 2.3e+91) tmp = x; else tmp = z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -8.2e+64], z, If[LessEqual[z, 2.3e+91], x, z]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.2 \cdot 10^{+64}:\\
\;\;\;\;z\\
\mathbf{elif}\;z \leq 2.3 \cdot 10^{+91}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;z\\
\end{array}
\end{array}
if z < -8.19999999999999956e64 or 2.29999999999999991e91 < z Initial program 88.8%
Taylor expanded in z around inf 59.2%
Taylor expanded in y around 0 27.6%
if -8.19999999999999956e64 < z < 2.29999999999999991e91Initial program 100.0%
Taylor expanded in x around inf 17.0%
(FPCore (x y z t a b) :precision binary64 (if (<= x -1.95e+127) x (if (<= x 1.16e+138) a x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= -1.95e+127) {
tmp = x;
} else if (x <= 1.16e+138) {
tmp = a;
} 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.95d+127)) then
tmp = x
else if (x <= 1.16d+138) then
tmp = a
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.95e+127) {
tmp = x;
} else if (x <= 1.16e+138) {
tmp = a;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= -1.95e+127: tmp = x elif x <= 1.16e+138: tmp = a else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= -1.95e+127) tmp = x; elseif (x <= 1.16e+138) tmp = a; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (x <= -1.95e+127) tmp = x; elseif (x <= 1.16e+138) tmp = a; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, -1.95e+127], x, If[LessEqual[x, 1.16e+138], a, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.95 \cdot 10^{+127}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 1.16 \cdot 10^{+138}:\\
\;\;\;\;a\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -1.94999999999999991e127 or 1.15999999999999994e138 < x Initial program 94.4%
Taylor expanded in x around inf 35.6%
if -1.94999999999999991e127 < x < 1.15999999999999994e138Initial program 95.1%
Taylor expanded in a around inf 31.6%
Taylor expanded in t around 0 14.0%
(FPCore (x y z t a b) :precision binary64 a)
double code(double x, double y, double z, double t, double a, double b) {
return a;
}
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 = a
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return a;
}
def code(x, y, z, t, a, b): return a
function code(x, y, z, t, a, b) return a end
function tmp = code(x, y, z, t, a, b) tmp = a; end
code[x_, y_, z_, t_, a_, b_] := a
\begin{array}{l}
\\
a
\end{array}
Initial program 94.9%
Taylor expanded in a around inf 28.4%
Taylor expanded in t around 0 11.4%
herbie shell --seed 2024165
(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)))