
(FPCore (x y z t a b c i j k) :precision binary64 (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k): return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 19 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i j k) :precision binary64 (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k): return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1
(-
(-
(+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
(* (* x 4.0) i))
(* (* j 27.0) k))))
(if (<= t_1 INFINITY)
t_1
(fma
j
(* k -27.0)
(fma
x
(* i -4.0)
(fma t (fma x (* 18.0 (* y z)) (* a -4.0)) (* b c)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = fma(j, (k * -27.0), fma(x, (i * -4.0), fma(t, fma(x, (18.0 * (y * z)), (a * -4.0)), (b * c))));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = fma(j, Float64(k * -27.0), fma(x, Float64(i * -4.0), fma(t, fma(x, Float64(18.0 * Float64(y * z)), Float64(a * -4.0)), Float64(b * c)))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(j * N[(k * -27.0), $MachinePrecision] + N[(x * N[(i * -4.0), $MachinePrecision] + N[(t * N[(x * N[(18.0 * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(j, k \cdot -27, \mathsf{fma}\left(x, i \cdot -4, \mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), b \cdot c\right)\right)\right)\\
\end{array}
\end{array}
if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) < +inf.0Initial program 96.7%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) Initial program 0.0%
sub-neg0.0%
+-commutative0.0%
associate-*l*0.0%
distribute-rgt-neg-in0.0%
fma-def28.6%
*-commutative28.6%
distribute-rgt-neg-in28.6%
metadata-eval28.6%
sub-neg28.6%
+-commutative28.6%
associate-*l*28.6%
distribute-rgt-neg-in28.6%
Simplified66.7%
Final simplification94.2%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1
(-
(-
(+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
(* (* x 4.0) i))
(* (* j 27.0) k))))
(if (<= t_1 INFINITY)
t_1
(+ (* b c) (* t (- (* 18.0 (* y (* x z))) (* a 4.0)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)));
}
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 k) {
double t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0))) return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(y * Float64(x * z))) - Float64(a * 4.0)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(y \cdot \left(x \cdot z\right)\right) - a \cdot 4\right)\\
\end{array}
\end{array}
if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) < +inf.0Initial program 96.7%
if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) Initial program 0.0%
sub-neg0.0%
associate-+l-0.0%
sub-neg0.0%
sub-neg0.0%
distribute-rgt-out--14.3%
associate-*l*14.3%
distribute-lft-neg-in14.3%
cancel-sign-sub14.3%
associate-*l*14.3%
associate-*l*14.3%
Simplified14.3%
Taylor expanded in j around 0 42.9%
Taylor expanded in i around 0 52.6%
Final simplification93.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 4.0 (* x i))) (t_2 (* (* j 27.0) k)))
(if (<= t_2 -1e+95)
(- (- (* b c) t_1) t_2)
(if (<= t_2 5e+112)
(- (+ (* b c) (* t (- (* 18.0 (* y (* x z))) (* a 4.0)))) t_1)
(- (- (* b c) (* 4.0 (* t a))) t_2)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 4.0 * (x * i);
double t_2 = (j * 27.0) * k;
double tmp;
if (t_2 <= -1e+95) {
tmp = ((b * c) - t_1) - t_2;
} else if (t_2 <= 5e+112) {
tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1;
} else {
tmp = ((b * c) - (4.0 * (t * a))) - t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = 4.0d0 * (x * i)
t_2 = (j * 27.0d0) * k
if (t_2 <= (-1d+95)) then
tmp = ((b * c) - t_1) - t_2
else if (t_2 <= 5d+112) then
tmp = ((b * c) + (t * ((18.0d0 * (y * (x * z))) - (a * 4.0d0)))) - t_1
else
tmp = ((b * c) - (4.0d0 * (t * a))) - t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 4.0 * (x * i);
double t_2 = (j * 27.0) * k;
double tmp;
if (t_2 <= -1e+95) {
tmp = ((b * c) - t_1) - t_2;
} else if (t_2 <= 5e+112) {
tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1;
} else {
tmp = ((b * c) - (4.0 * (t * a))) - t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = 4.0 * (x * i) t_2 = (j * 27.0) * k tmp = 0 if t_2 <= -1e+95: tmp = ((b * c) - t_1) - t_2 elif t_2 <= 5e+112: tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1 else: tmp = ((b * c) - (4.0 * (t * a))) - t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(4.0 * Float64(x * i)) t_2 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_2 <= -1e+95) tmp = Float64(Float64(Float64(b * c) - t_1) - t_2); elseif (t_2 <= 5e+112) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(y * Float64(x * z))) - Float64(a * 4.0)))) - t_1); else tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - t_2); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = 4.0 * (x * i); t_2 = (j * 27.0) * k; tmp = 0.0; if (t_2 <= -1e+95) tmp = ((b * c) - t_1) - t_2; elseif (t_2 <= 5e+112) tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1; else tmp = ((b * c) - (4.0 * (t * a))) - t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$2, -1e+95], N[(N[(N[(b * c), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[t$95$2, 5e+112], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 4 \cdot \left(x \cdot i\right)\\
t_2 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t_2 \leq -1 \cdot 10^{+95}:\\
\;\;\;\;\left(b \cdot c - t_1\right) - t_2\\
\mathbf{elif}\;t_2 \leq 5 \cdot 10^{+112}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(y \cdot \left(x \cdot z\right)\right) - a \cdot 4\right)\right) - t_1\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - t_2\\
\end{array}
\end{array}
if (*.f64 (*.f64 j 27) k) < -1.00000000000000002e95Initial program 82.5%
Taylor expanded in t around 0 72.1%
if -1.00000000000000002e95 < (*.f64 (*.f64 j 27) k) < 5e112Initial program 91.8%
sub-neg91.8%
associate-+l-91.8%
sub-neg91.8%
sub-neg91.8%
distribute-rgt-out--93.6%
associate-*l*91.2%
distribute-lft-neg-in91.2%
cancel-sign-sub91.2%
associate-*l*91.2%
associate-*l*91.2%
Simplified91.2%
Taylor expanded in j around 0 89.6%
if 5e112 < (*.f64 (*.f64 j 27) k) Initial program 83.8%
Taylor expanded in x around 0 77.2%
Final simplification84.3%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* 4.0 (* x i))) (t_2 (* (* j 27.0) k)))
(if (<= t_2 -1e+95)
(- (- (+ (* b c) (* 18.0 (* y (* t (* x z))))) t_1) t_2)
(if (<= t_2 5e+112)
(- (+ (* b c) (* t (- (* 18.0 (* y (* x z))) (* a 4.0)))) t_1)
(- (- (* b c) (* 4.0 (* t a))) t_2)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 4.0 * (x * i);
double t_2 = (j * 27.0) * k;
double tmp;
if (t_2 <= -1e+95) {
tmp = (((b * c) + (18.0 * (y * (t * (x * z))))) - t_1) - t_2;
} else if (t_2 <= 5e+112) {
tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1;
} else {
tmp = ((b * c) - (4.0 * (t * a))) - t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = 4.0d0 * (x * i)
t_2 = (j * 27.0d0) * k
if (t_2 <= (-1d+95)) then
tmp = (((b * c) + (18.0d0 * (y * (t * (x * z))))) - t_1) - t_2
else if (t_2 <= 5d+112) then
tmp = ((b * c) + (t * ((18.0d0 * (y * (x * z))) - (a * 4.0d0)))) - t_1
else
tmp = ((b * c) - (4.0d0 * (t * a))) - t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = 4.0 * (x * i);
double t_2 = (j * 27.0) * k;
double tmp;
if (t_2 <= -1e+95) {
tmp = (((b * c) + (18.0 * (y * (t * (x * z))))) - t_1) - t_2;
} else if (t_2 <= 5e+112) {
tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1;
} else {
tmp = ((b * c) - (4.0 * (t * a))) - t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = 4.0 * (x * i) t_2 = (j * 27.0) * k tmp = 0 if t_2 <= -1e+95: tmp = (((b * c) + (18.0 * (y * (t * (x * z))))) - t_1) - t_2 elif t_2 <= 5e+112: tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1 else: tmp = ((b * c) - (4.0 * (t * a))) - t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(4.0 * Float64(x * i)) t_2 = Float64(Float64(j * 27.0) * k) tmp = 0.0 if (t_2 <= -1e+95) tmp = Float64(Float64(Float64(Float64(b * c) + Float64(18.0 * Float64(y * Float64(t * Float64(x * z))))) - t_1) - t_2); elseif (t_2 <= 5e+112) tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(y * Float64(x * z))) - Float64(a * 4.0)))) - t_1); else tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - t_2); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = 4.0 * (x * i); t_2 = (j * 27.0) * k; tmp = 0.0; if (t_2 <= -1e+95) tmp = (((b * c) + (18.0 * (y * (t * (x * z))))) - t_1) - t_2; elseif (t_2 <= 5e+112) tmp = ((b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)))) - t_1; else tmp = ((b * c) - (4.0 * (t * a))) - t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$2, -1e+95], N[(N[(N[(N[(b * c), $MachinePrecision] + N[(18.0 * N[(y * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[t$95$2, 5e+112], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 4 \cdot \left(x \cdot i\right)\\
t_2 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t_2 \leq -1 \cdot 10^{+95}:\\
\;\;\;\;\left(\left(b \cdot c + 18 \cdot \left(y \cdot \left(t \cdot \left(x \cdot z\right)\right)\right)\right) - t_1\right) - t_2\\
\mathbf{elif}\;t_2 \leq 5 \cdot 10^{+112}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(y \cdot \left(x \cdot z\right)\right) - a \cdot 4\right)\right) - t_1\\
\mathbf{else}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - t_2\\
\end{array}
\end{array}
if (*.f64 (*.f64 j 27) k) < -1.00000000000000002e95Initial program 82.5%
Taylor expanded in a around 0 80.5%
if -1.00000000000000002e95 < (*.f64 (*.f64 j 27) k) < 5e112Initial program 91.8%
sub-neg91.8%
associate-+l-91.8%
sub-neg91.8%
sub-neg91.8%
distribute-rgt-out--93.6%
associate-*l*91.2%
distribute-lft-neg-in91.2%
cancel-sign-sub91.2%
associate-*l*91.2%
associate-*l*91.2%
Simplified91.2%
Taylor expanded in j around 0 89.6%
if 5e112 < (*.f64 (*.f64 j 27) k) Initial program 83.8%
Taylor expanded in x around 0 77.2%
Final simplification85.8%
(FPCore (x y z t a b c i j k) :precision binary64 (- (+ (* b c) (* t (- (* (* x 18.0) (* y z)) (* a 4.0)))) (+ (* x (* 4.0 i)) (* j (* 27.0 k)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = ((b * c) + (t * (((x * 18.0d0) * (y * z)) - (a * 4.0d0)))) - ((x * (4.0d0 * i)) + (j * (27.0d0 * k)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
}
def code(x, y, z, t, a, b, c, i, j, k): return ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)))
function code(x, y, z, t, a, b, c, i, j, k) return Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(x * 18.0) * Float64(y * z)) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k)))) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k))); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(27.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)
\end{array}
Initial program 88.8%
sub-neg88.8%
associate-+l-88.8%
sub-neg88.8%
sub-neg88.8%
distribute-rgt-out--89.9%
associate-*l*87.6%
distribute-lft-neg-in87.6%
cancel-sign-sub87.6%
associate-*l*87.6%
associate-*l*87.6%
Simplified87.6%
Final simplification87.6%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (* j 27.0) k))
(t_2 (- (- (* b c) (* 4.0 (* x i))) t_1))
(t_3 (+ (* b c) (* t (- (* 18.0 (* y (* x z))) (* a 4.0))))))
(if (<= t -5.1e+98)
t_3
(if (<= t -3.8e-107)
t_2
(if (<= t -1.3e-180)
t_3
(if (<= t 5.5e-164)
t_2
(if (<= t 7.8e+149) (- (- (* b c) (* 4.0 (* t a))) t_1) t_3)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double t_2 = ((b * c) - (4.0 * (x * i))) - t_1;
double t_3 = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)));
double tmp;
if (t <= -5.1e+98) {
tmp = t_3;
} else if (t <= -3.8e-107) {
tmp = t_2;
} else if (t <= -1.3e-180) {
tmp = t_3;
} else if (t <= 5.5e-164) {
tmp = t_2;
} else if (t <= 7.8e+149) {
tmp = ((b * c) - (4.0 * (t * a))) - t_1;
} else {
tmp = t_3;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = (j * 27.0d0) * k
t_2 = ((b * c) - (4.0d0 * (x * i))) - t_1
t_3 = (b * c) + (t * ((18.0d0 * (y * (x * z))) - (a * 4.0d0)))
if (t <= (-5.1d+98)) then
tmp = t_3
else if (t <= (-3.8d-107)) then
tmp = t_2
else if (t <= (-1.3d-180)) then
tmp = t_3
else if (t <= 5.5d-164) then
tmp = t_2
else if (t <= 7.8d+149) then
tmp = ((b * c) - (4.0d0 * (t * a))) - t_1
else
tmp = t_3
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (j * 27.0) * k;
double t_2 = ((b * c) - (4.0 * (x * i))) - t_1;
double t_3 = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0)));
double tmp;
if (t <= -5.1e+98) {
tmp = t_3;
} else if (t <= -3.8e-107) {
tmp = t_2;
} else if (t <= -1.3e-180) {
tmp = t_3;
} else if (t <= 5.5e-164) {
tmp = t_2;
} else if (t <= 7.8e+149) {
tmp = ((b * c) - (4.0 * (t * a))) - t_1;
} else {
tmp = t_3;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = (j * 27.0) * k t_2 = ((b * c) - (4.0 * (x * i))) - t_1 t_3 = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0))) tmp = 0 if t <= -5.1e+98: tmp = t_3 elif t <= -3.8e-107: tmp = t_2 elif t <= -1.3e-180: tmp = t_3 elif t <= 5.5e-164: tmp = t_2 elif t <= 7.8e+149: tmp = ((b * c) - (4.0 * (t * a))) - t_1 else: tmp = t_3 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(j * 27.0) * k) t_2 = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - t_1) t_3 = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(y * Float64(x * z))) - Float64(a * 4.0)))) tmp = 0.0 if (t <= -5.1e+98) tmp = t_3; elseif (t <= -3.8e-107) tmp = t_2; elseif (t <= -1.3e-180) tmp = t_3; elseif (t <= 5.5e-164) tmp = t_2; elseif (t <= 7.8e+149) tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - t_1); else tmp = t_3; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = (j * 27.0) * k; t_2 = ((b * c) - (4.0 * (x * i))) - t_1; t_3 = (b * c) + (t * ((18.0 * (y * (x * z))) - (a * 4.0))); tmp = 0.0; if (t <= -5.1e+98) tmp = t_3; elseif (t <= -3.8e-107) tmp = t_2; elseif (t <= -1.3e-180) tmp = t_3; elseif (t <= 5.5e-164) tmp = t_2; elseif (t <= 7.8e+149) tmp = ((b * c) - (4.0 * (t * a))) - t_1; else tmp = t_3; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -5.1e+98], t$95$3, If[LessEqual[t, -3.8e-107], t$95$2, If[LessEqual[t, -1.3e-180], t$95$3, If[LessEqual[t, 5.5e-164], t$95$2, If[LessEqual[t, 7.8e+149], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], t$95$3]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
t_2 := \left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - t_1\\
t_3 := b \cdot c + t \cdot \left(18 \cdot \left(y \cdot \left(x \cdot z\right)\right) - a \cdot 4\right)\\
\mathbf{if}\;t \leq -5.1 \cdot 10^{+98}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;t \leq -3.8 \cdot 10^{-107}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t \leq -1.3 \cdot 10^{-180}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;t \leq 5.5 \cdot 10^{-164}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t \leq 7.8 \cdot 10^{+149}:\\
\;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - t_1\\
\mathbf{else}:\\
\;\;\;\;t_3\\
\end{array}
\end{array}
if t < -5.09999999999999988e98 or -3.8000000000000002e-107 < t < -1.2999999999999999e-180 or 7.7999999999999998e149 < t Initial program 83.8%
sub-neg83.8%
associate-+l-83.8%
sub-neg83.8%
sub-neg83.8%
distribute-rgt-out--87.1%
associate-*l*86.0%
distribute-lft-neg-in86.0%
cancel-sign-sub86.0%
associate-*l*86.0%
associate-*l*86.0%
Simplified86.0%
Taylor expanded in j around 0 86.0%
Taylor expanded in i around 0 86.0%
if -5.09999999999999988e98 < t < -3.8000000000000002e-107 or -1.2999999999999999e-180 < t < 5.50000000000000027e-164Initial program 90.6%
Taylor expanded in t around 0 78.8%
if 5.50000000000000027e-164 < t < 7.7999999999999998e149Initial program 93.2%
Taylor expanded in x around 0 74.2%
Final simplification80.4%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (- (- (* b c) (* 4.0 (* t a))) (* (* j 27.0) k)))
(t_2 (* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))))
(if (<= x -1.15e+55)
t_2
(if (<= x 9.2e+18)
t_1
(if (<= x 8.8e+172)
t_2
(if (<= x 2.4e+196)
t_1
(* x (- (* 18.0 (* y (* z t))) (* 4.0 i)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = ((b * c) - (4.0 * (t * a))) - ((j * 27.0) * k);
double t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
double tmp;
if (x <= -1.15e+55) {
tmp = t_2;
} else if (x <= 9.2e+18) {
tmp = t_1;
} else if (x <= 8.8e+172) {
tmp = t_2;
} else if (x <= 2.4e+196) {
tmp = t_1;
} else {
tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = ((b * c) - (4.0d0 * (t * a))) - ((j * 27.0d0) * k)
t_2 = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
if (x <= (-1.15d+55)) then
tmp = t_2
else if (x <= 9.2d+18) then
tmp = t_1
else if (x <= 8.8d+172) then
tmp = t_2
else if (x <= 2.4d+196) then
tmp = t_1
else
tmp = x * ((18.0d0 * (y * (z * t))) - (4.0d0 * 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 k) {
double t_1 = ((b * c) - (4.0 * (t * a))) - ((j * 27.0) * k);
double t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
double tmp;
if (x <= -1.15e+55) {
tmp = t_2;
} else if (x <= 9.2e+18) {
tmp = t_1;
} else if (x <= 8.8e+172) {
tmp = t_2;
} else if (x <= 2.4e+196) {
tmp = t_1;
} else {
tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = ((b * c) - (4.0 * (t * a))) - ((j * 27.0) * k) t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i)) tmp = 0 if x <= -1.15e+55: tmp = t_2 elif x <= 9.2e+18: tmp = t_1 elif x <= 8.8e+172: tmp = t_2 elif x <= 2.4e+196: tmp = t_1 else: tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i)) return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - Float64(Float64(j * 27.0) * k)) t_2 = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i))) tmp = 0.0 if (x <= -1.15e+55) tmp = t_2; elseif (x <= 9.2e+18) tmp = t_1; elseif (x <= 8.8e+172) tmp = t_2; elseif (x <= 2.4e+196) tmp = t_1; else tmp = Float64(x * Float64(Float64(18.0 * Float64(y * Float64(z * t))) - Float64(4.0 * i))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = ((b * c) - (4.0 * (t * a))) - ((j * 27.0) * k); t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i)); tmp = 0.0; if (x <= -1.15e+55) tmp = t_2; elseif (x <= 9.2e+18) tmp = t_1; elseif (x <= 8.8e+172) tmp = t_2; elseif (x <= 2.4e+196) tmp = t_1; else tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.15e+55], t$95$2, If[LessEqual[x, 9.2e+18], t$95$1, If[LessEqual[x, 8.8e+172], t$95$2, If[LessEqual[x, 2.4e+196], t$95$1, N[(x * N[(N[(18.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(j \cdot 27\right) \cdot k\\
t_2 := x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\
\mathbf{if}\;x \leq -1.15 \cdot 10^{+55}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq 9.2 \cdot 10^{+18}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 8.8 \cdot 10^{+172}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq 2.4 \cdot 10^{+196}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(y \cdot \left(z \cdot t\right)\right) - 4 \cdot i\right)\\
\end{array}
\end{array}
if x < -1.14999999999999994e55 or 9.2e18 < x < 8.8000000000000005e172Initial program 86.8%
sub-neg86.8%
associate-+l-86.8%
sub-neg86.8%
sub-neg86.8%
distribute-rgt-out--88.1%
associate-*l*89.4%
distribute-lft-neg-in89.4%
cancel-sign-sub89.4%
associate-*l*89.4%
associate-*l*89.4%
Simplified89.4%
Taylor expanded in x around inf 73.6%
pow173.6%
associate-*r*74.8%
Applied egg-rr74.8%
unpow174.8%
*-commutative74.8%
associate-*l*74.8%
Simplified74.8%
if -1.14999999999999994e55 < x < 9.2e18 or 8.8000000000000005e172 < x < 2.4e196Initial program 92.0%
Taylor expanded in x around 0 77.5%
if 2.4e196 < x Initial program 67.3%
sub-neg67.3%
associate-+l-67.3%
sub-neg67.3%
sub-neg67.3%
distribute-rgt-out--67.3%
associate-*l*72.8%
distribute-lft-neg-in72.8%
cancel-sign-sub72.8%
associate-*l*72.8%
associate-*l*72.8%
Simplified72.8%
Taylor expanded in x around inf 83.7%
Final simplification77.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* x (* i -4.0)) (* -27.0 (* j k))))
(t_2 (* t (- (* 18.0 (* y (* x z))) (* a 4.0)))))
(if (<= b -1.02e+144)
(- (* b c) (* 4.0 (* x i)))
(if (<= b 1e-308)
t_2
(if (<= b 9e-228)
t_1
(if (<= b 2.9e-139)
t_2
(if (<= b 260000000.0) t_1 (+ (* b c) (* -4.0 (* t a))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (x * (i * -4.0)) + (-27.0 * (j * k));
double t_2 = t * ((18.0 * (y * (x * z))) - (a * 4.0));
double tmp;
if (b <= -1.02e+144) {
tmp = (b * c) - (4.0 * (x * i));
} else if (b <= 1e-308) {
tmp = t_2;
} else if (b <= 9e-228) {
tmp = t_1;
} else if (b <= 2.9e-139) {
tmp = t_2;
} else if (b <= 260000000.0) {
tmp = t_1;
} else {
tmp = (b * c) + (-4.0 * (t * a));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (x * (i * (-4.0d0))) + ((-27.0d0) * (j * k))
t_2 = t * ((18.0d0 * (y * (x * z))) - (a * 4.0d0))
if (b <= (-1.02d+144)) then
tmp = (b * c) - (4.0d0 * (x * i))
else if (b <= 1d-308) then
tmp = t_2
else if (b <= 9d-228) then
tmp = t_1
else if (b <= 2.9d-139) then
tmp = t_2
else if (b <= 260000000.0d0) then
tmp = t_1
else
tmp = (b * c) + ((-4.0d0) * (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 k) {
double t_1 = (x * (i * -4.0)) + (-27.0 * (j * k));
double t_2 = t * ((18.0 * (y * (x * z))) - (a * 4.0));
double tmp;
if (b <= -1.02e+144) {
tmp = (b * c) - (4.0 * (x * i));
} else if (b <= 1e-308) {
tmp = t_2;
} else if (b <= 9e-228) {
tmp = t_1;
} else if (b <= 2.9e-139) {
tmp = t_2;
} else if (b <= 260000000.0) {
tmp = t_1;
} else {
tmp = (b * c) + (-4.0 * (t * a));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = (x * (i * -4.0)) + (-27.0 * (j * k)) t_2 = t * ((18.0 * (y * (x * z))) - (a * 4.0)) tmp = 0 if b <= -1.02e+144: tmp = (b * c) - (4.0 * (x * i)) elif b <= 1e-308: tmp = t_2 elif b <= 9e-228: tmp = t_1 elif b <= 2.9e-139: tmp = t_2 elif b <= 260000000.0: tmp = t_1 else: tmp = (b * c) + (-4.0 * (t * a)) return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(x * Float64(i * -4.0)) + Float64(-27.0 * Float64(j * k))) t_2 = Float64(t * Float64(Float64(18.0 * Float64(y * Float64(x * z))) - Float64(a * 4.0))) tmp = 0.0 if (b <= -1.02e+144) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); elseif (b <= 1e-308) tmp = t_2; elseif (b <= 9e-228) tmp = t_1; elseif (b <= 2.9e-139) tmp = t_2; elseif (b <= 260000000.0) tmp = t_1; else tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = (x * (i * -4.0)) + (-27.0 * (j * k)); t_2 = t * ((18.0 * (y * (x * z))) - (a * 4.0)); tmp = 0.0; if (b <= -1.02e+144) tmp = (b * c) - (4.0 * (x * i)); elseif (b <= 1e-308) tmp = t_2; elseif (b <= 9e-228) tmp = t_1; elseif (b <= 2.9e-139) tmp = t_2; elseif (b <= 260000000.0) tmp = t_1; else tmp = (b * c) + (-4.0 * (t * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision] + N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(N[(18.0 * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.02e+144], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1e-308], t$95$2, If[LessEqual[b, 9e-228], t$95$1, If[LessEqual[b, 2.9e-139], t$95$2, If[LessEqual[b, 260000000.0], t$95$1, N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(i \cdot -4\right) + -27 \cdot \left(j \cdot k\right)\\
t_2 := t \cdot \left(18 \cdot \left(y \cdot \left(x \cdot z\right)\right) - a \cdot 4\right)\\
\mathbf{if}\;b \leq -1.02 \cdot 10^{+144}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;b \leq 10^{-308}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;b \leq 9 \cdot 10^{-228}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;b \leq 2.9 \cdot 10^{-139}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;b \leq 260000000:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\end{array}
\end{array}
if b < -1.02000000000000008e144Initial program 78.6%
sub-neg78.6%
associate-+l-78.6%
sub-neg78.6%
sub-neg78.6%
distribute-rgt-out--81.7%
associate-*l*72.4%
distribute-lft-neg-in72.4%
cancel-sign-sub72.4%
associate-*l*72.4%
associate-*l*72.4%
Simplified72.4%
Taylor expanded in j around 0 72.8%
Taylor expanded in t around 0 69.7%
if -1.02000000000000008e144 < b < 9.9999999999999991e-309 or 8.9999999999999999e-228 < b < 2.8999999999999999e-139Initial program 90.7%
sub-neg90.7%
associate-+l-90.7%
sub-neg90.7%
sub-neg90.7%
distribute-rgt-out--91.6%
associate-*l*89.8%
distribute-lft-neg-in89.8%
cancel-sign-sub89.8%
associate-*l*89.8%
associate-*l*89.8%
Simplified89.8%
Taylor expanded in t around inf 60.2%
if 9.9999999999999991e-309 < b < 8.9999999999999999e-228 or 2.8999999999999999e-139 < b < 2.6e8Initial program 92.2%
Taylor expanded in t around 0 55.3%
Taylor expanded in c around 0 48.8%
distribute-rgt-in48.8%
*-commutative48.8%
*-commutative48.8%
associate-*r*48.8%
metadata-eval48.8%
*-commutative48.8%
associate-*r*48.8%
*-commutative48.8%
associate-*l*48.8%
metadata-eval48.8%
*-commutative48.8%
Simplified48.8%
if 2.6e8 < b Initial program 88.0%
sub-neg88.0%
associate-+l-88.0%
sub-neg88.0%
sub-neg88.0%
distribute-rgt-out--89.5%
associate-*l*88.1%
distribute-lft-neg-in88.1%
cancel-sign-sub88.1%
associate-*l*88.1%
associate-*l*88.1%
Simplified88.1%
Taylor expanded in j around 0 67.9%
Taylor expanded in x around 0 46.8%
Final simplification55.7%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* b c) (* -4.0 (* t a))))
(t_2 (* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))))
(if (<= x -3.7e+53)
t_2
(if (<= x -2.45e-95)
t_1
(if (<= x -3.2e-188)
(+ (* x (* i -4.0)) (* -27.0 (* j k)))
(if (<= x 6.6e+18) 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 k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
double tmp;
if (x <= -3.7e+53) {
tmp = t_2;
} else if (x <= -2.45e-95) {
tmp = t_1;
} else if (x <= -3.2e-188) {
tmp = (x * (i * -4.0)) + (-27.0 * (j * k));
} else if (x <= 6.6e+18) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (b * c) + ((-4.0d0) * (t * a))
t_2 = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
if (x <= (-3.7d+53)) then
tmp = t_2
else if (x <= (-2.45d-95)) then
tmp = t_1
else if (x <= (-3.2d-188)) then
tmp = (x * (i * (-4.0d0))) + ((-27.0d0) * (j * k))
else if (x <= 6.6d+18) then
tmp = 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 k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i));
double tmp;
if (x <= -3.7e+53) {
tmp = t_2;
} else if (x <= -2.45e-95) {
tmp = t_1;
} else if (x <= -3.2e-188) {
tmp = (x * (i * -4.0)) + (-27.0 * (j * k));
} else if (x <= 6.6e+18) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) + (-4.0 * (t * a)) t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i)) tmp = 0 if x <= -3.7e+53: tmp = t_2 elif x <= -2.45e-95: tmp = t_1 elif x <= -3.2e-188: tmp = (x * (i * -4.0)) + (-27.0 * (j * k)) elif x <= 6.6e+18: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) t_2 = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i))) tmp = 0.0 if (x <= -3.7e+53) tmp = t_2; elseif (x <= -2.45e-95) tmp = t_1; elseif (x <= -3.2e-188) tmp = Float64(Float64(x * Float64(i * -4.0)) + Float64(-27.0 * Float64(j * k))); elseif (x <= 6.6e+18) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = (b * c) + (-4.0 * (t * a)); t_2 = x * ((18.0 * (t * (y * z))) - (4.0 * i)); tmp = 0.0; if (x <= -3.7e+53) tmp = t_2; elseif (x <= -2.45e-95) tmp = t_1; elseif (x <= -3.2e-188) tmp = (x * (i * -4.0)) + (-27.0 * (j * k)); elseif (x <= 6.6e+18) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -3.7e+53], t$95$2, If[LessEqual[x, -2.45e-95], t$95$1, If[LessEqual[x, -3.2e-188], N[(N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision] + N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 6.6e+18], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
t_2 := x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\
\mathbf{if}\;x \leq -3.7 \cdot 10^{+53}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -2.45 \cdot 10^{-95}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -3.2 \cdot 10^{-188}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right) + -27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;x \leq 6.6 \cdot 10^{+18}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if x < -3.7e53 or 6.6e18 < x Initial program 82.8%
sub-neg82.8%
associate-+l-82.8%
sub-neg82.8%
sub-neg82.8%
distribute-rgt-out--83.8%
associate-*l*85.9%
distribute-lft-neg-in85.9%
cancel-sign-sub85.9%
associate-*l*85.9%
associate-*l*85.9%
Simplified85.9%
Taylor expanded in x around inf 71.7%
pow171.7%
associate-*r*72.6%
Applied egg-rr72.6%
unpow172.6%
*-commutative72.6%
associate-*l*71.6%
Simplified71.6%
if -3.7e53 < x < -2.45e-95 or -3.20000000000000022e-188 < x < 6.6e18Initial program 91.8%
sub-neg91.8%
associate-+l-91.8%
sub-neg91.8%
sub-neg91.8%
distribute-rgt-out--93.2%
associate-*l*87.8%
distribute-lft-neg-in87.8%
cancel-sign-sub87.8%
associate-*l*87.8%
associate-*l*87.8%
Simplified87.8%
Taylor expanded in j around 0 74.1%
Taylor expanded in x around 0 56.6%
if -2.45e-95 < x < -3.20000000000000022e-188Initial program 99.7%
Taylor expanded in t around 0 84.3%
Taylor expanded in c around 0 75.1%
distribute-rgt-in75.1%
*-commutative75.1%
*-commutative75.1%
associate-*r*75.1%
metadata-eval75.1%
*-commutative75.1%
associate-*r*75.1%
*-commutative75.1%
associate-*l*75.1%
metadata-eval75.1%
*-commutative75.1%
Simplified75.1%
Final simplification63.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* b c) (* -4.0 (* t a)))))
(if (<= x -6.5e+53)
(* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))
(if (<= x -2.45e-95)
t_1
(if (<= x -3.2e-188)
(+ (* x (* i -4.0)) (* -27.0 (* j k)))
(if (<= x 1.8e+33)
t_1
(* x (- (* 18.0 (* y (* z t))) (* 4.0 i)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (x <= -6.5e+53) {
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
} else if (x <= -2.45e-95) {
tmp = t_1;
} else if (x <= -3.2e-188) {
tmp = (x * (i * -4.0)) + (-27.0 * (j * k));
} else if (x <= 1.8e+33) {
tmp = t_1;
} else {
tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (b * c) + ((-4.0d0) * (t * a))
if (x <= (-6.5d+53)) then
tmp = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
else if (x <= (-2.45d-95)) then
tmp = t_1
else if (x <= (-3.2d-188)) then
tmp = (x * (i * (-4.0d0))) + ((-27.0d0) * (j * k))
else if (x <= 1.8d+33) then
tmp = t_1
else
tmp = x * ((18.0d0 * (y * (z * t))) - (4.0d0 * 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 k) {
double t_1 = (b * c) + (-4.0 * (t * a));
double tmp;
if (x <= -6.5e+53) {
tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
} else if (x <= -2.45e-95) {
tmp = t_1;
} else if (x <= -3.2e-188) {
tmp = (x * (i * -4.0)) + (-27.0 * (j * k));
} else if (x <= 1.8e+33) {
tmp = t_1;
} else {
tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = (b * c) + (-4.0 * (t * a)) tmp = 0 if x <= -6.5e+53: tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i)) elif x <= -2.45e-95: tmp = t_1 elif x <= -3.2e-188: tmp = (x * (i * -4.0)) + (-27.0 * (j * k)) elif x <= 1.8e+33: tmp = t_1 else: tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i)) return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (x <= -6.5e+53) tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i))); elseif (x <= -2.45e-95) tmp = t_1; elseif (x <= -3.2e-188) tmp = Float64(Float64(x * Float64(i * -4.0)) + Float64(-27.0 * Float64(j * k))); elseif (x <= 1.8e+33) tmp = t_1; else tmp = Float64(x * Float64(Float64(18.0 * Float64(y * Float64(z * t))) - Float64(4.0 * i))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = (b * c) + (-4.0 * (t * a)); tmp = 0.0; if (x <= -6.5e+53) tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i)); elseif (x <= -2.45e-95) tmp = t_1; elseif (x <= -3.2e-188) tmp = (x * (i * -4.0)) + (-27.0 * (j * k)); elseif (x <= 1.8e+33) tmp = t_1; else tmp = x * ((18.0 * (y * (z * t))) - (4.0 * i)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6.5e+53], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -2.45e-95], t$95$1, If[LessEqual[x, -3.2e-188], N[(N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision] + N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.8e+33], t$95$1, N[(x * N[(N[(18.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;x \leq -6.5 \cdot 10^{+53}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\
\mathbf{elif}\;x \leq -2.45 \cdot 10^{-95}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -3.2 \cdot 10^{-188}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right) + -27 \cdot \left(j \cdot k\right)\\
\mathbf{elif}\;x \leq 1.8 \cdot 10^{+33}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(y \cdot \left(z \cdot t\right)\right) - 4 \cdot i\right)\\
\end{array}
\end{array}
if x < -6.50000000000000017e53Initial program 82.2%
sub-neg82.2%
associate-+l-82.2%
sub-neg82.2%
sub-neg82.2%
distribute-rgt-out--84.5%
associate-*l*86.7%
distribute-lft-neg-in86.7%
cancel-sign-sub86.7%
associate-*l*86.7%
associate-*l*86.7%
Simplified86.7%
Taylor expanded in x around inf 75.3%
pow175.3%
associate-*r*73.2%
Applied egg-rr73.2%
unpow173.2%
*-commutative73.2%
associate-*l*73.2%
Simplified73.2%
if -6.50000000000000017e53 < x < -2.45e-95 or -3.20000000000000022e-188 < x < 1.8000000000000001e33Initial program 92.0%
sub-neg92.0%
associate-+l-92.0%
sub-neg92.0%
sub-neg92.0%
distribute-rgt-out--93.3%
associate-*l*88.1%
distribute-lft-neg-in88.1%
cancel-sign-sub88.1%
associate-*l*88.1%
associate-*l*88.0%
Simplified88.0%
Taylor expanded in j around 0 74.6%
Taylor expanded in x around 0 56.1%
if -2.45e-95 < x < -3.20000000000000022e-188Initial program 99.7%
Taylor expanded in t around 0 84.3%
Taylor expanded in c around 0 75.1%
distribute-rgt-in75.1%
*-commutative75.1%
*-commutative75.1%
associate-*r*75.1%
metadata-eval75.1%
*-commutative75.1%
associate-*r*75.1%
*-commutative75.1%
associate-*l*75.1%
metadata-eval75.1%
*-commutative75.1%
Simplified75.1%
if 1.8000000000000001e33 < x Initial program 82.3%
sub-neg82.3%
associate-+l-82.3%
sub-neg82.3%
sub-neg82.3%
distribute-rgt-out--82.3%
associate-*l*84.3%
distribute-lft-neg-in84.3%
cancel-sign-sub84.3%
associate-*l*84.3%
associate-*l*84.3%
Simplified84.3%
Taylor expanded in x around inf 72.4%
Final simplification63.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (+ (* x (* i -4.0)) (* -27.0 (* j k))))
(t_2 (+ (* b c) (* -4.0 (* t a)))))
(if (<= a -2.6e+151)
t_2
(if (<= a 2.5e-101)
t_1
(if (<= a 1.15e-12)
(- (* b c) (* 4.0 (* x i)))
(if (<= a 9600.0) 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 k) {
double t_1 = (x * (i * -4.0)) + (-27.0 * (j * k));
double t_2 = (b * c) + (-4.0 * (t * a));
double tmp;
if (a <= -2.6e+151) {
tmp = t_2;
} else if (a <= 2.5e-101) {
tmp = t_1;
} else if (a <= 1.15e-12) {
tmp = (b * c) - (4.0 * (x * i));
} else if (a <= 9600.0) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (x * (i * (-4.0d0))) + ((-27.0d0) * (j * k))
t_2 = (b * c) + ((-4.0d0) * (t * a))
if (a <= (-2.6d+151)) then
tmp = t_2
else if (a <= 2.5d-101) then
tmp = t_1
else if (a <= 1.15d-12) then
tmp = (b * c) - (4.0d0 * (x * i))
else if (a <= 9600.0d0) then
tmp = 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 k) {
double t_1 = (x * (i * -4.0)) + (-27.0 * (j * k));
double t_2 = (b * c) + (-4.0 * (t * a));
double tmp;
if (a <= -2.6e+151) {
tmp = t_2;
} else if (a <= 2.5e-101) {
tmp = t_1;
} else if (a <= 1.15e-12) {
tmp = (b * c) - (4.0 * (x * i));
} else if (a <= 9600.0) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = (x * (i * -4.0)) + (-27.0 * (j * k)) t_2 = (b * c) + (-4.0 * (t * a)) tmp = 0 if a <= -2.6e+151: tmp = t_2 elif a <= 2.5e-101: tmp = t_1 elif a <= 1.15e-12: tmp = (b * c) - (4.0 * (x * i)) elif a <= 9600.0: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(x * Float64(i * -4.0)) + Float64(-27.0 * Float64(j * k))) t_2 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))) tmp = 0.0 if (a <= -2.6e+151) tmp = t_2; elseif (a <= 2.5e-101) tmp = t_1; elseif (a <= 1.15e-12) tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))); elseif (a <= 9600.0) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = (x * (i * -4.0)) + (-27.0 * (j * k)); t_2 = (b * c) + (-4.0 * (t * a)); tmp = 0.0; if (a <= -2.6e+151) tmp = t_2; elseif (a <= 2.5e-101) tmp = t_1; elseif (a <= 1.15e-12) tmp = (b * c) - (4.0 * (x * i)); elseif (a <= 9600.0) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision] + N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.6e+151], t$95$2, If[LessEqual[a, 2.5e-101], t$95$1, If[LessEqual[a, 1.15e-12], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 9600.0], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(i \cdot -4\right) + -27 \cdot \left(j \cdot k\right)\\
t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;a \leq -2.6 \cdot 10^{+151}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;a \leq 2.5 \cdot 10^{-101}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq 1.15 \cdot 10^{-12}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\
\mathbf{elif}\;a \leq 9600:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if a < -2.60000000000000013e151 or 9600 < a Initial program 87.6%
sub-neg87.6%
associate-+l-87.6%
sub-neg87.6%
sub-neg87.6%
distribute-rgt-out--90.5%
associate-*l*88.6%
distribute-lft-neg-in88.6%
cancel-sign-sub88.6%
associate-*l*88.6%
associate-*l*88.6%
Simplified88.6%
Taylor expanded in j around 0 83.0%
Taylor expanded in x around 0 67.3%
if -2.60000000000000013e151 < a < 2.5e-101 or 1.14999999999999995e-12 < a < 9600Initial program 89.7%
Taylor expanded in t around 0 66.9%
Taylor expanded in c around 0 51.8%
distribute-rgt-in51.8%
*-commutative51.8%
*-commutative51.8%
associate-*r*51.8%
metadata-eval51.8%
*-commutative51.8%
associate-*r*51.8%
*-commutative51.8%
associate-*l*51.8%
metadata-eval51.8%
*-commutative51.8%
Simplified51.8%
if 2.5e-101 < a < 1.14999999999999995e-12Initial program 88.5%
sub-neg88.5%
associate-+l-88.5%
sub-neg88.5%
sub-neg88.5%
distribute-rgt-out--88.5%
associate-*l*82.5%
distribute-lft-neg-in82.5%
cancel-sign-sub82.5%
associate-*l*82.5%
associate-*l*82.5%
Simplified82.5%
Taylor expanded in j around 0 82.4%
Taylor expanded in t around 0 60.4%
Final simplification58.6%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* -4.0 (* t a))) (t_2 (* 18.0 (* t (* y (* x z))))))
(if (<= z -3.6e-93)
t_2
(if (<= z 4.7e-10)
t_1
(if (<= z 2.9e+69) (* b c) (if (<= z 8.5e+152) 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 k) {
double t_1 = -4.0 * (t * a);
double t_2 = 18.0 * (t * (y * (x * z)));
double tmp;
if (z <= -3.6e-93) {
tmp = t_2;
} else if (z <= 4.7e-10) {
tmp = t_1;
} else if (z <= 2.9e+69) {
tmp = b * c;
} else if (z <= 8.5e+152) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (-4.0d0) * (t * a)
t_2 = 18.0d0 * (t * (y * (x * z)))
if (z <= (-3.6d-93)) then
tmp = t_2
else if (z <= 4.7d-10) then
tmp = t_1
else if (z <= 2.9d+69) then
tmp = b * c
else if (z <= 8.5d+152) then
tmp = 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 k) {
double t_1 = -4.0 * (t * a);
double t_2 = 18.0 * (t * (y * (x * z)));
double tmp;
if (z <= -3.6e-93) {
tmp = t_2;
} else if (z <= 4.7e-10) {
tmp = t_1;
} else if (z <= 2.9e+69) {
tmp = b * c;
} else if (z <= 8.5e+152) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (t * a) t_2 = 18.0 * (t * (y * (x * z))) tmp = 0 if z <= -3.6e-93: tmp = t_2 elif z <= 4.7e-10: tmp = t_1 elif z <= 2.9e+69: tmp = b * c elif z <= 8.5e+152: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(t * a)) t_2 = Float64(18.0 * Float64(t * Float64(y * Float64(x * z)))) tmp = 0.0 if (z <= -3.6e-93) tmp = t_2; elseif (z <= 4.7e-10) tmp = t_1; elseif (z <= 2.9e+69) tmp = Float64(b * c); elseif (z <= 8.5e+152) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = -4.0 * (t * a); t_2 = 18.0 * (t * (y * (x * z))); tmp = 0.0; if (z <= -3.6e-93) tmp = t_2; elseif (z <= 4.7e-10) tmp = t_1; elseif (z <= 2.9e+69) tmp = b * c; elseif (z <= 8.5e+152) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(18.0 * N[(t * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.6e-93], t$95$2, If[LessEqual[z, 4.7e-10], t$95$1, If[LessEqual[z, 2.9e+69], N[(b * c), $MachinePrecision], If[LessEqual[z, 8.5e+152], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -4 \cdot \left(t \cdot a\right)\\
t_2 := 18 \cdot \left(t \cdot \left(y \cdot \left(x \cdot z\right)\right)\right)\\
\mathbf{if}\;z \leq -3.6 \cdot 10^{-93}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;z \leq 4.7 \cdot 10^{-10}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 2.9 \cdot 10^{+69}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;z \leq 8.5 \cdot 10^{+152}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if z < -3.6000000000000002e-93 or 8.4999999999999993e152 < z Initial program 86.0%
sub-neg86.0%
associate-+l-86.0%
sub-neg86.0%
sub-neg86.0%
distribute-rgt-out--87.9%
associate-*l*81.4%
distribute-lft-neg-in81.4%
cancel-sign-sub81.4%
associate-*l*81.4%
associate-*l*81.4%
Simplified81.4%
Taylor expanded in x around inf 53.3%
pow153.3%
associate-*r*53.2%
Applied egg-rr53.2%
unpow153.2%
*-commutative53.2%
associate-*l*51.4%
Simplified51.4%
Taylor expanded in t around inf 42.6%
*-commutative42.6%
associate-*l*44.0%
*-commutative44.0%
*-commutative44.0%
Simplified44.0%
if -3.6000000000000002e-93 < z < 4.7000000000000003e-10 or 2.8999999999999998e69 < z < 8.4999999999999993e152Initial program 90.1%
sub-neg90.1%
associate-+l-90.1%
sub-neg90.1%
sub-neg90.1%
distribute-rgt-out--90.8%
associate-*l*91.5%
distribute-lft-neg-in91.5%
cancel-sign-sub91.5%
associate-*l*91.5%
associate-*l*91.5%
Simplified91.5%
Taylor expanded in j around 0 75.0%
Taylor expanded in x around 0 54.0%
Taylor expanded in c around 0 37.0%
if 4.7000000000000003e-10 < z < 2.8999999999999998e69Initial program 100.0%
sub-neg100.0%
associate-+l-100.0%
sub-neg100.0%
sub-neg100.0%
distribute-rgt-out--100.0%
associate-*l*100.0%
distribute-lft-neg-in100.0%
cancel-sign-sub100.0%
associate-*l*100.0%
associate-*l*100.0%
Simplified100.0%
Taylor expanded in j around 0 77.8%
Taylor expanded in c around inf 67.3%
Final simplification41.0%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* -4.0 (* t a))))
(if (<= z -7.5e-93)
(* 18.0 (* y (* t (* x z))))
(if (<= z 8.2e-12)
t_1
(if (<= z 1.8e+70)
(* b c)
(if (<= z 9e+152) t_1 (* 18.0 (* t (* y (* x z))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (t * a);
double tmp;
if (z <= -7.5e-93) {
tmp = 18.0 * (y * (t * (x * z)));
} else if (z <= 8.2e-12) {
tmp = t_1;
} else if (z <= 1.8e+70) {
tmp = b * c;
} else if (z <= 9e+152) {
tmp = t_1;
} else {
tmp = 18.0 * (t * (y * (x * z)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (t * a)
if (z <= (-7.5d-93)) then
tmp = 18.0d0 * (y * (t * (x * z)))
else if (z <= 8.2d-12) then
tmp = t_1
else if (z <= 1.8d+70) then
tmp = b * c
else if (z <= 9d+152) then
tmp = t_1
else
tmp = 18.0d0 * (t * (y * (x * 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 k) {
double t_1 = -4.0 * (t * a);
double tmp;
if (z <= -7.5e-93) {
tmp = 18.0 * (y * (t * (x * z)));
} else if (z <= 8.2e-12) {
tmp = t_1;
} else if (z <= 1.8e+70) {
tmp = b * c;
} else if (z <= 9e+152) {
tmp = t_1;
} else {
tmp = 18.0 * (t * (y * (x * z)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (t * a) tmp = 0 if z <= -7.5e-93: tmp = 18.0 * (y * (t * (x * z))) elif z <= 8.2e-12: tmp = t_1 elif z <= 1.8e+70: tmp = b * c elif z <= 9e+152: tmp = t_1 else: tmp = 18.0 * (t * (y * (x * z))) return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(t * a)) tmp = 0.0 if (z <= -7.5e-93) tmp = Float64(18.0 * Float64(y * Float64(t * Float64(x * z)))); elseif (z <= 8.2e-12) tmp = t_1; elseif (z <= 1.8e+70) tmp = Float64(b * c); elseif (z <= 9e+152) tmp = t_1; else tmp = Float64(18.0 * Float64(t * Float64(y * Float64(x * z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = -4.0 * (t * a); tmp = 0.0; if (z <= -7.5e-93) tmp = 18.0 * (y * (t * (x * z))); elseif (z <= 8.2e-12) tmp = t_1; elseif (z <= 1.8e+70) tmp = b * c; elseif (z <= 9e+152) tmp = t_1; else tmp = 18.0 * (t * (y * (x * z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -7.5e-93], N[(18.0 * N[(y * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.2e-12], t$95$1, If[LessEqual[z, 1.8e+70], N[(b * c), $MachinePrecision], If[LessEqual[z, 9e+152], t$95$1, N[(18.0 * N[(t * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;z \leq -7.5 \cdot 10^{-93}:\\
\;\;\;\;18 \cdot \left(y \cdot \left(t \cdot \left(x \cdot z\right)\right)\right)\\
\mathbf{elif}\;z \leq 8.2 \cdot 10^{-12}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 1.8 \cdot 10^{+70}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+152}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(y \cdot \left(x \cdot z\right)\right)\right)\\
\end{array}
\end{array}
if z < -7.50000000000000034e-93Initial program 85.2%
sub-neg85.2%
associate-+l-85.2%
sub-neg85.2%
sub-neg85.2%
distribute-rgt-out--86.6%
associate-*l*80.0%
distribute-lft-neg-in80.0%
cancel-sign-sub80.0%
associate-*l*80.0%
associate-*l*80.0%
Simplified80.0%
Taylor expanded in x around inf 51.2%
pow151.2%
associate-*r*48.7%
Applied egg-rr48.7%
unpow148.7%
*-commutative48.7%
associate-*l*47.3%
Simplified47.3%
Taylor expanded in t around inf 42.2%
if -7.50000000000000034e-93 < z < 8.19999999999999979e-12 or 1.8e70 < z < 9.0000000000000002e152Initial program 90.1%
sub-neg90.1%
associate-+l-90.1%
sub-neg90.1%
sub-neg90.1%
distribute-rgt-out--90.8%
associate-*l*91.5%
distribute-lft-neg-in91.5%
cancel-sign-sub91.5%
associate-*l*91.5%
associate-*l*91.5%
Simplified91.5%
Taylor expanded in j around 0 75.0%
Taylor expanded in x around 0 54.0%
Taylor expanded in c around 0 37.0%
if 8.19999999999999979e-12 < z < 1.8e70Initial program 100.0%
sub-neg100.0%
associate-+l-100.0%
sub-neg100.0%
sub-neg100.0%
distribute-rgt-out--100.0%
associate-*l*100.0%
distribute-lft-neg-in100.0%
cancel-sign-sub100.0%
associate-*l*100.0%
associate-*l*100.0%
Simplified100.0%
Taylor expanded in j around 0 77.8%
Taylor expanded in c around inf 67.3%
if 9.0000000000000002e152 < z Initial program 87.9%
sub-neg87.9%
associate-+l-87.9%
sub-neg87.9%
sub-neg87.9%
distribute-rgt-out--91.0%
associate-*l*84.9%
distribute-lft-neg-in84.9%
cancel-sign-sub84.9%
associate-*l*84.9%
associate-*l*84.9%
Simplified84.9%
Taylor expanded in x around inf 58.1%
pow158.1%
associate-*r*63.9%
Applied egg-rr63.9%
unpow163.9%
*-commutative63.9%
associate-*l*60.8%
Simplified60.8%
Taylor expanded in t around inf 43.3%
*-commutative43.3%
associate-*l*49.2%
*-commutative49.2%
*-commutative49.2%
Simplified49.2%
Final simplification41.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* -4.0 (* t a))))
(if (<= z -1.6e-92)
(* (* 18.0 y) (* t (* x z)))
(if (<= z 2.5e-11)
t_1
(if (<= z 1.65e+68)
(* b c)
(if (<= z 1.02e+153) t_1 (* 18.0 (* t (* y (* x z))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = -4.0 * (t * a);
double tmp;
if (z <= -1.6e-92) {
tmp = (18.0 * y) * (t * (x * z));
} else if (z <= 2.5e-11) {
tmp = t_1;
} else if (z <= 1.65e+68) {
tmp = b * c;
} else if (z <= 1.02e+153) {
tmp = t_1;
} else {
tmp = 18.0 * (t * (y * (x * z)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (t * a)
if (z <= (-1.6d-92)) then
tmp = (18.0d0 * y) * (t * (x * z))
else if (z <= 2.5d-11) then
tmp = t_1
else if (z <= 1.65d+68) then
tmp = b * c
else if (z <= 1.02d+153) then
tmp = t_1
else
tmp = 18.0d0 * (t * (y * (x * 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 k) {
double t_1 = -4.0 * (t * a);
double tmp;
if (z <= -1.6e-92) {
tmp = (18.0 * y) * (t * (x * z));
} else if (z <= 2.5e-11) {
tmp = t_1;
} else if (z <= 1.65e+68) {
tmp = b * c;
} else if (z <= 1.02e+153) {
tmp = t_1;
} else {
tmp = 18.0 * (t * (y * (x * z)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = -4.0 * (t * a) tmp = 0 if z <= -1.6e-92: tmp = (18.0 * y) * (t * (x * z)) elif z <= 2.5e-11: tmp = t_1 elif z <= 1.65e+68: tmp = b * c elif z <= 1.02e+153: tmp = t_1 else: tmp = 18.0 * (t * (y * (x * z))) return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(-4.0 * Float64(t * a)) tmp = 0.0 if (z <= -1.6e-92) tmp = Float64(Float64(18.0 * y) * Float64(t * Float64(x * z))); elseif (z <= 2.5e-11) tmp = t_1; elseif (z <= 1.65e+68) tmp = Float64(b * c); elseif (z <= 1.02e+153) tmp = t_1; else tmp = Float64(18.0 * Float64(t * Float64(y * Float64(x * z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = -4.0 * (t * a); tmp = 0.0; if (z <= -1.6e-92) tmp = (18.0 * y) * (t * (x * z)); elseif (z <= 2.5e-11) tmp = t_1; elseif (z <= 1.65e+68) tmp = b * c; elseif (z <= 1.02e+153) tmp = t_1; else tmp = 18.0 * (t * (y * (x * z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.6e-92], N[(N[(18.0 * y), $MachinePrecision] * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e-11], t$95$1, If[LessEqual[z, 1.65e+68], N[(b * c), $MachinePrecision], If[LessEqual[z, 1.02e+153], t$95$1, N[(18.0 * N[(t * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;z \leq -1.6 \cdot 10^{-92}:\\
\;\;\;\;\left(18 \cdot y\right) \cdot \left(t \cdot \left(x \cdot z\right)\right)\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{-11}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 1.65 \cdot 10^{+68}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;z \leq 1.02 \cdot 10^{+153}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(y \cdot \left(x \cdot z\right)\right)\right)\\
\end{array}
\end{array}
if z < -1.5999999999999998e-92Initial program 85.0%
Taylor expanded in t around -inf 58.5%
mul-1-neg58.5%
*-commutative58.5%
distribute-rgt-neg-in58.5%
cancel-sign-sub-inv58.5%
metadata-eval58.5%
+-commutative58.5%
*-commutative58.5%
fma-def58.5%
*-commutative58.5%
associate-*r*58.5%
Simplified58.5%
Taylor expanded in a around 0 42.8%
associate-*r*42.7%
*-commutative42.7%
*-commutative42.7%
Simplified42.7%
if -1.5999999999999998e-92 < z < 2.50000000000000009e-11 or 1.65e68 < z < 1.0199999999999999e153Initial program 90.2%
sub-neg90.2%
associate-+l-90.2%
sub-neg90.2%
sub-neg90.2%
distribute-rgt-out--90.9%
associate-*l*91.6%
distribute-lft-neg-in91.6%
cancel-sign-sub91.6%
associate-*l*91.6%
associate-*l*91.6%
Simplified91.6%
Taylor expanded in j around 0 74.5%
Taylor expanded in x around 0 53.6%
Taylor expanded in c around 0 36.8%
if 2.50000000000000009e-11 < z < 1.65e68Initial program 100.0%
sub-neg100.0%
associate-+l-100.0%
sub-neg100.0%
sub-neg100.0%
distribute-rgt-out--100.0%
associate-*l*100.0%
distribute-lft-neg-in100.0%
cancel-sign-sub100.0%
associate-*l*100.0%
associate-*l*100.0%
Simplified100.0%
Taylor expanded in j around 0 77.8%
Taylor expanded in c around inf 67.3%
if 1.0199999999999999e153 < z Initial program 87.9%
sub-neg87.9%
associate-+l-87.9%
sub-neg87.9%
sub-neg87.9%
distribute-rgt-out--91.0%
associate-*l*84.9%
distribute-lft-neg-in84.9%
cancel-sign-sub84.9%
associate-*l*84.9%
associate-*l*84.9%
Simplified84.9%
Taylor expanded in x around inf 58.1%
pow158.1%
associate-*r*63.9%
Applied egg-rr63.9%
unpow163.9%
*-commutative63.9%
associate-*l*60.8%
Simplified60.8%
Taylor expanded in t around inf 43.3%
*-commutative43.3%
associate-*l*49.2%
*-commutative49.2%
*-commutative49.2%
Simplified49.2%
Final simplification41.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= z -1.6e-92)
(* (* 18.0 y) (* t (* x z)))
(if (<= z 9e+152)
(+ (* b c) (* -4.0 (* t a)))
(* 18.0 (* t (* y (* x z)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (z <= -1.6e-92) {
tmp = (18.0 * y) * (t * (x * z));
} else if (z <= 9e+152) {
tmp = (b * c) + (-4.0 * (t * a));
} else {
tmp = 18.0 * (t * (y * (x * z)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (z <= (-1.6d-92)) then
tmp = (18.0d0 * y) * (t * (x * z))
else if (z <= 9d+152) then
tmp = (b * c) + ((-4.0d0) * (t * a))
else
tmp = 18.0d0 * (t * (y * (x * 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 k) {
double tmp;
if (z <= -1.6e-92) {
tmp = (18.0 * y) * (t * (x * z));
} else if (z <= 9e+152) {
tmp = (b * c) + (-4.0 * (t * a));
} else {
tmp = 18.0 * (t * (y * (x * z)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if z <= -1.6e-92: tmp = (18.0 * y) * (t * (x * z)) elif z <= 9e+152: tmp = (b * c) + (-4.0 * (t * a)) else: tmp = 18.0 * (t * (y * (x * z))) return tmp
function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (z <= -1.6e-92) tmp = Float64(Float64(18.0 * y) * Float64(t * Float64(x * z))); elseif (z <= 9e+152) tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a))); else tmp = Float64(18.0 * Float64(t * Float64(y * Float64(x * z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0; if (z <= -1.6e-92) tmp = (18.0 * y) * (t * (x * z)); elseif (z <= 9e+152) tmp = (b * c) + (-4.0 * (t * a)); else tmp = 18.0 * (t * (y * (x * z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[z, -1.6e-92], N[(N[(18.0 * y), $MachinePrecision] * N[(t * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e+152], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(18.0 * N[(t * N[(y * N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.6 \cdot 10^{-92}:\\
\;\;\;\;\left(18 \cdot y\right) \cdot \left(t \cdot \left(x \cdot z\right)\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+152}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{else}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(y \cdot \left(x \cdot z\right)\right)\right)\\
\end{array}
\end{array}
if z < -1.5999999999999998e-92Initial program 85.0%
Taylor expanded in t around -inf 58.5%
mul-1-neg58.5%
*-commutative58.5%
distribute-rgt-neg-in58.5%
cancel-sign-sub-inv58.5%
metadata-eval58.5%
+-commutative58.5%
*-commutative58.5%
fma-def58.5%
*-commutative58.5%
associate-*r*58.5%
Simplified58.5%
Taylor expanded in a around 0 42.8%
associate-*r*42.7%
*-commutative42.7%
*-commutative42.7%
Simplified42.7%
if -1.5999999999999998e-92 < z < 9.0000000000000002e152Initial program 90.8%
sub-neg90.8%
associate-+l-90.8%
sub-neg90.8%
sub-neg90.8%
distribute-rgt-out--91.4%
associate-*l*92.1%
distribute-lft-neg-in92.1%
cancel-sign-sub92.1%
associate-*l*92.1%
associate-*l*92.1%
Simplified92.1%
Taylor expanded in j around 0 74.7%
Taylor expanded in x around 0 54.4%
if 9.0000000000000002e152 < z Initial program 87.9%
sub-neg87.9%
associate-+l-87.9%
sub-neg87.9%
sub-neg87.9%
distribute-rgt-out--91.0%
associate-*l*84.9%
distribute-lft-neg-in84.9%
cancel-sign-sub84.9%
associate-*l*84.9%
associate-*l*84.9%
Simplified84.9%
Taylor expanded in x around inf 58.1%
pow158.1%
associate-*r*63.9%
Applied egg-rr63.9%
unpow163.9%
*-commutative63.9%
associate-*l*60.8%
Simplified60.8%
Taylor expanded in t around inf 43.3%
*-commutative43.3%
associate-*l*49.2%
*-commutative49.2%
*-commutative49.2%
Simplified49.2%
Final simplification50.4%
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= b -1.62e+142)
(* b c)
(if (<= b -2.5e-174)
(* -4.0 (* t a))
(if (<= b 1.06e-7) (* -27.0 (* j k)) (* b c)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (b <= -1.62e+142) {
tmp = b * c;
} else if (b <= -2.5e-174) {
tmp = -4.0 * (t * a);
} else if (b <= 1.06e-7) {
tmp = -27.0 * (j * k);
} else {
tmp = b * c;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (b <= (-1.62d+142)) then
tmp = b * c
else if (b <= (-2.5d-174)) then
tmp = (-4.0d0) * (t * a)
else if (b <= 1.06d-7) then
tmp = (-27.0d0) * (j * k)
else
tmp = b * c
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (b <= -1.62e+142) {
tmp = b * c;
} else if (b <= -2.5e-174) {
tmp = -4.0 * (t * a);
} else if (b <= 1.06e-7) {
tmp = -27.0 * (j * k);
} else {
tmp = b * c;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if b <= -1.62e+142: tmp = b * c elif b <= -2.5e-174: tmp = -4.0 * (t * a) elif b <= 1.06e-7: tmp = -27.0 * (j * k) else: tmp = b * c return tmp
function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (b <= -1.62e+142) tmp = Float64(b * c); elseif (b <= -2.5e-174) tmp = Float64(-4.0 * Float64(t * a)); elseif (b <= 1.06e-7) tmp = Float64(-27.0 * Float64(j * k)); else tmp = Float64(b * c); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0; if (b <= -1.62e+142) tmp = b * c; elseif (b <= -2.5e-174) tmp = -4.0 * (t * a); elseif (b <= 1.06e-7) tmp = -27.0 * (j * k); else tmp = b * c; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[b, -1.62e+142], N[(b * c), $MachinePrecision], If[LessEqual[b, -2.5e-174], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.06e-7], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.62 \cdot 10^{+142}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \leq -2.5 \cdot 10^{-174}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;b \leq 1.06 \cdot 10^{-7}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if b < -1.62000000000000006e142 or 1.06e-7 < b Initial program 85.5%
sub-neg85.5%
associate-+l-85.5%
sub-neg85.5%
sub-neg85.5%
distribute-rgt-out--87.5%
associate-*l*83.7%
distribute-lft-neg-in83.7%
cancel-sign-sub83.7%
associate-*l*83.7%
associate-*l*83.7%
Simplified83.7%
Taylor expanded in j around 0 70.7%
Taylor expanded in c around inf 37.1%
if -1.62000000000000006e142 < b < -2.5000000000000001e-174Initial program 90.6%
sub-neg90.6%
associate-+l-90.6%
sub-neg90.6%
sub-neg90.6%
distribute-rgt-out--92.2%
associate-*l*92.2%
distribute-lft-neg-in92.2%
cancel-sign-sub92.2%
associate-*l*92.2%
associate-*l*92.2%
Simplified92.2%
Taylor expanded in j around 0 78.7%
Taylor expanded in x around 0 48.4%
Taylor expanded in c around 0 36.0%
if -2.5000000000000001e-174 < b < 1.06e-7Initial program 91.2%
sub-neg91.2%
+-commutative91.2%
associate-*l*91.2%
distribute-rgt-neg-in91.2%
fma-def92.3%
*-commutative92.3%
distribute-rgt-neg-in92.3%
metadata-eval92.3%
sub-neg92.3%
+-commutative92.3%
associate-*l*92.3%
distribute-rgt-neg-in92.3%
Simplified91.2%
Taylor expanded in j around inf 23.4%
Final simplification32.1%
(FPCore (x y z t a b c i j k)
:precision binary64
(if (<= b -3.4e+141)
(* b c)
(if (<= b -1.06e-172)
(* -4.0 (* t a))
(if (<= b 8.2e-8) (* j (* k -27.0)) (* b c)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (b <= -3.4e+141) {
tmp = b * c;
} else if (b <= -1.06e-172) {
tmp = -4.0 * (t * a);
} else if (b <= 8.2e-8) {
tmp = j * (k * -27.0);
} else {
tmp = b * c;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (b <= (-3.4d+141)) then
tmp = b * c
else if (b <= (-1.06d-172)) then
tmp = (-4.0d0) * (t * a)
else if (b <= 8.2d-8) then
tmp = j * (k * (-27.0d0))
else
tmp = b * c
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (b <= -3.4e+141) {
tmp = b * c;
} else if (b <= -1.06e-172) {
tmp = -4.0 * (t * a);
} else if (b <= 8.2e-8) {
tmp = j * (k * -27.0);
} else {
tmp = b * c;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if b <= -3.4e+141: tmp = b * c elif b <= -1.06e-172: tmp = -4.0 * (t * a) elif b <= 8.2e-8: tmp = j * (k * -27.0) else: tmp = b * c return tmp
function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (b <= -3.4e+141) tmp = Float64(b * c); elseif (b <= -1.06e-172) tmp = Float64(-4.0 * Float64(t * a)); elseif (b <= 8.2e-8) tmp = Float64(j * Float64(k * -27.0)); else tmp = Float64(b * c); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0; if (b <= -3.4e+141) tmp = b * c; elseif (b <= -1.06e-172) tmp = -4.0 * (t * a); elseif (b <= 8.2e-8) tmp = j * (k * -27.0); else tmp = b * c; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[b, -3.4e+141], N[(b * c), $MachinePrecision], If[LessEqual[b, -1.06e-172], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 8.2e-8], N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.4 \cdot 10^{+141}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \leq -1.06 \cdot 10^{-172}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\
\mathbf{elif}\;b \leq 8.2 \cdot 10^{-8}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if b < -3.3999999999999998e141 or 8.20000000000000063e-8 < b Initial program 85.5%
sub-neg85.5%
associate-+l-85.5%
sub-neg85.5%
sub-neg85.5%
distribute-rgt-out--87.5%
associate-*l*83.7%
distribute-lft-neg-in83.7%
cancel-sign-sub83.7%
associate-*l*83.7%
associate-*l*83.7%
Simplified83.7%
Taylor expanded in j around 0 70.7%
Taylor expanded in c around inf 37.1%
if -3.3999999999999998e141 < b < -1.05999999999999993e-172Initial program 90.6%
sub-neg90.6%
associate-+l-90.6%
sub-neg90.6%
sub-neg90.6%
distribute-rgt-out--92.2%
associate-*l*92.2%
distribute-lft-neg-in92.2%
cancel-sign-sub92.2%
associate-*l*92.2%
associate-*l*92.2%
Simplified92.2%
Taylor expanded in j around 0 78.7%
Taylor expanded in x around 0 48.4%
Taylor expanded in c around 0 36.0%
if -1.05999999999999993e-172 < b < 8.20000000000000063e-8Initial program 91.2%
sub-neg91.2%
+-commutative91.2%
associate-*l*91.2%
distribute-rgt-neg-in91.2%
fma-def92.3%
*-commutative92.3%
distribute-rgt-neg-in92.3%
metadata-eval92.3%
sub-neg92.3%
+-commutative92.3%
associate-*l*92.3%
distribute-rgt-neg-in92.3%
Simplified91.2%
Taylor expanded in j around inf 23.4%
associate-*r*23.4%
*-commutative23.4%
*-commutative23.4%
*-commutative23.4%
Simplified23.4%
Final simplification32.1%
(FPCore (x y z t a b c i j k) :precision binary64 (if (<= b -2.05e+86) (* b c) (if (<= b 5e-9) (* -27.0 (* j k)) (* b c))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (b <= -2.05e+86) {
tmp = b * c;
} else if (b <= 5e-9) {
tmp = -27.0 * (j * k);
} else {
tmp = b * c;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: tmp
if (b <= (-2.05d+86)) then
tmp = b * c
else if (b <= 5d-9) then
tmp = (-27.0d0) * (j * k)
else
tmp = b * c
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double tmp;
if (b <= -2.05e+86) {
tmp = b * c;
} else if (b <= 5e-9) {
tmp = -27.0 * (j * k);
} else {
tmp = b * c;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): tmp = 0 if b <= -2.05e+86: tmp = b * c elif b <= 5e-9: tmp = -27.0 * (j * k) else: tmp = b * c return tmp
function code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0 if (b <= -2.05e+86) tmp = Float64(b * c); elseif (b <= 5e-9) tmp = Float64(-27.0 * Float64(j * k)); else tmp = Float64(b * c); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) tmp = 0.0; if (b <= -2.05e+86) tmp = b * c; elseif (b <= 5e-9) tmp = -27.0 * (j * k); else tmp = b * c; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[b, -2.05e+86], N[(b * c), $MachinePrecision], If[LessEqual[b, 5e-9], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -2.05 \cdot 10^{+86}:\\
\;\;\;\;b \cdot c\\
\mathbf{elif}\;b \leq 5 \cdot 10^{-9}:\\
\;\;\;\;-27 \cdot \left(j \cdot k\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot c\\
\end{array}
\end{array}
if b < -2.05e86 or 5.0000000000000001e-9 < b Initial program 85.9%
sub-neg85.9%
associate-+l-85.9%
sub-neg85.9%
sub-neg85.9%
distribute-rgt-out--88.4%
associate-*l*85.2%
distribute-lft-neg-in85.2%
cancel-sign-sub85.2%
associate-*l*85.2%
associate-*l*85.2%
Simplified85.2%
Taylor expanded in j around 0 73.2%
Taylor expanded in c around inf 35.6%
if -2.05e86 < b < 5.0000000000000001e-9Initial program 91.3%
sub-neg91.3%
+-commutative91.3%
associate-*l*91.3%
distribute-rgt-neg-in91.3%
fma-def93.5%
*-commutative93.5%
distribute-rgt-neg-in93.5%
metadata-eval93.5%
sub-neg93.5%
+-commutative93.5%
associate-*l*93.5%
distribute-rgt-neg-in93.5%
Simplified92.8%
Taylor expanded in j around inf 23.6%
Final simplification29.2%
(FPCore (x y z t a b c i j k) :precision binary64 (* b c))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
code = b * c
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
return b * c;
}
def code(x, y, z, t, a, b, c, i, j, k): return b * c
function code(x, y, z, t, a, b, c, i, j, k) return Float64(b * c) end
function tmp = code(x, y, z, t, a, b, c, i, j, k) tmp = b * c; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(b * c), $MachinePrecision]
\begin{array}{l}
\\
b \cdot c
\end{array}
Initial program 88.8%
sub-neg88.8%
associate-+l-88.8%
sub-neg88.8%
sub-neg88.8%
distribute-rgt-out--89.9%
associate-*l*87.6%
distribute-lft-neg-in87.6%
cancel-sign-sub87.6%
associate-*l*87.6%
associate-*l*87.6%
Simplified87.6%
Taylor expanded in j around 0 73.0%
Taylor expanded in c around inf 20.6%
Final simplification20.6%
(FPCore (x y z t a b c i j k)
:precision binary64
(let* ((t_1 (* (+ (* a t) (* i x)) 4.0))
(t_2
(-
(- (* (* 18.0 t) (* (* x y) z)) t_1)
(- (* (* k j) 27.0) (* c b)))))
(if (< t -1.6210815397541398e-69)
t_2
(if (< t 165.68027943805222)
(+ (- (* (* 18.0 y) (* x (* z t))) t_1) (- (* c b) (* 27.0 (* k j))))
t_2))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = ((a * t) + (i * x)) * 4.0;
double t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
double tmp;
if (t < -1.6210815397541398e-69) {
tmp = t_2;
} else if (t < 165.68027943805222) {
tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8), intent (in) :: j
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = ((a * t) + (i * x)) * 4.0d0
t_2 = (((18.0d0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0d0) - (c * b))
if (t < (-1.6210815397541398d-69)) then
tmp = t_2
else if (t < 165.68027943805222d0) then
tmp = (((18.0d0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0d0 * (k * j)))
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
double t_1 = ((a * t) + (i * x)) * 4.0;
double t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
double tmp;
if (t < -1.6210815397541398e-69) {
tmp = t_2;
} else if (t < 165.68027943805222) {
tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k): t_1 = ((a * t) + (i * x)) * 4.0 t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b)) tmp = 0 if t < -1.6210815397541398e-69: tmp = t_2 elif t < 165.68027943805222: tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j))) else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i, j, k) t_1 = Float64(Float64(Float64(a * t) + Float64(i * x)) * 4.0) t_2 = Float64(Float64(Float64(Float64(18.0 * t) * Float64(Float64(x * y) * z)) - t_1) - Float64(Float64(Float64(k * j) * 27.0) - Float64(c * b))) tmp = 0.0 if (t < -1.6210815397541398e-69) tmp = t_2; elseif (t < 165.68027943805222) tmp = Float64(Float64(Float64(Float64(18.0 * y) * Float64(x * Float64(z * t))) - t_1) + Float64(Float64(c * b) - Float64(27.0 * Float64(k * j)))); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k) t_1 = ((a * t) + (i * x)) * 4.0; t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b)); tmp = 0.0; if (t < -1.6210815397541398e-69) tmp = t_2; elseif (t < 165.68027943805222) tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j))); else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(a * t), $MachinePrecision] + N[(i * x), $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(18.0 * t), $MachinePrecision] * N[(N[(x * y), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - N[(N[(N[(k * j), $MachinePrecision] * 27.0), $MachinePrecision] - N[(c * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -1.6210815397541398e-69], t$95$2, If[Less[t, 165.68027943805222], N[(N[(N[(N[(18.0 * y), $MachinePrecision] * N[(x * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] + N[(N[(c * b), $MachinePrecision] - N[(27.0 * N[(k * j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(a \cdot t + i \cdot x\right) \cdot 4\\
t_2 := \left(\left(18 \cdot t\right) \cdot \left(\left(x \cdot y\right) \cdot z\right) - t_1\right) - \left(\left(k \cdot j\right) \cdot 27 - c \cdot b\right)\\
\mathbf{if}\;t < -1.6210815397541398 \cdot 10^{-69}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t < 165.68027943805222:\\
\;\;\;\;\left(\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right) - t_1\right) + \left(c \cdot b - 27 \cdot \left(k \cdot j\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
herbie shell --seed 2023196
(FPCore (x y z t a b c i j k)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, E"
:precision binary64
:herbie-target
(if (< t -1.6210815397541398e-69) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b))) (if (< t 165.68027943805222) (+ (- (* (* 18.0 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4.0)) (- (* c b) (* 27.0 (* k j)))) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b)))))
(- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))