Math FPCore C Julia Wolfram TeX \[\left(x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\right) + \left(a \cdot 27\right) \cdot b
\]
↓
\[\begin{array}{l}
t_1 := x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\\
\mathbf{if}\;t \leq -1 \cdot 10^{+217}:\\
\;\;\;\;t_1 + \left(a \cdot 27\right) \cdot b\\
\mathbf{elif}\;t \leq 4.8 \cdot 10^{+124}:\\
\;\;\;\;\mathsf{fma}\left(27, b \cdot a, \mathsf{fma}\left(x, 2, -9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_1 + \left(27 \cdot b\right) \cdot a\\
\end{array}
\]
(FPCore (x y z t a b)
:precision binary64
(+ (- (* x 2.0) (* (* (* y 9.0) z) t)) (* (* a 27.0) b))) ↓
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (- (* x 2.0) (* (* (* y 9.0) z) t))))
(if (<= t -1e+217)
(+ t_1 (* (* a 27.0) b))
(if (<= t 4.8e+124)
(fma 27.0 (* b a) (fma x 2.0 (- (* 9.0 (* y (* z t))))))
(+ t_1 (* (* 27.0 b) a)))))) double code(double x, double y, double z, double t, double a, double b) {
return ((x * 2.0) - (((y * 9.0) * z) * t)) + ((a * 27.0) * b);
}
↓
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x * 2.0) - (((y * 9.0) * z) * t);
double tmp;
if (t <= -1e+217) {
tmp = t_1 + ((a * 27.0) * b);
} else if (t <= 4.8e+124) {
tmp = fma(27.0, (b * a), fma(x, 2.0, -(9.0 * (y * (z * t)))));
} else {
tmp = t_1 + ((27.0 * b) * a);
}
return tmp;
}
function code(x, y, z, t, a, b)
return Float64(Float64(Float64(x * 2.0) - Float64(Float64(Float64(y * 9.0) * z) * t)) + Float64(Float64(a * 27.0) * b))
end
↓
function code(x, y, z, t, a, b)
t_1 = Float64(Float64(x * 2.0) - Float64(Float64(Float64(y * 9.0) * z) * t))
tmp = 0.0
if (t <= -1e+217)
tmp = Float64(t_1 + Float64(Float64(a * 27.0) * b));
elseif (t <= 4.8e+124)
tmp = fma(27.0, Float64(b * a), fma(x, 2.0, Float64(-Float64(9.0 * Float64(y * Float64(z * t))))));
else
tmp = Float64(t_1 + Float64(Float64(27.0 * b) * a));
end
return tmp
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x * 2.0), $MachinePrecision] - N[(N[(N[(y * 9.0), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(N[(a * 27.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
↓
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x * 2.0), $MachinePrecision] - N[(N[(N[(y * 9.0), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1e+217], N[(t$95$1 + N[(N[(a * 27.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.8e+124], N[(27.0 * N[(b * a), $MachinePrecision] + N[(x * 2.0 + (-N[(9.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision])), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(N[(27.0 * b), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]]]]
\left(x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\right) + \left(a \cdot 27\right) \cdot b
↓
\begin{array}{l}
t_1 := x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\\
\mathbf{if}\;t \leq -1 \cdot 10^{+217}:\\
\;\;\;\;t_1 + \left(a \cdot 27\right) \cdot b\\
\mathbf{elif}\;t \leq 4.8 \cdot 10^{+124}:\\
\;\;\;\;\mathsf{fma}\left(27, b \cdot a, \mathsf{fma}\left(x, 2, -9 \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_1 + \left(27 \cdot b\right) \cdot a\\
\end{array}
Alternatives Alternative 1 Error 0.9 Cost 1608
\[\begin{array}{l}
t_1 := \left(a \cdot 27\right) \cdot b\\
t_2 := \left(x \cdot 2 - \left(z \cdot t\right) \cdot \left(y \cdot 9\right)\right) + t_1\\
\mathbf{if}\;y \cdot 9 \leq -5 \cdot 10^{-92}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;y \cdot 9 \leq 5 \cdot 10^{-40}:\\
\;\;\;\;\left(x \cdot 2 - \left(9 \cdot \left(t \cdot y\right)\right) \cdot z\right) + t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\]
Alternative 2 Error 10.8 Cost 1480
\[\begin{array}{l}
t_1 := \left(a \cdot 27\right) \cdot b\\
t_2 := 2 \cdot x + 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;t_1 \leq -2 \cdot 10^{-27}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_1 \leq 5 \cdot 10^{+16}:\\
\;\;\;\;2 \cdot x - 9 \cdot \left(y \cdot \left(t \cdot z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\]
Alternative 3 Error 10.6 Cost 1480
\[\begin{array}{l}
t_1 := \left(a \cdot 27\right) \cdot b\\
t_2 := 2 \cdot x + 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;t_1 \leq -1 \cdot 10^{-13}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_1 \leq 100000000000:\\
\;\;\;\;2 \cdot x - \left(z \cdot 9\right) \cdot \left(y \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\]
Alternative 4 Error 1.9 Cost 1352
\[\begin{array}{l}
t_1 := \left(x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\right) + \left(27 \cdot b\right) \cdot a\\
\mathbf{if}\;t \leq -1.15 \cdot 10^{+206}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 2 \cdot 10^{-113}:\\
\;\;\;\;\left(x \cdot 2 - \left(z \cdot t\right) \cdot \left(y \cdot 9\right)\right) + \left(a \cdot 27\right) \cdot b\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\]
Alternative 5 Error 1.9 Cost 1352
\[\begin{array}{l}
t_1 := \left(a \cdot 27\right) \cdot b\\
t_2 := x \cdot 2 - \left(\left(y \cdot 9\right) \cdot z\right) \cdot t\\
\mathbf{if}\;t \leq -2.1 \cdot 10^{+216}:\\
\;\;\;\;t_2 + t_1\\
\mathbf{elif}\;t \leq 2 \cdot 10^{-112}:\\
\;\;\;\;\left(x \cdot 2 - \left(z \cdot t\right) \cdot \left(y \cdot 9\right)\right) + t_1\\
\mathbf{else}:\\
\;\;\;\;t_2 + \left(27 \cdot b\right) \cdot a\\
\end{array}
\]
Alternative 6 Error 28.8 Cost 1112
\[\begin{array}{l}
t_1 := -9 \cdot \left(y \cdot \left(t \cdot z\right)\right)\\
t_2 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;x \leq -550000000000:\\
\;\;\;\;2 \cdot x\\
\mathbf{elif}\;x \leq -6.2 \cdot 10^{-114}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -1.3 \cdot 10^{-162}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 3.8 \cdot 10^{-220}:\\
\;\;\;\;\left(27 \cdot b\right) \cdot a\\
\mathbf{elif}\;x \leq 6.5 \cdot 10^{-168}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 6.5 \cdot 10^{+32}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;2 \cdot x\\
\end{array}
\]
Alternative 7 Error 28.7 Cost 1112
\[\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;x \leq -210000000000:\\
\;\;\;\;2 \cdot x\\
\mathbf{elif}\;x \leq -3.1 \cdot 10^{-109}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -1.48 \cdot 10^{-164}:\\
\;\;\;\;-9 \cdot \left(\left(y \cdot z\right) \cdot t\right)\\
\mathbf{elif}\;x \leq 2.3 \cdot 10^{-221}:\\
\;\;\;\;\left(27 \cdot b\right) \cdot a\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{-168}:\\
\;\;\;\;-9 \cdot \left(y \cdot \left(t \cdot z\right)\right)\\
\mathbf{elif}\;x \leq 3.4 \cdot 10^{+16}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;2 \cdot x\\
\end{array}
\]
Alternative 8 Error 28.7 Cost 1112
\[\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;x \leq -950000000000:\\
\;\;\;\;2 \cdot x\\
\mathbf{elif}\;x \leq -3.7 \cdot 10^{-109}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -5.5 \cdot 10^{-162}:\\
\;\;\;\;-9 \cdot \left(\left(y \cdot z\right) \cdot t\right)\\
\mathbf{elif}\;x \leq 3.8 \cdot 10^{-220}:\\
\;\;\;\;\left(27 \cdot b\right) \cdot a\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{-168}:\\
\;\;\;\;\left(t \cdot z\right) \cdot \left(-9 \cdot y\right)\\
\mathbf{elif}\;x \leq 1.11 \cdot 10^{+21}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;2 \cdot x\\
\end{array}
\]
Alternative 9 Error 29.0 Cost 1112
\[\begin{array}{l}
t_1 := 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;x \leq -850000000000:\\
\;\;\;\;2 \cdot x\\
\mathbf{elif}\;x \leq -2.05 \cdot 10^{-109}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -1.4 \cdot 10^{-164}:\\
\;\;\;\;-9 \cdot \left(\left(y \cdot z\right) \cdot t\right)\\
\mathbf{elif}\;x \leq 1.55 \cdot 10^{-266}:\\
\;\;\;\;\left(27 \cdot b\right) \cdot a\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{-168}:\\
\;\;\;\;\left(z \cdot -9\right) \cdot \left(y \cdot t\right)\\
\mathbf{elif}\;x \leq 4.2 \cdot 10^{+17}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;2 \cdot x\\
\end{array}
\]
Alternative 10 Error 19.1 Cost 1104
\[\begin{array}{l}
t_1 := 2 \cdot x + 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;x \leq -1.82 \cdot 10^{-109}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -4.3 \cdot 10^{-162}:\\
\;\;\;\;-9 \cdot \left(\left(y \cdot z\right) \cdot t\right)\\
\mathbf{elif}\;x \leq 4.4 \cdot 10^{-186}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 10^{-167}:\\
\;\;\;\;\left(t \cdot z\right) \cdot \left(-9 \cdot y\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\]
Alternative 11 Error 19.2 Cost 1104
\[\begin{array}{l}
t_1 := 2 \cdot x + 27 \cdot \left(a \cdot b\right)\\
\mathbf{if}\;x \leq -1.82 \cdot 10^{-109}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -1 \cdot 10^{-161}:\\
\;\;\;\;-9 \cdot \left(\left(y \cdot z\right) \cdot t\right)\\
\mathbf{elif}\;x \leq 2.5 \cdot 10^{-187}:\\
\;\;\;\;2 \cdot x + \left(27 \cdot b\right) \cdot a\\
\mathbf{elif}\;x \leq 10^{-167}:\\
\;\;\;\;\left(t \cdot z\right) \cdot \left(-9 \cdot y\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\]
Alternative 12 Error 3.3 Cost 1088
\[\left(x \cdot 2 - \left(9 \cdot \left(t \cdot y\right)\right) \cdot z\right) + \left(a \cdot 27\right) \cdot b
\]
Alternative 13 Error 28.1 Cost 584
\[\begin{array}{l}
\mathbf{if}\;x \leq -1.7 \cdot 10^{+14}:\\
\;\;\;\;2 \cdot x\\
\mathbf{elif}\;x \leq 1.16 \cdot 10^{+15}:\\
\;\;\;\;27 \cdot \left(a \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;2 \cdot x\\
\end{array}
\]
Alternative 14 Error 37.4 Cost 192
\[2 \cdot x
\]