
(FPCore (x y z t a b c i) :precision binary64 (+ (+ (+ (* x y) (* z t)) (* a b)) (* c i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((x * y) + (z * t)) + (a * b)) + (c * i);
}
real(8) function code(x, y, z, t, a, b, c, i)
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
code = (((x * y) + (z * t)) + (a * b)) + (c * i)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((x * y) + (z * t)) + (a * b)) + (c * i);
}
def code(x, y, z, t, a, b, c, i): return (((x * y) + (z * t)) + (a * b)) + (c * i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(Float64(x * y) + Float64(z * t)) + Float64(a * b)) + Float64(c * i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (((x * y) + (z * t)) + (a * b)) + (c * i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision] + N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(c * i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x \cdot y + z \cdot t\right) + a \cdot b\right) + c \cdot i
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 20 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i) :precision binary64 (+ (+ (+ (* x y) (* z t)) (* a b)) (* c i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((x * y) + (z * t)) + (a * b)) + (c * i);
}
real(8) function code(x, y, z, t, a, b, c, i)
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
code = (((x * y) + (z * t)) + (a * b)) + (c * i)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((x * y) + (z * t)) + (a * b)) + (c * i);
}
def code(x, y, z, t, a, b, c, i): return (((x * y) + (z * t)) + (a * b)) + (c * i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(Float64(x * y) + Float64(z * t)) + Float64(a * b)) + Float64(c * i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (((x * y) + (z * t)) + (a * b)) + (c * i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision] + N[(a * b), $MachinePrecision]), $MachinePrecision] + N[(c * i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x \cdot y + z \cdot t\right) + a \cdot b\right) + c \cdot i
\end{array}
(FPCore (x y z t a b c i) :precision binary64 (let* ((t_1 (+ (* c i) (+ (* a b) (+ (* x y) (* z t)))))) (if (<= t_1 INFINITY) t_1 (fma i c (* a b)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (c * i) + ((a * b) + ((x * y) + (z * t)));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = fma(i, c, (a * b));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(c * i) + Float64(Float64(a * b) + Float64(Float64(x * y) + Float64(z * t)))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = fma(i, c, Float64(a * b)); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(c * i), $MachinePrecision] + N[(N[(a * b), $MachinePrecision] + N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(i * c + N[(a * b), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := c \cdot i + \left(a \cdot b + \left(x \cdot y + z \cdot t\right)\right)\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(i, c, a \cdot b\right)\\
\end{array}
\end{array}
if (+.f64 (+.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 a b)) (*.f64 c i)) < +inf.0Initial program 100.0%
if +inf.0 < (+.f64 (+.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 a b)) (*.f64 c i)) Initial program 0.0%
Taylor expanded in x around 0 20.0%
Taylor expanded in t around 0 40.1%
+-commutative40.1%
*-commutative40.1%
fma-def70.1%
Applied egg-rr70.1%
Final simplification98.8%
(FPCore (x y z t a b c i) :precision binary64 (fma x y (fma z t (fma a b (* c i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return fma(x, y, fma(z, t, fma(a, b, (c * i))));
}
function code(x, y, z, t, a, b, c, i) return fma(x, y, fma(z, t, fma(a, b, Float64(c * i)))) end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(x * y + N[(z * t + N[(a * b + N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(x, y, \mathsf{fma}\left(z, t, \mathsf{fma}\left(a, b, c \cdot i\right)\right)\right)
\end{array}
Initial program 96.1%
associate-+l+96.1%
associate-+l+96.1%
fma-def96.9%
fma-def98.0%
fma-def98.4%
Simplified98.4%
Final simplification98.4%
(FPCore (x y z t a b c i) :precision binary64 (fma c i (fma x y (fma z t (* a b)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return fma(c, i, fma(x, y, fma(z, t, (a * b))));
}
function code(x, y, z, t, a, b, c, i) return fma(c, i, fma(x, y, fma(z, t, Float64(a * b)))) end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(c * i + N[(x * y + N[(z * t + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(c, i, \mathsf{fma}\left(x, y, \mathsf{fma}\left(z, t, a \cdot b\right)\right)\right)
\end{array}
Initial program 96.1%
+-commutative96.1%
fma-def97.3%
associate-+l+97.3%
fma-def97.6%
fma-def98.0%
Simplified98.0%
Final simplification98.0%
(FPCore (x y z t a b c i) :precision binary64 (fma c i (fma x y (+ (* a b) (* z t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return fma(c, i, fma(x, y, ((a * b) + (z * t))));
}
function code(x, y, z, t, a, b, c, i) return fma(c, i, fma(x, y, Float64(Float64(a * b) + Float64(z * t)))) end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(c * i + N[(x * y + N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(c, i, \mathsf{fma}\left(x, y, a \cdot b + z \cdot t\right)\right)
\end{array}
Initial program 96.1%
+-commutative96.1%
fma-def97.3%
associate-+l+97.3%
fma-def97.6%
fma-def98.0%
Simplified98.0%
fma-udef97.6%
Applied egg-rr97.6%
Final simplification97.6%
(FPCore (x y z t a b c i) :precision binary64 (let* ((t_1 (+ (* c i) (+ (* a b) (+ (* x y) (* z t)))))) (if (<= t_1 INFINITY) t_1 (fma a b (* z t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (c * i) + ((a * b) + ((x * y) + (z * t)));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = fma(a, b, (z * t));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(c * i) + Float64(Float64(a * b) + Float64(Float64(x * y) + Float64(z * t)))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = fma(a, b, Float64(z * t)); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(c * i), $MachinePrecision] + N[(N[(a * b), $MachinePrecision] + N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(a * b + N[(z * t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := c \cdot i + \left(a \cdot b + \left(x \cdot y + z \cdot t\right)\right)\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, b, z \cdot t\right)\\
\end{array}
\end{array}
if (+.f64 (+.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 a b)) (*.f64 c i)) < +inf.0Initial program 100.0%
if +inf.0 < (+.f64 (+.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 a b)) (*.f64 c i)) Initial program 0.0%
+-commutative0.0%
fma-def30.0%
associate-+l+30.0%
fma-def40.0%
fma-def50.0%
Simplified50.0%
fma-udef40.0%
Applied egg-rr40.0%
Taylor expanded in c around 0 30.0%
Taylor expanded in x around 0 41.6%
fma-def51.6%
Simplified51.6%
Final simplification98.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= (* x y) -5e+75)
(* x y)
(if (<= (* x y) -5.5e+41)
(* z t)
(if (<= (* x y) -8.5e+22)
(* a b)
(if (<= (* x y) -2.55e-14)
(* z t)
(if (<= (* x y) -2.5e-54)
(* c i)
(if (<= (* x y) 3.5e-225)
(* z t)
(if (<= (* x y) 7.2e-87)
(* a b)
(if (<= (* x y) 7e+164) (* c i) (* x y))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x * y) <= -5e+75) {
tmp = x * y;
} else if ((x * y) <= -5.5e+41) {
tmp = z * t;
} else if ((x * y) <= -8.5e+22) {
tmp = a * b;
} else if ((x * y) <= -2.55e-14) {
tmp = z * t;
} else if ((x * y) <= -2.5e-54) {
tmp = c * i;
} else if ((x * y) <= 3.5e-225) {
tmp = z * t;
} else if ((x * y) <= 7.2e-87) {
tmp = a * b;
} else if ((x * y) <= 7e+164) {
tmp = c * i;
} else {
tmp = x * y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: tmp
if ((x * y) <= (-5d+75)) then
tmp = x * y
else if ((x * y) <= (-5.5d+41)) then
tmp = z * t
else if ((x * y) <= (-8.5d+22)) then
tmp = a * b
else if ((x * y) <= (-2.55d-14)) then
tmp = z * t
else if ((x * y) <= (-2.5d-54)) then
tmp = c * i
else if ((x * y) <= 3.5d-225) then
tmp = z * t
else if ((x * y) <= 7.2d-87) then
tmp = a * b
else if ((x * y) <= 7d+164) then
tmp = c * i
else
tmp = x * y
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 tmp;
if ((x * y) <= -5e+75) {
tmp = x * y;
} else if ((x * y) <= -5.5e+41) {
tmp = z * t;
} else if ((x * y) <= -8.5e+22) {
tmp = a * b;
} else if ((x * y) <= -2.55e-14) {
tmp = z * t;
} else if ((x * y) <= -2.5e-54) {
tmp = c * i;
} else if ((x * y) <= 3.5e-225) {
tmp = z * t;
} else if ((x * y) <= 7.2e-87) {
tmp = a * b;
} else if ((x * y) <= 7e+164) {
tmp = c * i;
} else {
tmp = x * y;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (x * y) <= -5e+75: tmp = x * y elif (x * y) <= -5.5e+41: tmp = z * t elif (x * y) <= -8.5e+22: tmp = a * b elif (x * y) <= -2.55e-14: tmp = z * t elif (x * y) <= -2.5e-54: tmp = c * i elif (x * y) <= 3.5e-225: tmp = z * t elif (x * y) <= 7.2e-87: tmp = a * b elif (x * y) <= 7e+164: tmp = c * i else: tmp = x * y return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(x * y) <= -5e+75) tmp = Float64(x * y); elseif (Float64(x * y) <= -5.5e+41) tmp = Float64(z * t); elseif (Float64(x * y) <= -8.5e+22) tmp = Float64(a * b); elseif (Float64(x * y) <= -2.55e-14) tmp = Float64(z * t); elseif (Float64(x * y) <= -2.5e-54) tmp = Float64(c * i); elseif (Float64(x * y) <= 3.5e-225) tmp = Float64(z * t); elseif (Float64(x * y) <= 7.2e-87) tmp = Float64(a * b); elseif (Float64(x * y) <= 7e+164) tmp = Float64(c * i); else tmp = Float64(x * y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((x * y) <= -5e+75) tmp = x * y; elseif ((x * y) <= -5.5e+41) tmp = z * t; elseif ((x * y) <= -8.5e+22) tmp = a * b; elseif ((x * y) <= -2.55e-14) tmp = z * t; elseif ((x * y) <= -2.5e-54) tmp = c * i; elseif ((x * y) <= 3.5e-225) tmp = z * t; elseif ((x * y) <= 7.2e-87) tmp = a * b; elseif ((x * y) <= 7e+164) tmp = c * i; else tmp = x * y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(x * y), $MachinePrecision], -5e+75], N[(x * y), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -5.5e+41], N[(z * t), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -8.5e+22], N[(a * b), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -2.55e-14], N[(z * t), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -2.5e-54], N[(c * i), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], 3.5e-225], N[(z * t), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], 7.2e-87], N[(a * b), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], 7e+164], N[(c * i), $MachinePrecision], N[(x * y), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \cdot y \leq -5 \cdot 10^{+75}:\\
\;\;\;\;x \cdot y\\
\mathbf{elif}\;x \cdot y \leq -5.5 \cdot 10^{+41}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;x \cdot y \leq -8.5 \cdot 10^{+22}:\\
\;\;\;\;a \cdot b\\
\mathbf{elif}\;x \cdot y \leq -2.55 \cdot 10^{-14}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;x \cdot y \leq -2.5 \cdot 10^{-54}:\\
\;\;\;\;c \cdot i\\
\mathbf{elif}\;x \cdot y \leq 3.5 \cdot 10^{-225}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;x \cdot y \leq 7.2 \cdot 10^{-87}:\\
\;\;\;\;a \cdot b\\
\mathbf{elif}\;x \cdot y \leq 7 \cdot 10^{+164}:\\
\;\;\;\;c \cdot i\\
\mathbf{else}:\\
\;\;\;\;x \cdot y\\
\end{array}
\end{array}
if (*.f64 x y) < -5.0000000000000002e75 or 6.9999999999999995e164 < (*.f64 x y) Initial program 93.7%
Taylor expanded in x around inf 71.3%
if -5.0000000000000002e75 < (*.f64 x y) < -5.5000000000000003e41 or -8.49999999999999979e22 < (*.f64 x y) < -2.5499999999999999e-14 or -2.50000000000000008e-54 < (*.f64 x y) < 3.4999999999999997e-225Initial program 99.0%
Taylor expanded in z around inf 50.0%
if -5.5000000000000003e41 < (*.f64 x y) < -8.49999999999999979e22 or 3.4999999999999997e-225 < (*.f64 x y) < 7.19999999999999986e-87Initial program 95.6%
Taylor expanded in a around inf 68.5%
if -2.5499999999999999e-14 < (*.f64 x y) < -2.50000000000000008e-54 or 7.19999999999999986e-87 < (*.f64 x y) < 6.9999999999999995e164Initial program 94.4%
Taylor expanded in c around inf 49.7%
Final simplification58.3%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* a b) (* z t))) (t_2 (+ (* c i) (* a b))))
(if (<= (* x y) -4.8e+107)
(* x y)
(if (<= (* x y) -4.2e-13)
t_1
(if (<= (* x y) -2.4e-54)
t_2
(if (<= (* x y) 2e-235)
t_1
(if (<= (* x y) 7.2e+84)
t_2
(if (<= (* x y) 5.2e+111)
t_1
(if (<= (* x y) 5.5e+235) t_2 (* x y))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (a * b);
double tmp;
if ((x * y) <= -4.8e+107) {
tmp = x * y;
} else if ((x * y) <= -4.2e-13) {
tmp = t_1;
} else if ((x * y) <= -2.4e-54) {
tmp = t_2;
} else if ((x * y) <= 2e-235) {
tmp = t_1;
} else if ((x * y) <= 7.2e+84) {
tmp = t_2;
} else if ((x * y) <= 5.2e+111) {
tmp = t_1;
} else if ((x * y) <= 5.5e+235) {
tmp = t_2;
} else {
tmp = x * y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (a * b) + (z * t)
t_2 = (c * i) + (a * b)
if ((x * y) <= (-4.8d+107)) then
tmp = x * y
else if ((x * y) <= (-4.2d-13)) then
tmp = t_1
else if ((x * y) <= (-2.4d-54)) then
tmp = t_2
else if ((x * y) <= 2d-235) then
tmp = t_1
else if ((x * y) <= 7.2d+84) then
tmp = t_2
else if ((x * y) <= 5.2d+111) then
tmp = t_1
else if ((x * y) <= 5.5d+235) then
tmp = t_2
else
tmp = x * y
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 t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (a * b);
double tmp;
if ((x * y) <= -4.8e+107) {
tmp = x * y;
} else if ((x * y) <= -4.2e-13) {
tmp = t_1;
} else if ((x * y) <= -2.4e-54) {
tmp = t_2;
} else if ((x * y) <= 2e-235) {
tmp = t_1;
} else if ((x * y) <= 7.2e+84) {
tmp = t_2;
} else if ((x * y) <= 5.2e+111) {
tmp = t_1;
} else if ((x * y) <= 5.5e+235) {
tmp = t_2;
} else {
tmp = x * y;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (a * b) + (z * t) t_2 = (c * i) + (a * b) tmp = 0 if (x * y) <= -4.8e+107: tmp = x * y elif (x * y) <= -4.2e-13: tmp = t_1 elif (x * y) <= -2.4e-54: tmp = t_2 elif (x * y) <= 2e-235: tmp = t_1 elif (x * y) <= 7.2e+84: tmp = t_2 elif (x * y) <= 5.2e+111: tmp = t_1 elif (x * y) <= 5.5e+235: tmp = t_2 else: tmp = x * y return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(a * b) + Float64(z * t)) t_2 = Float64(Float64(c * i) + Float64(a * b)) tmp = 0.0 if (Float64(x * y) <= -4.8e+107) tmp = Float64(x * y); elseif (Float64(x * y) <= -4.2e-13) tmp = t_1; elseif (Float64(x * y) <= -2.4e-54) tmp = t_2; elseif (Float64(x * y) <= 2e-235) tmp = t_1; elseif (Float64(x * y) <= 7.2e+84) tmp = t_2; elseif (Float64(x * y) <= 5.2e+111) tmp = t_1; elseif (Float64(x * y) <= 5.5e+235) tmp = t_2; else tmp = Float64(x * y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (a * b) + (z * t); t_2 = (c * i) + (a * b); tmp = 0.0; if ((x * y) <= -4.8e+107) tmp = x * y; elseif ((x * y) <= -4.2e-13) tmp = t_1; elseif ((x * y) <= -2.4e-54) tmp = t_2; elseif ((x * y) <= 2e-235) tmp = t_1; elseif ((x * y) <= 7.2e+84) tmp = t_2; elseif ((x * y) <= 5.2e+111) tmp = t_1; elseif ((x * y) <= 5.5e+235) tmp = t_2; else tmp = x * y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * i), $MachinePrecision] + N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(x * y), $MachinePrecision], -4.8e+107], N[(x * y), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -4.2e-13], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], -2.4e-54], t$95$2, If[LessEqual[N[(x * y), $MachinePrecision], 2e-235], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], 7.2e+84], t$95$2, If[LessEqual[N[(x * y), $MachinePrecision], 5.2e+111], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], 5.5e+235], t$95$2, N[(x * y), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b + z \cdot t\\
t_2 := c \cdot i + a \cdot b\\
\mathbf{if}\;x \cdot y \leq -4.8 \cdot 10^{+107}:\\
\;\;\;\;x \cdot y\\
\mathbf{elif}\;x \cdot y \leq -4.2 \cdot 10^{-13}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq -2.4 \cdot 10^{-54}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \cdot y \leq 2 \cdot 10^{-235}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq 7.2 \cdot 10^{+84}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \cdot y \leq 5.2 \cdot 10^{+111}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq 5.5 \cdot 10^{+235}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;x \cdot y\\
\end{array}
\end{array}
if (*.f64 x y) < -4.8000000000000001e107 or 5.49999999999999945e235 < (*.f64 x y) Initial program 95.5%
Taylor expanded in x around inf 79.1%
if -4.8000000000000001e107 < (*.f64 x y) < -4.19999999999999977e-13 or -2.40000000000000013e-54 < (*.f64 x y) < 1.9999999999999999e-235 or 7.1999999999999999e84 < (*.f64 x y) < 5.1999999999999997e111Initial program 98.3%
+-commutative98.3%
fma-def99.2%
associate-+l+99.2%
fma-def99.2%
fma-def100.0%
Simplified100.0%
fma-udef99.2%
Applied egg-rr99.2%
Taylor expanded in c around 0 78.1%
Taylor expanded in x around 0 72.7%
if -4.19999999999999977e-13 < (*.f64 x y) < -2.40000000000000013e-54 or 1.9999999999999999e-235 < (*.f64 x y) < 7.1999999999999999e84 or 5.1999999999999997e111 < (*.f64 x y) < 5.49999999999999945e235Initial program 92.6%
Taylor expanded in x around 0 87.0%
Taylor expanded in t around 0 76.4%
Final simplification75.4%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* a b) (* z t))) (t_2 (+ (* c i) (* a b))))
(if (<= (* x y) -5e+75)
(+ (* a b) (* x y))
(if (<= (* x y) -4.6e-17)
t_1
(if (<= (* x y) -1.22e-54)
t_2
(if (<= (* x y) 1.05e-233)
t_1
(if (<= (* x y) 3.8e+84)
t_2
(if (<= (* x y) 6.6e+111)
t_1
(if (<= (* x y) 7.5e+234) t_2 (* x y))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (a * b);
double tmp;
if ((x * y) <= -5e+75) {
tmp = (a * b) + (x * y);
} else if ((x * y) <= -4.6e-17) {
tmp = t_1;
} else if ((x * y) <= -1.22e-54) {
tmp = t_2;
} else if ((x * y) <= 1.05e-233) {
tmp = t_1;
} else if ((x * y) <= 3.8e+84) {
tmp = t_2;
} else if ((x * y) <= 6.6e+111) {
tmp = t_1;
} else if ((x * y) <= 7.5e+234) {
tmp = t_2;
} else {
tmp = x * y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (a * b) + (z * t)
t_2 = (c * i) + (a * b)
if ((x * y) <= (-5d+75)) then
tmp = (a * b) + (x * y)
else if ((x * y) <= (-4.6d-17)) then
tmp = t_1
else if ((x * y) <= (-1.22d-54)) then
tmp = t_2
else if ((x * y) <= 1.05d-233) then
tmp = t_1
else if ((x * y) <= 3.8d+84) then
tmp = t_2
else if ((x * y) <= 6.6d+111) then
tmp = t_1
else if ((x * y) <= 7.5d+234) then
tmp = t_2
else
tmp = x * y
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 t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (a * b);
double tmp;
if ((x * y) <= -5e+75) {
tmp = (a * b) + (x * y);
} else if ((x * y) <= -4.6e-17) {
tmp = t_1;
} else if ((x * y) <= -1.22e-54) {
tmp = t_2;
} else if ((x * y) <= 1.05e-233) {
tmp = t_1;
} else if ((x * y) <= 3.8e+84) {
tmp = t_2;
} else if ((x * y) <= 6.6e+111) {
tmp = t_1;
} else if ((x * y) <= 7.5e+234) {
tmp = t_2;
} else {
tmp = x * y;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (a * b) + (z * t) t_2 = (c * i) + (a * b) tmp = 0 if (x * y) <= -5e+75: tmp = (a * b) + (x * y) elif (x * y) <= -4.6e-17: tmp = t_1 elif (x * y) <= -1.22e-54: tmp = t_2 elif (x * y) <= 1.05e-233: tmp = t_1 elif (x * y) <= 3.8e+84: tmp = t_2 elif (x * y) <= 6.6e+111: tmp = t_1 elif (x * y) <= 7.5e+234: tmp = t_2 else: tmp = x * y return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(a * b) + Float64(z * t)) t_2 = Float64(Float64(c * i) + Float64(a * b)) tmp = 0.0 if (Float64(x * y) <= -5e+75) tmp = Float64(Float64(a * b) + Float64(x * y)); elseif (Float64(x * y) <= -4.6e-17) tmp = t_1; elseif (Float64(x * y) <= -1.22e-54) tmp = t_2; elseif (Float64(x * y) <= 1.05e-233) tmp = t_1; elseif (Float64(x * y) <= 3.8e+84) tmp = t_2; elseif (Float64(x * y) <= 6.6e+111) tmp = t_1; elseif (Float64(x * y) <= 7.5e+234) tmp = t_2; else tmp = Float64(x * y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (a * b) + (z * t); t_2 = (c * i) + (a * b); tmp = 0.0; if ((x * y) <= -5e+75) tmp = (a * b) + (x * y); elseif ((x * y) <= -4.6e-17) tmp = t_1; elseif ((x * y) <= -1.22e-54) tmp = t_2; elseif ((x * y) <= 1.05e-233) tmp = t_1; elseif ((x * y) <= 3.8e+84) tmp = t_2; elseif ((x * y) <= 6.6e+111) tmp = t_1; elseif ((x * y) <= 7.5e+234) tmp = t_2; else tmp = x * y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * i), $MachinePrecision] + N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(x * y), $MachinePrecision], -5e+75], N[(N[(a * b), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -4.6e-17], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], -1.22e-54], t$95$2, If[LessEqual[N[(x * y), $MachinePrecision], 1.05e-233], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], 3.8e+84], t$95$2, If[LessEqual[N[(x * y), $MachinePrecision], 6.6e+111], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], 7.5e+234], t$95$2, N[(x * y), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b + z \cdot t\\
t_2 := c \cdot i + a \cdot b\\
\mathbf{if}\;x \cdot y \leq -5 \cdot 10^{+75}:\\
\;\;\;\;a \cdot b + x \cdot y\\
\mathbf{elif}\;x \cdot y \leq -4.6 \cdot 10^{-17}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq -1.22 \cdot 10^{-54}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \cdot y \leq 1.05 \cdot 10^{-233}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq 3.8 \cdot 10^{+84}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \cdot y \leq 6.6 \cdot 10^{+111}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq 7.5 \cdot 10^{+234}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;x \cdot y\\
\end{array}
\end{array}
if (*.f64 x y) < -5.0000000000000002e75Initial program 93.4%
+-commutative93.4%
fma-def93.4%
associate-+l+93.4%
fma-def95.6%
fma-def97.8%
Simplified97.8%
fma-udef95.6%
Applied egg-rr95.6%
Taylor expanded in c around 0 82.5%
Taylor expanded in t around 0 74.0%
if -5.0000000000000002e75 < (*.f64 x y) < -4.60000000000000018e-17 or -1.22e-54 < (*.f64 x y) < 1.0499999999999999e-233 or 3.8000000000000001e84 < (*.f64 x y) < 6.6000000000000002e111Initial program 99.1%
+-commutative99.1%
fma-def100.0%
associate-+l+100.0%
fma-def100.0%
fma-def100.0%
Simplified100.0%
fma-udef100.0%
Applied egg-rr100.0%
Taylor expanded in c around 0 78.7%
Taylor expanded in x around 0 74.1%
if -4.60000000000000018e-17 < (*.f64 x y) < -1.22e-54 or 1.0499999999999999e-233 < (*.f64 x y) < 3.8000000000000001e84 or 6.6000000000000002e111 < (*.f64 x y) < 7.5000000000000004e234Initial program 92.6%
Taylor expanded in x around 0 87.0%
Taylor expanded in t around 0 76.4%
if 7.5000000000000004e234 < (*.f64 x y) Initial program 96.4%
Taylor expanded in x around inf 84.8%
Final simplification75.9%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* a b) (* x y)))
(t_2 (+ (* c i) (* z t)))
(t_3 (+ (* a b) (* z t))))
(if (<= (* c i) -9e+82)
t_2
(if (<= (* c i) -8.5e-57)
t_1
(if (<= (* c i) -9e-180)
t_3
(if (<= (* c i) -5.2e-228)
t_1
(if (<= (* c i) 5.6e-159)
t_3
(if (<= (* c i) 0.066)
t_1
(if (<= (* c i) 1.2e+47) t_3 t_2)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (a * b) + (x * y);
double t_2 = (c * i) + (z * t);
double t_3 = (a * b) + (z * t);
double tmp;
if ((c * i) <= -9e+82) {
tmp = t_2;
} else if ((c * i) <= -8.5e-57) {
tmp = t_1;
} else if ((c * i) <= -9e-180) {
tmp = t_3;
} else if ((c * i) <= -5.2e-228) {
tmp = t_1;
} else if ((c * i) <= 5.6e-159) {
tmp = t_3;
} else if ((c * i) <= 0.066) {
tmp = t_1;
} else if ((c * i) <= 1.2e+47) {
tmp = t_3;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = (a * b) + (x * y)
t_2 = (c * i) + (z * t)
t_3 = (a * b) + (z * t)
if ((c * i) <= (-9d+82)) then
tmp = t_2
else if ((c * i) <= (-8.5d-57)) then
tmp = t_1
else if ((c * i) <= (-9d-180)) then
tmp = t_3
else if ((c * i) <= (-5.2d-228)) then
tmp = t_1
else if ((c * i) <= 5.6d-159) then
tmp = t_3
else if ((c * i) <= 0.066d0) then
tmp = t_1
else if ((c * i) <= 1.2d+47) then
tmp = t_3
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 t_1 = (a * b) + (x * y);
double t_2 = (c * i) + (z * t);
double t_3 = (a * b) + (z * t);
double tmp;
if ((c * i) <= -9e+82) {
tmp = t_2;
} else if ((c * i) <= -8.5e-57) {
tmp = t_1;
} else if ((c * i) <= -9e-180) {
tmp = t_3;
} else if ((c * i) <= -5.2e-228) {
tmp = t_1;
} else if ((c * i) <= 5.6e-159) {
tmp = t_3;
} else if ((c * i) <= 0.066) {
tmp = t_1;
} else if ((c * i) <= 1.2e+47) {
tmp = t_3;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (a * b) + (x * y) t_2 = (c * i) + (z * t) t_3 = (a * b) + (z * t) tmp = 0 if (c * i) <= -9e+82: tmp = t_2 elif (c * i) <= -8.5e-57: tmp = t_1 elif (c * i) <= -9e-180: tmp = t_3 elif (c * i) <= -5.2e-228: tmp = t_1 elif (c * i) <= 5.6e-159: tmp = t_3 elif (c * i) <= 0.066: tmp = t_1 elif (c * i) <= 1.2e+47: tmp = t_3 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(a * b) + Float64(x * y)) t_2 = Float64(Float64(c * i) + Float64(z * t)) t_3 = Float64(Float64(a * b) + Float64(z * t)) tmp = 0.0 if (Float64(c * i) <= -9e+82) tmp = t_2; elseif (Float64(c * i) <= -8.5e-57) tmp = t_1; elseif (Float64(c * i) <= -9e-180) tmp = t_3; elseif (Float64(c * i) <= -5.2e-228) tmp = t_1; elseif (Float64(c * i) <= 5.6e-159) tmp = t_3; elseif (Float64(c * i) <= 0.066) tmp = t_1; elseif (Float64(c * i) <= 1.2e+47) tmp = t_3; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (a * b) + (x * y); t_2 = (c * i) + (z * t); t_3 = (a * b) + (z * t); tmp = 0.0; if ((c * i) <= -9e+82) tmp = t_2; elseif ((c * i) <= -8.5e-57) tmp = t_1; elseif ((c * i) <= -9e-180) tmp = t_3; elseif ((c * i) <= -5.2e-228) tmp = t_1; elseif ((c * i) <= 5.6e-159) tmp = t_3; elseif ((c * i) <= 0.066) tmp = t_1; elseif ((c * i) <= 1.2e+47) tmp = t_3; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * i), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(c * i), $MachinePrecision], -9e+82], t$95$2, If[LessEqual[N[(c * i), $MachinePrecision], -8.5e-57], t$95$1, If[LessEqual[N[(c * i), $MachinePrecision], -9e-180], t$95$3, If[LessEqual[N[(c * i), $MachinePrecision], -5.2e-228], t$95$1, If[LessEqual[N[(c * i), $MachinePrecision], 5.6e-159], t$95$3, If[LessEqual[N[(c * i), $MachinePrecision], 0.066], t$95$1, If[LessEqual[N[(c * i), $MachinePrecision], 1.2e+47], t$95$3, t$95$2]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b + x \cdot y\\
t_2 := c \cdot i + z \cdot t\\
t_3 := a \cdot b + z \cdot t\\
\mathbf{if}\;c \cdot i \leq -9 \cdot 10^{+82}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;c \cdot i \leq -8.5 \cdot 10^{-57}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \cdot i \leq -9 \cdot 10^{-180}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;c \cdot i \leq -5.2 \cdot 10^{-228}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \cdot i \leq 5.6 \cdot 10^{-159}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;c \cdot i \leq 0.066:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \cdot i \leq 1.2 \cdot 10^{+47}:\\
\;\;\;\;t_3\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if (*.f64 c i) < -8.9999999999999993e82 or 1.20000000000000009e47 < (*.f64 c i) Initial program 91.9%
Taylor expanded in x around 0 79.7%
Taylor expanded in a around 0 77.8%
if -8.9999999999999993e82 < (*.f64 c i) < -8.49999999999999955e-57 or -9.00000000000000019e-180 < (*.f64 c i) < -5.2e-228 or 5.6000000000000004e-159 < (*.f64 c i) < 0.066000000000000003Initial program 100.0%
+-commutative100.0%
fma-def100.0%
associate-+l+100.0%
fma-def100.0%
fma-def100.0%
Simplified100.0%
fma-udef100.0%
Applied egg-rr100.0%
Taylor expanded in c around 0 94.2%
Taylor expanded in t around 0 78.2%
if -8.49999999999999955e-57 < (*.f64 c i) < -9.00000000000000019e-180 or -5.2e-228 < (*.f64 c i) < 5.6000000000000004e-159 or 0.066000000000000003 < (*.f64 c i) < 1.20000000000000009e47Initial program 98.0%
+-commutative98.0%
fma-def98.0%
associate-+l+98.0%
fma-def99.0%
fma-def100.0%
Simplified100.0%
fma-udef99.0%
Applied egg-rr99.0%
Taylor expanded in c around 0 96.1%
Taylor expanded in x around 0 75.7%
Final simplification77.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= (* c i) -2.1e+140)
(* c i)
(if (<= (* c i) -2.5e+99)
(* z t)
(if (<= (* c i) -1.7e+82)
(* c i)
(if (<= (* c i) -2.4e-69)
(* a b)
(if (<= (* c i) 1.4e-195)
(* z t)
(if (<= (* c i) 3.8e-20)
(* a b)
(if (<= (* c i) 3.1e+106) (* z t) (* c i)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((c * i) <= -2.1e+140) {
tmp = c * i;
} else if ((c * i) <= -2.5e+99) {
tmp = z * t;
} else if ((c * i) <= -1.7e+82) {
tmp = c * i;
} else if ((c * i) <= -2.4e-69) {
tmp = a * b;
} else if ((c * i) <= 1.4e-195) {
tmp = z * t;
} else if ((c * i) <= 3.8e-20) {
tmp = a * b;
} else if ((c * i) <= 3.1e+106) {
tmp = z * t;
} else {
tmp = c * i;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: tmp
if ((c * i) <= (-2.1d+140)) then
tmp = c * i
else if ((c * i) <= (-2.5d+99)) then
tmp = z * t
else if ((c * i) <= (-1.7d+82)) then
tmp = c * i
else if ((c * i) <= (-2.4d-69)) then
tmp = a * b
else if ((c * i) <= 1.4d-195) then
tmp = z * t
else if ((c * i) <= 3.8d-20) then
tmp = a * b
else if ((c * i) <= 3.1d+106) then
tmp = z * t
else
tmp = c * 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 tmp;
if ((c * i) <= -2.1e+140) {
tmp = c * i;
} else if ((c * i) <= -2.5e+99) {
tmp = z * t;
} else if ((c * i) <= -1.7e+82) {
tmp = c * i;
} else if ((c * i) <= -2.4e-69) {
tmp = a * b;
} else if ((c * i) <= 1.4e-195) {
tmp = z * t;
} else if ((c * i) <= 3.8e-20) {
tmp = a * b;
} else if ((c * i) <= 3.1e+106) {
tmp = z * t;
} else {
tmp = c * i;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (c * i) <= -2.1e+140: tmp = c * i elif (c * i) <= -2.5e+99: tmp = z * t elif (c * i) <= -1.7e+82: tmp = c * i elif (c * i) <= -2.4e-69: tmp = a * b elif (c * i) <= 1.4e-195: tmp = z * t elif (c * i) <= 3.8e-20: tmp = a * b elif (c * i) <= 3.1e+106: tmp = z * t else: tmp = c * i return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(c * i) <= -2.1e+140) tmp = Float64(c * i); elseif (Float64(c * i) <= -2.5e+99) tmp = Float64(z * t); elseif (Float64(c * i) <= -1.7e+82) tmp = Float64(c * i); elseif (Float64(c * i) <= -2.4e-69) tmp = Float64(a * b); elseif (Float64(c * i) <= 1.4e-195) tmp = Float64(z * t); elseif (Float64(c * i) <= 3.8e-20) tmp = Float64(a * b); elseif (Float64(c * i) <= 3.1e+106) tmp = Float64(z * t); else tmp = Float64(c * i); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((c * i) <= -2.1e+140) tmp = c * i; elseif ((c * i) <= -2.5e+99) tmp = z * t; elseif ((c * i) <= -1.7e+82) tmp = c * i; elseif ((c * i) <= -2.4e-69) tmp = a * b; elseif ((c * i) <= 1.4e-195) tmp = z * t; elseif ((c * i) <= 3.8e-20) tmp = a * b; elseif ((c * i) <= 3.1e+106) tmp = z * t; else tmp = c * i; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(c * i), $MachinePrecision], -2.1e+140], N[(c * i), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], -2.5e+99], N[(z * t), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], -1.7e+82], N[(c * i), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], -2.4e-69], N[(a * b), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], 1.4e-195], N[(z * t), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], 3.8e-20], N[(a * b), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], 3.1e+106], N[(z * t), $MachinePrecision], N[(c * i), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;c \cdot i \leq -2.1 \cdot 10^{+140}:\\
\;\;\;\;c \cdot i\\
\mathbf{elif}\;c \cdot i \leq -2.5 \cdot 10^{+99}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;c \cdot i \leq -1.7 \cdot 10^{+82}:\\
\;\;\;\;c \cdot i\\
\mathbf{elif}\;c \cdot i \leq -2.4 \cdot 10^{-69}:\\
\;\;\;\;a \cdot b\\
\mathbf{elif}\;c \cdot i \leq 1.4 \cdot 10^{-195}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;c \cdot i \leq 3.8 \cdot 10^{-20}:\\
\;\;\;\;a \cdot b\\
\mathbf{elif}\;c \cdot i \leq 3.1 \cdot 10^{+106}:\\
\;\;\;\;z \cdot t\\
\mathbf{else}:\\
\;\;\;\;c \cdot i\\
\end{array}
\end{array}
if (*.f64 c i) < -2.1000000000000002e140 or -2.50000000000000004e99 < (*.f64 c i) < -1.69999999999999997e82 or 3.0999999999999999e106 < (*.f64 c i) Initial program 90.2%
Taylor expanded in c around inf 70.4%
if -2.1000000000000002e140 < (*.f64 c i) < -2.50000000000000004e99 or -2.4000000000000001e-69 < (*.f64 c i) < 1.40000000000000002e-195 or 3.7999999999999998e-20 < (*.f64 c i) < 3.0999999999999999e106Initial program 98.3%
Taylor expanded in z around inf 47.0%
if -1.69999999999999997e82 < (*.f64 c i) < -2.4000000000000001e-69 or 1.40000000000000002e-195 < (*.f64 c i) < 3.7999999999999998e-20Initial program 100.0%
Taylor expanded in a around inf 43.2%
Final simplification53.7%
(FPCore (x y z t a b c i) :precision binary64 (let* ((t_1 (+ (* c i) (+ (* a b) (+ (* x y) (* z t)))))) (if (<= t_1 INFINITY) t_1 (+ (* a b) (* z t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (c * i) + ((a * b) + ((x * y) + (z * t)));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = (a * b) + (z * t);
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (c * i) + ((a * b) + ((x * y) + (z * t)));
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = (a * b) + (z * t);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (c * i) + ((a * b) + ((x * y) + (z * t))) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = (a * b) + (z * t) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(c * i) + Float64(Float64(a * b) + Float64(Float64(x * y) + Float64(z * t)))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(Float64(a * b) + Float64(z * t)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (c * i) + ((a * b) + ((x * y) + (z * t))); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = (a * b) + (z * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(c * i), $MachinePrecision] + N[(N[(a * b), $MachinePrecision] + N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := c \cdot i + \left(a \cdot b + \left(x \cdot y + z \cdot t\right)\right)\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot b + z \cdot t\\
\end{array}
\end{array}
if (+.f64 (+.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 a b)) (*.f64 c i)) < +inf.0Initial program 100.0%
if +inf.0 < (+.f64 (+.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 a b)) (*.f64 c i)) Initial program 0.0%
+-commutative0.0%
fma-def30.0%
associate-+l+30.0%
fma-def40.0%
fma-def50.0%
Simplified50.0%
fma-udef40.0%
Applied egg-rr40.0%
Taylor expanded in c around 0 30.0%
Taylor expanded in x around 0 41.6%
Final simplification97.7%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* c i) (* a b))))
(if (<= (* x y) -5.3e+75)
(* x y)
(if (<= (* x y) -6.8e+41)
(* z t)
(if (<= (* x y) -3.4e-115)
t_1
(if (<= (* x y) -7.7e-274)
(* z t)
(if (<= (* x y) 1.7e+238) t_1 (* x y))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (c * i) + (a * b);
double tmp;
if ((x * y) <= -5.3e+75) {
tmp = x * y;
} else if ((x * y) <= -6.8e+41) {
tmp = z * t;
} else if ((x * y) <= -3.4e-115) {
tmp = t_1;
} else if ((x * y) <= -7.7e-274) {
tmp = z * t;
} else if ((x * y) <= 1.7e+238) {
tmp = t_1;
} else {
tmp = x * y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: tmp
t_1 = (c * i) + (a * b)
if ((x * y) <= (-5.3d+75)) then
tmp = x * y
else if ((x * y) <= (-6.8d+41)) then
tmp = z * t
else if ((x * y) <= (-3.4d-115)) then
tmp = t_1
else if ((x * y) <= (-7.7d-274)) then
tmp = z * t
else if ((x * y) <= 1.7d+238) then
tmp = t_1
else
tmp = x * y
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 t_1 = (c * i) + (a * b);
double tmp;
if ((x * y) <= -5.3e+75) {
tmp = x * y;
} else if ((x * y) <= -6.8e+41) {
tmp = z * t;
} else if ((x * y) <= -3.4e-115) {
tmp = t_1;
} else if ((x * y) <= -7.7e-274) {
tmp = z * t;
} else if ((x * y) <= 1.7e+238) {
tmp = t_1;
} else {
tmp = x * y;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (c * i) + (a * b) tmp = 0 if (x * y) <= -5.3e+75: tmp = x * y elif (x * y) <= -6.8e+41: tmp = z * t elif (x * y) <= -3.4e-115: tmp = t_1 elif (x * y) <= -7.7e-274: tmp = z * t elif (x * y) <= 1.7e+238: tmp = t_1 else: tmp = x * y return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(c * i) + Float64(a * b)) tmp = 0.0 if (Float64(x * y) <= -5.3e+75) tmp = Float64(x * y); elseif (Float64(x * y) <= -6.8e+41) tmp = Float64(z * t); elseif (Float64(x * y) <= -3.4e-115) tmp = t_1; elseif (Float64(x * y) <= -7.7e-274) tmp = Float64(z * t); elseif (Float64(x * y) <= 1.7e+238) tmp = t_1; else tmp = Float64(x * y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (c * i) + (a * b); tmp = 0.0; if ((x * y) <= -5.3e+75) tmp = x * y; elseif ((x * y) <= -6.8e+41) tmp = z * t; elseif ((x * y) <= -3.4e-115) tmp = t_1; elseif ((x * y) <= -7.7e-274) tmp = z * t; elseif ((x * y) <= 1.7e+238) tmp = t_1; else tmp = x * y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(c * i), $MachinePrecision] + N[(a * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(x * y), $MachinePrecision], -5.3e+75], N[(x * y), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -6.8e+41], N[(z * t), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], -3.4e-115], t$95$1, If[LessEqual[N[(x * y), $MachinePrecision], -7.7e-274], N[(z * t), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], 1.7e+238], t$95$1, N[(x * y), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := c \cdot i + a \cdot b\\
\mathbf{if}\;x \cdot y \leq -5.3 \cdot 10^{+75}:\\
\;\;\;\;x \cdot y\\
\mathbf{elif}\;x \cdot y \leq -6.8 \cdot 10^{+41}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;x \cdot y \leq -3.4 \cdot 10^{-115}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \cdot y \leq -7.7 \cdot 10^{-274}:\\
\;\;\;\;z \cdot t\\
\mathbf{elif}\;x \cdot y \leq 1.7 \cdot 10^{+238}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot y\\
\end{array}
\end{array}
if (*.f64 x y) < -5.2999999999999998e75 or 1.6999999999999999e238 < (*.f64 x y) Initial program 94.5%
Taylor expanded in x around inf 74.3%
if -5.2999999999999998e75 < (*.f64 x y) < -6.79999999999999996e41 or -3.3999999999999998e-115 < (*.f64 x y) < -7.6999999999999997e-274Initial program 100.0%
Taylor expanded in z around inf 70.9%
if -6.79999999999999996e41 < (*.f64 x y) < -3.3999999999999998e-115 or -7.6999999999999997e-274 < (*.f64 x y) < 1.6999999999999999e238Initial program 95.9%
Taylor expanded in x around 0 90.0%
Taylor expanded in t around 0 65.5%
Final simplification68.8%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* a b) (* z t)))
(t_2 (+ (* c i) (* x y)))
(t_3 (+ (* a b) (* x y))))
(if (<= c -5.5e+71)
t_2
(if (<= c -1.75e-140)
t_1
(if (<= c -1.72e-186)
t_3
(if (<= c -9e-246)
t_1
(if (<= c -1.1e-302) t_3 (if (<= c 5.2e-114) t_1 t_2))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (x * y);
double t_3 = (a * b) + (x * y);
double tmp;
if (c <= -5.5e+71) {
tmp = t_2;
} else if (c <= -1.75e-140) {
tmp = t_1;
} else if (c <= -1.72e-186) {
tmp = t_3;
} else if (c <= -9e-246) {
tmp = t_1;
} else if (c <= -1.1e-302) {
tmp = t_3;
} else if (c <= 5.2e-114) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = (a * b) + (z * t)
t_2 = (c * i) + (x * y)
t_3 = (a * b) + (x * y)
if (c <= (-5.5d+71)) then
tmp = t_2
else if (c <= (-1.75d-140)) then
tmp = t_1
else if (c <= (-1.72d-186)) then
tmp = t_3
else if (c <= (-9d-246)) then
tmp = t_1
else if (c <= (-1.1d-302)) then
tmp = t_3
else if (c <= 5.2d-114) 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 t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (x * y);
double t_3 = (a * b) + (x * y);
double tmp;
if (c <= -5.5e+71) {
tmp = t_2;
} else if (c <= -1.75e-140) {
tmp = t_1;
} else if (c <= -1.72e-186) {
tmp = t_3;
} else if (c <= -9e-246) {
tmp = t_1;
} else if (c <= -1.1e-302) {
tmp = t_3;
} else if (c <= 5.2e-114) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (a * b) + (z * t) t_2 = (c * i) + (x * y) t_3 = (a * b) + (x * y) tmp = 0 if c <= -5.5e+71: tmp = t_2 elif c <= -1.75e-140: tmp = t_1 elif c <= -1.72e-186: tmp = t_3 elif c <= -9e-246: tmp = t_1 elif c <= -1.1e-302: tmp = t_3 elif c <= 5.2e-114: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(a * b) + Float64(z * t)) t_2 = Float64(Float64(c * i) + Float64(x * y)) t_3 = Float64(Float64(a * b) + Float64(x * y)) tmp = 0.0 if (c <= -5.5e+71) tmp = t_2; elseif (c <= -1.75e-140) tmp = t_1; elseif (c <= -1.72e-186) tmp = t_3; elseif (c <= -9e-246) tmp = t_1; elseif (c <= -1.1e-302) tmp = t_3; elseif (c <= 5.2e-114) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (a * b) + (z * t); t_2 = (c * i) + (x * y); t_3 = (a * b) + (x * y); tmp = 0.0; if (c <= -5.5e+71) tmp = t_2; elseif (c <= -1.75e-140) tmp = t_1; elseif (c <= -1.72e-186) tmp = t_3; elseif (c <= -9e-246) tmp = t_1; elseif (c <= -1.1e-302) tmp = t_3; elseif (c <= 5.2e-114) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * i), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(a * b), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[c, -5.5e+71], t$95$2, If[LessEqual[c, -1.75e-140], t$95$1, If[LessEqual[c, -1.72e-186], t$95$3, If[LessEqual[c, -9e-246], t$95$1, If[LessEqual[c, -1.1e-302], t$95$3, If[LessEqual[c, 5.2e-114], t$95$1, t$95$2]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b + z \cdot t\\
t_2 := c \cdot i + x \cdot y\\
t_3 := a \cdot b + x \cdot y\\
\mathbf{if}\;c \leq -5.5 \cdot 10^{+71}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;c \leq -1.75 \cdot 10^{-140}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \leq -1.72 \cdot 10^{-186}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;c \leq -9 \cdot 10^{-246}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \leq -1.1 \cdot 10^{-302}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;c \leq 5.2 \cdot 10^{-114}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if c < -5.5e71 or 5.20000000000000026e-114 < c Initial program 93.9%
Taylor expanded in a around 0 81.1%
Taylor expanded in t around 0 63.2%
if -5.5e71 < c < -1.7499999999999999e-140 or -1.72e-186 < c < -8.99999999999999998e-246 or -1.10000000000000004e-302 < c < 5.20000000000000026e-114Initial program 99.0%
+-commutative99.0%
fma-def99.0%
associate-+l+99.0%
fma-def99.0%
fma-def100.0%
Simplified100.0%
fma-udef99.0%
Applied egg-rr99.0%
Taylor expanded in c around 0 88.9%
Taylor expanded in x around 0 66.4%
if -1.7499999999999999e-140 < c < -1.72e-186 or -8.99999999999999998e-246 < c < -1.10000000000000004e-302Initial program 95.0%
+-commutative95.0%
fma-def95.0%
associate-+l+95.0%
fma-def100.0%
fma-def100.0%
Simplified100.0%
fma-udef100.0%
Applied egg-rr100.0%
Taylor expanded in c around 0 95.0%
Taylor expanded in t around 0 70.7%
Final simplification65.1%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* a b) (* z t))) (t_2 (+ (* c i) (* x y))))
(if (<= c -2.7e+72)
t_2
(if (<= c -1.6e-140)
t_1
(if (<= c -2.55e-186)
(+ (* a b) (* x y))
(if (<= c -5.5e-227)
t_1
(if (<= c -5.4e-304)
(+ (* x y) (* z t))
(if (<= c 6.1e-114) t_1 t_2))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (x * y);
double tmp;
if (c <= -2.7e+72) {
tmp = t_2;
} else if (c <= -1.6e-140) {
tmp = t_1;
} else if (c <= -2.55e-186) {
tmp = (a * b) + (x * y);
} else if (c <= -5.5e-227) {
tmp = t_1;
} else if (c <= -5.4e-304) {
tmp = (x * y) + (z * t);
} else if (c <= 6.1e-114) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (a * b) + (z * t)
t_2 = (c * i) + (x * y)
if (c <= (-2.7d+72)) then
tmp = t_2
else if (c <= (-1.6d-140)) then
tmp = t_1
else if (c <= (-2.55d-186)) then
tmp = (a * b) + (x * y)
else if (c <= (-5.5d-227)) then
tmp = t_1
else if (c <= (-5.4d-304)) then
tmp = (x * y) + (z * t)
else if (c <= 6.1d-114) 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 t_1 = (a * b) + (z * t);
double t_2 = (c * i) + (x * y);
double tmp;
if (c <= -2.7e+72) {
tmp = t_2;
} else if (c <= -1.6e-140) {
tmp = t_1;
} else if (c <= -2.55e-186) {
tmp = (a * b) + (x * y);
} else if (c <= -5.5e-227) {
tmp = t_1;
} else if (c <= -5.4e-304) {
tmp = (x * y) + (z * t);
} else if (c <= 6.1e-114) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (a * b) + (z * t) t_2 = (c * i) + (x * y) tmp = 0 if c <= -2.7e+72: tmp = t_2 elif c <= -1.6e-140: tmp = t_1 elif c <= -2.55e-186: tmp = (a * b) + (x * y) elif c <= -5.5e-227: tmp = t_1 elif c <= -5.4e-304: tmp = (x * y) + (z * t) elif c <= 6.1e-114: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(a * b) + Float64(z * t)) t_2 = Float64(Float64(c * i) + Float64(x * y)) tmp = 0.0 if (c <= -2.7e+72) tmp = t_2; elseif (c <= -1.6e-140) tmp = t_1; elseif (c <= -2.55e-186) tmp = Float64(Float64(a * b) + Float64(x * y)); elseif (c <= -5.5e-227) tmp = t_1; elseif (c <= -5.4e-304) tmp = Float64(Float64(x * y) + Float64(z * t)); elseif (c <= 6.1e-114) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (a * b) + (z * t); t_2 = (c * i) + (x * y); tmp = 0.0; if (c <= -2.7e+72) tmp = t_2; elseif (c <= -1.6e-140) tmp = t_1; elseif (c <= -2.55e-186) tmp = (a * b) + (x * y); elseif (c <= -5.5e-227) tmp = t_1; elseif (c <= -5.4e-304) tmp = (x * y) + (z * t); elseif (c <= 6.1e-114) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * i), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[c, -2.7e+72], t$95$2, If[LessEqual[c, -1.6e-140], t$95$1, If[LessEqual[c, -2.55e-186], N[(N[(a * b), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, -5.5e-227], t$95$1, If[LessEqual[c, -5.4e-304], N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 6.1e-114], t$95$1, t$95$2]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b + z \cdot t\\
t_2 := c \cdot i + x \cdot y\\
\mathbf{if}\;c \leq -2.7 \cdot 10^{+72}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;c \leq -1.6 \cdot 10^{-140}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \leq -2.55 \cdot 10^{-186}:\\
\;\;\;\;a \cdot b + x \cdot y\\
\mathbf{elif}\;c \leq -5.5 \cdot 10^{-227}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;c \leq -5.4 \cdot 10^{-304}:\\
\;\;\;\;x \cdot y + z \cdot t\\
\mathbf{elif}\;c \leq 6.1 \cdot 10^{-114}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if c < -2.7000000000000001e72 or 6.09999999999999977e-114 < c Initial program 93.9%
Taylor expanded in a around 0 81.1%
Taylor expanded in t around 0 63.2%
if -2.7000000000000001e72 < c < -1.6000000000000001e-140 or -2.5500000000000002e-186 < c < -5.5e-227 or -5.40000000000000021e-304 < c < 6.09999999999999977e-114Initial program 99.0%
+-commutative99.0%
fma-def99.0%
associate-+l+99.0%
fma-def99.0%
fma-def100.0%
Simplified100.0%
fma-udef99.0%
Applied egg-rr99.0%
Taylor expanded in c around 0 88.6%
Taylor expanded in x around 0 65.4%
if -1.6000000000000001e-140 < c < -2.5500000000000002e-186Initial program 91.7%
+-commutative91.7%
fma-def91.7%
associate-+l+91.7%
fma-def100.0%
fma-def100.0%
Simplified100.0%
fma-udef100.0%
Applied egg-rr100.0%
Taylor expanded in c around 0 91.7%
Taylor expanded in t around 0 67.6%
if -5.5e-227 < c < -5.40000000000000021e-304Initial program 100.0%
Taylor expanded in a around 0 82.3%
Taylor expanded in c around 0 82.3%
Final simplification65.1%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* x y) (* z t))))
(if (or (<= (* c i) -5.7e+76) (not (<= (* c i) 5e-20)))
(+ (* c i) t_1)
(+ (* a b) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (x * y) + (z * t);
double tmp;
if (((c * i) <= -5.7e+76) || !((c * i) <= 5e-20)) {
tmp = (c * i) + t_1;
} else {
tmp = (a * b) + t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: t_1
real(8) :: tmp
t_1 = (x * y) + (z * t)
if (((c * i) <= (-5.7d+76)) .or. (.not. ((c * i) <= 5d-20))) then
tmp = (c * i) + t_1
else
tmp = (a * b) + t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (x * y) + (z * t);
double tmp;
if (((c * i) <= -5.7e+76) || !((c * i) <= 5e-20)) {
tmp = (c * i) + t_1;
} else {
tmp = (a * b) + t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (x * y) + (z * t) tmp = 0 if ((c * i) <= -5.7e+76) or not ((c * i) <= 5e-20): tmp = (c * i) + t_1 else: tmp = (a * b) + t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(x * y) + Float64(z * t)) tmp = 0.0 if ((Float64(c * i) <= -5.7e+76) || !(Float64(c * i) <= 5e-20)) tmp = Float64(Float64(c * i) + t_1); else tmp = Float64(Float64(a * b) + t_1); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (x * y) + (z * t); tmp = 0.0; if (((c * i) <= -5.7e+76) || ~(((c * i) <= 5e-20))) tmp = (c * i) + t_1; else tmp = (a * b) + t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[N[(c * i), $MachinePrecision], -5.7e+76], N[Not[LessEqual[N[(c * i), $MachinePrecision], 5e-20]], $MachinePrecision]], N[(N[(c * i), $MachinePrecision] + t$95$1), $MachinePrecision], N[(N[(a * b), $MachinePrecision] + t$95$1), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot y + z \cdot t\\
\mathbf{if}\;c \cdot i \leq -5.7 \cdot 10^{+76} \lor \neg \left(c \cdot i \leq 5 \cdot 10^{-20}\right):\\
\;\;\;\;c \cdot i + t_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot b + t_1\\
\end{array}
\end{array}
if (*.f64 c i) < -5.70000000000000004e76 or 4.9999999999999999e-20 < (*.f64 c i) Initial program 92.8%
Taylor expanded in a around 0 91.2%
if -5.70000000000000004e76 < (*.f64 c i) < 4.9999999999999999e-20Initial program 98.6%
+-commutative98.6%
fma-def98.6%
associate-+l+98.6%
fma-def99.3%
fma-def100.0%
Simplified100.0%
fma-udef99.3%
Applied egg-rr99.3%
Taylor expanded in c around 0 95.3%
Final simplification93.5%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= (* c i) -2.7e+147)
(+ (* c i) (* x y))
(if (<= (* c i) 6.5e+125)
(+ (* a b) (+ (* x y) (* z t)))
(+ (* c i) (* z t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((c * i) <= -2.7e+147) {
tmp = (c * i) + (x * y);
} else if ((c * i) <= 6.5e+125) {
tmp = (a * b) + ((x * y) + (z * t));
} else {
tmp = (c * i) + (z * t);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: tmp
if ((c * i) <= (-2.7d+147)) then
tmp = (c * i) + (x * y)
else if ((c * i) <= 6.5d+125) then
tmp = (a * b) + ((x * y) + (z * t))
else
tmp = (c * i) + (z * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((c * i) <= -2.7e+147) {
tmp = (c * i) + (x * y);
} else if ((c * i) <= 6.5e+125) {
tmp = (a * b) + ((x * y) + (z * t));
} else {
tmp = (c * i) + (z * t);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (c * i) <= -2.7e+147: tmp = (c * i) + (x * y) elif (c * i) <= 6.5e+125: tmp = (a * b) + ((x * y) + (z * t)) else: tmp = (c * i) + (z * t) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(c * i) <= -2.7e+147) tmp = Float64(Float64(c * i) + Float64(x * y)); elseif (Float64(c * i) <= 6.5e+125) tmp = Float64(Float64(a * b) + Float64(Float64(x * y) + Float64(z * t))); else tmp = Float64(Float64(c * i) + Float64(z * t)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((c * i) <= -2.7e+147) tmp = (c * i) + (x * y); elseif ((c * i) <= 6.5e+125) tmp = (a * b) + ((x * y) + (z * t)); else tmp = (c * i) + (z * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(c * i), $MachinePrecision], -2.7e+147], N[(N[(c * i), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], 6.5e+125], N[(N[(a * b), $MachinePrecision] + N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(c * i), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;c \cdot i \leq -2.7 \cdot 10^{+147}:\\
\;\;\;\;c \cdot i + x \cdot y\\
\mathbf{elif}\;c \cdot i \leq 6.5 \cdot 10^{+125}:\\
\;\;\;\;a \cdot b + \left(x \cdot y + z \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot i + z \cdot t\\
\end{array}
\end{array}
if (*.f64 c i) < -2.69999999999999998e147Initial program 84.9%
Taylor expanded in a around 0 87.4%
Taylor expanded in t around 0 83.7%
if -2.69999999999999998e147 < (*.f64 c i) < 6.4999999999999999e125Initial program 98.9%
+-commutative98.9%
fma-def98.9%
associate-+l+98.9%
fma-def99.4%
fma-def100.0%
Simplified100.0%
fma-udef99.4%
Applied egg-rr99.4%
Taylor expanded in c around 0 92.8%
if 6.4999999999999999e125 < (*.f64 c i) Initial program 94.2%
Taylor expanded in x around 0 83.8%
Taylor expanded in a around 0 81.5%
Final simplification89.9%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= (* x y) -6.5e-9)
(+ (* a b) (+ (* x y) (* z t)))
(if (<= (* x y) 9e+186)
(+ (* c i) (+ (* a b) (* z t)))
(+ (* c i) (* x y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x * y) <= -6.5e-9) {
tmp = (a * b) + ((x * y) + (z * t));
} else if ((x * y) <= 9e+186) {
tmp = (c * i) + ((a * b) + (z * t));
} else {
tmp = (c * i) + (x * y);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: tmp
if ((x * y) <= (-6.5d-9)) then
tmp = (a * b) + ((x * y) + (z * t))
else if ((x * y) <= 9d+186) then
tmp = (c * i) + ((a * b) + (z * t))
else
tmp = (c * i) + (x * y)
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 tmp;
if ((x * y) <= -6.5e-9) {
tmp = (a * b) + ((x * y) + (z * t));
} else if ((x * y) <= 9e+186) {
tmp = (c * i) + ((a * b) + (z * t));
} else {
tmp = (c * i) + (x * y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (x * y) <= -6.5e-9: tmp = (a * b) + ((x * y) + (z * t)) elif (x * y) <= 9e+186: tmp = (c * i) + ((a * b) + (z * t)) else: tmp = (c * i) + (x * y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(x * y) <= -6.5e-9) tmp = Float64(Float64(a * b) + Float64(Float64(x * y) + Float64(z * t))); elseif (Float64(x * y) <= 9e+186) tmp = Float64(Float64(c * i) + Float64(Float64(a * b) + Float64(z * t))); else tmp = Float64(Float64(c * i) + Float64(x * y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((x * y) <= -6.5e-9) tmp = (a * b) + ((x * y) + (z * t)); elseif ((x * y) <= 9e+186) tmp = (c * i) + ((a * b) + (z * t)); else tmp = (c * i) + (x * y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(x * y), $MachinePrecision], -6.5e-9], N[(N[(a * b), $MachinePrecision] + N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], 9e+186], N[(N[(c * i), $MachinePrecision] + N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(c * i), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \cdot y \leq -6.5 \cdot 10^{-9}:\\
\;\;\;\;a \cdot b + \left(x \cdot y + z \cdot t\right)\\
\mathbf{elif}\;x \cdot y \leq 9 \cdot 10^{+186}:\\
\;\;\;\;c \cdot i + \left(a \cdot b + z \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot i + x \cdot y\\
\end{array}
\end{array}
if (*.f64 x y) < -6.5000000000000003e-9Initial program 95.5%
+-commutative95.5%
fma-def95.5%
associate-+l+95.5%
fma-def97.0%
fma-def98.5%
Simplified98.5%
fma-udef97.0%
Applied egg-rr97.0%
Taylor expanded in c around 0 86.5%
if -6.5000000000000003e-9 < (*.f64 x y) < 9.0000000000000009e186Initial program 96.8%
Taylor expanded in x around 0 93.7%
if 9.0000000000000009e186 < (*.f64 x y) Initial program 93.9%
Taylor expanded in a around 0 91.1%
Taylor expanded in t around 0 89.9%
Final simplification91.3%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= (* x y) -6.5e-9)
(+ (* a b) (+ (* x y) (* z t)))
(if (<= (* x y) 3.1e+166)
(+ (* c i) (+ (* a b) (* z t)))
(+ (* c i) (+ (* a b) (* x y))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x * y) <= -6.5e-9) {
tmp = (a * b) + ((x * y) + (z * t));
} else if ((x * y) <= 3.1e+166) {
tmp = (c * i) + ((a * b) + (z * t));
} else {
tmp = (c * i) + ((a * b) + (x * y));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: tmp
if ((x * y) <= (-6.5d-9)) then
tmp = (a * b) + ((x * y) + (z * t))
else if ((x * y) <= 3.1d+166) then
tmp = (c * i) + ((a * b) + (z * t))
else
tmp = (c * i) + ((a * b) + (x * y))
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 tmp;
if ((x * y) <= -6.5e-9) {
tmp = (a * b) + ((x * y) + (z * t));
} else if ((x * y) <= 3.1e+166) {
tmp = (c * i) + ((a * b) + (z * t));
} else {
tmp = (c * i) + ((a * b) + (x * y));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (x * y) <= -6.5e-9: tmp = (a * b) + ((x * y) + (z * t)) elif (x * y) <= 3.1e+166: tmp = (c * i) + ((a * b) + (z * t)) else: tmp = (c * i) + ((a * b) + (x * y)) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(x * y) <= -6.5e-9) tmp = Float64(Float64(a * b) + Float64(Float64(x * y) + Float64(z * t))); elseif (Float64(x * y) <= 3.1e+166) tmp = Float64(Float64(c * i) + Float64(Float64(a * b) + Float64(z * t))); else tmp = Float64(Float64(c * i) + Float64(Float64(a * b) + Float64(x * y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((x * y) <= -6.5e-9) tmp = (a * b) + ((x * y) + (z * t)); elseif ((x * y) <= 3.1e+166) tmp = (c * i) + ((a * b) + (z * t)); else tmp = (c * i) + ((a * b) + (x * y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(x * y), $MachinePrecision], -6.5e-9], N[(N[(a * b), $MachinePrecision] + N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(x * y), $MachinePrecision], 3.1e+166], N[(N[(c * i), $MachinePrecision] + N[(N[(a * b), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(c * i), $MachinePrecision] + N[(N[(a * b), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \cdot y \leq -6.5 \cdot 10^{-9}:\\
\;\;\;\;a \cdot b + \left(x \cdot y + z \cdot t\right)\\
\mathbf{elif}\;x \cdot y \leq 3.1 \cdot 10^{+166}:\\
\;\;\;\;c \cdot i + \left(a \cdot b + z \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot i + \left(a \cdot b + x \cdot y\right)\\
\end{array}
\end{array}
if (*.f64 x y) < -6.5000000000000003e-9Initial program 95.5%
+-commutative95.5%
fma-def95.5%
associate-+l+95.5%
fma-def97.0%
fma-def98.5%
Simplified98.5%
fma-udef97.0%
Applied egg-rr97.0%
Taylor expanded in c around 0 86.5%
if -6.5000000000000003e-9 < (*.f64 x y) < 3.09999999999999983e166Initial program 96.8%
Taylor expanded in x around 0 93.7%
if 3.09999999999999983e166 < (*.f64 x y) Initial program 93.9%
Taylor expanded in z around 0 92.7%
Final simplification91.7%
(FPCore (x y z t a b c i) :precision binary64 (if (<= (* c i) -1.4e+82) (* c i) (if (<= (* c i) 2.8e+45) (* a b) (* c i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((c * i) <= -1.4e+82) {
tmp = c * i;
} else if ((c * i) <= 2.8e+45) {
tmp = a * b;
} else {
tmp = c * i;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
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) :: tmp
if ((c * i) <= (-1.4d+82)) then
tmp = c * i
else if ((c * i) <= 2.8d+45) then
tmp = a * b
else
tmp = c * 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 tmp;
if ((c * i) <= -1.4e+82) {
tmp = c * i;
} else if ((c * i) <= 2.8e+45) {
tmp = a * b;
} else {
tmp = c * i;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (c * i) <= -1.4e+82: tmp = c * i elif (c * i) <= 2.8e+45: tmp = a * b else: tmp = c * i return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(c * i) <= -1.4e+82) tmp = Float64(c * i); elseif (Float64(c * i) <= 2.8e+45) tmp = Float64(a * b); else tmp = Float64(c * i); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((c * i) <= -1.4e+82) tmp = c * i; elseif ((c * i) <= 2.8e+45) tmp = a * b; else tmp = c * i; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(c * i), $MachinePrecision], -1.4e+82], N[(c * i), $MachinePrecision], If[LessEqual[N[(c * i), $MachinePrecision], 2.8e+45], N[(a * b), $MachinePrecision], N[(c * i), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;c \cdot i \leq -1.4 \cdot 10^{+82}:\\
\;\;\;\;c \cdot i\\
\mathbf{elif}\;c \cdot i \leq 2.8 \cdot 10^{+45}:\\
\;\;\;\;a \cdot b\\
\mathbf{else}:\\
\;\;\;\;c \cdot i\\
\end{array}
\end{array}
if (*.f64 c i) < -1.4e82 or 2.7999999999999999e45 < (*.f64 c i) Initial program 91.9%
Taylor expanded in c around inf 61.1%
if -1.4e82 < (*.f64 c i) < 2.7999999999999999e45Initial program 98.7%
Taylor expanded in a around inf 34.7%
Final simplification45.0%
(FPCore (x y z t a b c i) :precision binary64 (* a b))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return a * b;
}
real(8) function code(x, y, z, t, a, b, c, i)
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
code = a * b
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return a * b;
}
def code(x, y, z, t, a, b, c, i): return a * b
function code(x, y, z, t, a, b, c, i) return Float64(a * b) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = a * b; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(a * b), $MachinePrecision]
\begin{array}{l}
\\
a \cdot b
\end{array}
Initial program 96.1%
Taylor expanded in a around inf 24.4%
Final simplification24.4%
herbie shell --seed 2023279
(FPCore (x y z t a b c i)
:name "Linear.V4:$cdot from linear-1.19.1.3, C"
:precision binary64
(+ (+ (+ (* x y) (* z t)) (* a b)) (* c i)))