
(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 27 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 (* k (* j 27.0)))
(t_2 (* 18.0 (* t (* x z))))
(t_3 (* i (* x 4.0)))
(t_4 (+ (* j (* k 27.0)) (* x (* 4.0 i))))
(t_5 (* t (* a 4.0)))
(t_6 (- (- (+ (* b c) (- (* t (* z (* y (* 18.0 x)))) t_5)) t_3) t_1)))
(if (<= t_6 (- INFINITY))
(- (+ (* b c) (* t (- (* (* y z) (* 18.0 x)) (* a 4.0)))) t_4)
(if (<= t_6 5e+300)
(- (- (+ (* b c) (- (* t (* z (* 18.0 (* y x)))) t_5)) t_3) t_1)
(if (<= t_6 INFINITY)
(- (+ (* y (+ (* -4.0 (/ (* a t) y)) t_2)) (* b c)) t_4)
(* y (+ t_2 (* -27.0 (/ (* j k) y)))))))))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 = k * (j * 27.0);
double t_2 = 18.0 * (t * (x * z));
double t_3 = i * (x * 4.0);
double t_4 = (j * (k * 27.0)) + (x * (4.0 * i));
double t_5 = t * (a * 4.0);
double t_6 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_5)) - t_3) - t_1;
double tmp;
if (t_6 <= -((double) INFINITY)) {
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - t_4;
} else if (t_6 <= 5e+300) {
tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_5)) - t_3) - t_1;
} else if (t_6 <= ((double) INFINITY)) {
tmp = ((y * ((-4.0 * ((a * t) / y)) + t_2)) + (b * c)) - t_4;
} else {
tmp = y * (t_2 + (-27.0 * ((j * k) / y)));
}
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 = k * (j * 27.0);
double t_2 = 18.0 * (t * (x * z));
double t_3 = i * (x * 4.0);
double t_4 = (j * (k * 27.0)) + (x * (4.0 * i));
double t_5 = t * (a * 4.0);
double t_6 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_5)) - t_3) - t_1;
double tmp;
if (t_6 <= -Double.POSITIVE_INFINITY) {
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - t_4;
} else if (t_6 <= 5e+300) {
tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_5)) - t_3) - t_1;
} else if (t_6 <= Double.POSITIVE_INFINITY) {
tmp = ((y * ((-4.0 * ((a * t) / y)) + t_2)) + (b * c)) - t_4;
} else {
tmp = y * (t_2 + (-27.0 * ((j * k) / y)));
}
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 = k * (j * 27.0) t_2 = 18.0 * (t * (x * z)) t_3 = i * (x * 4.0) t_4 = (j * (k * 27.0)) + (x * (4.0 * i)) t_5 = t * (a * 4.0) t_6 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_5)) - t_3) - t_1 tmp = 0 if t_6 <= -math.inf: tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - t_4 elif t_6 <= 5e+300: tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_5)) - t_3) - t_1 elif t_6 <= math.inf: tmp = ((y * ((-4.0 * ((a * t) / y)) + t_2)) + (b * c)) - t_4 else: tmp = y * (t_2 + (-27.0 * ((j * k) / y))) 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(k * Float64(j * 27.0)) t_2 = Float64(18.0 * Float64(t * Float64(x * z))) t_3 = Float64(i * Float64(x * 4.0)) t_4 = Float64(Float64(j * Float64(k * 27.0)) + Float64(x * Float64(4.0 * i))) t_5 = Float64(t * Float64(a * 4.0)) t_6 = Float64(Float64(Float64(Float64(b * c) + Float64(Float64(t * Float64(z * Float64(y * Float64(18.0 * x)))) - t_5)) - t_3) - t_1) tmp = 0.0 if (t_6 <= Float64(-Inf)) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(y * z) * Float64(18.0 * x)) - Float64(a * 4.0)))) - t_4); elseif (t_6 <= 5e+300) tmp = Float64(Float64(Float64(Float64(b * c) + Float64(Float64(t * Float64(z * Float64(18.0 * Float64(y * x)))) - t_5)) - t_3) - t_1); elseif (t_6 <= Inf) tmp = Float64(Float64(Float64(y * Float64(Float64(-4.0 * Float64(Float64(a * t) / y)) + t_2)) + Float64(b * c)) - t_4); else tmp = Float64(y * Float64(t_2 + Float64(-27.0 * Float64(Float64(j * k) / y)))); 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 = k * (j * 27.0);
t_2 = 18.0 * (t * (x * z));
t_3 = i * (x * 4.0);
t_4 = (j * (k * 27.0)) + (x * (4.0 * i));
t_5 = t * (a * 4.0);
t_6 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_5)) - t_3) - t_1;
tmp = 0.0;
if (t_6 <= -Inf)
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - t_4;
elseif (t_6 <= 5e+300)
tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_5)) - t_3) - t_1;
elseif (t_6 <= Inf)
tmp = ((y * ((-4.0 * ((a * t) / y)) + t_2)) + (b * c)) - t_4;
else
tmp = y * (t_2 + (-27.0 * ((j * k) / y)));
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[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(18.0 * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(i * N[(x * 4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(j * N[(k * 27.0), $MachinePrecision]), $MachinePrecision] + N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * N[(z * N[(y * N[(18.0 * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$5), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision] - t$95$1), $MachinePrecision]}, If[LessEqual[t$95$6, (-Infinity)], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(y * z), $MachinePrecision] * N[(18.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$4), $MachinePrecision], If[LessEqual[t$95$6, 5e+300], N[(N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * N[(z * N[(18.0 * N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$5), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[t$95$6, Infinity], N[(N[(N[(y * N[(N[(-4.0 * N[(N[(a * t), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - t$95$4), $MachinePrecision], N[(y * N[(t$95$2 + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / y), $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 := k \cdot \left(j \cdot 27\right)\\
t_2 := 18 \cdot \left(t \cdot \left(x \cdot z\right)\right)\\
t_3 := i \cdot \left(x \cdot 4\right)\\
t_4 := j \cdot \left(k \cdot 27\right) + x \cdot \left(4 \cdot i\right)\\
t_5 := t \cdot \left(a \cdot 4\right)\\
t_6 := \left(\left(b \cdot c + \left(t \cdot \left(z \cdot \left(y \cdot \left(18 \cdot x\right)\right)\right) - t\_5\right)\right) - t\_3\right) - t\_1\\
\mathbf{if}\;t\_6 \leq -\infty:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(y \cdot z\right) \cdot \left(18 \cdot x\right) - a \cdot 4\right)\right) - t\_4\\
\mathbf{elif}\;t\_6 \leq 5 \cdot 10^{+300}:\\
\;\;\;\;\left(\left(b \cdot c + \left(t \cdot \left(z \cdot \left(18 \cdot \left(y \cdot x\right)\right)\right) - t\_5\right)\right) - t\_3\right) - t\_1\\
\mathbf{elif}\;t\_6 \leq \infty:\\
\;\;\;\;\left(y \cdot \left(-4 \cdot \frac{a \cdot t}{y} + t\_2\right) + b \cdot c\right) - t\_4\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(t\_2 + -27 \cdot \frac{j \cdot k}{y}\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 87.4%
Simplified98.2%
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)) < 5.00000000000000026e300Initial program 99.0%
Taylor expanded in x around 0 99.1%
if 5.00000000000000026e300 < (-.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 91.9%
Simplified91.9%
Taylor expanded in y around inf 96.6%
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%
Simplified20.0%
Taylor expanded in y around inf 50.0%
*-commutative50.0%
Simplified50.0%
Taylor expanded in y around inf 55.0%
Final simplification94.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
(if (<= y -2e+147)
(-
(+ (* y (+ (* -4.0 (/ (* a t) y)) (* 18.0 (* t (* x z))))) (* b c))
(+ (* j (* k 27.0)) (* x (* 4.0 i))))
(+
(fma t (fma x (* 18.0 (* y z)) (* -4.0 a)) (fma b c (* x (* -4.0 i))))
(* 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 tmp;
if (y <= -2e+147) {
tmp = ((y * ((-4.0 * ((a * t) / y)) + (18.0 * (t * (x * z))))) + (b * c)) - ((j * (k * 27.0)) + (x * (4.0 * i)));
} else {
tmp = fma(t, fma(x, (18.0 * (y * z)), (-4.0 * a)), fma(b, c, (x * (-4.0 * i)))) + (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) tmp = 0.0 if (y <= -2e+147) tmp = Float64(Float64(Float64(y * Float64(Float64(-4.0 * Float64(Float64(a * t) / y)) + Float64(18.0 * Float64(t * Float64(x * z))))) + Float64(b * c)) - Float64(Float64(j * Float64(k * 27.0)) + Float64(x * Float64(4.0 * i)))); else tmp = Float64(fma(t, fma(x, Float64(18.0 * Float64(y * z)), Float64(-4.0 * a)), fma(b, c, Float64(x * Float64(-4.0 * i)))) + Float64(j * Float64(k * -27.0))); end return 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[y, -2e+147], N[(N[(N[(y * N[(N[(-4.0 * N[(N[(a * t), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(j * N[(k * 27.0), $MachinePrecision]), $MachinePrecision] + N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(x * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] + N[(b * c + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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}
\mathbf{if}\;y \leq -2 \cdot 10^{+147}:\\
\;\;\;\;\left(y \cdot \left(-4 \cdot \frac{a \cdot t}{y} + 18 \cdot \left(t \cdot \left(x \cdot z\right)\right)\right) + b \cdot c\right) - \left(j \cdot \left(k \cdot 27\right) + x \cdot \left(4 \cdot i\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), -4 \cdot a\right), \mathsf{fma}\left(b, c, x \cdot \left(-4 \cdot i\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\
\end{array}
\end{array}
if y < -2e147Initial program 80.5%
Simplified80.5%
Taylor expanded in y around inf 94.2%
if -2e147 < y Initial program 88.2%
Simplified90.1%
Final simplification90.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 (* i (* x 4.0)))
(t_2 (* k (* j 27.0)))
(t_3 (* t (* a 4.0)))
(t_4 (- (- (+ (* b c) (- (* t (* z (* y (* 18.0 x)))) t_3)) t_1) t_2)))
(if (<= t_4 (- INFINITY))
(-
(+ (* b c) (* t (- (* (* y z) (* 18.0 x)) (* a 4.0))))
(+ (* j (* k 27.0)) (* x (* 4.0 i))))
(if (<= t_4 INFINITY)
(- (- (+ (* b c) (- (* t (* z (* 18.0 (* y x)))) t_3)) t_1) t_2)
(* y (+ (* 18.0 (* t (* x z))) (* -27.0 (/ (* j k) y))))))))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 = i * (x * 4.0);
double t_2 = k * (j * 27.0);
double t_3 = t * (a * 4.0);
double t_4 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_3)) - t_1) - t_2;
double tmp;
if (t_4 <= -((double) INFINITY)) {
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (4.0 * i)));
} else if (t_4 <= ((double) INFINITY)) {
tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_3)) - t_1) - t_2;
} else {
tmp = y * ((18.0 * (t * (x * z))) + (-27.0 * ((j * k) / y)));
}
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 = i * (x * 4.0);
double t_2 = k * (j * 27.0);
double t_3 = t * (a * 4.0);
double t_4 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_3)) - t_1) - t_2;
double tmp;
if (t_4 <= -Double.POSITIVE_INFINITY) {
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (4.0 * i)));
} else if (t_4 <= Double.POSITIVE_INFINITY) {
tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_3)) - t_1) - t_2;
} else {
tmp = y * ((18.0 * (t * (x * z))) + (-27.0 * ((j * k) / y)));
}
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 = i * (x * 4.0) t_2 = k * (j * 27.0) t_3 = t * (a * 4.0) t_4 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_3)) - t_1) - t_2 tmp = 0 if t_4 <= -math.inf: tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (4.0 * i))) elif t_4 <= math.inf: tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_3)) - t_1) - t_2 else: tmp = y * ((18.0 * (t * (x * z))) + (-27.0 * ((j * k) / y))) 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(i * Float64(x * 4.0)) t_2 = Float64(k * Float64(j * 27.0)) t_3 = Float64(t * Float64(a * 4.0)) t_4 = Float64(Float64(Float64(Float64(b * c) + Float64(Float64(t * Float64(z * Float64(y * Float64(18.0 * x)))) - t_3)) - t_1) - t_2) tmp = 0.0 if (t_4 <= Float64(-Inf)) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(y * z) * Float64(18.0 * x)) - Float64(a * 4.0)))) - Float64(Float64(j * Float64(k * 27.0)) + Float64(x * Float64(4.0 * i)))); elseif (t_4 <= Inf) tmp = Float64(Float64(Float64(Float64(b * c) + Float64(Float64(t * Float64(z * Float64(18.0 * Float64(y * x)))) - t_3)) - t_1) - t_2); else tmp = Float64(y * Float64(Float64(18.0 * Float64(t * Float64(x * z))) + Float64(-27.0 * Float64(Float64(j * k) / y)))); 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 = i * (x * 4.0);
t_2 = k * (j * 27.0);
t_3 = t * (a * 4.0);
t_4 = (((b * c) + ((t * (z * (y * (18.0 * x)))) - t_3)) - t_1) - t_2;
tmp = 0.0;
if (t_4 <= -Inf)
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (4.0 * i)));
elseif (t_4 <= Inf)
tmp = (((b * c) + ((t * (z * (18.0 * (y * x)))) - t_3)) - t_1) - t_2;
else
tmp = y * ((18.0 * (t * (x * z))) + (-27.0 * ((j * k) / y)));
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[(i * N[(x * 4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * N[(z * N[(y * N[(18.0 * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision]}, If[LessEqual[t$95$4, (-Infinity)], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(y * z), $MachinePrecision] * N[(18.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * N[(k * 27.0), $MachinePrecision]), $MachinePrecision] + N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, Infinity], N[(N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * N[(z * N[(18.0 * N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], N[(y * N[(N[(18.0 * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / y), $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 := i \cdot \left(x \cdot 4\right)\\
t_2 := k \cdot \left(j \cdot 27\right)\\
t_3 := t \cdot \left(a \cdot 4\right)\\
t_4 := \left(\left(b \cdot c + \left(t \cdot \left(z \cdot \left(y \cdot \left(18 \cdot x\right)\right)\right) - t\_3\right)\right) - t\_1\right) - t\_2\\
\mathbf{if}\;t\_4 \leq -\infty:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(y \cdot z\right) \cdot \left(18 \cdot x\right) - a \cdot 4\right)\right) - \left(j \cdot \left(k \cdot 27\right) + x \cdot \left(4 \cdot i\right)\right)\\
\mathbf{elif}\;t\_4 \leq \infty:\\
\;\;\;\;\left(\left(b \cdot c + \left(t \cdot \left(z \cdot \left(18 \cdot \left(y \cdot x\right)\right)\right) - t\_3\right)\right) - t\_1\right) - t\_2\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(18 \cdot \left(t \cdot \left(x \cdot z\right)\right) + -27 \cdot \frac{j \cdot k}{y}\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 87.4%
Simplified98.2%
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)) < +inf.0Initial program 96.7%
Taylor expanded in x around 0 96.7%
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%
Simplified20.0%
Taylor expanded in y around inf 50.0%
*-commutative50.0%
Simplified50.0%
Taylor expanded in y around inf 55.0%
Final simplification93.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 (* j (* k -27.0)))
(t_2 (* t (- (* 18.0 (* x (* y z))) (* a 4.0)))))
(if (<= t -1.8e+136)
t_2
(if (<= t -3.05e+31)
(* c (+ b (* -27.0 (* j (/ k c)))))
(if (<= t -1.6e-32)
(- (* b c) (* a (* t 4.0)))
(if (<= t -1.7e-175)
(+ (* b c) t_1)
(if (<= t -2e-256)
(- (* b c) (* i (* x 4.0)))
(if (<= t 1.4e-302)
(* j (+ (* k -27.0) (/ (* b c) j)))
(if (<= t 1.55e-145)
(+ t_1 (* x (* -4.0 i)))
(if (<= t 8000000000000.0)
(* k (+ (* j -27.0) (/ (* b c) k)))
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 = t * ((18.0 * (x * (y * z))) - (a * 4.0));
double tmp;
if (t <= -1.8e+136) {
tmp = t_2;
} else if (t <= -3.05e+31) {
tmp = c * (b + (-27.0 * (j * (k / c))));
} else if (t <= -1.6e-32) {
tmp = (b * c) - (a * (t * 4.0));
} else if (t <= -1.7e-175) {
tmp = (b * c) + t_1;
} else if (t <= -2e-256) {
tmp = (b * c) - (i * (x * 4.0));
} else if (t <= 1.4e-302) {
tmp = j * ((k * -27.0) + ((b * c) / j));
} else if (t <= 1.55e-145) {
tmp = t_1 + (x * (-4.0 * i));
} else if (t <= 8000000000000.0) {
tmp = k * ((j * -27.0) + ((b * c) / k));
} 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 = t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))
if (t <= (-1.8d+136)) then
tmp = t_2
else if (t <= (-3.05d+31)) then
tmp = c * (b + ((-27.0d0) * (j * (k / c))))
else if (t <= (-1.6d-32)) then
tmp = (b * c) - (a * (t * 4.0d0))
else if (t <= (-1.7d-175)) then
tmp = (b * c) + t_1
else if (t <= (-2d-256)) then
tmp = (b * c) - (i * (x * 4.0d0))
else if (t <= 1.4d-302) then
tmp = j * ((k * (-27.0d0)) + ((b * c) / j))
else if (t <= 1.55d-145) then
tmp = t_1 + (x * ((-4.0d0) * i))
else if (t <= 8000000000000.0d0) then
tmp = k * ((j * (-27.0d0)) + ((b * c) / k))
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 = t * ((18.0 * (x * (y * z))) - (a * 4.0));
double tmp;
if (t <= -1.8e+136) {
tmp = t_2;
} else if (t <= -3.05e+31) {
tmp = c * (b + (-27.0 * (j * (k / c))));
} else if (t <= -1.6e-32) {
tmp = (b * c) - (a * (t * 4.0));
} else if (t <= -1.7e-175) {
tmp = (b * c) + t_1;
} else if (t <= -2e-256) {
tmp = (b * c) - (i * (x * 4.0));
} else if (t <= 1.4e-302) {
tmp = j * ((k * -27.0) + ((b * c) / j));
} else if (t <= 1.55e-145) {
tmp = t_1 + (x * (-4.0 * i));
} else if (t <= 8000000000000.0) {
tmp = k * ((j * -27.0) + ((b * c) / k));
} 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 = t * ((18.0 * (x * (y * z))) - (a * 4.0)) tmp = 0 if t <= -1.8e+136: tmp = t_2 elif t <= -3.05e+31: tmp = c * (b + (-27.0 * (j * (k / c)))) elif t <= -1.6e-32: tmp = (b * c) - (a * (t * 4.0)) elif t <= -1.7e-175: tmp = (b * c) + t_1 elif t <= -2e-256: tmp = (b * c) - (i * (x * 4.0)) elif t <= 1.4e-302: tmp = j * ((k * -27.0) + ((b * c) / j)) elif t <= 1.55e-145: tmp = t_1 + (x * (-4.0 * i)) elif t <= 8000000000000.0: tmp = k * ((j * -27.0) + ((b * c) / k)) 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(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))) tmp = 0.0 if (t <= -1.8e+136) tmp = t_2; elseif (t <= -3.05e+31) tmp = Float64(c * Float64(b + Float64(-27.0 * Float64(j * Float64(k / c))))); elseif (t <= -1.6e-32) tmp = Float64(Float64(b * c) - Float64(a * Float64(t * 4.0))); elseif (t <= -1.7e-175) tmp = Float64(Float64(b * c) + t_1); elseif (t <= -2e-256) tmp = Float64(Float64(b * c) - Float64(i * Float64(x * 4.0))); elseif (t <= 1.4e-302) tmp = Float64(j * Float64(Float64(k * -27.0) + Float64(Float64(b * c) / j))); elseif (t <= 1.55e-145) tmp = Float64(t_1 + Float64(x * Float64(-4.0 * i))); elseif (t <= 8000000000000.0) tmp = Float64(k * Float64(Float64(j * -27.0) + Float64(Float64(b * c) / k))); 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 = t * ((18.0 * (x * (y * z))) - (a * 4.0));
tmp = 0.0;
if (t <= -1.8e+136)
tmp = t_2;
elseif (t <= -3.05e+31)
tmp = c * (b + (-27.0 * (j * (k / c))));
elseif (t <= -1.6e-32)
tmp = (b * c) - (a * (t * 4.0));
elseif (t <= -1.7e-175)
tmp = (b * c) + t_1;
elseif (t <= -2e-256)
tmp = (b * c) - (i * (x * 4.0));
elseif (t <= 1.4e-302)
tmp = j * ((k * -27.0) + ((b * c) / j));
elseif (t <= 1.55e-145)
tmp = t_1 + (x * (-4.0 * i));
elseif (t <= 8000000000000.0)
tmp = k * ((j * -27.0) + ((b * c) / k));
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[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.8e+136], t$95$2, If[LessEqual[t, -3.05e+31], N[(c * N[(b + N[(-27.0 * N[(j * N[(k / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -1.6e-32], N[(N[(b * c), $MachinePrecision] - N[(a * N[(t * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -1.7e-175], N[(N[(b * c), $MachinePrecision] + t$95$1), $MachinePrecision], If[LessEqual[t, -2e-256], N[(N[(b * c), $MachinePrecision] - N[(i * N[(x * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.4e-302], N[(j * N[(N[(k * -27.0), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] / j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.55e-145], N[(t$95$1 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 8000000000000.0], N[(k * N[(N[(j * -27.0), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] / k), $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 := t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\
\mathbf{if}\;t \leq -1.8 \cdot 10^{+136}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -3.05 \cdot 10^{+31}:\\
\;\;\;\;c \cdot \left(b + -27 \cdot \left(j \cdot \frac{k}{c}\right)\right)\\
\mathbf{elif}\;t \leq -1.6 \cdot 10^{-32}:\\
\;\;\;\;b \cdot c - a \cdot \left(t \cdot 4\right)\\
\mathbf{elif}\;t \leq -1.7 \cdot 10^{-175}:\\
\;\;\;\;b \cdot c + t\_1\\
\mathbf{elif}\;t \leq -2 \cdot 10^{-256}:\\
\;\;\;\;b \cdot c - i \cdot \left(x \cdot 4\right)\\
\mathbf{elif}\;t \leq 1.4 \cdot 10^{-302}:\\
\;\;\;\;j \cdot \left(k \cdot -27 + \frac{b \cdot c}{j}\right)\\
\mathbf{elif}\;t \leq 1.55 \cdot 10^{-145}:\\
\;\;\;\;t\_1 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;t \leq 8000000000000:\\
\;\;\;\;k \cdot \left(j \cdot -27 + \frac{b \cdot c}{k}\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -1.80000000000000003e136 or 8e12 < t Initial program 85.4%
Simplified89.2%
Taylor expanded in t around inf 71.5%
if -1.80000000000000003e136 < t < -3.05000000000000005e31Initial program 94.4%
Simplified94.8%
Taylor expanded in b around inf 63.6%
Taylor expanded in c around inf 73.9%
*-commutative73.9%
associate-/l*73.9%
Simplified73.9%
if -3.05000000000000005e31 < t < -1.6000000000000001e-32Initial program 99.7%
Taylor expanded in y around 0 92.7%
distribute-lft-out92.7%
*-commutative92.7%
Simplified92.7%
Taylor expanded in j around 0 77.4%
Taylor expanded in a around inf 66.6%
*-commutative66.6%
associate-*l*66.6%
Simplified66.6%
if -1.6000000000000001e-32 < t < -1.7e-175Initial program 88.3%
Simplified85.7%
Taylor expanded in b around inf 55.7%
if -1.7e-175 < t < -1.99999999999999995e-256Initial program 100.0%
Taylor expanded in y around 0 100.0%
distribute-lft-out100.0%
*-commutative100.0%
Simplified100.0%
Taylor expanded in j around 0 98.5%
Taylor expanded in a around 0 98.5%
*-commutative98.5%
associate-*r*98.5%
Simplified98.5%
if -1.99999999999999995e-256 < t < 1.4e-302Initial program 86.4%
Simplified72.7%
Taylor expanded in b around inf 85.8%
Taylor expanded in j around inf 85.8%
if 1.4e-302 < t < 1.55e-145Initial program 78.7%
Simplified75.9%
Taylor expanded in i around inf 77.8%
*-commutative77.8%
*-commutative77.8%
associate-*l*77.8%
*-commutative77.8%
Simplified77.8%
if 1.55e-145 < t < 8e12Initial program 85.2%
Simplified93.8%
Taylor expanded in b around inf 73.2%
Taylor expanded in k around inf 73.4%
Final simplification72.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 (* c (+ b (* -27.0 (* j (/ k c))))))
(t_2 (* j (* k -27.0)))
(t_3 (+ t_2 (* x (* -4.0 i))))
(t_4 (+ t_2 (* -4.0 (* a t)))))
(if (<= (* b c) -5e+192)
t_1
(if (<= (* b c) -2e-183)
t_4
(if (<= (* b c) -4e-294)
t_3
(if (<= (* b c) 5e-192) t_4 (if (<= (* b c) 2e+100) t_3 t_1)))))))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 = c * (b + (-27.0 * (j * (k / c))));
double t_2 = j * (k * -27.0);
double t_3 = t_2 + (x * (-4.0 * i));
double t_4 = t_2 + (-4.0 * (a * t));
double tmp;
if ((b * c) <= -5e+192) {
tmp = t_1;
} else if ((b * c) <= -2e-183) {
tmp = t_4;
} else if ((b * c) <= -4e-294) {
tmp = t_3;
} else if ((b * c) <= 5e-192) {
tmp = t_4;
} else if ((b * c) <= 2e+100) {
tmp = t_3;
} else {
tmp = t_1;
}
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) :: t_4
real(8) :: tmp
t_1 = c * (b + ((-27.0d0) * (j * (k / c))))
t_2 = j * (k * (-27.0d0))
t_3 = t_2 + (x * ((-4.0d0) * i))
t_4 = t_2 + ((-4.0d0) * (a * t))
if ((b * c) <= (-5d+192)) then
tmp = t_1
else if ((b * c) <= (-2d-183)) then
tmp = t_4
else if ((b * c) <= (-4d-294)) then
tmp = t_3
else if ((b * c) <= 5d-192) then
tmp = t_4
else if ((b * c) <= 2d+100) then
tmp = t_3
else
tmp = t_1
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 = c * (b + (-27.0 * (j * (k / c))));
double t_2 = j * (k * -27.0);
double t_3 = t_2 + (x * (-4.0 * i));
double t_4 = t_2 + (-4.0 * (a * t));
double tmp;
if ((b * c) <= -5e+192) {
tmp = t_1;
} else if ((b * c) <= -2e-183) {
tmp = t_4;
} else if ((b * c) <= -4e-294) {
tmp = t_3;
} else if ((b * c) <= 5e-192) {
tmp = t_4;
} else if ((b * c) <= 2e+100) {
tmp = t_3;
} else {
tmp = t_1;
}
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 = c * (b + (-27.0 * (j * (k / c)))) t_2 = j * (k * -27.0) t_3 = t_2 + (x * (-4.0 * i)) t_4 = t_2 + (-4.0 * (a * t)) tmp = 0 if (b * c) <= -5e+192: tmp = t_1 elif (b * c) <= -2e-183: tmp = t_4 elif (b * c) <= -4e-294: tmp = t_3 elif (b * c) <= 5e-192: tmp = t_4 elif (b * c) <= 2e+100: tmp = t_3 else: tmp = t_1 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(c * Float64(b + Float64(-27.0 * Float64(j * Float64(k / c))))) t_2 = Float64(j * Float64(k * -27.0)) t_3 = Float64(t_2 + Float64(x * Float64(-4.0 * i))) t_4 = Float64(t_2 + Float64(-4.0 * Float64(a * t))) tmp = 0.0 if (Float64(b * c) <= -5e+192) tmp = t_1; elseif (Float64(b * c) <= -2e-183) tmp = t_4; elseif (Float64(b * c) <= -4e-294) tmp = t_3; elseif (Float64(b * c) <= 5e-192) tmp = t_4; elseif (Float64(b * c) <= 2e+100) tmp = t_3; else tmp = t_1; 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 = c * (b + (-27.0 * (j * (k / c))));
t_2 = j * (k * -27.0);
t_3 = t_2 + (x * (-4.0 * i));
t_4 = t_2 + (-4.0 * (a * t));
tmp = 0.0;
if ((b * c) <= -5e+192)
tmp = t_1;
elseif ((b * c) <= -2e-183)
tmp = t_4;
elseif ((b * c) <= -4e-294)
tmp = t_3;
elseif ((b * c) <= 5e-192)
tmp = t_4;
elseif ((b * c) <= 2e+100)
tmp = t_3;
else
tmp = t_1;
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[(c * N[(b + N[(-27.0 * N[(j * N[(k / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(t$95$2 + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -5e+192], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -2e-183], t$95$4, If[LessEqual[N[(b * c), $MachinePrecision], -4e-294], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 5e-192], t$95$4, If[LessEqual[N[(b * c), $MachinePrecision], 2e+100], t$95$3, t$95$1]]]]]]]]]
\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 := c \cdot \left(b + -27 \cdot \left(j \cdot \frac{k}{c}\right)\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
t_3 := t\_2 + x \cdot \left(-4 \cdot i\right)\\
t_4 := t\_2 + -4 \cdot \left(a \cdot t\right)\\
\mathbf{if}\;b \cdot c \leq -5 \cdot 10^{+192}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq -2 \cdot 10^{-183}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;b \cdot c \leq -4 \cdot 10^{-294}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;b \cdot c \leq 5 \cdot 10^{-192}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+100}:\\
\;\;\;\;t\_3\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (*.f64 b c) < -5.00000000000000033e192 or 2.00000000000000003e100 < (*.f64 b c) Initial program 85.3%
Simplified86.7%
Taylor expanded in b around inf 77.7%
Taylor expanded in c around inf 79.1%
*-commutative79.1%
associate-/l*80.5%
Simplified80.5%
if -5.00000000000000033e192 < (*.f64 b c) < -2.00000000000000001e-183 or -4.00000000000000007e-294 < (*.f64 b c) < 5.0000000000000001e-192Initial program 87.8%
Simplified91.1%
Taylor expanded in a around inf 57.4%
if -2.00000000000000001e-183 < (*.f64 b c) < -4.00000000000000007e-294 or 5.0000000000000001e-192 < (*.f64 b c) < 2.00000000000000003e100Initial program 88.3%
Simplified86.7%
Taylor expanded in i around inf 56.2%
*-commutative56.2%
*-commutative56.2%
associate-*l*56.2%
*-commutative56.2%
Simplified56.2%
Final simplification63.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 (+ (* a t) (* x i)))))
(t_2 (* j (* k -27.0)))
(t_3 (+ t_2 (* 18.0 (* x (* y (* t z)))))))
(if (<= j -2.4e+277)
t_3
(if (<= j -4.4e+247)
(* c (+ b (* -27.0 (* j (/ k c)))))
(if (<= j -2.05e+247)
(* c (+ b (* -4.0 (* i (/ x c)))))
(if (<= j -3.1e+203)
t_1
(if (<= j -4.1e+146)
(+ t_2 (* x (* -4.0 i)))
(if (<= j 5.5e-67) t_1 t_3))))))))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 * ((a * t) + (x * i)));
double t_2 = j * (k * -27.0);
double t_3 = t_2 + (18.0 * (x * (y * (t * z))));
double tmp;
if (j <= -2.4e+277) {
tmp = t_3;
} else if (j <= -4.4e+247) {
tmp = c * (b + (-27.0 * (j * (k / c))));
} else if (j <= -2.05e+247) {
tmp = c * (b + (-4.0 * (i * (x / c))));
} else if (j <= -3.1e+203) {
tmp = t_1;
} else if (j <= -4.1e+146) {
tmp = t_2 + (x * (-4.0 * i));
} else if (j <= 5.5e-67) {
tmp = t_1;
} else {
tmp = t_3;
}
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 * ((a * t) + (x * i)))
t_2 = j * (k * (-27.0d0))
t_3 = t_2 + (18.0d0 * (x * (y * (t * z))))
if (j <= (-2.4d+277)) then
tmp = t_3
else if (j <= (-4.4d+247)) then
tmp = c * (b + ((-27.0d0) * (j * (k / c))))
else if (j <= (-2.05d+247)) then
tmp = c * (b + ((-4.0d0) * (i * (x / c))))
else if (j <= (-3.1d+203)) then
tmp = t_1
else if (j <= (-4.1d+146)) then
tmp = t_2 + (x * ((-4.0d0) * i))
else if (j <= 5.5d-67) then
tmp = t_1
else
tmp = t_3
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 * ((a * t) + (x * i)));
double t_2 = j * (k * -27.0);
double t_3 = t_2 + (18.0 * (x * (y * (t * z))));
double tmp;
if (j <= -2.4e+277) {
tmp = t_3;
} else if (j <= -4.4e+247) {
tmp = c * (b + (-27.0 * (j * (k / c))));
} else if (j <= -2.05e+247) {
tmp = c * (b + (-4.0 * (i * (x / c))));
} else if (j <= -3.1e+203) {
tmp = t_1;
} else if (j <= -4.1e+146) {
tmp = t_2 + (x * (-4.0 * i));
} else if (j <= 5.5e-67) {
tmp = t_1;
} else {
tmp = t_3;
}
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 * ((a * t) + (x * i))) t_2 = j * (k * -27.0) t_3 = t_2 + (18.0 * (x * (y * (t * z)))) tmp = 0 if j <= -2.4e+277: tmp = t_3 elif j <= -4.4e+247: tmp = c * (b + (-27.0 * (j * (k / c)))) elif j <= -2.05e+247: tmp = c * (b + (-4.0 * (i * (x / c)))) elif j <= -3.1e+203: tmp = t_1 elif j <= -4.1e+146: tmp = t_2 + (x * (-4.0 * i)) elif j <= 5.5e-67: tmp = t_1 else: tmp = t_3 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(Float64(a * t) + Float64(x * i)))) t_2 = Float64(j * Float64(k * -27.0)) t_3 = Float64(t_2 + Float64(18.0 * Float64(x * Float64(y * Float64(t * z))))) tmp = 0.0 if (j <= -2.4e+277) tmp = t_3; elseif (j <= -4.4e+247) tmp = Float64(c * Float64(b + Float64(-27.0 * Float64(j * Float64(k / c))))); elseif (j <= -2.05e+247) tmp = Float64(c * Float64(b + Float64(-4.0 * Float64(i * Float64(x / c))))); elseif (j <= -3.1e+203) tmp = t_1; elseif (j <= -4.1e+146) tmp = Float64(t_2 + Float64(x * Float64(-4.0 * i))); elseif (j <= 5.5e-67) tmp = t_1; else tmp = t_3; 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 * ((a * t) + (x * i)));
t_2 = j * (k * -27.0);
t_3 = t_2 + (18.0 * (x * (y * (t * z))));
tmp = 0.0;
if (j <= -2.4e+277)
tmp = t_3;
elseif (j <= -4.4e+247)
tmp = c * (b + (-27.0 * (j * (k / c))));
elseif (j <= -2.05e+247)
tmp = c * (b + (-4.0 * (i * (x / c))));
elseif (j <= -3.1e+203)
tmp = t_1;
elseif (j <= -4.1e+146)
tmp = t_2 + (x * (-4.0 * i));
elseif (j <= 5.5e-67)
tmp = t_1;
else
tmp = t_3;
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[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 + N[(18.0 * N[(x * N[(y * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -2.4e+277], t$95$3, If[LessEqual[j, -4.4e+247], N[(c * N[(b + N[(-27.0 * N[(j * N[(k / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -2.05e+247], N[(c * N[(b + N[(-4.0 * N[(i * N[(x / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -3.1e+203], t$95$1, If[LessEqual[j, -4.1e+146], N[(t$95$2 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 5.5e-67], t$95$1, t$95$3]]]]]]]]]
\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(a \cdot t + x \cdot i\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
t_3 := t\_2 + 18 \cdot \left(x \cdot \left(y \cdot \left(t \cdot z\right)\right)\right)\\
\mathbf{if}\;j \leq -2.4 \cdot 10^{+277}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;j \leq -4.4 \cdot 10^{+247}:\\
\;\;\;\;c \cdot \left(b + -27 \cdot \left(j \cdot \frac{k}{c}\right)\right)\\
\mathbf{elif}\;j \leq -2.05 \cdot 10^{+247}:\\
\;\;\;\;c \cdot \left(b + -4 \cdot \left(i \cdot \frac{x}{c}\right)\right)\\
\mathbf{elif}\;j \leq -3.1 \cdot 10^{+203}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -4.1 \cdot 10^{+146}:\\
\;\;\;\;t\_2 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;j \leq 5.5 \cdot 10^{-67}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if j < -2.39999999999999993e277 or 5.5000000000000003e-67 < j Initial program 82.0%
Simplified82.1%
Taylor expanded in y around inf 55.6%
*-commutative55.6%
Simplified55.6%
Taylor expanded in x around 0 55.6%
*-commutative55.6%
associate-*r*55.9%
associate-*l*55.8%
Simplified55.8%
if -2.39999999999999993e277 < j < -4.40000000000000022e247Initial program 99.8%
Simplified99.8%
Taylor expanded in b around inf 87.5%
Taylor expanded in c around inf 87.7%
*-commutative87.7%
associate-/l*87.7%
Simplified87.7%
if -4.40000000000000022e247 < j < -2.0500000000000001e247Initial program 87.2%
Taylor expanded in y around 0 78.3%
distribute-lft-out78.3%
*-commutative78.3%
Simplified78.3%
Taylor expanded in j around 0 57.9%
Taylor expanded in a around 0 40.5%
*-commutative40.5%
associate-*r*40.5%
Simplified40.5%
Taylor expanded in c around inf 38.4%
associate-/l*38.6%
Simplified38.6%
if -2.0500000000000001e247 < j < -3.1e203 or -4.1000000000000004e146 < j < 5.5000000000000003e-67Initial program 90.9%
Taylor expanded in y around 0 79.8%
distribute-lft-out79.8%
*-commutative79.8%
Simplified79.8%
Taylor expanded in j around 0 69.7%
if -3.1e203 < j < -4.1000000000000004e146Initial program 69.0%
Simplified69.2%
Taylor expanded in i around inf 76.9%
*-commutative76.9%
*-commutative76.9%
associate-*l*76.9%
*-commutative76.9%
Simplified76.9%
Final simplification66.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 (<= (* k (* j 27.0)) -1e+276)
(* j (- (* b (/ c j)) (* k 27.0)))
(-
(+ (* b c) (* t (- (* (* y z) (* 18.0 x)) (* a 4.0))))
(+ (* j (* k 27.0)) (* x (* 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 tmp;
if ((k * (j * 27.0)) <= -1e+276) {
tmp = j * ((b * (c / j)) - (k * 27.0));
} else {
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (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) :: tmp
if ((k * (j * 27.0d0)) <= (-1d+276)) then
tmp = j * ((b * (c / j)) - (k * 27.0d0))
else
tmp = ((b * c) + (t * (((y * z) * (18.0d0 * x)) - (a * 4.0d0)))) - ((j * (k * 27.0d0)) + (x * (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 tmp;
if ((k * (j * 27.0)) <= -1e+276) {
tmp = j * ((b * (c / j)) - (k * 27.0));
} else {
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (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): tmp = 0 if (k * (j * 27.0)) <= -1e+276: tmp = j * ((b * (c / j)) - (k * 27.0)) else: tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (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) tmp = 0.0 if (Float64(k * Float64(j * 27.0)) <= -1e+276) tmp = Float64(j * Float64(Float64(b * Float64(c / j)) - Float64(k * 27.0))); else tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(y * z) * Float64(18.0 * x)) - Float64(a * 4.0)))) - Float64(Float64(j * Float64(k * 27.0)) + Float64(x * 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)
tmp = 0.0;
if ((k * (j * 27.0)) <= -1e+276)
tmp = j * ((b * (c / j)) - (k * 27.0));
else
tmp = ((b * c) + (t * (((y * z) * (18.0 * x)) - (a * 4.0)))) - ((j * (k * 27.0)) + (x * (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_] := If[LessEqual[N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision], -1e+276], N[(j * N[(N[(b * N[(c / j), $MachinePrecision]), $MachinePrecision] - N[(k * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(y * z), $MachinePrecision] * N[(18.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * N[(k * 27.0), $MachinePrecision]), $MachinePrecision] + N[(x * N[(4.0 * i), $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}\;k \cdot \left(j \cdot 27\right) \leq -1 \cdot 10^{+276}:\\
\;\;\;\;j \cdot \left(b \cdot \frac{c}{j} - k \cdot 27\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(y \cdot z\right) \cdot \left(18 \cdot x\right) - a \cdot 4\right)\right) - \left(j \cdot \left(k \cdot 27\right) + x \cdot \left(4 \cdot i\right)\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -1.0000000000000001e276Initial program 69.4%
Simplified69.5%
Taylor expanded in b around inf 82.5%
Taylor expanded in j around -inf 86.9%
mul-1-neg86.9%
*-commutative86.9%
distribute-rgt-neg-in86.9%
+-commutative86.9%
mul-1-neg86.9%
unsub-neg86.9%
associate-/l*95.6%
Simplified95.6%
if -1.0000000000000001e276 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 88.9%
Simplified90.3%
Final simplification90.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
(if (<= (* b c) -1.8e+184)
(* b c)
(if (or (<= (* b c) -6e+14)
(and (not (<= (* b c) -1.2e-103)) (<= (* b c) 1.85e-187)))
(* -4.0 (+ (* a t) (* 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 tmp;
if ((b * c) <= -1.8e+184) {
tmp = b * c;
} else if (((b * c) <= -6e+14) || (!((b * c) <= -1.2e-103) && ((b * c) <= 1.85e-187))) {
tmp = -4.0 * ((a * t) + (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) :: tmp
if ((b * c) <= (-1.8d+184)) then
tmp = b * c
else if (((b * c) <= (-6d+14)) .or. (.not. ((b * c) <= (-1.2d-103))) .and. ((b * c) <= 1.85d-187)) then
tmp = (-4.0d0) * ((a * t) + (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 tmp;
if ((b * c) <= -1.8e+184) {
tmp = b * c;
} else if (((b * c) <= -6e+14) || (!((b * c) <= -1.2e-103) && ((b * c) <= 1.85e-187))) {
tmp = -4.0 * ((a * t) + (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): tmp = 0 if (b * c) <= -1.8e+184: tmp = b * c elif ((b * c) <= -6e+14) or (not ((b * c) <= -1.2e-103) and ((b * c) <= 1.85e-187)): tmp = -4.0 * ((a * t) + (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) tmp = 0.0 if (Float64(b * c) <= -1.8e+184) tmp = Float64(b * c); elseif ((Float64(b * c) <= -6e+14) || (!(Float64(b * c) <= -1.2e-103) && (Float64(b * c) <= 1.85e-187))) tmp = Float64(-4.0 * Float64(Float64(a * t) + 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)
tmp = 0.0;
if ((b * c) <= -1.8e+184)
tmp = b * c;
elseif (((b * c) <= -6e+14) || (~(((b * c) <= -1.2e-103)) && ((b * c) <= 1.85e-187)))
tmp = -4.0 * ((a * t) + (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_] := If[LessEqual[N[(b * c), $MachinePrecision], -1.8e+184], N[(b * c), $MachinePrecision], If[Or[LessEqual[N[(b * c), $MachinePrecision], -6e+14], And[N[Not[LessEqual[N[(b * c), $MachinePrecision], -1.2e-103]], $MachinePrecision], LessEqual[N[(b * c), $MachinePrecision], 1.85e-187]]], N[(-4.0 * N[(N[(a * t), $MachinePrecision] + 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}
\mathbf{if}\;b \cdot c \leq -1.8 \cdot 10^{+184}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -6 \cdot 10^{+14} \lor \neg \left(b \cdot c \leq -1.2 \cdot 10^{-103}\right) \land b \cdot c \leq 1.85 \cdot 10^{-187}:\\
\;\;\;\;-4 \cdot \left(a \cdot t + x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -1.80000000000000007e184Initial program 81.3%
Taylor expanded in x around 0 81.3%
Taylor expanded in b around inf 75.2%
if -1.80000000000000007e184 < (*.f64 b c) < -6e14 or -1.2000000000000001e-103 < (*.f64 b c) < 1.85000000000000005e-187Initial program 86.5%
Taylor expanded in y around 0 73.7%
distribute-lft-out73.7%
*-commutative73.7%
Simplified73.7%
Taylor expanded in j around 0 51.9%
Taylor expanded in b around 0 50.3%
if -6e14 < (*.f64 b c) < -1.2000000000000001e-103 or 1.85000000000000005e-187 < (*.f64 b c) Initial program 89.5%
Simplified88.7%
Taylor expanded in b around inf 61.1%
Final simplification58.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 (* 18.0 (* x (* y z))))
(t_2 (* k (* j 27.0)))
(t_3 (+ (* j (* k -27.0)) (* t (+ (* -4.0 a) t_1)))))
(if (<= t -3.9e+122)
t_3
(if (<= t -6.2e-25)
(- (- (* b c) (* (* a t) 4.0)) t_2)
(if (<= t -9.8e-155)
t_3
(if (<= t 22500000.0)
(- (- (* b c) (* 4.0 (* x i))) t_2)
(+ (* b c) (* t (- t_1 (* a 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 = 18.0 * (x * (y * z));
double t_2 = k * (j * 27.0);
double t_3 = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
double tmp;
if (t <= -3.9e+122) {
tmp = t_3;
} else if (t <= -6.2e-25) {
tmp = ((b * c) - ((a * t) * 4.0)) - t_2;
} else if (t <= -9.8e-155) {
tmp = t_3;
} else if (t <= 22500000.0) {
tmp = ((b * c) - (4.0 * (x * i))) - t_2;
} else {
tmp = (b * c) + (t * (t_1 - (a * 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) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = 18.0d0 * (x * (y * z))
t_2 = k * (j * 27.0d0)
t_3 = (j * (k * (-27.0d0))) + (t * (((-4.0d0) * a) + t_1))
if (t <= (-3.9d+122)) then
tmp = t_3
else if (t <= (-6.2d-25)) then
tmp = ((b * c) - ((a * t) * 4.0d0)) - t_2
else if (t <= (-9.8d-155)) then
tmp = t_3
else if (t <= 22500000.0d0) then
tmp = ((b * c) - (4.0d0 * (x * i))) - t_2
else
tmp = (b * c) + (t * (t_1 - (a * 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 = 18.0 * (x * (y * z));
double t_2 = k * (j * 27.0);
double t_3 = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
double tmp;
if (t <= -3.9e+122) {
tmp = t_3;
} else if (t <= -6.2e-25) {
tmp = ((b * c) - ((a * t) * 4.0)) - t_2;
} else if (t <= -9.8e-155) {
tmp = t_3;
} else if (t <= 22500000.0) {
tmp = ((b * c) - (4.0 * (x * i))) - t_2;
} else {
tmp = (b * c) + (t * (t_1 - (a * 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 = 18.0 * (x * (y * z)) t_2 = k * (j * 27.0) t_3 = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1)) tmp = 0 if t <= -3.9e+122: tmp = t_3 elif t <= -6.2e-25: tmp = ((b * c) - ((a * t) * 4.0)) - t_2 elif t <= -9.8e-155: tmp = t_3 elif t <= 22500000.0: tmp = ((b * c) - (4.0 * (x * i))) - t_2 else: tmp = (b * c) + (t * (t_1 - (a * 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(18.0 * Float64(x * Float64(y * z))) t_2 = Float64(k * Float64(j * 27.0)) t_3 = Float64(Float64(j * Float64(k * -27.0)) + Float64(t * Float64(Float64(-4.0 * a) + t_1))) tmp = 0.0 if (t <= -3.9e+122) tmp = t_3; elseif (t <= -6.2e-25) tmp = Float64(Float64(Float64(b * c) - Float64(Float64(a * t) * 4.0)) - t_2); elseif (t <= -9.8e-155) tmp = t_3; elseif (t <= 22500000.0) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - t_2); else tmp = Float64(Float64(b * c) + Float64(t * Float64(t_1 - Float64(a * 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 = 18.0 * (x * (y * z));
t_2 = k * (j * 27.0);
t_3 = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
tmp = 0.0;
if (t <= -3.9e+122)
tmp = t_3;
elseif (t <= -6.2e-25)
tmp = ((b * c) - ((a * t) * 4.0)) - t_2;
elseif (t <= -9.8e-155)
tmp = t_3;
elseif (t <= 22500000.0)
tmp = ((b * c) - (4.0 * (x * i))) - t_2;
else
tmp = (b * c) + (t * (t_1 - (a * 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[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(t * N[(N[(-4.0 * a), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3.9e+122], t$95$3, If[LessEqual[t, -6.2e-25], N[(N[(N[(b * c), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[t, -9.8e-155], t$95$3, If[LessEqual[t, 22500000.0], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision], N[(N[(b * c), $MachinePrecision] + N[(t * N[(t$95$1 - N[(a * 4.0), $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 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\
t_2 := k \cdot \left(j \cdot 27\right)\\
t_3 := j \cdot \left(k \cdot -27\right) + t \cdot \left(-4 \cdot a + t\_1\right)\\
\mathbf{if}\;t \leq -3.9 \cdot 10^{+122}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;t \leq -6.2 \cdot 10^{-25}:\\
\;\;\;\;\left(b \cdot c - \left(a \cdot t\right) \cdot 4\right) - t\_2\\
\mathbf{elif}\;t \leq -9.8 \cdot 10^{-155}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;t \leq 22500000:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - t\_2\\
\mathbf{else}:\\
\;\;\;\;b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\\
\end{array}
\end{array}
if t < -3.8999999999999999e122 or -6.19999999999999989e-25 < t < -9.80000000000000026e-155Initial program 85.2%
Simplified87.8%
Taylor expanded in t around inf 79.6%
if -3.8999999999999999e122 < t < -6.19999999999999989e-25Initial program 95.9%
Taylor expanded in x around 0 75.9%
if -9.80000000000000026e-155 < t < 2.25e7Initial program 84.8%
Taylor expanded in t around 0 91.8%
if 2.25e7 < t Initial program 89.7%
Simplified93.1%
Taylor expanded in j around 0 87.9%
Taylor expanded in i around 0 81.6%
Final simplification84.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 (* k (* j 27.0)))
(t_2 (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))))
(if (<= t -1.8e+136)
t_2
(if (<= t -4.5e-42)
(- (- (* b c) (* (* a t) 4.0)) t_1)
(if (<= t -7.2e-92)
(+ (* j (* k -27.0)) (* 18.0 (* x (* y (* t z)))))
(if (<= t 31000000.0) (- (- (* b c) (* 4.0 (* x i))) 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 = k * (j * 27.0);
double t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
double tmp;
if (t <= -1.8e+136) {
tmp = t_2;
} else if (t <= -4.5e-42) {
tmp = ((b * c) - ((a * t) * 4.0)) - t_1;
} else if (t <= -7.2e-92) {
tmp = (j * (k * -27.0)) + (18.0 * (x * (y * (t * z))));
} else if (t <= 31000000.0) {
tmp = ((b * c) - (4.0 * (x * i))) - 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 = k * (j * 27.0d0)
t_2 = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
if (t <= (-1.8d+136)) then
tmp = t_2
else if (t <= (-4.5d-42)) then
tmp = ((b * c) - ((a * t) * 4.0d0)) - t_1
else if (t <= (-7.2d-92)) then
tmp = (j * (k * (-27.0d0))) + (18.0d0 * (x * (y * (t * z))))
else if (t <= 31000000.0d0) then
tmp = ((b * c) - (4.0d0 * (x * i))) - 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 = k * (j * 27.0);
double t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
double tmp;
if (t <= -1.8e+136) {
tmp = t_2;
} else if (t <= -4.5e-42) {
tmp = ((b * c) - ((a * t) * 4.0)) - t_1;
} else if (t <= -7.2e-92) {
tmp = (j * (k * -27.0)) + (18.0 * (x * (y * (t * z))));
} else if (t <= 31000000.0) {
tmp = ((b * c) - (4.0 * (x * i))) - 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 = k * (j * 27.0) t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0))) tmp = 0 if t <= -1.8e+136: tmp = t_2 elif t <= -4.5e-42: tmp = ((b * c) - ((a * t) * 4.0)) - t_1 elif t <= -7.2e-92: tmp = (j * (k * -27.0)) + (18.0 * (x * (y * (t * z)))) elif t <= 31000000.0: tmp = ((b * c) - (4.0 * (x * i))) - 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(k * Float64(j * 27.0)) t_2 = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0)))) tmp = 0.0 if (t <= -1.8e+136) tmp = t_2; elseif (t <= -4.5e-42) tmp = Float64(Float64(Float64(b * c) - Float64(Float64(a * t) * 4.0)) - t_1); elseif (t <= -7.2e-92) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(18.0 * Float64(x * Float64(y * Float64(t * z))))); elseif (t <= 31000000.0) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - 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 = k * (j * 27.0);
t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
tmp = 0.0;
if (t <= -1.8e+136)
tmp = t_2;
elseif (t <= -4.5e-42)
tmp = ((b * c) - ((a * t) * 4.0)) - t_1;
elseif (t <= -7.2e-92)
tmp = (j * (k * -27.0)) + (18.0 * (x * (y * (t * z))));
elseif (t <= 31000000.0)
tmp = ((b * c) - (4.0 * (x * i))) - 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[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = 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]}, If[LessEqual[t, -1.8e+136], t$95$2, If[LessEqual[t, -4.5e-42], N[(N[(N[(b * c), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[t, -7.2e-92], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(x * N[(y * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 31000000.0], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $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 := k \cdot \left(j \cdot 27\right)\\
t_2 := b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\
\mathbf{if}\;t \leq -1.8 \cdot 10^{+136}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -4.5 \cdot 10^{-42}:\\
\;\;\;\;\left(b \cdot c - \left(a \cdot t\right) \cdot 4\right) - t\_1\\
\mathbf{elif}\;t \leq -7.2 \cdot 10^{-92}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + 18 \cdot \left(x \cdot \left(y \cdot \left(t \cdot z\right)\right)\right)\\
\mathbf{elif}\;t \leq 31000000:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -1.80000000000000003e136 or 3.1e7 < t Initial program 85.8%
Simplified89.5%
Taylor expanded in j around 0 84.8%
Taylor expanded in i around 0 82.2%
if -1.80000000000000003e136 < t < -4.5e-42Initial program 96.9%
Taylor expanded in x around 0 78.9%
if -4.5e-42 < t < -7.20000000000000032e-92Initial program 92.0%
Simplified76.5%
Taylor expanded in y around inf 51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in x around 0 51.8%
*-commutative51.8%
associate-*r*59.4%
associate-*l*59.4%
Simplified59.4%
if -7.20000000000000032e-92 < t < 3.1e7Initial program 84.9%
Taylor expanded in t around 0 87.3%
Final simplification82.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 (* -4.0 (+ (* a t) (* x i)))))
(if (<= (* b c) -1.05e+189)
(* b c)
(if (<= (* b c) -10500000000.0)
t_1
(if (<= (* b c) -4.3e-107)
(* -27.0 (* j k))
(if (<= (* b c) 4.7e+100) 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 * ((a * t) + (x * i));
double tmp;
if ((b * c) <= -1.05e+189) {
tmp = b * c;
} else if ((b * c) <= -10500000000.0) {
tmp = t_1;
} else if ((b * c) <= -4.3e-107) {
tmp = -27.0 * (j * k);
} else if ((b * c) <= 4.7e+100) {
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) * ((a * t) + (x * i))
if ((b * c) <= (-1.05d+189)) then
tmp = b * c
else if ((b * c) <= (-10500000000.0d0)) then
tmp = t_1
else if ((b * c) <= (-4.3d-107)) then
tmp = (-27.0d0) * (j * k)
else if ((b * c) <= 4.7d+100) 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 * ((a * t) + (x * i));
double tmp;
if ((b * c) <= -1.05e+189) {
tmp = b * c;
} else if ((b * c) <= -10500000000.0) {
tmp = t_1;
} else if ((b * c) <= -4.3e-107) {
tmp = -27.0 * (j * k);
} else if ((b * c) <= 4.7e+100) {
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 * ((a * t) + (x * i)) tmp = 0 if (b * c) <= -1.05e+189: tmp = b * c elif (b * c) <= -10500000000.0: tmp = t_1 elif (b * c) <= -4.3e-107: tmp = -27.0 * (j * k) elif (b * c) <= 4.7e+100: 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(Float64(a * t) + Float64(x * i))) tmp = 0.0 if (Float64(b * c) <= -1.05e+189) tmp = Float64(b * c); elseif (Float64(b * c) <= -10500000000.0) tmp = t_1; elseif (Float64(b * c) <= -4.3e-107) tmp = Float64(-27.0 * Float64(j * k)); elseif (Float64(b * c) <= 4.7e+100) 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 * ((a * t) + (x * i));
tmp = 0.0;
if ((b * c) <= -1.05e+189)
tmp = b * c;
elseif ((b * c) <= -10500000000.0)
tmp = t_1;
elseif ((b * c) <= -4.3e-107)
tmp = -27.0 * (j * k);
elseif ((b * c) <= 4.7e+100)
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[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -1.05e+189], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -10500000000.0], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -4.3e-107], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 4.7e+100], 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(a \cdot t + x \cdot i\right)\\
\mathbf{if}\;b \cdot c \leq -1.05 \cdot 10^{+189}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -10500000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \cdot c \leq -4.3 \cdot 10^{-107}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;b \cdot c \leq 4.7 \cdot 10^{+100}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -1.04999999999999996e189 or 4.7e100 < (*.f64 b c) Initial program 85.3%
Taylor expanded in x around 0 85.3%
Taylor expanded in b around inf 69.9%
if -1.04999999999999996e189 < (*.f64 b c) < -1.05e10 or -4.2999999999999997e-107 < (*.f64 b c) < 4.7e100Initial program 87.7%
Taylor expanded in y around 0 74.7%
distribute-lft-out74.7%
*-commutative74.7%
Simplified74.7%
Taylor expanded in j around 0 51.2%
Taylor expanded in b around 0 46.3%
if -1.05e10 < (*.f64 b c) < -4.2999999999999997e-107Initial program 89.9%
Simplified94.8%
Taylor expanded in j around inf 56.5%
Final simplification54.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 (* k -27.0)) (* 18.0 (* t (* x (* y z))))))
(t_2 (- (* b c) (* 4.0 (+ (* a t) (* x i))))))
(if (<= k -2.8e-47)
t_1
(if (<= k 1.26e-164)
t_2
(if (<= k 1.2e-136)
t_1
(if (<= k 4e+27)
t_2
(- (- (* b c) (* (* a t) 4.0)) (* k (* j 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 * (k * -27.0)) + (18.0 * (t * (x * (y * z))));
double t_2 = (b * c) - (4.0 * ((a * t) + (x * i)));
double tmp;
if (k <= -2.8e-47) {
tmp = t_1;
} else if (k <= 1.26e-164) {
tmp = t_2;
} else if (k <= 1.2e-136) {
tmp = t_1;
} else if (k <= 4e+27) {
tmp = t_2;
} else {
tmp = ((b * c) - ((a * t) * 4.0)) - (k * (j * 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) :: t_2
real(8) :: tmp
t_1 = (j * (k * (-27.0d0))) + (18.0d0 * (t * (x * (y * z))))
t_2 = (b * c) - (4.0d0 * ((a * t) + (x * i)))
if (k <= (-2.8d-47)) then
tmp = t_1
else if (k <= 1.26d-164) then
tmp = t_2
else if (k <= 1.2d-136) then
tmp = t_1
else if (k <= 4d+27) then
tmp = t_2
else
tmp = ((b * c) - ((a * t) * 4.0d0)) - (k * (j * 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 * (k * -27.0)) + (18.0 * (t * (x * (y * z))));
double t_2 = (b * c) - (4.0 * ((a * t) + (x * i)));
double tmp;
if (k <= -2.8e-47) {
tmp = t_1;
} else if (k <= 1.26e-164) {
tmp = t_2;
} else if (k <= 1.2e-136) {
tmp = t_1;
} else if (k <= 4e+27) {
tmp = t_2;
} else {
tmp = ((b * c) - ((a * t) * 4.0)) - (k * (j * 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 * (k * -27.0)) + (18.0 * (t * (x * (y * z)))) t_2 = (b * c) - (4.0 * ((a * t) + (x * i))) tmp = 0 if k <= -2.8e-47: tmp = t_1 elif k <= 1.26e-164: tmp = t_2 elif k <= 1.2e-136: tmp = t_1 elif k <= 4e+27: tmp = t_2 else: tmp = ((b * c) - ((a * t) * 4.0)) - (k * (j * 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 * Float64(k * -27.0)) + Float64(18.0 * Float64(t * Float64(x * Float64(y * z))))) t_2 = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(a * t) + Float64(x * i)))) tmp = 0.0 if (k <= -2.8e-47) tmp = t_1; elseif (k <= 1.26e-164) tmp = t_2; elseif (k <= 1.2e-136) tmp = t_1; elseif (k <= 4e+27) tmp = t_2; else tmp = Float64(Float64(Float64(b * c) - Float64(Float64(a * t) * 4.0)) - Float64(k * Float64(j * 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 * (k * -27.0)) + (18.0 * (t * (x * (y * z))));
t_2 = (b * c) - (4.0 * ((a * t) + (x * i)));
tmp = 0.0;
if (k <= -2.8e-47)
tmp = t_1;
elseif (k <= 1.26e-164)
tmp = t_2;
elseif (k <= 1.2e-136)
tmp = t_1;
elseif (k <= 4e+27)
tmp = t_2;
else
tmp = ((b * c) - ((a * t) * 4.0)) - (k * (j * 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 * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -2.8e-47], t$95$1, If[LessEqual[k, 1.26e-164], t$95$2, If[LessEqual[k, 1.2e-136], t$95$1, If[LessEqual[k, 4e+27], t$95$2, N[(N[(N[(b * c), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision] - N[(k * N[(j * 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 := j \cdot \left(k \cdot -27\right) + 18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
t_2 := b \cdot c - 4 \cdot \left(a \cdot t + x \cdot i\right)\\
\mathbf{if}\;k \leq -2.8 \cdot 10^{-47}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq 1.26 \cdot 10^{-164}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;k \leq 1.2 \cdot 10^{-136}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq 4 \cdot 10^{+27}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - \left(a \cdot t\right) \cdot 4\right) - k \cdot \left(j \cdot 27\right)\\
\end{array}
\end{array}
if k < -2.79999999999999993e-47 or 1.26e-164 < k < 1.1999999999999999e-136Initial program 83.7%
Simplified85.2%
Taylor expanded in y around inf 55.8%
*-commutative55.8%
Simplified55.8%
if -2.79999999999999993e-47 < k < 1.26e-164 or 1.1999999999999999e-136 < k < 4.0000000000000001e27Initial program 91.1%
Taylor expanded in y around 0 81.6%
distribute-lft-out81.6%
*-commutative81.6%
Simplified81.6%
Taylor expanded in j around 0 77.0%
if 4.0000000000000001e27 < k Initial program 84.7%
Taylor expanded in x around 0 72.4%
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 (* j (* k -27.0))))
(if (<= j -6.5e+249)
(+ t_1 (* 18.0 (* x (* y (* t z)))))
(if (<= j -5.2e+202)
(- (* b c) (* 4.0 (* i (+ x (/ (* a t) i)))))
(if (<= j -1.46e+144)
(+ t_1 (* x (* -4.0 i)))
(if (<= j 5e-68)
(- (* b c) (* 4.0 (+ (* a t) (* x i))))
(+ t_1 (* 18.0 (* t (* z (* y x)))))))))))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 (j <= -6.5e+249) {
tmp = t_1 + (18.0 * (x * (y * (t * z))));
} else if (j <= -5.2e+202) {
tmp = (b * c) - (4.0 * (i * (x + ((a * t) / i))));
} else if (j <= -1.46e+144) {
tmp = t_1 + (x * (-4.0 * i));
} else if (j <= 5e-68) {
tmp = (b * c) - (4.0 * ((a * t) + (x * i)));
} else {
tmp = t_1 + (18.0 * (t * (z * (y * x))));
}
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 (j <= (-6.5d+249)) then
tmp = t_1 + (18.0d0 * (x * (y * (t * z))))
else if (j <= (-5.2d+202)) then
tmp = (b * c) - (4.0d0 * (i * (x + ((a * t) / i))))
else if (j <= (-1.46d+144)) then
tmp = t_1 + (x * ((-4.0d0) * i))
else if (j <= 5d-68) then
tmp = (b * c) - (4.0d0 * ((a * t) + (x * i)))
else
tmp = t_1 + (18.0d0 * (t * (z * (y * x))))
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 (j <= -6.5e+249) {
tmp = t_1 + (18.0 * (x * (y * (t * z))));
} else if (j <= -5.2e+202) {
tmp = (b * c) - (4.0 * (i * (x + ((a * t) / i))));
} else if (j <= -1.46e+144) {
tmp = t_1 + (x * (-4.0 * i));
} else if (j <= 5e-68) {
tmp = (b * c) - (4.0 * ((a * t) + (x * i)));
} else {
tmp = t_1 + (18.0 * (t * (z * (y * x))));
}
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 j <= -6.5e+249: tmp = t_1 + (18.0 * (x * (y * (t * z)))) elif j <= -5.2e+202: tmp = (b * c) - (4.0 * (i * (x + ((a * t) / i)))) elif j <= -1.46e+144: tmp = t_1 + (x * (-4.0 * i)) elif j <= 5e-68: tmp = (b * c) - (4.0 * ((a * t) + (x * i))) else: tmp = t_1 + (18.0 * (t * (z * (y * x)))) 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 (j <= -6.5e+249) tmp = Float64(t_1 + Float64(18.0 * Float64(x * Float64(y * Float64(t * z))))); elseif (j <= -5.2e+202) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(i * Float64(x + Float64(Float64(a * t) / i))))); elseif (j <= -1.46e+144) tmp = Float64(t_1 + Float64(x * Float64(-4.0 * i))); elseif (j <= 5e-68) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(a * t) + Float64(x * i)))); else tmp = Float64(t_1 + Float64(18.0 * Float64(t * Float64(z * Float64(y * x))))); 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 (j <= -6.5e+249)
tmp = t_1 + (18.0 * (x * (y * (t * z))));
elseif (j <= -5.2e+202)
tmp = (b * c) - (4.0 * (i * (x + ((a * t) / i))));
elseif (j <= -1.46e+144)
tmp = t_1 + (x * (-4.0 * i));
elseif (j <= 5e-68)
tmp = (b * c) - (4.0 * ((a * t) + (x * i)));
else
tmp = t_1 + (18.0 * (t * (z * (y * x))));
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[j, -6.5e+249], N[(t$95$1 + N[(18.0 * N[(x * N[(y * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -5.2e+202], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(i * N[(x + N[(N[(a * t), $MachinePrecision] / i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -1.46e+144], N[(t$95$1 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 5e-68], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(18.0 * N[(t * N[(z * N[(y * x), $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 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;j \leq -6.5 \cdot 10^{+249}:\\
\;\;\;\;t\_1 + 18 \cdot \left(x \cdot \left(y \cdot \left(t \cdot z\right)\right)\right)\\
\mathbf{elif}\;j \leq -5.2 \cdot 10^{+202}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(i \cdot \left(x + \frac{a \cdot t}{i}\right)\right)\\
\mathbf{elif}\;j \leq -1.46 \cdot 10^{+144}:\\
\;\;\;\;t\_1 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;j \leq 5 \cdot 10^{-68}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(a \cdot t + x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1 + 18 \cdot \left(t \cdot \left(z \cdot \left(y \cdot x\right)\right)\right)\\
\end{array}
\end{array}
if j < -6.50000000000000028e249Initial program 77.4%
Simplified85.0%
Taylor expanded in y around inf 78.5%
*-commutative78.5%
Simplified78.5%
Taylor expanded in x around 0 78.5%
*-commutative78.5%
associate-*r*85.3%
associate-*l*85.3%
Simplified85.3%
if -6.50000000000000028e249 < j < -5.2000000000000004e202Initial program 99.9%
Taylor expanded in y around 0 92.0%
distribute-lft-out92.0%
*-commutative92.0%
Simplified92.0%
Taylor expanded in i around inf 92.1%
Taylor expanded in j around 0 75.6%
if -5.2000000000000004e202 < j < -1.46e144Initial program 69.0%
Simplified69.2%
Taylor expanded in i around inf 76.9%
*-commutative76.9%
*-commutative76.9%
associate-*l*76.9%
*-commutative76.9%
Simplified76.9%
if -1.46e144 < j < 4.99999999999999971e-68Initial program 90.2%
Taylor expanded in y around 0 78.9%
distribute-lft-out78.9%
*-commutative78.9%
Simplified78.9%
Taylor expanded in j around 0 69.5%
if 4.99999999999999971e-68 < j Initial program 84.2%
Simplified83.0%
Taylor expanded in y around inf 53.9%
*-commutative53.9%
Simplified53.9%
pow153.9%
Applied egg-rr53.9%
unpow153.9%
associate-*r*57.7%
Simplified57.7%
Final simplification67.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)))
(t_2 (+ t_1 (* 18.0 (* t (* x (* y z))))))
(t_3 (- (* b c) (* 4.0 (+ (* a t) (* x i))))))
(if (<= k -8.6e-48)
t_2
(if (<= k 1.26e-164)
t_3
(if (<= k 1.95e-136)
t_2
(if (<= k 1.6e+131) t_3 (+ t_1 (* 18.0 (* t (* z (* y x)))))))))))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 = t_1 + (18.0 * (t * (x * (y * z))));
double t_3 = (b * c) - (4.0 * ((a * t) + (x * i)));
double tmp;
if (k <= -8.6e-48) {
tmp = t_2;
} else if (k <= 1.26e-164) {
tmp = t_3;
} else if (k <= 1.95e-136) {
tmp = t_2;
} else if (k <= 1.6e+131) {
tmp = t_3;
} else {
tmp = t_1 + (18.0 * (t * (z * (y * x))));
}
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 = j * (k * (-27.0d0))
t_2 = t_1 + (18.0d0 * (t * (x * (y * z))))
t_3 = (b * c) - (4.0d0 * ((a * t) + (x * i)))
if (k <= (-8.6d-48)) then
tmp = t_2
else if (k <= 1.26d-164) then
tmp = t_3
else if (k <= 1.95d-136) then
tmp = t_2
else if (k <= 1.6d+131) then
tmp = t_3
else
tmp = t_1 + (18.0d0 * (t * (z * (y * x))))
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 = t_1 + (18.0 * (t * (x * (y * z))));
double t_3 = (b * c) - (4.0 * ((a * t) + (x * i)));
double tmp;
if (k <= -8.6e-48) {
tmp = t_2;
} else if (k <= 1.26e-164) {
tmp = t_3;
} else if (k <= 1.95e-136) {
tmp = t_2;
} else if (k <= 1.6e+131) {
tmp = t_3;
} else {
tmp = t_1 + (18.0 * (t * (z * (y * x))));
}
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 = t_1 + (18.0 * (t * (x * (y * z)))) t_3 = (b * c) - (4.0 * ((a * t) + (x * i))) tmp = 0 if k <= -8.6e-48: tmp = t_2 elif k <= 1.26e-164: tmp = t_3 elif k <= 1.95e-136: tmp = t_2 elif k <= 1.6e+131: tmp = t_3 else: tmp = t_1 + (18.0 * (t * (z * (y * x)))) 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(t_1 + Float64(18.0 * Float64(t * Float64(x * Float64(y * z))))) t_3 = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(a * t) + Float64(x * i)))) tmp = 0.0 if (k <= -8.6e-48) tmp = t_2; elseif (k <= 1.26e-164) tmp = t_3; elseif (k <= 1.95e-136) tmp = t_2; elseif (k <= 1.6e+131) tmp = t_3; else tmp = Float64(t_1 + Float64(18.0 * Float64(t * Float64(z * Float64(y * x))))); 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 = t_1 + (18.0 * (t * (x * (y * z))));
t_3 = (b * c) - (4.0 * ((a * t) + (x * i)));
tmp = 0.0;
if (k <= -8.6e-48)
tmp = t_2;
elseif (k <= 1.26e-164)
tmp = t_3;
elseif (k <= 1.95e-136)
tmp = t_2;
elseif (k <= 1.6e+131)
tmp = t_3;
else
tmp = t_1 + (18.0 * (t * (z * (y * x))));
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[(t$95$1 + N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -8.6e-48], t$95$2, If[LessEqual[k, 1.26e-164], t$95$3, If[LessEqual[k, 1.95e-136], t$95$2, If[LessEqual[k, 1.6e+131], t$95$3, N[(t$95$1 + N[(18.0 * N[(t * N[(z * N[(y * x), $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 := j \cdot \left(k \cdot -27\right)\\
t_2 := t\_1 + 18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
t_3 := b \cdot c - 4 \cdot \left(a \cdot t + x \cdot i\right)\\
\mathbf{if}\;k \leq -8.6 \cdot 10^{-48}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;k \leq 1.26 \cdot 10^{-164}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;k \leq 1.95 \cdot 10^{-136}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;k \leq 1.6 \cdot 10^{+131}:\\
\;\;\;\;t\_3\\
\mathbf{else}:\\
\;\;\;\;t\_1 + 18 \cdot \left(t \cdot \left(z \cdot \left(y \cdot x\right)\right)\right)\\
\end{array}
\end{array}
if k < -8.6e-48 or 1.26e-164 < k < 1.94999999999999988e-136Initial program 83.7%
Simplified85.2%
Taylor expanded in y around inf 55.8%
*-commutative55.8%
Simplified55.8%
if -8.6e-48 < k < 1.26e-164 or 1.94999999999999988e-136 < k < 1.6000000000000001e131Initial program 90.2%
Taylor expanded in y around 0 80.9%
distribute-lft-out80.9%
*-commutative80.9%
Simplified80.9%
Taylor expanded in j around 0 70.2%
if 1.6000000000000001e131 < k Initial program 82.8%
Simplified83.0%
Taylor expanded in y around inf 61.1%
*-commutative61.1%
Simplified61.1%
pow161.1%
Applied egg-rr61.1%
unpow161.1%
associate-*r*63.8%
Simplified63.8%
Final simplification64.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 (+ (* a t) (* x i))))))
(if (<= k -2.6)
(+ (* j (* k -27.0)) (* -4.0 (* a t)))
(if (<= k 1.55e-197)
t_1
(if (<= k 1.95e-136)
(* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))
(if (<= k 4.3e+128) t_1 (* k (+ (* j -27.0) (/ (* b c) 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 * ((a * t) + (x * i)));
double tmp;
if (k <= -2.6) {
tmp = (j * (k * -27.0)) + (-4.0 * (a * t));
} else if (k <= 1.55e-197) {
tmp = t_1;
} else if (k <= 1.95e-136) {
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
} else if (k <= 4.3e+128) {
tmp = t_1;
} else {
tmp = k * ((j * -27.0) + ((b * c) / 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 * ((a * t) + (x * i)))
if (k <= (-2.6d0)) then
tmp = (j * (k * (-27.0d0))) + ((-4.0d0) * (a * t))
else if (k <= 1.55d-197) then
tmp = t_1
else if (k <= 1.95d-136) then
tmp = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
else if (k <= 4.3d+128) then
tmp = t_1
else
tmp = k * ((j * (-27.0d0)) + ((b * c) / 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 * ((a * t) + (x * i)));
double tmp;
if (k <= -2.6) {
tmp = (j * (k * -27.0)) + (-4.0 * (a * t));
} else if (k <= 1.55e-197) {
tmp = t_1;
} else if (k <= 1.95e-136) {
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
} else if (k <= 4.3e+128) {
tmp = t_1;
} else {
tmp = k * ((j * -27.0) + ((b * c) / 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 * ((a * t) + (x * i))) tmp = 0 if k <= -2.6: tmp = (j * (k * -27.0)) + (-4.0 * (a * t)) elif k <= 1.55e-197: tmp = t_1 elif k <= 1.95e-136: tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i)) elif k <= 4.3e+128: tmp = t_1 else: tmp = k * ((j * -27.0) + ((b * c) / 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(Float64(a * t) + Float64(x * i)))) tmp = 0.0 if (k <= -2.6) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(-4.0 * Float64(a * t))); elseif (k <= 1.55e-197) tmp = t_1; elseif (k <= 1.95e-136) tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i))); elseif (k <= 4.3e+128) tmp = t_1; else tmp = Float64(k * Float64(Float64(j * -27.0) + Float64(Float64(b * c) / 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 * ((a * t) + (x * i)));
tmp = 0.0;
if (k <= -2.6)
tmp = (j * (k * -27.0)) + (-4.0 * (a * t));
elseif (k <= 1.55e-197)
tmp = t_1;
elseif (k <= 1.95e-136)
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
elseif (k <= 4.3e+128)
tmp = t_1;
else
tmp = k * ((j * -27.0) + ((b * c) / 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[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -2.6], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.55e-197], t$95$1, If[LessEqual[k, 1.95e-136], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 4.3e+128], t$95$1, N[(k * N[(N[(j * -27.0), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] / k), $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(a \cdot t + x \cdot i\right)\\
\mathbf{if}\;k \leq -2.6:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + -4 \cdot \left(a \cdot t\right)\\
\mathbf{elif}\;k \leq 1.55 \cdot 10^{-197}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq 1.95 \cdot 10^{-136}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\
\mathbf{elif}\;k \leq 4.3 \cdot 10^{+128}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27 + \frac{b \cdot c}{k}\right)\\
\end{array}
\end{array}
if k < -2.60000000000000009Initial program 84.3%
Simplified84.6%
Taylor expanded in a around inf 58.3%
if -2.60000000000000009 < k < 1.55000000000000014e-197 or 1.94999999999999988e-136 < k < 4.29999999999999975e128Initial program 89.9%
Taylor expanded in y around 0 80.3%
distribute-lft-out80.3%
*-commutative80.3%
Simplified80.3%
Taylor expanded in j around 0 69.3%
if 1.55000000000000014e-197 < k < 1.94999999999999988e-136Initial program 77.8%
Simplified88.5%
Taylor expanded in x around inf 65.4%
if 4.29999999999999975e128 < k Initial program 83.3%
Simplified83.4%
Taylor expanded in b around inf 62.3%
Taylor expanded in k around inf 65.1%
Final simplification65.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 (* 18.0 (* x (* y z)))))
(if (<= t -9.5e+123)
(+ (* j (* k -27.0)) (* t (+ (* -4.0 a) t_1)))
(if (<= t 0.0145)
(- (- (* b c) (* 4.0 (+ (* a t) (* x i)))) (* k (* j 27.0)))
(- (+ (* b c) (* t (- t_1 (* 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 t_1 = 18.0 * (x * (y * z));
double tmp;
if (t <= -9.5e+123) {
tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
} else if (t <= 0.0145) {
tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0));
} else {
tmp = ((b * c) + (t * (t_1 - (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) :: t_1
real(8) :: tmp
t_1 = 18.0d0 * (x * (y * z))
if (t <= (-9.5d+123)) then
tmp = (j * (k * (-27.0d0))) + (t * (((-4.0d0) * a) + t_1))
else if (t <= 0.0145d0) then
tmp = ((b * c) - (4.0d0 * ((a * t) + (x * i)))) - (k * (j * 27.0d0))
else
tmp = ((b * c) + (t * (t_1 - (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 t_1 = 18.0 * (x * (y * z));
double tmp;
if (t <= -9.5e+123) {
tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
} else if (t <= 0.0145) {
tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0));
} else {
tmp = ((b * c) + (t * (t_1 - (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): t_1 = 18.0 * (x * (y * z)) tmp = 0 if t <= -9.5e+123: tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1)) elif t <= 0.0145: tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0)) else: tmp = ((b * c) + (t * (t_1 - (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) t_1 = Float64(18.0 * Float64(x * Float64(y * z))) tmp = 0.0 if (t <= -9.5e+123) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(t * Float64(Float64(-4.0 * a) + t_1))); elseif (t <= 0.0145) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(a * t) + Float64(x * i)))) - Float64(k * Float64(j * 27.0))); else tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(t_1 - 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)
t_1 = 18.0 * (x * (y * z));
tmp = 0.0;
if (t <= -9.5e+123)
tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
elseif (t <= 0.0145)
tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0));
else
tmp = ((b * c) + (t * (t_1 - (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_] := Block[{t$95$1 = N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -9.5e+123], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(t * N[(N[(-4.0 * a), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 0.0145], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(t$95$1 - N[(a * 4.0), $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}
t_1 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\
\mathbf{if}\;t \leq -9.5 \cdot 10^{+123}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(-4 \cdot a + t\_1\right)\\
\mathbf{elif}\;t \leq 0.0145:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(a \cdot t + x \cdot i\right)\right) - k \cdot \left(j \cdot 27\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\right) - 4 \cdot \left(x \cdot i\right)\\
\end{array}
\end{array}
if t < -9.4999999999999996e123Initial program 82.1%
Simplified87.9%
Taylor expanded in t around inf 86.5%
if -9.4999999999999996e123 < t < 0.0145000000000000007Initial program 88.4%
Taylor expanded in y around 0 86.5%
distribute-lft-out86.5%
*-commutative86.5%
Simplified86.5%
if 0.0145000000000000007 < t Initial program 88.5%
Simplified93.4%
Taylor expanded in j around 0 88.3%
Final simplification86.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 (* k (* j 27.0))))
(if (<= t -5.1e+139)
(* t (- (* a (- 4.0)) (* (* y z) (* x -18.0))))
(if (<= t -1.65e-32)
(- (- (* b c) (* (* a t) 4.0)) t_1)
(if (<= t 0.0195)
(- (- (* b c) (* 4.0 (* x i))) t_1)
(- (* b c) (* 4.0 (+ (* a t) (* 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 t_1 = k * (j * 27.0);
double tmp;
if (t <= -5.1e+139) {
tmp = t * ((a * -4.0) - ((y * z) * (x * -18.0)));
} else if (t <= -1.65e-32) {
tmp = ((b * c) - ((a * t) * 4.0)) - t_1;
} else if (t <= 0.0195) {
tmp = ((b * c) - (4.0 * (x * i))) - t_1;
} else {
tmp = (b * c) - (4.0 * ((a * t) + (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) :: t_1
real(8) :: tmp
t_1 = k * (j * 27.0d0)
if (t <= (-5.1d+139)) then
tmp = t * ((a * -4.0d0) - ((y * z) * (x * (-18.0d0))))
else if (t <= (-1.65d-32)) then
tmp = ((b * c) - ((a * t) * 4.0d0)) - t_1
else if (t <= 0.0195d0) then
tmp = ((b * c) - (4.0d0 * (x * i))) - t_1
else
tmp = (b * c) - (4.0d0 * ((a * t) + (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 t_1 = k * (j * 27.0);
double tmp;
if (t <= -5.1e+139) {
tmp = t * ((a * -4.0) - ((y * z) * (x * -18.0)));
} else if (t <= -1.65e-32) {
tmp = ((b * c) - ((a * t) * 4.0)) - t_1;
} else if (t <= 0.0195) {
tmp = ((b * c) - (4.0 * (x * i))) - t_1;
} else {
tmp = (b * c) - (4.0 * ((a * t) + (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): t_1 = k * (j * 27.0) tmp = 0 if t <= -5.1e+139: tmp = t * ((a * -4.0) - ((y * z) * (x * -18.0))) elif t <= -1.65e-32: tmp = ((b * c) - ((a * t) * 4.0)) - t_1 elif t <= 0.0195: tmp = ((b * c) - (4.0 * (x * i))) - t_1 else: tmp = (b * c) - (4.0 * ((a * t) + (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) t_1 = Float64(k * Float64(j * 27.0)) tmp = 0.0 if (t <= -5.1e+139) tmp = Float64(t * Float64(Float64(a * Float64(-4.0)) - Float64(Float64(y * z) * Float64(x * -18.0)))); elseif (t <= -1.65e-32) tmp = Float64(Float64(Float64(b * c) - Float64(Float64(a * t) * 4.0)) - t_1); elseif (t <= 0.0195) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - t_1); else tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(a * t) + 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)
t_1 = k * (j * 27.0);
tmp = 0.0;
if (t <= -5.1e+139)
tmp = t * ((a * -4.0) - ((y * z) * (x * -18.0)));
elseif (t <= -1.65e-32)
tmp = ((b * c) - ((a * t) * 4.0)) - t_1;
elseif (t <= 0.0195)
tmp = ((b * c) - (4.0 * (x * i))) - t_1;
else
tmp = (b * c) - (4.0 * ((a * t) + (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_] := Block[{t$95$1 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -5.1e+139], N[(t * N[(N[(a * (-4.0)), $MachinePrecision] - N[(N[(y * z), $MachinePrecision] * N[(x * -18.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -1.65e-32], N[(N[(N[(b * c), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[t, 0.0195], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $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 := k \cdot \left(j \cdot 27\right)\\
\mathbf{if}\;t \leq -5.1 \cdot 10^{+139}:\\
\;\;\;\;t \cdot \left(a \cdot \left(-4\right) - \left(y \cdot z\right) \cdot \left(x \cdot -18\right)\right)\\
\mathbf{elif}\;t \leq -1.65 \cdot 10^{-32}:\\
\;\;\;\;\left(b \cdot c - \left(a \cdot t\right) \cdot 4\right) - t\_1\\
\mathbf{elif}\;t \leq 0.0195:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(a \cdot t + x \cdot i\right)\\
\end{array}
\end{array}
if t < -5.10000000000000037e139Initial program 80.9%
Taylor expanded in t around -inf 79.6%
associate-*r*79.6%
neg-mul-179.6%
cancel-sign-sub-inv79.6%
associate-*r*79.6%
metadata-eval79.6%
*-commutative79.6%
Simplified79.6%
if -5.10000000000000037e139 < t < -1.65000000000000013e-32Initial program 96.7%
Taylor expanded in x around 0 77.5%
if -1.65000000000000013e-32 < t < 0.0195Initial program 86.4%
Taylor expanded in t around 0 83.6%
if 0.0195 < t Initial program 88.5%
Taylor expanded in y around 0 74.7%
distribute-lft-out74.7%
*-commutative74.7%
Simplified74.7%
Taylor expanded in j around 0 69.5%
Final simplification78.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 (+ (* b c) (* j (* k -27.0)))))
(if (<= j -1.55e+126)
t_1
(if (<= j -1.62e+103)
(* -4.0 (+ (* a t) (* x i)))
(if (or (<= j -4.5e+77) (not (<= j 7.6e-105)))
t_1
(- (* b c) (* a (* t 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 = (b * c) + (j * (k * -27.0));
double tmp;
if (j <= -1.55e+126) {
tmp = t_1;
} else if (j <= -1.62e+103) {
tmp = -4.0 * ((a * t) + (x * i));
} else if ((j <= -4.5e+77) || !(j <= 7.6e-105)) {
tmp = t_1;
} else {
tmp = (b * c) - (a * (t * 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 = (b * c) + (j * (k * (-27.0d0)))
if (j <= (-1.55d+126)) then
tmp = t_1
else if (j <= (-1.62d+103)) then
tmp = (-4.0d0) * ((a * t) + (x * i))
else if ((j <= (-4.5d+77)) .or. (.not. (j <= 7.6d-105))) then
tmp = t_1
else
tmp = (b * c) - (a * (t * 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 = (b * c) + (j * (k * -27.0));
double tmp;
if (j <= -1.55e+126) {
tmp = t_1;
} else if (j <= -1.62e+103) {
tmp = -4.0 * ((a * t) + (x * i));
} else if ((j <= -4.5e+77) || !(j <= 7.6e-105)) {
tmp = t_1;
} else {
tmp = (b * c) - (a * (t * 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 = (b * c) + (j * (k * -27.0)) tmp = 0 if j <= -1.55e+126: tmp = t_1 elif j <= -1.62e+103: tmp = -4.0 * ((a * t) + (x * i)) elif (j <= -4.5e+77) or not (j <= 7.6e-105): tmp = t_1 else: tmp = (b * c) - (a * (t * 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(b * c) + Float64(j * Float64(k * -27.0))) tmp = 0.0 if (j <= -1.55e+126) tmp = t_1; elseif (j <= -1.62e+103) tmp = Float64(-4.0 * Float64(Float64(a * t) + Float64(x * i))); elseif ((j <= -4.5e+77) || !(j <= 7.6e-105)) tmp = t_1; else tmp = Float64(Float64(b * c) - Float64(a * Float64(t * 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 = (b * c) + (j * (k * -27.0));
tmp = 0.0;
if (j <= -1.55e+126)
tmp = t_1;
elseif (j <= -1.62e+103)
tmp = -4.0 * ((a * t) + (x * i));
elseif ((j <= -4.5e+77) || ~((j <= 7.6e-105)))
tmp = t_1;
else
tmp = (b * c) - (a * (t * 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[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -1.55e+126], t$95$1, If[LessEqual[j, -1.62e+103], N[(-4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[j, -4.5e+77], N[Not[LessEqual[j, 7.6e-105]], $MachinePrecision]], t$95$1, N[(N[(b * c), $MachinePrecision] - N[(a * N[(t * 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 := b \cdot c + j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;j \leq -1.55 \cdot 10^{+126}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -1.62 \cdot 10^{+103}:\\
\;\;\;\;-4 \cdot \left(a \cdot t + x \cdot i\right)\\
\mathbf{elif}\;j \leq -4.5 \cdot 10^{+77} \lor \neg \left(j \leq 7.6 \cdot 10^{-105}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c - a \cdot \left(t \cdot 4\right)\\
\end{array}
\end{array}
if j < -1.55e126 or -1.62000000000000007e103 < j < -4.50000000000000024e77 or 7.5999999999999995e-105 < j Initial program 84.2%
Simplified84.3%
Taylor expanded in b around inf 56.9%
if -1.55e126 < j < -1.62000000000000007e103Initial program 99.7%
Taylor expanded in y around 0 73.6%
distribute-lft-out73.6%
*-commutative73.6%
Simplified73.6%
Taylor expanded in j around 0 72.9%
Taylor expanded in b around 0 72.5%
if -4.50000000000000024e77 < j < 7.5999999999999995e-105Initial program 89.4%
Taylor expanded in y around 0 77.6%
distribute-lft-out77.6%
*-commutative77.6%
Simplified77.6%
Taylor expanded in j around 0 69.2%
Taylor expanded in a around inf 54.0%
*-commutative54.0%
associate-*l*54.0%
Simplified54.0%
Final simplification56.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 (* 18.0 (* x (* y z)))))
(if (<= t -2e+127)
(+ (* j (* k -27.0)) (* t (+ (* -4.0 a) t_1)))
(if (<= t 6.7e+25)
(- (- (* b c) (* 4.0 (+ (* a t) (* x i)))) (* k (* j 27.0)))
(+ (* b c) (* t (- t_1 (* a 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 = 18.0 * (x * (y * z));
double tmp;
if (t <= -2e+127) {
tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
} else if (t <= 6.7e+25) {
tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0));
} else {
tmp = (b * c) + (t * (t_1 - (a * 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 = 18.0d0 * (x * (y * z))
if (t <= (-2d+127)) then
tmp = (j * (k * (-27.0d0))) + (t * (((-4.0d0) * a) + t_1))
else if (t <= 6.7d+25) then
tmp = ((b * c) - (4.0d0 * ((a * t) + (x * i)))) - (k * (j * 27.0d0))
else
tmp = (b * c) + (t * (t_1 - (a * 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 = 18.0 * (x * (y * z));
double tmp;
if (t <= -2e+127) {
tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
} else if (t <= 6.7e+25) {
tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0));
} else {
tmp = (b * c) + (t * (t_1 - (a * 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 = 18.0 * (x * (y * z)) tmp = 0 if t <= -2e+127: tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1)) elif t <= 6.7e+25: tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0)) else: tmp = (b * c) + (t * (t_1 - (a * 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(18.0 * Float64(x * Float64(y * z))) tmp = 0.0 if (t <= -2e+127) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(t * Float64(Float64(-4.0 * a) + t_1))); elseif (t <= 6.7e+25) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(a * t) + Float64(x * i)))) - Float64(k * Float64(j * 27.0))); else tmp = Float64(Float64(b * c) + Float64(t * Float64(t_1 - Float64(a * 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 = 18.0 * (x * (y * z));
tmp = 0.0;
if (t <= -2e+127)
tmp = (j * (k * -27.0)) + (t * ((-4.0 * a) + t_1));
elseif (t <= 6.7e+25)
tmp = ((b * c) - (4.0 * ((a * t) + (x * i)))) - (k * (j * 27.0));
else
tmp = (b * c) + (t * (t_1 - (a * 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[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2e+127], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(t * N[(N[(-4.0 * a), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 6.7e+25], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(a * t), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] + N[(t * N[(t$95$1 - N[(a * 4.0), $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 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\
\mathbf{if}\;t \leq -2 \cdot 10^{+127}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(-4 \cdot a + t\_1\right)\\
\mathbf{elif}\;t \leq 6.7 \cdot 10^{+25}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(a \cdot t + x \cdot i\right)\right) - k \cdot \left(j \cdot 27\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\\
\end{array}
\end{array}
if t < -1.99999999999999991e127Initial program 82.1%
Simplified87.9%
Taylor expanded in t around inf 86.5%
if -1.99999999999999991e127 < t < 6.70000000000000037e25Initial program 88.5%
Taylor expanded in y around 0 86.8%
distribute-lft-out86.8%
*-commutative86.8%
Simplified86.8%
if 6.70000000000000037e25 < t Initial program 88.1%
Simplified92.0%
Taylor expanded in j around 0 86.0%
Taylor expanded in i around 0 84.2%
Final simplification86.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 (<= k -9.2e-48)
(+ (* b c) (* j (* k -27.0)))
(if (<= k -4.4e-263)
(* i (+ (* b (/ c i)) (* -4.0 x)))
(if (<= k 1.4e+25)
(- (* b c) (* a (* t 4.0)))
(* k (+ (* j -27.0) (/ (* b c) 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 (k <= -9.2e-48) {
tmp = (b * c) + (j * (k * -27.0));
} else if (k <= -4.4e-263) {
tmp = i * ((b * (c / i)) + (-4.0 * x));
} else if (k <= 1.4e+25) {
tmp = (b * c) - (a * (t * 4.0));
} else {
tmp = k * ((j * -27.0) + ((b * c) / 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 (k <= (-9.2d-48)) then
tmp = (b * c) + (j * (k * (-27.0d0)))
else if (k <= (-4.4d-263)) then
tmp = i * ((b * (c / i)) + ((-4.0d0) * x))
else if (k <= 1.4d+25) then
tmp = (b * c) - (a * (t * 4.0d0))
else
tmp = k * ((j * (-27.0d0)) + ((b * c) / 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 (k <= -9.2e-48) {
tmp = (b * c) + (j * (k * -27.0));
} else if (k <= -4.4e-263) {
tmp = i * ((b * (c / i)) + (-4.0 * x));
} else if (k <= 1.4e+25) {
tmp = (b * c) - (a * (t * 4.0));
} else {
tmp = k * ((j * -27.0) + ((b * c) / 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 k <= -9.2e-48: tmp = (b * c) + (j * (k * -27.0)) elif k <= -4.4e-263: tmp = i * ((b * (c / i)) + (-4.0 * x)) elif k <= 1.4e+25: tmp = (b * c) - (a * (t * 4.0)) else: tmp = k * ((j * -27.0) + ((b * c) / 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 (k <= -9.2e-48) tmp = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0))); elseif (k <= -4.4e-263) tmp = Float64(i * Float64(Float64(b * Float64(c / i)) + Float64(-4.0 * x))); elseif (k <= 1.4e+25) tmp = Float64(Float64(b * c) - Float64(a * Float64(t * 4.0))); else tmp = Float64(k * Float64(Float64(j * -27.0) + Float64(Float64(b * c) / 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 (k <= -9.2e-48)
tmp = (b * c) + (j * (k * -27.0));
elseif (k <= -4.4e-263)
tmp = i * ((b * (c / i)) + (-4.0 * x));
elseif (k <= 1.4e+25)
tmp = (b * c) - (a * (t * 4.0));
else
tmp = k * ((j * -27.0) + ((b * c) / 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[LessEqual[k, -9.2e-48], N[(N[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, -4.4e-263], N[(i * N[(N[(b * N[(c / i), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.4e+25], N[(N[(b * c), $MachinePrecision] - N[(a * N[(t * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(k * N[(N[(j * -27.0), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] / k), $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}\;k \leq -9.2 \cdot 10^{-48}:\\
\;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;k \leq -4.4 \cdot 10^{-263}:\\
\;\;\;\;i \cdot \left(b \cdot \frac{c}{i} + -4 \cdot x\right)\\
\mathbf{elif}\;k \leq 1.4 \cdot 10^{+25}:\\
\;\;\;\;b \cdot c - a \cdot \left(t \cdot 4\right)\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27 + \frac{b \cdot c}{k}\right)\\
\end{array}
\end{array}
if k < -9.2000000000000003e-48Initial program 85.5%
Simplified85.7%
Taylor expanded in b around inf 50.4%
if -9.2000000000000003e-48 < k < -4.4000000000000001e-263Initial program 86.6%
Taylor expanded in y around 0 77.4%
distribute-lft-out77.4%
*-commutative77.4%
Simplified77.4%
Taylor expanded in j around 0 77.3%
Taylor expanded in a around 0 55.0%
*-commutative55.0%
associate-*r*55.0%
Simplified55.0%
Taylor expanded in i around inf 51.4%
cancel-sign-sub-inv51.4%
associate-/l*49.4%
metadata-eval49.4%
Simplified49.4%
if -4.4000000000000001e-263 < k < 1.4000000000000001e25Initial program 92.1%
Taylor expanded in y around 0 80.2%
distribute-lft-out80.2%
*-commutative80.2%
Simplified80.2%
Taylor expanded in j around 0 72.3%
Taylor expanded in a around inf 52.2%
*-commutative52.2%
associate-*l*52.2%
Simplified52.2%
if 1.4000000000000001e25 < k Initial program 84.7%
Simplified86.4%
Taylor expanded in b around inf 62.1%
Taylor expanded in k around inf 63.6%
Final simplification54.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 (<= (* b c) -1.65e+184)
(* b c)
(if (<= (* b c) -1.32e+48)
(* -4.0 (* a t))
(if (<= (* b c) 3.6e+47) (* j (* k -27.0)) (* 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 tmp;
if ((b * c) <= -1.65e+184) {
tmp = b * c;
} else if ((b * c) <= -1.32e+48) {
tmp = -4.0 * (a * t);
} else if ((b * c) <= 3.6e+47) {
tmp = j * (k * -27.0);
} 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) :: tmp
if ((b * c) <= (-1.65d+184)) then
tmp = b * c
else if ((b * c) <= (-1.32d+48)) then
tmp = (-4.0d0) * (a * t)
else if ((b * c) <= 3.6d+47) then
tmp = j * (k * (-27.0d0))
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 tmp;
if ((b * c) <= -1.65e+184) {
tmp = b * c;
} else if ((b * c) <= -1.32e+48) {
tmp = -4.0 * (a * t);
} else if ((b * c) <= 3.6e+47) {
tmp = j * (k * -27.0);
} 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): tmp = 0 if (b * c) <= -1.65e+184: tmp = b * c elif (b * c) <= -1.32e+48: tmp = -4.0 * (a * t) elif (b * c) <= 3.6e+47: tmp = j * (k * -27.0) 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) tmp = 0.0 if (Float64(b * c) <= -1.65e+184) tmp = Float64(b * c); elseif (Float64(b * c) <= -1.32e+48) tmp = Float64(-4.0 * Float64(a * t)); elseif (Float64(b * c) <= 3.6e+47) tmp = Float64(j * Float64(k * -27.0)); 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)
tmp = 0.0;
if ((b * c) <= -1.65e+184)
tmp = b * c;
elseif ((b * c) <= -1.32e+48)
tmp = -4.0 * (a * t);
elseif ((b * c) <= 3.6e+47)
tmp = j * (k * -27.0);
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_] := If[LessEqual[N[(b * c), $MachinePrecision], -1.65e+184], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -1.32e+48], N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 3.6e+47], N[(j * N[(k * -27.0), $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}
\mathbf{if}\;b \cdot c \leq -1.65 \cdot 10^{+184}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -1.32 \cdot 10^{+48}:\\
\;\;\;\;-4 \cdot \left(a \cdot t\right)\\
\mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{+47}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -1.6499999999999999e184 or 3.60000000000000008e47 < (*.f64 b c) Initial program 84.5%
Taylor expanded in x around 0 84.5%
Taylor expanded in b around inf 65.1%
if -1.6499999999999999e184 < (*.f64 b c) < -1.32e48Initial program 95.1%
Taylor expanded in x around 0 95.3%
Taylor expanded in a around inf 41.8%
*-commutative41.8%
Simplified41.8%
if -1.32e48 < (*.f64 b c) < 3.60000000000000008e47Initial program 87.6%
Simplified89.6%
Taylor expanded in j around inf 33.8%
*-commutative33.8%
associate-*r*33.1%
*-commutative33.1%
Simplified33.1%
Final simplification44.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 (<= (* b c) -6.5e+184)
(* b c)
(if (<= (* b c) -1.2e+49)
(* -4.0 (* a t))
(if (<= (* b c) 7.3e+47) (* -27.0 (* j k)) (* 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 tmp;
if ((b * c) <= -6.5e+184) {
tmp = b * c;
} else if ((b * c) <= -1.2e+49) {
tmp = -4.0 * (a * t);
} else if ((b * c) <= 7.3e+47) {
tmp = -27.0 * (j * k);
} 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) :: tmp
if ((b * c) <= (-6.5d+184)) then
tmp = b * c
else if ((b * c) <= (-1.2d+49)) then
tmp = (-4.0d0) * (a * t)
else if ((b * c) <= 7.3d+47) then
tmp = (-27.0d0) * (j * k)
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 tmp;
if ((b * c) <= -6.5e+184) {
tmp = b * c;
} else if ((b * c) <= -1.2e+49) {
tmp = -4.0 * (a * t);
} else if ((b * c) <= 7.3e+47) {
tmp = -27.0 * (j * k);
} 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): tmp = 0 if (b * c) <= -6.5e+184: tmp = b * c elif (b * c) <= -1.2e+49: tmp = -4.0 * (a * t) elif (b * c) <= 7.3e+47: tmp = -27.0 * (j * k) 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) tmp = 0.0 if (Float64(b * c) <= -6.5e+184) tmp = Float64(b * c); elseif (Float64(b * c) <= -1.2e+49) tmp = Float64(-4.0 * Float64(a * t)); elseif (Float64(b * c) <= 7.3e+47) tmp = Float64(-27.0 * Float64(j * k)); 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)
tmp = 0.0;
if ((b * c) <= -6.5e+184)
tmp = b * c;
elseif ((b * c) <= -1.2e+49)
tmp = -4.0 * (a * t);
elseif ((b * c) <= 7.3e+47)
tmp = -27.0 * (j * k);
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_] := If[LessEqual[N[(b * c), $MachinePrecision], -6.5e+184], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -1.2e+49], N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 7.3e+47], N[(-27.0 * N[(j * k), $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}
\mathbf{if}\;b \cdot c \leq -6.5 \cdot 10^{+184}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq -1.2 \cdot 10^{+49}:\\
\;\;\;\;-4 \cdot \left(a \cdot t\right)\\
\mathbf{elif}\;b \cdot c \leq 7.3 \cdot 10^{+47}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -6.50000000000000002e184 or 7.3000000000000001e47 < (*.f64 b c) Initial program 84.5%
Taylor expanded in x around 0 84.5%
Taylor expanded in b around inf 65.1%
if -6.50000000000000002e184 < (*.f64 b c) < -1.2e49Initial program 95.1%
Taylor expanded in x around 0 95.3%
Taylor expanded in a around inf 41.8%
*-commutative41.8%
Simplified41.8%
if -1.2e49 < (*.f64 b c) < 7.3000000000000001e47Initial program 87.6%
Simplified89.6%
Taylor expanded in j around inf 33.8%
Final simplification44.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 (if (or (<= (* b c) -5e+192) (not (<= (* b c) 1e+96))) (* c (+ b (* -27.0 (* j (/ k c))))) (+ (* j (* k -27.0)) (* -4.0 (* a 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 tmp;
if (((b * c) <= -5e+192) || !((b * c) <= 1e+96)) {
tmp = c * (b + (-27.0 * (j * (k / c))));
} else {
tmp = (j * (k * -27.0)) + (-4.0 * (a * 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) :: tmp
if (((b * c) <= (-5d+192)) .or. (.not. ((b * c) <= 1d+96))) then
tmp = c * (b + ((-27.0d0) * (j * (k / c))))
else
tmp = (j * (k * (-27.0d0))) + ((-4.0d0) * (a * 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 tmp;
if (((b * c) <= -5e+192) || !((b * c) <= 1e+96)) {
tmp = c * (b + (-27.0 * (j * (k / c))));
} else {
tmp = (j * (k * -27.0)) + (-4.0 * (a * 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): tmp = 0 if ((b * c) <= -5e+192) or not ((b * c) <= 1e+96): tmp = c * (b + (-27.0 * (j * (k / c)))) else: tmp = (j * (k * -27.0)) + (-4.0 * (a * 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) tmp = 0.0 if ((Float64(b * c) <= -5e+192) || !(Float64(b * c) <= 1e+96)) tmp = Float64(c * Float64(b + Float64(-27.0 * Float64(j * Float64(k / c))))); else tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(-4.0 * Float64(a * 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)
tmp = 0.0;
if (((b * c) <= -5e+192) || ~(((b * c) <= 1e+96)))
tmp = c * (b + (-27.0 * (j * (k / c))));
else
tmp = (j * (k * -27.0)) + (-4.0 * (a * 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_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -5e+192], N[Not[LessEqual[N[(b * c), $MachinePrecision], 1e+96]], $MachinePrecision]], N[(c * N[(b + N[(-27.0 * N[(j * N[(k / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * N[(a * 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}
\mathbf{if}\;b \cdot c \leq -5 \cdot 10^{+192} \lor \neg \left(b \cdot c \leq 10^{+96}\right):\\
\;\;\;\;c \cdot \left(b + -27 \cdot \left(j \cdot \frac{k}{c}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + -4 \cdot \left(a \cdot t\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -5.00000000000000033e192 or 1.00000000000000005e96 < (*.f64 b c) Initial program 85.5%
Simplified86.9%
Taylor expanded in b around inf 76.8%
Taylor expanded in c around inf 78.2%
*-commutative78.2%
associate-/l*79.5%
Simplified79.5%
if -5.00000000000000033e192 < (*.f64 b c) < 1.00000000000000005e96Initial program 87.9%
Simplified89.6%
Taylor expanded in a around inf 52.8%
Final simplification60.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 (+ (* b c) (* j (* k -27.0)))))
(if (<= k -1.95e-47)
t_1
(if (<= k -5.5e-264)
(* i (+ (* b (/ c i)) (* -4.0 x)))
(if (<= k 1.15e+29) (- (* b c) (* a (* t 4.0))) t_1)))))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) + (j * (k * -27.0));
double tmp;
if (k <= -1.95e-47) {
tmp = t_1;
} else if (k <= -5.5e-264) {
tmp = i * ((b * (c / i)) + (-4.0 * x));
} else if (k <= 1.15e+29) {
tmp = (b * c) - (a * (t * 4.0));
} else {
tmp = t_1;
}
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) + (j * (k * (-27.0d0)))
if (k <= (-1.95d-47)) then
tmp = t_1
else if (k <= (-5.5d-264)) then
tmp = i * ((b * (c / i)) + ((-4.0d0) * x))
else if (k <= 1.15d+29) then
tmp = (b * c) - (a * (t * 4.0d0))
else
tmp = t_1
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) + (j * (k * -27.0));
double tmp;
if (k <= -1.95e-47) {
tmp = t_1;
} else if (k <= -5.5e-264) {
tmp = i * ((b * (c / i)) + (-4.0 * x));
} else if (k <= 1.15e+29) {
tmp = (b * c) - (a * (t * 4.0));
} else {
tmp = t_1;
}
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) + (j * (k * -27.0)) tmp = 0 if k <= -1.95e-47: tmp = t_1 elif k <= -5.5e-264: tmp = i * ((b * (c / i)) + (-4.0 * x)) elif k <= 1.15e+29: tmp = (b * c) - (a * (t * 4.0)) else: tmp = t_1 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(j * Float64(k * -27.0))) tmp = 0.0 if (k <= -1.95e-47) tmp = t_1; elseif (k <= -5.5e-264) tmp = Float64(i * Float64(Float64(b * Float64(c / i)) + Float64(-4.0 * x))); elseif (k <= 1.15e+29) tmp = Float64(Float64(b * c) - Float64(a * Float64(t * 4.0))); else tmp = t_1; 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) + (j * (k * -27.0));
tmp = 0.0;
if (k <= -1.95e-47)
tmp = t_1;
elseif (k <= -5.5e-264)
tmp = i * ((b * (c / i)) + (-4.0 * x));
elseif (k <= 1.15e+29)
tmp = (b * c) - (a * (t * 4.0));
else
tmp = t_1;
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[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -1.95e-47], t$95$1, If[LessEqual[k, -5.5e-264], N[(i * N[(N[(b * N[(c / i), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.15e+29], N[(N[(b * c), $MachinePrecision] - N[(a * N[(t * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\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 + j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;k \leq -1.95 \cdot 10^{-47}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq -5.5 \cdot 10^{-264}:\\
\;\;\;\;i \cdot \left(b \cdot \frac{c}{i} + -4 \cdot x\right)\\
\mathbf{elif}\;k \leq 1.15 \cdot 10^{+29}:\\
\;\;\;\;b \cdot c - a \cdot \left(t \cdot 4\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if k < -1.94999999999999989e-47 or 1.1500000000000001e29 < k Initial program 85.0%
Simplified85.9%
Taylor expanded in b around inf 55.6%
if -1.94999999999999989e-47 < k < -5.5000000000000001e-264Initial program 86.6%
Taylor expanded in y around 0 77.4%
distribute-lft-out77.4%
*-commutative77.4%
Simplified77.4%
Taylor expanded in j around 0 77.3%
Taylor expanded in a around 0 55.0%
*-commutative55.0%
associate-*r*55.0%
Simplified55.0%
Taylor expanded in i around inf 51.4%
cancel-sign-sub-inv51.4%
associate-/l*49.4%
metadata-eval49.4%
Simplified49.4%
if -5.5000000000000001e-264 < k < 1.1500000000000001e29Initial program 92.3%
Taylor expanded in y around 0 80.5%
distribute-lft-out80.5%
*-commutative80.5%
Simplified80.5%
Taylor expanded in j around 0 71.2%
Taylor expanded in a around inf 51.4%
*-commutative51.4%
associate-*l*51.4%
Simplified51.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) (* j (* k -27.0)))))
(if (<= k -8.5e-48)
t_1
(if (<= k -3.2e-206)
(- (* b c) (* i (* x 4.0)))
(if (<= k 2.1e+26) (- (* b c) (* a (* t 4.0))) t_1)))))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) + (j * (k * -27.0));
double tmp;
if (k <= -8.5e-48) {
tmp = t_1;
} else if (k <= -3.2e-206) {
tmp = (b * c) - (i * (x * 4.0));
} else if (k <= 2.1e+26) {
tmp = (b * c) - (a * (t * 4.0));
} else {
tmp = t_1;
}
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) + (j * (k * (-27.0d0)))
if (k <= (-8.5d-48)) then
tmp = t_1
else if (k <= (-3.2d-206)) then
tmp = (b * c) - (i * (x * 4.0d0))
else if (k <= 2.1d+26) then
tmp = (b * c) - (a * (t * 4.0d0))
else
tmp = t_1
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) + (j * (k * -27.0));
double tmp;
if (k <= -8.5e-48) {
tmp = t_1;
} else if (k <= -3.2e-206) {
tmp = (b * c) - (i * (x * 4.0));
} else if (k <= 2.1e+26) {
tmp = (b * c) - (a * (t * 4.0));
} else {
tmp = t_1;
}
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) + (j * (k * -27.0)) tmp = 0 if k <= -8.5e-48: tmp = t_1 elif k <= -3.2e-206: tmp = (b * c) - (i * (x * 4.0)) elif k <= 2.1e+26: tmp = (b * c) - (a * (t * 4.0)) else: tmp = t_1 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(j * Float64(k * -27.0))) tmp = 0.0 if (k <= -8.5e-48) tmp = t_1; elseif (k <= -3.2e-206) tmp = Float64(Float64(b * c) - Float64(i * Float64(x * 4.0))); elseif (k <= 2.1e+26) tmp = Float64(Float64(b * c) - Float64(a * Float64(t * 4.0))); else tmp = t_1; 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) + (j * (k * -27.0));
tmp = 0.0;
if (k <= -8.5e-48)
tmp = t_1;
elseif (k <= -3.2e-206)
tmp = (b * c) - (i * (x * 4.0));
elseif (k <= 2.1e+26)
tmp = (b * c) - (a * (t * 4.0));
else
tmp = t_1;
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[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -8.5e-48], t$95$1, If[LessEqual[k, -3.2e-206], N[(N[(b * c), $MachinePrecision] - N[(i * N[(x * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 2.1e+26], N[(N[(b * c), $MachinePrecision] - N[(a * N[(t * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\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 + j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;k \leq -8.5 \cdot 10^{-48}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq -3.2 \cdot 10^{-206}:\\
\;\;\;\;b \cdot c - i \cdot \left(x \cdot 4\right)\\
\mathbf{elif}\;k \leq 2.1 \cdot 10^{+26}:\\
\;\;\;\;b \cdot c - a \cdot \left(t \cdot 4\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if k < -8.5000000000000004e-48 or 2.1000000000000001e26 < k Initial program 85.1%
Simplified86.0%
Taylor expanded in b around inf 55.9%
if -8.5000000000000004e-48 < k < -3.19999999999999976e-206Initial program 86.1%
Taylor expanded in y around 0 80.6%
distribute-lft-out80.6%
*-commutative80.6%
Simplified80.6%
Taylor expanded in j around 0 80.6%
Taylor expanded in a around 0 58.9%
*-commutative58.9%
associate-*r*58.9%
Simplified58.9%
if -3.19999999999999976e-206 < k < 2.1000000000000001e26Initial program 91.3%
Taylor expanded in y around 0 78.2%
distribute-lft-out78.2%
*-commutative78.2%
Simplified78.2%
Taylor expanded in j around 0 71.9%
Taylor expanded in a around inf 51.1%
*-commutative51.1%
associate-*l*51.1%
Simplified51.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 (<= (* b c) -3.2e+152) (not (<= (* b c) 2.35e+47))) (* 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) <= -3.2e+152) || !((b * c) <= 2.35e+47)) {
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) <= (-3.2d+152)) .or. (.not. ((b * c) <= 2.35d+47))) 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) <= -3.2e+152) || !((b * c) <= 2.35e+47)) {
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) <= -3.2e+152) or not ((b * c) <= 2.35e+47): 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) <= -3.2e+152) || !(Float64(b * c) <= 2.35e+47)) 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) <= -3.2e+152) || ~(((b * c) <= 2.35e+47)))
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], -3.2e+152], N[Not[LessEqual[N[(b * c), $MachinePrecision], 2.35e+47]], $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 -3.2 \cdot 10^{+152} \lor \neg \left(b \cdot c \leq 2.35 \cdot 10^{+47}\right):\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -3.20000000000000005e152 or 2.34999999999999982e47 < (*.f64 b c) Initial program 84.9%
Taylor expanded in x around 0 84.9%
Taylor expanded in b around inf 60.8%
if -3.20000000000000005e152 < (*.f64 b c) < 2.34999999999999982e47Initial program 88.5%
Simplified90.4%
Taylor expanded in j around inf 32.4%
Final simplification42.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 (* 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 87.2%
Taylor expanded in x around 0 87.2%
Taylor expanded in b around inf 25.4%
(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 2024110
(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)))