\[ \begin{array}{c}[z, t, a] = \mathsf{sort}([z, t, a])\\ \end{array} \]
Math FPCore C Julia Wolfram TeX \[\left(\left(\left(\left(x \cdot \log y + z\right) + t\right) + a\right) + \left(b - 0.5\right) \cdot \log c\right) + y \cdot i
\]
↓
\[z + \left(t + \mathsf{fma}\left(x, \log y, \mathsf{fma}\left(b + -0.5, \log c, \mathsf{fma}\left(y, i, a\right)\right)\right)\right)
\]
(FPCore (x y z t a b c i)
:precision binary64
(+ (+ (+ (+ (+ (* x (log y)) z) t) a) (* (- b 0.5) (log c))) (* y i))) ↓
(FPCore (x y z t a b c i)
:precision binary64
(+ z (+ t (fma x (log y) (fma (+ b -0.5) (log c) (fma y i a)))))) double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((((x * log(y)) + z) + t) + a) + ((b - 0.5) * log(c))) + (y * i);
}
↓
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return z + (t + fma(x, log(y), fma((b + -0.5), log(c), fma(y, i, a))));
}
function code(x, y, z, t, a, b, c, i)
return Float64(Float64(Float64(Float64(Float64(Float64(x * log(y)) + z) + t) + a) + Float64(Float64(b - 0.5) * log(c))) + Float64(y * i))
end
↓
function code(x, y, z, t, a, b, c, i)
return Float64(z + Float64(t + fma(x, log(y), fma(Float64(b + -0.5), log(c), fma(y, i, a)))))
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision] + t), $MachinePrecision] + a), $MachinePrecision] + N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]
↓
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(z + N[(t + N[(x * N[Log[y], $MachinePrecision] + N[(N[(b + -0.5), $MachinePrecision] * N[Log[c], $MachinePrecision] + N[(y * i + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\left(\left(\left(\left(x \cdot \log y + z\right) + t\right) + a\right) + \left(b - 0.5\right) \cdot \log c\right) + y \cdot i
↓
z + \left(t + \mathsf{fma}\left(x, \log y, \mathsf{fma}\left(b + -0.5, \log c, \mathsf{fma}\left(y, i, a\right)\right)\right)\right)
Alternatives Alternative 1 Error 2.7 Cost 14025
\[\begin{array}{l}
t_1 := \log c \cdot \left(b + -0.5\right)\\
\mathbf{if}\;x \leq -5.5 \cdot 10^{+75} \lor \neg \left(x \leq 5.2 \cdot 10^{+78}\right):\\
\;\;\;\;\left(z + a\right) + \left(x \cdot \log y + \left(t + t_1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(t_1 + \left(a + \left(z + t\right)\right)\right)\\
\end{array}
\]
Alternative 2 Error 0.1 Cost 14016
\[\left(\left(a + \left(t + \left(z + x \cdot \log y\right)\right)\right) + \log c \cdot \left(b + -0.5\right)\right) + y \cdot i
\]
Alternative 3 Error 3.8 Cost 13641
\[\begin{array}{l}
\mathbf{if}\;x \leq -9.2 \cdot 10^{+138} \lor \neg \left(x \leq 4.3 \cdot 10^{+86}\right):\\
\;\;\;\;\left(z + a\right) + \mathsf{fma}\left(y, i, x \cdot \log y\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(\log c \cdot \left(b + -0.5\right) + \left(a + \left(z + t\right)\right)\right)\\
\end{array}
\]
Alternative 4 Error 5.2 Cost 13512
\[\begin{array}{l}
\mathbf{if}\;x \leq -1 \cdot 10^{+140}:\\
\;\;\;\;\left(z + a\right) + x \cdot \log y\\
\mathbf{elif}\;x \leq 9.2 \cdot 10^{+86}:\\
\;\;\;\;y \cdot i + \left(\log c \cdot \left(b + -0.5\right) + \left(a + \left(z + t\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;z + \left(t + \mathsf{fma}\left(x, \log y, a\right)\right)\\
\end{array}
\]
Alternative 5 Error 5.3 Cost 7625
\[\begin{array}{l}
\mathbf{if}\;x \leq -3.4 \cdot 10^{+139} \lor \neg \left(x \leq 5.6 \cdot 10^{+86}\right):\\
\;\;\;\;\left(z + a\right) + x \cdot \log y\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(\log c \cdot \left(b + -0.5\right) + \left(a + \left(z + t\right)\right)\right)\\
\end{array}
\]
Alternative 6 Error 6.6 Cost 7497
\[\begin{array}{l}
\mathbf{if}\;x \leq -3.5 \cdot 10^{+142} \lor \neg \left(x \leq 10^{+87}\right):\\
\;\;\;\;\left(z + a\right) + x \cdot \log y\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(\left(a + \left(z + t\right)\right) + b \cdot \log c\right)\\
\end{array}
\]
Alternative 7 Error 11.7 Cost 7376
\[\begin{array}{l}
t_1 := \left(z + a\right) + x \cdot \log y\\
\mathbf{if}\;x \leq -9 \cdot 10^{+140}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 1.1 \cdot 10^{-16}:\\
\;\;\;\;a + \left(\log c \cdot \left(b + -0.5\right) + \left(z + t\right)\right)\\
\mathbf{elif}\;x \leq 7 \cdot 10^{+85}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\mathbf{elif}\;x \leq 7.5 \cdot 10^{+85}:\\
\;\;\;\;b \cdot \log c\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\]
Alternative 8 Error 16.0 Cost 7116
\[\begin{array}{l}
t_1 := z + b \cdot \log c\\
\mathbf{if}\;b \leq -4.6 \cdot 10^{+174}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;b \leq 300:\\
\;\;\;\;\left(z + a\right) + x \cdot \log y\\
\mathbf{elif}\;b \leq 6 \cdot 10^{+143}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\]
Alternative 9 Error 18.8 Cost 6985
\[\begin{array}{l}
\mathbf{if}\;b \leq -6.2 \cdot 10^{+180} \lor \neg \left(b \leq 1.5 \cdot 10^{+144}\right):\\
\;\;\;\;z + b \cdot \log c\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\end{array}
\]
Alternative 10 Error 20.2 Cost 6857
\[\begin{array}{l}
\mathbf{if}\;b \leq -1.55 \cdot 10^{+178} \lor \neg \left(b \leq 9.2 \cdot 10^{+220}\right):\\
\;\;\;\;b \cdot \log c\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\end{array}
\]
Alternative 11 Error 33.2 Cost 721
\[\begin{array}{l}
\mathbf{if}\;x \leq -1 \cdot 10^{-302}:\\
\;\;\;\;z + a\\
\mathbf{elif}\;x \leq 2.6 \cdot 10^{-285} \lor \neg \left(x \leq 1.25 \cdot 10^{-21}\right) \land x \leq 4400000000000:\\
\;\;\;\;y \cdot i\\
\mathbf{else}:\\
\;\;\;\;z + a\\
\end{array}
\]
Alternative 12 Error 27.5 Cost 452
\[\begin{array}{l}
\mathbf{if}\;a \leq 2.4 \cdot 10^{+104}:\\
\;\;\;\;z + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;z + a\\
\end{array}
\]
Alternative 13 Error 27.3 Cost 452
\[\begin{array}{l}
\mathbf{if}\;a \leq 8.8 \cdot 10^{+102}:\\
\;\;\;\;z + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;z + \left(t + a\right)\\
\end{array}
\]
Alternative 14 Error 24.4 Cost 448
\[y \cdot i + \left(z + a\right)
\]
Alternative 15 Error 36.5 Cost 196
\[\begin{array}{l}
\mathbf{if}\;z \leq -1.25 \cdot 10^{+128}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;a\\
\end{array}
\]
Alternative 16 Error 47.4 Cost 64
\[a
\]