
(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 24 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i j k) :precision binary64 (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k): return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (<= t -6.5e-245)
(+
(fma t (fma x (* 18.0 (* y z)) (* a -4.0)) (fma b c (* x (* -4.0 i))))
t_1)
(if (<= t 6.4e-57)
(+ t_1 (fma x (fma 18.0 (* y (* t z)) (* -4.0 i)) (* b c)))
(fma
(fma x (* z (* 18.0 y)) (* a (- 4.0)))
t
(- (* b c) (fma j (* k 27.0) (* i (* x 4.0)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (t <= -6.5e-245) {
tmp = fma(t, fma(x, (18.0 * (y * z)), (a * -4.0)), fma(b, c, (x * (-4.0 * i)))) + t_1;
} else if (t <= 6.4e-57) {
tmp = t_1 + fma(x, fma(18.0, (y * (t * z)), (-4.0 * i)), (b * c));
} else {
tmp = fma(fma(x, (z * (18.0 * y)), (a * -4.0)), t, ((b * c) - fma(j, (k * 27.0), (i * (x * 4.0)))));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (t <= -6.5e-245) tmp = Float64(fma(t, fma(x, Float64(18.0 * Float64(y * z)), Float64(a * -4.0)), fma(b, c, Float64(x * Float64(-4.0 * i)))) + t_1); elseif (t <= 6.4e-57) tmp = Float64(t_1 + fma(x, fma(18.0, Float64(y * Float64(t * z)), Float64(-4.0 * i)), Float64(b * c))); else tmp = fma(fma(x, Float64(z * Float64(18.0 * y)), Float64(a * Float64(-4.0))), t, Float64(Float64(b * c) - fma(j, Float64(k * 27.0), Float64(i * Float64(x * 4.0))))); end return tmp end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -6.5e-245], N[(N[(t * N[(x * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(b * c + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision], If[LessEqual[t, 6.4e-57], N[(t$95$1 + N[(x * N[(18.0 * N[(y * N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(z * N[(18.0 * y), $MachinePrecision]), $MachinePrecision] + N[(a * (-4.0)), $MachinePrecision]), $MachinePrecision] * t + N[(N[(b * c), $MachinePrecision] - N[(j * N[(k * 27.0), $MachinePrecision] + N[(i * N[(x * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;t \leq -6.5 \cdot 10^{-245}:\\
\;\;\;\;\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(-4 \cdot i\right)\right)\right) + t_1\\
\mathbf{elif}\;t \leq 6.4 \cdot 10^{-57}:\\
\;\;\;\;t_1 + \mathsf{fma}\left(x, \mathsf{fma}\left(18, y \cdot \left(t \cdot z\right), -4 \cdot i\right), b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(x, z \cdot \left(18 \cdot y\right), a \cdot \left(-4\right)\right), t, b \cdot c - \mathsf{fma}\left(j, k \cdot 27, i \cdot \left(x \cdot 4\right)\right)\right)\\
\end{array}
\end{array}
if t < -6.5000000000000004e-245Initial program 84.7%
Simplified92.2%
if -6.5000000000000004e-245 < t < 6.4000000000000002e-57Initial program 78.5%
Simplified79.9%
associate-*r*78.5%
distribute-rgt-out--78.5%
associate-*l*85.3%
*-commutative85.3%
*-commutative85.3%
Applied egg-rr85.3%
Taylor expanded in a around 0 77.1%
Simplified95.5%
if 6.4000000000000002e-57 < t Initial program 89.9%
Simplified97.0%
associate--l+97.0%
*-commutative97.0%
fma-def97.0%
associate-*l*97.0%
fma-neg97.0%
associate-*r*97.0%
associate-*r*97.0%
+-commutative97.0%
fma-def97.0%
*-commutative97.0%
*-commutative97.0%
Applied egg-rr97.0%
Final simplification94.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (or (<= t -6.5e-245) (not (<= t 7e-57)))
(+
(fma t (fma x (* 18.0 (* y z)) (* a -4.0)) (fma b c (* x (* -4.0 i))))
t_1)
(+ t_1 (fma x (fma 18.0 (* y (* t z)) (* -4.0 i)) (* b c))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if ((t <= -6.5e-245) || !(t <= 7e-57)) {
tmp = fma(t, fma(x, (18.0 * (y * z)), (a * -4.0)), fma(b, c, (x * (-4.0 * i)))) + t_1;
} else {
tmp = t_1 + fma(x, fma(18.0, (y * (t * z)), (-4.0 * i)), (b * c));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if ((t <= -6.5e-245) || !(t <= 7e-57)) tmp = Float64(fma(t, fma(x, Float64(18.0 * Float64(y * z)), Float64(a * -4.0)), fma(b, c, Float64(x * Float64(-4.0 * i)))) + t_1); else tmp = Float64(t_1 + fma(x, fma(18.0, Float64(y * Float64(t * z)), Float64(-4.0 * i)), Float64(b * c))); end return tmp end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t, -6.5e-245], N[Not[LessEqual[t, 7e-57]], $MachinePrecision]], N[(N[(t * N[(x * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(b * c + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision], N[(t$95$1 + N[(x * N[(18.0 * N[(y * N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;t \leq -6.5 \cdot 10^{-245} \lor \neg \left(t \leq 7 \cdot 10^{-57}\right):\\
\;\;\;\;\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(-4 \cdot i\right)\right)\right) + t_1\\
\mathbf{else}:\\
\;\;\;\;t_1 + \mathsf{fma}\left(x, \mathsf{fma}\left(18, y \cdot \left(t \cdot z\right), -4 \cdot i\right), b \cdot c\right)\\
\end{array}
\end{array}
if t < -6.5000000000000004e-245 or 6.99999999999999983e-57 < t Initial program 86.6%
Simplified94.0%
if -6.5000000000000004e-245 < t < 6.99999999999999983e-57Initial program 78.5%
Simplified79.9%
associate-*r*78.5%
distribute-rgt-out--78.5%
associate-*l*85.3%
*-commutative85.3%
*-commutative85.3%
Applied egg-rr85.3%
Taylor expanded in a around 0 77.1%
Simplified95.5%
Final simplification94.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0)))
(t_2 (+ t_1 (* b c)))
(t_3 (+ t_1 (* -4.0 (* t a))))
(t_4 (+ t_1 (* x (* -4.0 i))))
(t_5 (* x (* y z))))
(if (<= (* b c) -4.7e+39)
t_2
(if (<= (* b c) -2.7e-66)
t_4
(if (<= (* b c) -3.3e-166)
t_3
(if (<= (* b c) 1.65e-177)
t_4
(if (<= (* b c) 1.25e-110)
t_3
(if (<= (* b c) 1.4e-44)
(* t_5 (* t 18.0))
(if (<= (* b c) 4e+17)
t_3
(if (<= (* b c) 6.2e+35)
(* 18.0 (* t t_5))
(if (<= (* b c) 2.25e+189) t_4 t_2)))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double t_2 = t_1 + (b * c);
double t_3 = t_1 + (-4.0 * (t * a));
double t_4 = t_1 + (x * (-4.0 * i));
double t_5 = x * (y * z);
double tmp;
if ((b * c) <= -4.7e+39) {
tmp = t_2;
} else if ((b * c) <= -2.7e-66) {
tmp = t_4;
} else if ((b * c) <= -3.3e-166) {
tmp = t_3;
} else if ((b * c) <= 1.65e-177) {
tmp = t_4;
} else if ((b * c) <= 1.25e-110) {
tmp = t_3;
} else if ((b * c) <= 1.4e-44) {
tmp = t_5 * (t * 18.0);
} else if ((b * c) <= 4e+17) {
tmp = t_3;
} else if ((b * c) <= 6.2e+35) {
tmp = 18.0 * (t * t_5);
} else if ((b * c) <= 2.25e+189) {
tmp = t_4;
} else {
tmp = t_2;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
t_2 = t_1 + (b * c)
t_3 = t_1 + ((-4.0d0) * (t * a))
t_4 = t_1 + (x * ((-4.0d0) * i))
t_5 = x * (y * z)
if ((b * c) <= (-4.7d+39)) then
tmp = t_2
else if ((b * c) <= (-2.7d-66)) then
tmp = t_4
else if ((b * c) <= (-3.3d-166)) then
tmp = t_3
else if ((b * c) <= 1.65d-177) then
tmp = t_4
else if ((b * c) <= 1.25d-110) then
tmp = t_3
else if ((b * c) <= 1.4d-44) then
tmp = t_5 * (t * 18.0d0)
else if ((b * c) <= 4d+17) then
tmp = t_3
else if ((b * c) <= 6.2d+35) then
tmp = 18.0d0 * (t * t_5)
else if ((b * c) <= 2.25d+189) then
tmp = t_4
else
tmp = t_2
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double t_2 = t_1 + (b * c);
double t_3 = t_1 + (-4.0 * (t * a));
double t_4 = t_1 + (x * (-4.0 * i));
double t_5 = x * (y * z);
double tmp;
if ((b * c) <= -4.7e+39) {
tmp = t_2;
} else if ((b * c) <= -2.7e-66) {
tmp = t_4;
} else if ((b * c) <= -3.3e-166) {
tmp = t_3;
} else if ((b * c) <= 1.65e-177) {
tmp = t_4;
} else if ((b * c) <= 1.25e-110) {
tmp = t_3;
} else if ((b * c) <= 1.4e-44) {
tmp = t_5 * (t * 18.0);
} else if ((b * c) <= 4e+17) {
tmp = t_3;
} else if ((b * c) <= 6.2e+35) {
tmp = 18.0 * (t * t_5);
} else if ((b * c) <= 2.25e+189) {
tmp = t_4;
} else {
tmp = t_2;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) t_2 = t_1 + (b * c) t_3 = t_1 + (-4.0 * (t * a)) t_4 = t_1 + (x * (-4.0 * i)) t_5 = x * (y * z) tmp = 0 if (b * c) <= -4.7e+39: tmp = t_2 elif (b * c) <= -2.7e-66: tmp = t_4 elif (b * c) <= -3.3e-166: tmp = t_3 elif (b * c) <= 1.65e-177: tmp = t_4 elif (b * c) <= 1.25e-110: tmp = t_3 elif (b * c) <= 1.4e-44: tmp = t_5 * (t * 18.0) elif (b * c) <= 4e+17: tmp = t_3 elif (b * c) <= 6.2e+35: tmp = 18.0 * (t * t_5) elif (b * c) <= 2.25e+189: tmp = t_4 else: tmp = t_2 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) t_2 = Float64(t_1 + Float64(b * c)) t_3 = Float64(t_1 + Float64(-4.0 * Float64(t * a))) t_4 = Float64(t_1 + Float64(x * Float64(-4.0 * i))) t_5 = Float64(x * Float64(y * z)) tmp = 0.0 if (Float64(b * c) <= -4.7e+39) tmp = t_2; elseif (Float64(b * c) <= -2.7e-66) tmp = t_4; elseif (Float64(b * c) <= -3.3e-166) tmp = t_3; elseif (Float64(b * c) <= 1.65e-177) tmp = t_4; elseif (Float64(b * c) <= 1.25e-110) tmp = t_3; elseif (Float64(b * c) <= 1.4e-44) tmp = Float64(t_5 * Float64(t * 18.0)); elseif (Float64(b * c) <= 4e+17) tmp = t_3; elseif (Float64(b * c) <= 6.2e+35) tmp = Float64(18.0 * Float64(t * t_5)); elseif (Float64(b * c) <= 2.25e+189) tmp = t_4; else tmp = t_2; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
t_2 = t_1 + (b * c);
t_3 = t_1 + (-4.0 * (t * a));
t_4 = t_1 + (x * (-4.0 * i));
t_5 = x * (y * z);
tmp = 0.0;
if ((b * c) <= -4.7e+39)
tmp = t_2;
elseif ((b * c) <= -2.7e-66)
tmp = t_4;
elseif ((b * c) <= -3.3e-166)
tmp = t_3;
elseif ((b * c) <= 1.65e-177)
tmp = t_4;
elseif ((b * c) <= 1.25e-110)
tmp = t_3;
elseif ((b * c) <= 1.4e-44)
tmp = t_5 * (t * 18.0);
elseif ((b * c) <= 4e+17)
tmp = t_3;
elseif ((b * c) <= 6.2e+35)
tmp = 18.0 * (t * t_5);
elseif ((b * c) <= 2.25e+189)
tmp = t_4;
else
tmp = t_2;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 + N[(b * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$1 + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(t$95$1 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -4.7e+39], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], -2.7e-66], t$95$4, If[LessEqual[N[(b * c), $MachinePrecision], -3.3e-166], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 1.65e-177], t$95$4, If[LessEqual[N[(b * c), $MachinePrecision], 1.25e-110], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 1.4e-44], N[(t$95$5 * N[(t * 18.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 4e+17], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 6.2e+35], N[(18.0 * N[(t * t$95$5), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2.25e+189], t$95$4, t$95$2]]]]]]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
t_2 := t_1 + b \cdot c\\
t_3 := t_1 + -4 \cdot \left(t \cdot a\right)\\
t_4 := t_1 + x \cdot \left(-4 \cdot i\right)\\
t_5 := x \cdot \left(y \cdot z\right)\\
\mathbf{if}\;b \cdot c \leq -4.7 \cdot 10^{+39}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;b \cdot c \leq -2.7 \cdot 10^{-66}:\\
\;\;\;\;t_4\\
\mathbf{elif}\;b \cdot c \leq -3.3 \cdot 10^{-166}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;b \cdot c \leq 1.65 \cdot 10^{-177}:\\
\;\;\;\;t_4\\
\mathbf{elif}\;b \cdot c \leq 1.25 \cdot 10^{-110}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;b \cdot c \leq 1.4 \cdot 10^{-44}:\\
\;\;\;\;t_5 \cdot \left(t \cdot 18\right)\\
\mathbf{elif}\;b \cdot c \leq 4 \cdot 10^{+17}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;b \cdot c \leq 6.2 \cdot 10^{+35}:\\
\;\;\;\;18 \cdot \left(t \cdot t_5\right)\\
\mathbf{elif}\;b \cdot c \leq 2.25 \cdot 10^{+189}:\\
\;\;\;\;t_4\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if (*.f64 b c) < -4.6999999999999999e39 or 2.24999999999999987e189 < (*.f64 b c) Initial program 82.9%
Simplified86.4%
Taylor expanded in b around inf 77.7%
if -4.6999999999999999e39 < (*.f64 b c) < -2.69999999999999996e-66 or -3.30000000000000018e-166 < (*.f64 b c) < 1.65e-177 or 6.19999999999999973e35 < (*.f64 b c) < 2.24999999999999987e189Initial program 84.6%
Simplified89.6%
Taylor expanded in i around inf 62.9%
associate-*r*62.9%
*-commutative62.9%
Simplified62.9%
if -2.69999999999999996e-66 < (*.f64 b c) < -3.30000000000000018e-166 or 1.65e-177 < (*.f64 b c) < 1.25e-110 or 1.4e-44 < (*.f64 b c) < 4e17Initial program 93.1%
Simplified96.3%
Taylor expanded in a around inf 79.8%
*-commutative79.8%
Simplified79.8%
if 1.25e-110 < (*.f64 b c) < 1.4e-44Initial program 84.9%
Simplified99.7%
associate--l+99.7%
*-commutative99.7%
fma-def99.7%
associate-*l*99.7%
fma-neg99.7%
associate-*r*94.8%
associate-*r*94.8%
+-commutative94.8%
fma-def94.8%
*-commutative94.8%
*-commutative94.8%
Applied egg-rr94.8%
Taylor expanded in y around inf 50.5%
associate-*r*50.6%
*-commutative50.6%
*-commutative50.6%
Simplified50.6%
if 4e17 < (*.f64 b c) < 6.19999999999999973e35Initial program 50.0%
Simplified100.0%
associate--l+100.0%
*-commutative100.0%
fma-def100.0%
associate-*l*100.0%
fma-neg100.0%
associate-*r*100.0%
associate-*r*100.0%
+-commutative100.0%
fma-def100.0%
*-commutative100.0%
*-commutative100.0%
Applied egg-rr100.0%
Taylor expanded in y around inf 100.0%
Final simplification69.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<=
(-
(-
(+ (* b c) (- (* t (* z (* y (* x 18.0)))) (* t (* a 4.0))))
(* i (* x 4.0)))
(* k (* j 27.0)))
INFINITY)
(-
(+ (* b c) (* t (- (* (* y z) (* x 18.0)) (* a 4.0))))
(+ (* x (* i 4.0)) (* j (* k 27.0))))
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (((((b * c) + ((t * (z * (y * (x * 18.0)))) - (t * (a * 4.0)))) - (i * (x * 4.0))) - (k * (j * 27.0))) <= ((double) INFINITY)) {
tmp = ((b * c) + (t * (((y * z) * (x * 18.0)) - (a * 4.0)))) - ((x * (i * 4.0)) + (j * (k * 27.0)));
} else {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
}
return tmp;
}
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (((((b * c) + ((t * (z * (y * (x * 18.0)))) - (t * (a * 4.0)))) - (i * (x * 4.0))) - (k * (j * 27.0))) <= Double.POSITIVE_INFINITY) {
tmp = ((b * c) + (t * (((y * z) * (x * 18.0)) - (a * 4.0)))) - ((x * (i * 4.0)) + (j * (k * 27.0)));
} else {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if ((((b * c) + ((t * (z * (y * (x * 18.0)))) - (t * (a * 4.0)))) - (i * (x * 4.0))) - (k * (j * 27.0))) <= math.inf: tmp = ((b * c) + (t * (((y * z) * (x * 18.0)) - (a * 4.0)))) - ((x * (i * 4.0)) + (j * (k * 27.0))) else: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (Float64(Float64(Float64(Float64(b * c) + Float64(Float64(t * Float64(z * Float64(y * Float64(x * 18.0)))) - Float64(t * Float64(a * 4.0)))) - Float64(i * Float64(x * 4.0))) - Float64(k * Float64(j * 27.0))) <= Inf) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(y * z) * Float64(x * 18.0)) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(i * 4.0)) + Float64(j * Float64(k * 27.0)))); else tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (((((b * c) + ((t * (z * (y * (x * 18.0)))) - (t * (a * 4.0)))) - (i * (x * 4.0))) - (k * (j * 27.0))) <= Inf)
tmp = ((b * c) + (t * (((y * z) * (x * 18.0)) - (a * 4.0)))) - ((x * (i * 4.0)) + (j * (k * 27.0)));
else
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * N[(z * N[(y * N[(x * 18.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * N[(x * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(y * z), $MachinePrecision] * N[(x * 18.0), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(i * 4.0), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;\left(\left(b \cdot c + \left(t \cdot \left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right) - t \cdot \left(a \cdot 4\right)\right)\right) - i \cdot \left(x \cdot 4\right)\right) - k \cdot \left(j \cdot 27\right) \leq \infty:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot 18\right) - a \cdot 4\right)\right) - \left(x \cdot \left(i \cdot 4\right) + j \cdot \left(k \cdot 27\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\end{array}
\end{array}
if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) < +inf.0Initial program 96.1%
Simplified96.0%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) Initial program 0.0%
Simplified35.5%
Taylor expanded in x around inf 61.6%
expm1-log1p-u32.5%
expm1-udef32.5%
Applied egg-rr32.5%
expm1-def32.5%
expm1-log1p61.6%
associate-*r*61.6%
Simplified61.6%
Final simplification91.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0)))
(t_2 (+ t_1 (* b c)))
(t_3 (+ t_1 (* -4.0 (* t a)))))
(if (<= (* b c) -5.8e-42)
t_2
(if (<= (* b c) 1.22e-110)
t_3
(if (<= (* b c) 1.5e-44)
(* (* x (* y z)) (* t 18.0))
(if (<= (* b c) 5e+139)
t_3
(if (<= (* b c) 2.4e+169)
(* -4.0 (* x i))
(if (<= (* b c) 5.6e+247) t_3 t_2))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double t_2 = t_1 + (b * c);
double t_3 = t_1 + (-4.0 * (t * a));
double tmp;
if ((b * c) <= -5.8e-42) {
tmp = t_2;
} else if ((b * c) <= 1.22e-110) {
tmp = t_3;
} else if ((b * c) <= 1.5e-44) {
tmp = (x * (y * z)) * (t * 18.0);
} else if ((b * c) <= 5e+139) {
tmp = t_3;
} else if ((b * c) <= 2.4e+169) {
tmp = -4.0 * (x * i);
} else if ((b * c) <= 5.6e+247) {
tmp = t_3;
} else {
tmp = t_2;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
t_2 = t_1 + (b * c)
t_3 = t_1 + ((-4.0d0) * (t * a))
if ((b * c) <= (-5.8d-42)) then
tmp = t_2
else if ((b * c) <= 1.22d-110) then
tmp = t_3
else if ((b * c) <= 1.5d-44) then
tmp = (x * (y * z)) * (t * 18.0d0)
else if ((b * c) <= 5d+139) then
tmp = t_3
else if ((b * c) <= 2.4d+169) then
tmp = (-4.0d0) * (x * i)
else if ((b * c) <= 5.6d+247) then
tmp = t_3
else
tmp = t_2
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double t_2 = t_1 + (b * c);
double t_3 = t_1 + (-4.0 * (t * a));
double tmp;
if ((b * c) <= -5.8e-42) {
tmp = t_2;
} else if ((b * c) <= 1.22e-110) {
tmp = t_3;
} else if ((b * c) <= 1.5e-44) {
tmp = (x * (y * z)) * (t * 18.0);
} else if ((b * c) <= 5e+139) {
tmp = t_3;
} else if ((b * c) <= 2.4e+169) {
tmp = -4.0 * (x * i);
} else if ((b * c) <= 5.6e+247) {
tmp = t_3;
} else {
tmp = t_2;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) t_2 = t_1 + (b * c) t_3 = t_1 + (-4.0 * (t * a)) tmp = 0 if (b * c) <= -5.8e-42: tmp = t_2 elif (b * c) <= 1.22e-110: tmp = t_3 elif (b * c) <= 1.5e-44: tmp = (x * (y * z)) * (t * 18.0) elif (b * c) <= 5e+139: tmp = t_3 elif (b * c) <= 2.4e+169: tmp = -4.0 * (x * i) elif (b * c) <= 5.6e+247: tmp = t_3 else: tmp = t_2 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) t_2 = Float64(t_1 + Float64(b * c)) t_3 = Float64(t_1 + Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (Float64(b * c) <= -5.8e-42) tmp = t_2; elseif (Float64(b * c) <= 1.22e-110) tmp = t_3; elseif (Float64(b * c) <= 1.5e-44) tmp = Float64(Float64(x * Float64(y * z)) * Float64(t * 18.0)); elseif (Float64(b * c) <= 5e+139) tmp = t_3; elseif (Float64(b * c) <= 2.4e+169) tmp = Float64(-4.0 * Float64(x * i)); elseif (Float64(b * c) <= 5.6e+247) tmp = t_3; else tmp = t_2; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
t_2 = t_1 + (b * c);
t_3 = t_1 + (-4.0 * (t * a));
tmp = 0.0;
if ((b * c) <= -5.8e-42)
tmp = t_2;
elseif ((b * c) <= 1.22e-110)
tmp = t_3;
elseif ((b * c) <= 1.5e-44)
tmp = (x * (y * z)) * (t * 18.0);
elseif ((b * c) <= 5e+139)
tmp = t_3;
elseif ((b * c) <= 2.4e+169)
tmp = -4.0 * (x * i);
elseif ((b * c) <= 5.6e+247)
tmp = t_3;
else
tmp = t_2;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 + N[(b * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$1 + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -5.8e-42], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], 1.22e-110], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 1.5e-44], N[(N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision] * N[(t * 18.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 5e+139], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 2.4e+169], N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 5.6e+247], t$95$3, t$95$2]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
t_2 := t_1 + b \cdot c\\
t_3 := t_1 + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;b \cdot c \leq -5.8 \cdot 10^{-42}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;b \cdot c \leq 1.22 \cdot 10^{-110}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;b \cdot c \leq 1.5 \cdot 10^{-44}:\\
\;\;\;\;\left(x \cdot \left(y \cdot z\right)\right) \cdot \left(t \cdot 18\right)\\
\mathbf{elif}\;b \cdot c \leq 5 \cdot 10^{+139}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;b \cdot c \leq 2.4 \cdot 10^{+169}:\\
\;\;\;\;-4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;b \cdot c \leq 5.6 \cdot 10^{+247}:\\
\;\;\;\;t_3\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if (*.f64 b c) < -5.8000000000000006e-42 or 5.59999999999999961e247 < (*.f64 b c) Initial program 84.0%
Simplified87.3%
Taylor expanded in b around inf 72.2%
if -5.8000000000000006e-42 < (*.f64 b c) < 1.22e-110 or 1.5000000000000001e-44 < (*.f64 b c) < 5.0000000000000003e139 or 2.3999999999999998e169 < (*.f64 b c) < 5.59999999999999961e247Initial program 84.7%
Simplified91.2%
Taylor expanded in a around inf 60.2%
*-commutative60.2%
Simplified60.2%
if 1.22e-110 < (*.f64 b c) < 1.5000000000000001e-44Initial program 84.9%
Simplified99.7%
associate--l+99.7%
*-commutative99.7%
fma-def99.7%
associate-*l*99.7%
fma-neg99.7%
associate-*r*94.8%
associate-*r*94.8%
+-commutative94.8%
fma-def94.8%
*-commutative94.8%
*-commutative94.8%
Applied egg-rr94.8%
Taylor expanded in y around inf 50.5%
associate-*r*50.6%
*-commutative50.6%
*-commutative50.6%
Simplified50.6%
if 5.0000000000000003e139 < (*.f64 b c) < 2.3999999999999998e169Initial program 84.4%
Simplified84.4%
associate--l+84.4%
*-commutative84.4%
fma-def84.4%
associate-*l*84.4%
fma-neg84.4%
associate-*r*84.4%
associate-*r*84.4%
+-commutative84.4%
fma-def84.4%
*-commutative84.4%
*-commutative84.4%
Applied egg-rr84.4%
Taylor expanded in i around inf 68.0%
*-commutative68.0%
Simplified68.0%
Final simplification64.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 4.0 (* x i)))
(t_2 (* k (* j 27.0)))
(t_3 (- (+ (* b c) (* -4.0 (* t a))) t_1)))
(if (<= t_2 -4e+53)
(- (- (* b c) t_1) t_2)
(if (<= t_2 500.0)
t_3
(if (<= t_2 3e+48)
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))
(if (<= t_2 1e+106) t_3 (+ (* j (* k -27.0)) (* b c))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 4.0 * (x * i);
double t_2 = k * (j * 27.0);
double t_3 = ((b * c) + (-4.0 * (t * a))) - t_1;
double tmp;
if (t_2 <= -4e+53) {
tmp = ((b * c) - t_1) - t_2;
} else if (t_2 <= 500.0) {
tmp = t_3;
} else if (t_2 <= 3e+48) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (t_2 <= 1e+106) {
tmp = t_3;
} else {
tmp = (j * (k * -27.0)) + (b * c);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = 4.0d0 * (x * i)
t_2 = k * (j * 27.0d0)
t_3 = ((b * c) + ((-4.0d0) * (t * a))) - t_1
if (t_2 <= (-4d+53)) then
tmp = ((b * c) - t_1) - t_2
else if (t_2 <= 500.0d0) then
tmp = t_3
else if (t_2 <= 3d+48) then
tmp = x * ((18.0d0 * (z * (t * y))) - (i * 4.0d0))
else if (t_2 <= 1d+106) then
tmp = t_3
else
tmp = (j * (k * (-27.0d0))) + (b * c)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 4.0 * (x * i);
double t_2 = k * (j * 27.0);
double t_3 = ((b * c) + (-4.0 * (t * a))) - t_1;
double tmp;
if (t_2 <= -4e+53) {
tmp = ((b * c) - t_1) - t_2;
} else if (t_2 <= 500.0) {
tmp = t_3;
} else if (t_2 <= 3e+48) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (t_2 <= 1e+106) {
tmp = t_3;
} else {
tmp = (j * (k * -27.0)) + (b * c);
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = 4.0 * (x * i) t_2 = k * (j * 27.0) t_3 = ((b * c) + (-4.0 * (t * a))) - t_1 tmp = 0 if t_2 <= -4e+53: tmp = ((b * c) - t_1) - t_2 elif t_2 <= 500.0: tmp = t_3 elif t_2 <= 3e+48: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) elif t_2 <= 1e+106: tmp = t_3 else: tmp = (j * (k * -27.0)) + (b * c) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(4.0 * Float64(x * i)) t_2 = Float64(k * Float64(j * 27.0)) t_3 = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - t_1) tmp = 0.0 if (t_2 <= -4e+53) tmp = Float64(Float64(Float64(b * c) - t_1) - t_2); elseif (t_2 <= 500.0) tmp = t_3; elseif (t_2 <= 3e+48) tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); elseif (t_2 <= 1e+106) tmp = t_3; else tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(b * c)); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = 4.0 * (x * i);
t_2 = k * (j * 27.0);
t_3 = ((b * c) + (-4.0 * (t * a))) - t_1;
tmp = 0.0;
if (t_2 <= -4e+53)
tmp = ((b * c) - t_1) - t_2;
elseif (t_2 <= 500.0)
tmp = t_3;
elseif (t_2 <= 3e+48)
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
elseif (t_2 <= 1e+106)
tmp = t_3;
else
tmp = (j * (k * -27.0)) + (b * c);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]}, If[LessEqual[t$95$2, -4e+53], N[(N[(N[(b * c), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[t$95$2, 500.0], t$95$3, If[LessEqual[t$95$2, 3e+48], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 1e+106], t$95$3, N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 4 \cdot \left(x \cdot i\right)\\
t_2 := k \cdot \left(j \cdot 27\right)\\
t_3 := \left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - t_1\\
\mathbf{if}\;t_2 \leq -4 \cdot 10^{+53}:\\
\;\;\;\;\left(b \cdot c - t_1\right) - t_2\\
\mathbf{elif}\;t_2 \leq 500:\\
\;\;\;\;t_3\\
\mathbf{elif}\;t_2 \leq 3 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\mathbf{elif}\;t_2 \leq 10^{+106}:\\
\;\;\;\;t_3\\
\mathbf{else}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + b \cdot c\\
\end{array}
\end{array}
if (*.f64 (*.f64 j 27) k) < -4e53Initial program 80.1%
Taylor expanded in t around 0 78.9%
if -4e53 < (*.f64 (*.f64 j 27) k) < 500 or 3e48 < (*.f64 (*.f64 j 27) k) < 1.00000000000000009e106Initial program 86.2%
Simplified89.6%
associate--l+89.6%
*-commutative89.6%
fma-def91.7%
associate-*l*91.7%
fma-neg91.7%
associate-*r*91.0%
associate-*r*91.0%
+-commutative91.0%
fma-def91.0%
*-commutative91.0%
*-commutative91.0%
Applied egg-rr91.0%
Taylor expanded in x around 0 81.9%
Taylor expanded in j around 0 78.7%
if 500 < (*.f64 (*.f64 j 27) k) < 3e48Initial program 61.5%
Simplified71.2%
Taylor expanded in x around inf 70.9%
expm1-log1p-u58.5%
expm1-udef58.5%
Applied egg-rr58.5%
expm1-def58.5%
expm1-log1p70.9%
associate-*r*61.4%
Simplified61.4%
if 1.00000000000000009e106 < (*.f64 (*.f64 j 27) k) Initial program 90.3%
Simplified90.5%
Taylor expanded in b around inf 81.0%
Final simplification78.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (<= x -5.2e+85)
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))
(if (<= x 9.2e-36)
(+ t_1 (* b c))
(if (<= x 112000000.0)
(+ t_1 (* -4.0 (* t a)))
(if (or (<= x 3.9e+135) (not (<= x 1.6e+237)))
(+ t_1 (* x (* -4.0 i)))
(+ t_1 (* 18.0 (* (* y z) (* t x))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -5.2e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 9.2e-36) {
tmp = t_1 + (b * c);
} else if (x <= 112000000.0) {
tmp = t_1 + (-4.0 * (t * a));
} else if ((x <= 3.9e+135) || !(x <= 1.6e+237)) {
tmp = t_1 + (x * (-4.0 * i));
} else {
tmp = t_1 + (18.0 * ((y * z) * (t * x)));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
if (x <= (-5.2d+85)) then
tmp = x * ((18.0d0 * (z * (t * y))) - (i * 4.0d0))
else if (x <= 9.2d-36) then
tmp = t_1 + (b * c)
else if (x <= 112000000.0d0) then
tmp = t_1 + ((-4.0d0) * (t * a))
else if ((x <= 3.9d+135) .or. (.not. (x <= 1.6d+237))) then
tmp = t_1 + (x * ((-4.0d0) * i))
else
tmp = t_1 + (18.0d0 * ((y * z) * (t * x)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -5.2e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 9.2e-36) {
tmp = t_1 + (b * c);
} else if (x <= 112000000.0) {
tmp = t_1 + (-4.0 * (t * a));
} else if ((x <= 3.9e+135) || !(x <= 1.6e+237)) {
tmp = t_1 + (x * (-4.0 * i));
} else {
tmp = t_1 + (18.0 * ((y * z) * (t * x)));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) tmp = 0 if x <= -5.2e+85: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) elif x <= 9.2e-36: tmp = t_1 + (b * c) elif x <= 112000000.0: tmp = t_1 + (-4.0 * (t * a)) elif (x <= 3.9e+135) or not (x <= 1.6e+237): tmp = t_1 + (x * (-4.0 * i)) else: tmp = t_1 + (18.0 * ((y * z) * (t * x))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -5.2e+85) tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); elseif (x <= 9.2e-36) tmp = Float64(t_1 + Float64(b * c)); elseif (x <= 112000000.0) tmp = Float64(t_1 + Float64(-4.0 * Float64(t * a))); elseif ((x <= 3.9e+135) || !(x <= 1.6e+237)) tmp = Float64(t_1 + Float64(x * Float64(-4.0 * i))); else tmp = Float64(t_1 + Float64(18.0 * Float64(Float64(y * z) * Float64(t * x)))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
tmp = 0.0;
if (x <= -5.2e+85)
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
elseif (x <= 9.2e-36)
tmp = t_1 + (b * c);
elseif (x <= 112000000.0)
tmp = t_1 + (-4.0 * (t * a));
elseif ((x <= 3.9e+135) || ~((x <= 1.6e+237)))
tmp = t_1 + (x * (-4.0 * i));
else
tmp = t_1 + (18.0 * ((y * z) * (t * x)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.2e+85], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 9.2e-36], N[(t$95$1 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 112000000.0], N[(t$95$1 + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[x, 3.9e+135], N[Not[LessEqual[x, 1.6e+237]], $MachinePrecision]], N[(t$95$1 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(t * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -5.2 \cdot 10^{+85}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\mathbf{elif}\;x \leq 9.2 \cdot 10^{-36}:\\
\;\;\;\;t_1 + b \cdot c\\
\mathbf{elif}\;x \leq 112000000:\\
\;\;\;\;t_1 + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 3.9 \cdot 10^{+135} \lor \neg \left(x \leq 1.6 \cdot 10^{+237}\right):\\
\;\;\;\;t_1 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t_1 + 18 \cdot \left(\left(y \cdot z\right) \cdot \left(t \cdot x\right)\right)\\
\end{array}
\end{array}
if x < -5.20000000000000021e85Initial program 69.6%
Simplified84.7%
Taylor expanded in x around inf 77.5%
expm1-log1p-u61.5%
expm1-udef59.8%
Applied egg-rr59.8%
expm1-def61.5%
expm1-log1p77.5%
associate-*r*75.8%
Simplified75.8%
if -5.20000000000000021e85 < x < 9.19999999999999986e-36Initial program 92.0%
Simplified91.9%
Taylor expanded in b around inf 63.9%
if 9.19999999999999986e-36 < x < 1.12e8Initial program 85.5%
Simplified93.3%
Taylor expanded in a around inf 71.6%
*-commutative71.6%
Simplified71.6%
if 1.12e8 < x < 3.90000000000000032e135 or 1.60000000000000009e237 < x Initial program 87.5%
Simplified95.0%
Taylor expanded in i around inf 66.4%
associate-*r*66.4%
*-commutative66.4%
Simplified66.4%
if 3.90000000000000032e135 < x < 1.60000000000000009e237Initial program 72.1%
Simplified80.1%
Taylor expanded in y around inf 74.7%
associate-*r*74.4%
Simplified74.4%
Final simplification68.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (<= x -8.8e+85)
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))
(if (<= x 7e-37)
(+ t_1 (* b c))
(if (<= x 112000000.0)
(+ t_1 (* -4.0 (* t a)))
(if (or (<= x 5.3e+143) (not (<= x 1.05e+241)))
(+ t_1 (* x (* -4.0 i)))
(+ t_1 (* x (* (* t y) (* 18.0 z))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -8.8e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 7e-37) {
tmp = t_1 + (b * c);
} else if (x <= 112000000.0) {
tmp = t_1 + (-4.0 * (t * a));
} else if ((x <= 5.3e+143) || !(x <= 1.05e+241)) {
tmp = t_1 + (x * (-4.0 * i));
} else {
tmp = t_1 + (x * ((t * y) * (18.0 * 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.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
if (x <= (-8.8d+85)) then
tmp = x * ((18.0d0 * (z * (t * y))) - (i * 4.0d0))
else if (x <= 7d-37) then
tmp = t_1 + (b * c)
else if (x <= 112000000.0d0) then
tmp = t_1 + ((-4.0d0) * (t * a))
else if ((x <= 5.3d+143) .or. (.not. (x <= 1.05d+241))) then
tmp = t_1 + (x * ((-4.0d0) * i))
else
tmp = t_1 + (x * ((t * y) * (18.0d0 * 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;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -8.8e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 7e-37) {
tmp = t_1 + (b * c);
} else if (x <= 112000000.0) {
tmp = t_1 + (-4.0 * (t * a));
} else if ((x <= 5.3e+143) || !(x <= 1.05e+241)) {
tmp = t_1 + (x * (-4.0 * i));
} else {
tmp = t_1 + (x * ((t * y) * (18.0 * z)));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) tmp = 0 if x <= -8.8e+85: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) elif x <= 7e-37: tmp = t_1 + (b * c) elif x <= 112000000.0: tmp = t_1 + (-4.0 * (t * a)) elif (x <= 5.3e+143) or not (x <= 1.05e+241): tmp = t_1 + (x * (-4.0 * i)) else: tmp = t_1 + (x * ((t * y) * (18.0 * z))) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -8.8e+85) tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); elseif (x <= 7e-37) tmp = Float64(t_1 + Float64(b * c)); elseif (x <= 112000000.0) tmp = Float64(t_1 + Float64(-4.0 * Float64(t * a))); elseif ((x <= 5.3e+143) || !(x <= 1.05e+241)) tmp = Float64(t_1 + Float64(x * Float64(-4.0 * i))); else tmp = Float64(t_1 + Float64(x * Float64(Float64(t * y) * Float64(18.0 * 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])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
tmp = 0.0;
if (x <= -8.8e+85)
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
elseif (x <= 7e-37)
tmp = t_1 + (b * c);
elseif (x <= 112000000.0)
tmp = t_1 + (-4.0 * (t * a));
elseif ((x <= 5.3e+143) || ~((x <= 1.05e+241)))
tmp = t_1 + (x * (-4.0 * i));
else
tmp = t_1 + (x * ((t * y) * (18.0 * 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.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -8.8e+85], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 7e-37], N[(t$95$1 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 112000000.0], N[(t$95$1 + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[x, 5.3e+143], N[Not[LessEqual[x, 1.05e+241]], $MachinePrecision]], N[(t$95$1 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(x * N[(N[(t * y), $MachinePrecision] * N[(18.0 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -8.8 \cdot 10^{+85}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\mathbf{elif}\;x \leq 7 \cdot 10^{-37}:\\
\;\;\;\;t_1 + b \cdot c\\
\mathbf{elif}\;x \leq 112000000:\\
\;\;\;\;t_1 + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 5.3 \cdot 10^{+143} \lor \neg \left(x \leq 1.05 \cdot 10^{+241}\right):\\
\;\;\;\;t_1 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t_1 + x \cdot \left(\left(t \cdot y\right) \cdot \left(18 \cdot z\right)\right)\\
\end{array}
\end{array}
if x < -8.8000000000000007e85Initial program 69.6%
Simplified84.7%
Taylor expanded in x around inf 77.5%
expm1-log1p-u61.5%
expm1-udef59.8%
Applied egg-rr59.8%
expm1-def61.5%
expm1-log1p77.5%
associate-*r*75.8%
Simplified75.8%
if -8.8000000000000007e85 < x < 7.0000000000000003e-37Initial program 92.0%
Simplified91.9%
Taylor expanded in b around inf 63.9%
if 7.0000000000000003e-37 < x < 1.12e8Initial program 85.5%
Simplified93.3%
Taylor expanded in a around inf 71.6%
*-commutative71.6%
Simplified71.6%
if 1.12e8 < x < 5.3e143 or 1.05e241 < x Initial program 87.5%
Simplified95.0%
Taylor expanded in i around inf 66.4%
associate-*r*66.4%
*-commutative66.4%
Simplified66.4%
if 5.3e143 < x < 1.05e241Initial program 72.1%
Simplified80.1%
Taylor expanded in y around inf 74.7%
*-commutative74.7%
*-commutative74.7%
associate-*l*78.3%
*-commutative78.3%
associate-*r*78.3%
associate-*r*77.4%
associate-*l*77.4%
Simplified77.4%
Final simplification68.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (- (+ (* b c) (* -4.0 (* t a))) (* 4.0 (* x i))))
(t_2 (* j (* k -27.0))))
(if (<= x -5.2e+85)
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))
(if (<= x 1e-217)
(+ t_2 (* b c))
(if (<= x 1.3e+59)
t_1
(if (<= x 1.7e+112)
(+ t_2 (* x (* -4.0 i)))
(if (<= x 1.2e+162)
t_1
(* x (- (* 18.0 (* t (* y z))) (* i 4.0))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i));
double t_2 = j * (k * -27.0);
double tmp;
if (x <= -5.2e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 1e-217) {
tmp = t_2 + (b * c);
} else if (x <= 1.3e+59) {
tmp = t_1;
} else if (x <= 1.7e+112) {
tmp = t_2 + (x * (-4.0 * i));
} else if (x <= 1.2e+162) {
tmp = t_1;
} else {
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = ((b * c) + ((-4.0d0) * (t * a))) - (4.0d0 * (x * i))
t_2 = j * (k * (-27.0d0))
if (x <= (-5.2d+85)) then
tmp = x * ((18.0d0 * (z * (t * y))) - (i * 4.0d0))
else if (x <= 1d-217) then
tmp = t_2 + (b * c)
else if (x <= 1.3d+59) then
tmp = t_1
else if (x <= 1.7d+112) then
tmp = t_2 + (x * ((-4.0d0) * i))
else if (x <= 1.2d+162) then
tmp = t_1
else
tmp = x * ((18.0d0 * (t * (y * z))) - (i * 4.0d0))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i));
double t_2 = j * (k * -27.0);
double tmp;
if (x <= -5.2e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 1e-217) {
tmp = t_2 + (b * c);
} else if (x <= 1.3e+59) {
tmp = t_1;
} else if (x <= 1.7e+112) {
tmp = t_2 + (x * (-4.0 * i));
} else if (x <= 1.2e+162) {
tmp = t_1;
} else {
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i)) t_2 = j * (k * -27.0) tmp = 0 if x <= -5.2e+85: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) elif x <= 1e-217: tmp = t_2 + (b * c) elif x <= 1.3e+59: tmp = t_1 elif x <= 1.7e+112: tmp = t_2 + (x * (-4.0 * i)) elif x <= 1.2e+162: tmp = t_1 else: tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) - Float64(4.0 * Float64(x * i))) t_2 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -5.2e+85) tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); elseif (x <= 1e-217) tmp = Float64(t_2 + Float64(b * c)); elseif (x <= 1.3e+59) tmp = t_1; elseif (x <= 1.7e+112) tmp = Float64(t_2 + Float64(x * Float64(-4.0 * i))); elseif (x <= 1.2e+162) tmp = t_1; else tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(i * 4.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = ((b * c) + (-4.0 * (t * a))) - (4.0 * (x * i));
t_2 = j * (k * -27.0);
tmp = 0.0;
if (x <= -5.2e+85)
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
elseif (x <= 1e-217)
tmp = t_2 + (b * c);
elseif (x <= 1.3e+59)
tmp = t_1;
elseif (x <= 1.7e+112)
tmp = t_2 + (x * (-4.0 * i));
elseif (x <= 1.2e+162)
tmp = t_1;
else
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.2e+85], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1e-217], N[(t$95$2 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.3e+59], t$95$1, If[LessEqual[x, 1.7e+112], N[(t$95$2 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.2e+162], t$95$1, N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(b \cdot c + -4 \cdot \left(t \cdot a\right)\right) - 4 \cdot \left(x \cdot i\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -5.2 \cdot 10^{+85}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\mathbf{elif}\;x \leq 10^{-217}:\\
\;\;\;\;t_2 + b \cdot c\\
\mathbf{elif}\;x \leq 1.3 \cdot 10^{+59}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 1.7 \cdot 10^{+112}:\\
\;\;\;\;t_2 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;x \leq 1.2 \cdot 10^{+162}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - i \cdot 4\right)\\
\end{array}
\end{array}
if x < -5.20000000000000021e85Initial program 69.6%
Simplified84.7%
Taylor expanded in x around inf 77.5%
expm1-log1p-u61.5%
expm1-udef59.8%
Applied egg-rr59.8%
expm1-def61.5%
expm1-log1p77.5%
associate-*r*75.8%
Simplified75.8%
if -5.20000000000000021e85 < x < 1.00000000000000008e-217Initial program 92.0%
Simplified91.9%
Taylor expanded in b around inf 68.5%
if 1.00000000000000008e-217 < x < 1.3e59 or 1.69999999999999997e112 < x < 1.20000000000000005e162Initial program 89.2%
Simplified90.6%
associate--l+90.6%
*-commutative90.6%
fma-def93.4%
associate-*l*92.0%
fma-neg92.0%
associate-*r*92.0%
associate-*r*92.0%
+-commutative92.0%
fma-def92.0%
*-commutative92.0%
*-commutative92.0%
Applied egg-rr92.0%
Taylor expanded in x around 0 84.2%
Taylor expanded in j around 0 64.9%
if 1.3e59 < x < 1.69999999999999997e112Initial program 88.2%
Simplified94.0%
Taylor expanded in i around inf 76.8%
associate-*r*76.8%
*-commutative76.8%
Simplified76.8%
if 1.20000000000000005e162 < x Initial program 73.0%
Simplified80.7%
Taylor expanded in x around inf 77.1%
Final simplification70.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (or (<= t -1.38e+73)
(not
(or (<= t 3.4e-93) (and (not (<= t 1.4e-42)) (<= t 51000000.0)))))
(+ (* j (* k -27.0)) (* t (+ (* 18.0 (* x (* y z))) (* a -4.0))))
(- (- (* b c) (* 4.0 (* x i))) (* k (* j 27.0)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -1.38e+73) || !((t <= 3.4e-93) || (!(t <= 1.4e-42) && (t <= 51000000.0)))) {
tmp = (j * (k * -27.0)) + (t * ((18.0 * (x * (y * z))) + (a * -4.0)));
} else {
tmp = ((b * c) - (4.0 * (x * i))) - (k * (j * 27.0));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((t <= (-1.38d+73)) .or. (.not. (t <= 3.4d-93) .or. (.not. (t <= 1.4d-42)) .and. (t <= 51000000.0d0))) then
tmp = (j * (k * (-27.0d0))) + (t * ((18.0d0 * (x * (y * z))) + (a * (-4.0d0))))
else
tmp = ((b * c) - (4.0d0 * (x * i))) - (k * (j * 27.0d0))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((t <= -1.38e+73) || !((t <= 3.4e-93) || (!(t <= 1.4e-42) && (t <= 51000000.0)))) {
tmp = (j * (k * -27.0)) + (t * ((18.0 * (x * (y * z))) + (a * -4.0)));
} else {
tmp = ((b * c) - (4.0 * (x * i))) - (k * (j * 27.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (t <= -1.38e+73) or not ((t <= 3.4e-93) or (not (t <= 1.4e-42) and (t <= 51000000.0))): tmp = (j * (k * -27.0)) + (t * ((18.0 * (x * (y * z))) + (a * -4.0))) else: tmp = ((b * c) - (4.0 * (x * i))) - (k * (j * 27.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((t <= -1.38e+73) || !((t <= 3.4e-93) || (!(t <= 1.4e-42) && (t <= 51000000.0)))) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) + Float64(a * -4.0)))); else tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - Float64(k * Float64(j * 27.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((t <= -1.38e+73) || ~(((t <= 3.4e-93) || (~((t <= 1.4e-42)) && (t <= 51000000.0)))))
tmp = (j * (k * -27.0)) + (t * ((18.0 * (x * (y * z))) + (a * -4.0)));
else
tmp = ((b * c) - (4.0 * (x * i))) - (k * (j * 27.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -1.38e+73], N[Not[Or[LessEqual[t, 3.4e-93], And[N[Not[LessEqual[t, 1.4e-42]], $MachinePrecision], LessEqual[t, 51000000.0]]]], $MachinePrecision]], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.38 \cdot 10^{+73} \lor \neg \left(t \leq 3.4 \cdot 10^{-93} \lor \neg \left(t \leq 1.4 \cdot 10^{-42}\right) \land t \leq 51000000\right):\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - k \cdot \left(j \cdot 27\right)\\
\end{array}
\end{array}
if t < -1.38000000000000007e73 or 3.40000000000000001e-93 < t < 1.39999999999999999e-42 or 5.1e7 < t Initial program 79.7%
Simplified92.3%
Taylor expanded in t around inf 79.7%
if -1.38000000000000007e73 < t < 3.40000000000000001e-93 or 1.39999999999999999e-42 < t < 5.1e7Initial program 88.5%
Taylor expanded in t around 0 84.3%
Final simplification82.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (* y z)))
(t_2 (* k (* j 27.0)))
(t_3 (- (- (* b c) (* 4.0 (* x i))) t_2))
(t_4 (+ (* j (* k -27.0)) (* t (+ (* 18.0 t_1) (* a -4.0))))))
(if (<= t -1.35e+73)
t_4
(if (<= t 5.8e-97)
t_3
(if (<= t 1.25e-43)
(- (- (* 18.0 (* t t_1)) (* 4.0 (* t a))) t_2)
(if (<= t 57000000.0) t_3 t_4))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (y * z);
double t_2 = k * (j * 27.0);
double t_3 = ((b * c) - (4.0 * (x * i))) - t_2;
double t_4 = (j * (k * -27.0)) + (t * ((18.0 * t_1) + (a * -4.0)));
double tmp;
if (t <= -1.35e+73) {
tmp = t_4;
} else if (t <= 5.8e-97) {
tmp = t_3;
} else if (t <= 1.25e-43) {
tmp = ((18.0 * (t * t_1)) - (4.0 * (t * a))) - t_2;
} else if (t <= 57000000.0) {
tmp = t_3;
} else {
tmp = t_4;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: tmp
t_1 = x * (y * z)
t_2 = k * (j * 27.0d0)
t_3 = ((b * c) - (4.0d0 * (x * i))) - t_2
t_4 = (j * (k * (-27.0d0))) + (t * ((18.0d0 * t_1) + (a * (-4.0d0))))
if (t <= (-1.35d+73)) then
tmp = t_4
else if (t <= 5.8d-97) then
tmp = t_3
else if (t <= 1.25d-43) then
tmp = ((18.0d0 * (t * t_1)) - (4.0d0 * (t * a))) - t_2
else if (t <= 57000000.0d0) then
tmp = t_3
else
tmp = t_4
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (y * z);
double t_2 = k * (j * 27.0);
double t_3 = ((b * c) - (4.0 * (x * i))) - t_2;
double t_4 = (j * (k * -27.0)) + (t * ((18.0 * t_1) + (a * -4.0)));
double tmp;
if (t <= -1.35e+73) {
tmp = t_4;
} else if (t <= 5.8e-97) {
tmp = t_3;
} else if (t <= 1.25e-43) {
tmp = ((18.0 * (t * t_1)) - (4.0 * (t * a))) - t_2;
} else if (t <= 57000000.0) {
tmp = t_3;
} else {
tmp = t_4;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = x * (y * z) t_2 = k * (j * 27.0) t_3 = ((b * c) - (4.0 * (x * i))) - t_2 t_4 = (j * (k * -27.0)) + (t * ((18.0 * t_1) + (a * -4.0))) tmp = 0 if t <= -1.35e+73: tmp = t_4 elif t <= 5.8e-97: tmp = t_3 elif t <= 1.25e-43: tmp = ((18.0 * (t * t_1)) - (4.0 * (t * a))) - t_2 elif t <= 57000000.0: tmp = t_3 else: tmp = t_4 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * Float64(y * z)) t_2 = Float64(k * Float64(j * 27.0)) t_3 = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - t_2) t_4 = Float64(Float64(j * Float64(k * -27.0)) + Float64(t * Float64(Float64(18.0 * t_1) + Float64(a * -4.0)))) tmp = 0.0 if (t <= -1.35e+73) tmp = t_4; elseif (t <= 5.8e-97) tmp = t_3; elseif (t <= 1.25e-43) tmp = Float64(Float64(Float64(18.0 * Float64(t * t_1)) - Float64(4.0 * Float64(t * a))) - t_2); elseif (t <= 57000000.0) tmp = t_3; else tmp = t_4; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = x * (y * z);
t_2 = k * (j * 27.0);
t_3 = ((b * c) - (4.0 * (x * i))) - t_2;
t_4 = (j * (k * -27.0)) + (t * ((18.0 * t_1) + (a * -4.0)));
tmp = 0.0;
if (t <= -1.35e+73)
tmp = t_4;
elseif (t <= 5.8e-97)
tmp = t_3;
elseif (t <= 1.25e-43)
tmp = ((18.0 * (t * t_1)) - (4.0 * (t * a))) - t_2;
elseif (t <= 57000000.0)
tmp = t_3;
else
tmp = t_4;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision]}, Block[{t$95$4 = N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(t * N[(N[(18.0 * t$95$1), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.35e+73], t$95$4, If[LessEqual[t, 5.8e-97], t$95$3, If[LessEqual[t, 1.25e-43], N[(N[(N[(18.0 * N[(t * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[t, 57000000.0], t$95$3, t$95$4]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \left(y \cdot z\right)\\
t_2 := k \cdot \left(j \cdot 27\right)\\
t_3 := \left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - t_2\\
t_4 := j \cdot \left(k \cdot -27\right) + t \cdot \left(18 \cdot t_1 + a \cdot -4\right)\\
\mathbf{if}\;t \leq -1.35 \cdot 10^{+73}:\\
\;\;\;\;t_4\\
\mathbf{elif}\;t \leq 5.8 \cdot 10^{-97}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;t \leq 1.25 \cdot 10^{-43}:\\
\;\;\;\;\left(18 \cdot \left(t \cdot t_1\right) - 4 \cdot \left(t \cdot a\right)\right) - t_2\\
\mathbf{elif}\;t \leq 57000000:\\
\;\;\;\;t_3\\
\mathbf{else}:\\
\;\;\;\;t_4\\
\end{array}
\end{array}
if t < -1.35e73 or 5.7e7 < t Initial program 79.5%
Simplified93.9%
Taylor expanded in t around inf 79.5%
if -1.35e73 < t < 5.7999999999999999e-97 or 1.25000000000000005e-43 < t < 5.7e7Initial program 88.5%
Taylor expanded in t around 0 84.2%
if 5.7999999999999999e-97 < t < 1.25000000000000005e-43Initial program 82.2%
Taylor expanded in i around 0 82.3%
Taylor expanded in b around 0 82.3%
Final simplification82.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (- (* 18.0 (* t (* y z))) (* i 4.0))))
(t_2 (* j (* k -27.0))))
(if (<= x -8.5e+85)
t_1
(if (<= x 1.28e-36)
(+ t_2 (* b c))
(if (<= x 96000000.0)
(+ t_2 (* -4.0 (* t a)))
(if (<= x 1.9e+131)
(+ t_2 (* x (* -4.0 i)))
(if (<= x 2.15e+131) (* t (* a -4.0)) t_1)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * ((18.0 * (t * (y * z))) - (i * 4.0));
double t_2 = j * (k * -27.0);
double tmp;
if (x <= -8.5e+85) {
tmp = t_1;
} else if (x <= 1.28e-36) {
tmp = t_2 + (b * c);
} else if (x <= 96000000.0) {
tmp = t_2 + (-4.0 * (t * a));
} else if (x <= 1.9e+131) {
tmp = t_2 + (x * (-4.0 * i));
} else if (x <= 2.15e+131) {
tmp = t * (a * -4.0);
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x * ((18.0d0 * (t * (y * z))) - (i * 4.0d0))
t_2 = j * (k * (-27.0d0))
if (x <= (-8.5d+85)) then
tmp = t_1
else if (x <= 1.28d-36) then
tmp = t_2 + (b * c)
else if (x <= 96000000.0d0) then
tmp = t_2 + ((-4.0d0) * (t * a))
else if (x <= 1.9d+131) then
tmp = t_2 + (x * ((-4.0d0) * i))
else if (x <= 2.15d+131) then
tmp = t * (a * (-4.0d0))
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * ((18.0 * (t * (y * z))) - (i * 4.0));
double t_2 = j * (k * -27.0);
double tmp;
if (x <= -8.5e+85) {
tmp = t_1;
} else if (x <= 1.28e-36) {
tmp = t_2 + (b * c);
} else if (x <= 96000000.0) {
tmp = t_2 + (-4.0 * (t * a));
} else if (x <= 1.9e+131) {
tmp = t_2 + (x * (-4.0 * i));
} else if (x <= 2.15e+131) {
tmp = t * (a * -4.0);
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = x * ((18.0 * (t * (y * z))) - (i * 4.0)) t_2 = j * (k * -27.0) tmp = 0 if x <= -8.5e+85: tmp = t_1 elif x <= 1.28e-36: tmp = t_2 + (b * c) elif x <= 96000000.0: tmp = t_2 + (-4.0 * (t * a)) elif x <= 1.9e+131: tmp = t_2 + (x * (-4.0 * i)) elif x <= 2.15e+131: tmp = t * (a * -4.0) else: tmp = t_1 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(i * 4.0))) t_2 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -8.5e+85) tmp = t_1; elseif (x <= 1.28e-36) tmp = Float64(t_2 + Float64(b * c)); elseif (x <= 96000000.0) tmp = Float64(t_2 + Float64(-4.0 * Float64(t * a))); elseif (x <= 1.9e+131) tmp = Float64(t_2 + Float64(x * Float64(-4.0 * i))); elseif (x <= 2.15e+131) tmp = Float64(t * Float64(a * -4.0)); else tmp = t_1; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = x * ((18.0 * (t * (y * z))) - (i * 4.0));
t_2 = j * (k * -27.0);
tmp = 0.0;
if (x <= -8.5e+85)
tmp = t_1;
elseif (x <= 1.28e-36)
tmp = t_2 + (b * c);
elseif (x <= 96000000.0)
tmp = t_2 + (-4.0 * (t * a));
elseif (x <= 1.9e+131)
tmp = t_2 + (x * (-4.0 * i));
elseif (x <= 2.15e+131)
tmp = t * (a * -4.0);
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -8.5e+85], t$95$1, If[LessEqual[x, 1.28e-36], N[(t$95$2 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 96000000.0], N[(t$95$2 + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.9e+131], N[(t$95$2 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.15e+131], N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - i \cdot 4\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -8.5 \cdot 10^{+85}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 1.28 \cdot 10^{-36}:\\
\;\;\;\;t_2 + b \cdot c\\
\mathbf{elif}\;x \leq 96000000:\\
\;\;\;\;t_2 + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 1.9 \cdot 10^{+131}:\\
\;\;\;\;t_2 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;x \leq 2.15 \cdot 10^{+131}:\\
\;\;\;\;t \cdot \left(a \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if x < -8.4999999999999994e85 or 2.1500000000000001e131 < x Initial program 71.2%
Simplified82.7%
Taylor expanded in x around inf 74.9%
if -8.4999999999999994e85 < x < 1.28e-36Initial program 92.0%
Simplified91.9%
Taylor expanded in b around inf 63.9%
if 1.28e-36 < x < 9.6e7Initial program 85.5%
Simplified93.3%
Taylor expanded in a around inf 71.6%
*-commutative71.6%
Simplified71.6%
if 9.6e7 < x < 1.9000000000000002e131Initial program 89.9%
Simplified96.6%
Taylor expanded in i around inf 64.9%
associate-*r*64.9%
*-commutative64.9%
Simplified64.9%
if 1.9000000000000002e131 < x < 2.1500000000000001e131Initial program 100.0%
Simplified100.0%
associate--l+100.0%
*-commutative100.0%
fma-def100.0%
associate-*l*100.0%
fma-neg100.0%
associate-*r*100.0%
associate-*r*100.0%
+-commutative100.0%
fma-def100.0%
*-commutative100.0%
*-commutative100.0%
Applied egg-rr100.0%
Taylor expanded in a around inf 100.0%
*-commutative100.0%
*-commutative100.0%
associate-*l*100.0%
*-commutative100.0%
Simplified100.0%
Final simplification68.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* j (* k -27.0))))
(if (<= x -6e+85)
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))
(if (<= x 3.9e-36)
(+ t_1 (* b c))
(if (<= x 62000000.0)
(+ t_1 (* -4.0 (* t a)))
(if (<= x 2.1e+131)
(+ t_1 (* x (* -4.0 i)))
(if (<= x 2.15e+131)
(* t (* a -4.0))
(* x (- (* 18.0 (* t (* y z))) (* i 4.0))))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -6e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 3.9e-36) {
tmp = t_1 + (b * c);
} else if (x <= 62000000.0) {
tmp = t_1 + (-4.0 * (t * a));
} else if (x <= 2.1e+131) {
tmp = t_1 + (x * (-4.0 * i));
} else if (x <= 2.15e+131) {
tmp = t * (a * -4.0);
} else {
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = j * (k * (-27.0d0))
if (x <= (-6d+85)) then
tmp = x * ((18.0d0 * (z * (t * y))) - (i * 4.0d0))
else if (x <= 3.9d-36) then
tmp = t_1 + (b * c)
else if (x <= 62000000.0d0) then
tmp = t_1 + ((-4.0d0) * (t * a))
else if (x <= 2.1d+131) then
tmp = t_1 + (x * ((-4.0d0) * i))
else if (x <= 2.15d+131) then
tmp = t * (a * (-4.0d0))
else
tmp = x * ((18.0d0 * (t * (y * z))) - (i * 4.0d0))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = j * (k * -27.0);
double tmp;
if (x <= -6e+85) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 3.9e-36) {
tmp = t_1 + (b * c);
} else if (x <= 62000000.0) {
tmp = t_1 + (-4.0 * (t * a));
} else if (x <= 2.1e+131) {
tmp = t_1 + (x * (-4.0 * i));
} else if (x <= 2.15e+131) {
tmp = t * (a * -4.0);
} else {
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = j * (k * -27.0) tmp = 0 if x <= -6e+85: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) elif x <= 3.9e-36: tmp = t_1 + (b * c) elif x <= 62000000.0: tmp = t_1 + (-4.0 * (t * a)) elif x <= 2.1e+131: tmp = t_1 + (x * (-4.0 * i)) elif x <= 2.15e+131: tmp = t * (a * -4.0) else: tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(j * Float64(k * -27.0)) tmp = 0.0 if (x <= -6e+85) tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); elseif (x <= 3.9e-36) tmp = Float64(t_1 + Float64(b * c)); elseif (x <= 62000000.0) tmp = Float64(t_1 + Float64(-4.0 * Float64(t * a))); elseif (x <= 2.1e+131) tmp = Float64(t_1 + Float64(x * Float64(-4.0 * i))); elseif (x <= 2.15e+131) tmp = Float64(t * Float64(a * -4.0)); else tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(i * 4.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = j * (k * -27.0);
tmp = 0.0;
if (x <= -6e+85)
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
elseif (x <= 3.9e-36)
tmp = t_1 + (b * c);
elseif (x <= 62000000.0)
tmp = t_1 + (-4.0 * (t * a));
elseif (x <= 2.1e+131)
tmp = t_1 + (x * (-4.0 * i));
elseif (x <= 2.15e+131)
tmp = t * (a * -4.0);
else
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6e+85], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.9e-36], N[(t$95$1 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 62000000.0], N[(t$95$1 + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+131], N[(t$95$1 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.15e+131], N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
\mathbf{if}\;x \leq -6 \cdot 10^{+85}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\mathbf{elif}\;x \leq 3.9 \cdot 10^{-36}:\\
\;\;\;\;t_1 + b \cdot c\\
\mathbf{elif}\;x \leq 62000000:\\
\;\;\;\;t_1 + -4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+131}:\\
\;\;\;\;t_1 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;x \leq 2.15 \cdot 10^{+131}:\\
\;\;\;\;t \cdot \left(a \cdot -4\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - i \cdot 4\right)\\
\end{array}
\end{array}
if x < -6.0000000000000001e85Initial program 69.6%
Simplified84.7%
Taylor expanded in x around inf 77.5%
expm1-log1p-u61.5%
expm1-udef59.8%
Applied egg-rr59.8%
expm1-def61.5%
expm1-log1p77.5%
associate-*r*75.8%
Simplified75.8%
if -6.0000000000000001e85 < x < 3.9000000000000001e-36Initial program 92.0%
Simplified91.9%
Taylor expanded in b around inf 63.9%
if 3.9000000000000001e-36 < x < 6.2e7Initial program 85.5%
Simplified93.3%
Taylor expanded in a around inf 71.6%
*-commutative71.6%
Simplified71.6%
if 6.2e7 < x < 2.09999999999999985e131Initial program 89.9%
Simplified96.6%
Taylor expanded in i around inf 64.9%
associate-*r*64.9%
*-commutative64.9%
Simplified64.9%
if 2.09999999999999985e131 < x < 2.1500000000000001e131Initial program 100.0%
Simplified100.0%
associate--l+100.0%
*-commutative100.0%
fma-def100.0%
associate-*l*100.0%
fma-neg100.0%
associate-*r*100.0%
associate-*r*100.0%
+-commutative100.0%
fma-def100.0%
*-commutative100.0%
*-commutative100.0%
Applied egg-rr100.0%
Taylor expanded in a around inf 100.0%
*-commutative100.0%
*-commutative100.0%
associate-*l*100.0%
*-commutative100.0%
Simplified100.0%
if 2.1500000000000001e131 < x Initial program 73.6%
Simplified79.6%
Taylor expanded in x around inf 70.9%
Final simplification67.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* k (* j 27.0))) (t_2 (* 4.0 (* t a))))
(if (or (<= i -8.5e-140) (not (<= i 5.5e-16)))
(- (- (* b c) (+ t_2 (* 4.0 (* x i)))) t_1)
(- (- (+ (* b c) (* 18.0 (* t (* x (* y z))))) t_2) t_1))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = k * (j * 27.0);
double t_2 = 4.0 * (t * a);
double tmp;
if ((i <= -8.5e-140) || !(i <= 5.5e-16)) {
tmp = ((b * c) - (t_2 + (4.0 * (x * i)))) - t_1;
} else {
tmp = (((b * c) + (18.0 * (t * (x * (y * z))))) - t_2) - t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = k * (j * 27.0d0)
t_2 = 4.0d0 * (t * a)
if ((i <= (-8.5d-140)) .or. (.not. (i <= 5.5d-16))) then
tmp = ((b * c) - (t_2 + (4.0d0 * (x * i)))) - t_1
else
tmp = (((b * c) + (18.0d0 * (t * (x * (y * z))))) - t_2) - t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = k * (j * 27.0);
double t_2 = 4.0 * (t * a);
double tmp;
if ((i <= -8.5e-140) || !(i <= 5.5e-16)) {
tmp = ((b * c) - (t_2 + (4.0 * (x * i)))) - t_1;
} else {
tmp = (((b * c) + (18.0 * (t * (x * (y * z))))) - t_2) - t_1;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = k * (j * 27.0) t_2 = 4.0 * (t * a) tmp = 0 if (i <= -8.5e-140) or not (i <= 5.5e-16): tmp = ((b * c) - (t_2 + (4.0 * (x * i)))) - t_1 else: tmp = (((b * c) + (18.0 * (t * (x * (y * z))))) - t_2) - t_1 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(k * Float64(j * 27.0)) t_2 = Float64(4.0 * Float64(t * a)) tmp = 0.0 if ((i <= -8.5e-140) || !(i <= 5.5e-16)) tmp = Float64(Float64(Float64(b * c) - Float64(t_2 + Float64(4.0 * Float64(x * i)))) - t_1); else tmp = Float64(Float64(Float64(Float64(b * c) + Float64(18.0 * Float64(t * Float64(x * Float64(y * z))))) - t_2) - t_1); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = k * (j * 27.0);
t_2 = 4.0 * (t * a);
tmp = 0.0;
if ((i <= -8.5e-140) || ~((i <= 5.5e-16)))
tmp = ((b * c) - (t_2 + (4.0 * (x * i)))) - t_1;
else
tmp = (((b * c) + (18.0 * (t * (x * (y * z))))) - t_2) - t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[i, -8.5e-140], N[Not[LessEqual[i, 5.5e-16]], $MachinePrecision]], N[(N[(N[(b * c), $MachinePrecision] - N[(t$95$2 + N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], N[(N[(N[(N[(b * c), $MachinePrecision] + N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision] - t$95$1), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := k \cdot \left(j \cdot 27\right)\\
t_2 := 4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;i \leq -8.5 \cdot 10^{-140} \lor \neg \left(i \leq 5.5 \cdot 10^{-16}\right):\\
\;\;\;\;\left(b \cdot c - \left(t_2 + 4 \cdot \left(x \cdot i\right)\right)\right) - t_1\\
\mathbf{else}:\\
\;\;\;\;\left(\left(b \cdot c + 18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\right) - t_2\right) - t_1\\
\end{array}
\end{array}
if i < -8.49999999999999997e-140 or 5.49999999999999964e-16 < i Initial program 82.6%
Taylor expanded in y around 0 86.8%
if -8.49999999999999997e-140 < i < 5.49999999999999964e-16Initial program 87.9%
Taylor expanded in i around 0 88.1%
Final simplification87.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))
(t_2 (* j (* k -27.0)))
(t_3 (+ t_2 (* b c))))
(if (<= t -5.5e+86)
t_1
(if (<= t 6.8e-189)
t_3
(if (<= t 3.6e-121)
(+ t_2 (* x (* -4.0 i)))
(if (<= t 520000000.0) t_3 t_1))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = t * ((18.0 * (x * (y * z))) - (a * 4.0));
double t_2 = j * (k * -27.0);
double t_3 = t_2 + (b * c);
double tmp;
if (t <= -5.5e+86) {
tmp = t_1;
} else if (t <= 6.8e-189) {
tmp = t_3;
} else if (t <= 3.6e-121) {
tmp = t_2 + (x * (-4.0 * i));
} else if (t <= 520000000.0) {
tmp = t_3;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))
t_2 = j * (k * (-27.0d0))
t_3 = t_2 + (b * c)
if (t <= (-5.5d+86)) then
tmp = t_1
else if (t <= 6.8d-189) then
tmp = t_3
else if (t <= 3.6d-121) then
tmp = t_2 + (x * ((-4.0d0) * i))
else if (t <= 520000000.0d0) then
tmp = t_3
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = t * ((18.0 * (x * (y * z))) - (a * 4.0));
double t_2 = j * (k * -27.0);
double t_3 = t_2 + (b * c);
double tmp;
if (t <= -5.5e+86) {
tmp = t_1;
} else if (t <= 6.8e-189) {
tmp = t_3;
} else if (t <= 3.6e-121) {
tmp = t_2 + (x * (-4.0 * i));
} else if (t <= 520000000.0) {
tmp = t_3;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = t * ((18.0 * (x * (y * z))) - (a * 4.0)) t_2 = j * (k * -27.0) t_3 = t_2 + (b * c) tmp = 0 if t <= -5.5e+86: tmp = t_1 elif t <= 6.8e-189: tmp = t_3 elif t <= 3.6e-121: tmp = t_2 + (x * (-4.0 * i)) elif t <= 520000000.0: tmp = t_3 else: tmp = t_1 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))) t_2 = Float64(j * Float64(k * -27.0)) t_3 = Float64(t_2 + Float64(b * c)) tmp = 0.0 if (t <= -5.5e+86) tmp = t_1; elseif (t <= 6.8e-189) tmp = t_3; elseif (t <= 3.6e-121) tmp = Float64(t_2 + Float64(x * Float64(-4.0 * i))); elseif (t <= 520000000.0) tmp = t_3; else tmp = t_1; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = t * ((18.0 * (x * (y * z))) - (a * 4.0));
t_2 = j * (k * -27.0);
t_3 = t_2 + (b * c);
tmp = 0.0;
if (t <= -5.5e+86)
tmp = t_1;
elseif (t <= 6.8e-189)
tmp = t_3;
elseif (t <= 3.6e-121)
tmp = t_2 + (x * (-4.0 * i));
elseif (t <= 520000000.0)
tmp = t_3;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 + N[(b * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -5.5e+86], t$95$1, If[LessEqual[t, 6.8e-189], t$95$3, If[LessEqual[t, 3.6e-121], N[(t$95$2 + N[(x * N[(-4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 520000000.0], t$95$3, t$95$1]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
t_3 := t_2 + b \cdot c\\
\mathbf{if}\;t \leq -5.5 \cdot 10^{+86}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 6.8 \cdot 10^{-189}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;t \leq 3.6 \cdot 10^{-121}:\\
\;\;\;\;t_2 + x \cdot \left(-4 \cdot i\right)\\
\mathbf{elif}\;t \leq 520000000:\\
\;\;\;\;t_3\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -5.5000000000000002e86 or 5.2e8 < t Initial program 78.9%
Simplified90.7%
associate--l+90.7%
*-commutative90.7%
fma-def94.8%
associate-*l*93.8%
fma-neg93.8%
associate-*r*93.8%
associate-*r*93.8%
+-commutative93.8%
fma-def93.8%
*-commutative93.8%
*-commutative93.8%
Applied egg-rr93.8%
Taylor expanded in t around inf 65.0%
if -5.5000000000000002e86 < t < 6.8000000000000002e-189 or 3.59999999999999984e-121 < t < 5.2e8Initial program 87.6%
Simplified87.6%
Taylor expanded in b around inf 61.5%
if 6.8000000000000002e-189 < t < 3.59999999999999984e-121Initial program 92.9%
Simplified92.9%
Taylor expanded in i around inf 78.3%
associate-*r*78.3%
*-commutative78.3%
Simplified78.3%
Final simplification63.7%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (* y z))) (t_2 (* 4.0 (* x i))) (t_3 (* k (* j 27.0))))
(if (<= k -3.9e-118)
(- (+ (* b c) (* 18.0 (* t t_1))) t_3)
(if (<= k 7.4e+74)
(- (+ (* b c) (* t (- (* 18.0 t_1) (* a 4.0)))) t_2)
(- (- (* b c) (+ (* 4.0 (* t a)) t_2)) t_3)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (y * z);
double t_2 = 4.0 * (x * i);
double t_3 = k * (j * 27.0);
double tmp;
if (k <= -3.9e-118) {
tmp = ((b * c) + (18.0 * (t * t_1))) - t_3;
} else if (k <= 7.4e+74) {
tmp = ((b * c) + (t * ((18.0 * t_1) - (a * 4.0)))) - t_2;
} else {
tmp = ((b * c) - ((4.0 * (t * a)) + t_2)) - t_3;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = x * (y * z)
t_2 = 4.0d0 * (x * i)
t_3 = k * (j * 27.0d0)
if (k <= (-3.9d-118)) then
tmp = ((b * c) + (18.0d0 * (t * t_1))) - t_3
else if (k <= 7.4d+74) then
tmp = ((b * c) + (t * ((18.0d0 * t_1) - (a * 4.0d0)))) - t_2
else
tmp = ((b * c) - ((4.0d0 * (t * a)) + t_2)) - t_3
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * (y * z);
double t_2 = 4.0 * (x * i);
double t_3 = k * (j * 27.0);
double tmp;
if (k <= -3.9e-118) {
tmp = ((b * c) + (18.0 * (t * t_1))) - t_3;
} else if (k <= 7.4e+74) {
tmp = ((b * c) + (t * ((18.0 * t_1) - (a * 4.0)))) - t_2;
} else {
tmp = ((b * c) - ((4.0 * (t * a)) + t_2)) - t_3;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = x * (y * z) t_2 = 4.0 * (x * i) t_3 = k * (j * 27.0) tmp = 0 if k <= -3.9e-118: tmp = ((b * c) + (18.0 * (t * t_1))) - t_3 elif k <= 7.4e+74: tmp = ((b * c) + (t * ((18.0 * t_1) - (a * 4.0)))) - t_2 else: tmp = ((b * c) - ((4.0 * (t * a)) + t_2)) - t_3 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * Float64(y * z)) t_2 = Float64(4.0 * Float64(x * i)) t_3 = Float64(k * Float64(j * 27.0)) tmp = 0.0 if (k <= -3.9e-118) tmp = Float64(Float64(Float64(b * c) + Float64(18.0 * Float64(t * t_1))) - t_3); elseif (k <= 7.4e+74) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * t_1) - Float64(a * 4.0)))) - t_2); else tmp = Float64(Float64(Float64(b * c) - Float64(Float64(4.0 * Float64(t * a)) + t_2)) - t_3); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = x * (y * z);
t_2 = 4.0 * (x * i);
t_3 = k * (j * 27.0);
tmp = 0.0;
if (k <= -3.9e-118)
tmp = ((b * c) + (18.0 * (t * t_1))) - t_3;
elseif (k <= 7.4e+74)
tmp = ((b * c) + (t * ((18.0 * t_1) - (a * 4.0)))) - t_2;
else
tmp = ((b * c) - ((4.0 * (t * a)) + t_2)) - t_3;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -3.9e-118], N[(N[(N[(b * c), $MachinePrecision] + N[(18.0 * N[(t * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision], If[LessEqual[k, 7.4e+74], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * t$95$1), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \left(y \cdot z\right)\\
t_2 := 4 \cdot \left(x \cdot i\right)\\
t_3 := k \cdot \left(j \cdot 27\right)\\
\mathbf{if}\;k \leq -3.9 \cdot 10^{-118}:\\
\;\;\;\;\left(b \cdot c + 18 \cdot \left(t \cdot t_1\right)\right) - t_3\\
\mathbf{elif}\;k \leq 7.4 \cdot 10^{+74}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot t_1 - a \cdot 4\right)\right) - t_2\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - \left(4 \cdot \left(t \cdot a\right) + t_2\right)\right) - t_3\\
\end{array}
\end{array}
if k < -3.90000000000000001e-118Initial program 82.2%
Taylor expanded in i around 0 78.5%
Taylor expanded in a around 0 77.3%
if -3.90000000000000001e-118 < k < 7.4000000000000002e74Initial program 82.9%
Simplified88.2%
Taylor expanded in j around 0 81.7%
if 7.4000000000000002e74 < k Initial program 92.2%
Taylor expanded in y around 0 92.1%
Final simplification82.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= x -3.3e+86)
(* x (- (* 18.0 (* z (* t y))) (* i 4.0)))
(if (<= x 6e+167)
(- (- (* b c) (+ (* 4.0 (* t a)) (* 4.0 (* x i)))) (* k (* j 27.0)))
(* x (- (* 18.0 (* t (* y z))) (* i 4.0))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -3.3e+86) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 6e+167) {
tmp = ((b * c) - ((4.0 * (t * a)) + (4.0 * (x * i)))) - (k * (j * 27.0));
} else {
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (x <= (-3.3d+86)) then
tmp = x * ((18.0d0 * (z * (t * y))) - (i * 4.0d0))
else if (x <= 6d+167) then
tmp = ((b * c) - ((4.0d0 * (t * a)) + (4.0d0 * (x * i)))) - (k * (j * 27.0d0))
else
tmp = x * ((18.0d0 * (t * (y * z))) - (i * 4.0d0))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -3.3e+86) {
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
} else if (x <= 6e+167) {
tmp = ((b * c) - ((4.0 * (t * a)) + (4.0 * (x * i)))) - (k * (j * 27.0));
} else {
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if x <= -3.3e+86: tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0)) elif x <= 6e+167: tmp = ((b * c) - ((4.0 * (t * a)) + (4.0 * (x * i)))) - (k * (j * 27.0)) else: tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0)) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (x <= -3.3e+86) tmp = Float64(x * Float64(Float64(18.0 * Float64(z * Float64(t * y))) - Float64(i * 4.0))); elseif (x <= 6e+167) tmp = Float64(Float64(Float64(b * c) - Float64(Float64(4.0 * Float64(t * a)) + Float64(4.0 * Float64(x * i)))) - Float64(k * Float64(j * 27.0))); else tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(i * 4.0))); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (x <= -3.3e+86)
tmp = x * ((18.0 * (z * (t * y))) - (i * 4.0));
elseif (x <= 6e+167)
tmp = ((b * c) - ((4.0 * (t * a)) + (4.0 * (x * i)))) - (k * (j * 27.0));
else
tmp = x * ((18.0 * (t * (y * z))) - (i * 4.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[x, -3.3e+86], N[(x * N[(N[(18.0 * N[(z * N[(t * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 6e+167], N[(N[(N[(b * c), $MachinePrecision] - N[(N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision] + N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(k * N[(j * 27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(i * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.3 \cdot 10^{+86}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(z \cdot \left(t \cdot y\right)\right) - i \cdot 4\right)\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+167}:\\
\;\;\;\;\left(b \cdot c - \left(4 \cdot \left(t \cdot a\right) + 4 \cdot \left(x \cdot i\right)\right)\right) - k \cdot \left(j \cdot 27\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - i \cdot 4\right)\\
\end{array}
\end{array}
if x < -3.2999999999999999e86Initial program 69.6%
Simplified84.7%
Taylor expanded in x around inf 77.5%
expm1-log1p-u61.5%
expm1-udef59.8%
Applied egg-rr59.8%
expm1-def61.5%
expm1-log1p77.5%
associate-*r*75.8%
Simplified75.8%
if -3.2999999999999999e86 < x < 6.00000000000000023e167Initial program 90.5%
Taylor expanded in y around 0 87.3%
if 6.00000000000000023e167 < x Initial program 73.0%
Simplified80.7%
Taylor expanded in x around inf 77.1%
Final simplification83.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= k -1.45e-60)
(* -27.0 (* j k))
(if (<= k 1.4e-196)
(* b c)
(if (<= k 9.5e-123)
(* -4.0 (* x i))
(if (<= k 3.3e+75) (* 18.0 (* t (* x (* y z)))) (* k (* j -27.0)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (k <= -1.45e-60) {
tmp = -27.0 * (j * k);
} else if (k <= 1.4e-196) {
tmp = b * c;
} else if (k <= 9.5e-123) {
tmp = -4.0 * (x * i);
} else if (k <= 3.3e+75) {
tmp = 18.0 * (t * (x * (y * z)));
} 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.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (k <= (-1.45d-60)) then
tmp = (-27.0d0) * (j * k)
else if (k <= 1.4d-196) then
tmp = b * c
else if (k <= 9.5d-123) then
tmp = (-4.0d0) * (x * i)
else if (k <= 3.3d+75) then
tmp = 18.0d0 * (t * (x * (y * z)))
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;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (k <= -1.45e-60) {
tmp = -27.0 * (j * k);
} else if (k <= 1.4e-196) {
tmp = b * c;
} else if (k <= 9.5e-123) {
tmp = -4.0 * (x * i);
} else if (k <= 3.3e+75) {
tmp = 18.0 * (t * (x * (y * z)));
} 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]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if k <= -1.45e-60: tmp = -27.0 * (j * k) elif k <= 1.4e-196: tmp = b * c elif k <= 9.5e-123: tmp = -4.0 * (x * i) elif k <= 3.3e+75: tmp = 18.0 * (t * (x * (y * z))) 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]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (k <= -1.45e-60) tmp = Float64(-27.0 * Float64(j * k)); elseif (k <= 1.4e-196) tmp = Float64(b * c); elseif (k <= 9.5e-123) tmp = Float64(-4.0 * Float64(x * i)); elseif (k <= 3.3e+75) tmp = Float64(18.0 * Float64(t * Float64(x * Float64(y * z)))); 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])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (k <= -1.45e-60)
tmp = -27.0 * (j * k);
elseif (k <= 1.4e-196)
tmp = b * c;
elseif (k <= 9.5e-123)
tmp = -4.0 * (x * i);
elseif (k <= 3.3e+75)
tmp = 18.0 * (t * (x * (y * z)));
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. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[k, -1.45e-60], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.4e-196], N[(b * c), $MachinePrecision], If[LessEqual[k, 9.5e-123], N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 3.3e+75], N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;k \leq -1.45 \cdot 10^{-60}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;k \leq 1.4 \cdot 10^{-196}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;k \leq 9.5 \cdot 10^{-123}:\\
\;\;\;\;-4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;k \leq 3.3 \cdot 10^{+75}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\
\end{array}
\end{array}
if k < -1.45e-60Initial program 81.3%
Simplified88.5%
Taylor expanded in j around inf 40.3%
if -1.45e-60 < k < 1.3999999999999999e-196Initial program 88.6%
Simplified88.5%
associate--l+88.5%
*-commutative88.5%
fma-def89.9%
associate-*l*89.9%
fma-neg89.9%
associate-*r*88.6%
associate-*r*88.6%
+-commutative88.6%
fma-def88.6%
*-commutative88.6%
*-commutative88.6%
Applied egg-rr88.6%
Taylor expanded in b around inf 28.8%
if 1.3999999999999999e-196 < k < 9.5000000000000002e-123Initial program 81.4%
Simplified85.6%
associate--l+85.6%
*-commutative85.6%
fma-def90.5%
associate-*l*90.5%
fma-neg90.5%
associate-*r*90.5%
associate-*r*90.5%
+-commutative90.5%
fma-def90.5%
*-commutative90.5%
*-commutative90.5%
Applied egg-rr90.5%
Taylor expanded in i around inf 41.4%
*-commutative41.4%
Simplified41.4%
if 9.5000000000000002e-123 < k < 3.29999999999999998e75Initial program 75.9%
Simplified89.1%
associate--l+89.1%
*-commutative89.1%
fma-def89.1%
associate-*l*89.0%
fma-neg89.0%
associate-*r*89.1%
associate-*r*89.1%
+-commutative89.1%
fma-def89.1%
*-commutative89.1%
*-commutative89.1%
Applied egg-rr89.1%
Taylor expanded in y around inf 32.5%
if 3.29999999999999998e75 < k Initial program 92.2%
Simplified92.2%
Taylor expanded in j around inf 52.0%
associate-*r*52.1%
Simplified52.1%
Final simplification38.1%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* -27.0 (* j k))))
(if (<= k -1.45e-60)
t_1
(if (<= k 1.5e-196)
(* b c)
(if (<= k 8e+21) (* -4.0 (* x i)) (if (<= k 6.8e+96) (* b c) t_1))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -27.0 * (j * k);
double tmp;
if (k <= -1.45e-60) {
tmp = t_1;
} else if (k <= 1.5e-196) {
tmp = b * c;
} else if (k <= 8e+21) {
tmp = -4.0 * (x * i);
} else if (k <= 6.8e+96) {
tmp = b * c;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-27.0d0) * (j * k)
if (k <= (-1.45d-60)) then
tmp = t_1
else if (k <= 1.5d-196) then
tmp = b * c
else if (k <= 8d+21) then
tmp = (-4.0d0) * (x * i)
else if (k <= 6.8d+96) then
tmp = b * c
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -27.0 * (j * k);
double tmp;
if (k <= -1.45e-60) {
tmp = t_1;
} else if (k <= 1.5e-196) {
tmp = b * c;
} else if (k <= 8e+21) {
tmp = -4.0 * (x * i);
} else if (k <= 6.8e+96) {
tmp = b * c;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = -27.0 * (j * k) tmp = 0 if k <= -1.45e-60: tmp = t_1 elif k <= 1.5e-196: tmp = b * c elif k <= 8e+21: tmp = -4.0 * (x * i) elif k <= 6.8e+96: tmp = b * c else: tmp = t_1 return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-27.0 * Float64(j * k)) tmp = 0.0 if (k <= -1.45e-60) tmp = t_1; elseif (k <= 1.5e-196) tmp = Float64(b * c); elseif (k <= 8e+21) tmp = Float64(-4.0 * Float64(x * i)); elseif (k <= 6.8e+96) tmp = Float64(b * c); else tmp = t_1; end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = -27.0 * (j * k);
tmp = 0.0;
if (k <= -1.45e-60)
tmp = t_1;
elseif (k <= 1.5e-196)
tmp = b * c;
elseif (k <= 8e+21)
tmp = -4.0 * (x * i);
elseif (k <= 6.8e+96)
tmp = b * c;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -1.45e-60], t$95$1, If[LessEqual[k, 1.5e-196], N[(b * c), $MachinePrecision], If[LessEqual[k, 8e+21], N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 6.8e+96], N[(b * c), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := -27 \cdot \left(j \cdot k\right)\\
\mathbf{if}\;k \leq -1.45 \cdot 10^{-60}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;k \leq 1.5 \cdot 10^{-196}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;k \leq 8 \cdot 10^{+21}:\\
\;\;\;\;-4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;k \leq 6.8 \cdot 10^{+96}:\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if k < -1.45e-60 or 6.8000000000000002e96 < k Initial program 85.4%
Simplified89.8%
Taylor expanded in j around inf 46.2%
if -1.45e-60 < k < 1.5e-196 or 8e21 < k < 6.8000000000000002e96Initial program 86.2%
Simplified88.4%
associate--l+88.4%
*-commutative88.4%
fma-def89.5%
associate-*l*89.5%
fma-neg89.5%
associate-*r*88.4%
associate-*r*88.4%
+-commutative88.4%
fma-def88.4%
*-commutative88.4%
*-commutative88.4%
Applied egg-rr88.4%
Taylor expanded in b around inf 29.5%
if 1.5e-196 < k < 8e21Initial program 79.6%
Simplified88.7%
associate--l+88.7%
*-commutative88.7%
fma-def90.6%
associate-*l*90.6%
fma-neg90.6%
associate-*r*90.6%
associate-*r*90.6%
+-commutative90.6%
fma-def90.6%
*-commutative90.6%
*-commutative90.6%
Applied egg-rr90.6%
Taylor expanded in i around inf 32.9%
*-commutative32.9%
Simplified32.9%
Final simplification37.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= k -1.4e-60)
(* -27.0 (* j k))
(if (<= k 1.4e-196)
(* b c)
(if (<= k 1.1e+22)
(* -4.0 (* x i))
(if (<= k 7.2e+96) (* b c) (* j (* k -27.0)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (k <= -1.4e-60) {
tmp = -27.0 * (j * k);
} else if (k <= 1.4e-196) {
tmp = b * c;
} else if (k <= 1.1e+22) {
tmp = -4.0 * (x * i);
} else if (k <= 7.2e+96) {
tmp = b * c;
} else {
tmp = j * (k * -27.0);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (k <= (-1.4d-60)) then
tmp = (-27.0d0) * (j * k)
else if (k <= 1.4d-196) then
tmp = b * c
else if (k <= 1.1d+22) then
tmp = (-4.0d0) * (x * i)
else if (k <= 7.2d+96) then
tmp = b * c
else
tmp = j * (k * (-27.0d0))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (k <= -1.4e-60) {
tmp = -27.0 * (j * k);
} else if (k <= 1.4e-196) {
tmp = b * c;
} else if (k <= 1.1e+22) {
tmp = -4.0 * (x * i);
} else if (k <= 7.2e+96) {
tmp = b * c;
} else {
tmp = j * (k * -27.0);
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if k <= -1.4e-60: tmp = -27.0 * (j * k) elif k <= 1.4e-196: tmp = b * c elif k <= 1.1e+22: tmp = -4.0 * (x * i) elif k <= 7.2e+96: tmp = b * c else: tmp = j * (k * -27.0) return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (k <= -1.4e-60) tmp = Float64(-27.0 * Float64(j * k)); elseif (k <= 1.4e-196) tmp = Float64(b * c); elseif (k <= 1.1e+22) tmp = Float64(-4.0 * Float64(x * i)); elseif (k <= 7.2e+96) tmp = Float64(b * c); else tmp = Float64(j * Float64(k * -27.0)); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (k <= -1.4e-60)
tmp = -27.0 * (j * k);
elseif (k <= 1.4e-196)
tmp = b * c;
elseif (k <= 1.1e+22)
tmp = -4.0 * (x * i);
elseif (k <= 7.2e+96)
tmp = b * c;
else
tmp = j * (k * -27.0);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[k, -1.4e-60], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.4e-196], N[(b * c), $MachinePrecision], If[LessEqual[k, 1.1e+22], N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 7.2e+96], N[(b * c), $MachinePrecision], N[(j * N[(k * -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])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;k \leq -1.4 \cdot 10^{-60}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;k \leq 1.4 \cdot 10^{-196}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;k \leq 1.1 \cdot 10^{+22}:\\
\;\;\;\;-4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;k \leq 7.2 \cdot 10^{+96}:\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right)\\
\end{array}
\end{array}
if k < -1.4000000000000001e-60Initial program 81.3%
Simplified88.5%
Taylor expanded in j around inf 40.3%
if -1.4000000000000001e-60 < k < 1.3999999999999999e-196 or 1.1e22 < k < 7.20000000000000026e96Initial program 86.2%
Simplified88.4%
associate--l+88.4%
*-commutative88.4%
fma-def89.5%
associate-*l*89.5%
fma-neg89.5%
associate-*r*88.4%
associate-*r*88.4%
+-commutative88.4%
fma-def88.4%
*-commutative88.4%
*-commutative88.4%
Applied egg-rr88.4%
Taylor expanded in b around inf 29.5%
if 1.3999999999999999e-196 < k < 1.1e22Initial program 79.6%
Simplified88.7%
associate--l+88.7%
*-commutative88.7%
fma-def90.6%
associate-*l*90.6%
fma-neg90.6%
associate-*r*90.6%
associate-*r*90.6%
+-commutative90.6%
fma-def90.6%
*-commutative90.6%
*-commutative90.6%
Applied egg-rr90.6%
Taylor expanded in i around inf 32.9%
*-commutative32.9%
Simplified32.9%
if 7.20000000000000026e96 < k Initial program 91.7%
Simplified91.7%
associate--l+91.7%
*-commutative91.7%
fma-def91.7%
associate-*l*91.7%
fma-neg91.7%
associate-*r*91.7%
associate-*r*91.7%
+-commutative91.7%
fma-def91.7%
*-commutative91.7%
*-commutative91.7%
Applied egg-rr91.7%
Taylor expanded in j around inf 55.2%
*-commutative55.2%
associate-*r*55.1%
Simplified55.1%
Final simplification37.7%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= k -1.22e-60)
(* -27.0 (* j k))
(if (<= k 1.4e-196)
(* b c)
(if (<= k 3.2e+22)
(* -4.0 (* x i))
(if (<= k 7.8e+97) (* 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);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (k <= -1.22e-60) {
tmp = -27.0 * (j * k);
} else if (k <= 1.4e-196) {
tmp = b * c;
} else if (k <= 3.2e+22) {
tmp = -4.0 * (x * i);
} else if (k <= 7.8e+97) {
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.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (k <= (-1.22d-60)) then
tmp = (-27.0d0) * (j * k)
else if (k <= 1.4d-196) then
tmp = b * c
else if (k <= 3.2d+22) then
tmp = (-4.0d0) * (x * i)
else if (k <= 7.8d+97) 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;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (k <= -1.22e-60) {
tmp = -27.0 * (j * k);
} else if (k <= 1.4e-196) {
tmp = b * c;
} else if (k <= 3.2e+22) {
tmp = -4.0 * (x * i);
} else if (k <= 7.8e+97) {
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]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if k <= -1.22e-60: tmp = -27.0 * (j * k) elif k <= 1.4e-196: tmp = b * c elif k <= 3.2e+22: tmp = -4.0 * (x * i) elif k <= 7.8e+97: 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]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (k <= -1.22e-60) tmp = Float64(-27.0 * Float64(j * k)); elseif (k <= 1.4e-196) tmp = Float64(b * c); elseif (k <= 3.2e+22) tmp = Float64(-4.0 * Float64(x * i)); elseif (k <= 7.8e+97) 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])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (k <= -1.22e-60)
tmp = -27.0 * (j * k);
elseif (k <= 1.4e-196)
tmp = b * c;
elseif (k <= 3.2e+22)
tmp = -4.0 * (x * i);
elseif (k <= 7.8e+97)
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. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[k, -1.22e-60], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.4e-196], N[(b * c), $MachinePrecision], If[LessEqual[k, 3.2e+22], N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 7.8e+97], 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])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;k \leq -1.22 \cdot 10^{-60}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;k \leq 1.4 \cdot 10^{-196}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;k \leq 3.2 \cdot 10^{+22}:\\
\;\;\;\;-4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;k \leq 7.8 \cdot 10^{+97}:\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\
\end{array}
\end{array}
if k < -1.22e-60Initial program 81.3%
Simplified88.5%
Taylor expanded in j around inf 40.3%
if -1.22e-60 < k < 1.3999999999999999e-196 or 3.2e22 < k < 7.7999999999999999e97Initial program 86.2%
Simplified88.4%
associate--l+88.4%
*-commutative88.4%
fma-def89.5%
associate-*l*89.5%
fma-neg89.5%
associate-*r*88.4%
associate-*r*88.4%
+-commutative88.4%
fma-def88.4%
*-commutative88.4%
*-commutative88.4%
Applied egg-rr88.4%
Taylor expanded in b around inf 29.5%
if 1.3999999999999999e-196 < k < 3.2e22Initial program 79.6%
Simplified88.7%
associate--l+88.7%
*-commutative88.7%
fma-def90.6%
associate-*l*90.6%
fma-neg90.6%
associate-*r*90.6%
associate-*r*90.6%
+-commutative90.6%
fma-def90.6%
*-commutative90.6%
*-commutative90.6%
Applied egg-rr90.6%
Taylor expanded in i around inf 32.9%
*-commutative32.9%
Simplified32.9%
if 7.7999999999999999e97 < k Initial program 91.7%
Simplified91.7%
Taylor expanded in j around inf 55.2%
associate-*r*55.2%
Simplified55.2%
Final simplification37.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= x -2.3e+89)
(* -4.0 (* x i))
(if (<= x 1.9e+126)
(+ (* j (* k -27.0)) (* b c))
(* 18.0 (* t (* x (* y z)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -2.3e+89) {
tmp = -4.0 * (x * i);
} else if (x <= 1.9e+126) {
tmp = (j * (k * -27.0)) + (b * c);
} else {
tmp = 18.0 * (t * (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.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (x <= (-2.3d+89)) then
tmp = (-4.0d0) * (x * i)
else if (x <= 1.9d+126) then
tmp = (j * (k * (-27.0d0))) + (b * c)
else
tmp = 18.0d0 * (t * (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;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (x <= -2.3e+89) {
tmp = -4.0 * (x * i);
} else if (x <= 1.9e+126) {
tmp = (j * (k * -27.0)) + (b * c);
} else {
tmp = 18.0 * (t * (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]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if x <= -2.3e+89: tmp = -4.0 * (x * i) elif x <= 1.9e+126: tmp = (j * (k * -27.0)) + (b * c) else: tmp = 18.0 * (t * (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]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (x <= -2.3e+89) tmp = Float64(-4.0 * Float64(x * i)); elseif (x <= 1.9e+126) tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(b * c)); else tmp = Float64(18.0 * Float64(t * 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])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if (x <= -2.3e+89)
tmp = -4.0 * (x * i);
elseif (x <= 1.9e+126)
tmp = (j * (k * -27.0)) + (b * c);
else
tmp = 18.0 * (t * (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. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[x, -2.3e+89], N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.9e+126], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision], N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.3 \cdot 10^{+89}:\\
\;\;\;\;-4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;x \leq 1.9 \cdot 10^{+126}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + b \cdot c\\
\mathbf{else}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\
\end{array}
\end{array}
if x < -2.2999999999999999e89Initial program 68.4%
Simplified84.1%
associate--l+84.1%
*-commutative84.1%
fma-def84.1%
associate-*l*84.1%
fma-neg84.1%
associate-*r*84.1%
associate-*r*84.1%
+-commutative84.1%
fma-def84.1%
*-commutative84.1%
*-commutative84.1%
Applied egg-rr84.1%
Taylor expanded in i around inf 49.5%
*-commutative49.5%
Simplified49.5%
if -2.2999999999999999e89 < x < 1.90000000000000008e126Initial program 91.1%
Simplified92.9%
Taylor expanded in b around inf 59.5%
if 1.90000000000000008e126 < x Initial program 75.1%
Simplified80.7%
associate--l+80.7%
*-commutative80.7%
fma-def86.2%
associate-*l*86.2%
fma-neg86.2%
associate-*r*86.2%
associate-*r*86.2%
+-commutative86.2%
fma-def86.2%
*-commutative86.2%
*-commutative86.2%
Applied egg-rr86.2%
Taylor expanded in y around inf 47.0%
Final simplification55.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (if (or (<= k -1.45e-60) (not (<= k 1.25e+98))) (* -27.0 (* j k)) (* b c)))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((k <= -1.45e-60) || !(k <= 1.25e+98)) {
tmp = -27.0 * (j * k);
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if ((k <= (-1.45d-60)) .or. (.not. (k <= 1.25d+98))) then
tmp = (-27.0d0) * (j * k)
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if ((k <= -1.45e-60) || !(k <= 1.25e+98)) {
tmp = -27.0 * (j * k);
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if (k <= -1.45e-60) or not (k <= 1.25e+98): tmp = -27.0 * (j * k) else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if ((k <= -1.45e-60) || !(k <= 1.25e+98)) tmp = Float64(-27.0 * Float64(j * k)); else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
tmp = 0.0;
if ((k <= -1.45e-60) || ~((k <= 1.25e+98)))
tmp = -27.0 * (j * k);
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[k, -1.45e-60], N[Not[LessEqual[k, 1.25e+98]], $MachinePrecision]], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;k \leq -1.45 \cdot 10^{-60} \lor \neg \left(k \leq 1.25 \cdot 10^{+98}\right):\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if k < -1.45e-60 or 1.25e98 < k Initial program 85.4%
Simplified89.8%
Taylor expanded in j around inf 46.2%
if -1.45e-60 < k < 1.25e98Initial program 83.7%
Simplified88.5%
associate--l+88.5%
*-commutative88.5%
fma-def89.9%
associate-*l*89.9%
fma-neg89.9%
associate-*r*89.3%
associate-*r*89.3%
+-commutative89.3%
fma-def89.3%
*-commutative89.3%
*-commutative89.3%
Applied egg-rr89.3%
Taylor expanded in b around inf 26.3%
Final simplification35.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (* b c))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = b * c
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): return b * c
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) return Float64(b * c) end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp = code(x, y, z, t, a, b, c, i, j, k)
tmp = b * c;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(b * c), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
b \cdot c
\end{array}
Initial program 84.5%
Simplified88.7%
associate--l+88.7%
*-commutative88.7%
fma-def90.6%
associate-*l*90.3%
fma-neg90.3%
associate-*r*89.9%
associate-*r*89.9%
+-commutative89.9%
fma-def89.9%
*-commutative89.9%
*-commutative89.9%
Applied egg-rr89.9%
Taylor expanded in b around inf 25.9%
Final simplification25.9%
(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 2024020
(FPCore (x y z t a b c i j k)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, E"
:precision binary64
:herbie-target
(if (< t -1.6210815397541398e-69) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b))) (if (< t 165.68027943805222) (+ (- (* (* 18.0 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4.0)) (- (* c b) (* 27.0 (* k j)))) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b)))))
(- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))