
(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 19 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.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1
(-
(-
(+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
(* (* x 4.0) i))
(* (* j 27.0) k))))
(if (<= t_1 INFINITY)
t_1
(* b (+ c (/ (+ (* t (* a -4.0)) (* j (* k -27.0))) b))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b));
}
return tmp;
}
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(b * Float64(c + Float64(Float64(Float64(t * Float64(a * -4.0)) + Float64(j * Float64(k * -27.0))) / b))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
tmp = 0.0;
if (t_1 <= Inf)
tmp = t_1;
else
tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b));
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(b * N[(c + N[(N[(N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $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])\\
\\
\begin{array}{l}
t_1 := \left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(c + \frac{t \cdot \left(a \cdot -4\right) + j \cdot \left(k \cdot -27\right)}{b}\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 97.9%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) Initial program 0.0%
Simplified19.2%
Taylor expanded in x around 0 42.3%
Taylor expanded in b around inf 57.7%
associate--l+57.7%
associate-*r/57.7%
associate-*r/57.7%
div-sub57.7%
cancel-sign-sub-inv57.7%
associate-*r*57.7%
*-commutative57.7%
metadata-eval57.7%
associate-*r*57.7%
*-commutative57.7%
associate-*r*57.7%
Simplified57.7%
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.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= (* b c) (- INFINITY))
(* b (+ c (* -27.0 (/ (* j k) b))))
(-
(+ (* b c) (* t (- (* (* x 18.0) (* y z)) (* a 4.0))))
(+ (* x (* 4.0 i)) (* j (* 27.0 k))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
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) <= -((double) INFINITY)) {
tmp = b * (c + (-27.0 * ((j * k) / b)));
} else {
tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
}
return tmp;
}
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) <= -Double.POSITIVE_INFINITY) {
tmp = b * (c + (-27.0 * ((j * k) / b)));
} else {
tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (b * c) <= -math.inf: tmp = b * (c + (-27.0 * ((j * k) / b))) else: tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (Float64(b * c) <= Float64(-Inf)) tmp = Float64(b * Float64(c + Float64(-27.0 * Float64(Float64(j * k) / b)))); else tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(x * 18.0) * Float64(y * z)) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k)))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((b * c) <= -Inf)
tmp = b * (c + (-27.0 * ((j * k) / b)));
else
tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], (-Infinity)], N[(b * N[(c + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(27.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -\infty:\\
\;\;\;\;b \cdot \left(c + -27 \cdot \frac{j \cdot k}{b}\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -inf.0Initial program 73.9%
Simplified82.6%
Taylor expanded in b around inf 87.0%
Taylor expanded in b around inf 91.3%
if -inf.0 < (*.f64 b c) Initial program 89.3%
Simplified90.6%
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.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= (* b c) -1e+72)
(- (* b c) (* 4.0 (* x i)))
(if (<= (* b c) 2e-67)
(+ (* j (* k -27.0)) (* -4.0 (* x i)))
(if (<= (* b c) 2e+226)
(* -4.0 (+ (* t a) (* x i)))
(* b (+ c (* -27.0 (/ (* j k) b))))))))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) <= -1e+72) {
tmp = (b * c) - (4.0 * (x * i));
} else if ((b * c) <= 2e-67) {
tmp = (j * (k * -27.0)) + (-4.0 * (x * i));
} else if ((b * c) <= 2e+226) {
tmp = -4.0 * ((t * a) + (x * i));
} else {
tmp = b * (c + (-27.0 * ((j * k) / b)));
}
return tmp;
}
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) <= (-1d+72)) then
tmp = (b * c) - (4.0d0 * (x * i))
else if ((b * c) <= 2d-67) then
tmp = (j * (k * (-27.0d0))) + ((-4.0d0) * (x * i))
else if ((b * c) <= 2d+226) then
tmp = (-4.0d0) * ((t * a) + (x * i))
else
tmp = b * (c + ((-27.0d0) * ((j * k) / b)))
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;
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) <= -1e+72) {
tmp = (b * c) - (4.0 * (x * i));
} else if ((b * c) <= 2e-67) {
tmp = (j * (k * -27.0)) + (-4.0 * (x * i));
} else if ((b * c) <= 2e+226) {
tmp = -4.0 * ((t * a) + (x * i));
} else {
tmp = b * (c + (-27.0 * ((j * k) / b)));
}
return tmp;
}
[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) <= -1e+72: tmp = (b * c) - (4.0 * (x * i)) elif (b * c) <= 2e-67: tmp = (j * (k * -27.0)) + (-4.0 * (x * i)) elif (b * c) <= 2e+226: tmp = -4.0 * ((t * a) + (x * i)) else: tmp = b * (c + (-27.0 * ((j * k) / b))) return tmp
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) <= -1e+72) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); elseif (Float64(b * c) <= 2e-67) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(-4.0 * Float64(x * i))); elseif (Float64(b * c) <= 2e+226) tmp = Float64(-4.0 * Float64(Float64(t * a) + Float64(x * i))); else tmp = Float64(b * Float64(c + Float64(-27.0 * Float64(Float64(j * k) / b)))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((b * c) <= -1e+72)
tmp = (b * c) - (4.0 * (x * i));
elseif ((b * c) <= 2e-67)
tmp = (j * (k * -27.0)) + (-4.0 * (x * i));
elseif ((b * c) <= 2e+226)
tmp = -4.0 * ((t * a) + (x * i));
else
tmp = b * (c + (-27.0 * ((j * k) / b)));
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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1e+72], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2e-67], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2e+226], N[(-4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(c + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / b), $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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+72}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{-67}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + -4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+226}:\\
\;\;\;\;-4 \cdot \left(t \cdot a + x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(c + -27 \cdot \frac{j \cdot k}{b}\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -9.99999999999999944e71Initial program 81.8%
Simplified83.3%
Taylor expanded in y around 0 75.1%
Taylor expanded in i around inf 71.5%
associate-*r*71.5%
*-commutative71.5%
associate-*r*71.5%
Simplified71.5%
Taylor expanded in a around 0 68.4%
if -9.99999999999999944e71 < (*.f64 b c) < 1.99999999999999989e-67Initial program 92.1%
Simplified92.2%
Taylor expanded in i around inf 61.0%
if 1.99999999999999989e-67 < (*.f64 b c) < 1.99999999999999992e226Initial program 91.9%
Simplified93.9%
Taylor expanded in y around 0 84.0%
Taylor expanded in i around inf 68.4%
associate-*r*68.4%
*-commutative68.4%
associate-*r*68.4%
Simplified68.4%
Taylor expanded in b around 0 55.2%
cancel-sign-sub-inv55.2%
metadata-eval55.2%
distribute-lft-out55.2%
Simplified55.2%
if 1.99999999999999992e226 < (*.f64 b c) Initial program 78.4%
Simplified81.5%
Taylor expanded in b around inf 69.7%
Taylor expanded in b around inf 76.0%
Final simplification63.5%
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 (* -27.0 (/ (* j k) b))))))
(if (<= j -8.2e+56)
t_1
(if (<= j -8e-135)
(+ (* b c) (* -4.0 (* t a)))
(if (<= j 5.9e-202)
(- (* b c) (* 4.0 (* x i)))
(if (<= j 1.25e-150) (* 18.0 (* t (* x (* y z)))) t_1))))))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 + (-27.0 * ((j * k) / b)));
double tmp;
if (j <= -8.2e+56) {
tmp = t_1;
} else if (j <= -8e-135) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (j <= 5.9e-202) {
tmp = (b * c) - (4.0 * (x * i));
} else if (j <= 1.25e-150) {
tmp = 18.0 * (t * (x * (y * z)));
} 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.
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 + ((-27.0d0) * ((j * k) / b)))
if (j <= (-8.2d+56)) then
tmp = t_1
else if (j <= (-8d-135)) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (j <= 5.9d-202) then
tmp = (b * c) - (4.0d0 * (x * i))
else if (j <= 1.25d-150) then
tmp = 18.0d0 * (t * (x * (y * z)))
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;
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 + (-27.0 * ((j * k) / b)));
double tmp;
if (j <= -8.2e+56) {
tmp = t_1;
} else if (j <= -8e-135) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (j <= 5.9e-202) {
tmp = (b * c) - (4.0 * (x * i));
} else if (j <= 1.25e-150) {
tmp = 18.0 * (t * (x * (y * z)));
} 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]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = b * (c + (-27.0 * ((j * k) / b))) tmp = 0 if j <= -8.2e+56: tmp = t_1 elif j <= -8e-135: tmp = (b * c) + (-4.0 * (t * a)) elif j <= 5.9e-202: tmp = (b * c) - (4.0 * (x * i)) elif j <= 1.25e-150: tmp = 18.0 * (t * (x * (y * z))) 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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(b * Float64(c + Float64(-27.0 * Float64(Float64(j * k) / b)))) tmp = 0.0 if (j <= -8.2e+56) tmp = t_1; elseif (j <= -8e-135) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (j <= 5.9e-202) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); elseif (j <= 1.25e-150) tmp = Float64(18.0 * Float64(t * Float64(x * Float64(y * z)))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = b * (c + (-27.0 * ((j * k) / b)));
tmp = 0.0;
if (j <= -8.2e+56)
tmp = t_1;
elseif (j <= -8e-135)
tmp = (b * c) + (-4.0 * (t * a));
elseif (j <= 5.9e-202)
tmp = (b * c) - (4.0 * (x * i));
elseif (j <= 1.25e-150)
tmp = 18.0 * (t * (x * (y * z)));
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(b * N[(c + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -8.2e+56], t$95$1, If[LessEqual[j, -8e-135], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 5.9e-202], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1.25e-150], N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $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])\\
\\
\begin{array}{l}
t_1 := b \cdot \left(c + -27 \cdot \frac{j \cdot k}{b}\right)\\
\mathbf{if}\;j \leq -8.2 \cdot 10^{+56}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -8 \cdot 10^{-135}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;j \leq 5.9 \cdot 10^{-202}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;j \leq 1.25 \cdot 10^{-150}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if j < -8.2000000000000007e56 or 1.24999999999999997e-150 < j Initial program 85.5%
Simplified88.9%
Taylor expanded in b around inf 62.9%
Taylor expanded in b around inf 64.2%
if -8.2000000000000007e56 < j < -8.0000000000000003e-135Initial program 95.5%
Simplified97.6%
Taylor expanded in x around 0 60.4%
Taylor expanded in j around 0 52.2%
if -8.0000000000000003e-135 < j < 5.89999999999999999e-202Initial program 88.4%
Simplified88.4%
Taylor expanded in y around 0 77.6%
Taylor expanded in i around inf 74.0%
associate-*r*74.0%
*-commutative74.0%
associate-*r*74.0%
Simplified74.0%
Taylor expanded in a around 0 47.5%
if 5.89999999999999999e-202 < j < 1.24999999999999997e-150Initial program 90.8%
Simplified90.7%
Taylor expanded in y around inf 51.8%
Taylor expanded in t around inf 51.9%
Final simplification58.4%
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 (* 27.0 (* j k)))
(t_2 (* t (+ (* a -4.0) (* 18.0 (* x (* y z)))))))
(if (<= t -7.2e+253)
t_2
(if (<= t -1.8e-84)
(- (+ (* b c) (* -4.0 (* t a))) t_1)
(if (<= t 1.15e+78) (- (* 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);
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 = 27.0 * (j * k);
double t_2 = t * ((a * -4.0) + (18.0 * (x * (y * z))));
double tmp;
if (t <= -7.2e+253) {
tmp = t_2;
} else if (t <= -1.8e-84) {
tmp = ((b * c) + (-4.0 * (t * a))) - t_1;
} else if (t <= 1.15e+78) {
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.
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 = 27.0d0 * (j * k)
t_2 = t * ((a * (-4.0d0)) + (18.0d0 * (x * (y * z))))
if (t <= (-7.2d+253)) then
tmp = t_2
else if (t <= (-1.8d-84)) then
tmp = ((b * c) + ((-4.0d0) * (t * a))) - t_1
else if (t <= 1.15d+78) 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;
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 = 27.0 * (j * k);
double t_2 = t * ((a * -4.0) + (18.0 * (x * (y * z))));
double tmp;
if (t <= -7.2e+253) {
tmp = t_2;
} else if (t <= -1.8e-84) {
tmp = ((b * c) + (-4.0 * (t * a))) - t_1;
} else if (t <= 1.15e+78) {
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]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = 27.0 * (j * k) t_2 = t * ((a * -4.0) + (18.0 * (x * (y * z)))) tmp = 0 if t <= -7.2e+253: tmp = t_2 elif t <= -1.8e-84: tmp = ((b * c) + (-4.0 * (t * a))) - t_1 elif t <= 1.15e+78: 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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(27.0 * Float64(j * k)) t_2 = Float64(t * Float64(Float64(a * -4.0) + Float64(18.0 * Float64(x * Float64(y * z))))) tmp = 0.0 if (t <= -7.2e+253) tmp = t_2; elseif (t <= -1.8e-84) tmp = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - t_1); elseif (t <= 1.15e+78) tmp = Float64(Float64(b * c) - Float64(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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = 27.0 * (j * k);
t_2 = t * ((a * -4.0) + (18.0 * (x * (y * z))));
tmp = 0.0;
if (t <= -7.2e+253)
tmp = t_2;
elseif (t <= -1.8e-84)
tmp = ((b * c) + (-4.0 * (t * a))) - t_1;
elseif (t <= 1.15e+78)
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(N[(a * -4.0), $MachinePrecision] + N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -7.2e+253], t$95$2, If[LessEqual[t, -1.8e-84], N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[t, 1.15e+78], N[(N[(b * c), $MachinePrecision] - N[(N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision] + t$95$1), $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])\\
\\
\begin{array}{l}
t_1 := 27 \cdot \left(j \cdot k\right)\\
t_2 := t \cdot \left(a \cdot -4 + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{if}\;t \leq -7.2 \cdot 10^{+253}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -1.8 \cdot 10^{-84}:\\
\;\;\;\;\left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - t\_1\\
\mathbf{elif}\;t \leq 1.15 \cdot 10^{+78}:\\
\;\;\;\;b \cdot c - \left(4 \cdot \left(x \cdot i\right) + t\_1\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -7.2000000000000001e253 or 1.1500000000000001e78 < t Initial program 79.3%
Simplified87.3%
Taylor expanded in t around inf 84.8%
Taylor expanded in t around inf 81.8%
if -7.2000000000000001e253 < t < -1.80000000000000002e-84Initial program 95.6%
Simplified99.9%
Taylor expanded in x around 0 73.8%
if -1.80000000000000002e-84 < t < 1.1500000000000001e78Initial program 88.1%
Simplified85.0%
Taylor expanded in t around 0 84.3%
Final simplification80.9%
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 (* -27.0 (* j k))))
(if (<= k -1e+40)
t_1
(if (<= k 1.36e+82)
(+ (* b c) (* -4.0 (* t a)))
(if (<= k 2.1e+124)
t_1
(if (<= k 1.35e+217)
(* -4.0 (+ (* t a) (* x i)))
(* b (* -27.0 (* j (/ k b))))))))))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 = -27.0 * (j * k);
double tmp;
if (k <= -1e+40) {
tmp = t_1;
} else if (k <= 1.36e+82) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (k <= 2.1e+124) {
tmp = t_1;
} else if (k <= 1.35e+217) {
tmp = -4.0 * ((t * a) + (x * i));
} else {
tmp = b * (-27.0 * (j * (k / b)));
}
return tmp;
}
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 = (-27.0d0) * (j * k)
if (k <= (-1d+40)) then
tmp = t_1
else if (k <= 1.36d+82) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (k <= 2.1d+124) then
tmp = t_1
else if (k <= 1.35d+217) then
tmp = (-4.0d0) * ((t * a) + (x * i))
else
tmp = b * ((-27.0d0) * (j * (k / b)))
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;
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 = -27.0 * (j * k);
double tmp;
if (k <= -1e+40) {
tmp = t_1;
} else if (k <= 1.36e+82) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (k <= 2.1e+124) {
tmp = t_1;
} else if (k <= 1.35e+217) {
tmp = -4.0 * ((t * a) + (x * i));
} else {
tmp = b * (-27.0 * (j * (k / b)));
}
return tmp;
}
[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 = -27.0 * (j * k) tmp = 0 if k <= -1e+40: tmp = t_1 elif k <= 1.36e+82: tmp = (b * c) + (-4.0 * (t * a)) elif k <= 2.1e+124: tmp = t_1 elif k <= 1.35e+217: tmp = -4.0 * ((t * a) + (x * i)) else: tmp = b * (-27.0 * (j * (k / b))) return tmp
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(-27.0 * Float64(j * k)) tmp = 0.0 if (k <= -1e+40) tmp = t_1; elseif (k <= 1.36e+82) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (k <= 2.1e+124) tmp = t_1; elseif (k <= 1.35e+217) tmp = Float64(-4.0 * Float64(Float64(t * a) + Float64(x * i))); else tmp = Float64(b * Float64(-27.0 * Float64(j * Float64(k / b)))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = -27.0 * (j * k);
tmp = 0.0;
if (k <= -1e+40)
tmp = t_1;
elseif (k <= 1.36e+82)
tmp = (b * c) + (-4.0 * (t * a));
elseif (k <= 2.1e+124)
tmp = t_1;
elseif (k <= 1.35e+217)
tmp = -4.0 * ((t * a) + (x * i));
else
tmp = b * (-27.0 * (j * (k / b)));
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -1e+40], t$95$1, If[LessEqual[k, 1.36e+82], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 2.1e+124], t$95$1, If[LessEqual[k, 1.35e+217], N[(-4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(-27.0 * N[(j * N[(k / b), $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])\\
\\
\begin{array}{l}
t_1 := -27 \cdot \left(j \cdot k\right)\\
\mathbf{if}\;k \leq -1 \cdot 10^{+40}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq 1.36 \cdot 10^{+82}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;k \leq 2.1 \cdot 10^{+124}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;k \leq 1.35 \cdot 10^{+217}:\\
\;\;\;\;-4 \cdot \left(t \cdot a + x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(-27 \cdot \left(j \cdot \frac{k}{b}\right)\right)\\
\end{array}
\end{array}
if k < -1.00000000000000003e40 or 1.36000000000000001e82 < k < 2.10000000000000011e124Initial program 85.8%
Simplified92.8%
Taylor expanded in j around inf 51.2%
if -1.00000000000000003e40 < k < 1.36000000000000001e82Initial program 90.0%
Simplified90.6%
Taylor expanded in x around 0 63.4%
Taylor expanded in j around 0 51.0%
if 2.10000000000000011e124 < k < 1.35000000000000001e217Initial program 81.3%
Simplified81.3%
Taylor expanded in y around 0 87.5%
Taylor expanded in i around inf 69.3%
associate-*r*69.3%
*-commutative69.3%
associate-*r*69.3%
Simplified69.3%
Taylor expanded in b around 0 57.4%
cancel-sign-sub-inv57.4%
metadata-eval57.4%
distribute-lft-out57.4%
Simplified57.4%
if 1.35000000000000001e217 < k Initial program 84.0%
Simplified84.0%
Taylor expanded in b around inf 56.7%
Taylor expanded in b around inf 72.3%
Taylor expanded in c around 0 61.9%
associate-*r/73.4%
Simplified73.4%
Final simplification53.7%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (if (or (<= t -58.0) (not (<= t 8.6e+72))) (+ (* t (+ (* a -4.0) (* 18.0 (* x (* y z))))) (* j (* k -27.0))) (- (* b c) (+ (* 4.0 (* x i)) (* 27.0 (* j k))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -58.0) || !(t <= 8.6e+72)) {
tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (j * (k * -27.0));
} else {
tmp = (b * c) - ((4.0 * (x * i)) + (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.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((t <= (-58.0d0)) .or. (.not. (t <= 8.6d+72))) then
tmp = (t * ((a * (-4.0d0)) + (18.0d0 * (x * (y * z))))) + (j * (k * (-27.0d0)))
else
tmp = (b * c) - ((4.0d0 * (x * i)) + (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;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -58.0) || !(t <= 8.6e+72)) {
tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (j * (k * -27.0));
} else {
tmp = (b * c) - ((4.0 * (x * i)) + (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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (t <= -58.0) or not (t <= 8.6e+72): tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (j * (k * -27.0)) else: tmp = (b * c) - ((4.0 * (x * i)) + (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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((t <= -58.0) || !(t <= 8.6e+72)) tmp = Float64(Float64(t * Float64(Float64(a * -4.0) + Float64(18.0 * Float64(x * Float64(y * z))))) + Float64(j * Float64(k * -27.0))); else tmp = Float64(Float64(b * c) - Float64(Float64(4.0 * Float64(x * i)) + 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((t <= -58.0) || ~((t <= 8.6e+72)))
tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (j * (k * -27.0));
else
tmp = (b * c) - ((4.0 * (x * i)) + (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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -58.0], N[Not[LessEqual[t, 8.6e+72]], $MachinePrecision]], N[(N[(t * N[(N[(a * -4.0), $MachinePrecision] + N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] - N[(N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -58 \lor \neg \left(t \leq 8.6 \cdot 10^{+72}\right):\\
\;\;\;\;t \cdot \left(a \cdot -4 + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c - \left(4 \cdot \left(x \cdot i\right) + 27 \cdot \left(j \cdot k\right)\right)\\
\end{array}
\end{array}
if t < -58 or 8.6000000000000003e72 < t Initial program 86.5%
Simplified92.8%
Taylor expanded in t around inf 81.5%
if -58 < t < 8.6000000000000003e72Initial program 89.1%
Simplified86.9%
Taylor expanded in t around 0 83.7%
Final simplification82.7%
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 (* t (+ (* a -4.0) (* 18.0 (* x (* y z)))))))
(if (<= t -49.0)
t_1
(if (<= t 4.6e-156)
(* b (+ c (* -27.0 (/ (* j k) b))))
(if (<= t 1.25e+73) (- (* b c) (* 4.0 (* x i))) t_1)))))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 = t * ((a * -4.0) + (18.0 * (x * (y * z))));
double tmp;
if (t <= -49.0) {
tmp = t_1;
} else if (t <= 4.6e-156) {
tmp = b * (c + (-27.0 * ((j * k) / b)));
} else if (t <= 1.25e+73) {
tmp = (b * c) - (4.0 * (x * i));
} 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.
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 = t * ((a * (-4.0d0)) + (18.0d0 * (x * (y * z))))
if (t <= (-49.0d0)) then
tmp = t_1
else if (t <= 4.6d-156) then
tmp = b * (c + ((-27.0d0) * ((j * k) / b)))
else if (t <= 1.25d+73) then
tmp = (b * c) - (4.0d0 * (x * i))
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;
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 = t * ((a * -4.0) + (18.0 * (x * (y * z))));
double tmp;
if (t <= -49.0) {
tmp = t_1;
} else if (t <= 4.6e-156) {
tmp = b * (c + (-27.0 * ((j * k) / b)));
} else if (t <= 1.25e+73) {
tmp = (b * c) - (4.0 * (x * i));
} 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]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = t * ((a * -4.0) + (18.0 * (x * (y * z)))) tmp = 0 if t <= -49.0: tmp = t_1 elif t <= 4.6e-156: tmp = b * (c + (-27.0 * ((j * k) / b))) elif t <= 1.25e+73: tmp = (b * c) - (4.0 * (x * i)) 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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(t * Float64(Float64(a * -4.0) + Float64(18.0 * Float64(x * Float64(y * z))))) tmp = 0.0 if (t <= -49.0) tmp = t_1; elseif (t <= 4.6e-156) tmp = Float64(b * Float64(c + Float64(-27.0 * Float64(Float64(j * k) / b)))); elseif (t <= 1.25e+73) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = t * ((a * -4.0) + (18.0 * (x * (y * z))));
tmp = 0.0;
if (t <= -49.0)
tmp = t_1;
elseif (t <= 4.6e-156)
tmp = b * (c + (-27.0 * ((j * k) / b)));
elseif (t <= 1.25e+73)
tmp = (b * c) - (4.0 * (x * i));
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(t * N[(N[(a * -4.0), $MachinePrecision] + N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -49.0], t$95$1, If[LessEqual[t, 4.6e-156], N[(b * N[(c + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.25e+73], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $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])\\
\\
\begin{array}{l}
t_1 := t \cdot \left(a \cdot -4 + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{if}\;t \leq -49:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 4.6 \cdot 10^{-156}:\\
\;\;\;\;b \cdot \left(c + -27 \cdot \frac{j \cdot k}{b}\right)\\
\mathbf{elif}\;t \leq 1.25 \cdot 10^{+73}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -49 or 1.24999999999999994e73 < t Initial program 86.5%
Simplified92.8%
Taylor expanded in t around inf 81.5%
Taylor expanded in t around inf 71.2%
if -49 < t < 4.5999999999999999e-156Initial program 87.4%
Simplified87.4%
Taylor expanded in b around inf 68.1%
Taylor expanded in b around inf 70.3%
if 4.5999999999999999e-156 < t < 1.24999999999999994e73Initial program 92.2%
Simplified90.1%
Taylor expanded in y around 0 90.2%
Taylor expanded in i around inf 72.5%
associate-*r*72.5%
*-commutative72.5%
associate-*r*72.5%
Simplified72.5%
Taylor expanded in a around 0 66.6%
Final simplification70.0%
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) -4.5e+68)
(* b c)
(if (<= (* b c) 1.65e-65)
(* j (* k -27.0))
(if (<= (* b c) 1.14e+226) (* t (* a -4.0)) (* b c)))))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) <= -4.5e+68) {
tmp = b * c;
} else if ((b * c) <= 1.65e-65) {
tmp = j * (k * -27.0);
} else if ((b * c) <= 1.14e+226) {
tmp = t * (a * -4.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.
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) <= (-4.5d+68)) then
tmp = b * c
else if ((b * c) <= 1.65d-65) then
tmp = j * (k * (-27.0d0))
else if ((b * c) <= 1.14d+226) then
tmp = t * (a * (-4.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;
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) <= -4.5e+68) {
tmp = b * c;
} else if ((b * c) <= 1.65e-65) {
tmp = j * (k * -27.0);
} else if ((b * c) <= 1.14e+226) {
tmp = t * (a * -4.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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (b * c) <= -4.5e+68: tmp = b * c elif (b * c) <= 1.65e-65: tmp = j * (k * -27.0) elif (b * c) <= 1.14e+226: tmp = t * (a * -4.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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (Float64(b * c) <= -4.5e+68) tmp = Float64(b * c); elseif (Float64(b * c) <= 1.65e-65) tmp = Float64(j * Float64(k * -27.0)); elseif (Float64(b * c) <= 1.14e+226) tmp = Float64(t * Float64(a * -4.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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((b * c) <= -4.5e+68)
tmp = b * c;
elseif ((b * c) <= 1.65e-65)
tmp = j * (k * -27.0);
elseif ((b * c) <= 1.14e+226)
tmp = t * (a * -4.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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -4.5e+68], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.65e-65], N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.14e+226], N[(t * N[(a * -4.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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -4.5 \cdot 10^{+68}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq 1.65 \cdot 10^{-65}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right)\\
\mathbf{elif}\;b \cdot c \leq 1.14 \cdot 10^{+226}:\\
\;\;\;\;t \cdot \left(a \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -4.5000000000000003e68 or 1.14000000000000003e226 < (*.f64 b c) Initial program 80.6%
Simplified81.6%
Taylor expanded in y around 0 77.4%
Taylor expanded in b around inf 58.6%
if -4.5000000000000003e68 < (*.f64 b c) < 1.6500000000000001e-65Initial program 92.1%
Simplified92.2%
Taylor expanded in j around inf 41.3%
associate-*r*41.3%
*-commutative41.3%
metadata-eval41.3%
distribute-rgt-neg-in41.3%
*-commutative41.3%
distribute-rgt-neg-in41.3%
metadata-eval41.3%
*-commutative41.3%
Simplified41.3%
Taylor expanded in k around 0 41.3%
*-commutative41.3%
associate-*r*41.3%
Simplified41.3%
if 1.6500000000000001e-65 < (*.f64 b c) < 1.14000000000000003e226Initial program 91.9%
Simplified93.9%
Taylor expanded in y around 0 84.0%
Taylor expanded in a around inf 41.1%
associate-*r*41.1%
*-commutative41.1%
Simplified41.1%
Final simplification47.5%
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.15e+71)
(* b c)
(if (<= (* b c) 7e-67)
(* k (* j -27.0))
(if (<= (* b c) 1.25e+226) (* t (* a -4.0)) (* b c)))))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.15e+71) {
tmp = b * c;
} else if ((b * c) <= 7e-67) {
tmp = k * (j * -27.0);
} else if ((b * c) <= 1.25e+226) {
tmp = t * (a * -4.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.
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.15d+71)) then
tmp = b * c
else if ((b * c) <= 7d-67) then
tmp = k * (j * (-27.0d0))
else if ((b * c) <= 1.25d+226) then
tmp = t * (a * (-4.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;
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.15e+71) {
tmp = b * c;
} else if ((b * c) <= 7e-67) {
tmp = k * (j * -27.0);
} else if ((b * c) <= 1.25e+226) {
tmp = t * (a * -4.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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (b * c) <= -1.15e+71: tmp = b * c elif (b * c) <= 7e-67: tmp = k * (j * -27.0) elif (b * c) <= 1.25e+226: tmp = t * (a * -4.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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (Float64(b * c) <= -1.15e+71) tmp = Float64(b * c); elseif (Float64(b * c) <= 7e-67) tmp = Float64(k * Float64(j * -27.0)); elseif (Float64(b * c) <= 1.25e+226) tmp = Float64(t * Float64(a * -4.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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((b * c) <= -1.15e+71)
tmp = b * c;
elseif ((b * c) <= 7e-67)
tmp = k * (j * -27.0);
elseif ((b * c) <= 1.25e+226)
tmp = t * (a * -4.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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1.15e+71], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 7e-67], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.25e+226], N[(t * N[(a * -4.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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.15 \cdot 10^{+71}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \cdot c \leq 7 \cdot 10^{-67}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\
\mathbf{elif}\;b \cdot c \leq 1.25 \cdot 10^{+226}:\\
\;\;\;\;t \cdot \left(a \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if (*.f64 b c) < -1.1500000000000001e71 or 1.2500000000000001e226 < (*.f64 b c) Initial program 80.6%
Simplified81.6%
Taylor expanded in y around 0 77.4%
Taylor expanded in b around inf 58.6%
if -1.1500000000000001e71 < (*.f64 b c) < 7.0000000000000001e-67Initial program 92.1%
Simplified92.2%
Taylor expanded in j around inf 41.3%
associate-*r*41.3%
*-commutative41.3%
metadata-eval41.3%
distribute-rgt-neg-in41.3%
*-commutative41.3%
distribute-rgt-neg-in41.3%
metadata-eval41.3%
*-commutative41.3%
Simplified41.3%
if 7.0000000000000001e-67 < (*.f64 b c) < 1.2500000000000001e226Initial program 91.9%
Simplified93.9%
Taylor expanded in y around 0 84.0%
Taylor expanded in a around inf 41.1%
associate-*r*41.1%
*-commutative41.1%
Simplified41.1%
Final simplification47.5%
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 (<= z 3.15e+162) (- (+ (* b c) (* -4.0 (* t a))) (+ (* 4.0 (* x i)) (* 27.0 (* j k)))) (+ (* t (+ (* a -4.0) (* 18.0 (* x (* y z))))) (* j (* k -27.0)))))
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 (z <= 3.15e+162) {
tmp = ((b * c) + (-4.0 * (t * a))) - ((4.0 * (x * i)) + (27.0 * (j * k)));
} else {
tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (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.
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 (z <= 3.15d+162) then
tmp = ((b * c) + ((-4.0d0) * (t * a))) - ((4.0d0 * (x * i)) + (27.0d0 * (j * k)))
else
tmp = (t * ((a * (-4.0d0)) + (18.0d0 * (x * (y * z))))) + (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;
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 (z <= 3.15e+162) {
tmp = ((b * c) + (-4.0 * (t * a))) - ((4.0 * (x * i)) + (27.0 * (j * k)));
} else {
tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if z <= 3.15e+162: tmp = ((b * c) + (-4.0 * (t * a))) - ((4.0 * (x * i)) + (27.0 * (j * k))) else: tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (z <= 3.15e+162) tmp = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - Float64(Float64(4.0 * Float64(x * i)) + Float64(27.0 * Float64(j * k)))); else tmp = Float64(Float64(t * Float64(Float64(a * -4.0) + Float64(18.0 * Float64(x * Float64(y * z))))) + 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (z <= 3.15e+162)
tmp = ((b * c) + (-4.0 * (t * a))) - ((4.0 * (x * i)) + (27.0 * (j * k)));
else
tmp = (t * ((a * -4.0) + (18.0 * (x * (y * z))))) + (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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[z, 3.15e+162], N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(N[(a * -4.0), $MachinePrecision] + N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $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])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq 3.15 \cdot 10^{+162}:\\
\;\;\;\;\left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - \left(4 \cdot \left(x \cdot i\right) + 27 \cdot \left(j \cdot k\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(a \cdot -4 + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\
\end{array}
\end{array}
if z < 3.15e162Initial program 89.9%
Simplified91.2%
Taylor expanded in y around 0 83.6%
if 3.15e162 < z Initial program 73.3%
Simplified73.4%
Taylor expanded in t around inf 77.1%
Final simplification82.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (if (or (<= t -1.7e+55) (not (<= t 1.05e+79))) (* t (+ (* a -4.0) (* 18.0 (* x (* y z))))) (- (* b c) (+ (* 4.0 (* x i)) (* 27.0 (* j k))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -1.7e+55) || !(t <= 1.05e+79)) {
tmp = t * ((a * -4.0) + (18.0 * (x * (y * z))));
} else {
tmp = (b * c) - ((4.0 * (x * i)) + (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.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((t <= (-1.7d+55)) .or. (.not. (t <= 1.05d+79))) then
tmp = t * ((a * (-4.0d0)) + (18.0d0 * (x * (y * z))))
else
tmp = (b * c) - ((4.0d0 * (x * i)) + (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;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -1.7e+55) || !(t <= 1.05e+79)) {
tmp = t * ((a * -4.0) + (18.0 * (x * (y * z))));
} else {
tmp = (b * c) - ((4.0 * (x * i)) + (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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (t <= -1.7e+55) or not (t <= 1.05e+79): tmp = t * ((a * -4.0) + (18.0 * (x * (y * z)))) else: tmp = (b * c) - ((4.0 * (x * i)) + (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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((t <= -1.7e+55) || !(t <= 1.05e+79)) tmp = Float64(t * Float64(Float64(a * -4.0) + Float64(18.0 * Float64(x * Float64(y * z))))); else tmp = Float64(Float64(b * c) - Float64(Float64(4.0 * Float64(x * i)) + 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((t <= -1.7e+55) || ~((t <= 1.05e+79)))
tmp = t * ((a * -4.0) + (18.0 * (x * (y * z))));
else
tmp = (b * c) - ((4.0 * (x * i)) + (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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -1.7e+55], N[Not[LessEqual[t, 1.05e+79]], $MachinePrecision]], N[(t * N[(N[(a * -4.0), $MachinePrecision] + N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] - N[(N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.7 \cdot 10^{+55} \lor \neg \left(t \leq 1.05 \cdot 10^{+79}\right):\\
\;\;\;\;t \cdot \left(a \cdot -4 + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c - \left(4 \cdot \left(x \cdot i\right) + 27 \cdot \left(j \cdot k\right)\right)\\
\end{array}
\end{array}
if t < -1.6999999999999999e55 or 1.05000000000000004e79 < t Initial program 84.6%
Simplified91.8%
Taylor expanded in t around inf 82.8%
Taylor expanded in t around inf 75.0%
if -1.6999999999999999e55 < t < 1.05000000000000004e79Initial program 90.0%
Simplified88.1%
Taylor expanded in t around 0 81.4%
Final simplification79.0%
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 (<= t -1.7e-231)
(* b (+ c (/ (+ (* t (* a -4.0)) (* j (* k -27.0))) b)))
(if (<= t 1.9e+76)
(- (* b c) (+ (* 4.0 (* x i)) (* 27.0 (* j k))))
(* t (+ (* a -4.0) (* 18.0 (* x (* y z))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (t <= -1.7e-231) {
tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b));
} else if (t <= 1.9e+76) {
tmp = (b * c) - ((4.0 * (x * i)) + (27.0 * (j * k)));
} else {
tmp = t * ((a * -4.0) + (18.0 * (x * (y * z))));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (t <= (-1.7d-231)) then
tmp = b * (c + (((t * (a * (-4.0d0))) + (j * (k * (-27.0d0)))) / b))
else if (t <= 1.9d+76) then
tmp = (b * c) - ((4.0d0 * (x * i)) + (27.0d0 * (j * k)))
else
tmp = t * ((a * (-4.0d0)) + (18.0d0 * (x * (y * z))))
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;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (t <= -1.7e-231) {
tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b));
} else if (t <= 1.9e+76) {
tmp = (b * c) - ((4.0 * (x * i)) + (27.0 * (j * k)));
} else {
tmp = t * ((a * -4.0) + (18.0 * (x * (y * z))));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if t <= -1.7e-231: tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b)) elif t <= 1.9e+76: tmp = (b * c) - ((4.0 * (x * i)) + (27.0 * (j * k))) else: tmp = t * ((a * -4.0) + (18.0 * (x * (y * z)))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (t <= -1.7e-231) tmp = Float64(b * Float64(c + Float64(Float64(Float64(t * Float64(a * -4.0)) + Float64(j * Float64(k * -27.0))) / b))); elseif (t <= 1.9e+76) tmp = Float64(Float64(b * c) - Float64(Float64(4.0 * Float64(x * i)) + Float64(27.0 * Float64(j * k)))); else tmp = Float64(t * Float64(Float64(a * -4.0) + Float64(18.0 * Float64(x * Float64(y * z))))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (t <= -1.7e-231)
tmp = b * (c + (((t * (a * -4.0)) + (j * (k * -27.0))) / b));
elseif (t <= 1.9e+76)
tmp = (b * c) - ((4.0 * (x * i)) + (27.0 * (j * k)));
else
tmp = t * ((a * -4.0) + (18.0 * (x * (y * z))));
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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[t, -1.7e-231], N[(b * N[(c + N[(N[(N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.9e+76], N[(N[(b * c), $MachinePrecision] - N[(N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(a * -4.0), $MachinePrecision] + N[(18.0 * N[(x * N[(y * z), $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])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.7 \cdot 10^{-231}:\\
\;\;\;\;b \cdot \left(c + \frac{t \cdot \left(a \cdot -4\right) + j \cdot \left(k \cdot -27\right)}{b}\right)\\
\mathbf{elif}\;t \leq 1.9 \cdot 10^{+76}:\\
\;\;\;\;b \cdot c - \left(4 \cdot \left(x \cdot i\right) + 27 \cdot \left(j \cdot k\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(a \cdot -4 + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\end{array}
\end{array}
if t < -1.7e-231Initial program 87.7%
Simplified91.4%
Taylor expanded in x around 0 69.4%
Taylor expanded in b around inf 68.6%
associate--l+68.6%
associate-*r/68.6%
associate-*r/68.6%
div-sub72.3%
cancel-sign-sub-inv72.3%
associate-*r*72.3%
*-commutative72.3%
metadata-eval72.3%
associate-*r*72.3%
*-commutative72.3%
associate-*r*72.3%
Simplified72.3%
if -1.7e-231 < t < 1.90000000000000012e76Initial program 90.4%
Simplified86.6%
Taylor expanded in t around 0 85.7%
if 1.90000000000000012e76 < t Initial program 82.9%
Simplified89.3%
Taylor expanded in t around inf 87.5%
Taylor expanded in t around inf 83.4%
Final simplification79.8%
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) -1e+72)
(- (* b c) (* 4.0 (* x i)))
(if (<= (* b c) 2e+226)
(+ (* -4.0 (* t a)) (* j (* k -27.0)))
(* b (+ c (* -27.0 (/ (* j k) b)))))))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) <= -1e+72) {
tmp = (b * c) - (4.0 * (x * i));
} else if ((b * c) <= 2e+226) {
tmp = (-4.0 * (t * a)) + (j * (k * -27.0));
} else {
tmp = b * (c + (-27.0 * ((j * k) / b)));
}
return tmp;
}
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) <= (-1d+72)) then
tmp = (b * c) - (4.0d0 * (x * i))
else if ((b * c) <= 2d+226) then
tmp = ((-4.0d0) * (t * a)) + (j * (k * (-27.0d0)))
else
tmp = b * (c + ((-27.0d0) * ((j * k) / b)))
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;
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) <= -1e+72) {
tmp = (b * c) - (4.0 * (x * i));
} else if ((b * c) <= 2e+226) {
tmp = (-4.0 * (t * a)) + (j * (k * -27.0));
} else {
tmp = b * (c + (-27.0 * ((j * k) / b)));
}
return tmp;
}
[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) <= -1e+72: tmp = (b * c) - (4.0 * (x * i)) elif (b * c) <= 2e+226: tmp = (-4.0 * (t * a)) + (j * (k * -27.0)) else: tmp = b * (c + (-27.0 * ((j * k) / b))) return tmp
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) <= -1e+72) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); elseif (Float64(b * c) <= 2e+226) tmp = Float64(Float64(-4.0 * Float64(t * a)) + Float64(j * Float64(k * -27.0))); else tmp = Float64(b * Float64(c + Float64(-27.0 * Float64(Float64(j * k) / b)))); 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((b * c) <= -1e+72)
tmp = (b * c) - (4.0 * (x * i));
elseif ((b * c) <= 2e+226)
tmp = (-4.0 * (t * a)) + (j * (k * -27.0));
else
tmp = b * (c + (-27.0 * ((j * k) / b)));
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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1e+72], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2e+226], N[(N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(c + N[(-27.0 * N[(N[(j * k), $MachinePrecision] / b), $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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+72}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+226}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right) + j \cdot \left(k \cdot -27\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(c + -27 \cdot \frac{j \cdot k}{b}\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -9.99999999999999944e71Initial program 81.8%
Simplified83.3%
Taylor expanded in y around 0 75.1%
Taylor expanded in i around inf 71.5%
associate-*r*71.5%
*-commutative71.5%
associate-*r*71.5%
Simplified71.5%
Taylor expanded in a around 0 68.4%
if -9.99999999999999944e71 < (*.f64 b c) < 1.99999999999999992e226Initial program 92.1%
Simplified92.7%
Taylor expanded in a around inf 60.4%
*-commutative60.4%
Simplified60.4%
if 1.99999999999999992e226 < (*.f64 b c) Initial program 78.4%
Simplified81.5%
Taylor expanded in b around inf 69.7%
Taylor expanded in b around inf 76.0%
Final simplification64.2%
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) -1e+110) (not (<= (* b c) 5e+237))) (* b c) (* -4.0 (+ (* t a) (* x i)))))
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) <= -1e+110) || !((b * c) <= 5e+237)) {
tmp = b * c;
} else {
tmp = -4.0 * ((t * a) + (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.
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) <= (-1d+110)) .or. (.not. ((b * c) <= 5d+237))) then
tmp = b * c
else
tmp = (-4.0d0) * ((t * a) + (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;
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) <= -1e+110) || !((b * c) <= 5e+237)) {
tmp = b * c;
} else {
tmp = -4.0 * ((t * a) + (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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if ((b * c) <= -1e+110) or not ((b * c) <= 5e+237): tmp = b * c else: tmp = -4.0 * ((t * a) + (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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((Float64(b * c) <= -1e+110) || !(Float64(b * c) <= 5e+237)) tmp = Float64(b * c); else tmp = Float64(-4.0 * Float64(Float64(t * a) + 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (((b * c) <= -1e+110) || ~(((b * c) <= 5e+237)))
tmp = b * c;
else
tmp = -4.0 * ((t * a) + (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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -1e+110], N[Not[LessEqual[N[(b * c), $MachinePrecision], 5e+237]], $MachinePrecision]], N[(b * c), $MachinePrecision], N[(-4.0 * N[(N[(t * a), $MachinePrecision] + 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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+110} \lor \neg \left(b \cdot c \leq 5 \cdot 10^{+237}\right):\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(t \cdot a + x \cdot i\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -1e110 or 5.0000000000000002e237 < (*.f64 b c) Initial program 78.4%
Simplified80.9%
Taylor expanded in y around 0 75.9%
Taylor expanded in b around inf 62.6%
if -1e110 < (*.f64 b c) < 5.0000000000000002e237Initial program 92.1%
Simplified92.2%
Taylor expanded in y around 0 83.1%
Taylor expanded in i around inf 55.1%
associate-*r*55.1%
*-commutative55.1%
associate-*r*55.1%
Simplified55.1%
Taylor expanded in b around 0 48.8%
cancel-sign-sub-inv48.8%
metadata-eval48.8%
distribute-lft-out48.8%
Simplified48.8%
Final simplification53.0%
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) -4.8e+68) (not (<= (* b c) 8.5e+270))) (* b c) (* k (* j -27.0))))
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) <= -4.8e+68) || !((b * c) <= 8.5e+270)) {
tmp = b * c;
} else {
tmp = 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.
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) <= (-4.8d+68)) .or. (.not. ((b * c) <= 8.5d+270))) then
tmp = b * c
else
tmp = 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;
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) <= -4.8e+68) || !((b * c) <= 8.5e+270)) {
tmp = b * c;
} else {
tmp = 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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if ((b * c) <= -4.8e+68) or not ((b * c) <= 8.5e+270): tmp = b * c else: tmp = 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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((Float64(b * c) <= -4.8e+68) || !(Float64(b * c) <= 8.5e+270)) tmp = Float64(b * c); else tmp = 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (((b * c) <= -4.8e+68) || ~(((b * c) <= 8.5e+270)))
tmp = b * c;
else
tmp = 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -4.8e+68], N[Not[LessEqual[N[(b * c), $MachinePrecision], 8.5e+270]], $MachinePrecision]], N[(b * c), $MachinePrecision], N[(k * N[(j * -27.0), $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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -4.8 \cdot 10^{+68} \lor \neg \left(b \cdot c \leq 8.5 \cdot 10^{+270}\right):\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -4.80000000000000016e68 or 8.50000000000000063e270 < (*.f64 b c) Initial program 79.9%
Simplified81.0%
Taylor expanded in y around 0 76.5%
Taylor expanded in b around inf 61.5%
if -4.80000000000000016e68 < (*.f64 b c) < 8.50000000000000063e270Initial program 91.9%
Simplified92.5%
Taylor expanded in j around inf 35.9%
associate-*r*35.9%
*-commutative35.9%
metadata-eval35.9%
distribute-rgt-neg-in35.9%
*-commutative35.9%
distribute-rgt-neg-in35.9%
metadata-eval35.9%
*-commutative35.9%
Simplified35.9%
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. (FPCore (x y z t a b c i j k) :precision binary64 (if (or (<= (* b c) -2.9e+71) (not (<= (* b c) 8.5e+270))) (* 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);
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) <= -2.9e+71) || !((b * c) <= 8.5e+270)) {
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.
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) <= (-2.9d+71)) .or. (.not. ((b * c) <= 8.5d+270))) 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;
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) <= -2.9e+71) || !((b * c) <= 8.5e+270)) {
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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if ((b * c) <= -2.9e+71) or not ((b * c) <= 8.5e+270): 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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((Float64(b * c) <= -2.9e+71) || !(Float64(b * c) <= 8.5e+270)) 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (((b * c) <= -2.9e+71) || ~(((b * c) <= 8.5e+270)))
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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -2.9e+71], N[Not[LessEqual[N[(b * c), $MachinePrecision], 8.5e+270]], $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])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -2.9 \cdot 10^{+71} \lor \neg \left(b \cdot c \leq 8.5 \cdot 10^{+270}\right):\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\end{array}
\end{array}
if (*.f64 b c) < -2.90000000000000007e71 or 8.50000000000000063e270 < (*.f64 b c) Initial program 79.9%
Simplified81.0%
Taylor expanded in y around 0 76.5%
Taylor expanded in b around inf 61.5%
if -2.90000000000000007e71 < (*.f64 b c) < 8.50000000000000063e270Initial program 91.9%
Simplified92.5%
Taylor expanded in j around inf 35.9%
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.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= t -4.3e+173)
(+ (* b c) (* -4.0 (* t a)))
(if (<= t 8.5e+26)
(+ (* b c) (* j (* k -27.0)))
(* -4.0 (+ (* t a) (* x i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (t <= -4.3e+173) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (t <= 8.5e+26) {
tmp = (b * c) + (j * (k * -27.0));
} else {
tmp = -4.0 * ((t * a) + (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.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (t <= (-4.3d+173)) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else if (t <= 8.5d+26) then
tmp = (b * c) + (j * (k * (-27.0d0)))
else
tmp = (-4.0d0) * ((t * a) + (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;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (t <= -4.3e+173) {
tmp = (b * c) + (-4.0 * (t * a));
} else if (t <= 8.5e+26) {
tmp = (b * c) + (j * (k * -27.0));
} else {
tmp = -4.0 * ((t * a) + (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]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if t <= -4.3e+173: tmp = (b * c) + (-4.0 * (t * a)) elif t <= 8.5e+26: tmp = (b * c) + (j * (k * -27.0)) else: tmp = -4.0 * ((t * a) + (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]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (t <= -4.3e+173) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); elseif (t <= 8.5e+26) tmp = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0))); else tmp = Float64(-4.0 * Float64(Float64(t * a) + 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (t <= -4.3e+173)
tmp = (b * c) + (-4.0 * (t * a));
elseif (t <= 8.5e+26)
tmp = (b * c) + (j * (k * -27.0));
else
tmp = -4.0 * ((t * a) + (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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[t, -4.3e+173], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 8.5e+26], N[(N[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-4.0 * N[(N[(t * a), $MachinePrecision] + 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])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.3 \cdot 10^{+173}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;t \leq 8.5 \cdot 10^{+26}:\\
\;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\
\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(t \cdot a + x \cdot i\right)\\
\end{array}
\end{array}
if t < -4.30000000000000025e173Initial program 82.8%
Simplified88.5%
Taylor expanded in x around 0 67.0%
Taylor expanded in j around 0 61.1%
if -4.30000000000000025e173 < t < 8.5e26Initial program 90.3%
Simplified90.9%
Taylor expanded in b around inf 60.8%
if 8.5e26 < t Initial program 84.5%
Simplified86.2%
Taylor expanded in y around 0 71.2%
Taylor expanded in i around inf 66.3%
associate-*r*66.3%
*-commutative66.3%
associate-*r*66.3%
Simplified66.3%
Taylor expanded in b around 0 55.9%
cancel-sign-sub-inv55.9%
metadata-eval55.9%
distribute-lft-out55.9%
Simplified55.9%
Final simplification59.7%
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);
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.
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;
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]) 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]) 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])){:}
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. 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])\\
\\
b \cdot c
\end{array}
Initial program 87.9%
Simplified88.7%
Taylor expanded in y around 0 80.9%
Taylor expanded in b around inf 24.7%
(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 2024138
(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
(! :herbie-platform default (if (< t -8105407698770699/5000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- (- (* (* 18 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4)) (- (* (* k j) 27) (* c b))) (if (< t 8284013971902611/50000000000000) (+ (- (* (* 18 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4)) (- (* c b) (* 27 (* k j)))) (- (- (* (* 18 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4)) (- (* (* k j) 27) (* c b))))))
(- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))