
(FPCore (x y z t a b) :precision binary64 (+ (- (* x 2.0) (* (* (* y 9.0) z) t)) (* (* a 27.0) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b);
}
real(8) function code(x, y, z, t, a, b)
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
code = ((x * 2.0d0) - (((y * 9.0d0) * z) * t)) + ((a * 27.0d0) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b);
}
def code(x, y, z, t, a, b): return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x * 2.0) - Float64(Float64(Float64(y * 9.0) * z) * t)) + Float64(Float64(a * 27.0) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x * 2.0), $MachinePrecision] - N[(N[(N[(y * 9.0), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(N[(a * 27.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\right) + \left(a \cdot 27\right) \cdot b
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 19 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (+ (- (* x 2.0) (* (* (* y 9.0) z) t)) (* (* a 27.0) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b);
}
real(8) function code(x, y, z, t, a, b)
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
code = ((x * 2.0d0) - (((y * 9.0d0) * z) * t)) + ((a * 27.0d0) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b);
}
def code(x, y, z, t, a, b): return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x * 2.0) - Float64(Float64(Float64(y * 9.0) * z) * t)) + Float64(Float64(a * 27.0) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x * 2.0), $MachinePrecision] - N[(N[(N[(y * 9.0), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(N[(a * 27.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\right) + \left(a \cdot 27\right) \cdot b
\end{array}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -1.9e-100) (fma a (* 27.0 b) (fma x 2.0 (* y (* z (* t -9.0))))) (+ (- (* x 2.0) (* t (* y (* z 9.0)))) (* a (* 27.0 b)))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.9e-100) {
tmp = fma(a, (27.0 * b), fma(x, 2.0, (y * (z * (t * -9.0)))));
} else {
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
}
return tmp;
}
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.9e-100) tmp = fma(a, Float64(27.0 * b), fma(x, 2.0, Float64(y * Float64(z * Float64(t * -9.0))))); else tmp = Float64(Float64(Float64(x * 2.0) - Float64(t * Float64(y * Float64(z * 9.0)))) + Float64(a * Float64(27.0 * b))); end return tmp end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.9e-100], N[(a * N[(27.0 * b), $MachinePrecision] + N[(x * 2.0 + N[(y * N[(z * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x * 2.0), $MachinePrecision] - N[(t * N[(y * N[(z * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * N[(27.0 * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{-100}:\\
\;\;\;\;\mathsf{fma}\left(a, 27 \cdot b, \mathsf{fma}\left(x, 2, y \cdot \left(z \cdot \left(t \cdot -9\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot 2 - t \cdot \left(y \cdot \left(z \cdot 9\right)\right)\right) + a \cdot \left(27 \cdot b\right)\\
\end{array}
\end{array}
if z < -1.89999999999999999e-100Initial program 95.6%
+-commutative95.6%
associate-+r-95.6%
*-commutative95.6%
cancel-sign-sub-inv95.6%
associate-*r*98.2%
distribute-lft-neg-in98.2%
*-commutative98.2%
cancel-sign-sub-inv98.2%
associate-+r-98.2%
associate-*l*98.2%
fma-define98.2%
fma-neg98.2%
associate-*l*94.4%
distribute-rgt-neg-in94.4%
*-commutative94.4%
associate-*l*94.5%
*-commutative94.5%
distribute-lft-neg-in94.5%
associate-*r*94.5%
Simplified94.5%
if -1.89999999999999999e-100 < z Initial program 96.4%
associate-+l-96.4%
*-commutative96.4%
*-commutative96.4%
associate-*l*96.4%
associate-+l-96.4%
associate-*l*96.4%
*-commutative96.4%
*-commutative96.4%
associate-*l*97.6%
associate-*l*97.6%
Simplified97.6%
Taylor expanded in y around 0 96.4%
*-commutative96.4%
associate-*r*95.3%
associate-*l*95.4%
*-commutative95.4%
associate-*r*96.4%
Simplified96.4%
Final simplification95.7%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= (* z (* y 9.0)) 1e+245) (+ (- (* x 2.0) (* t (* y (* z 9.0)))) (* a (* 27.0 b))) (+ (* z (* y (* t -9.0))) (+ (* 27.0 (* a b)) (* x 2.0)))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z * (y * 9.0)) <= 1e+245) {
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
} else {
tmp = (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z * (y * 9.0d0)) <= 1d+245) then
tmp = ((x * 2.0d0) - (t * (y * (z * 9.0d0)))) + (a * (27.0d0 * b))
else
tmp = (z * (y * (t * (-9.0d0)))) + ((27.0d0 * (a * b)) + (x * 2.0d0))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z * (y * 9.0)) <= 1e+245) {
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
} else {
tmp = (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if (z * (y * 9.0)) <= 1e+245: tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b)) else: tmp = (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(z * Float64(y * 9.0)) <= 1e+245) tmp = Float64(Float64(Float64(x * 2.0) - Float64(t * Float64(y * Float64(z * 9.0)))) + Float64(a * Float64(27.0 * b))); else tmp = Float64(Float64(z * Float64(y * Float64(t * -9.0))) + Float64(Float64(27.0 * Float64(a * b)) + Float64(x * 2.0))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if ((z * (y * 9.0)) <= 1e+245)
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
else
tmp = (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(z * N[(y * 9.0), $MachinePrecision]), $MachinePrecision], 1e+245], N[(N[(N[(x * 2.0), $MachinePrecision] - N[(t * N[(y * N[(z * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * N[(27.0 * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(z * N[(y * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \cdot \left(y \cdot 9\right) \leq 10^{+245}:\\
\;\;\;\;\left(x \cdot 2 - t \cdot \left(y \cdot \left(z \cdot 9\right)\right)\right) + a \cdot \left(27 \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(y \cdot \left(t \cdot -9\right)\right) + \left(27 \cdot \left(a \cdot b\right) + x \cdot 2\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 y #s(literal 9 binary64)) z) < 1.00000000000000004e245Initial program 96.6%
associate-+l-96.6%
*-commutative96.6%
*-commutative96.6%
associate-*l*96.2%
associate-+l-96.2%
associate-*l*96.6%
*-commutative96.6%
*-commutative96.6%
associate-*l*96.1%
associate-*l*96.2%
Simplified96.2%
Taylor expanded in y around 0 96.7%
*-commutative96.7%
associate-*r*96.0%
associate-*l*96.0%
*-commutative96.0%
associate-*r*96.2%
Simplified96.2%
if 1.00000000000000004e245 < (*.f64 (*.f64 y #s(literal 9 binary64)) z) Initial program 90.9%
+-commutative90.9%
associate-+r-90.9%
*-commutative90.9%
cancel-sign-sub-inv90.9%
associate-*r*99.9%
distribute-lft-neg-in99.9%
*-commutative99.9%
cancel-sign-sub-inv99.9%
associate-+r-99.9%
associate-*l*99.9%
fma-define99.9%
cancel-sign-sub-inv99.9%
fma-define99.9%
distribute-lft-neg-in99.9%
distribute-rgt-neg-in99.9%
*-commutative99.9%
associate-*r*90.9%
associate-*l*90.9%
neg-mul-190.9%
associate-*r*90.9%
Simplified90.9%
fma-undefine90.9%
fma-undefine90.9%
associate-+r+90.9%
*-commutative90.9%
associate-*l*99.9%
*-commutative99.9%
associate-*r*99.9%
*-commutative99.9%
associate-*r*99.9%
*-commutative99.9%
associate-*l*99.9%
*-commutative99.9%
associate-*l*99.9%
Applied egg-rr99.9%
Final simplification96.5%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* 27.0 (* a b))))
(if (<= z -2.05e-100)
(+ t_1 (* -9.0 (* y (* z t))))
(if (<= z 4.6e+26)
(+ t_1 (* x 2.0))
(* z (- (* 27.0 (/ (* a b) z)) (* 9.0 (* y t))))))))assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -2.05e-100) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 4.6e+26) {
tmp = t_1 + (x * 2.0);
} else {
tmp = z * ((27.0 * ((a * b) / z)) - (9.0 * (y * t)));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = 27.0d0 * (a * b)
if (z <= (-2.05d-100)) then
tmp = t_1 + ((-9.0d0) * (y * (z * t)))
else if (z <= 4.6d+26) then
tmp = t_1 + (x * 2.0d0)
else
tmp = z * ((27.0d0 * ((a * b) / z)) - (9.0d0 * (y * t)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -2.05e-100) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 4.6e+26) {
tmp = t_1 + (x * 2.0);
} else {
tmp = z * ((27.0 * ((a * b) / z)) - (9.0 * (y * t)));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): t_1 = 27.0 * (a * b) tmp = 0 if z <= -2.05e-100: tmp = t_1 + (-9.0 * (y * (z * t))) elif z <= 4.6e+26: tmp = t_1 + (x * 2.0) else: tmp = z * ((27.0 * ((a * b) / z)) - (9.0 * (y * t))) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) t_1 = Float64(27.0 * Float64(a * b)) tmp = 0.0 if (z <= -2.05e-100) tmp = Float64(t_1 + Float64(-9.0 * Float64(y * Float64(z * t)))); elseif (z <= 4.6e+26) tmp = Float64(t_1 + Float64(x * 2.0)); else tmp = Float64(z * Float64(Float64(27.0 * Float64(Float64(a * b) / z)) - Float64(9.0 * Float64(y * t)))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
t_1 = 27.0 * (a * b);
tmp = 0.0;
if (z <= -2.05e-100)
tmp = t_1 + (-9.0 * (y * (z * t)));
elseif (z <= 4.6e+26)
tmp = t_1 + (x * 2.0);
else
tmp = z * ((27.0 * ((a * b) / z)) - (9.0 * (y * t)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.05e-100], N[(t$95$1 + N[(-9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.6e+26], N[(t$95$1 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], N[(z * N[(N[(27.0 * N[(N[(a * b), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] - N[(9.0 * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;z \leq -2.05 \cdot 10^{-100}:\\
\;\;\;\;t\_1 + -9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 4.6 \cdot 10^{+26}:\\
\;\;\;\;t\_1 + x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(27 \cdot \frac{a \cdot b}{z} - 9 \cdot \left(y \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -2.0499999999999999e-100Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
sub-neg76.6%
+-commutative76.6%
*-commutative76.6%
distribute-rgt-neg-in76.6%
*-commutative76.6%
associate-*l*77.5%
metadata-eval77.5%
Applied egg-rr77.5%
if -2.0499999999999999e-100 < z < 4.6000000000000001e26Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
if 4.6000000000000001e26 < z Initial program 91.8%
associate-+l-91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*91.8%
associate-+l-91.8%
associate-*l*91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*93.4%
associate-*l*93.5%
Simplified93.5%
Taylor expanded in x around 0 73.3%
Taylor expanded in z around inf 81.3%
Final simplification80.3%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* 27.0 (* a b))))
(if (<= z -2.05e-100)
(+ t_1 (* -9.0 (* y (* z t))))
(if (<= z 9.5e+29) (+ t_1 (* x 2.0)) (- t_1 (* 9.0 (* z (* y t))))))))assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -2.05e-100) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 9.5e+29) {
tmp = t_1 + (x * 2.0);
} else {
tmp = t_1 - (9.0 * (z * (y * t)));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = 27.0d0 * (a * b)
if (z <= (-2.05d-100)) then
tmp = t_1 + ((-9.0d0) * (y * (z * t)))
else if (z <= 9.5d+29) then
tmp = t_1 + (x * 2.0d0)
else
tmp = t_1 - (9.0d0 * (z * (y * t)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -2.05e-100) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 9.5e+29) {
tmp = t_1 + (x * 2.0);
} else {
tmp = t_1 - (9.0 * (z * (y * t)));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): t_1 = 27.0 * (a * b) tmp = 0 if z <= -2.05e-100: tmp = t_1 + (-9.0 * (y * (z * t))) elif z <= 9.5e+29: tmp = t_1 + (x * 2.0) else: tmp = t_1 - (9.0 * (z * (y * t))) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) t_1 = Float64(27.0 * Float64(a * b)) tmp = 0.0 if (z <= -2.05e-100) tmp = Float64(t_1 + Float64(-9.0 * Float64(y * Float64(z * t)))); elseif (z <= 9.5e+29) tmp = Float64(t_1 + Float64(x * 2.0)); else tmp = Float64(t_1 - Float64(9.0 * Float64(z * Float64(y * t)))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
t_1 = 27.0 * (a * b);
tmp = 0.0;
if (z <= -2.05e-100)
tmp = t_1 + (-9.0 * (y * (z * t)));
elseif (z <= 9.5e+29)
tmp = t_1 + (x * 2.0);
else
tmp = t_1 - (9.0 * (z * (y * t)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.05e-100], N[(t$95$1 + N[(-9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.5e+29], N[(t$95$1 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], N[(t$95$1 - N[(9.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;z \leq -2.05 \cdot 10^{-100}:\\
\;\;\;\;t\_1 + -9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 9.5 \cdot 10^{+29}:\\
\;\;\;\;t\_1 + x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;t\_1 - 9 \cdot \left(z \cdot \left(y \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -2.0499999999999999e-100Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
sub-neg76.6%
+-commutative76.6%
*-commutative76.6%
distribute-rgt-neg-in76.6%
*-commutative76.6%
associate-*l*77.5%
metadata-eval77.5%
Applied egg-rr77.5%
if -2.0499999999999999e-100 < z < 9.5000000000000003e29Initial program 98.1%
+-commutative98.1%
associate-+r-98.1%
*-commutative98.1%
cancel-sign-sub-inv98.1%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*98.1%
associate-*l*98.1%
neg-mul-198.1%
associate-*r*98.1%
Simplified98.1%
Taylor expanded in t around 0 81.3%
if 9.5000000000000003e29 < z Initial program 93.2%
associate-+l-93.2%
*-commutative93.2%
*-commutative93.2%
associate-*l*93.3%
associate-+l-93.3%
associate-*l*93.2%
*-commutative93.2%
*-commutative93.2%
associate-*l*93.3%
associate-*l*93.4%
Simplified93.4%
Taylor expanded in x around 0 74.5%
pow174.5%
*-commutative74.5%
associate-*l*76.2%
Applied egg-rr76.2%
unpow176.2%
*-commutative76.2%
associate-*l*80.9%
Simplified80.9%
Final simplification79.9%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* 27.0 (* a b))))
(if (<= z -1.65e-100)
(+ t_1 (* -9.0 (* y (* z t))))
(if (<= z 8e+26) (+ t_1 (* x 2.0)) (- t_1 (* 9.0 (* t (* z y))))))))assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -1.65e-100) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 8e+26) {
tmp = t_1 + (x * 2.0);
} else {
tmp = t_1 - (9.0 * (t * (z * y)));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = 27.0d0 * (a * b)
if (z <= (-1.65d-100)) then
tmp = t_1 + ((-9.0d0) * (y * (z * t)))
else if (z <= 8d+26) then
tmp = t_1 + (x * 2.0d0)
else
tmp = t_1 - (9.0d0 * (t * (z * y)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -1.65e-100) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 8e+26) {
tmp = t_1 + (x * 2.0);
} else {
tmp = t_1 - (9.0 * (t * (z * y)));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): t_1 = 27.0 * (a * b) tmp = 0 if z <= -1.65e-100: tmp = t_1 + (-9.0 * (y * (z * t))) elif z <= 8e+26: tmp = t_1 + (x * 2.0) else: tmp = t_1 - (9.0 * (t * (z * y))) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) t_1 = Float64(27.0 * Float64(a * b)) tmp = 0.0 if (z <= -1.65e-100) tmp = Float64(t_1 + Float64(-9.0 * Float64(y * Float64(z * t)))); elseif (z <= 8e+26) tmp = Float64(t_1 + Float64(x * 2.0)); else tmp = Float64(t_1 - Float64(9.0 * Float64(t * Float64(z * y)))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
t_1 = 27.0 * (a * b);
tmp = 0.0;
if (z <= -1.65e-100)
tmp = t_1 + (-9.0 * (y * (z * t)));
elseif (z <= 8e+26)
tmp = t_1 + (x * 2.0);
else
tmp = t_1 - (9.0 * (t * (z * y)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.65e-100], N[(t$95$1 + N[(-9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8e+26], N[(t$95$1 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], N[(t$95$1 - N[(9.0 * N[(t * N[(z * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;z \leq -1.65 \cdot 10^{-100}:\\
\;\;\;\;t\_1 + -9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+26}:\\
\;\;\;\;t\_1 + x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;t\_1 - 9 \cdot \left(t \cdot \left(z \cdot y\right)\right)\\
\end{array}
\end{array}
if z < -1.64999999999999998e-100Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
sub-neg76.6%
+-commutative76.6%
*-commutative76.6%
distribute-rgt-neg-in76.6%
*-commutative76.6%
associate-*l*77.5%
metadata-eval77.5%
Applied egg-rr77.5%
if -1.64999999999999998e-100 < z < 8.00000000000000038e26Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
if 8.00000000000000038e26 < z Initial program 91.8%
associate-+l-91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*91.8%
associate-+l-91.8%
associate-*l*91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*93.4%
associate-*l*93.5%
Simplified93.5%
Taylor expanded in x around 0 73.3%
Final simplification78.5%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* 27.0 (* a b))))
(if (<= z -9.8e-101)
(+ t_1 (* -9.0 (* y (* z t))))
(if (<= z 1.05e-18)
(+ t_1 (* x 2.0))
(* z (+ (* -9.0 (* y t)) (* 2.0 (/ x z))))))))assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -9.8e-101) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 1.05e-18) {
tmp = t_1 + (x * 2.0);
} else {
tmp = z * ((-9.0 * (y * t)) + (2.0 * (x / z)));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = 27.0d0 * (a * b)
if (z <= (-9.8d-101)) then
tmp = t_1 + ((-9.0d0) * (y * (z * t)))
else if (z <= 1.05d-18) then
tmp = t_1 + (x * 2.0d0)
else
tmp = z * (((-9.0d0) * (y * t)) + (2.0d0 * (x / z)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 27.0 * (a * b);
double tmp;
if (z <= -9.8e-101) {
tmp = t_1 + (-9.0 * (y * (z * t)));
} else if (z <= 1.05e-18) {
tmp = t_1 + (x * 2.0);
} else {
tmp = z * ((-9.0 * (y * t)) + (2.0 * (x / z)));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): t_1 = 27.0 * (a * b) tmp = 0 if z <= -9.8e-101: tmp = t_1 + (-9.0 * (y * (z * t))) elif z <= 1.05e-18: tmp = t_1 + (x * 2.0) else: tmp = z * ((-9.0 * (y * t)) + (2.0 * (x / z))) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) t_1 = Float64(27.0 * Float64(a * b)) tmp = 0.0 if (z <= -9.8e-101) tmp = Float64(t_1 + Float64(-9.0 * Float64(y * Float64(z * t)))); elseif (z <= 1.05e-18) tmp = Float64(t_1 + Float64(x * 2.0)); else tmp = Float64(z * Float64(Float64(-9.0 * Float64(y * t)) + Float64(2.0 * Float64(x / z)))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
t_1 = 27.0 * (a * b);
tmp = 0.0;
if (z <= -9.8e-101)
tmp = t_1 + (-9.0 * (y * (z * t)));
elseif (z <= 1.05e-18)
tmp = t_1 + (x * 2.0);
else
tmp = z * ((-9.0 * (y * t)) + (2.0 * (x / z)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -9.8e-101], N[(t$95$1 + N[(-9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.05e-18], N[(t$95$1 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], N[(z * N[(N[(-9.0 * N[(y * t), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;z \leq -9.8 \cdot 10^{-101}:\\
\;\;\;\;t\_1 + -9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 1.05 \cdot 10^{-18}:\\
\;\;\;\;t\_1 + x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(-9 \cdot \left(y \cdot t\right) + 2 \cdot \frac{x}{z}\right)\\
\end{array}
\end{array}
if z < -9.8000000000000001e-101Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
sub-neg76.6%
+-commutative76.6%
*-commutative76.6%
distribute-rgt-neg-in76.6%
*-commutative76.6%
associate-*l*77.5%
metadata-eval77.5%
Applied egg-rr77.5%
if -9.8000000000000001e-101 < z < 1.05e-18Initial program 98.8%
+-commutative98.8%
associate-+r-98.8%
*-commutative98.8%
cancel-sign-sub-inv98.8%
associate-*r*91.7%
distribute-lft-neg-in91.7%
*-commutative91.7%
cancel-sign-sub-inv91.7%
associate-+r-91.7%
associate-*l*91.7%
fma-define91.7%
cancel-sign-sub-inv91.7%
fma-define91.7%
distribute-lft-neg-in91.7%
distribute-rgt-neg-in91.7%
*-commutative91.7%
associate-*r*98.8%
associate-*l*98.8%
neg-mul-198.8%
associate-*r*98.8%
Simplified98.8%
Taylor expanded in t around 0 83.8%
if 1.05e-18 < z Initial program 93.4%
+-commutative93.4%
associate-+r-93.4%
*-commutative93.4%
cancel-sign-sub-inv93.4%
associate-*r*99.8%
distribute-lft-neg-in99.8%
*-commutative99.8%
cancel-sign-sub-inv99.8%
associate-+r-99.8%
associate-*l*99.8%
fma-define99.8%
cancel-sign-sub-inv99.8%
fma-define99.8%
distribute-lft-neg-in99.8%
distribute-rgt-neg-in99.8%
*-commutative99.8%
associate-*r*93.5%
associate-*l*93.5%
neg-mul-193.5%
associate-*r*93.5%
Simplified93.5%
Taylor expanded in a around 0 75.1%
Taylor expanded in z around inf 80.2%
Final simplification80.6%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -2.05e-100) (- (+ (* 27.0 (* a b)) (* x 2.0)) (* y (* t (* z 9.0)))) (+ (- (* x 2.0) (* t (* y (* z 9.0)))) (* a (* 27.0 b)))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -2.05e-100) {
tmp = ((27.0 * (a * b)) + (x * 2.0)) - (y * (t * (z * 9.0)));
} else {
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-2.05d-100)) then
tmp = ((27.0d0 * (a * b)) + (x * 2.0d0)) - (y * (t * (z * 9.0d0)))
else
tmp = ((x * 2.0d0) - (t * (y * (z * 9.0d0)))) + (a * (27.0d0 * b))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -2.05e-100) {
tmp = ((27.0 * (a * b)) + (x * 2.0)) - (y * (t * (z * 9.0)));
} else {
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if z <= -2.05e-100: tmp = ((27.0 * (a * b)) + (x * 2.0)) - (y * (t * (z * 9.0))) else: tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -2.05e-100) tmp = Float64(Float64(Float64(27.0 * Float64(a * b)) + Float64(x * 2.0)) - Float64(y * Float64(t * Float64(z * 9.0)))); else tmp = Float64(Float64(Float64(x * 2.0) - Float64(t * Float64(y * Float64(z * 9.0)))) + Float64(a * Float64(27.0 * b))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (z <= -2.05e-100)
tmp = ((27.0 * (a * b)) + (x * 2.0)) - (y * (t * (z * 9.0)));
else
tmp = ((x * 2.0) - (t * (y * (z * 9.0)))) + (a * (27.0 * b));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -2.05e-100], N[(N[(N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] - N[(y * N[(t * N[(z * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x * 2.0), $MachinePrecision] - N[(t * N[(y * N[(z * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * N[(27.0 * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.05 \cdot 10^{-100}:\\
\;\;\;\;\left(27 \cdot \left(a \cdot b\right) + x \cdot 2\right) - y \cdot \left(t \cdot \left(z \cdot 9\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot 2 - t \cdot \left(y \cdot \left(z \cdot 9\right)\right)\right) + a \cdot \left(27 \cdot b\right)\\
\end{array}
\end{array}
if z < -2.0499999999999999e-100Initial program 95.6%
+-commutative95.6%
associate-+r-95.6%
*-commutative95.6%
cancel-sign-sub-inv95.6%
associate-*r*98.2%
distribute-lft-neg-in98.2%
*-commutative98.2%
cancel-sign-sub-inv98.2%
associate-+r-98.2%
associate-*l*98.2%
fma-define98.2%
cancel-sign-sub-inv98.2%
fma-define98.2%
distribute-lft-neg-in98.2%
distribute-rgt-neg-in98.2%
*-commutative98.2%
associate-*r*95.6%
associate-*l*94.6%
neg-mul-194.6%
associate-*r*94.6%
Simplified94.6%
fma-undefine94.6%
fma-undefine94.6%
associate-+r+94.6%
associate-*r*95.7%
metadata-eval95.7%
distribute-rgt-neg-in95.7%
distribute-lft-neg-in95.7%
distribute-rgt-neg-in95.7%
*-commutative95.7%
associate-*r*94.4%
associate-+r+94.4%
sub-neg94.4%
associate-+r-94.4%
associate-*r*94.4%
*-commutative94.4%
associate-*l*94.4%
associate-*l*94.5%
associate-*r*93.4%
Applied egg-rr93.4%
if -2.0499999999999999e-100 < z Initial program 96.4%
associate-+l-96.4%
*-commutative96.4%
*-commutative96.4%
associate-*l*96.4%
associate-+l-96.4%
associate-*l*96.4%
*-commutative96.4%
*-commutative96.4%
associate-*l*97.6%
associate-*l*97.6%
Simplified97.6%
Taylor expanded in y around 0 96.4%
*-commutative96.4%
associate-*r*95.3%
associate-*l*95.4%
*-commutative95.4%
associate-*r*96.4%
Simplified96.4%
Final simplification95.4%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -1.25e+99) (* -9.0 (* z (* y t))) (if (<= z 4e+75) (+ (* 27.0 (* a b)) (* x 2.0)) (* z (* y (* t -9.0))))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.25e+99) {
tmp = -9.0 * (z * (y * t));
} else if (z <= 4e+75) {
tmp = (27.0 * (a * b)) + (x * 2.0);
} else {
tmp = z * (y * (t * -9.0));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-1.25d+99)) then
tmp = (-9.0d0) * (z * (y * t))
else if (z <= 4d+75) then
tmp = (27.0d0 * (a * b)) + (x * 2.0d0)
else
tmp = z * (y * (t * (-9.0d0)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.25e+99) {
tmp = -9.0 * (z * (y * t));
} else if (z <= 4e+75) {
tmp = (27.0 * (a * b)) + (x * 2.0);
} else {
tmp = z * (y * (t * -9.0));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if z <= -1.25e+99: tmp = -9.0 * (z * (y * t)) elif z <= 4e+75: tmp = (27.0 * (a * b)) + (x * 2.0) else: tmp = z * (y * (t * -9.0)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.25e+99) tmp = Float64(-9.0 * Float64(z * Float64(y * t))); elseif (z <= 4e+75) tmp = Float64(Float64(27.0 * Float64(a * b)) + Float64(x * 2.0)); else tmp = Float64(z * Float64(y * Float64(t * -9.0))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (z <= -1.25e+99)
tmp = -9.0 * (z * (y * t));
elseif (z <= 4e+75)
tmp = (27.0 * (a * b)) + (x * 2.0);
else
tmp = z * (y * (t * -9.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.25e+99], N[(-9.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4e+75], N[(N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], N[(z * N[(y * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.25 \cdot 10^{+99}:\\
\;\;\;\;-9 \cdot \left(z \cdot \left(y \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 4 \cdot 10^{+75}:\\
\;\;\;\;27 \cdot \left(a \cdot b\right) + x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(y \cdot \left(t \cdot -9\right)\right)\\
\end{array}
\end{array}
if z < -1.25000000000000002e99Initial program 92.1%
associate-+l-92.1%
*-commutative92.1%
*-commutative92.1%
associate-*l*90.2%
associate-+l-90.2%
associate-*l*92.1%
*-commutative92.1%
*-commutative92.1%
associate-*l*91.8%
associate-*l*91.8%
Simplified91.8%
Taylor expanded in x around 0 80.1%
Taylor expanded in a around 0 63.7%
*-commutative63.7%
associate-*r*64.0%
*-commutative64.0%
associate-*r*63.7%
*-commutative63.7%
associate-*r*63.9%
associate-*l*63.7%
Simplified63.7%
Taylor expanded in t around 0 63.7%
associate-*r*63.9%
Simplified63.9%
if -1.25000000000000002e99 < z < 3.99999999999999971e75Initial program 98.6%
+-commutative98.6%
associate-+r-98.6%
*-commutative98.6%
cancel-sign-sub-inv98.6%
associate-*r*95.0%
distribute-lft-neg-in95.0%
*-commutative95.0%
cancel-sign-sub-inv95.0%
associate-+r-95.0%
associate-*l*95.0%
fma-define95.0%
cancel-sign-sub-inv95.0%
fma-define95.0%
distribute-lft-neg-in95.0%
distribute-rgt-neg-in95.0%
*-commutative95.0%
associate-*r*98.6%
associate-*l*98.6%
neg-mul-198.6%
associate-*r*98.6%
Simplified98.6%
Taylor expanded in t around 0 77.8%
if 3.99999999999999971e75 < z Initial program 92.5%
+-commutative92.5%
associate-+r-92.5%
*-commutative92.5%
cancel-sign-sub-inv92.5%
associate-*r*99.7%
distribute-lft-neg-in99.7%
*-commutative99.7%
cancel-sign-sub-inv99.7%
associate-+r-99.7%
associate-*l*99.8%
fma-define99.8%
cancel-sign-sub-inv99.8%
fma-define99.8%
distribute-lft-neg-in99.8%
distribute-rgt-neg-in99.8%
*-commutative99.8%
associate-*r*92.6%
associate-*l*92.6%
neg-mul-192.6%
associate-*r*92.6%
Simplified92.6%
Taylor expanded in a around 0 77.7%
Taylor expanded in z around inf 83.2%
Taylor expanded in t around inf 64.4%
associate-*r*64.5%
*-commutative64.5%
Simplified64.5%
Final simplification72.5%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (or (<= z -6e-101) (not (<= z 3.7e+26))) (* -9.0 (* t (* z y))) (* x 2.0)))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -6e-101) || !(z <= 3.7e+26)) {
tmp = -9.0 * (t * (z * y));
} else {
tmp = x * 2.0;
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-6d-101)) .or. (.not. (z <= 3.7d+26))) then
tmp = (-9.0d0) * (t * (z * y))
else
tmp = x * 2.0d0
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -6e-101) || !(z <= 3.7e+26)) {
tmp = -9.0 * (t * (z * y));
} else {
tmp = x * 2.0;
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if (z <= -6e-101) or not (z <= 3.7e+26): tmp = -9.0 * (t * (z * y)) else: tmp = x * 2.0 return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -6e-101) || !(z <= 3.7e+26)) tmp = Float64(-9.0 * Float64(t * Float64(z * y))); else tmp = Float64(x * 2.0); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if ((z <= -6e-101) || ~((z <= 3.7e+26)))
tmp = -9.0 * (t * (z * y));
else
tmp = x * 2.0;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -6e-101], N[Not[LessEqual[z, 3.7e+26]], $MachinePrecision]], N[(-9.0 * N[(t * N[(z * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * 2.0), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6 \cdot 10^{-101} \lor \neg \left(z \leq 3.7 \cdot 10^{+26}\right):\\
\;\;\;\;-9 \cdot \left(t \cdot \left(z \cdot y\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot 2\\
\end{array}
\end{array}
if z < -6.0000000000000006e-101 or 3.69999999999999988e26 < z Initial program 94.1%
+-commutative94.1%
associate-+r-94.1%
*-commutative94.1%
cancel-sign-sub-inv94.1%
associate-*r*98.8%
distribute-lft-neg-in98.8%
*-commutative98.8%
cancel-sign-sub-inv98.8%
associate-+r-98.8%
associate-*l*98.8%
fma-define98.8%
cancel-sign-sub-inv98.8%
fma-define98.8%
distribute-lft-neg-in98.8%
distribute-rgt-neg-in98.8%
*-commutative98.8%
associate-*r*94.1%
associate-*l*93.5%
neg-mul-193.5%
associate-*r*93.5%
Simplified93.5%
Taylor expanded in t around inf 51.5%
if -6.0000000000000006e-101 < z < 3.69999999999999988e26Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
Taylor expanded in x around inf 48.9%
Final simplification50.4%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -5.8e-101) (* y (* z (* t -9.0))) (if (<= z 4.4e+26) (* x 2.0) (* z (* y (* t -9.0))))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -5.8e-101) {
tmp = y * (z * (t * -9.0));
} else if (z <= 4.4e+26) {
tmp = x * 2.0;
} else {
tmp = z * (y * (t * -9.0));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-5.8d-101)) then
tmp = y * (z * (t * (-9.0d0)))
else if (z <= 4.4d+26) then
tmp = x * 2.0d0
else
tmp = z * (y * (t * (-9.0d0)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -5.8e-101) {
tmp = y * (z * (t * -9.0));
} else if (z <= 4.4e+26) {
tmp = x * 2.0;
} else {
tmp = z * (y * (t * -9.0));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if z <= -5.8e-101: tmp = y * (z * (t * -9.0)) elif z <= 4.4e+26: tmp = x * 2.0 else: tmp = z * (y * (t * -9.0)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -5.8e-101) tmp = Float64(y * Float64(z * Float64(t * -9.0))); elseif (z <= 4.4e+26) tmp = Float64(x * 2.0); else tmp = Float64(z * Float64(y * Float64(t * -9.0))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (z <= -5.8e-101)
tmp = y * (z * (t * -9.0));
elseif (z <= 4.4e+26)
tmp = x * 2.0;
else
tmp = z * (y * (t * -9.0));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -5.8e-101], N[(y * N[(z * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.4e+26], N[(x * 2.0), $MachinePrecision], N[(z * N[(y * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.8 \cdot 10^{-101}:\\
\;\;\;\;y \cdot \left(z \cdot \left(t \cdot -9\right)\right)\\
\mathbf{elif}\;z \leq 4.4 \cdot 10^{+26}:\\
\;\;\;\;x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(y \cdot \left(t \cdot -9\right)\right)\\
\end{array}
\end{array}
if z < -5.800000000000001e-101Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
Taylor expanded in a around 0 48.8%
associate-*r*48.7%
associate-*r*48.9%
*-commutative48.9%
associate-*r*49.0%
Simplified49.0%
if -5.800000000000001e-101 < z < 4.40000000000000014e26Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
Taylor expanded in x around inf 48.9%
if 4.40000000000000014e26 < z Initial program 91.8%
+-commutative91.8%
associate-+r-91.8%
*-commutative91.8%
cancel-sign-sub-inv91.8%
associate-*r*99.7%
distribute-lft-neg-in99.7%
*-commutative99.7%
cancel-sign-sub-inv99.7%
associate-+r-99.7%
associate-*l*99.8%
fma-define99.8%
cancel-sign-sub-inv99.8%
fma-define99.8%
distribute-lft-neg-in99.8%
distribute-rgt-neg-in99.8%
*-commutative99.8%
associate-*r*91.8%
associate-*l*91.9%
neg-mul-191.9%
associate-*r*91.9%
Simplified91.9%
Taylor expanded in a around 0 73.7%
Taylor expanded in z around inf 80.2%
Taylor expanded in t around inf 62.0%
associate-*r*62.0%
*-commutative62.0%
Simplified62.0%
Final simplification52.0%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -5e-101) (* y (* z (* t -9.0))) (if (<= z 7e+26) (* x 2.0) (* -9.0 (* z (* y t))))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -5e-101) {
tmp = y * (z * (t * -9.0));
} else if (z <= 7e+26) {
tmp = x * 2.0;
} else {
tmp = -9.0 * (z * (y * t));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-5d-101)) then
tmp = y * (z * (t * (-9.0d0)))
else if (z <= 7d+26) then
tmp = x * 2.0d0
else
tmp = (-9.0d0) * (z * (y * t))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -5e-101) {
tmp = y * (z * (t * -9.0));
} else if (z <= 7e+26) {
tmp = x * 2.0;
} else {
tmp = -9.0 * (z * (y * t));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if z <= -5e-101: tmp = y * (z * (t * -9.0)) elif z <= 7e+26: tmp = x * 2.0 else: tmp = -9.0 * (z * (y * t)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -5e-101) tmp = Float64(y * Float64(z * Float64(t * -9.0))); elseif (z <= 7e+26) tmp = Float64(x * 2.0); else tmp = Float64(-9.0 * Float64(z * Float64(y * t))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (z <= -5e-101)
tmp = y * (z * (t * -9.0));
elseif (z <= 7e+26)
tmp = x * 2.0;
else
tmp = -9.0 * (z * (y * t));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -5e-101], N[(y * N[(z * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7e+26], N[(x * 2.0), $MachinePrecision], N[(-9.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5 \cdot 10^{-101}:\\
\;\;\;\;y \cdot \left(z \cdot \left(t \cdot -9\right)\right)\\
\mathbf{elif}\;z \leq 7 \cdot 10^{+26}:\\
\;\;\;\;x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;-9 \cdot \left(z \cdot \left(y \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -5.0000000000000001e-101Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
Taylor expanded in a around 0 48.8%
associate-*r*48.7%
associate-*r*48.9%
*-commutative48.9%
associate-*r*49.0%
Simplified49.0%
if -5.0000000000000001e-101 < z < 6.9999999999999998e26Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
Taylor expanded in x around inf 48.9%
if 6.9999999999999998e26 < z Initial program 91.8%
associate-+l-91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*91.8%
associate-+l-91.8%
associate-*l*91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*93.4%
associate-*l*93.5%
Simplified93.5%
Taylor expanded in x around 0 73.3%
Taylor expanded in a around 0 55.7%
*-commutative55.7%
associate-*r*59.0%
*-commutative59.0%
associate-*r*55.7%
*-commutative55.7%
associate-*r*62.0%
associate-*l*62.1%
Simplified62.1%
Taylor expanded in t around 0 55.7%
associate-*r*62.0%
Simplified62.0%
Final simplification52.0%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -7.2e-101) (* -9.0 (* y (* z t))) (if (<= z 1.6e+29) (* x 2.0) (* -9.0 (* z (* y t))))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -7.2e-101) {
tmp = -9.0 * (y * (z * t));
} else if (z <= 1.6e+29) {
tmp = x * 2.0;
} else {
tmp = -9.0 * (z * (y * t));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-7.2d-101)) then
tmp = (-9.0d0) * (y * (z * t))
else if (z <= 1.6d+29) then
tmp = x * 2.0d0
else
tmp = (-9.0d0) * (z * (y * t))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -7.2e-101) {
tmp = -9.0 * (y * (z * t));
} else if (z <= 1.6e+29) {
tmp = x * 2.0;
} else {
tmp = -9.0 * (z * (y * t));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if z <= -7.2e-101: tmp = -9.0 * (y * (z * t)) elif z <= 1.6e+29: tmp = x * 2.0 else: tmp = -9.0 * (z * (y * t)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -7.2e-101) tmp = Float64(-9.0 * Float64(y * Float64(z * t))); elseif (z <= 1.6e+29) tmp = Float64(x * 2.0); else tmp = Float64(-9.0 * Float64(z * Float64(y * t))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (z <= -7.2e-101)
tmp = -9.0 * (y * (z * t));
elseif (z <= 1.6e+29)
tmp = x * 2.0;
else
tmp = -9.0 * (z * (y * t));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -7.2e-101], N[(-9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.6e+29], N[(x * 2.0), $MachinePrecision], N[(-9.0 * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.2 \cdot 10^{-101}:\\
\;\;\;\;-9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 1.6 \cdot 10^{+29}:\\
\;\;\;\;x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;-9 \cdot \left(z \cdot \left(y \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -7.19999999999999999e-101Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
Taylor expanded in a around 0 48.8%
*-commutative48.8%
associate-*r*48.9%
*-commutative48.9%
associate-*r*48.8%
*-commutative48.8%
associate-*r*48.9%
associate-*l*48.8%
Simplified48.8%
Taylor expanded in t around 0 48.8%
*-commutative48.8%
associate-*l*48.9%
*-commutative48.9%
Simplified48.9%
if -7.19999999999999999e-101 < z < 1.59999999999999993e29Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
Taylor expanded in x around inf 48.9%
if 1.59999999999999993e29 < z Initial program 91.8%
associate-+l-91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*91.8%
associate-+l-91.8%
associate-*l*91.8%
*-commutative91.8%
*-commutative91.8%
associate-*l*93.4%
associate-*l*93.5%
Simplified93.5%
Taylor expanded in x around 0 73.3%
Taylor expanded in a around 0 55.7%
*-commutative55.7%
associate-*r*59.0%
*-commutative59.0%
associate-*r*55.7%
*-commutative55.7%
associate-*r*62.0%
associate-*l*62.1%
Simplified62.1%
Taylor expanded in t around 0 55.7%
associate-*r*62.0%
Simplified62.0%
Final simplification51.9%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= z -3.7e-101) (* -9.0 (* y (* z t))) (if (<= z 9e+26) (* x 2.0) (* -9.0 (* t (* z y))))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -3.7e-101) {
tmp = -9.0 * (y * (z * t));
} else if (z <= 9e+26) {
tmp = x * 2.0;
} else {
tmp = -9.0 * (t * (z * y));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-3.7d-101)) then
tmp = (-9.0d0) * (y * (z * t))
else if (z <= 9d+26) then
tmp = x * 2.0d0
else
tmp = (-9.0d0) * (t * (z * y))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -3.7e-101) {
tmp = -9.0 * (y * (z * t));
} else if (z <= 9e+26) {
tmp = x * 2.0;
} else {
tmp = -9.0 * (t * (z * y));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if z <= -3.7e-101: tmp = -9.0 * (y * (z * t)) elif z <= 9e+26: tmp = x * 2.0 else: tmp = -9.0 * (t * (z * y)) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -3.7e-101) tmp = Float64(-9.0 * Float64(y * Float64(z * t))); elseif (z <= 9e+26) tmp = Float64(x * 2.0); else tmp = Float64(-9.0 * Float64(t * Float64(z * y))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (z <= -3.7e-101)
tmp = -9.0 * (y * (z * t));
elseif (z <= 9e+26)
tmp = x * 2.0;
else
tmp = -9.0 * (t * (z * y));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -3.7e-101], N[(-9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e+26], N[(x * 2.0), $MachinePrecision], N[(-9.0 * N[(t * N[(z * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.7 \cdot 10^{-101}:\\
\;\;\;\;-9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+26}:\\
\;\;\;\;x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;-9 \cdot \left(t \cdot \left(z \cdot y\right)\right)\\
\end{array}
\end{array}
if z < -3.70000000000000005e-101Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.6%
associate-+l-94.6%
associate-*l*95.6%
*-commutative95.6%
*-commutative95.6%
associate-*l*94.4%
associate-*l*94.4%
Simplified94.4%
Taylor expanded in x around 0 76.6%
Taylor expanded in a around 0 48.8%
*-commutative48.8%
associate-*r*48.9%
*-commutative48.9%
associate-*r*48.8%
*-commutative48.8%
associate-*r*48.9%
associate-*l*48.8%
Simplified48.8%
Taylor expanded in t around 0 48.8%
*-commutative48.8%
associate-*l*48.9%
*-commutative48.9%
Simplified48.9%
if -3.70000000000000005e-101 < z < 8.99999999999999957e26Initial program 99.0%
+-commutative99.0%
associate-+r-99.0%
*-commutative99.0%
cancel-sign-sub-inv99.0%
associate-*r*92.9%
distribute-lft-neg-in92.9%
*-commutative92.9%
cancel-sign-sub-inv92.9%
associate-+r-92.9%
associate-*l*92.9%
fma-define92.9%
cancel-sign-sub-inv92.9%
fma-define92.9%
distribute-lft-neg-in92.9%
distribute-rgt-neg-in92.9%
*-commutative92.9%
associate-*r*99.0%
associate-*l*98.9%
neg-mul-198.9%
associate-*r*98.9%
Simplified98.9%
Taylor expanded in t around 0 82.1%
Taylor expanded in x around inf 48.9%
if 8.99999999999999957e26 < z Initial program 91.8%
+-commutative91.8%
associate-+r-91.8%
*-commutative91.8%
cancel-sign-sub-inv91.8%
associate-*r*99.7%
distribute-lft-neg-in99.7%
*-commutative99.7%
cancel-sign-sub-inv99.7%
associate-+r-99.7%
associate-*l*99.8%
fma-define99.8%
cancel-sign-sub-inv99.8%
fma-define99.8%
distribute-lft-neg-in99.8%
distribute-rgt-neg-in99.8%
*-commutative99.8%
associate-*r*91.8%
associate-*l*91.9%
neg-mul-191.9%
associate-*r*91.9%
Simplified91.9%
Taylor expanded in t around inf 55.7%
Final simplification50.5%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (+ (* z (* y (* t -9.0))) (+ (* 27.0 (* a b)) (* x 2.0))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
return (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0));
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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
code = (z * (y * (t * (-9.0d0)))) + ((27.0d0 * (a * b)) + (x * 2.0d0))
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
return (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0));
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): return (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0))
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) return Float64(Float64(z * Float64(y * Float64(t * -9.0))) + Float64(Float64(27.0 * Float64(a * b)) + Float64(x * 2.0))) end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp = code(x, y, z, t, a, b)
tmp = (z * (y * (t * -9.0))) + ((27.0 * (a * b)) + (x * 2.0));
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := N[(N[(z * N[(y * N[(t * -9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
z \cdot \left(y \cdot \left(t \cdot -9\right)\right) + \left(27 \cdot \left(a \cdot b\right) + x \cdot 2\right)
\end{array}
Initial program 96.1%
+-commutative96.1%
associate-+r-96.1%
*-commutative96.1%
cancel-sign-sub-inv96.1%
associate-*r*96.3%
distribute-lft-neg-in96.3%
*-commutative96.3%
cancel-sign-sub-inv96.3%
associate-+r-96.3%
associate-*l*96.3%
fma-define96.3%
cancel-sign-sub-inv96.3%
fma-define96.3%
distribute-lft-neg-in96.3%
distribute-rgt-neg-in96.3%
*-commutative96.3%
associate-*r*96.1%
associate-*l*95.8%
neg-mul-195.8%
associate-*r*95.8%
Simplified95.8%
fma-undefine95.8%
fma-undefine95.8%
associate-+r+95.8%
*-commutative95.8%
associate-*l*96.1%
*-commutative96.1%
associate-*r*96.1%
*-commutative96.1%
associate-*r*96.1%
*-commutative96.1%
associate-*l*96.1%
*-commutative96.1%
associate-*l*96.3%
Applied egg-rr96.3%
Final simplification96.3%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= t 6.2e+74) (+ (* 27.0 (* a b)) (* x 2.0)) (+ (* x 2.0) (* -9.0 (* t (* z y))))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= 6.2e+74) {
tmp = (27.0 * (a * b)) + (x * 2.0);
} else {
tmp = (x * 2.0) + (-9.0 * (t * (z * y)));
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (t <= 6.2d+74) then
tmp = (27.0d0 * (a * b)) + (x * 2.0d0)
else
tmp = (x * 2.0d0) + ((-9.0d0) * (t * (z * y)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= 6.2e+74) {
tmp = (27.0 * (a * b)) + (x * 2.0);
} else {
tmp = (x * 2.0) + (-9.0 * (t * (z * y)));
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if t <= 6.2e+74: tmp = (27.0 * (a * b)) + (x * 2.0) else: tmp = (x * 2.0) + (-9.0 * (t * (z * y))) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (t <= 6.2e+74) tmp = Float64(Float64(27.0 * Float64(a * b)) + Float64(x * 2.0)); else tmp = Float64(Float64(x * 2.0) + Float64(-9.0 * Float64(t * Float64(z * y)))); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (t <= 6.2e+74)
tmp = (27.0 * (a * b)) + (x * 2.0);
else
tmp = (x * 2.0) + (-9.0 * (t * (z * y)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, 6.2e+74], N[(N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], N[(N[(x * 2.0), $MachinePrecision] + N[(-9.0 * N[(t * N[(z * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq 6.2 \cdot 10^{+74}:\\
\;\;\;\;27 \cdot \left(a \cdot b\right) + x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;x \cdot 2 + -9 \cdot \left(t \cdot \left(z \cdot y\right)\right)\\
\end{array}
\end{array}
if t < 6.20000000000000043e74Initial program 95.8%
+-commutative95.8%
associate-+r-95.8%
*-commutative95.8%
cancel-sign-sub-inv95.8%
associate-*r*96.9%
distribute-lft-neg-in96.9%
*-commutative96.9%
cancel-sign-sub-inv96.9%
associate-+r-97.0%
associate-*l*97.0%
fma-define97.0%
cancel-sign-sub-inv97.0%
fma-define97.0%
distribute-lft-neg-in97.0%
distribute-rgt-neg-in97.0%
*-commutative97.0%
associate-*r*95.8%
associate-*l*95.4%
neg-mul-195.4%
associate-*r*95.4%
Simplified95.4%
Taylor expanded in t around 0 67.7%
if 6.20000000000000043e74 < t Initial program 97.7%
+-commutative97.7%
associate-+r-97.7%
*-commutative97.7%
cancel-sign-sub-inv97.7%
associate-*r*93.4%
distribute-lft-neg-in93.4%
*-commutative93.4%
cancel-sign-sub-inv93.4%
associate-+r-93.4%
associate-*l*93.4%
fma-define93.4%
cancel-sign-sub-inv93.4%
fma-define93.4%
distribute-lft-neg-in93.4%
distribute-rgt-neg-in93.4%
*-commutative93.4%
associate-*r*97.7%
associate-*l*97.7%
neg-mul-197.7%
associate-*r*97.7%
Simplified97.7%
Taylor expanded in a around 0 82.5%
Final simplification70.3%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (or (<= b -1.6e-77) (not (<= b 2.1e+107))) (* a (* 27.0 b)) (* x 2.0)))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.6e-77) || !(b <= 2.1e+107)) {
tmp = a * (27.0 * b);
} else {
tmp = x * 2.0;
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((b <= (-1.6d-77)) .or. (.not. (b <= 2.1d+107))) then
tmp = a * (27.0d0 * b)
else
tmp = x * 2.0d0
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -1.6e-77) || !(b <= 2.1e+107)) {
tmp = a * (27.0 * b);
} else {
tmp = x * 2.0;
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if (b <= -1.6e-77) or not (b <= 2.1e+107): tmp = a * (27.0 * b) else: tmp = x * 2.0 return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -1.6e-77) || !(b <= 2.1e+107)) tmp = Float64(a * Float64(27.0 * b)); else tmp = Float64(x * 2.0); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if ((b <= -1.6e-77) || ~((b <= 2.1e+107)))
tmp = a * (27.0 * b);
else
tmp = x * 2.0;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -1.6e-77], N[Not[LessEqual[b, 2.1e+107]], $MachinePrecision]], N[(a * N[(27.0 * b), $MachinePrecision]), $MachinePrecision], N[(x * 2.0), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.6 \cdot 10^{-77} \lor \neg \left(b \leq 2.1 \cdot 10^{+107}\right):\\
\;\;\;\;a \cdot \left(27 \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot 2\\
\end{array}
\end{array}
if b < -1.6e-77 or 2.1e107 < b Initial program 96.0%
+-commutative96.0%
associate-+r-96.0%
*-commutative96.0%
cancel-sign-sub-inv96.0%
associate-*r*98.6%
distribute-lft-neg-in98.6%
*-commutative98.6%
cancel-sign-sub-inv98.6%
associate-+r-98.6%
associate-*l*98.6%
fma-define98.6%
cancel-sign-sub-inv98.6%
fma-define98.6%
distribute-lft-neg-in98.6%
distribute-rgt-neg-in98.6%
*-commutative98.6%
associate-*r*96.0%
associate-*l*96.0%
neg-mul-196.0%
associate-*r*96.0%
Simplified96.0%
Taylor expanded in t around 0 68.7%
Taylor expanded in x around 0 52.1%
associate-*r*52.2%
*-commutative52.2%
associate-*r*52.2%
Simplified52.2%
if -1.6e-77 < b < 2.1e107Initial program 96.3%
+-commutative96.3%
associate-+r-96.3%
*-commutative96.3%
cancel-sign-sub-inv96.3%
associate-*r*94.2%
distribute-lft-neg-in94.2%
*-commutative94.2%
cancel-sign-sub-inv94.2%
associate-+r-94.2%
associate-*l*94.2%
fma-define94.2%
cancel-sign-sub-inv94.2%
fma-define94.2%
distribute-lft-neg-in94.2%
distribute-rgt-neg-in94.2%
*-commutative94.2%
associate-*r*96.3%
associate-*l*95.6%
neg-mul-195.6%
associate-*r*95.6%
Simplified95.6%
Taylor expanded in t around 0 55.1%
Taylor expanded in x around inf 44.8%
Final simplification48.3%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (or (<= b -3.4e-77) (not (<= b 6.2e+109))) (* 27.0 (* a b)) (* x 2.0)))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -3.4e-77) || !(b <= 6.2e+109)) {
tmp = 27.0 * (a * b);
} else {
tmp = x * 2.0;
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((b <= (-3.4d-77)) .or. (.not. (b <= 6.2d+109))) then
tmp = 27.0d0 * (a * b)
else
tmp = x * 2.0d0
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -3.4e-77) || !(b <= 6.2e+109)) {
tmp = 27.0 * (a * b);
} else {
tmp = x * 2.0;
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if (b <= -3.4e-77) or not (b <= 6.2e+109): tmp = 27.0 * (a * b) else: tmp = x * 2.0 return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -3.4e-77) || !(b <= 6.2e+109)) tmp = Float64(27.0 * Float64(a * b)); else tmp = Float64(x * 2.0); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if ((b <= -3.4e-77) || ~((b <= 6.2e+109)))
tmp = 27.0 * (a * b);
else
tmp = x * 2.0;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -3.4e-77], N[Not[LessEqual[b, 6.2e+109]], $MachinePrecision]], N[(27.0 * N[(a * b), $MachinePrecision]), $MachinePrecision], N[(x * 2.0), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.4 \cdot 10^{-77} \lor \neg \left(b \leq 6.2 \cdot 10^{+109}\right):\\
\;\;\;\;27 \cdot \left(a \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot 2\\
\end{array}
\end{array}
if b < -3.39999999999999983e-77 or 6.19999999999999985e109 < b Initial program 96.0%
+-commutative96.0%
associate-+r-96.0%
*-commutative96.0%
cancel-sign-sub-inv96.0%
associate-*r*98.6%
distribute-lft-neg-in98.6%
*-commutative98.6%
cancel-sign-sub-inv98.6%
associate-+r-98.6%
associate-*l*98.6%
fma-define98.6%
cancel-sign-sub-inv98.6%
fma-define98.6%
distribute-lft-neg-in98.6%
distribute-rgt-neg-in98.6%
*-commutative98.6%
associate-*r*96.0%
associate-*l*96.0%
neg-mul-196.0%
associate-*r*96.0%
Simplified96.0%
Taylor expanded in a around inf 52.1%
if -3.39999999999999983e-77 < b < 6.19999999999999985e109Initial program 96.3%
+-commutative96.3%
associate-+r-96.3%
*-commutative96.3%
cancel-sign-sub-inv96.3%
associate-*r*94.2%
distribute-lft-neg-in94.2%
*-commutative94.2%
cancel-sign-sub-inv94.2%
associate-+r-94.2%
associate-*l*94.2%
fma-define94.2%
cancel-sign-sub-inv94.2%
fma-define94.2%
distribute-lft-neg-in94.2%
distribute-rgt-neg-in94.2%
*-commutative94.2%
associate-*r*96.3%
associate-*l*95.6%
neg-mul-195.6%
associate-*r*95.6%
Simplified95.6%
Taylor expanded in t around 0 55.1%
Taylor expanded in x around inf 44.8%
Final simplification48.2%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (if (<= b -5.5e-87) (* b (* a 27.0)) (if (<= b 5.5e+105) (* x 2.0) (* a (* 27.0 b)))))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -5.5e-87) {
tmp = b * (a * 27.0);
} else if (b <= 5.5e+105) {
tmp = x * 2.0;
} else {
tmp = a * (27.0 * b);
}
return tmp;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (b <= (-5.5d-87)) then
tmp = b * (a * 27.0d0)
else if (b <= 5.5d+105) then
tmp = x * 2.0d0
else
tmp = a * (27.0d0 * b)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -5.5e-87) {
tmp = b * (a * 27.0);
} else if (b <= 5.5e+105) {
tmp = x * 2.0;
} else {
tmp = a * (27.0 * b);
}
return tmp;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): tmp = 0 if b <= -5.5e-87: tmp = b * (a * 27.0) elif b <= 5.5e+105: tmp = x * 2.0 else: tmp = a * (27.0 * b) return tmp
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -5.5e-87) tmp = Float64(b * Float64(a * 27.0)); elseif (b <= 5.5e+105) tmp = Float64(x * 2.0); else tmp = Float64(a * Float64(27.0 * b)); end return tmp end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp_2 = code(x, y, z, t, a, b)
tmp = 0.0;
if (b <= -5.5e-87)
tmp = b * (a * 27.0);
elseif (b <= 5.5e+105)
tmp = x * 2.0;
else
tmp = a * (27.0 * b);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -5.5e-87], N[(b * N[(a * 27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 5.5e+105], N[(x * 2.0), $MachinePrecision], N[(a * N[(27.0 * b), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
\begin{array}{l}
\mathbf{if}\;b \leq -5.5 \cdot 10^{-87}:\\
\;\;\;\;b \cdot \left(a \cdot 27\right)\\
\mathbf{elif}\;b \leq 5.5 \cdot 10^{+105}:\\
\;\;\;\;x \cdot 2\\
\mathbf{else}:\\
\;\;\;\;a \cdot \left(27 \cdot b\right)\\
\end{array}
\end{array}
if b < -5.5000000000000004e-87Initial program 97.5%
+-commutative97.5%
associate-+r-97.5%
*-commutative97.5%
cancel-sign-sub-inv97.5%
associate-*r*98.0%
distribute-lft-neg-in98.0%
*-commutative98.0%
cancel-sign-sub-inv98.0%
associate-+r-98.0%
associate-*l*97.9%
fma-define97.9%
cancel-sign-sub-inv97.9%
fma-define97.9%
distribute-lft-neg-in97.9%
distribute-rgt-neg-in97.9%
*-commutative97.9%
associate-*r*97.4%
associate-*l*97.4%
neg-mul-197.4%
associate-*r*97.4%
Simplified97.4%
Taylor expanded in t around 0 65.3%
Taylor expanded in b around inf 64.4%
Taylor expanded in x around 0 48.8%
if -5.5000000000000004e-87 < b < 5.49999999999999979e105Initial program 96.2%
+-commutative96.2%
associate-+r-96.2%
*-commutative96.2%
cancel-sign-sub-inv96.2%
associate-*r*94.2%
distribute-lft-neg-in94.2%
*-commutative94.2%
cancel-sign-sub-inv94.2%
associate-+r-94.2%
associate-*l*94.2%
fma-define94.2%
cancel-sign-sub-inv94.2%
fma-define94.2%
distribute-lft-neg-in94.2%
distribute-rgt-neg-in94.2%
*-commutative94.2%
associate-*r*96.2%
associate-*l*95.5%
neg-mul-195.5%
associate-*r*95.5%
Simplified95.5%
Taylor expanded in t around 0 55.0%
Taylor expanded in x around inf 44.7%
if 5.49999999999999979e105 < b Initial program 93.5%
+-commutative93.5%
associate-+r-93.5%
*-commutative93.5%
cancel-sign-sub-inv93.5%
associate-*r*99.7%
distribute-lft-neg-in99.7%
*-commutative99.7%
cancel-sign-sub-inv99.7%
associate-+r-99.8%
associate-*l*99.9%
fma-define99.9%
cancel-sign-sub-inv99.9%
fma-define99.9%
distribute-lft-neg-in99.9%
distribute-rgt-neg-in99.9%
*-commutative99.9%
associate-*r*93.7%
associate-*l*93.6%
neg-mul-193.6%
associate-*r*93.6%
Simplified93.6%
Taylor expanded in t around 0 74.2%
Taylor expanded in x around 0 57.0%
associate-*r*57.0%
*-commutative57.0%
associate-*r*57.1%
Simplified57.1%
Final simplification48.1%
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. (FPCore (x y z t a b) :precision binary64 (* x 2.0))
assert(x < y && y < z && z < t && t < a && a < b);
assert(x < y && y < z && z < t && t < a && a < b);
double code(double x, double y, double z, double t, double a, double b) {
return x * 2.0;
}
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b)
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
code = x * 2.0d0
end function
assert x < y && y < z && z < t && t < a && a < b;
assert x < y && y < z && z < t && t < a && a < b;
public static double code(double x, double y, double z, double t, double a, double b) {
return x * 2.0;
}
[x, y, z, t, a, b] = sort([x, y, z, t, a, b]) [x, y, z, t, a, b] = sort([x, y, z, t, a, b]) def code(x, y, z, t, a, b): return x * 2.0
x, y, z, t, a, b = sort([x, y, z, t, a, b]) x, y, z, t, a, b = sort([x, y, z, t, a, b]) function code(x, y, z, t, a, b) return Float64(x * 2.0) end
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
x, y, z, t, a, b = num2cell(sort([x, y, z, t, a, b])){:}
function tmp = code(x, y, z, t, a, b)
tmp = x * 2.0;
end
NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, and b should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_] := N[(x * 2.0), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\\\
[x, y, z, t, a, b] = \mathsf{sort}([x, y, z, t, a, b])\\
\\
x \cdot 2
\end{array}
Initial program 96.1%
+-commutative96.1%
associate-+r-96.1%
*-commutative96.1%
cancel-sign-sub-inv96.1%
associate-*r*96.3%
distribute-lft-neg-in96.3%
*-commutative96.3%
cancel-sign-sub-inv96.3%
associate-+r-96.3%
associate-*l*96.3%
fma-define96.3%
cancel-sign-sub-inv96.3%
fma-define96.3%
distribute-lft-neg-in96.3%
distribute-rgt-neg-in96.3%
*-commutative96.3%
associate-*r*96.1%
associate-*l*95.8%
neg-mul-195.8%
associate-*r*95.8%
Simplified95.8%
Taylor expanded in t around 0 61.5%
Taylor expanded in x around inf 32.2%
Final simplification32.2%
(FPCore (x y z t a b) :precision binary64 (if (< y 7.590524218811189e-161) (+ (- (* x 2.0) (* (* (* y 9.0) z) t)) (* a (* 27.0 b))) (+ (- (* x 2.0) (* 9.0 (* y (* t z)))) (* (* a 27.0) b))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y < 7.590524218811189e-161) {
tmp = ((x * 2.0) - (((y * 9.0) * z) * t)) + (a * (27.0 * b));
} else {
tmp = ((x * 2.0) - (9.0 * (y * (t * z)))) + ((a * 27.0) * b);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (y < 7.590524218811189d-161) then
tmp = ((x * 2.0d0) - (((y * 9.0d0) * z) * t)) + (a * (27.0d0 * b))
else
tmp = ((x * 2.0d0) - (9.0d0 * (y * (t * z)))) + ((a * 27.0d0) * b)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y < 7.590524218811189e-161) {
tmp = ((x * 2.0) - (((y * 9.0) * z) * t)) + (a * (27.0 * b));
} else {
tmp = ((x * 2.0) - (9.0 * (y * (t * z)))) + ((a * 27.0) * b);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y < 7.590524218811189e-161: tmp = ((x * 2.0) - (((y * 9.0) * z) * t)) + (a * (27.0 * b)) else: tmp = ((x * 2.0) - (9.0 * (y * (t * z)))) + ((a * 27.0) * b) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y < 7.590524218811189e-161) tmp = Float64(Float64(Float64(x * 2.0) - Float64(Float64(Float64(y * 9.0) * z) * t)) + Float64(a * Float64(27.0 * b))); else tmp = Float64(Float64(Float64(x * 2.0) - Float64(9.0 * Float64(y * Float64(t * z)))) + Float64(Float64(a * 27.0) * b)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y < 7.590524218811189e-161) tmp = ((x * 2.0) - (((y * 9.0) * z) * t)) + (a * (27.0 * b)); else tmp = ((x * 2.0) - (9.0 * (y * (t * z)))) + ((a * 27.0) * b); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Less[y, 7.590524218811189e-161], N[(N[(N[(x * 2.0), $MachinePrecision] - N[(N[(N[(y * 9.0), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(27.0 * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x * 2.0), $MachinePrecision] - N[(9.0 * N[(y * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(a * 27.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y < 7.590524218811189 \cdot 10^{-161}:\\
\;\;\;\;\left(x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\right) + a \cdot \left(27 \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot 2 - 9 \cdot \left(y \cdot \left(t \cdot z\right)\right)\right) + \left(a \cdot 27\right) \cdot b\\
\end{array}
\end{array}
herbie shell --seed 2024132
(FPCore (x y z t a b)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, A"
:precision binary64
:alt
(! :herbie-platform default (if (< y 7590524218811189/100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (* x 2) (* (* (* y 9) z) t)) (* a (* 27 b))) (+ (- (* x 2) (* 9 (* y (* t z)))) (* (* a 27) b))))
(+ (- (* x 2.0) (* (* (* y 9.0) z) t)) (* (* a 27.0) b)))