
(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 29 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i j k) :precision binary64 (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k): return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<=
(-
(-
(+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
(* (* x 4.0) i))
(* (* j 27.0) k))
INFINITY)
(fma
(fma x (* 18.0 (* y z)) (* a -4.0))
t
(- (* b c) (fma x (* 4.0 i) (* 27.0 (* j k)))))
(fma (fma (* (* x 18.0) z) y (* a -4.0)) t (* b c))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (((((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)) <= ((double) INFINITY)) {
tmp = fma(fma(x, (18.0 * (y * z)), (a * -4.0)), t, ((b * c) - fma(x, (4.0 * i), (27.0 * (j * k)))));
} else {
tmp = fma(fma(((x * 18.0) * z), y, (a * -4.0)), t, (b * c));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) <= Inf) tmp = fma(fma(x, Float64(18.0 * Float64(y * z)), Float64(a * -4.0)), t, Float64(Float64(b * c) - fma(x, Float64(4.0 * i), Float64(27.0 * Float64(j * k))))); else tmp = fma(fma(Float64(Float64(x * 18.0) * z), y, Float64(a * -4.0)), t, 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], Infinity], N[(N[(x * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + N[(N[(b * c), $MachinePrecision] - N[(x * N[(4.0 * i), $MachinePrecision] + N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(x * 18.0), $MachinePrecision] * z), $MachinePrecision] * y + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + 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])\\
\\
\begin{array}{l}
\mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \leq \infty:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), t, b \cdot c - \mathsf{fma}\left(x, 4 \cdot i, 27 \cdot \left(j \cdot k\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(x \cdot 18\right) \cdot z, y, a \cdot -4\right), t, b \cdot c\right)\\
\end{array}
\end{array}
if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) < +inf.0Initial program 95.7%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr96.1%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) Initial program 0.0%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr29.0%
Taylor expanded in b around inf
*-lowering-*.f6458.1
Simplified58.1%
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6461.3
Applied egg-rr61.3%
Final simplification91.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<=
(-
(-
(+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
(* (* x 4.0) i))
(* (* j 27.0) k))
INFINITY)
(fma
(* j k)
-27.0
(fma t (fma x (* 18.0 (* y z)) (* a -4.0)) (fma b c (* -4.0 (* x i)))))
(fma (fma (* (* x 18.0) z) y (* a -4.0)) t (* b c))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (((((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)) <= ((double) INFINITY)) {
tmp = fma((j * k), -27.0, fma(t, fma(x, (18.0 * (y * z)), (a * -4.0)), fma(b, c, (-4.0 * (x * i)))));
} else {
tmp = fma(fma(((x * 18.0) * z), y, (a * -4.0)), t, (b * c));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) <= Inf) tmp = fma(Float64(j * k), -27.0, fma(t, fma(x, Float64(18.0 * Float64(y * z)), Float64(a * -4.0)), fma(b, c, Float64(-4.0 * Float64(x * i))))); else tmp = fma(fma(Float64(Float64(x * 18.0) * z), y, Float64(a * -4.0)), t, 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], Infinity], N[(N[(j * k), $MachinePrecision] * -27.0 + N[(t * N[(x * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(b * c + N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(x * 18.0), $MachinePrecision] * z), $MachinePrecision] * y + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + 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])\\
\\
\begin{array}{l}
\mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \leq \infty:\\
\;\;\;\;\mathsf{fma}\left(j \cdot k, -27, \mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, -4 \cdot \left(x \cdot i\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(x \cdot 18\right) \cdot z, y, a \cdot -4\right), t, b \cdot c\right)\\
\end{array}
\end{array}
if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) < +inf.0Initial program 95.7%
sub-negN/A
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
metadata-evalN/A
associate--l+N/A
distribute-rgt-out--N/A
accelerator-lowering-fma.f64N/A
Applied egg-rr96.1%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) Initial program 0.0%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr29.0%
Taylor expanded in b around inf
*-lowering-*.f6458.1
Simplified58.1%
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6461.3
Applied egg-rr61.3%
Final simplification91.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j k) -27.0)) (t_2 (* (* j 27.0) k)))
(if (<= t_2 -4e+174)
t_1
(if (<= t_2 -5e-21)
(* b c)
(if (<= t_2 -1e-215)
(* -4.0 (* t a))
(if (<= t_2 5e+122) (* b c) t_1))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * k) * -27.0;
double t_2 = (j * 27.0) * k;
double tmp;
if (t_2 <= -4e+174) {
tmp = t_1;
} else if (t_2 <= -5e-21) {
tmp = b * c;
} else if (t_2 <= -1e-215) {
tmp = -4.0 * (t * a);
} else if (t_2 <= 5e+122) {
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.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (j * k) * (-27.0d0)
t_2 = (j * 27.0d0) * k
if (t_2 <= (-4d+174)) then
tmp = t_1
else if (t_2 <= (-5d-21)) then
tmp = b * c
else if (t_2 <= (-1d-215)) then
tmp = (-4.0d0) * (t * a)
else if (t_2 <= 5d+122) 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;
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 = (j * 27.0) * k;
double tmp;
if (t_2 <= -4e+174) {
tmp = t_1;
} else if (t_2 <= -5e-21) {
tmp = b * c;
} else if (t_2 <= -1e-215) {
tmp = -4.0 * (t * a);
} else if (t_2 <= 5e+122) {
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]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (j * k) * -27.0 t_2 = (j * 27.0) * k tmp = 0 if t_2 <= -4e+174: tmp = t_1 elif t_2 <= -5e-21: tmp = b * c elif t_2 <= -1e-215: tmp = -4.0 * (t * a) elif t_2 <= 5e+122: 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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * k) * -27.0) t_2 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_2 <= -4e+174) tmp = t_1; elseif (t_2 <= -5e-21) tmp = Float64(b * c); elseif (t_2 <= -1e-215) tmp = Float64(-4.0 * Float64(t * a)); elseif (t_2 <= 5e+122) 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (j * k) * -27.0;
t_2 = (j * 27.0) * k;
tmp = 0.0;
if (t_2 <= -4e+174)
tmp = t_1;
elseif (t_2 <= -5e-21)
tmp = b * c;
elseif (t_2 <= -1e-215)
tmp = -4.0 * (t * a);
elseif (t_2 <= 5e+122)
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$2, -4e+174], t$95$1, If[LessEqual[t$95$2, -5e-21], N[(b * c), $MachinePrecision], If[LessEqual[t$95$2, -1e-215], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 5e+122], 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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot k\right) \cdot -27\\
t_2 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_2 \leq -4 \cdot 10^{+174}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-21}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;t\_2 \leq -1 \cdot 10^{-215}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+122}:\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.00000000000000028e174 or 4.99999999999999989e122 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 83.3%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6483.5
Simplified83.5%
Taylor expanded in j around inf
*-lowering-*.f64N/A
*-lowering-*.f6461.1
Simplified61.1%
if -4.00000000000000028e174 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.99999999999999973e-21 or -1.00000000000000004e-215 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 4.99999999999999989e122Initial program 84.0%
Taylor expanded in b around inf
*-lowering-*.f6432.0
Simplified32.0%
if -4.99999999999999973e-21 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -1.00000000000000004e-215Initial program 86.4%
Taylor expanded in a around inf
*-lowering-*.f64N/A
*-lowering-*.f6440.9
Simplified40.9%
Final simplification41.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= t_1 -0.002)
(fma j (* k -27.0) (fma -4.0 (* x i) (* b c)))
(if (<= t_1 2e+84)
(fma (fma (* (* x 18.0) z) y (* a -4.0)) t (* b c))
(fma (* t -4.0) a (fma 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);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -0.002) {
tmp = fma(j, (k * -27.0), fma(-4.0, (x * i), (b * c)));
} else if (t_1 <= 2e+84) {
tmp = fma(fma(((x * 18.0) * z), y, (a * -4.0)), t, (b * c));
} else {
tmp = fma((t * -4.0), a, fma(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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_1 <= -0.002) tmp = fma(j, Float64(k * -27.0), fma(-4.0, Float64(x * i), Float64(b * c))); elseif (t_1 <= 2e+84) tmp = fma(fma(Float64(Float64(x * 18.0) * z), y, Float64(a * -4.0)), t, Float64(b * c)); else tmp = fma(Float64(t * -4.0), a, fma(j, Float64(k * -27.0), 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$1, -0.002], N[(j * N[(k * -27.0), $MachinePrecision] + N[(-4.0 * N[(x * i), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e+84], N[(N[(N[(N[(x * 18.0), $MachinePrecision] * z), $MachinePrecision] * y + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], N[(N[(t * -4.0), $MachinePrecision] * a + N[(j * N[(k * -27.0), $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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -0.002:\\
\;\;\;\;\mathsf{fma}\left(j, k \cdot -27, \mathsf{fma}\left(-4, x \cdot i, b \cdot c\right)\right)\\
\mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+84}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(x \cdot 18\right) \cdot z, y, a \cdot -4\right), t, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(t \cdot -4, a, \mathsf{fma}\left(j, k \cdot -27, b \cdot c\right)\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -2e-3Initial program 83.8%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr80.1%
Taylor expanded in t around 0
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6483.0
Simplified83.0%
if -2e-3 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 2.00000000000000012e84Initial program 83.4%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr86.6%
Taylor expanded in b around inf
*-lowering-*.f6476.0
Simplified76.0%
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6476.0
Applied egg-rr76.0%
if 2.00000000000000012e84 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 87.1%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6471.5
Simplified71.5%
+-commutativeN/A
associate-+l+N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6477.9
Applied egg-rr77.9%
Final simplification77.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 18.0 (* y z))) (t_2 (* (* j 27.0) k)))
(if (<= x -4.3e+99)
(- (* x (fma 18.0 (* z (* y t)) (* i -4.0))) t_2)
(if (<= x 0.23)
(fma b c (fma -4.0 (fma a t (* x i)) (* j (* k -27.0))))
(if (<= x 2.15e+111)
(fma (fma x t_1 (* a -4.0)) t (* b c))
(- (* x (fma -4.0 i (* t t_1))) t_2))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 18.0 * (y * z);
double t_2 = (j * 27.0) * k;
double tmp;
if (x <= -4.3e+99) {
tmp = (x * fma(18.0, (z * (y * t)), (i * -4.0))) - t_2;
} else if (x <= 0.23) {
tmp = fma(b, c, fma(-4.0, fma(a, t, (x * i)), (j * (k * -27.0))));
} else if (x <= 2.15e+111) {
tmp = fma(fma(x, t_1, (a * -4.0)), t, (b * c));
} else {
tmp = (x * fma(-4.0, i, (t * t_1))) - t_2;
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(18.0 * Float64(y * z)) t_2 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (x <= -4.3e+99) tmp = Float64(Float64(x * fma(18.0, Float64(z * Float64(y * t)), Float64(i * -4.0))) - t_2); elseif (x <= 0.23) tmp = fma(b, c, fma(-4.0, fma(a, t, Float64(x * i)), Float64(j * Float64(k * -27.0)))); elseif (x <= 2.15e+111) tmp = fma(fma(x, t_1, Float64(a * -4.0)), t, Float64(b * c)); else tmp = Float64(Float64(x * fma(-4.0, i, Float64(t * t_1))) - t_2); 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[x, -4.3e+99], N[(N[(x * N[(18.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[x, 0.23], N[(b * c + N[(-4.0 * N[(a * t + N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.15e+111], N[(N[(x * t$95$1 + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(-4.0 * i + N[(t * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(y \cdot z\right)\\
t_2 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;x \leq -4.3 \cdot 10^{+99}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(18, z \cdot \left(y \cdot t\right), i \cdot -4\right) - t\_2\\
\mathbf{elif}\;x \leq 0.23:\\
\;\;\;\;\mathsf{fma}\left(b, c, \mathsf{fma}\left(-4, \mathsf{fma}\left(a, t, x \cdot i\right), j \cdot \left(k \cdot -27\right)\right)\right)\\
\mathbf{elif}\;x \leq 2.15 \cdot 10^{+111}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(x, t\_1, a \cdot -4\right), t, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(-4, i, t \cdot t\_1\right) - t\_2\\
\end{array}
\end{array}
if x < -4.3000000000000001e99Initial program 75.7%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr75.6%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6491.5
Simplified91.5%
if -4.3000000000000001e99 < x < 0.23000000000000001Initial program 91.1%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6482.7
Simplified82.7%
if 0.23000000000000001 < x < 2.14999999999999997e111Initial program 76.4%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr88.1%
Taylor expanded in b around inf
*-lowering-*.f6488.2
Simplified88.2%
if 2.14999999999999997e111 < x Initial program 73.5%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6490.6
Simplified90.6%
Final simplification86.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 18.0 (* y z)))
(t_2 (- (* x (fma -4.0 i (* t t_1))) (* (* j 27.0) k))))
(if (<= x -1.02e+102)
t_2
(if (<= x 0.0075)
(fma b c (fma -4.0 (fma a t (* x i)) (* j (* k -27.0))))
(if (<= x 1.8e+112) (fma (fma x t_1 (* a -4.0)) t (* b c)) t_2)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 18.0 * (y * z);
double t_2 = (x * fma(-4.0, i, (t * t_1))) - ((j * 27.0) * k);
double tmp;
if (x <= -1.02e+102) {
tmp = t_2;
} else if (x <= 0.0075) {
tmp = fma(b, c, fma(-4.0, fma(a, t, (x * i)), (j * (k * -27.0))));
} else if (x <= 1.8e+112) {
tmp = fma(fma(x, t_1, (a * -4.0)), t, (b * c));
} else {
tmp = t_2;
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(18.0 * Float64(y * z)) t_2 = Float64(Float64(x * fma(-4.0, i, Float64(t * t_1))) - Float64(Float64(j * 27.0) * k)) tmp = 0.0 if (x <= -1.02e+102) tmp = t_2; elseif (x <= 0.0075) tmp = fma(b, c, fma(-4.0, fma(a, t, Float64(x * i)), Float64(j * Float64(k * -27.0)))); elseif (x <= 1.8e+112) tmp = fma(fma(x, t_1, Float64(a * -4.0)), t, Float64(b * c)); else tmp = t_2; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * N[(-4.0 * i + N[(t * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.02e+102], t$95$2, If[LessEqual[x, 0.0075], N[(b * c + N[(-4.0 * N[(a * t + N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.8e+112], N[(N[(x * t$95$1 + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(y \cdot z\right)\\
t_2 := x \cdot \mathsf{fma}\left(-4, i, t \cdot t\_1\right) - \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;x \leq -1.02 \cdot 10^{+102}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq 0.0075:\\
\;\;\;\;\mathsf{fma}\left(b, c, \mathsf{fma}\left(-4, \mathsf{fma}\left(a, t, x \cdot i\right), j \cdot \left(k \cdot -27\right)\right)\right)\\
\mathbf{elif}\;x \leq 1.8 \cdot 10^{+112}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(x, t\_1, a \cdot -4\right), t, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if x < -1.01999999999999999e102 or 1.8e112 < x Initial program 74.5%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6490.9
Simplified90.9%
if -1.01999999999999999e102 < x < 0.0074999999999999997Initial program 91.1%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6482.7
Simplified82.7%
if 0.0074999999999999997 < x < 1.8e112Initial program 76.4%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr88.1%
Taylor expanded in b around inf
*-lowering-*.f6488.2
Simplified88.2%
Final simplification86.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= x -1e+123)
(- (* x (fma 18.0 (* z (* y t)) (* i -4.0))) t_1)
(if (<= x 6.8e+81)
(fma t (fma (* (* x 18.0) y) z (* a -4.0)) (fma b c (* j (* k -27.0))))
(- (* x (fma -4.0 i (* t (* 18.0 (* y z))))) t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (x <= -1e+123) {
tmp = (x * fma(18.0, (z * (y * t)), (i * -4.0))) - t_1;
} else if (x <= 6.8e+81) {
tmp = fma(t, fma(((x * 18.0) * y), z, (a * -4.0)), fma(b, c, (j * (k * -27.0))));
} else {
tmp = (x * fma(-4.0, i, (t * (18.0 * (y * z))))) - t_1;
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (x <= -1e+123) tmp = Float64(Float64(x * fma(18.0, Float64(z * Float64(y * t)), Float64(i * -4.0))) - t_1); elseif (x <= 6.8e+81) tmp = fma(t, fma(Float64(Float64(x * 18.0) * y), z, Float64(a * -4.0)), fma(b, c, Float64(j * Float64(k * -27.0)))); else tmp = Float64(Float64(x * fma(-4.0, i, Float64(t * Float64(18.0 * Float64(y * z))))) - t_1); 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[x, -1e+123], N[(N[(x * N[(18.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[x, 6.8e+81], N[(t * N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(b * c + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(-4.0 * i + N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;x \leq -1 \cdot 10^{+123}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(18, z \cdot \left(y \cdot t\right), i \cdot -4\right) - t\_1\\
\mathbf{elif}\;x \leq 6.8 \cdot 10^{+81}:\\
\;\;\;\;\mathsf{fma}\left(t, \mathsf{fma}\left(\left(x \cdot 18\right) \cdot y, z, a \cdot -4\right), \mathsf{fma}\left(b, c, j \cdot \left(k \cdot -27\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(-4, i, t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right) - t\_1\\
\end{array}
\end{array}
if x < -9.99999999999999978e122Initial program 74.4%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr74.4%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6491.0
Simplified91.0%
if -9.99999999999999978e122 < x < 6.80000000000000005e81Initial program 90.7%
Taylor expanded in i around 0
associate--r+N/A
+-commutativeN/A
associate--l+N/A
+-commutativeN/A
associate--l+N/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
distribute-rgt-out--N/A
accelerator-lowering-fma.f64N/A
Simplified85.1%
+-commutativeN/A
associate-*r*N/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6487.5
Applied egg-rr87.5%
if 6.80000000000000005e81 < x Initial program 71.3%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6487.5
Simplified87.5%
Final simplification88.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= x -2.4e+122)
(- (* x (fma 18.0 (* z (* y t)) (* i -4.0))) t_1)
(if (<= x 5.2e+112)
(fma t (fma -4.0 a (* 18.0 (* x (* y z)))) (fma b c (* j (* k -27.0))))
(- (* x (fma -4.0 i (* t (* 18.0 (* y z))))) t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (x <= -2.4e+122) {
tmp = (x * fma(18.0, (z * (y * t)), (i * -4.0))) - t_1;
} else if (x <= 5.2e+112) {
tmp = fma(t, fma(-4.0, a, (18.0 * (x * (y * z)))), fma(b, c, (j * (k * -27.0))));
} else {
tmp = (x * fma(-4.0, i, (t * (18.0 * (y * z))))) - t_1;
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (x <= -2.4e+122) tmp = Float64(Float64(x * fma(18.0, Float64(z * Float64(y * t)), Float64(i * -4.0))) - t_1); elseif (x <= 5.2e+112) tmp = fma(t, fma(-4.0, a, Float64(18.0 * Float64(x * Float64(y * z)))), fma(b, c, Float64(j * Float64(k * -27.0)))); else tmp = Float64(Float64(x * fma(-4.0, i, Float64(t * Float64(18.0 * Float64(y * z))))) - t_1); 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[x, -2.4e+122], N[(N[(x * N[(18.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[x, 5.2e+112], N[(t * N[(-4.0 * a + N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(-4.0 * i + N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;x \leq -2.4 \cdot 10^{+122}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(18, z \cdot \left(y \cdot t\right), i \cdot -4\right) - t\_1\\
\mathbf{elif}\;x \leq 5.2 \cdot 10^{+112}:\\
\;\;\;\;\mathsf{fma}\left(t, \mathsf{fma}\left(-4, a, 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right), \mathsf{fma}\left(b, c, j \cdot \left(k \cdot -27\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(-4, i, t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right) - t\_1\\
\end{array}
\end{array}
if x < -2.4000000000000002e122Initial program 74.4%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr74.4%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6491.0
Simplified91.0%
if -2.4000000000000002e122 < x < 5.2000000000000001e112Initial program 89.7%
Taylor expanded in i around 0
associate--r+N/A
+-commutativeN/A
associate--l+N/A
+-commutativeN/A
associate--l+N/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
distribute-rgt-out--N/A
accelerator-lowering-fma.f64N/A
Simplified84.8%
if 5.2000000000000001e112 < x Initial program 73.5%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6490.6
Simplified90.6%
Final simplification86.9%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= t_1 -5e+202)
(fma j (* k -27.0) (* -4.0 (* t a)))
(if (<= t_1 1e+193)
(fma b c (* -4.0 (fma a t (* x i))))
(fma (* x i) -4.0 (* k (* j -27.0)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -5e+202) {
tmp = fma(j, (k * -27.0), (-4.0 * (t * a)));
} else if (t_1 <= 1e+193) {
tmp = fma(b, c, (-4.0 * fma(a, t, (x * i))));
} else {
tmp = fma((x * i), -4.0, (k * (j * -27.0)));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_1 <= -5e+202) tmp = fma(j, Float64(k * -27.0), Float64(-4.0 * Float64(t * a))); elseif (t_1 <= 1e+193) tmp = fma(b, c, Float64(-4.0 * fma(a, t, Float64(x * i)))); else tmp = fma(Float64(x * i), -4.0, Float64(k * Float64(j * -27.0))); end return tmp end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$1, -5e+202], N[(j * N[(k * -27.0), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e+193], N[(b * c + N[(-4.0 * N[(a * t + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * i), $MachinePrecision] * -4.0 + 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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{+202}:\\
\;\;\;\;\mathsf{fma}\left(j, k \cdot -27, -4 \cdot \left(t \cdot a\right)\right)\\
\mathbf{elif}\;t\_1 \leq 10^{+193}:\\
\;\;\;\;\mathsf{fma}\left(b, c, -4 \cdot \mathsf{fma}\left(a, t, x \cdot i\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot i, -4, k \cdot \left(j \cdot -27\right)\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.9999999999999999e202Initial program 74.4%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6474.5
Simplified74.5%
Taylor expanded in b around 0
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6474.9
Simplified74.9%
if -4.9999999999999999e202 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 1.00000000000000007e193Initial program 85.5%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6471.8
Simplified71.8%
Taylor expanded in j around 0
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f6467.1
Simplified67.1%
if 1.00000000000000007e193 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 85.0%
Taylor expanded in i around inf
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6481.6
Simplified81.6%
sub-negN/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-eval81.6
Applied egg-rr81.6%
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.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 18.0 (* y z))) (t_2 (* x (fma -4.0 i (* t t_1)))))
(if (<= x -6e+99)
t_2
(if (<= x 0.022)
(fma (* t -4.0) a (fma j (* k -27.0) (* b c)))
(if (<= x 1.5e+111) (fma (fma x t_1 (* a -4.0)) t (* b c)) t_2)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 18.0 * (y * z);
double t_2 = x * fma(-4.0, i, (t * t_1));
double tmp;
if (x <= -6e+99) {
tmp = t_2;
} else if (x <= 0.022) {
tmp = fma((t * -4.0), a, fma(j, (k * -27.0), (b * c)));
} else if (x <= 1.5e+111) {
tmp = fma(fma(x, t_1, (a * -4.0)), t, (b * c));
} else {
tmp = t_2;
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(18.0 * Float64(y * z)) t_2 = Float64(x * fma(-4.0, i, Float64(t * t_1))) tmp = 0.0 if (x <= -6e+99) tmp = t_2; elseif (x <= 0.022) tmp = fma(Float64(t * -4.0), a, fma(j, Float64(k * -27.0), Float64(b * c))); elseif (x <= 1.5e+111) tmp = fma(fma(x, t_1, Float64(a * -4.0)), t, Float64(b * c)); else tmp = t_2; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(-4.0 * i + N[(t * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6e+99], t$95$2, If[LessEqual[x, 0.022], N[(N[(t * -4.0), $MachinePrecision] * a + N[(j * N[(k * -27.0), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.5e+111], N[(N[(x * t$95$1 + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(y \cdot z\right)\\
t_2 := x \cdot \mathsf{fma}\left(-4, i, t \cdot t\_1\right)\\
\mathbf{if}\;x \leq -6 \cdot 10^{+99}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq 0.022:\\
\;\;\;\;\mathsf{fma}\left(t \cdot -4, a, \mathsf{fma}\left(j, k \cdot -27, b \cdot c\right)\right)\\
\mathbf{elif}\;x \leq 1.5 \cdot 10^{+111}:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(x, t\_1, a \cdot -4\right), t, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if x < -6.00000000000000029e99 or 1.5e111 < x Initial program 74.5%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6483.8
Simplified83.8%
if -6.00000000000000029e99 < x < 0.021999999999999999Initial program 91.1%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6474.3
Simplified74.3%
+-commutativeN/A
associate-+l+N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6477.0
Applied egg-rr77.0%
if 0.021999999999999999 < x < 1.5e111Initial program 76.4%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr88.1%
Taylor expanded in b around inf
*-lowering-*.f6488.2
Simplified88.2%
Final simplification80.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k)))
(if (<= t_1 -5e+202)
(* (* j k) -27.0)
(if (<= t_1 2e+162) (fma -4.0 (* x i) (* b c)) (* k (* j -27.0))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double tmp;
if (t_1 <= -5e+202) {
tmp = (j * k) * -27.0;
} else if (t_1 <= 2e+162) {
tmp = fma(-4.0, (x * i), (b * c));
} else {
tmp = k * (j * -27.0);
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_1 <= -5e+202) tmp = Float64(Float64(j * k) * -27.0); elseif (t_1 <= 2e+162) tmp = fma(-4.0, Float64(x * i), Float64(b * c)); else tmp = Float64(k * Float64(j * -27.0)); end return tmp end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$1, -5e+202], N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision], If[LessEqual[t$95$1, 2e+162], N[(-4.0 * N[(x * i), $MachinePrecision] + N[(b * c), $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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{+202}:\\
\;\;\;\;\left(j \cdot k\right) \cdot -27\\
\mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+162}:\\
\;\;\;\;\mathsf{fma}\left(-4, x \cdot i, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.9999999999999999e202Initial program 74.4%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6483.8
Simplified83.8%
Taylor expanded in j around inf
*-lowering-*.f64N/A
*-lowering-*.f6468.5
Simplified68.5%
if -4.9999999999999999e202 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 1.9999999999999999e162Initial program 85.0%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr87.5%
Taylor expanded in t around 0
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6454.2
Simplified54.2%
Taylor expanded in j around 0
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6450.3
Simplified50.3%
if 1.9999999999999999e162 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 88.1%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr85.2%
Taylor expanded in j around inf
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6463.0
Simplified63.0%
Final simplification54.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (fma (fma (* (* x 18.0) z) y (* a -4.0)) t (* b c))))
(if (<= t -2e+100)
t_1
(if (<= t 4.7e+45)
(fma b c (fma -4.0 (fma a t (* x i)) (* j (* k -27.0))))
t_1))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = fma(fma(((x * 18.0) * z), y, (a * -4.0)), t, (b * c));
double tmp;
if (t <= -2e+100) {
tmp = t_1;
} else if (t <= 4.7e+45) {
tmp = fma(b, c, fma(-4.0, fma(a, t, (x * i)), (j * (k * -27.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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = fma(fma(Float64(Float64(x * 18.0) * z), y, Float64(a * -4.0)), t, Float64(b * c)) tmp = 0.0 if (t <= -2e+100) tmp = t_1; elseif (t <= 4.7e+45) tmp = fma(b, c, fma(-4.0, fma(a, t, Float64(x * i)), Float64(j * Float64(k * -27.0)))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(N[(x * 18.0), $MachinePrecision] * z), $MachinePrecision] * y + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2e+100], t$95$1, If[LessEqual[t, 4.7e+45], N[(b * c + N[(-4.0 * N[(a * t + N[(x * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\mathsf{fma}\left(\left(x \cdot 18\right) \cdot z, y, a \cdot -4\right), t, b \cdot c\right)\\
\mathbf{if}\;t \leq -2 \cdot 10^{+100}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 4.7 \cdot 10^{+45}:\\
\;\;\;\;\mathsf{fma}\left(b, c, \mathsf{fma}\left(-4, \mathsf{fma}\left(a, t, x \cdot i\right), j \cdot \left(k \cdot -27\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -2.00000000000000003e100 or 4.70000000000000002e45 < t Initial program 82.4%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr89.7%
Taylor expanded in b around inf
*-lowering-*.f6480.0
Simplified80.0%
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6482.8
Applied egg-rr82.8%
if -2.00000000000000003e100 < t < 4.70000000000000002e45Initial program 85.4%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6484.0
Simplified84.0%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= y -1e+136)
(* x (fma -4.0 i (* t (* 18.0 (* y z)))))
(if (<= y -1.22e-175)
(fma b c (* -4.0 (fma a t (* x i))))
(if (<= y 2.3e-85)
(fma (* x i) -4.0 (* k (* j -27.0)))
(* t (fma -4.0 a (* z (* 18.0 (* x y)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (y <= -1e+136) {
tmp = x * fma(-4.0, i, (t * (18.0 * (y * z))));
} else if (y <= -1.22e-175) {
tmp = fma(b, c, (-4.0 * fma(a, t, (x * i))));
} else if (y <= 2.3e-85) {
tmp = fma((x * i), -4.0, (k * (j * -27.0)));
} else {
tmp = t * fma(-4.0, a, (z * (18.0 * (x * y))));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (y <= -1e+136) tmp = Float64(x * fma(-4.0, i, Float64(t * Float64(18.0 * Float64(y * z))))); elseif (y <= -1.22e-175) tmp = fma(b, c, Float64(-4.0 * fma(a, t, Float64(x * i)))); elseif (y <= 2.3e-85) tmp = fma(Float64(x * i), -4.0, Float64(k * Float64(j * -27.0))); else tmp = Float64(t * fma(-4.0, a, Float64(z * Float64(18.0 * Float64(x * y))))); 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, -1e+136], N[(x * N[(-4.0 * i + N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.22e-175], N[(b * c + N[(-4.0 * N[(a * t + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.3e-85], N[(N[(x * i), $MachinePrecision] * -4.0 + N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(-4.0 * a + N[(z * N[(18.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \cdot 10^{+136}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(-4, i, t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{elif}\;y \leq -1.22 \cdot 10^{-175}:\\
\;\;\;\;\mathsf{fma}\left(b, c, -4 \cdot \mathsf{fma}\left(a, t, x \cdot i\right)\right)\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{-85}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot i, -4, k \cdot \left(j \cdot -27\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \mathsf{fma}\left(-4, a, z \cdot \left(18 \cdot \left(x \cdot y\right)\right)\right)\\
\end{array}
\end{array}
if y < -1.00000000000000006e136Initial program 76.9%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6459.6
Simplified59.6%
if -1.00000000000000006e136 < y < -1.2200000000000001e-175Initial program 79.3%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6470.8
Simplified70.8%
Taylor expanded in j around 0
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f6466.3
Simplified66.3%
if -1.2200000000000001e-175 < y < 2.3e-85Initial program 96.6%
Taylor expanded in i around inf
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6458.9
Simplified58.9%
sub-negN/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-eval58.9
Applied egg-rr58.9%
if 2.3e-85 < y Initial program 82.4%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr81.3%
Taylor expanded in t around inf
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6452.3
Simplified52.3%
Final simplification58.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (let* ((t_1 (* (* j k) -27.0)) (t_2 (* (* j 27.0) k))) (if (<= t_2 -4e+174) t_1 (if (<= t_2 5e+122) (* b c) t_1))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * k) * -27.0;
double t_2 = (j * 27.0) * k;
double tmp;
if (t_2 <= -4e+174) {
tmp = t_1;
} else if (t_2 <= 5e+122) {
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.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (j * k) * (-27.0d0)
t_2 = (j * 27.0d0) * k
if (t_2 <= (-4d+174)) then
tmp = t_1
else if (t_2 <= 5d+122) 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;
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 = (j * 27.0) * k;
double tmp;
if (t_2 <= -4e+174) {
tmp = t_1;
} else if (t_2 <= 5e+122) {
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]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = (j * k) * -27.0 t_2 = (j * 27.0) * k tmp = 0 if t_2 <= -4e+174: tmp = t_1 elif t_2 <= 5e+122: 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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * k) * -27.0) t_2 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_2 <= -4e+174) tmp = t_1; elseif (t_2 <= 5e+122) 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])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = (j * k) * -27.0;
t_2 = (j * 27.0) * k;
tmp = 0.0;
if (t_2 <= -4e+174)
tmp = t_1;
elseif (t_2 <= 5e+122)
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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$2, -4e+174], t$95$1, If[LessEqual[t$95$2, 5e+122], 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])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot k\right) \cdot -27\\
t_2 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_2 \leq -4 \cdot 10^{+174}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+122}:\\
\;\;\;\;b \cdot c\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.00000000000000028e174 or 4.99999999999999989e122 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) Initial program 83.3%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6483.5
Simplified83.5%
Taylor expanded in j around inf
*-lowering-*.f64N/A
*-lowering-*.f6461.1
Simplified61.1%
if -4.00000000000000028e174 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 4.99999999999999989e122Initial program 84.5%
Taylor expanded in b around inf
*-lowering-*.f6428.5
Simplified28.5%
Final simplification37.6%
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))))
(if (<= c -2600000.0)
(* b c)
(if (<= c -1.2e-189)
(* k (* j -27.0))
(if (<= c 3.1e-137)
t_1
(if (<= c 5.4e+38)
(* -4.0 (* t a))
(if (<= c 9e+151) t_1 (* b c))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (x * i);
double tmp;
if (c <= -2600000.0) {
tmp = b * c;
} else if (c <= -1.2e-189) {
tmp = k * (j * -27.0);
} else if (c <= 3.1e-137) {
tmp = t_1;
} else if (c <= 5.4e+38) {
tmp = -4.0 * (t * a);
} else if (c <= 9e+151) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (x * i)
if (c <= (-2600000.0d0)) then
tmp = b * c
else if (c <= (-1.2d-189)) then
tmp = k * (j * (-27.0d0))
else if (c <= 3.1d-137) then
tmp = t_1
else if (c <= 5.4d+38) then
tmp = (-4.0d0) * (t * a)
else if (c <= 9d+151) then
tmp = t_1
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
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 tmp;
if (c <= -2600000.0) {
tmp = b * c;
} else if (c <= -1.2e-189) {
tmp = k * (j * -27.0);
} else if (c <= 3.1e-137) {
tmp = t_1;
} else if (c <= 5.4e+38) {
tmp = -4.0 * (t * a);
} else if (c <= 9e+151) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (x * i) tmp = 0 if c <= -2600000.0: tmp = b * c elif c <= -1.2e-189: tmp = k * (j * -27.0) elif c <= 3.1e-137: tmp = t_1 elif c <= 5.4e+38: tmp = -4.0 * (t * a) elif c <= 9e+151: tmp = t_1 else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(x * i)) tmp = 0.0 if (c <= -2600000.0) tmp = Float64(b * c); elseif (c <= -1.2e-189) tmp = Float64(k * Float64(j * -27.0)); elseif (c <= 3.1e-137) tmp = t_1; elseif (c <= 5.4e+38) tmp = Float64(-4.0 * Float64(t * a)); elseif (c <= 9e+151) tmp = t_1; else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = -4.0 * (x * i);
tmp = 0.0;
if (c <= -2600000.0)
tmp = b * c;
elseif (c <= -1.2e-189)
tmp = k * (j * -27.0);
elseif (c <= 3.1e-137)
tmp = t_1;
elseif (c <= 5.4e+38)
tmp = -4.0 * (t * a);
elseif (c <= 9e+151)
tmp = t_1;
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[c, -2600000.0], N[(b * c), $MachinePrecision], If[LessEqual[c, -1.2e-189], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 3.1e-137], t$95$1, If[LessEqual[c, 5.4e+38], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 9e+151], t$95$1, N[(b * c), $MachinePrecision]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \left(x \cdot i\right)\\
\mathbf{if}\;c \leq -2600000:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;c \leq -1.2 \cdot 10^{-189}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\
\mathbf{elif}\;c \leq 3.1 \cdot 10^{-137}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;c \leq 5.4 \cdot 10^{+38}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;c \leq 9 \cdot 10^{+151}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if c < -2.6e6 or 8.9999999999999997e151 < c Initial program 81.6%
Taylor expanded in b around inf
*-lowering-*.f6450.2
Simplified50.2%
if -2.6e6 < c < -1.1999999999999999e-189Initial program 91.2%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr88.9%
Taylor expanded in j around inf
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6437.7
Simplified37.7%
if -1.1999999999999999e-189 < c < 3.09999999999999978e-137 or 5.39999999999999992e38 < c < 8.9999999999999997e151Initial program 85.7%
Taylor expanded in i around inf
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6438.0
Simplified38.0%
if 3.09999999999999978e-137 < c < 5.39999999999999992e38Initial program 75.3%
Taylor expanded in a around inf
*-lowering-*.f64N/A
*-lowering-*.f6433.7
Simplified33.7%
Final simplification41.6%
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))))
(if (<= c -180000000.0)
(* b c)
(if (<= c -2.7e-192)
(* (* j k) -27.0)
(if (<= c 9.8e-138)
t_1
(if (<= c 5.8e+38)
(* -4.0 (* t a))
(if (<= c 5e+151) t_1 (* b c))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (x * i);
double tmp;
if (c <= -180000000.0) {
tmp = b * c;
} else if (c <= -2.7e-192) {
tmp = (j * k) * -27.0;
} else if (c <= 9.8e-138) {
tmp = t_1;
} else if (c <= 5.8e+38) {
tmp = -4.0 * (t * a);
} else if (c <= 5e+151) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (x * i)
if (c <= (-180000000.0d0)) then
tmp = b * c
else if (c <= (-2.7d-192)) then
tmp = (j * k) * (-27.0d0)
else if (c <= 9.8d-138) then
tmp = t_1
else if (c <= 5.8d+38) then
tmp = (-4.0d0) * (t * a)
else if (c <= 5d+151) then
tmp = t_1
else
tmp = b * c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
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 tmp;
if (c <= -180000000.0) {
tmp = b * c;
} else if (c <= -2.7e-192) {
tmp = (j * k) * -27.0;
} else if (c <= 9.8e-138) {
tmp = t_1;
} else if (c <= 5.8e+38) {
tmp = -4.0 * (t * a);
} else if (c <= 5e+151) {
tmp = t_1;
} else {
tmp = b * c;
}
return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (x * i) tmp = 0 if c <= -180000000.0: tmp = b * c elif c <= -2.7e-192: tmp = (j * k) * -27.0 elif c <= 9.8e-138: tmp = t_1 elif c <= 5.8e+38: tmp = -4.0 * (t * a) elif c <= 5e+151: tmp = t_1 else: tmp = b * c return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(x * i)) tmp = 0.0 if (c <= -180000000.0) tmp = Float64(b * c); elseif (c <= -2.7e-192) tmp = Float64(Float64(j * k) * -27.0); elseif (c <= 9.8e-138) tmp = t_1; elseif (c <= 5.8e+38) tmp = Float64(-4.0 * Float64(t * a)); elseif (c <= 5e+151) tmp = t_1; else tmp = Float64(b * c); end return tmp end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
t_1 = -4.0 * (x * i);
tmp = 0.0;
if (c <= -180000000.0)
tmp = b * c;
elseif (c <= -2.7e-192)
tmp = (j * k) * -27.0;
elseif (c <= 9.8e-138)
tmp = t_1;
elseif (c <= 5.8e+38)
tmp = -4.0 * (t * a);
elseif (c <= 5e+151)
tmp = t_1;
else
tmp = b * c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[c, -180000000.0], N[(b * c), $MachinePrecision], If[LessEqual[c, -2.7e-192], N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision], If[LessEqual[c, 9.8e-138], t$95$1, If[LessEqual[c, 5.8e+38], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 5e+151], t$95$1, N[(b * c), $MachinePrecision]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \left(x \cdot i\right)\\
\mathbf{if}\;c \leq -180000000:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;c \leq -2.7 \cdot 10^{-192}:\\
\;\;\;\;\left(j \cdot k\right) \cdot -27\\
\mathbf{elif}\;c \leq 9.8 \cdot 10^{-138}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;c \leq 5.8 \cdot 10^{+38}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;c \leq 5 \cdot 10^{+151}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if c < -1.8e8 or 5.0000000000000002e151 < c Initial program 81.6%
Taylor expanded in b around inf
*-lowering-*.f6450.2
Simplified50.2%
if -1.8e8 < c < -2.69999999999999991e-192Initial program 89.5%
Taylor expanded in y around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
associate-+r+N/A
distribute-neg-inN/A
distribute-lft-outN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6487.1
Simplified87.1%
Taylor expanded in j around inf
*-lowering-*.f64N/A
*-lowering-*.f6436.2
Simplified36.2%
if -2.69999999999999991e-192 < c < 9.80000000000000033e-138 or 5.80000000000000013e38 < c < 5.0000000000000002e151Initial program 86.3%
Taylor expanded in i around inf
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6439.1
Simplified39.1%
if 9.80000000000000033e-138 < c < 5.80000000000000013e38Initial program 76.2%
Taylor expanded in a around inf
*-lowering-*.f64N/A
*-lowering-*.f6432.6
Simplified32.6%
Final simplification41.6%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= y -2.7e+63)
(* z (* (* x y) (* 18.0 t)))
(if (<= y -1.7e-139)
(fma (* a -4.0) t (* b c))
(if (<= y 1.22e+40)
(fma j (* k -27.0) (* -4.0 (* t a)))
(* (* x y) (* z (* 18.0 t)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (y <= -2.7e+63) {
tmp = z * ((x * y) * (18.0 * t));
} else if (y <= -1.7e-139) {
tmp = fma((a * -4.0), t, (b * c));
} else if (y <= 1.22e+40) {
tmp = fma(j, (k * -27.0), (-4.0 * (t * a)));
} else {
tmp = (x * y) * (z * (18.0 * t));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (y <= -2.7e+63) tmp = Float64(z * Float64(Float64(x * y) * Float64(18.0 * t))); elseif (y <= -1.7e-139) tmp = fma(Float64(a * -4.0), t, Float64(b * c)); elseif (y <= 1.22e+40) tmp = fma(j, Float64(k * -27.0), Float64(-4.0 * Float64(t * a))); else tmp = Float64(Float64(x * y) * Float64(z * Float64(18.0 * t))); 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, -2.7e+63], N[(z * N[(N[(x * y), $MachinePrecision] * N[(18.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.7e-139], N[(N[(a * -4.0), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.22e+40], N[(j * N[(k * -27.0), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * y), $MachinePrecision] * N[(z * N[(18.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.7 \cdot 10^{+63}:\\
\;\;\;\;z \cdot \left(\left(x \cdot y\right) \cdot \left(18 \cdot t\right)\right)\\
\mathbf{elif}\;y \leq -1.7 \cdot 10^{-139}:\\
\;\;\;\;\mathsf{fma}\left(a \cdot -4, t, b \cdot c\right)\\
\mathbf{elif}\;y \leq 1.22 \cdot 10^{+40}:\\
\;\;\;\;\mathsf{fma}\left(j, k \cdot -27, -4 \cdot \left(t \cdot a\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot y\right) \cdot \left(z \cdot \left(18 \cdot t\right)\right)\\
\end{array}
\end{array}
if y < -2.70000000000000017e63Initial program 75.0%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6445.7
Simplified45.7%
associate-*r*N/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6448.8
Applied egg-rr48.8%
if -2.70000000000000017e63 < y < -1.69999999999999999e-139Initial program 79.3%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr85.6%
Taylor expanded in b around inf
*-lowering-*.f6473.6
Simplified73.6%
Taylor expanded in x around 0
*-lowering-*.f6459.5
Simplified59.5%
if -1.69999999999999999e-139 < y < 1.22000000000000004e40Initial program 90.2%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6460.0
Simplified60.0%
Taylor expanded in b around 0
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6442.7
Simplified42.7%
if 1.22000000000000004e40 < y Initial program 85.1%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6446.3
Simplified46.3%
associate-*r*N/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6451.0
Applied egg-rr51.0%
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f6447.8
Applied egg-rr47.8%
Final simplification48.2%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (fma -4.0 i (* t (* 18.0 (* y z)))))))
(if (<= x -4.2e+101)
t_1
(if (<= x 1.4e+41) (fma (* t -4.0) a (fma j (* k -27.0) (* b c))) t_1))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * fma(-4.0, i, (t * (18.0 * (y * z))));
double tmp;
if (x <= -4.2e+101) {
tmp = t_1;
} else if (x <= 1.4e+41) {
tmp = fma((t * -4.0), a, fma(j, (k * -27.0), (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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * fma(-4.0, i, Float64(t * Float64(18.0 * Float64(y * z))))) tmp = 0.0 if (x <= -4.2e+101) tmp = t_1; elseif (x <= 1.4e+41) tmp = fma(Float64(t * -4.0), a, fma(j, Float64(k * -27.0), Float64(b * c))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(-4.0 * i + N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -4.2e+101], t$95$1, If[LessEqual[x, 1.4e+41], N[(N[(t * -4.0), $MachinePrecision] * a + N[(j * N[(k * -27.0), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \mathsf{fma}\left(-4, i, t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{if}\;x \leq -4.2 \cdot 10^{+101}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 1.4 \cdot 10^{+41}:\\
\;\;\;\;\mathsf{fma}\left(t \cdot -4, a, \mathsf{fma}\left(j, k \cdot -27, b \cdot c\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -4.2e101 or 1.4e41 < x Initial program 73.8%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6480.3
Simplified80.3%
if -4.2e101 < x < 1.4e41Initial program 91.3%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6474.3
Simplified74.3%
+-commutativeN/A
associate-+l+N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6477.0
Applied egg-rr77.0%
Final simplification78.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (fma -4.0 i (* t (* 18.0 (* y z)))))))
(if (<= x -5.4e+99)
t_1
(if (<= x 2.1e+41) (fma b c (fma (* j k) -27.0 (* 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);
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 * fma(-4.0, i, (t * (18.0 * (y * z))));
double tmp;
if (x <= -5.4e+99) {
tmp = t_1;
} else if (x <= 2.1e+41) {
tmp = fma(b, c, fma((j * k), -27.0, (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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * fma(-4.0, i, Float64(t * Float64(18.0 * Float64(y * z))))) tmp = 0.0 if (x <= -5.4e+99) tmp = t_1; elseif (x <= 2.1e+41) tmp = fma(b, c, fma(Float64(j * k), -27.0, Float64(t * Float64(a * -4.0)))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(-4.0 * i + N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.4e+99], t$95$1, If[LessEqual[x, 2.1e+41], N[(b * c + N[(N[(j * k), $MachinePrecision] * -27.0 + N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \mathsf{fma}\left(-4, i, t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{if}\;x \leq -5.4 \cdot 10^{+99}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+41}:\\
\;\;\;\;\mathsf{fma}\left(b, c, \mathsf{fma}\left(j \cdot k, -27, t \cdot \left(a \cdot -4\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -5.39999999999999978e99 or 2.1e41 < x Initial program 73.8%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6480.3
Simplified80.3%
if -5.39999999999999978e99 < x < 2.1e41Initial program 91.3%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6474.3
Simplified74.3%
+-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6474.3
Applied egg-rr74.3%
Final simplification76.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* x (fma -4.0 i (* t (* 18.0 (* y z)))))))
(if (<= x -2.7e+102)
t_1
(if (<= x 6e+38) (fma b c (fma -4.0 (* t a) (* j (* k -27.0)))) t_1))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = x * fma(-4.0, i, (t * (18.0 * (y * z))));
double tmp;
if (x <= -2.7e+102) {
tmp = t_1;
} else if (x <= 6e+38) {
tmp = fma(b, c, fma(-4.0, (t * a), (j * (k * -27.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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(x * fma(-4.0, i, Float64(t * Float64(18.0 * Float64(y * z))))) tmp = 0.0 if (x <= -2.7e+102) tmp = t_1; elseif (x <= 6e+38) tmp = fma(b, c, fma(-4.0, Float64(t * a), Float64(j * Float64(k * -27.0)))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(x * N[(-4.0 * i + N[(t * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.7e+102], t$95$1, If[LessEqual[x, 6e+38], N[(b * c + N[(-4.0 * N[(t * a), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := x \cdot \mathsf{fma}\left(-4, i, t \cdot \left(18 \cdot \left(y \cdot z\right)\right)\right)\\
\mathbf{if}\;x \leq -2.7 \cdot 10^{+102}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+38}:\\
\;\;\;\;\mathsf{fma}\left(b, c, \mathsf{fma}\left(-4, t \cdot a, j \cdot \left(k \cdot -27\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -2.7000000000000001e102 or 6.0000000000000002e38 < x Initial program 73.8%
Taylor expanded in x around inf
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6480.3
Simplified80.3%
if -2.7000000000000001e102 < x < 6.0000000000000002e38Initial program 91.3%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6474.3
Simplified74.3%
Final simplification76.8%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= y -2e+63)
(* z (* (* x y) (* 18.0 t)))
(if (<= y -8.2e-172)
(fma (* a -4.0) t (* b c))
(if (<= y 1.9e+46)
(- (* b c) (* 27.0 (* j k)))
(* (* x y) (* z (* 18.0 t)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (y <= -2e+63) {
tmp = z * ((x * y) * (18.0 * t));
} else if (y <= -8.2e-172) {
tmp = fma((a * -4.0), t, (b * c));
} else if (y <= 1.9e+46) {
tmp = (b * c) - (27.0 * (j * k));
} else {
tmp = (x * y) * (z * (18.0 * t));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (y <= -2e+63) tmp = Float64(z * Float64(Float64(x * y) * Float64(18.0 * t))); elseif (y <= -8.2e-172) tmp = fma(Float64(a * -4.0), t, Float64(b * c)); elseif (y <= 1.9e+46) tmp = Float64(Float64(b * c) - Float64(27.0 * Float64(j * k))); else tmp = Float64(Float64(x * y) * Float64(z * Float64(18.0 * t))); 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, -2e+63], N[(z * N[(N[(x * y), $MachinePrecision] * N[(18.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -8.2e-172], N[(N[(a * -4.0), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.9e+46], N[(N[(b * c), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * y), $MachinePrecision] * N[(z * N[(18.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2 \cdot 10^{+63}:\\
\;\;\;\;z \cdot \left(\left(x \cdot y\right) \cdot \left(18 \cdot t\right)\right)\\
\mathbf{elif}\;y \leq -8.2 \cdot 10^{-172}:\\
\;\;\;\;\mathsf{fma}\left(a \cdot -4, t, b \cdot c\right)\\
\mathbf{elif}\;y \leq 1.9 \cdot 10^{+46}:\\
\;\;\;\;b \cdot c - 27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot y\right) \cdot \left(z \cdot \left(18 \cdot t\right)\right)\\
\end{array}
\end{array}
if y < -2.00000000000000012e63Initial program 75.0%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6445.7
Simplified45.7%
associate-*r*N/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6448.8
Applied egg-rr48.8%
if -2.00000000000000012e63 < y < -8.2e-172Initial program 81.6%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr87.2%
Taylor expanded in b around inf
*-lowering-*.f6472.6
Simplified72.6%
Taylor expanded in x around 0
*-lowering-*.f6460.0
Simplified60.0%
if -8.2e-172 < y < 1.9e46Initial program 89.7%
Taylor expanded in b around inf
*-lowering-*.f6442.2
Simplified42.2%
--lowering--.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f6442.2
Applied egg-rr42.2%
if 1.9e46 < y Initial program 84.8%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6445.4
Simplified45.4%
associate-*r*N/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6450.2
Applied egg-rr50.2%
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f6446.9
Applied egg-rr46.9%
Final simplification48.3%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= y -2.7e+63)
(* 18.0 (* z (* t (* x y))))
(if (<= y -2.3e-174)
(fma (* a -4.0) t (* b c))
(if (<= y 1.3e+43)
(- (* b c) (* 27.0 (* j k)))
(* (* x y) (* z (* 18.0 t)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (y <= -2.7e+63) {
tmp = 18.0 * (z * (t * (x * y)));
} else if (y <= -2.3e-174) {
tmp = fma((a * -4.0), t, (b * c));
} else if (y <= 1.3e+43) {
tmp = (b * c) - (27.0 * (j * k));
} else {
tmp = (x * y) * (z * (18.0 * t));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (y <= -2.7e+63) tmp = Float64(18.0 * Float64(z * Float64(t * Float64(x * y)))); elseif (y <= -2.3e-174) tmp = fma(Float64(a * -4.0), t, Float64(b * c)); elseif (y <= 1.3e+43) tmp = Float64(Float64(b * c) - Float64(27.0 * Float64(j * k))); else tmp = Float64(Float64(x * y) * Float64(z * Float64(18.0 * t))); 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. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, -2.7e+63], N[(18.0 * N[(z * N[(t * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.3e-174], N[(N[(a * -4.0), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.3e+43], N[(N[(b * c), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * y), $MachinePrecision] * N[(z * N[(18.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.7 \cdot 10^{+63}:\\
\;\;\;\;18 \cdot \left(z \cdot \left(t \cdot \left(x \cdot y\right)\right)\right)\\
\mathbf{elif}\;y \leq -2.3 \cdot 10^{-174}:\\
\;\;\;\;\mathsf{fma}\left(a \cdot -4, t, b \cdot c\right)\\
\mathbf{elif}\;y \leq 1.3 \cdot 10^{+43}:\\
\;\;\;\;b \cdot c - 27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot y\right) \cdot \left(z \cdot \left(18 \cdot t\right)\right)\\
\end{array}
\end{array}
if y < -2.70000000000000017e63Initial program 75.0%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6445.7
Simplified45.7%
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6448.7
Applied egg-rr48.7%
if -2.70000000000000017e63 < y < -2.2999999999999999e-174Initial program 81.6%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr87.2%
Taylor expanded in b around inf
*-lowering-*.f6472.6
Simplified72.6%
Taylor expanded in x around 0
*-lowering-*.f6460.0
Simplified60.0%
if -2.2999999999999999e-174 < y < 1.3000000000000001e43Initial program 89.6%
Taylor expanded in b around inf
*-lowering-*.f6442.6
Simplified42.6%
--lowering--.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f6442.6
Applied egg-rr42.6%
if 1.3000000000000001e43 < y Initial program 85.1%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6446.3
Simplified46.3%
associate-*r*N/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6451.0
Applied egg-rr51.0%
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f6447.8
Applied egg-rr47.8%
Final simplification48.6%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 18.0 (* z (* t (* x y))))))
(if (<= y -8.6e+62)
t_1
(if (<= y -1.45e-174)
(fma (* a -4.0) t (* b c))
(if (<= y 3.25e+40) (- (* b c) (* 27.0 (* j k))) t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 18.0 * (z * (t * (x * y)));
double tmp;
if (y <= -8.6e+62) {
tmp = t_1;
} else if (y <= -1.45e-174) {
tmp = fma((a * -4.0), t, (b * c));
} else if (y <= 3.25e+40) {
tmp = (b * c) - (27.0 * (j * k));
} else {
tmp = t_1;
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(18.0 * Float64(z * Float64(t * Float64(x * y)))) tmp = 0.0 if (y <= -8.6e+62) tmp = t_1; elseif (y <= -1.45e-174) tmp = fma(Float64(a * -4.0), t, Float64(b * c)); elseif (y <= 3.25e+40) tmp = Float64(Float64(b * c) - Float64(27.0 * Float64(j * k))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(z * N[(t * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -8.6e+62], t$95$1, If[LessEqual[y, -1.45e-174], N[(N[(a * -4.0), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.25e+40], N[(N[(b * c), $MachinePrecision] - N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(z \cdot \left(t \cdot \left(x \cdot y\right)\right)\right)\\
\mathbf{if}\;y \leq -8.6 \cdot 10^{+62}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.45 \cdot 10^{-174}:\\
\;\;\;\;\mathsf{fma}\left(a \cdot -4, t, b \cdot c\right)\\
\mathbf{elif}\;y \leq 3.25 \cdot 10^{+40}:\\
\;\;\;\;b \cdot c - 27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -8.5999999999999994e62 or 3.2500000000000001e40 < y Initial program 80.6%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6446.0
Simplified46.0%
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6450.0
Applied egg-rr50.0%
if -8.5999999999999994e62 < y < -1.45000000000000005e-174Initial program 81.6%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr87.2%
Taylor expanded in b around inf
*-lowering-*.f6472.6
Simplified72.6%
Taylor expanded in x around 0
*-lowering-*.f6460.0
Simplified60.0%
if -1.45000000000000005e-174 < y < 3.2500000000000001e40Initial program 89.6%
Taylor expanded in b around inf
*-lowering-*.f6442.6
Simplified42.6%
--lowering--.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f6442.6
Applied egg-rr42.6%
Final simplification49.4%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (fma (* a -4.0) t (* b c))))
(if (<= (* a 4.0) -2e+35)
t_1
(if (<= (* a 4.0) 4e+110) (fma -4.0 (* x i) (* b c)) t_1))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = fma((a * -4.0), t, (b * c));
double tmp;
if ((a * 4.0) <= -2e+35) {
tmp = t_1;
} else if ((a * 4.0) <= 4e+110) {
tmp = fma(-4.0, (x * i), (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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = fma(Float64(a * -4.0), t, Float64(b * c)) tmp = 0.0 if (Float64(a * 4.0) <= -2e+35) tmp = t_1; elseif (Float64(a * 4.0) <= 4e+110) tmp = fma(-4.0, Float64(x * i), Float64(b * c)); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(a * -4.0), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 4.0), $MachinePrecision], -2e+35], t$95$1, If[LessEqual[N[(a * 4.0), $MachinePrecision], 4e+110], N[(-4.0 * N[(x * i), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(a \cdot -4, t, b \cdot c\right)\\
\mathbf{if}\;a \cdot 4 \leq -2 \cdot 10^{+35}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 4 \leq 4 \cdot 10^{+110}:\\
\;\;\;\;\mathsf{fma}\left(-4, x \cdot i, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (*.f64 a #s(literal 4 binary64)) < -1.9999999999999999e35 or 4.0000000000000001e110 < (*.f64 a #s(literal 4 binary64)) Initial program 78.3%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr84.9%
Taylor expanded in b around inf
*-lowering-*.f6474.3
Simplified74.3%
Taylor expanded in x around 0
*-lowering-*.f6462.5
Simplified62.5%
if -1.9999999999999999e35 < (*.f64 a #s(literal 4 binary64)) < 4.0000000000000001e110Initial program 87.4%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr87.3%
Taylor expanded in t around 0
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6470.6
Simplified70.6%
Taylor expanded in j around 0
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6453.2
Simplified53.2%
Final simplification56.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (fma b c (* -4.0 (* t a)))))
(if (<= (* a 4.0) -2e+35)
t_1
(if (<= (* a 4.0) 4e+110) (fma -4.0 (* x i) (* b c)) t_1))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = fma(b, c, (-4.0 * (t * a)));
double tmp;
if ((a * 4.0) <= -2e+35) {
tmp = t_1;
} else if ((a * 4.0) <= 4e+110) {
tmp = fma(-4.0, (x * i), (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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = fma(b, c, Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (Float64(a * 4.0) <= -2e+35) tmp = t_1; elseif (Float64(a * 4.0) <= 4e+110) tmp = fma(-4.0, Float64(x * i), Float64(b * c)); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(b * c + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 4.0), $MachinePrecision], -2e+35], t$95$1, If[LessEqual[N[(a * 4.0), $MachinePrecision], 4e+110], N[(-4.0 * N[(x * i), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(b, c, -4 \cdot \left(t \cdot a\right)\right)\\
\mathbf{if}\;a \cdot 4 \leq -2 \cdot 10^{+35}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 4 \leq 4 \cdot 10^{+110}:\\
\;\;\;\;\mathsf{fma}\left(-4, x \cdot i, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (*.f64 a #s(literal 4 binary64)) < -1.9999999999999999e35 or 4.0000000000000001e110 < (*.f64 a #s(literal 4 binary64)) Initial program 78.3%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6468.9
Simplified68.9%
Taylor expanded in j around 0
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6460.3
Simplified60.3%
if -1.9999999999999999e35 < (*.f64 a #s(literal 4 binary64)) < 4.0000000000000001e110Initial program 87.4%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr87.3%
Taylor expanded in t around 0
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6470.6
Simplified70.6%
Taylor expanded in j around 0
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6453.2
Simplified53.2%
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.
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (fma -4.0 (* x i) (* b c))))
(if (<= i -2.05e+26)
t_1
(if (<= i -3.5e-208)
(fma b c (* -4.0 (* t a)))
(if (<= i 0.033) (fma c b (* k (* j -27.0))) t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = fma(-4.0, (x * i), (b * c));
double tmp;
if (i <= -2.05e+26) {
tmp = t_1;
} else if (i <= -3.5e-208) {
tmp = fma(b, c, (-4.0 * (t * a)));
} else if (i <= 0.033) {
tmp = fma(c, b, (k * (j * -27.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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = fma(-4.0, Float64(x * i), Float64(b * c)) tmp = 0.0 if (i <= -2.05e+26) tmp = t_1; elseif (i <= -3.5e-208) tmp = fma(b, c, Float64(-4.0 * Float64(t * a))); elseif (i <= 0.033) tmp = fma(c, b, Float64(k * Float64(j * -27.0))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(x * i), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[i, -2.05e+26], t$95$1, If[LessEqual[i, -3.5e-208], N[(b * c + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[i, 0.033], N[(c * b + N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(-4, x \cdot i, b \cdot c\right)\\
\mathbf{if}\;i \leq -2.05 \cdot 10^{+26}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;i \leq -3.5 \cdot 10^{-208}:\\
\;\;\;\;\mathsf{fma}\left(b, c, -4 \cdot \left(t \cdot a\right)\right)\\
\mathbf{elif}\;i \leq 0.033:\\
\;\;\;\;\mathsf{fma}\left(c, b, k \cdot \left(j \cdot -27\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if i < -2.04999999999999992e26 or 0.033000000000000002 < i Initial program 81.1%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr82.8%
Taylor expanded in t around 0
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6472.0
Simplified72.0%
Taylor expanded in j around 0
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6464.1
Simplified64.1%
if -2.04999999999999992e26 < i < -3.49999999999999991e-208Initial program 83.0%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6464.4
Simplified64.4%
Taylor expanded in j around 0
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6452.7
Simplified52.7%
if -3.49999999999999991e-208 < i < 0.033000000000000002Initial program 88.7%
Taylor expanded in b around inf
*-lowering-*.f6452.5
Simplified52.5%
sub-negN/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-eval52.6
Applied egg-rr52.6%
Final simplification57.6%
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 (fma -4.0 (* x i) (* b c))))
(if (<= i -9.2e+25)
t_1
(if (<= i -2.3e-208)
(fma b c (* -4.0 (* t a)))
(if (<= i 0.8) (fma b c (* j (* k -27.0))) t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = fma(-4.0, (x * i), (b * c));
double tmp;
if (i <= -9.2e+25) {
tmp = t_1;
} else if (i <= -2.3e-208) {
tmp = fma(b, c, (-4.0 * (t * a)));
} else if (i <= 0.8) {
tmp = fma(b, c, (j * (k * -27.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]) function code(x, y, z, t, a, b, c, i, j, k) t_1 = fma(-4.0, Float64(x * i), Float64(b * c)) tmp = 0.0 if (i <= -9.2e+25) tmp = t_1; elseif (i <= -2.3e-208) tmp = fma(b, c, Float64(-4.0 * Float64(t * a))); elseif (i <= 0.8) tmp = fma(b, c, Float64(j * Float64(k * -27.0))); else tmp = t_1; 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.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(x * i), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[i, -9.2e+25], t$95$1, If[LessEqual[i, -2.3e-208], N[(b * c + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[i, 0.8], N[(b * c + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(-4, x \cdot i, b \cdot c\right)\\
\mathbf{if}\;i \leq -9.2 \cdot 10^{+25}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;i \leq -2.3 \cdot 10^{-208}:\\
\;\;\;\;\mathsf{fma}\left(b, c, -4 \cdot \left(t \cdot a\right)\right)\\
\mathbf{elif}\;i \leq 0.8:\\
\;\;\;\;\mathsf{fma}\left(b, c, j \cdot \left(k \cdot -27\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if i < -9.1999999999999992e25 or 0.80000000000000004 < i Initial program 81.1%
associate--l+N/A
sub-negN/A
associate-+l+N/A
*-commutativeN/A
associate-*r*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
accelerator-lowering-fma.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
Applied egg-rr82.8%
Taylor expanded in t around 0
cancel-sign-sub-invN/A
metadata-evalN/A
+-commutativeN/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6472.0
Simplified72.0%
Taylor expanded in j around 0
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6464.1
Simplified64.1%
if -9.1999999999999992e25 < i < -2.29999999999999997e-208Initial program 83.0%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6464.4
Simplified64.4%
Taylor expanded in j around 0
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6452.7
Simplified52.7%
if -2.29999999999999997e-208 < i < 0.80000000000000004Initial program 88.7%
Taylor expanded in x around 0
sub-negN/A
accelerator-lowering-fma.f64N/A
distribute-neg-inN/A
distribute-lft-neg-inN/A
metadata-evalN/A
distribute-lft-neg-inN/A
metadata-evalN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6465.7
Simplified65.7%
Taylor expanded in a around 0
+-commutativeN/A
accelerator-lowering-fma.f64N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6452.5
Simplified52.5%
Final simplification57.6%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= y -2.1e+63)
(* z (* (* x y) (* 18.0 t)))
(if (<= y -2.3e-135)
(fma (* a -4.0) t (* b c))
(fma (* x i) -4.0 (* k (* j -27.0))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (y <= -2.1e+63) {
tmp = z * ((x * y) * (18.0 * t));
} else if (y <= -2.3e-135) {
tmp = fma((a * -4.0), t, (b * c));
} else {
tmp = fma((x * i), -4.0, (k * (j * -27.0)));
}
return tmp;
}
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (y <= -2.1e+63) tmp = Float64(z * Float64(Float64(x * y) * Float64(18.0 * t))); elseif (y <= -2.3e-135) tmp = fma(Float64(a * -4.0), t, Float64(b * c)); else tmp = fma(Float64(x * i), -4.0, Float64(k * Float64(j * -27.0))); end return tmp end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, -2.1e+63], N[(z * N[(N[(x * y), $MachinePrecision] * N[(18.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.3e-135], N[(N[(a * -4.0), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision], N[(N[(x * i), $MachinePrecision] * -4.0 + 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])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.1 \cdot 10^{+63}:\\
\;\;\;\;z \cdot \left(\left(x \cdot y\right) \cdot \left(18 \cdot t\right)\right)\\
\mathbf{elif}\;y \leq -2.3 \cdot 10^{-135}:\\
\;\;\;\;\mathsf{fma}\left(a \cdot -4, t, b \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot i, -4, k \cdot \left(j \cdot -27\right)\right)\\
\end{array}
\end{array}
if y < -2.1000000000000002e63Initial program 75.0%
Taylor expanded in y around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6445.7
Simplified45.7%
associate-*r*N/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6448.8
Applied egg-rr48.8%
if -2.1000000000000002e63 < y < -2.2999999999999999e-135Initial program 77.9%
associate--l-N/A
associate--l+N/A
distribute-rgt-out--N/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
sub-negN/A
associate-*l*N/A
associate-*l*N/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-evalN/A
--lowering--.f64N/A
*-lowering-*.f64N/A
Applied egg-rr84.6%
Taylor expanded in b around inf
*-lowering-*.f6474.0
Simplified74.0%
Taylor expanded in x around 0
*-lowering-*.f6458.9
Simplified58.9%
if -2.2999999999999999e-135 < y Initial program 88.5%
Taylor expanded in i around inf
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6447.1
Simplified47.1%
sub-negN/A
*-commutativeN/A
accelerator-lowering-fma.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
metadata-eval47.1
Applied egg-rr47.1%
Final simplification49.5%
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i j k) :precision binary64 (* b c))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = b * c
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k]) def code(x, y, z, t, a, b, c, i, j, k): return b * c
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k]) function code(x, y, z, t, a, b, c, i, j, k) return Float64(b * c) end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp = code(x, y, z, t, a, b, c, i, j, k)
tmp = b * c;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(b * c), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
b \cdot c
\end{array}
Initial program 84.1%
Taylor expanded in b around inf
*-lowering-*.f6424.1
Simplified24.1%
(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 2024199
(FPCore (x y z t a b c i j k)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, E"
:precision binary64
:alt
(! :herbie-platform default (if (< t -8105407698770699/5000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- (- (* (* 18 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4)) (- (* (* k j) 27) (* c b))) (if (< t 8284013971902611/50000000000000) (+ (- (* (* 18 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4)) (- (* c b) (* 27 (* k j)))) (- (- (* (* 18 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4)) (- (* (* k j) 27) (* c b))))))
(- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))