
(FPCore (x y z t a b c i j k) :precision binary64 (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k): return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 25 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i j k) :precision binary64 (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k): return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1
(-
(-
(+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
(* (* x 4.0) i))
(* (* j 27.0) k))))
(if (<= t_1 INFINITY) t_1 (* x (- (* y (* z (* t (- -18.0)))) (* 4.0 i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
}
return tmp;
}
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(x * Float64(Float64(y * Float64(z * Float64(t * Float64(-(-18.0))))) - Float64(4.0 * i))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
tmp = 0.0;
if (t_1 <= Inf)
tmp = t_1;
else
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(x * N[(N[(y * N[(z * N[(t * (--18.0)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(z \cdot \left(t \cdot \left(--18\right)\right)\right) - 4 \cdot i\right)\\
\end{array}
\end{array}
if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) < +inf.0Initial program 96.9%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) Initial program 0.0%
Simplified16.1%
pow116.1%
associate-*l*16.1%
associate-*r*16.1%
Applied egg-rr16.1%
unpow116.1%
*-commutative16.1%
Simplified16.1%
Taylor expanded in x around -inf 58.1%
associate-*r*58.1%
neg-mul-158.1%
cancel-sign-sub-inv58.1%
metadata-eval58.1%
associate-*r*58.1%
Simplified58.1%
Taylor expanded in t around 0 58.1%
associate-*r*58.1%
*-commutative58.1%
*-commutative58.1%
associate-*l*58.1%
Simplified58.1%
Final simplification92.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (* i -4.0))))
(if (<= (* b c) -95000000000.0)
(* b c)
(if (<= (* b c) -1.15e-123)
t_1
(if (<= (* b c) -5e-320)
(* -4.0 (* t a))
(if (<= (* b c) 1.3e-157)
(* 18.0 (* (* y z) (* x t)))
(if (<= (* b c) 5.7e-108)
t_1
(if (<= (* b c) 9.8e+169)
(* x (* 18.0 (* z (* y t))))
(* b c)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (i * -4.0);
double tmp;
if ((b * c) <= -95000000000.0) {
tmp = b * c;
} else if ((b * c) <= -1.15e-123) {
tmp = t_1;
} else if ((b * c) <= -5e-320) {
tmp = -4.0 * (t * a);
} else if ((b * c) <= 1.3e-157) {
tmp = 18.0 * ((y * z) * (x * t));
} else if ((b * c) <= 5.7e-108) {
tmp = t_1;
} else if ((b * c) <= 9.8e+169) {
tmp = x * (18.0 * (z * (y * t)));
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = x * (i * (-4.0d0))
if ((b * c) <= (-95000000000.0d0)) then
tmp = b * c
else if ((b * c) <= (-1.15d-123)) then
tmp = t_1
else if ((b * c) <= (-5d-320)) then
tmp = (-4.0d0) * (t * a)
else if ((b * c) <= 1.3d-157) then
tmp = 18.0d0 * ((y * z) * (x * t))
else if ((b * c) <= 5.7d-108) then
tmp = t_1
else if ((b * c) <= 9.8d+169) then
tmp = x * (18.0d0 * (z * (y * t)))
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (i * -4.0);
double tmp;
if ((b * c) <= -95000000000.0) {
tmp = b * c;
} else if ((b * c) <= -1.15e-123) {
tmp = t_1;
} else if ((b * c) <= -5e-320) {
tmp = -4.0 * (t * a);
} else if ((b * c) <= 1.3e-157) {
tmp = 18.0 * ((y * z) * (x * t));
} else if ((b * c) <= 5.7e-108) {
tmp = t_1;
} else if ((b * c) <= 9.8e+169) {
tmp = x * (18.0 * (z * (y * t)));
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = x * (i * -4.0) tmp = 0 if (b * c) <= -95000000000.0: tmp = b * c elif (b * c) <= -1.15e-123: tmp = t_1 elif (b * c) <= -5e-320: tmp = -4.0 * (t * a) elif (b * c) <= 1.3e-157: tmp = 18.0 * ((y * z) * (x * t)) elif (b * c) <= 5.7e-108: tmp = t_1 elif (b * c) <= 9.8e+169: tmp = x * (18.0 * (z * (y * t))) else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * Float64(i * -4.0)) tmp = 0.0 if (Float64(b * c) <= -95000000000.0) tmp = Float64(b * c); elseif (Float64(b * c) <= -1.15e-123) tmp = t_1; elseif (Float64(b * c) <= -5e-320) tmp = Float64(-4.0 * Float64(t * a)); elseif (Float64(b * c) <= 1.3e-157) tmp = Float64(18.0 * Float64(Float64(y * z) * Float64(x * t))); elseif (Float64(b * c) <= 5.7e-108) tmp = t_1; elseif (Float64(b * c) <= 9.8e+169) tmp = Float64(x * Float64(18.0 * Float64(z * Float64(y * t)))); else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = x * (i * -4.0);
tmp = 0.0;
if ((b * c) <= -95000000000.0)
tmp = b * c;
elseif ((b * c) <= -1.15e-123)
tmp = t_1;
elseif ((b * c) <= -5e-320)
tmp = -4.0 * (t * a);
elseif ((b * c) <= 1.3e-157)
tmp = 18.0 * ((y * z) * (x * t));
elseif ((b * c) <= 5.7e-108)
tmp = t_1;
elseif ((b * c) <= 9.8e+169)
tmp = x * (18.0 * (z * (y * t)));
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -95000000000.0], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -1.15e-123], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -5e-320], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.3e-157], N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 5.7e-108], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 9.8e+169], N[(x * N[(18.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \left(i \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -95000000000:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -1.15 \cdot 10^{-123}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-320}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;b \cdot c \leq 1.3 \cdot 10^{-157}:\\
\;\;\;\;18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\
\mathbf{elif}\;b \cdot c \leq 5.7 \cdot 10^{-108}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq 9.8 \cdot 10^{+169}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -9.5e10 or 9.80000000000000053e169 < (*.f64 b c) Initial program 80.5%
Simplified80.5%
pow180.5%
associate-*l*80.5%
associate-*r*80.5%
Applied egg-rr80.5%
unpow180.5%
*-commutative80.5%
Simplified80.5%
Taylor expanded in b around inf 61.5%
if -9.5e10 < (*.f64 b c) < -1.14999999999999993e-123 or 1.29999999999999994e-157 < (*.f64 b c) < 5.7e-108Initial program 77.2%
Simplified77.5%
pow177.5%
associate-*l*77.5%
associate-*r*77.5%
Applied egg-rr77.5%
unpow177.5%
*-commutative77.5%
Simplified77.5%
Taylor expanded in i around inf 50.0%
metadata-eval50.0%
distribute-lft-neg-in50.0%
associate-*r*50.0%
*-commutative50.0%
distribute-rgt-neg-in50.0%
distribute-lft-neg-in50.0%
metadata-eval50.0%
Simplified50.0%
if -1.14999999999999993e-123 < (*.f64 b c) < -4.99994e-320Initial program 92.7%
Simplified93.4%
Taylor expanded in j around 0 70.1%
Taylor expanded in y around 0 66.5%
Taylor expanded in a around inf 40.5%
*-commutative40.5%
Simplified40.5%
if -4.99994e-320 < (*.f64 b c) < 1.29999999999999994e-157Initial program 89.2%
Simplified89.3%
Taylor expanded in x around inf 51.3%
Taylor expanded in t around inf 39.2%
associate-*r*38.5%
Simplified38.5%
if 5.7e-108 < (*.f64 b c) < 9.80000000000000053e169Initial program 91.4%
Simplified93.6%
Taylor expanded in x around inf 55.6%
Taylor expanded in t around inf 36.3%
*-commutative36.3%
associate-*l*36.2%
*-commutative36.2%
Simplified36.2%
Taylor expanded in t around 0 36.3%
associate-*r*36.3%
Simplified36.3%
Final simplification48.1%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 18.0 (* (* y z) (* x t)))) (t_2 (* x (* i -4.0))))
(if (<= (* b c) -2600000000.0)
(* b c)
(if (<= (* b c) -7.6e-124)
t_2
(if (<= (* b c) -5e-320)
(* -4.0 (* t a))
(if (<= (* b c) 5.3e-158)
t_1
(if (<= (* b c) 95.0)
t_2
(if (<= (* b c) 4.4e+170) t_1 (* b c)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 18.0 * ((y * z) * (x * t));
double t_2 = x * (i * -4.0);
double tmp;
if ((b * c) <= -2600000000.0) {
tmp = b * c;
} else if ((b * c) <= -7.6e-124) {
tmp = t_2;
} else if ((b * c) <= -5e-320) {
tmp = -4.0 * (t * a);
} else if ((b * c) <= 5.3e-158) {
tmp = t_1;
} else if ((b * c) <= 95.0) {
tmp = t_2;
} else if ((b * c) <= 4.4e+170) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = 18.0d0 * ((y * z) * (x * t))
t_2 = x * (i * (-4.0d0))
if ((b * c) <= (-2600000000.0d0)) then
tmp = b * c
else if ((b * c) <= (-7.6d-124)) then
tmp = t_2
else if ((b * c) <= (-5d-320)) then
tmp = (-4.0d0) * (t * a)
else if ((b * c) <= 5.3d-158) then
tmp = t_1
else if ((b * c) <= 95.0d0) then
tmp = t_2
else if ((b * c) <= 4.4d+170) then
tmp = t_1
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 18.0 * ((y * z) * (x * t));
double t_2 = x * (i * -4.0);
double tmp;
if ((b * c) <= -2600000000.0) {
tmp = b * c;
} else if ((b * c) <= -7.6e-124) {
tmp = t_2;
} else if ((b * c) <= -5e-320) {
tmp = -4.0 * (t * a);
} else if ((b * c) <= 5.3e-158) {
tmp = t_1;
} else if ((b * c) <= 95.0) {
tmp = t_2;
} else if ((b * c) <= 4.4e+170) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = 18.0 * ((y * z) * (x * t)) t_2 = x * (i * -4.0) tmp = 0 if (b * c) <= -2600000000.0: tmp = b * c elif (b * c) <= -7.6e-124: tmp = t_2 elif (b * c) <= -5e-320: tmp = -4.0 * (t * a) elif (b * c) <= 5.3e-158: tmp = t_1 elif (b * c) <= 95.0: tmp = t_2 elif (b * c) <= 4.4e+170: tmp = t_1 else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(18.0 * Float64(Float64(y * z) * Float64(x * t))) t_2 = Float64(x * Float64(i * -4.0)) tmp = 0.0 if (Float64(b * c) <= -2600000000.0) tmp = Float64(b * c); elseif (Float64(b * c) <= -7.6e-124) tmp = t_2; elseif (Float64(b * c) <= -5e-320) tmp = Float64(-4.0 * Float64(t * a)); elseif (Float64(b * c) <= 5.3e-158) tmp = t_1; elseif (Float64(b * c) <= 95.0) tmp = t_2; elseif (Float64(b * c) <= 4.4e+170) tmp = t_1; else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = 18.0 * ((y * z) * (x * t));
t_2 = x * (i * -4.0);
tmp = 0.0;
if ((b * c) <= -2600000000.0)
tmp = b * c;
elseif ((b * c) <= -7.6e-124)
tmp = t_2;
elseif ((b * c) <= -5e-320)
tmp = -4.0 * (t * a);
elseif ((b * c) <= 5.3e-158)
tmp = t_1;
elseif ((b * c) <= 95.0)
tmp = t_2;
elseif ((b * c) <= 4.4e+170)
tmp = t_1;
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -2600000000.0], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -7.6e-124], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], -5e-320], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 5.3e-158], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 95.0], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], 4.4e+170], t$95$1, N[(b * c), $MachinePrecision]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\
t_2 := x \cdot \left(i \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -2600000000:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -7.6 \cdot 10^{-124}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-320}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;b \cdot c \leq 5.3 \cdot 10^{-158}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq 95:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \cdot c \leq 4.4 \cdot 10^{+170}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -2.6e9 or 4.39999999999999978e170 < (*.f64 b c) Initial program 80.5%
Simplified80.5%
pow180.5%
associate-*l*80.5%
associate-*r*80.5%
Applied egg-rr80.5%
unpow180.5%
*-commutative80.5%
Simplified80.5%
Taylor expanded in b around inf 61.5%
if -2.6e9 < (*.f64 b c) < -7.60000000000000025e-124 or 5.2999999999999999e-158 < (*.f64 b c) < 95Initial program 80.4%
Simplified80.6%
pow180.6%
associate-*l*80.6%
associate-*r*80.6%
Applied egg-rr80.6%
unpow180.6%
*-commutative80.6%
Simplified80.6%
Taylor expanded in i around inf 42.8%
metadata-eval42.8%
distribute-lft-neg-in42.8%
associate-*r*42.8%
*-commutative42.8%
distribute-rgt-neg-in42.8%
distribute-lft-neg-in42.8%
metadata-eval42.8%
Simplified42.8%
if -7.60000000000000025e-124 < (*.f64 b c) < -4.99994e-320Initial program 92.7%
Simplified93.4%
Taylor expanded in j around 0 70.1%
Taylor expanded in y around 0 66.5%
Taylor expanded in a around inf 40.5%
*-commutative40.5%
Simplified40.5%
if -4.99994e-320 < (*.f64 b c) < 5.2999999999999999e-158 or 95 < (*.f64 b c) < 4.39999999999999978e170Initial program 90.8%
Simplified92.0%
Taylor expanded in x around inf 53.5%
Taylor expanded in t around inf 38.9%
associate-*r*38.4%
Simplified38.4%
Final simplification47.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (- (* b c) (* 4.0 (* x i))))
(t_2 (* t (+ (* 18.0 (* x (* y z))) (* a -4.0))))
(t_3 (* j (* k -27.0))))
(if (<= t -6e+220)
t_2
(if (<= t -2.2e+96)
t_1
(if (<= t -1.32e-33)
t_2
(if (<= t -6.5e-259)
t_1
(if (<= t 4.2e-261)
(+ (* b c) t_3)
(if (<= t 6.8e-125)
(+ t_3 (* i (* x -4.0)))
(if (<= t 5000000.0) (+ (* b c) (* -4.0 (* t a))) t_2)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) - (4.0 * (x * i));
double t_2 = t * ((18.0 * (x * (y * z))) + (a * -4.0));
double t_3 = j * (k * -27.0);
double tmp;
if (t <= -6e+220) {
tmp = t_2;
} else if (t <= -2.2e+96) {
tmp = t_1;
} else if (t <= -1.32e-33) {
tmp = t_2;
} else if (t <= -6.5e-259) {
tmp = t_1;
} else if (t <= 4.2e-261) {
tmp = (b * c) + t_3;
} else if (t <= 6.8e-125) {
tmp = t_3 + (i * (x * -4.0));
} else if (t <= 5000000.0) {
tmp = (b * c) + (-4.0 * (t * a));
} else {
tmp = t_2;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = (b * c) - (4.0d0 * (x * i))
t_2 = t * ((18.0d0 * (x * (y * z))) + (a * (-4.0d0)))
t_3 = j * (k * (-27.0d0))
if (t <= (-6d+220)) then
tmp = t_2
else if (t <= (-2.2d+96)) then
tmp = t_1
else if (t <= (-1.32d-33)) then
tmp = t_2
else if (t <= (-6.5d-259)) then
tmp = t_1
else if (t <= 4.2d-261) then
tmp = (b * c) + t_3
else if (t <= 6.8d-125) then
tmp = t_3 + (i * (x * (-4.0d0)))
else if (t <= 5000000.0d0) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else
tmp = t_2
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) - (4.0 * (x * i));
double t_2 = t * ((18.0 * (x * (y * z))) + (a * -4.0));
double t_3 = j * (k * -27.0);
double tmp;
if (t <= -6e+220) {
tmp = t_2;
} else if (t <= -2.2e+96) {
tmp = t_1;
} else if (t <= -1.32e-33) {
tmp = t_2;
} else if (t <= -6.5e-259) {
tmp = t_1;
} else if (t <= 4.2e-261) {
tmp = (b * c) + t_3;
} else if (t <= 6.8e-125) {
tmp = t_3 + (i * (x * -4.0));
} else if (t <= 5000000.0) {
tmp = (b * c) + (-4.0 * (t * a));
} else {
tmp = t_2;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) - (4.0 * (x * i)) t_2 = t * ((18.0 * (x * (y * z))) + (a * -4.0)) t_3 = j * (k * -27.0) tmp = 0 if t <= -6e+220: tmp = t_2 elif t <= -2.2e+96: tmp = t_1 elif t <= -1.32e-33: tmp = t_2 elif t <= -6.5e-259: tmp = t_1 elif t <= 4.2e-261: tmp = (b * c) + t_3 elif t <= 6.8e-125: tmp = t_3 + (i * (x * -4.0)) elif t <= 5000000.0: tmp = (b * c) + (-4.0 * (t * a)) else: tmp = t_2 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) t_2 = Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) + Float64(a * -4.0))) t_3 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (t <= -6e+220) tmp = t_2; elseif (t <= -2.2e+96) tmp = t_1; elseif (t <= -1.32e-33) tmp = t_2; elseif (t <= -6.5e-259) tmp = t_1; elseif (t <= 4.2e-261) tmp = Float64(Float64(b * c) + t_3); elseif (t <= 6.8e-125) tmp = Float64(t_3 + Float64(i * Float64(x * -4.0))); elseif (t <= 5000000.0) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); else tmp = t_2; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (b * c) - (4.0 * (x * i));
t_2 = t * ((18.0 * (x * (y * z))) + (a * -4.0));
t_3 = j * (k * -27.0);
tmp = 0.0;
if (t <= -6e+220)
tmp = t_2;
elseif (t <= -2.2e+96)
tmp = t_1;
elseif (t <= -1.32e-33)
tmp = t_2;
elseif (t <= -6.5e-259)
tmp = t_1;
elseif (t <= 4.2e-261)
tmp = (b * c) + t_3;
elseif (t <= 6.8e-125)
tmp = t_3 + (i * (x * -4.0));
elseif (t <= 5000000.0)
tmp = (b * c) + (-4.0 * (t * a));
else
tmp = t_2;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -6e+220], t$95$2, If[LessEqual[t, -2.2e+96], t$95$1, If[LessEqual[t, -1.32e-33], t$95$2, If[LessEqual[t, -6.5e-259], t$95$1, If[LessEqual[t, 4.2e-261], N[(N[(b * c), $MachinePrecision] + t$95$3), $MachinePrecision], If[LessEqual[t, 6.8e-125], N[(t$95$3 + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5000000.0], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c - 4 \cdot \left(x \cdot i\right)\\
t_2 := t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right)\\
t_3 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;t \leq -6 \cdot 10^{+220}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -2.2 \cdot 10^{+96}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.32 \cdot 10^{-33}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -6.5 \cdot 10^{-259}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 4.2 \cdot 10^{-261}:\\
\;\;\;\;b \cdot c + t\_3\\
\mathbf{elif}\;t \leq 6.8 \cdot 10^{-125}:\\
\;\;\;\;t\_3 + i \cdot \left(x \cdot -4\right)\\
\mathbf{elif}\;t \leq 5000000:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -6.00000000000000048e220 or -2.1999999999999999e96 < t < -1.31999999999999993e-33 or 5e6 < t Initial program 88.6%
Simplified89.8%
Taylor expanded in j around 0 86.8%
Taylor expanded in y around 0 84.9%
Taylor expanded in t around inf 73.4%
if -6.00000000000000048e220 < t < -2.1999999999999999e96 or -1.31999999999999993e-33 < t < -6.50000000000000045e-259Initial program 84.6%
Taylor expanded in t around 0 73.8%
Taylor expanded in j around 0 66.4%
if -6.50000000000000045e-259 < t < 4.19999999999999991e-261Initial program 87.1%
Simplified78.8%
Taylor expanded in b around inf 75.6%
if 4.19999999999999991e-261 < t < 6.7999999999999995e-125Initial program 74.2%
Simplified74.3%
Taylor expanded in i around inf 69.8%
associate-*r*69.8%
*-commutative69.8%
associate-*r*69.8%
*-commutative69.8%
*-commutative69.8%
Simplified69.8%
if 6.7999999999999995e-125 < t < 5e6Initial program 83.0%
Simplified79.8%
Taylor expanded in j around 0 69.9%
Taylor expanded in y around 0 69.9%
Taylor expanded in x around 0 58.3%
Final simplification69.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (* i -4.0))))
(if (<= (* b c) -35000000.0)
(* b c)
(if (<= (* b c) -8.5e-124)
t_1
(if (<= (* b c) -4.9e-281)
(* -4.0 (* t a))
(if (<= (* b c) 1.05e-197)
(* j (* k -27.0))
(if (<= (* b c) 2.4e+125) t_1 (* b c))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (i * -4.0);
double tmp;
if ((b * c) <= -35000000.0) {
tmp = b * c;
} else if ((b * c) <= -8.5e-124) {
tmp = t_1;
} else if ((b * c) <= -4.9e-281) {
tmp = -4.0 * (t * a);
} else if ((b * c) <= 1.05e-197) {
tmp = j * (k * -27.0);
} else if ((b * c) <= 2.4e+125) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = x * (i * (-4.0d0))
if ((b * c) <= (-35000000.0d0)) then
tmp = b * c
else if ((b * c) <= (-8.5d-124)) then
tmp = t_1
else if ((b * c) <= (-4.9d-281)) then
tmp = (-4.0d0) * (t * a)
else if ((b * c) <= 1.05d-197) then
tmp = j * (k * (-27.0d0))
else if ((b * c) <= 2.4d+125) then
tmp = t_1
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (i * -4.0);
double tmp;
if ((b * c) <= -35000000.0) {
tmp = b * c;
} else if ((b * c) <= -8.5e-124) {
tmp = t_1;
} else if ((b * c) <= -4.9e-281) {
tmp = -4.0 * (t * a);
} else if ((b * c) <= 1.05e-197) {
tmp = j * (k * -27.0);
} else if ((b * c) <= 2.4e+125) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = x * (i * -4.0) tmp = 0 if (b * c) <= -35000000.0: tmp = b * c elif (b * c) <= -8.5e-124: tmp = t_1 elif (b * c) <= -4.9e-281: tmp = -4.0 * (t * a) elif (b * c) <= 1.05e-197: tmp = j * (k * -27.0) elif (b * c) <= 2.4e+125: tmp = t_1 else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * Float64(i * -4.0)) tmp = 0.0 if (Float64(b * c) <= -35000000.0) tmp = Float64(b * c); elseif (Float64(b * c) <= -8.5e-124) tmp = t_1; elseif (Float64(b * c) <= -4.9e-281) tmp = Float64(-4.0 * Float64(t * a)); elseif (Float64(b * c) <= 1.05e-197) tmp = Float64(j * Float64(k * -27.0)); elseif (Float64(b * c) <= 2.4e+125) tmp = t_1; else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = x * (i * -4.0);
tmp = 0.0;
if ((b * c) <= -35000000.0)
tmp = b * c;
elseif ((b * c) <= -8.5e-124)
tmp = t_1;
elseif ((b * c) <= -4.9e-281)
tmp = -4.0 * (t * a);
elseif ((b * c) <= 1.05e-197)
tmp = j * (k * -27.0);
elseif ((b * c) <= 2.4e+125)
tmp = t_1;
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -35000000.0], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -8.5e-124], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -4.9e-281], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.05e-197], N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2.4e+125], t$95$1, N[(b * c), $MachinePrecision]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \left(i \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -35000000:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -8.5 \cdot 10^{-124}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq -4.9 \cdot 10^{-281}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;b \cdot c \leq 1.05 \cdot 10^{-197}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;b \cdot c \leq 2.4 \cdot 10^{+125}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -3.5e7 or 2.4e125 < (*.f64 b c) Initial program 81.1%
Simplified81.1%
pow181.1%
associate-*l*81.1%
associate-*r*81.1%
Applied egg-rr81.1%
unpow181.1%
*-commutative81.1%
Simplified81.1%
Taylor expanded in b around inf 58.2%
if -3.5e7 < (*.f64 b c) < -8.5000000000000002e-124 or 1.05e-197 < (*.f64 b c) < 2.4e125Initial program 85.2%
Simplified87.8%
pow187.8%
associate-*l*87.8%
associate-*r*87.8%
Applied egg-rr87.8%
unpow187.8%
*-commutative87.8%
Simplified87.8%
Taylor expanded in i around inf 36.4%
metadata-eval36.4%
distribute-lft-neg-in36.4%
associate-*r*36.4%
*-commutative36.4%
distribute-rgt-neg-in36.4%
distribute-lft-neg-in36.4%
metadata-eval36.4%
Simplified36.4%
if -8.5000000000000002e-124 < (*.f64 b c) < -4.8999999999999999e-281Initial program 92.2%
Simplified93.0%
Taylor expanded in j around 0 74.9%
Taylor expanded in y around 0 71.0%
Taylor expanded in a around inf 43.3%
*-commutative43.3%
Simplified43.3%
if -4.8999999999999999e-281 < (*.f64 b c) < 1.05e-197Initial program 89.9%
Simplified87.9%
pow187.9%
associate-*l*87.9%
associate-*r*87.8%
Applied egg-rr87.8%
unpow187.8%
*-commutative87.8%
Simplified87.8%
Taylor expanded in j around inf 33.3%
*-commutative33.3%
associate-*r*33.4%
Simplified33.4%
Final simplification45.1%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (or (<= x -1.6e+67) (not (<= x 5.5e+214)))
(*
x
(-
(+ (* -4.0 (/ (* t a) x)) (+ (* 18.0 (* t (* y z))) (/ (* b c) x)))
(* 4.0 i)))
(-
(+ (* b c) (* t (- (* x (* z (* 18.0 y))) (* a 4.0))))
(+ (* x (* 4.0 i)) (* j (* 27.0 k))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((x <= -1.6e+67) || !(x <= 5.5e+214)) {
tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i));
} else {
tmp = ((b * c) + (t * ((x * (z * (18.0 * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((x <= (-1.6d+67)) .or. (.not. (x <= 5.5d+214))) then
tmp = x * ((((-4.0d0) * ((t * a) / x)) + ((18.0d0 * (t * (y * z))) + ((b * c) / x))) - (4.0d0 * i))
else
tmp = ((b * c) + (t * ((x * (z * (18.0d0 * y))) - (a * 4.0d0)))) - ((x * (4.0d0 * i)) + (j * (27.0d0 * k)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((x <= -1.6e+67) || !(x <= 5.5e+214)) {
tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i));
} else {
tmp = ((b * c) + (t * ((x * (z * (18.0 * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (x <= -1.6e+67) or not (x <= 5.5e+214): tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i)) else: tmp = ((b * c) + (t * ((x * (z * (18.0 * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((x <= -1.6e+67) || !(x <= 5.5e+214)) tmp = Float64(x * Float64(Float64(Float64(-4.0 * Float64(Float64(t * a) / x)) + Float64(Float64(18.0 * Float64(t * Float64(y * z))) + Float64(Float64(b * c) / x))) - Float64(4.0 * i))); else tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(x * Float64(z * Float64(18.0 * y))) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k)))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((x <= -1.6e+67) || ~((x <= 5.5e+214)))
tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i));
else
tmp = ((b * c) + (t * ((x * (z * (18.0 * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[x, -1.6e+67], N[Not[LessEqual[x, 5.5e+214]], $MachinePrecision]], N[(x * N[(N[(N[(-4.0 * N[(N[(t * a), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision] + N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(x * N[(z * N[(18.0 * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(27.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.6 \cdot 10^{+67} \lor \neg \left(x \leq 5.5 \cdot 10^{+214}\right):\\
\;\;\;\;x \cdot \left(\left(-4 \cdot \frac{t \cdot a}{x} + \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + \frac{b \cdot c}{x}\right)\right) - 4 \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(x \cdot \left(z \cdot \left(18 \cdot y\right)\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\
\end{array}
\end{array}
if x < -1.59999999999999991e67 or 5.5000000000000003e214 < x Initial program 65.0%
Simplified73.7%
Taylor expanded in j around 0 80.5%
Taylor expanded in x around inf 90.6%
if -1.59999999999999991e67 < x < 5.5000000000000003e214Initial program 92.5%
Simplified90.1%
pow190.1%
associate-*l*90.1%
associate-*r*90.1%
Applied egg-rr90.1%
unpow190.1%
*-commutative90.1%
Simplified90.1%
Final simplification90.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (or (<= x -8.2e+55) (not (<= x 0.0076)))
(*
x
(-
(+ (* -4.0 (/ (* t a) x)) (+ (* 18.0 (* t (* y z))) (/ (* b c) x)))
(* 4.0 i)))
(- (- (* b c) (* 4.0 (+ (* t a) (* x i)))) (* (* j 27.0) k))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((x <= -8.2e+55) || !(x <= 0.0076)) {
tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i));
} else {
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((x <= (-8.2d+55)) .or. (.not. (x <= 0.0076d0))) then
tmp = x * ((((-4.0d0) * ((t * a) / x)) + ((18.0d0 * (t * (y * z))) + ((b * c) / x))) - (4.0d0 * i))
else
tmp = ((b * c) - (4.0d0 * ((t * a) + (x * i)))) - ((j * 27.0d0) * k)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((x <= -8.2e+55) || !(x <= 0.0076)) {
tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i));
} else {
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (x <= -8.2e+55) or not (x <= 0.0076): tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i)) else: tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((x <= -8.2e+55) || !(x <= 0.0076)) tmp = Float64(x * Float64(Float64(Float64(-4.0 * Float64(Float64(t * a) / x)) + Float64(Float64(18.0 * Float64(t * Float64(y * z))) + Float64(Float64(b * c) / x))) - Float64(4.0 * i))); else tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i)))) - Float64(Float64(j * 27.0) * k)); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((x <= -8.2e+55) || ~((x <= 0.0076)))
tmp = x * (((-4.0 * ((t * a) / x)) + ((18.0 * (t * (y * z))) + ((b * c) / x))) - (4.0 * i));
else
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[x, -8.2e+55], N[Not[LessEqual[x, 0.0076]], $MachinePrecision]], N[(x * N[(N[(N[(-4.0 * N[(N[(t * a), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision] + N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -8.2 \cdot 10^{+55} \lor \neg \left(x \leq 0.0076\right):\\
\;\;\;\;x \cdot \left(\left(-4 \cdot \frac{t \cdot a}{x} + \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + \frac{b \cdot c}{x}\right)\right) - 4 \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\
\end{array}
\end{array}
if x < -8.19999999999999962e55 or 0.00759999999999999998 < x Initial program 74.8%
Simplified80.0%
Taylor expanded in j around 0 81.5%
Taylor expanded in x around inf 88.4%
if -8.19999999999999962e55 < x < 0.00759999999999999998Initial program 93.6%
Taylor expanded in y around 0 87.5%
distribute-lft-out87.5%
*-commutative87.5%
Simplified87.5%
Final simplification87.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= t_1 -5e+87)
(- (* b c) (* 27.0 (* j k)))
(if (<= t_1 1e-53)
(+ (* b c) (* -4.0 (* t a)))
(if (<= t_1 5e+168)
(- (* b c) (* 4.0 (* x i)))
(+ (* b c) (* j (* k -27.0))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -5e+87) {
tmp = (b * c) - (27.0 * (j * k));
} else if (t_1 <= 1e-53) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (t_1 <= 5e+168) {
tmp = (b * c) - (4.0 * (x * i));
} else {
tmp = (b * c) + (j * (k * -27.0));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (j * 27.0d0) * k
if (t_1 <= (-5d+87)) then
tmp = (b * c) - (27.0d0 * (j * k))
else if (t_1 <= 1d-53) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (t_1 <= 5d+168) then
tmp = (b * c) - (4.0d0 * (x * i))
else
tmp = (b * c) + (j * (k * (-27.0d0)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -5e+87) {
tmp = (b * c) - (27.0 * (j * k));
} else if (t_1 <= 1e-53) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (t_1 <= 5e+168) {
tmp = (b * c) - (4.0 * (x * i));
} else {
tmp = (b * c) + (j * (k * -27.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (j * 27.0) * k tmp = 0 if t_1 <= -5e+87: tmp = (b * c) - (27.0 * (j * k)) elif t_1 <= 1e-53: tmp = (b * c) + (-4.0 * (t * a)) elif t_1 <= 5e+168: tmp = (b * c) - (4.0 * (x * i)) else: tmp = (b * c) + (j * (k * -27.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_1 <= -5e+87) tmp = Float64(Float64(b * c) - Float64(27.0 * Float64(j * k))); elseif (t_1 <= 1e-53) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (t_1 <= 5e+168) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); else tmp = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (j * 27.0) * k;
tmp = 0.0;
if (t_1 <= -5e+87)
tmp = (b * c) - (27.0 * (j * k));
elseif (t_1 <= 1e-53)
tmp = (b * c) + (-4.0 * (t * a));
elseif (t_1 <= 5e+168)
tmp = (b * c) - (4.0 * (x * i));
else
tmp = (b * c) + (j * (k * -27.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$1, -5e+87], N[(N[(b * c), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e-53], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 5e+168], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{+87}:\\
\;\;\;\;b \cdot c - 27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;t\_1 \leq 10^{-53}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+168}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.9999999999999998e87Initial program 77.3%
Taylor expanded in t around 0 62.2%
Taylor expanded in i around 0 61.0%
if -4.9999999999999998e87 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 1.00000000000000003e-53Initial program 89.2%
Simplified87.9%
Taylor expanded in j around 0 85.2%
Taylor expanded in y around 0 85.2%
Taylor expanded in x around 0 55.7%
if 1.00000000000000003e-53 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 4.99999999999999967e168Initial program 87.1%
Taylor expanded in t around 0 71.5%
Taylor expanded in j around 0 65.8%
if 4.99999999999999967e168 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 79.9%
Simplified86.6%
Taylor expanded in b around inf 77.1%
Final simplification60.6%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (- (* b c) (* 4.0 (* x i)))))
(if (<= j -7e+136)
(+ (* b c) (* j (* k -27.0)))
(if (<= j -1.75e-105)
t_1
(if (<= j 5.2e-164)
(+ (* b c) (* -4.0 (* t a)))
(if (<= j 1.5e+43)
t_1
(if (<= j 3.9e+54)
(* 18.0 (* (* y z) (* x t)))
(* -27.0 (* j k)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) - (4.0 * (x * i));
double tmp;
if (j <= -7e+136) {
tmp = (b * c) + (j * (k * -27.0));
} else if (j <= -1.75e-105) {
tmp = t_1;
} else if (j <= 5.2e-164) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (j <= 1.5e+43) {
tmp = t_1;
} else if (j <= 3.9e+54) {
tmp = 18.0 * ((y * z) * (x * t));
} else {
tmp = -27.0 * (j * k);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (b * c) - (4.0d0 * (x * i))
if (j <= (-7d+136)) then
tmp = (b * c) + (j * (k * (-27.0d0)))
else if (j <= (-1.75d-105)) then
tmp = t_1
else if (j <= 5.2d-164) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (j <= 1.5d+43) then
tmp = t_1
else if (j <= 3.9d+54) then
tmp = 18.0d0 * ((y * z) * (x * t))
else
tmp = (-27.0d0) * (j * k)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) - (4.0 * (x * i));
double tmp;
if (j <= -7e+136) {
tmp = (b * c) + (j * (k * -27.0));
} else if (j <= -1.75e-105) {
tmp = t_1;
} else if (j <= 5.2e-164) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (j <= 1.5e+43) {
tmp = t_1;
} else if (j <= 3.9e+54) {
tmp = 18.0 * ((y * z) * (x * t));
} else {
tmp = -27.0 * (j * k);
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) - (4.0 * (x * i)) tmp = 0 if j <= -7e+136: tmp = (b * c) + (j * (k * -27.0)) elif j <= -1.75e-105: tmp = t_1 elif j <= 5.2e-164: tmp = (b * c) + (-4.0 * (t * a)) elif j <= 1.5e+43: tmp = t_1 elif j <= 3.9e+54: tmp = 18.0 * ((y * z) * (x * t)) else: tmp = -27.0 * (j * k) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) tmp = 0.0 if (j <= -7e+136) tmp = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0))); elseif (j <= -1.75e-105) tmp = t_1; elseif (j <= 5.2e-164) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (j <= 1.5e+43) tmp = t_1; elseif (j <= 3.9e+54) tmp = Float64(18.0 * Float64(Float64(y * z) * Float64(x * t))); else tmp = Float64(-27.0 * Float64(j * k)); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (b * c) - (4.0 * (x * i));
tmp = 0.0;
if (j <= -7e+136)
tmp = (b * c) + (j * (k * -27.0));
elseif (j <= -1.75e-105)
tmp = t_1;
elseif (j <= 5.2e-164)
tmp = (b * c) + (-4.0 * (t * a));
elseif (j <= 1.5e+43)
tmp = t_1;
elseif (j <= 3.9e+54)
tmp = 18.0 * ((y * z) * (x * t));
else
tmp = -27.0 * (j * k);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -7e+136], N[(N[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -1.75e-105], t$95$1, If[LessEqual[j, 5.2e-164], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1.5e+43], t$95$1, If[LessEqual[j, 3.9e+54], N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{if}\;j \leq -7 \cdot 10^{+136}:\\
\;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;j \leq -1.75 \cdot 10^{-105}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq 5.2 \cdot 10^{-164}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;j \leq 1.5 \cdot 10^{+43}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq 3.9 \cdot 10^{+54}:\\
\;\;\;\;18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\
\mathbf{else}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\end{array}
\end{array}
if j < -7.00000000000000002e136Initial program 82.7%
Simplified85.4%
Taylor expanded in b around inf 70.8%
if -7.00000000000000002e136 < j < -1.75e-105 or 5.2000000000000003e-164 < j < 1.50000000000000008e43Initial program 78.5%
Taylor expanded in t around 0 58.2%
Taylor expanded in j around 0 50.5%
if -1.75e-105 < j < 5.2000000000000003e-164Initial program 89.4%
Simplified87.2%
Taylor expanded in j around 0 84.9%
Taylor expanded in y around 0 86.0%
Taylor expanded in x around 0 61.6%
if 1.50000000000000008e43 < j < 3.9000000000000003e54Initial program 80.0%
Simplified100.0%
Taylor expanded in x around inf 80.3%
Taylor expanded in t around inf 80.3%
associate-*r*80.3%
Simplified80.3%
if 3.9000000000000003e54 < j Initial program 91.7%
Simplified88.3%
Taylor expanded in j around inf 38.8%
Final simplification55.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* b c) (* -4.0 (* t a)))) (t_2 (+ (* b c) (* j (* k -27.0)))))
(if (<= j -6.8e+55)
t_2
(if (<= j -10200.0)
(* y (* 18.0 (* t (* x z))))
(if (<= j -1.55e-43)
t_1
(if (<= j -9.5e-80)
(* x (* i -4.0))
(if (<= j 5.9e-164) t_1 t_2)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double t_2 = (b * c) + (j * (k * -27.0));
double tmp;
if (j <= -6.8e+55) {
tmp = t_2;
} else if (j <= -10200.0) {
tmp = y * (18.0 * (t * (x * z)));
} else if (j <= -1.55e-43) {
tmp = t_1;
} else if (j <= -9.5e-80) {
tmp = x * (i * -4.0);
} else if (j <= 5.9e-164) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (b * c) + ((-4.0d0) * (t * a))
t_2 = (b * c) + (j * (k * (-27.0d0)))
if (j <= (-6.8d+55)) then
tmp = t_2
else if (j <= (-10200.0d0)) then
tmp = y * (18.0d0 * (t * (x * z)))
else if (j <= (-1.55d-43)) then
tmp = t_1
else if (j <= (-9.5d-80)) then
tmp = x * (i * (-4.0d0))
else if (j <= 5.9d-164) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double t_2 = (b * c) + (j * (k * -27.0));
double tmp;
if (j <= -6.8e+55) {
tmp = t_2;
} else if (j <= -10200.0) {
tmp = y * (18.0 * (t * (x * z)));
} else if (j <= -1.55e-43) {
tmp = t_1;
} else if (j <= -9.5e-80) {
tmp = x * (i * -4.0);
} else if (j <= 5.9e-164) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) + (-4.0 * (t * a)) t_2 = (b * c) + (j * (k * -27.0)) tmp = 0 if j <= -6.8e+55: tmp = t_2 elif j <= -10200.0: tmp = y * (18.0 * (t * (x * z))) elif j <= -1.55e-43: tmp = t_1 elif j <= -9.5e-80: tmp = x * (i * -4.0) elif j <= 5.9e-164: tmp = t_1 else: tmp = t_2 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) t_2 = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0))) tmp = 0.0 if (j <= -6.8e+55) tmp = t_2; elseif (j <= -10200.0) tmp = Float64(y * Float64(18.0 * Float64(t * Float64(x * z)))); elseif (j <= -1.55e-43) tmp = t_1; elseif (j <= -9.5e-80) tmp = Float64(x * Float64(i * -4.0)); elseif (j <= 5.9e-164) tmp = t_1; else tmp = t_2; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (b * c) + (-4.0 * (t * a));
t_2 = (b * c) + (j * (k * -27.0));
tmp = 0.0;
if (j <= -6.8e+55)
tmp = t_2;
elseif (j <= -10200.0)
tmp = y * (18.0 * (t * (x * z)));
elseif (j <= -1.55e-43)
tmp = t_1;
elseif (j <= -9.5e-80)
tmp = x * (i * -4.0);
elseif (j <= 5.9e-164)
tmp = t_1;
else
tmp = t_2;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -6.8e+55], t$95$2, If[LessEqual[j, -10200.0], N[(y * N[(18.0 * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -1.55e-43], t$95$1, If[LessEqual[j, -9.5e-80], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 5.9e-164], t$95$1, t$95$2]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
t_2 := b \cdot c + j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;j \leq -6.8 \cdot 10^{+55}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;j \leq -10200:\\
\;\;\;\;y \cdot \left(18 \cdot \left(t \cdot \left(x \cdot z\right)\right)\right)\\
\mathbf{elif}\;j \leq -1.55 \cdot 10^{-43}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -9.5 \cdot 10^{-80}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\
\mathbf{elif}\;j \leq 5.9 \cdot 10^{-164}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if j < -6.7999999999999996e55 or 5.90000000000000018e-164 < j Initial program 83.2%
Simplified86.9%
Taylor expanded in b around inf 50.0%
if -6.7999999999999996e55 < j < -10200Initial program 76.8%
Simplified84.3%
Taylor expanded in x around inf 52.6%
Taylor expanded in y around inf 44.7%
Taylor expanded in i around 0 36.8%
if -10200 < j < -1.55e-43 or -9.5000000000000003e-80 < j < 5.90000000000000018e-164Initial program 89.6%
Simplified87.6%
Taylor expanded in j around 0 85.6%
Taylor expanded in y around 0 86.5%
Taylor expanded in x around 0 60.9%
if -1.55e-43 < j < -9.5000000000000003e-80Initial program 80.0%
Simplified80.0%
pow180.0%
associate-*l*79.7%
associate-*r*79.5%
Applied egg-rr79.5%
unpow179.5%
*-commutative79.5%
Simplified79.5%
Taylor expanded in i around inf 54.5%
metadata-eval54.5%
distribute-lft-neg-in54.5%
associate-*r*54.5%
*-commutative54.5%
distribute-rgt-neg-in54.5%
distribute-lft-neg-in54.5%
metadata-eval54.5%
Simplified54.5%
Final simplification53.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (<= x -2.6e+55)
(* x (- (* 4.0 (- i)) (* (* t -18.0) (* y z))))
(if (<= x -4.2e-211)
(+ (* b c) t_1)
(if (<= x 4.7e-62)
(+ (* b c) (* -4.0 (* t a)))
(if (<= x 3.1e-8)
(+ t_1 (* i (* x -4.0)))
(* x (- (* y (* z (* t (- -18.0)))) (* 4.0 i)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -2.6e+55) {
tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z)));
} else if (x <= -4.2e-211) {
tmp = (b * c) + t_1;
} else if (x <= 4.7e-62) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (x <= 3.1e-8) {
tmp = t_1 + (i * (x * -4.0));
} else {
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
if (x <= (-2.6d+55)) then
tmp = x * ((4.0d0 * -i) - ((t * (-18.0d0)) * (y * z)))
else if (x <= (-4.2d-211)) then
tmp = (b * c) + t_1
else if (x <= 4.7d-62) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (x <= 3.1d-8) then
tmp = t_1 + (i * (x * (-4.0d0)))
else
tmp = x * ((y * (z * (t * -(-18.0d0)))) - (4.0d0 * i))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -2.6e+55) {
tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z)));
} else if (x <= -4.2e-211) {
tmp = (b * c) + t_1;
} else if (x <= 4.7e-62) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (x <= 3.1e-8) {
tmp = t_1 + (i * (x * -4.0));
} else {
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) tmp = 0 if x <= -2.6e+55: tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z))) elif x <= -4.2e-211: tmp = (b * c) + t_1 elif x <= 4.7e-62: tmp = (b * c) + (-4.0 * (t * a)) elif x <= 3.1e-8: tmp = t_1 + (i * (x * -4.0)) else: tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -2.6e+55) tmp = Float64(x * Float64(Float64(4.0 * Float64(-i)) - Float64(Float64(t * -18.0) * Float64(y * z)))); elseif (x <= -4.2e-211) tmp = Float64(Float64(b * c) + t_1); elseif (x <= 4.7e-62) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (x <= 3.1e-8) tmp = Float64(t_1 + Float64(i * Float64(x * -4.0))); else tmp = Float64(x * Float64(Float64(y * Float64(z * Float64(t * Float64(-(-18.0))))) - Float64(4.0 * i))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
tmp = 0.0;
if (x <= -2.6e+55)
tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z)));
elseif (x <= -4.2e-211)
tmp = (b * c) + t_1;
elseif (x <= 4.7e-62)
tmp = (b * c) + (-4.0 * (t * a));
elseif (x <= 3.1e-8)
tmp = t_1 + (i * (x * -4.0));
else
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.6e+55], N[(x * N[(N[(4.0 * (-i)), $MachinePrecision] - N[(N[(t * -18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -4.2e-211], N[(N[(b * c), $MachinePrecision] + t$95$1), $MachinePrecision], If[LessEqual[x, 4.7e-62], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.1e-8], N[(t$95$1 + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(y * N[(z * N[(t * (--18.0)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -2.6 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(4 \cdot \left(-i\right) - \left(t \cdot -18\right) \cdot \left(y \cdot z\right)\right)\\
\mathbf{elif}\;x \leq -4.2 \cdot 10^{-211}:\\
\;\;\;\;b \cdot c + t\_1\\
\mathbf{elif}\;x \leq 4.7 \cdot 10^{-62}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 3.1 \cdot 10^{-8}:\\
\;\;\;\;t\_1 + i \cdot \left(x \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(z \cdot \left(t \cdot \left(--18\right)\right)\right) - 4 \cdot i\right)\\
\end{array}
\end{array}
if x < -2.6e55Initial program 64.6%
Simplified73.8%
pow173.8%
associate-*l*73.8%
associate-*r*73.8%
Applied egg-rr73.8%
unpow173.8%
*-commutative73.8%
Simplified73.8%
Taylor expanded in x around -inf 76.4%
associate-*r*76.4%
neg-mul-176.4%
cancel-sign-sub-inv76.4%
metadata-eval76.4%
associate-*r*76.4%
Simplified76.4%
if -2.6e55 < x < -4.20000000000000015e-211Initial program 88.6%
Simplified89.0%
Taylor expanded in b around inf 61.8%
if -4.20000000000000015e-211 < x < 4.69999999999999984e-62Initial program 98.3%
Simplified90.8%
Taylor expanded in j around 0 75.6%
Taylor expanded in y around 0 75.6%
Taylor expanded in x around 0 74.4%
if 4.69999999999999984e-62 < x < 3.1e-8Initial program 99.8%
Simplified99.9%
Taylor expanded in i around inf 74.2%
associate-*r*74.2%
*-commutative74.2%
associate-*r*74.2%
*-commutative74.2%
*-commutative74.2%
Simplified74.2%
if 3.1e-8 < x Initial program 82.6%
Simplified84.2%
pow184.2%
associate-*l*84.1%
associate-*r*84.1%
Applied egg-rr84.1%
unpow184.1%
*-commutative84.1%
Simplified84.1%
Taylor expanded in x around -inf 64.4%
associate-*r*64.4%
neg-mul-164.4%
cancel-sign-sub-inv64.4%
metadata-eval64.4%
associate-*r*64.4%
Simplified64.4%
Taylor expanded in t around 0 64.4%
associate-*r*64.4%
*-commutative64.4%
*-commutative64.4%
associate-*l*65.9%
Simplified65.9%
Final simplification69.7%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (<= x -2.15e+55)
(* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))
(if (<= x -1.62e-214)
(+ (* b c) t_1)
(if (<= x 6.4e-62)
(+ (* b c) (* -4.0 (* t a)))
(if (<= x 1.1e-7)
(+ t_1 (* i (* x -4.0)))
(* x (- (* y (* z (* t (- -18.0)))) (* 4.0 i)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -2.15e+55) {
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
} else if (x <= -1.62e-214) {
tmp = (b * c) + t_1;
} else if (x <= 6.4e-62) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (x <= 1.1e-7) {
tmp = t_1 + (i * (x * -4.0));
} else {
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
if (x <= (-2.15d+55)) then
tmp = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
else if (x <= (-1.62d-214)) then
tmp = (b * c) + t_1
else if (x <= 6.4d-62) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (x <= 1.1d-7) then
tmp = t_1 + (i * (x * (-4.0d0)))
else
tmp = x * ((y * (z * (t * -(-18.0d0)))) - (4.0d0 * i))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -2.15e+55) {
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
} else if (x <= -1.62e-214) {
tmp = (b * c) + t_1;
} else if (x <= 6.4e-62) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (x <= 1.1e-7) {
tmp = t_1 + (i * (x * -4.0));
} else {
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) tmp = 0 if x <= -2.15e+55: tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i)) elif x <= -1.62e-214: tmp = (b * c) + t_1 elif x <= 6.4e-62: tmp = (b * c) + (-4.0 * (t * a)) elif x <= 1.1e-7: tmp = t_1 + (i * (x * -4.0)) else: tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -2.15e+55) tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i))); elseif (x <= -1.62e-214) tmp = Float64(Float64(b * c) + t_1); elseif (x <= 6.4e-62) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (x <= 1.1e-7) tmp = Float64(t_1 + Float64(i * Float64(x * -4.0))); else tmp = Float64(x * Float64(Float64(y * Float64(z * Float64(t * Float64(-(-18.0))))) - Float64(4.0 * i))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
tmp = 0.0;
if (x <= -2.15e+55)
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
elseif (x <= -1.62e-214)
tmp = (b * c) + t_1;
elseif (x <= 6.4e-62)
tmp = (b * c) + (-4.0 * (t * a));
elseif (x <= 1.1e-7)
tmp = t_1 + (i * (x * -4.0));
else
tmp = x * ((y * (z * (t * -(-18.0)))) - (4.0 * i));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.15e+55], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -1.62e-214], N[(N[(b * c), $MachinePrecision] + t$95$1), $MachinePrecision], If[LessEqual[x, 6.4e-62], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.1e-7], N[(t$95$1 + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(y * N[(z * N[(t * (--18.0)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -2.15 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\
\mathbf{elif}\;x \leq -1.62 \cdot 10^{-214}:\\
\;\;\;\;b \cdot c + t\_1\\
\mathbf{elif}\;x \leq 6.4 \cdot 10^{-62}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 1.1 \cdot 10^{-7}:\\
\;\;\;\;t\_1 + i \cdot \left(x \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(z \cdot \left(t \cdot \left(--18\right)\right)\right) - 4 \cdot i\right)\\
\end{array}
\end{array}
if x < -2.1499999999999999e55Initial program 64.6%
Simplified73.8%
Taylor expanded in x around inf 76.4%
if -2.1499999999999999e55 < x < -1.62e-214Initial program 88.6%
Simplified89.0%
Taylor expanded in b around inf 61.8%
if -1.62e-214 < x < 6.40000000000000043e-62Initial program 98.3%
Simplified90.8%
Taylor expanded in j around 0 75.6%
Taylor expanded in y around 0 75.6%
Taylor expanded in x around 0 74.4%
if 6.40000000000000043e-62 < x < 1.1000000000000001e-7Initial program 99.8%
Simplified99.9%
Taylor expanded in i around inf 74.2%
associate-*r*74.2%
*-commutative74.2%
associate-*r*74.2%
*-commutative74.2%
*-commutative74.2%
Simplified74.2%
if 1.1000000000000001e-7 < x Initial program 82.6%
Simplified84.2%
pow184.2%
associate-*l*84.1%
associate-*r*84.1%
Applied egg-rr84.1%
unpow184.1%
*-commutative84.1%
Simplified84.1%
Taylor expanded in x around -inf 64.4%
associate-*r*64.4%
neg-mul-164.4%
cancel-sign-sub-inv64.4%
metadata-eval64.4%
associate-*r*64.4%
Simplified64.4%
Taylor expanded in t around 0 64.4%
associate-*r*64.4%
*-commutative64.4%
*-commutative64.4%
associate-*l*65.9%
Simplified65.9%
Final simplification69.7%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0)))
(t_2 (* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))))
(if (<= x -2.35e+55)
t_2
(if (<= x -6.2e-214)
(+ (* b c) t_1)
(if (<= x 4.2e-62)
(+ (* b c) (* -4.0 (* t a)))
(if (<= x 3.1e-8) (+ t_1 (* i (* x -4.0))) t_2))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
double tmp;
if (x <= -2.35e+55) {
tmp = t_2;
} else if (x <= -6.2e-214) {
tmp = (b * c) + t_1;
} else if (x <= 4.2e-62) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (x <= 3.1e-8) {
tmp = t_1 + (i * (x * -4.0));
} else {
tmp = t_2;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
t_2 = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
if (x <= (-2.35d+55)) then
tmp = t_2
else if (x <= (-6.2d-214)) then
tmp = (b * c) + t_1
else if (x <= 4.2d-62) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (x <= 3.1d-8) then
tmp = t_1 + (i * (x * (-4.0d0)))
else
tmp = t_2
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
double tmp;
if (x <= -2.35e+55) {
tmp = t_2;
} else if (x <= -6.2e-214) {
tmp = (b * c) + t_1;
} else if (x <= 4.2e-62) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (x <= 3.1e-8) {
tmp = t_1 + (i * (x * -4.0));
} else {
tmp = t_2;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i)) tmp = 0 if x <= -2.35e+55: tmp = t_2 elif x <= -6.2e-214: tmp = (b * c) + t_1 elif x <= 4.2e-62: tmp = (b * c) + (-4.0 * (t * a)) elif x <= 3.1e-8: tmp = t_1 + (i * (x * -4.0)) else: tmp = t_2 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) t_2 = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i))) tmp = 0.0 if (x <= -2.35e+55) tmp = t_2; elseif (x <= -6.2e-214) tmp = Float64(Float64(b * c) + t_1); elseif (x <= 4.2e-62) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (x <= 3.1e-8) tmp = Float64(t_1 + Float64(i * Float64(x * -4.0))); else tmp = t_2; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
tmp = 0.0;
if (x <= -2.35e+55)
tmp = t_2;
elseif (x <= -6.2e-214)
tmp = (b * c) + t_1;
elseif (x <= 4.2e-62)
tmp = (b * c) + (-4.0 * (t * a));
elseif (x <= 3.1e-8)
tmp = t_1 + (i * (x * -4.0));
else
tmp = t_2;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.35e+55], t$95$2, If[LessEqual[x, -6.2e-214], N[(N[(b * c), $MachinePrecision] + t$95$1), $MachinePrecision], If[LessEqual[x, 4.2e-62], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.1e-8], N[(t$95$1 + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
t_2 := x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\
\mathbf{if}\;x \leq -2.35 \cdot 10^{+55}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -6.2 \cdot 10^{-214}:\\
\;\;\;\;b \cdot c + t\_1\\
\mathbf{elif}\;x \leq 4.2 \cdot 10^{-62}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 3.1 \cdot 10^{-8}:\\
\;\;\;\;t\_1 + i \cdot \left(x \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if x < -2.35e55 or 3.1e-8 < x Initial program 74.4%
Simplified79.4%
Taylor expanded in x around inf 69.9%
if -2.35e55 < x < -6.20000000000000008e-214Initial program 88.6%
Simplified89.0%
Taylor expanded in b around inf 61.8%
if -6.20000000000000008e-214 < x < 4.1999999999999998e-62Initial program 98.3%
Simplified90.8%
Taylor expanded in j around 0 75.6%
Taylor expanded in y around 0 75.6%
Taylor expanded in x around 0 74.4%
if 4.1999999999999998e-62 < x < 3.1e-8Initial program 99.8%
Simplified99.9%
Taylor expanded in i around inf 74.2%
associate-*r*74.2%
*-commutative74.2%
associate-*r*74.2%
*-commutative74.2%
*-commutative74.2%
Simplified74.2%
Final simplification69.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* -4.0 (* t a))))
(if (<= (* b c) -2.2e+25)
(* b c)
(if (<= (* b c) -4.6e-263)
t_1
(if (<= (* b c) 4.2e-248)
(* j (* k -27.0))
(if (<= (* b c) 4e+135) t_1 (* b c)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (t * a);
double tmp;
if ((b * c) <= -2.2e+25) {
tmp = b * c;
} else if ((b * c) <= -4.6e-263) {
tmp = t_1;
} else if ((b * c) <= 4.2e-248) {
tmp = j * (k * -27.0);
} else if ((b * c) <= 4e+135) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (t * a)
if ((b * c) <= (-2.2d+25)) then
tmp = b * c
else if ((b * c) <= (-4.6d-263)) then
tmp = t_1
else if ((b * c) <= 4.2d-248) then
tmp = j * (k * (-27.0d0))
else if ((b * c) <= 4d+135) then
tmp = t_1
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (t * a);
double tmp;
if ((b * c) <= -2.2e+25) {
tmp = b * c;
} else if ((b * c) <= -4.6e-263) {
tmp = t_1;
} else if ((b * c) <= 4.2e-248) {
tmp = j * (k * -27.0);
} else if ((b * c) <= 4e+135) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (t * a) tmp = 0 if (b * c) <= -2.2e+25: tmp = b * c elif (b * c) <= -4.6e-263: tmp = t_1 elif (b * c) <= 4.2e-248: tmp = j * (k * -27.0) elif (b * c) <= 4e+135: tmp = t_1 else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(t * a)) tmp = 0.0 if (Float64(b * c) <= -2.2e+25) tmp = Float64(b * c); elseif (Float64(b * c) <= -4.6e-263) tmp = t_1; elseif (Float64(b * c) <= 4.2e-248) tmp = Float64(j * Float64(k * -27.0)); elseif (Float64(b * c) <= 4e+135) tmp = t_1; else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = -4.0 * (t * a);
tmp = 0.0;
if ((b * c) <= -2.2e+25)
tmp = b * c;
elseif ((b * c) <= -4.6e-263)
tmp = t_1;
elseif ((b * c) <= 4.2e-248)
tmp = j * (k * -27.0);
elseif ((b * c) <= 4e+135)
tmp = t_1;
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -2.2e+25], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -4.6e-263], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 4.2e-248], N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 4e+135], t$95$1, N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;b \cdot c \leq -2.2 \cdot 10^{+25}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -4.6 \cdot 10^{-263}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq 4.2 \cdot 10^{-248}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;b \cdot c \leq 4 \cdot 10^{+135}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -2.2000000000000001e25 or 3.99999999999999985e135 < (*.f64 b c) Initial program 80.3%
Simplified81.3%
pow181.3%
associate-*l*81.3%
associate-*r*81.3%
Applied egg-rr81.3%
unpow181.3%
*-commutative81.3%
Simplified81.3%
Taylor expanded in b around inf 60.0%
if -2.2000000000000001e25 < (*.f64 b c) < -4.60000000000000006e-263 or 4.2e-248 < (*.f64 b c) < 3.99999999999999985e135Initial program 87.8%
Simplified89.0%
Taylor expanded in j around 0 79.1%
Taylor expanded in y around 0 77.3%
Taylor expanded in a around inf 29.6%
*-commutative29.6%
Simplified29.6%
if -4.60000000000000006e-263 < (*.f64 b c) < 4.2e-248Initial program 89.1%
Simplified86.9%
pow186.9%
associate-*l*86.9%
associate-*r*86.9%
Applied egg-rr86.9%
unpow186.9%
*-commutative86.9%
Simplified86.9%
Taylor expanded in j around inf 35.0%
*-commutative35.0%
associate-*r*35.0%
Simplified35.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* -4.0 (* t a))))
(if (<= (* b c) -9.4e+20)
(* b c)
(if (<= (* b c) -3e-272)
t_1
(if (<= (* b c) 3.6e-245)
(* -27.0 (* j k))
(if (<= (* b c) 8.5e+134) t_1 (* b c)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (t * a);
double tmp;
if ((b * c) <= -9.4e+20) {
tmp = b * c;
} else if ((b * c) <= -3e-272) {
tmp = t_1;
} else if ((b * c) <= 3.6e-245) {
tmp = -27.0 * (j * k);
} else if ((b * c) <= 8.5e+134) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (t * a)
if ((b * c) <= (-9.4d+20)) then
tmp = b * c
else if ((b * c) <= (-3d-272)) then
tmp = t_1
else if ((b * c) <= 3.6d-245) then
tmp = (-27.0d0) * (j * k)
else if ((b * c) <= 8.5d+134) then
tmp = t_1
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (t * a);
double tmp;
if ((b * c) <= -9.4e+20) {
tmp = b * c;
} else if ((b * c) <= -3e-272) {
tmp = t_1;
} else if ((b * c) <= 3.6e-245) {
tmp = -27.0 * (j * k);
} else if ((b * c) <= 8.5e+134) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (t * a) tmp = 0 if (b * c) <= -9.4e+20: tmp = b * c elif (b * c) <= -3e-272: tmp = t_1 elif (b * c) <= 3.6e-245: tmp = -27.0 * (j * k) elif (b * c) <= 8.5e+134: tmp = t_1 else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(t * a)) tmp = 0.0 if (Float64(b * c) <= -9.4e+20) tmp = Float64(b * c); elseif (Float64(b * c) <= -3e-272) tmp = t_1; elseif (Float64(b * c) <= 3.6e-245) tmp = Float64(-27.0 * Float64(j * k)); elseif (Float64(b * c) <= 8.5e+134) tmp = t_1; else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = -4.0 * (t * a);
tmp = 0.0;
if ((b * c) <= -9.4e+20)
tmp = b * c;
elseif ((b * c) <= -3e-272)
tmp = t_1;
elseif ((b * c) <= 3.6e-245)
tmp = -27.0 * (j * k);
elseif ((b * c) <= 8.5e+134)
tmp = t_1;
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -9.4e+20], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -3e-272], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 3.6e-245], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 8.5e+134], t$95$1, N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;b \cdot c \leq -9.4 \cdot 10^{+20}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -3 \cdot 10^{-272}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{-245}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;b \cdot c \leq 8.5 \cdot 10^{+134}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -9.4e20 or 8.50000000000000024e134 < (*.f64 b c) Initial program 80.3%
Simplified81.3%
pow181.3%
associate-*l*81.3%
associate-*r*81.3%
Applied egg-rr81.3%
unpow181.3%
*-commutative81.3%
Simplified81.3%
Taylor expanded in b around inf 60.0%
if -9.4e20 < (*.f64 b c) < -3.0000000000000003e-272 or 3.59999999999999999e-245 < (*.f64 b c) < 8.50000000000000024e134Initial program 87.8%
Simplified89.0%
Taylor expanded in j around 0 79.1%
Taylor expanded in y around 0 77.3%
Taylor expanded in a around inf 29.6%
*-commutative29.6%
Simplified29.6%
if -3.0000000000000003e-272 < (*.f64 b c) < 3.59999999999999999e-245Initial program 89.1%
Simplified89.1%
Taylor expanded in j around inf 35.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (if (or (<= t -8.8e-29) (not (<= t 40000.0))) (- (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0)))) (* 4.0 (* x i))) (- (- (* b c) (* 4.0 (+ (* t a) (* x i)))) (* (* j 27.0) k))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -8.8e-29) || !(t <= 40000.0)) {
tmp = ((b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))) - (4.0 * (x * i));
} else {
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((t <= (-8.8d-29)) .or. (.not. (t <= 40000.0d0))) then
tmp = ((b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))) - (4.0d0 * (x * i))
else
tmp = ((b * c) - (4.0d0 * ((t * a) + (x * i)))) - ((j * 27.0d0) * k)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -8.8e-29) || !(t <= 40000.0)) {
tmp = ((b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))) - (4.0 * (x * i));
} else {
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (t <= -8.8e-29) or not (t <= 40000.0): tmp = ((b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))) - (4.0 * (x * i)) else: tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((t <= -8.8e-29) || !(t <= 40000.0)) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0)))) - Float64(4.0 * Float64(x * i))); else tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i)))) - Float64(Float64(j * 27.0) * k)); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((t <= -8.8e-29) || ~((t <= 40000.0)))
tmp = ((b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))) - (4.0 * (x * i));
else
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -8.8e-29], N[Not[LessEqual[t, 40000.0]], $MachinePrecision]], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.8 \cdot 10^{-29} \lor \neg \left(t \leq 40000\right):\\
\;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\right) - 4 \cdot \left(x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\
\end{array}
\end{array}
if t < -8.79999999999999961e-29 or 4e4 < t Initial program 86.6%
Simplified89.1%
Taylor expanded in j around 0 86.6%
if -8.79999999999999961e-29 < t < 4e4Initial program 83.8%
Taylor expanded in y around 0 85.4%
distribute-lft-out85.4%
*-commutative85.4%
Simplified85.4%
Final simplification86.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= t_1 -1e+76)
(- (* b c) (* 27.0 (* j k)))
(if (<= t_1 4e+195)
(- (+ (* b c) (* -4.0 (* t a))) (* 4.0 (* x i)))
(+ (* j (* k -27.0)) (* i (* x -4.0)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -1e+76) {
tmp = (b * c) - (27.0 * (j * k));
} else if (t_1 <= 4e+195) {
tmp = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i));
} else {
tmp = (j * (k * -27.0)) + (i * (x * -4.0));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (j * 27.0d0) * k
if (t_1 <= (-1d+76)) then
tmp = (b * c) - (27.0d0 * (j * k))
else if (t_1 <= 4d+195) then
tmp = ((b * c) + ((-4.0d0) * (t * a))) - (4.0d0 * (x * i))
else
tmp = (j * (k * (-27.0d0))) + (i * (x * (-4.0d0)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -1e+76) {
tmp = (b * c) - (27.0 * (j * k));
} else if (t_1 <= 4e+195) {
tmp = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i));
} else {
tmp = (j * (k * -27.0)) + (i * (x * -4.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (j * 27.0) * k tmp = 0 if t_1 <= -1e+76: tmp = (b * c) - (27.0 * (j * k)) elif t_1 <= 4e+195: tmp = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i)) else: tmp = (j * (k * -27.0)) + (i * (x * -4.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_1 <= -1e+76) tmp = Float64(Float64(b * c) - Float64(27.0 * Float64(j * k))); elseif (t_1 <= 4e+195) tmp = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - Float64(4.0 * Float64(x * i))); else tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(i * Float64(x * -4.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (j * 27.0) * k;
tmp = 0.0;
if (t_1 <= -1e+76)
tmp = (b * c) - (27.0 * (j * k));
elseif (t_1 <= 4e+195)
tmp = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i));
else
tmp = (j * (k * -27.0)) + (i * (x * -4.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$1, -1e+76], N[(N[(b * c), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 4e+195], N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -1 \cdot 10^{+76}:\\
\;\;\;\;b \cdot c - 27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+195}:\\
\;\;\;\;\left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - 4 \cdot \left(x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + i \cdot \left(x \cdot -4\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -1e76Initial program 76.0%
Taylor expanded in t around 0 61.1%
Taylor expanded in i around 0 60.0%
if -1e76 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 3.99999999999999991e195Initial program 89.1%
Simplified88.6%
Taylor expanded in j around 0 84.8%
Taylor expanded in y around 0 73.9%
if 3.99999999999999991e195 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 79.9%
Simplified87.9%
Taylor expanded in i around inf 80.5%
associate-*r*80.5%
*-commutative80.5%
associate-*r*80.5%
*-commutative80.5%
*-commutative80.5%
Simplified80.5%
Final simplification71.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* b c) (* -4.0 (* t a)))))
(if (<= x -5.8e+55)
(+ (* x (+ (* 18.0 (* t (* y z))) (* i -4.0))) (* j (* k -27.0)))
(if (<= x 3.4e-9)
(- t_1 (* 27.0 (* j k)))
(if (<= x 4.2e+145)
(- t_1 (* 4.0 (* x i)))
(* x (* z (+ (* -4.0 (/ i z)) (* 18.0 (* y t))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (x <= -5.8e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 3.4e-9) {
tmp = t_1 - (27.0 * (j * k));
} else if (x <= 4.2e+145) {
tmp = t_1 - (4.0 * (x * i));
} else {
tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t))));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (b * c) + ((-4.0d0) * (t * a))
if (x <= (-5.8d+55)) then
tmp = (x * ((18.0d0 * (t * (y * z))) + (i * (-4.0d0)))) + (j * (k * (-27.0d0)))
else if (x <= 3.4d-9) then
tmp = t_1 - (27.0d0 * (j * k))
else if (x <= 4.2d+145) then
tmp = t_1 - (4.0d0 * (x * i))
else
tmp = x * (z * (((-4.0d0) * (i / z)) + (18.0d0 * (y * t))))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (x <= -5.8e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 3.4e-9) {
tmp = t_1 - (27.0 * (j * k));
} else if (x <= 4.2e+145) {
tmp = t_1 - (4.0 * (x * i));
} else {
tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t))));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) + (-4.0 * (t * a)) tmp = 0 if x <= -5.8e+55: tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0)) elif x <= 3.4e-9: tmp = t_1 - (27.0 * (j * k)) elif x <= 4.2e+145: tmp = t_1 - (4.0 * (x * i)) else: tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t)))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (x <= -5.8e+55) tmp = Float64(Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) + Float64(i * -4.0))) + Float64(j * Float64(k * -27.0))); elseif (x <= 3.4e-9) tmp = Float64(t_1 - Float64(27.0 * Float64(j * k))); elseif (x <= 4.2e+145) tmp = Float64(t_1 - Float64(4.0 * Float64(x * i))); else tmp = Float64(x * Float64(z * Float64(Float64(-4.0 * Float64(i / z)) + Float64(18.0 * Float64(y * t))))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (b * c) + (-4.0 * (t * a));
tmp = 0.0;
if (x <= -5.8e+55)
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
elseif (x <= 3.4e-9)
tmp = t_1 - (27.0 * (j * k));
elseif (x <= 4.2e+145)
tmp = t_1 - (4.0 * (x * i));
else
tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t))));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.8e+55], N[(N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.4e-9], N[(t$95$1 - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 4.2e+145], N[(t$95$1 - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(z * N[(N[(-4.0 * N[(i / z), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;x \leq -5.8 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + i \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;x \leq 3.4 \cdot 10^{-9}:\\
\;\;\;\;t\_1 - 27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;x \leq 4.2 \cdot 10^{+145}:\\
\;\;\;\;t\_1 - 4 \cdot \left(x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(z \cdot \left(-4 \cdot \frac{i}{z} + 18 \cdot \left(y \cdot t\right)\right)\right)\\
\end{array}
\end{array}
if x < -5.7999999999999997e55Initial program 64.6%
Simplified79.5%
Taylor expanded in x around inf 76.9%
if -5.7999999999999997e55 < x < 3.3999999999999998e-9Initial program 94.2%
Simplified91.0%
Taylor expanded in x around 0 80.6%
if 3.3999999999999998e-9 < x < 4.19999999999999979e145Initial program 96.4%
Simplified96.4%
Taylor expanded in j around 0 96.4%
Taylor expanded in y around 0 79.4%
if 4.19999999999999979e145 < x Initial program 71.5%
Simplified74.4%
Taylor expanded in x around inf 71.9%
Taylor expanded in z around inf 74.6%
Final simplification78.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* b c) (* -4.0 (* t a)))))
(if (<= x -6e+55)
(* x (- (* 4.0 (- i)) (* (* t -18.0) (* y z))))
(if (<= x 3.6e-7)
(- t_1 (* 27.0 (* j k)))
(if (<= x 3.7e+141)
(- t_1 (* 4.0 (* x i)))
(* x (* z (+ (* -4.0 (/ i z)) (* 18.0 (* y t))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (x <= -6e+55) {
tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z)));
} else if (x <= 3.6e-7) {
tmp = t_1 - (27.0 * (j * k));
} else if (x <= 3.7e+141) {
tmp = t_1 - (4.0 * (x * i));
} else {
tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t))));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (b * c) + ((-4.0d0) * (t * a))
if (x <= (-6d+55)) then
tmp = x * ((4.0d0 * -i) - ((t * (-18.0d0)) * (y * z)))
else if (x <= 3.6d-7) then
tmp = t_1 - (27.0d0 * (j * k))
else if (x <= 3.7d+141) then
tmp = t_1 - (4.0d0 * (x * i))
else
tmp = x * (z * (((-4.0d0) * (i / z)) + (18.0d0 * (y * t))))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (x <= -6e+55) {
tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z)));
} else if (x <= 3.6e-7) {
tmp = t_1 - (27.0 * (j * k));
} else if (x <= 3.7e+141) {
tmp = t_1 - (4.0 * (x * i));
} else {
tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t))));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) + (-4.0 * (t * a)) tmp = 0 if x <= -6e+55: tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z))) elif x <= 3.6e-7: tmp = t_1 - (27.0 * (j * k)) elif x <= 3.7e+141: tmp = t_1 - (4.0 * (x * i)) else: tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t)))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (x <= -6e+55) tmp = Float64(x * Float64(Float64(4.0 * Float64(-i)) - Float64(Float64(t * -18.0) * Float64(y * z)))); elseif (x <= 3.6e-7) tmp = Float64(t_1 - Float64(27.0 * Float64(j * k))); elseif (x <= 3.7e+141) tmp = Float64(t_1 - Float64(4.0 * Float64(x * i))); else tmp = Float64(x * Float64(z * Float64(Float64(-4.0 * Float64(i / z)) + Float64(18.0 * Float64(y * t))))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (b * c) + (-4.0 * (t * a));
tmp = 0.0;
if (x <= -6e+55)
tmp = x * ((4.0 * -i) - ((t * -18.0) * (y * z)));
elseif (x <= 3.6e-7)
tmp = t_1 - (27.0 * (j * k));
elseif (x <= 3.7e+141)
tmp = t_1 - (4.0 * (x * i));
else
tmp = x * (z * ((-4.0 * (i / z)) + (18.0 * (y * t))));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6e+55], N[(x * N[(N[(4.0 * (-i)), $MachinePrecision] - N[(N[(t * -18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.6e-7], N[(t$95$1 - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.7e+141], N[(t$95$1 - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(z * N[(N[(-4.0 * N[(i / z), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;x \leq -6 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(4 \cdot \left(-i\right) - \left(t \cdot -18\right) \cdot \left(y \cdot z\right)\right)\\
\mathbf{elif}\;x \leq 3.6 \cdot 10^{-7}:\\
\;\;\;\;t\_1 - 27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;x \leq 3.7 \cdot 10^{+141}:\\
\;\;\;\;t\_1 - 4 \cdot \left(x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(z \cdot \left(-4 \cdot \frac{i}{z} + 18 \cdot \left(y \cdot t\right)\right)\right)\\
\end{array}
\end{array}
if x < -6.00000000000000033e55Initial program 64.6%
Simplified73.8%
pow173.8%
associate-*l*73.8%
associate-*r*73.8%
Applied egg-rr73.8%
unpow173.8%
*-commutative73.8%
Simplified73.8%
Taylor expanded in x around -inf 76.4%
associate-*r*76.4%
neg-mul-176.4%
cancel-sign-sub-inv76.4%
metadata-eval76.4%
associate-*r*76.4%
Simplified76.4%
if -6.00000000000000033e55 < x < 3.59999999999999994e-7Initial program 94.2%
Simplified91.0%
Taylor expanded in x around 0 80.6%
if 3.59999999999999994e-7 < x < 3.7000000000000003e141Initial program 96.4%
Simplified96.4%
Taylor expanded in j around 0 96.4%
Taylor expanded in y around 0 79.4%
if 3.7000000000000003e141 < x Initial program 71.5%
Simplified74.4%
Taylor expanded in x around inf 71.9%
Taylor expanded in z around inf 74.6%
Final simplification78.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* b c) (* -4.0 (* t a)))))
(if (<= z -3.4e-93)
(* x (* t (* 18.0 (* y z))))
(if (<= z -5.8e-174)
t_1
(if (<= z -5.5e-232)
(* x (* i -4.0))
(if (<= z 8e+200) t_1 (* 18.0 (* (* y z) (* x t)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (z <= -3.4e-93) {
tmp = x * (t * (18.0 * (y * z)));
} else if (z <= -5.8e-174) {
tmp = t_1;
} else if (z <= -5.5e-232) {
tmp = x * (i * -4.0);
} else if (z <= 8e+200) {
tmp = t_1;
} else {
tmp = 18.0 * ((y * z) * (x * t));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (b * c) + ((-4.0d0) * (t * a))
if (z <= (-3.4d-93)) then
tmp = x * (t * (18.0d0 * (y * z)))
else if (z <= (-5.8d-174)) then
tmp = t_1
else if (z <= (-5.5d-232)) then
tmp = x * (i * (-4.0d0))
else if (z <= 8d+200) then
tmp = t_1
else
tmp = 18.0d0 * ((y * z) * (x * t))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (z <= -3.4e-93) {
tmp = x * (t * (18.0 * (y * z)));
} else if (z <= -5.8e-174) {
tmp = t_1;
} else if (z <= -5.5e-232) {
tmp = x * (i * -4.0);
} else if (z <= 8e+200) {
tmp = t_1;
} else {
tmp = 18.0 * ((y * z) * (x * t));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) + (-4.0 * (t * a)) tmp = 0 if z <= -3.4e-93: tmp = x * (t * (18.0 * (y * z))) elif z <= -5.8e-174: tmp = t_1 elif z <= -5.5e-232: tmp = x * (i * -4.0) elif z <= 8e+200: tmp = t_1 else: tmp = 18.0 * ((y * z) * (x * t)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (z <= -3.4e-93) tmp = Float64(x * Float64(t * Float64(18.0 * Float64(y * z)))); elseif (z <= -5.8e-174) tmp = t_1; elseif (z <= -5.5e-232) tmp = Float64(x * Float64(i * -4.0)); elseif (z <= 8e+200) tmp = t_1; else tmp = Float64(18.0 * Float64(Float64(y * z) * Float64(x * t))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (b * c) + (-4.0 * (t * a));
tmp = 0.0;
if (z <= -3.4e-93)
tmp = x * (t * (18.0 * (y * z)));
elseif (z <= -5.8e-174)
tmp = t_1;
elseif (z <= -5.5e-232)
tmp = x * (i * -4.0);
elseif (z <= 8e+200)
tmp = t_1;
else
tmp = 18.0 * ((y * z) * (x * t));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.4e-93], N[(x * N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5.8e-174], t$95$1, If[LessEqual[z, -5.5e-232], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8e+200], t$95$1, N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;z \leq -3.4 \cdot 10^{-93}:\\
\;\;\;\;x \cdot \left(t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{elif}\;z \leq -5.8 \cdot 10^{-174}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -5.5 \cdot 10^{-232}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+200}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -3.40000000000000001e-93Initial program 85.5%
Simplified83.4%
Taylor expanded in x around inf 53.7%
Taylor expanded in t around inf 39.8%
*-commutative39.8%
associate-*l*39.8%
*-commutative39.8%
Simplified39.8%
if -3.40000000000000001e-93 < z < -5.8000000000000002e-174 or -5.50000000000000023e-232 < z < 7.9999999999999998e200Initial program 86.3%
Simplified87.9%
Taylor expanded in j around 0 76.2%
Taylor expanded in y around 0 76.9%
Taylor expanded in x around 0 54.1%
if -5.8000000000000002e-174 < z < -5.50000000000000023e-232Initial program 93.1%
Simplified99.8%
pow199.8%
associate-*l*99.8%
associate-*r*99.8%
Applied egg-rr99.8%
unpow199.8%
*-commutative99.8%
Simplified99.8%
Taylor expanded in i around inf 37.1%
metadata-eval37.1%
distribute-lft-neg-in37.1%
associate-*r*37.1%
*-commutative37.1%
distribute-rgt-neg-in37.1%
distribute-lft-neg-in37.1%
metadata-eval37.1%
Simplified37.1%
if 7.9999999999999998e200 < z Initial program 71.7%
Simplified73.0%
Taylor expanded in x around inf 78.3%
Taylor expanded in t around inf 66.4%
associate-*r*70.8%
Simplified70.8%
Final simplification49.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= x -2.5e+55)
(+ (* x (+ (* 18.0 (* t (* y z))) (* i -4.0))) (* j (* k -27.0)))
(if (<= x 1.1e+135)
(- (- (* b c) (* 4.0 (+ (* t a) (* x i)))) (* (* j 27.0) k))
(- (+ (* b c) (* 18.0 (* t (* x (* y z))))) (* 4.0 (* x i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -2.5e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 1.1e+135) {
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
} else {
tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (x <= (-2.5d+55)) then
tmp = (x * ((18.0d0 * (t * (y * z))) + (i * (-4.0d0)))) + (j * (k * (-27.0d0)))
else if (x <= 1.1d+135) then
tmp = ((b * c) - (4.0d0 * ((t * a) + (x * i)))) - ((j * 27.0d0) * k)
else
tmp = ((b * c) + (18.0d0 * (t * (x * (y * z))))) - (4.0d0 * (x * i))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -2.5e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 1.1e+135) {
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
} else {
tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if x <= -2.5e+55: tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0)) elif x <= 1.1e+135: tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k) else: tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (x <= -2.5e+55) tmp = Float64(Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) + Float64(i * -4.0))) + Float64(j * Float64(k * -27.0))); elseif (x <= 1.1e+135) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i)))) - Float64(Float64(j * 27.0) * k)); else tmp = Float64(Float64(Float64(b * c) + Float64(18.0 * Float64(t * Float64(x * Float64(y * z))))) - Float64(4.0 * Float64(x * i))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (x <= -2.5e+55)
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
elseif (x <= 1.1e+135)
tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
else
tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[x, -2.5e+55], N[(N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.1e+135], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.5 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + i \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;x \leq 1.1 \cdot 10^{+135}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + 18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\right) - 4 \cdot \left(x \cdot i\right)\\
\end{array}
\end{array}
if x < -2.50000000000000023e55Initial program 64.6%
Simplified79.5%
Taylor expanded in x around inf 76.9%
if -2.50000000000000023e55 < x < 1.1e135Initial program 94.4%
Taylor expanded in y around 0 86.7%
distribute-lft-out86.7%
*-commutative86.7%
Simplified86.7%
if 1.1e135 < x Initial program 75.1%
Simplified77.6%
Taylor expanded in j around 0 80.2%
Taylor expanded in a around 0 77.8%
Final simplification83.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= x -2.1e+55)
(+ (* x (+ (* 18.0 (* t (* y z))) (* i -4.0))) (* j (* k -27.0)))
(if (<= x 1.4e-7)
(- (+ (* b c) (* -4.0 (* t a))) (* 27.0 (* j k)))
(- (+ (* b c) (* 18.0 (* t (* x (* y z))))) (* 4.0 (* x i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -2.1e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 1.4e-7) {
tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k));
} else {
tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (x <= (-2.1d+55)) then
tmp = (x * ((18.0d0 * (t * (y * z))) + (i * (-4.0d0)))) + (j * (k * (-27.0d0)))
else if (x <= 1.4d-7) then
tmp = ((b * c) + ((-4.0d0) * (t * a))) - (27.0d0 * (j * k))
else
tmp = ((b * c) + (18.0d0 * (t * (x * (y * z))))) - (4.0d0 * (x * i))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -2.1e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 1.4e-7) {
tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k));
} else {
tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if x <= -2.1e+55: tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0)) elif x <= 1.4e-7: tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k)) else: tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (x <= -2.1e+55) tmp = Float64(Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) + Float64(i * -4.0))) + Float64(j * Float64(k * -27.0))); elseif (x <= 1.4e-7) tmp = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - Float64(27.0 * Float64(j * k))); else tmp = Float64(Float64(Float64(b * c) + Float64(18.0 * Float64(t * Float64(x * Float64(y * z))))) - Float64(4.0 * Float64(x * i))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (x <= -2.1e+55)
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
elseif (x <= 1.4e-7)
tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k));
else
tmp = ((b * c) + (18.0 * (t * (x * (y * z))))) - (4.0 * (x * i));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[x, -2.1e+55], N[(N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.4e-7], N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.1 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + i \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;x \leq 1.4 \cdot 10^{-7}:\\
\;\;\;\;\left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - 27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + 18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\right) - 4 \cdot \left(x \cdot i\right)\\
\end{array}
\end{array}
if x < -2.1000000000000001e55Initial program 64.6%
Simplified79.5%
Taylor expanded in x around inf 76.9%
if -2.1000000000000001e55 < x < 1.4000000000000001e-7Initial program 94.2%
Simplified91.0%
Taylor expanded in x around 0 80.6%
if 1.4000000000000001e-7 < x Initial program 82.6%
Simplified84.2%
Taylor expanded in j around 0 85.9%
Taylor expanded in a around 0 74.9%
Final simplification78.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= x -4.3e+55)
(+ (* x (+ (* 18.0 (* t (* y z))) (* i -4.0))) (* j (* k -27.0)))
(if (<= x 160.0)
(- (+ (* b c) (* -4.0 (* t a))) (* 27.0 (* j k)))
(- (* t (- (* 18.0 (* x (* y z))) (* a 4.0))) (* 4.0 (* x i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -4.3e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 160.0) {
tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k));
} else {
tmp = (t * ((18.0 * (x * (y * z))) - (a * 4.0))) - (4.0 * (x * i));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (x <= (-4.3d+55)) then
tmp = (x * ((18.0d0 * (t * (y * z))) + (i * (-4.0d0)))) + (j * (k * (-27.0d0)))
else if (x <= 160.0d0) then
tmp = ((b * c) + ((-4.0d0) * (t * a))) - (27.0d0 * (j * k))
else
tmp = (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))) - (4.0d0 * (x * i))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -4.3e+55) {
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
} else if (x <= 160.0) {
tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k));
} else {
tmp = (t * ((18.0 * (x * (y * z))) - (a * 4.0))) - (4.0 * (x * i));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if x <= -4.3e+55: tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0)) elif x <= 160.0: tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k)) else: tmp = (t * ((18.0 * (x * (y * z))) - (a * 4.0))) - (4.0 * (x * i)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (x <= -4.3e+55) tmp = Float64(Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) + Float64(i * -4.0))) + Float64(j * Float64(k * -27.0))); elseif (x <= 160.0) tmp = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - Float64(27.0 * Float64(j * k))); else tmp = Float64(Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))) - Float64(4.0 * Float64(x * i))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (x <= -4.3e+55)
tmp = (x * ((18.0 * (t * (y * z))) + (i * -4.0))) + (j * (k * -27.0));
elseif (x <= 160.0)
tmp = ((b * c) + (-4.0 * (t * a))) - (27.0 * (j * k));
else
tmp = (t * ((18.0 * (x * (y * z))) - (a * 4.0))) - (4.0 * (x * i));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[x, -4.3e+55], N[(N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 160.0], N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -4.3 \cdot 10^{+55}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + i \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;x \leq 160:\\
\;\;\;\;\left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - 27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right) - 4 \cdot \left(x \cdot i\right)\\
\end{array}
\end{array}
if x < -4.2999999999999999e55Initial program 64.6%
Simplified79.5%
Taylor expanded in x around inf 76.9%
if -4.2999999999999999e55 < x < 160Initial program 94.2%
Simplified91.0%
Taylor expanded in x around 0 80.4%
if 160 < x Initial program 82.3%
Simplified83.9%
Taylor expanded in j around 0 85.6%
Taylor expanded in b around 0 74.7%
Final simplification78.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (if (or (<= (* b c) -8e-45) (not (<= (* b c) 3.1e+125))) (* b c) (* -27.0 (* j k))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (((b * c) <= -8e-45) || !((b * c) <= 3.1e+125)) {
tmp = b * c;
} else {
tmp = -27.0 * (j * k);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (((b * c) <= (-8d-45)) .or. (.not. ((b * c) <= 3.1d+125))) then
tmp = b * c
else
tmp = (-27.0d0) * (j * k)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (((b * c) <= -8e-45) || !((b * c) <= 3.1e+125)) {
tmp = b * c;
} else {
tmp = -27.0 * (j * k);
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if ((b * c) <= -8e-45) or not ((b * c) <= 3.1e+125): tmp = b * c else: tmp = -27.0 * (j * k) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((Float64(b * c) <= -8e-45) || !(Float64(b * c) <= 3.1e+125)) tmp = Float64(b * c); else tmp = Float64(-27.0 * Float64(j * k)); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (((b * c) <= -8e-45) || ~(((b * c) <= 3.1e+125)))
tmp = b * c;
else
tmp = -27.0 * (j * k);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -8e-45], N[Not[LessEqual[N[(b * c), $MachinePrecision], 3.1e+125]], $MachinePrecision]], N[(b * c), $MachinePrecision], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -8 \cdot 10^{-45} \lor \neg \left(b \cdot c \leq 3.1 \cdot 10^{+125}\right):\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -7.99999999999999987e-45 or 3.1e125 < (*.f64 b c) Initial program 81.8%
Simplified81.9%
pow181.9%
associate-*l*81.9%
associate-*r*81.8%
Applied egg-rr81.8%
unpow181.8%
*-commutative81.8%
Simplified81.8%
Taylor expanded in b around inf 57.0%
if -7.99999999999999987e-45 < (*.f64 b c) < 3.1e125Initial program 87.5%
Simplified89.7%
Taylor expanded in j around inf 25.1%
Final simplification38.1%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (* b c))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = b * c
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): return b * c
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) return Float64(b * c) end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp = code(x, y, z, t, a, b, c, i, j, k)
tmp = b * c;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(b * c), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
b \cdot c
\end{array}
Initial program 85.2%
Simplified85.7%
pow185.7%
associate-*l*85.7%
associate-*r*85.7%
Applied egg-rr85.7%
unpow185.7%
*-commutative85.7%
Simplified85.7%
Taylor expanded in b around inf 26.3%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (+ (* a t) (* i x)) 4.0))
(t_2
(-
(- (* (* 18.0 t) (* (* x y) z)) t_1)
(- (* (* k j) 27.0) (* c b)))))
(if (< t -1.6210815397541398e-69)
t_2
(if (< t 165.68027943805222)
(+ (- (* (* 18.0 y) (* x (* z t))) t_1) (- (* c b) (* 27.0 (* k j))))
t_2))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = ((a * t) + (i * x)) * 4.0;
double t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
double tmp;
if (t < -1.6210815397541398e-69) {
tmp = t_2;
} else if (t < 165.68027943805222) {
tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
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), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = ((a * t) + (i * x)) * 4.0d0
t_2 = (((18.0d0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0d0) - (c * b))
if (t < (-1.6210815397541398d-69)) then
tmp = t_2
else if (t < 165.68027943805222d0) then
tmp = (((18.0d0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0d0 * (k * j)))
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 c, double i, double j, double k) {
double t_1 = ((a * t) + (i * x)) * 4.0;
double t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
double tmp;
if (t < -1.6210815397541398e-69) {
tmp = t_2;
} else if (t < 165.68027943805222) {
tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = ((a * t) + (i * x)) * 4.0 t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b)) tmp = 0 if t < -1.6210815397541398e-69: tmp = t_2 elif t < 165.68027943805222: tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j))) else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(a * t) + Float64(i * x)) * 4.0) t_2 = Float64(Float64(Float64(Float64(18.0 * t) * Float64(Float64(x * y) * z)) - t_1) - Float64(Float64(Float64(k * j) * 27.0) - Float64(c * b))) tmp = 0.0 if (t < -1.6210815397541398e-69) tmp = t_2; elseif (t < 165.68027943805222) tmp = Float64(Float64(Float64(Float64(18.0 * y) * Float64(x * Float64(z * t))) - t_1) + Float64(Float64(c * b) - Float64(27.0 * Float64(k * j)))); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = ((a * t) + (i * x)) * 4.0; t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b)); tmp = 0.0; if (t < -1.6210815397541398e-69) tmp = t_2; elseif (t < 165.68027943805222) tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j))); else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(a * t), $MachinePrecision] + N[(i * x), $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(18.0 * t), $MachinePrecision] * N[(N[(x * y), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - N[(N[(N[(k * j), $MachinePrecision] * 27.0), $MachinePrecision] - N[(c * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -1.6210815397541398e-69], t$95$2, If[Less[t, 165.68027943805222], N[(N[(N[(N[(18.0 * y), $MachinePrecision] * N[(x * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] + N[(N[(c * b), $MachinePrecision] - N[(27.0 * N[(k * j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(a \cdot t + i \cdot x\right) \cdot 4\\
t_2 := \left(\left(18 \cdot t\right) \cdot \left(\left(x \cdot y\right) \cdot z\right) - t\_1\right) - \left(\left(k \cdot j\right) \cdot 27 - c \cdot b\right)\\
\mathbf{if}\;t < -1.6210815397541398 \cdot 10^{-69}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t < 165.68027943805222:\\
\;\;\;\;\left(\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right) - t\_1\right) + \left(c \cdot b - 27 \cdot \left(k \cdot j\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
herbie shell --seed 2024094
(FPCore (x y z t a b c i j k)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, E"
:precision binary64
:alt
(if (< t -1.6210815397541398e-69) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b))) (if (< t 165.68027943805222) (+ (- (* (* 18.0 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4.0)) (- (* c b) (* 27.0 (* k j)))) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b)))))
(- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))