
(FPCore (x y z t a b c i j) :precision binary64 (+ (- (* x (- (* y z) (* t a))) (* b (- (* c z) (* t i)))) (* j (- (* c a) (* y i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
return ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)));
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
code = ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
return ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)));
}
def code(x, y, z, t, a, b, c, i, j): return ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)))
function code(x, y, z, t, a, b, c, i, j) return Float64(Float64(Float64(x * Float64(Float64(y * z) - Float64(t * a))) - Float64(b * Float64(Float64(c * z) - Float64(t * i)))) + Float64(j * Float64(Float64(c * a) - Float64(y * i)))) end
function tmp = code(x, y, z, t, a, b, c, i, j) tmp = ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i))); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := N[(N[(N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(b * N[(N[(c * z), $MachinePrecision] - N[(t * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(N[(c * a), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - t \cdot i\right)\right) + j \cdot \left(c \cdot a - y \cdot i\right)
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 16 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i j) :precision binary64 (+ (- (* x (- (* y z) (* t a))) (* b (- (* c z) (* t i)))) (* j (- (* c a) (* y i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
return ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)));
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
code = ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
return ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)));
}
def code(x, y, z, t, a, b, c, i, j): return ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i)))
function code(x, y, z, t, a, b, c, i, j) return Float64(Float64(Float64(x * Float64(Float64(y * z) - Float64(t * a))) - Float64(b * Float64(Float64(c * z) - Float64(t * i)))) + Float64(j * Float64(Float64(c * a) - Float64(y * i)))) end
function tmp = code(x, y, z, t, a, b, c, i, j) tmp = ((x * ((y * z) - (t * a))) - (b * ((c * z) - (t * i)))) + (j * ((c * a) - (y * i))); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := N[(N[(N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(b * N[(N[(c * z), $MachinePrecision] - N[(t * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(N[(c * a), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - t \cdot i\right)\right) + j \cdot \left(c \cdot a - y \cdot i\right)
\end{array}
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* x (- (* y z) (* t a)))) (t_2 (* j (- (* a c) (* y i)))))
(if (<= (+ (+ t_1 (* b (- (* t i) (* z c)))) t_2) INFINITY)
(+ (+ t_1 (- (* b (* t i)) (* b (* z c)))) t_2)
(* a (* j (- c (* t (/ x j))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = x * ((y * z) - (t * a));
double t_2 = j * ((a * c) - (y * i));
double tmp;
if (((t_1 + (b * ((t * i) - (z * c)))) + t_2) <= ((double) INFINITY)) {
tmp = (t_1 + ((b * (t * i)) - (b * (z * c)))) + t_2;
} else {
tmp = a * (j * (c - (t * (x / j))));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = x * ((y * z) - (t * a));
double t_2 = j * ((a * c) - (y * i));
double tmp;
if (((t_1 + (b * ((t * i) - (z * c)))) + t_2) <= Double.POSITIVE_INFINITY) {
tmp = (t_1 + ((b * (t * i)) - (b * (z * c)))) + t_2;
} else {
tmp = a * (j * (c - (t * (x / j))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = x * ((y * z) - (t * a)) t_2 = j * ((a * c) - (y * i)) tmp = 0 if ((t_1 + (b * ((t * i) - (z * c)))) + t_2) <= math.inf: tmp = (t_1 + ((b * (t * i)) - (b * (z * c)))) + t_2 else: tmp = a * (j * (c - (t * (x / j)))) return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(x * Float64(Float64(y * z) - Float64(t * a))) t_2 = Float64(j * Float64(Float64(a * c) - Float64(y * i))) tmp = 0.0 if (Float64(Float64(t_1 + Float64(b * Float64(Float64(t * i) - Float64(z * c)))) + t_2) <= Inf) tmp = Float64(Float64(t_1 + Float64(Float64(b * Float64(t * i)) - Float64(b * Float64(z * c)))) + t_2); else tmp = Float64(a * Float64(j * Float64(c - Float64(t * Float64(x / j))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = x * ((y * z) - (t * a)); t_2 = j * ((a * c) - (y * i)); tmp = 0.0; if (((t_1 + (b * ((t * i) - (z * c)))) + t_2) <= Inf) tmp = (t_1 + ((b * (t * i)) - (b * (z * c)))) + t_2; else tmp = a * (j * (c - (t * (x / j)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(t$95$1 + N[(b * N[(N[(t * i), $MachinePrecision] - N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision], Infinity], N[(N[(t$95$1 + N[(N[(b * N[(t * i), $MachinePrecision]), $MachinePrecision] - N[(b * N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision], N[(a * N[(j * N[(c - N[(t * N[(x / j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(y \cdot z - t \cdot a\right)\\
t_2 := j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{if}\;\left(t\_1 + b \cdot \left(t \cdot i - z \cdot c\right)\right) + t\_2 \leq \infty:\\
\;\;\;\;\left(t\_1 + \left(b \cdot \left(t \cdot i\right) - b \cdot \left(z \cdot c\right)\right)\right) + t\_2\\
\mathbf{else}:\\
\;\;\;\;a \cdot \left(j \cdot \left(c - t \cdot \frac{x}{j}\right)\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (*.f64 x (-.f64 (*.f64 y z) (*.f64 t a))) (*.f64 b (-.f64 (*.f64 c z) (*.f64 t i)))) (*.f64 j (-.f64 (*.f64 c a) (*.f64 y i)))) < +inf.0Initial program 91.9%
sub-neg91.9%
distribute-rgt-in91.9%
*-commutative91.9%
distribute-rgt-neg-in91.9%
Applied egg-rr91.9%
if +inf.0 < (+.f64 (-.f64 (*.f64 x (-.f64 (*.f64 y z) (*.f64 t a))) (*.f64 b (-.f64 (*.f64 c z) (*.f64 t i)))) (*.f64 j (-.f64 (*.f64 c a) (*.f64 y i)))) Initial program 0.0%
Taylor expanded in a around inf 45.0%
+-commutative45.0%
mul-1-neg45.0%
unsub-neg45.0%
Simplified45.0%
Taylor expanded in j around inf 51.7%
mul-1-neg51.7%
unsub-neg51.7%
associate-/l*51.7%
Simplified51.7%
Final simplification85.1%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1
(+
(+ (* x (- (* y z) (* t a))) (* b (- (* t i) (* z c))))
(* j (- (* a c) (* y i))))))
(if (<= t_1 INFINITY) t_1 (* a (* j (- c (* t (/ x j))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = ((x * ((y * z) - (t * a))) + (b * ((t * i) - (z * c)))) + (j * ((a * c) - (y * i)));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = a * (j * (c - (t * (x / j))));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = ((x * ((y * z) - (t * a))) + (b * ((t * i) - (z * c)))) + (j * ((a * c) - (y * i)));
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = a * (j * (c - (t * (x / j))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = ((x * ((y * z) - (t * a))) + (b * ((t * i) - (z * c)))) + (j * ((a * c) - (y * i))) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = a * (j * (c - (t * (x / j)))) return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(Float64(Float64(x * Float64(Float64(y * z) - Float64(t * a))) + Float64(b * Float64(Float64(t * i) - Float64(z * c)))) + Float64(j * Float64(Float64(a * c) - Float64(y * i)))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(a * Float64(j * Float64(c - Float64(t * Float64(x / j))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = ((x * ((y * z) - (t * a))) + (b * ((t * i) - (z * c)))) + (j * ((a * c) - (y * i))); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = a * (j * (c - (t * (x / j)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(N[(N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * N[(N[(t * i), $MachinePrecision] - N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(a * N[(j * N[(c - N[(t * N[(x / j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x \cdot \left(y \cdot z - t \cdot a\right) + b \cdot \left(t \cdot i - z \cdot c\right)\right) + j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot \left(j \cdot \left(c - t \cdot \frac{x}{j}\right)\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (*.f64 x (-.f64 (*.f64 y z) (*.f64 t a))) (*.f64 b (-.f64 (*.f64 c z) (*.f64 t i)))) (*.f64 j (-.f64 (*.f64 c a) (*.f64 y i)))) < +inf.0Initial program 91.9%
if +inf.0 < (+.f64 (-.f64 (*.f64 x (-.f64 (*.f64 y z) (*.f64 t a))) (*.f64 b (-.f64 (*.f64 c z) (*.f64 t i)))) (*.f64 j (-.f64 (*.f64 c a) (*.f64 y i)))) Initial program 0.0%
Taylor expanded in a around inf 45.0%
+-commutative45.0%
mul-1-neg45.0%
unsub-neg45.0%
Simplified45.0%
Taylor expanded in j around inf 51.7%
mul-1-neg51.7%
unsub-neg51.7%
associate-/l*51.7%
Simplified51.7%
Final simplification85.1%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* j (- (* a c) (* y i)))))
(if (<= j -5.1e+94)
t_1
(if (<= j 2.7e+82)
(- (- (* b (* t i)) (* x (- (* t a) (* y z)))) (* b (* z c)))
(+ t_1 (* x (- (* y z) (* t a))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((a * c) - (y * i));
double tmp;
if (j <= -5.1e+94) {
tmp = t_1;
} else if (j <= 2.7e+82) {
tmp = ((b * (t * i)) - (x * ((t * a) - (y * z)))) - (b * (z * c));
} else {
tmp = t_1 + (x * ((y * z) - (t * a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: tmp
t_1 = j * ((a * c) - (y * i))
if (j <= (-5.1d+94)) then
tmp = t_1
else if (j <= 2.7d+82) then
tmp = ((b * (t * i)) - (x * ((t * a) - (y * z)))) - (b * (z * c))
else
tmp = t_1 + (x * ((y * z) - (t * a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((a * c) - (y * i));
double tmp;
if (j <= -5.1e+94) {
tmp = t_1;
} else if (j <= 2.7e+82) {
tmp = ((b * (t * i)) - (x * ((t * a) - (y * z)))) - (b * (z * c));
} else {
tmp = t_1 + (x * ((y * z) - (t * a)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = j * ((a * c) - (y * i)) tmp = 0 if j <= -5.1e+94: tmp = t_1 elif j <= 2.7e+82: tmp = ((b * (t * i)) - (x * ((t * a) - (y * z)))) - (b * (z * c)) else: tmp = t_1 + (x * ((y * z) - (t * a))) return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(j * Float64(Float64(a * c) - Float64(y * i))) tmp = 0.0 if (j <= -5.1e+94) tmp = t_1; elseif (j <= 2.7e+82) tmp = Float64(Float64(Float64(b * Float64(t * i)) - Float64(x * Float64(Float64(t * a) - Float64(y * z)))) - Float64(b * Float64(z * c))); else tmp = Float64(t_1 + Float64(x * Float64(Float64(y * z) - Float64(t * a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = j * ((a * c) - (y * i)); tmp = 0.0; if (j <= -5.1e+94) tmp = t_1; elseif (j <= 2.7e+82) tmp = ((b * (t * i)) - (x * ((t * a) - (y * z)))) - (b * (z * c)); else tmp = t_1 + (x * ((y * z) - (t * a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -5.1e+94], t$95$1, If[LessEqual[j, 2.7e+82], N[(N[(N[(b * N[(t * i), $MachinePrecision]), $MachinePrecision] - N[(x * N[(N[(t * a), $MachinePrecision] - N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(b * N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{if}\;j \leq -5.1 \cdot 10^{+94}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq 2.7 \cdot 10^{+82}:\\
\;\;\;\;\left(b \cdot \left(t \cdot i\right) - x \cdot \left(t \cdot a - y \cdot z\right)\right) - b \cdot \left(z \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1 + x \cdot \left(y \cdot z - t \cdot a\right)\\
\end{array}
\end{array}
if j < -5.1000000000000003e94Initial program 78.2%
sub-neg78.2%
distribute-rgt-in78.2%
*-commutative78.2%
distribute-rgt-neg-in78.2%
Applied egg-rr78.2%
Taylor expanded in j around inf 78.1%
*-commutative78.1%
Simplified78.1%
if -5.1000000000000003e94 < j < 2.6999999999999999e82Initial program 74.8%
Taylor expanded in j around 0 74.7%
*-commutative74.7%
*-commutative74.7%
Simplified74.7%
Taylor expanded in i around 0 74.7%
if 2.6999999999999999e82 < j Initial program 81.0%
Taylor expanded in b around 0 81.4%
Final simplification76.4%
(FPCore (x y z t a b c i j) :precision binary64 (if (or (<= b -2.7e+46) (not (<= b 360000000000.0))) (+ (* z (* x y)) (* b (- (* t i) (* z c)))) (+ (* j (- (* a c) (* y i))) (* x (- (* y z) (* t a))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((b <= -2.7e+46) || !(b <= 360000000000.0)) {
tmp = (z * (x * y)) + (b * ((t * i) - (z * c)));
} else {
tmp = (j * ((a * c) - (y * i))) + (x * ((y * z) - (t * a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if ((b <= (-2.7d+46)) .or. (.not. (b <= 360000000000.0d0))) then
tmp = (z * (x * y)) + (b * ((t * i) - (z * c)))
else
tmp = (j * ((a * c) - (y * i))) + (x * ((y * z) - (t * a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((b <= -2.7e+46) || !(b <= 360000000000.0)) {
tmp = (z * (x * y)) + (b * ((t * i) - (z * c)));
} else {
tmp = (j * ((a * c) - (y * i))) + (x * ((y * z) - (t * a)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if (b <= -2.7e+46) or not (b <= 360000000000.0): tmp = (z * (x * y)) + (b * ((t * i) - (z * c))) else: tmp = (j * ((a * c) - (y * i))) + (x * ((y * z) - (t * a))) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if ((b <= -2.7e+46) || !(b <= 360000000000.0)) tmp = Float64(Float64(z * Float64(x * y)) + Float64(b * Float64(Float64(t * i) - Float64(z * c)))); else tmp = Float64(Float64(j * Float64(Float64(a * c) - Float64(y * i))) + Float64(x * Float64(Float64(y * z) - Float64(t * a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if ((b <= -2.7e+46) || ~((b <= 360000000000.0))) tmp = (z * (x * y)) + (b * ((t * i) - (z * c))); else tmp = (j * ((a * c) - (y * i))) + (x * ((y * z) - (t * a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[Or[LessEqual[b, -2.7e+46], N[Not[LessEqual[b, 360000000000.0]], $MachinePrecision]], N[(N[(z * N[(x * y), $MachinePrecision]), $MachinePrecision] + N[(b * N[(N[(t * i), $MachinePrecision] - N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -2.7 \cdot 10^{+46} \lor \neg \left(b \leq 360000000000\right):\\
\;\;\;\;z \cdot \left(x \cdot y\right) + b \cdot \left(t \cdot i - z \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;j \cdot \left(a \cdot c - y \cdot i\right) + x \cdot \left(y \cdot z - t \cdot a\right)\\
\end{array}
\end{array}
if b < -2.7000000000000002e46 or 3.6e11 < b Initial program 76.0%
Taylor expanded in j around 0 73.5%
*-commutative73.5%
*-commutative73.5%
Simplified73.5%
Taylor expanded in a around 0 72.8%
associate-*r*71.9%
*-commutative71.9%
Simplified71.9%
if -2.7000000000000002e46 < b < 3.6e11Initial program 76.7%
Taylor expanded in b around 0 76.3%
Final simplification74.5%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* x (- (* y z) (* t a)))) (t_2 (* j (- (* a c) (* y i)))))
(if (<= j -1.55e+99)
t_2
(if (<= j 1.45e+83) (+ t_1 (* b (- (* t i) (* z c)))) (+ t_2 t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = x * ((y * z) - (t * a));
double t_2 = j * ((a * c) - (y * i));
double tmp;
if (j <= -1.55e+99) {
tmp = t_2;
} else if (j <= 1.45e+83) {
tmp = t_1 + (b * ((t * i) - (z * c)));
} else {
tmp = t_2 + t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x * ((y * z) - (t * a))
t_2 = j * ((a * c) - (y * i))
if (j <= (-1.55d+99)) then
tmp = t_2
else if (j <= 1.45d+83) then
tmp = t_1 + (b * ((t * i) - (z * c)))
else
tmp = t_2 + t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = x * ((y * z) - (t * a));
double t_2 = j * ((a * c) - (y * i));
double tmp;
if (j <= -1.55e+99) {
tmp = t_2;
} else if (j <= 1.45e+83) {
tmp = t_1 + (b * ((t * i) - (z * c)));
} else {
tmp = t_2 + t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = x * ((y * z) - (t * a)) t_2 = j * ((a * c) - (y * i)) tmp = 0 if j <= -1.55e+99: tmp = t_2 elif j <= 1.45e+83: tmp = t_1 + (b * ((t * i) - (z * c))) else: tmp = t_2 + t_1 return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(x * Float64(Float64(y * z) - Float64(t * a))) t_2 = Float64(j * Float64(Float64(a * c) - Float64(y * i))) tmp = 0.0 if (j <= -1.55e+99) tmp = t_2; elseif (j <= 1.45e+83) tmp = Float64(t_1 + Float64(b * Float64(Float64(t * i) - Float64(z * c)))); else tmp = Float64(t_2 + t_1); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = x * ((y * z) - (t * a)); t_2 = j * ((a * c) - (y * i)); tmp = 0.0; if (j <= -1.55e+99) tmp = t_2; elseif (j <= 1.45e+83) tmp = t_1 + (b * ((t * i) - (z * c))); else tmp = t_2 + t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -1.55e+99], t$95$2, If[LessEqual[j, 1.45e+83], N[(t$95$1 + N[(b * N[(N[(t * i), $MachinePrecision] - N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$2 + t$95$1), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(y \cdot z - t \cdot a\right)\\
t_2 := j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{if}\;j \leq -1.55 \cdot 10^{+99}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;j \leq 1.45 \cdot 10^{+83}:\\
\;\;\;\;t\_1 + b \cdot \left(t \cdot i - z \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2 + t\_1\\
\end{array}
\end{array}
if j < -1.55e99Initial program 78.2%
sub-neg78.2%
distribute-rgt-in78.2%
*-commutative78.2%
distribute-rgt-neg-in78.2%
Applied egg-rr78.2%
Taylor expanded in j around inf 78.1%
*-commutative78.1%
Simplified78.1%
if -1.55e99 < j < 1.45e83Initial program 74.8%
Taylor expanded in j around 0 74.7%
*-commutative74.7%
*-commutative74.7%
Simplified74.7%
if 1.45e83 < j Initial program 81.0%
Taylor expanded in b around 0 81.4%
Final simplification76.4%
(FPCore (x y z t a b c i j) :precision binary64 (if (or (<= j -3.3e+96) (not (<= j 8.5e+82))) (* j (- (* a c) (* y i))) (- (* b (* t i)) (* x (- (* t a) (* y z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((j <= -3.3e+96) || !(j <= 8.5e+82)) {
tmp = j * ((a * c) - (y * i));
} else {
tmp = (b * (t * i)) - (x * ((t * a) - (y * z)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if ((j <= (-3.3d+96)) .or. (.not. (j <= 8.5d+82))) then
tmp = j * ((a * c) - (y * i))
else
tmp = (b * (t * i)) - (x * ((t * a) - (y * z)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((j <= -3.3e+96) || !(j <= 8.5e+82)) {
tmp = j * ((a * c) - (y * i));
} else {
tmp = (b * (t * i)) - (x * ((t * a) - (y * z)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if (j <= -3.3e+96) or not (j <= 8.5e+82): tmp = j * ((a * c) - (y * i)) else: tmp = (b * (t * i)) - (x * ((t * a) - (y * z))) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if ((j <= -3.3e+96) || !(j <= 8.5e+82)) tmp = Float64(j * Float64(Float64(a * c) - Float64(y * i))); else tmp = Float64(Float64(b * Float64(t * i)) - Float64(x * Float64(Float64(t * a) - Float64(y * z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if ((j <= -3.3e+96) || ~((j <= 8.5e+82))) tmp = j * ((a * c) - (y * i)); else tmp = (b * (t * i)) - (x * ((t * a) - (y * z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[Or[LessEqual[j, -3.3e+96], N[Not[LessEqual[j, 8.5e+82]], $MachinePrecision]], N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * N[(t * i), $MachinePrecision]), $MachinePrecision] - N[(x * N[(N[(t * a), $MachinePrecision] - N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;j \leq -3.3 \cdot 10^{+96} \lor \neg \left(j \leq 8.5 \cdot 10^{+82}\right):\\
\;\;\;\;j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(t \cdot i\right) - x \cdot \left(t \cdot a - y \cdot z\right)\\
\end{array}
\end{array}
if j < -3.29999999999999984e96 or 8.4999999999999995e82 < j Initial program 79.5%
sub-neg79.5%
distribute-rgt-in79.5%
*-commutative79.5%
distribute-rgt-neg-in79.5%
Applied egg-rr79.5%
Taylor expanded in j around inf 75.2%
*-commutative75.2%
Simplified75.2%
if -3.29999999999999984e96 < j < 8.4999999999999995e82Initial program 74.8%
Taylor expanded in j around 0 74.7%
*-commutative74.7%
*-commutative74.7%
Simplified74.7%
Taylor expanded in i around 0 74.7%
Taylor expanded in c around 0 63.9%
Final simplification67.8%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* j (- (* a c) (* y i)))))
(if (<= j -1.6e+94)
t_1
(if (<= j -5e-89)
(- (* x (* t (- a))) (* b (* z c)))
(if (<= j 1e+87) (* t (- (* b i) (* x a))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((a * c) - (y * i));
double tmp;
if (j <= -1.6e+94) {
tmp = t_1;
} else if (j <= -5e-89) {
tmp = (x * (t * -a)) - (b * (z * c));
} else if (j <= 1e+87) {
tmp = t * ((b * i) - (x * a));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: tmp
t_1 = j * ((a * c) - (y * i))
if (j <= (-1.6d+94)) then
tmp = t_1
else if (j <= (-5d-89)) then
tmp = (x * (t * -a)) - (b * (z * c))
else if (j <= 1d+87) then
tmp = t * ((b * i) - (x * a))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((a * c) - (y * i));
double tmp;
if (j <= -1.6e+94) {
tmp = t_1;
} else if (j <= -5e-89) {
tmp = (x * (t * -a)) - (b * (z * c));
} else if (j <= 1e+87) {
tmp = t * ((b * i) - (x * a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = j * ((a * c) - (y * i)) tmp = 0 if j <= -1.6e+94: tmp = t_1 elif j <= -5e-89: tmp = (x * (t * -a)) - (b * (z * c)) elif j <= 1e+87: tmp = t * ((b * i) - (x * a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(j * Float64(Float64(a * c) - Float64(y * i))) tmp = 0.0 if (j <= -1.6e+94) tmp = t_1; elseif (j <= -5e-89) tmp = Float64(Float64(x * Float64(t * Float64(-a))) - Float64(b * Float64(z * c))); elseif (j <= 1e+87) tmp = Float64(t * Float64(Float64(b * i) - Float64(x * a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = j * ((a * c) - (y * i)); tmp = 0.0; if (j <= -1.6e+94) tmp = t_1; elseif (j <= -5e-89) tmp = (x * (t * -a)) - (b * (z * c)); elseif (j <= 1e+87) tmp = t * ((b * i) - (x * a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -1.6e+94], t$95$1, If[LessEqual[j, -5e-89], N[(N[(x * N[(t * (-a)), $MachinePrecision]), $MachinePrecision] - N[(b * N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1e+87], N[(t * N[(N[(b * i), $MachinePrecision] - N[(x * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{if}\;j \leq -1.6 \cdot 10^{+94}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -5 \cdot 10^{-89}:\\
\;\;\;\;x \cdot \left(t \cdot \left(-a\right)\right) - b \cdot \left(z \cdot c\right)\\
\mathbf{elif}\;j \leq 10^{+87}:\\
\;\;\;\;t \cdot \left(b \cdot i - x \cdot a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if j < -1.60000000000000007e94 or 9.9999999999999996e86 < j Initial program 80.2%
sub-neg80.2%
distribute-rgt-in80.2%
*-commutative80.2%
distribute-rgt-neg-in80.2%
Applied egg-rr80.2%
Taylor expanded in j around inf 75.8%
*-commutative75.8%
Simplified75.8%
if -1.60000000000000007e94 < j < -4.99999999999999967e-89Initial program 79.7%
Taylor expanded in j around 0 70.0%
*-commutative70.0%
*-commutative70.0%
Simplified70.0%
Taylor expanded in i around 0 69.9%
*-commutative69.9%
*-commutative69.9%
Simplified69.9%
Taylor expanded in z around 0 56.6%
neg-mul-156.6%
*-commutative56.6%
distribute-rgt-neg-in56.6%
Simplified56.6%
if -4.99999999999999967e-89 < j < 9.9999999999999996e86Initial program 73.5%
Taylor expanded in j around 0 74.6%
*-commutative74.6%
*-commutative74.6%
Simplified74.6%
Taylor expanded in i around 0 74.7%
Taylor expanded in t around -inf 57.5%
mul-1-neg57.5%
*-commutative57.5%
distribute-rgt-neg-in57.5%
+-commutative57.5%
mul-1-neg57.5%
unsub-neg57.5%
*-commutative57.5%
Simplified57.5%
Final simplification63.5%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* j (- (* a c) (* y i)))))
(if (<= j -1.45e+97)
t_1
(if (<= j -2.6e-31)
(* z (* x (- y (* b (/ c x)))))
(if (<= j 9.5e+86) (* t (- (* b i) (* x a))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((a * c) - (y * i));
double tmp;
if (j <= -1.45e+97) {
tmp = t_1;
} else if (j <= -2.6e-31) {
tmp = z * (x * (y - (b * (c / x))));
} else if (j <= 9.5e+86) {
tmp = t * ((b * i) - (x * a));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: tmp
t_1 = j * ((a * c) - (y * i))
if (j <= (-1.45d+97)) then
tmp = t_1
else if (j <= (-2.6d-31)) then
tmp = z * (x * (y - (b * (c / x))))
else if (j <= 9.5d+86) then
tmp = t * ((b * i) - (x * a))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((a * c) - (y * i));
double tmp;
if (j <= -1.45e+97) {
tmp = t_1;
} else if (j <= -2.6e-31) {
tmp = z * (x * (y - (b * (c / x))));
} else if (j <= 9.5e+86) {
tmp = t * ((b * i) - (x * a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = j * ((a * c) - (y * i)) tmp = 0 if j <= -1.45e+97: tmp = t_1 elif j <= -2.6e-31: tmp = z * (x * (y - (b * (c / x)))) elif j <= 9.5e+86: tmp = t * ((b * i) - (x * a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(j * Float64(Float64(a * c) - Float64(y * i))) tmp = 0.0 if (j <= -1.45e+97) tmp = t_1; elseif (j <= -2.6e-31) tmp = Float64(z * Float64(x * Float64(y - Float64(b * Float64(c / x))))); elseif (j <= 9.5e+86) tmp = Float64(t * Float64(Float64(b * i) - Float64(x * a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = j * ((a * c) - (y * i)); tmp = 0.0; if (j <= -1.45e+97) tmp = t_1; elseif (j <= -2.6e-31) tmp = z * (x * (y - (b * (c / x)))); elseif (j <= 9.5e+86) tmp = t * ((b * i) - (x * a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -1.45e+97], t$95$1, If[LessEqual[j, -2.6e-31], N[(z * N[(x * N[(y - N[(b * N[(c / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 9.5e+86], N[(t * N[(N[(b * i), $MachinePrecision] - N[(x * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{if}\;j \leq -1.45 \cdot 10^{+97}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -2.6 \cdot 10^{-31}:\\
\;\;\;\;z \cdot \left(x \cdot \left(y - b \cdot \frac{c}{x}\right)\right)\\
\mathbf{elif}\;j \leq 9.5 \cdot 10^{+86}:\\
\;\;\;\;t \cdot \left(b \cdot i - x \cdot a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if j < -1.44999999999999994e97 or 9.50000000000000028e86 < j Initial program 80.2%
sub-neg80.2%
distribute-rgt-in80.2%
*-commutative80.2%
distribute-rgt-neg-in80.2%
Applied egg-rr80.2%
Taylor expanded in j around inf 75.8%
*-commutative75.8%
Simplified75.8%
if -1.44999999999999994e97 < j < -2.59999999999999995e-31Initial program 72.5%
Taylor expanded in z around inf 51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in x around inf 51.8%
mul-1-neg51.8%
unsub-neg51.8%
associate-/l*57.2%
Simplified57.2%
if -2.59999999999999995e-31 < j < 9.50000000000000028e86Initial program 74.8%
Taylor expanded in j around 0 73.3%
*-commutative73.3%
*-commutative73.3%
Simplified73.3%
Taylor expanded in i around 0 73.3%
Taylor expanded in t around -inf 56.8%
mul-1-neg56.8%
*-commutative56.8%
distribute-rgt-neg-in56.8%
+-commutative56.8%
mul-1-neg56.8%
unsub-neg56.8%
*-commutative56.8%
Simplified56.8%
Final simplification63.2%
(FPCore (x y z t a b c i j)
:precision binary64
(if (<= j -2.3e+113)
(* j (* a c))
(if (<= j -9e-277)
(* x (* y z))
(if (<= j 1.6e+87) (* t (* b i)) (* a (* c j))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if (j <= -2.3e+113) {
tmp = j * (a * c);
} else if (j <= -9e-277) {
tmp = x * (y * z);
} else if (j <= 1.6e+87) {
tmp = t * (b * i);
} else {
tmp = a * (c * j);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if (j <= (-2.3d+113)) then
tmp = j * (a * c)
else if (j <= (-9d-277)) then
tmp = x * (y * z)
else if (j <= 1.6d+87) then
tmp = t * (b * i)
else
tmp = a * (c * j)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if (j <= -2.3e+113) {
tmp = j * (a * c);
} else if (j <= -9e-277) {
tmp = x * (y * z);
} else if (j <= 1.6e+87) {
tmp = t * (b * i);
} else {
tmp = a * (c * j);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if j <= -2.3e+113: tmp = j * (a * c) elif j <= -9e-277: tmp = x * (y * z) elif j <= 1.6e+87: tmp = t * (b * i) else: tmp = a * (c * j) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if (j <= -2.3e+113) tmp = Float64(j * Float64(a * c)); elseif (j <= -9e-277) tmp = Float64(x * Float64(y * z)); elseif (j <= 1.6e+87) tmp = Float64(t * Float64(b * i)); else tmp = Float64(a * Float64(c * j)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if (j <= -2.3e+113) tmp = j * (a * c); elseif (j <= -9e-277) tmp = x * (y * z); elseif (j <= 1.6e+87) tmp = t * (b * i); else tmp = a * (c * j); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[LessEqual[j, -2.3e+113], N[(j * N[(a * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -9e-277], N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1.6e+87], N[(t * N[(b * i), $MachinePrecision]), $MachinePrecision], N[(a * N[(c * j), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;j \leq -2.3 \cdot 10^{+113}:\\
\;\;\;\;j \cdot \left(a \cdot c\right)\\
\mathbf{elif}\;j \leq -9 \cdot 10^{-277}:\\
\;\;\;\;x \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;j \leq 1.6 \cdot 10^{+87}:\\
\;\;\;\;t \cdot \left(b \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;a \cdot \left(c \cdot j\right)\\
\end{array}
\end{array}
if j < -2.29999999999999997e113Initial program 79.0%
Taylor expanded in a around inf 51.9%
+-commutative51.9%
mul-1-neg51.9%
unsub-neg51.9%
Simplified51.9%
Taylor expanded in c around inf 52.1%
associate-*r*52.1%
*-commutative52.1%
Simplified52.1%
if -2.29999999999999997e113 < j < -8.99999999999999985e-277Initial program 77.2%
Taylor expanded in z around inf 39.7%
*-commutative39.7%
Simplified39.7%
Taylor expanded in y around inf 33.5%
if -8.99999999999999985e-277 < j < 1.6e87Initial program 72.1%
Taylor expanded in j around 0 73.9%
*-commutative73.9%
*-commutative73.9%
Simplified73.9%
Taylor expanded in i around inf 36.3%
associate-*r*37.4%
Simplified37.4%
if 1.6e87 < j Initial program 82.1%
Taylor expanded in a around inf 57.5%
+-commutative57.5%
mul-1-neg57.5%
unsub-neg57.5%
Simplified57.5%
Taylor expanded in c around inf 44.8%
Final simplification39.7%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* a (* c j))))
(if (<= j -1.75e+112)
t_1
(if (<= j -9.5e-277)
(* x (* y z))
(if (<= j 1.85e+87) (* t (* b i)) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = a * (c * j);
double tmp;
if (j <= -1.75e+112) {
tmp = t_1;
} else if (j <= -9.5e-277) {
tmp = x * (y * z);
} else if (j <= 1.85e+87) {
tmp = t * (b * i);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: tmp
t_1 = a * (c * j)
if (j <= (-1.75d+112)) then
tmp = t_1
else if (j <= (-9.5d-277)) then
tmp = x * (y * z)
else if (j <= 1.85d+87) then
tmp = t * (b * i)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = a * (c * j);
double tmp;
if (j <= -1.75e+112) {
tmp = t_1;
} else if (j <= -9.5e-277) {
tmp = x * (y * z);
} else if (j <= 1.85e+87) {
tmp = t * (b * i);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = a * (c * j) tmp = 0 if j <= -1.75e+112: tmp = t_1 elif j <= -9.5e-277: tmp = x * (y * z) elif j <= 1.85e+87: tmp = t * (b * i) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(a * Float64(c * j)) tmp = 0.0 if (j <= -1.75e+112) tmp = t_1; elseif (j <= -9.5e-277) tmp = Float64(x * Float64(y * z)); elseif (j <= 1.85e+87) tmp = Float64(t * Float64(b * i)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = a * (c * j); tmp = 0.0; if (j <= -1.75e+112) tmp = t_1; elseif (j <= -9.5e-277) tmp = x * (y * z); elseif (j <= 1.85e+87) tmp = t * (b * i); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(a * N[(c * j), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -1.75e+112], t$95$1, If[LessEqual[j, -9.5e-277], N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1.85e+87], N[(t * N[(b * i), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot \left(c \cdot j\right)\\
\mathbf{if}\;j \leq -1.75 \cdot 10^{+112}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -9.5 \cdot 10^{-277}:\\
\;\;\;\;x \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;j \leq 1.85 \cdot 10^{+87}:\\
\;\;\;\;t \cdot \left(b \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if j < -1.74999999999999998e112 or 1.85000000000000001e87 < j Initial program 80.5%
Taylor expanded in a around inf 54.6%
+-commutative54.6%
mul-1-neg54.6%
unsub-neg54.6%
Simplified54.6%
Taylor expanded in c around inf 48.6%
if -1.74999999999999998e112 < j < -9.5e-277Initial program 77.2%
Taylor expanded in z around inf 39.7%
*-commutative39.7%
Simplified39.7%
Taylor expanded in y around inf 33.5%
if -9.5e-277 < j < 1.85000000000000001e87Initial program 72.1%
Taylor expanded in j around 0 73.9%
*-commutative73.9%
*-commutative73.9%
Simplified73.9%
Taylor expanded in i around inf 36.3%
associate-*r*37.4%
Simplified37.4%
Final simplification39.7%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* a (* c j))))
(if (<= j -2.85e+113)
t_1
(if (<= j -8.8e-277)
(* x (* y z))
(if (<= j 1.6e+87) (* b (* t i)) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = a * (c * j);
double tmp;
if (j <= -2.85e+113) {
tmp = t_1;
} else if (j <= -8.8e-277) {
tmp = x * (y * z);
} else if (j <= 1.6e+87) {
tmp = b * (t * i);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: tmp
t_1 = a * (c * j)
if (j <= (-2.85d+113)) then
tmp = t_1
else if (j <= (-8.8d-277)) then
tmp = x * (y * z)
else if (j <= 1.6d+87) then
tmp = b * (t * i)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = a * (c * j);
double tmp;
if (j <= -2.85e+113) {
tmp = t_1;
} else if (j <= -8.8e-277) {
tmp = x * (y * z);
} else if (j <= 1.6e+87) {
tmp = b * (t * i);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = a * (c * j) tmp = 0 if j <= -2.85e+113: tmp = t_1 elif j <= -8.8e-277: tmp = x * (y * z) elif j <= 1.6e+87: tmp = b * (t * i) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(a * Float64(c * j)) tmp = 0.0 if (j <= -2.85e+113) tmp = t_1; elseif (j <= -8.8e-277) tmp = Float64(x * Float64(y * z)); elseif (j <= 1.6e+87) tmp = Float64(b * Float64(t * i)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = a * (c * j); tmp = 0.0; if (j <= -2.85e+113) tmp = t_1; elseif (j <= -8.8e-277) tmp = x * (y * z); elseif (j <= 1.6e+87) tmp = b * (t * i); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(a * N[(c * j), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -2.85e+113], t$95$1, If[LessEqual[j, -8.8e-277], N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1.6e+87], N[(b * N[(t * i), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot \left(c \cdot j\right)\\
\mathbf{if}\;j \leq -2.85 \cdot 10^{+113}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;j \leq -8.8 \cdot 10^{-277}:\\
\;\;\;\;x \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;j \leq 1.6 \cdot 10^{+87}:\\
\;\;\;\;b \cdot \left(t \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if j < -2.8499999999999999e113 or 1.6e87 < j Initial program 80.5%
Taylor expanded in a around inf 54.6%
+-commutative54.6%
mul-1-neg54.6%
unsub-neg54.6%
Simplified54.6%
Taylor expanded in c around inf 48.6%
if -2.8499999999999999e113 < j < -8.79999999999999983e-277Initial program 77.2%
Taylor expanded in z around inf 39.7%
*-commutative39.7%
Simplified39.7%
Taylor expanded in y around inf 33.5%
if -8.79999999999999983e-277 < j < 1.6e87Initial program 72.1%
Taylor expanded in j around 0 73.9%
*-commutative73.9%
*-commutative73.9%
Simplified73.9%
Taylor expanded in i around inf 36.3%
Final simplification39.3%
(FPCore (x y z t a b c i j) :precision binary64 (if (or (<= j -6.2e+95) (not (<= j 8.2e+86))) (* j (- (* a c) (* y i))) (* t (- (* b i) (* x a)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((j <= -6.2e+95) || !(j <= 8.2e+86)) {
tmp = j * ((a * c) - (y * i));
} else {
tmp = t * ((b * i) - (x * a));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if ((j <= (-6.2d+95)) .or. (.not. (j <= 8.2d+86))) then
tmp = j * ((a * c) - (y * i))
else
tmp = t * ((b * i) - (x * a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((j <= -6.2e+95) || !(j <= 8.2e+86)) {
tmp = j * ((a * c) - (y * i));
} else {
tmp = t * ((b * i) - (x * a));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if (j <= -6.2e+95) or not (j <= 8.2e+86): tmp = j * ((a * c) - (y * i)) else: tmp = t * ((b * i) - (x * a)) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if ((j <= -6.2e+95) || !(j <= 8.2e+86)) tmp = Float64(j * Float64(Float64(a * c) - Float64(y * i))); else tmp = Float64(t * Float64(Float64(b * i) - Float64(x * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if ((j <= -6.2e+95) || ~((j <= 8.2e+86))) tmp = j * ((a * c) - (y * i)); else tmp = t * ((b * i) - (x * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[Or[LessEqual[j, -6.2e+95], N[Not[LessEqual[j, 8.2e+86]], $MachinePrecision]], N[(j * N[(N[(a * c), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(b * i), $MachinePrecision] - N[(x * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;j \leq -6.2 \cdot 10^{+95} \lor \neg \left(j \leq 8.2 \cdot 10^{+86}\right):\\
\;\;\;\;j \cdot \left(a \cdot c - y \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(b \cdot i - x \cdot a\right)\\
\end{array}
\end{array}
if j < -6.2000000000000006e95 or 8.1999999999999998e86 < j Initial program 80.2%
sub-neg80.2%
distribute-rgt-in80.2%
*-commutative80.2%
distribute-rgt-neg-in80.2%
Applied egg-rr80.2%
Taylor expanded in j around inf 75.8%
*-commutative75.8%
Simplified75.8%
if -6.2000000000000006e95 < j < 8.1999999999999998e86Initial program 74.5%
Taylor expanded in j around 0 73.8%
*-commutative73.8%
*-commutative73.8%
Simplified73.8%
Taylor expanded in i around 0 73.9%
Taylor expanded in t around -inf 54.4%
mul-1-neg54.4%
*-commutative54.4%
distribute-rgt-neg-in54.4%
+-commutative54.4%
mul-1-neg54.4%
unsub-neg54.4%
*-commutative54.4%
Simplified54.4%
Final simplification61.6%
(FPCore (x y z t a b c i j) :precision binary64 (if (or (<= b -1.6e+47) (not (<= b 340000000000.0))) (* b (- (* t i) (* z c))) (* a (- (* c j) (* x t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((b <= -1.6e+47) || !(b <= 340000000000.0)) {
tmp = b * ((t * i) - (z * c));
} else {
tmp = a * ((c * j) - (x * t));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if ((b <= (-1.6d+47)) .or. (.not. (b <= 340000000000.0d0))) then
tmp = b * ((t * i) - (z * c))
else
tmp = a * ((c * j) - (x * t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((b <= -1.6e+47) || !(b <= 340000000000.0)) {
tmp = b * ((t * i) - (z * c));
} else {
tmp = a * ((c * j) - (x * t));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if (b <= -1.6e+47) or not (b <= 340000000000.0): tmp = b * ((t * i) - (z * c)) else: tmp = a * ((c * j) - (x * t)) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if ((b <= -1.6e+47) || !(b <= 340000000000.0)) tmp = Float64(b * Float64(Float64(t * i) - Float64(z * c))); else tmp = Float64(a * Float64(Float64(c * j) - Float64(x * t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if ((b <= -1.6e+47) || ~((b <= 340000000000.0))) tmp = b * ((t * i) - (z * c)); else tmp = a * ((c * j) - (x * t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[Or[LessEqual[b, -1.6e+47], N[Not[LessEqual[b, 340000000000.0]], $MachinePrecision]], N[(b * N[(N[(t * i), $MachinePrecision] - N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(c * j), $MachinePrecision] - N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.6 \cdot 10^{+47} \lor \neg \left(b \leq 340000000000\right):\\
\;\;\;\;b \cdot \left(t \cdot i - z \cdot c\right)\\
\mathbf{else}:\\
\;\;\;\;a \cdot \left(c \cdot j - x \cdot t\right)\\
\end{array}
\end{array}
if b < -1.6e47 or 3.4e11 < b Initial program 76.0%
Taylor expanded in b around inf 66.3%
*-commutative66.3%
Simplified66.3%
if -1.6e47 < b < 3.4e11Initial program 76.7%
Taylor expanded in a around inf 52.6%
+-commutative52.6%
mul-1-neg52.6%
unsub-neg52.6%
Simplified52.6%
Final simplification58.4%
(FPCore (x y z t a b c i j) :precision binary64 (if (<= i -1.5e+202) (* b (* t i)) (if (<= i 3e+217) (* a (- (* c j) (* x t))) (* t (* b i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if (i <= -1.5e+202) {
tmp = b * (t * i);
} else if (i <= 3e+217) {
tmp = a * ((c * j) - (x * t));
} else {
tmp = t * (b * i);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if (i <= (-1.5d+202)) then
tmp = b * (t * i)
else if (i <= 3d+217) then
tmp = a * ((c * j) - (x * t))
else
tmp = t * (b * i)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if (i <= -1.5e+202) {
tmp = b * (t * i);
} else if (i <= 3e+217) {
tmp = a * ((c * j) - (x * t));
} else {
tmp = t * (b * i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if i <= -1.5e+202: tmp = b * (t * i) elif i <= 3e+217: tmp = a * ((c * j) - (x * t)) else: tmp = t * (b * i) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if (i <= -1.5e+202) tmp = Float64(b * Float64(t * i)); elseif (i <= 3e+217) tmp = Float64(a * Float64(Float64(c * j) - Float64(x * t))); else tmp = Float64(t * Float64(b * i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if (i <= -1.5e+202) tmp = b * (t * i); elseif (i <= 3e+217) tmp = a * ((c * j) - (x * t)); else tmp = t * (b * i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[LessEqual[i, -1.5e+202], N[(b * N[(t * i), $MachinePrecision]), $MachinePrecision], If[LessEqual[i, 3e+217], N[(a * N[(N[(c * j), $MachinePrecision] - N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(b * i), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;i \leq -1.5 \cdot 10^{+202}:\\
\;\;\;\;b \cdot \left(t \cdot i\right)\\
\mathbf{elif}\;i \leq 3 \cdot 10^{+217}:\\
\;\;\;\;a \cdot \left(c \cdot j - x \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(b \cdot i\right)\\
\end{array}
\end{array}
if i < -1.5000000000000001e202Initial program 66.8%
Taylor expanded in j around 0 56.1%
*-commutative56.1%
*-commutative56.1%
Simplified56.1%
Taylor expanded in i around inf 59.6%
if -1.5000000000000001e202 < i < 2.99999999999999976e217Initial program 77.9%
Taylor expanded in a around inf 45.8%
+-commutative45.8%
mul-1-neg45.8%
unsub-neg45.8%
Simplified45.8%
if 2.99999999999999976e217 < i Initial program 69.1%
Taylor expanded in j around 0 59.2%
*-commutative59.2%
*-commutative59.2%
Simplified59.2%
Taylor expanded in i around inf 54.7%
associate-*r*69.3%
Simplified69.3%
Final simplification48.5%
(FPCore (x y z t a b c i j) :precision binary64 (if (or (<= j -7.2e-37) (not (<= j 2.25e+87))) (* a (* c j)) (* b (* t i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((j <= -7.2e-37) || !(j <= 2.25e+87)) {
tmp = a * (c * j);
} else {
tmp = b * (t * i);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: tmp
if ((j <= (-7.2d-37)) .or. (.not. (j <= 2.25d+87))) then
tmp = a * (c * j)
else
tmp = b * (t * i)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double tmp;
if ((j <= -7.2e-37) || !(j <= 2.25e+87)) {
tmp = a * (c * j);
} else {
tmp = b * (t * i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): tmp = 0 if (j <= -7.2e-37) or not (j <= 2.25e+87): tmp = a * (c * j) else: tmp = b * (t * i) return tmp
function code(x, y, z, t, a, b, c, i, j) tmp = 0.0 if ((j <= -7.2e-37) || !(j <= 2.25e+87)) tmp = Float64(a * Float64(c * j)); else tmp = Float64(b * Float64(t * i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) tmp = 0.0; if ((j <= -7.2e-37) || ~((j <= 2.25e+87))) tmp = a * (c * j); else tmp = b * (t * i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := If[Or[LessEqual[j, -7.2e-37], N[Not[LessEqual[j, 2.25e+87]], $MachinePrecision]], N[(a * N[(c * j), $MachinePrecision]), $MachinePrecision], N[(b * N[(t * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;j \leq -7.2 \cdot 10^{-37} \lor \neg \left(j \leq 2.25 \cdot 10^{+87}\right):\\
\;\;\;\;a \cdot \left(c \cdot j\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(t \cdot i\right)\\
\end{array}
\end{array}
if j < -7.20000000000000014e-37 or 2.2500000000000001e87 < j Initial program 79.1%
Taylor expanded in a around inf 50.7%
+-commutative50.7%
mul-1-neg50.7%
unsub-neg50.7%
Simplified50.7%
Taylor expanded in c around inf 40.3%
if -7.20000000000000014e-37 < j < 2.2500000000000001e87Initial program 74.6%
Taylor expanded in j around 0 72.5%
*-commutative72.5%
*-commutative72.5%
Simplified72.5%
Taylor expanded in i around inf 30.6%
Final simplification34.6%
(FPCore (x y z t a b c i j) :precision binary64 (* a (* c j)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
return a * (c * j);
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
code = a * (c * j)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
return a * (c * j);
}
def code(x, y, z, t, a, b, c, i, j): return a * (c * j)
function code(x, y, z, t, a, b, c, i, j) return Float64(a * Float64(c * j)) end
function tmp = code(x, y, z, t, a, b, c, i, j) tmp = a * (c * j); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := N[(a * N[(c * j), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
a \cdot \left(c \cdot j\right)
\end{array}
Initial program 76.4%
Taylor expanded in a around inf 41.8%
+-commutative41.8%
mul-1-neg41.8%
unsub-neg41.8%
Simplified41.8%
Taylor expanded in c around inf 22.5%
(FPCore (x y z t a b c i j)
:precision binary64
(let* ((t_1 (* j (- (* c a) (* y i))))
(t_2
(+
(-
(* x (- (* y z) (* t a)))
(/
(* b (- (pow (* c z) 2.0) (pow (* t i) 2.0)))
(+ (* c z) (* t i))))
t_1)))
(if (< x -1.469694296777705e-64)
t_2
(if (< x 3.2113527362226803e-147)
(- (* (- (* b i) (* x a)) t) (- (* z (* c b)) t_1))
t_2))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((c * a) - (y * i));
double t_2 = ((x * ((y * z) - (t * a))) - ((b * (pow((c * z), 2.0) - pow((t * i), 2.0))) / ((c * z) + (t * i)))) + t_1;
double tmp;
if (x < -1.469694296777705e-64) {
tmp = t_2;
} else if (x < 3.2113527362226803e-147) {
tmp = (((b * i) - (x * a)) * t) - ((z * (c * b)) - t_1);
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = j * ((c * a) - (y * i))
t_2 = ((x * ((y * z) - (t * a))) - ((b * (((c * z) ** 2.0d0) - ((t * i) ** 2.0d0))) / ((c * z) + (t * i)))) + t_1
if (x < (-1.469694296777705d-64)) then
tmp = t_2
else if (x < 3.2113527362226803d-147) then
tmp = (((b * i) - (x * a)) * t) - ((z * (c * b)) - t_1)
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
double t_1 = j * ((c * a) - (y * i));
double t_2 = ((x * ((y * z) - (t * a))) - ((b * (Math.pow((c * z), 2.0) - Math.pow((t * i), 2.0))) / ((c * z) + (t * i)))) + t_1;
double tmp;
if (x < -1.469694296777705e-64) {
tmp = t_2;
} else if (x < 3.2113527362226803e-147) {
tmp = (((b * i) - (x * a)) * t) - ((z * (c * b)) - t_1);
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j): t_1 = j * ((c * a) - (y * i)) t_2 = ((x * ((y * z) - (t * a))) - ((b * (math.pow((c * z), 2.0) - math.pow((t * i), 2.0))) / ((c * z) + (t * i)))) + t_1 tmp = 0 if x < -1.469694296777705e-64: tmp = t_2 elif x < 3.2113527362226803e-147: tmp = (((b * i) - (x * a)) * t) - ((z * (c * b)) - t_1) else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i, j) t_1 = Float64(j * Float64(Float64(c * a) - Float64(y * i))) t_2 = Float64(Float64(Float64(x * Float64(Float64(y * z) - Float64(t * a))) - Float64(Float64(b * Float64((Float64(c * z) ^ 2.0) - (Float64(t * i) ^ 2.0))) / Float64(Float64(c * z) + Float64(t * i)))) + t_1) tmp = 0.0 if (x < -1.469694296777705e-64) tmp = t_2; elseif (x < 3.2113527362226803e-147) tmp = Float64(Float64(Float64(Float64(b * i) - Float64(x * a)) * t) - Float64(Float64(z * Float64(c * b)) - t_1)); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j) t_1 = j * ((c * a) - (y * i)); t_2 = ((x * ((y * z) - (t * a))) - ((b * (((c * z) ^ 2.0) - ((t * i) ^ 2.0))) / ((c * z) + (t * i)))) + t_1; tmp = 0.0; if (x < -1.469694296777705e-64) tmp = t_2; elseif (x < 3.2113527362226803e-147) tmp = (((b * i) - (x * a)) * t) - ((z * (c * b)) - t_1); else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_] := Block[{t$95$1 = N[(j * N[(N[(c * a), $MachinePrecision] - N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(x * N[(N[(y * z), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(b * N[(N[Power[N[(c * z), $MachinePrecision], 2.0], $MachinePrecision] - N[Power[N[(t * i), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(c * z), $MachinePrecision] + N[(t * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision]}, If[Less[x, -1.469694296777705e-64], t$95$2, If[Less[x, 3.2113527362226803e-147], N[(N[(N[(N[(b * i), $MachinePrecision] - N[(x * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision] - N[(N[(z * N[(c * b), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]), $MachinePrecision], t$95$2]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := j \cdot \left(c \cdot a - y \cdot i\right)\\
t_2 := \left(x \cdot \left(y \cdot z - t \cdot a\right) - \frac{b \cdot \left({\left(c \cdot z\right)}^{2} - {\left(t \cdot i\right)}^{2}\right)}{c \cdot z + t \cdot i}\right) + t\_1\\
\mathbf{if}\;x < -1.469694296777705 \cdot 10^{-64}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x < 3.2113527362226803 \cdot 10^{-147}:\\
\;\;\;\;\left(b \cdot i - x \cdot a\right) \cdot t - \left(z \cdot \left(c \cdot b\right) - t\_1\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
herbie shell --seed 2024137
(FPCore (x y z t a b c i j)
:name "Data.Colour.Matrix:determinant from colour-2.3.3, A"
:precision binary64
:alt
(! :herbie-platform default (if (< x -293938859355541/2000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (* x (- (* y z) (* t a))) (/ (* b (- (pow (* c z) 2) (pow (* t i) 2))) (+ (* c z) (* t i)))) (* j (- (* c a) (* y i)))) (if (< x 32113527362226803/10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- (* (- (* b i) (* x a)) t) (- (* z (* c b)) (* j (- (* c a) (* y i))))) (+ (- (* x (- (* y z) (* t a))) (/ (* b (- (pow (* c z) 2) (pow (* t i) 2))) (+ (* c z) (* t i)))) (* j (- (* c a) (* y i)))))))
(+ (- (* x (- (* y z) (* t a))) (* b (- (* c z) (* t i)))) (* j (- (* c a) (* y i)))))