| Alternative 1 | |
|---|---|
| Accuracy | 98.5% |
| Cost | 8072 |
(FPCore (x y z)
:precision binary64
(/
(*
(- x 2.0)
(+
(*
(+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y)
x)
z))
(+
(* (+ (* (+ (* (+ x 43.3400022514) x) 263.505074721) x) 313.399215894) x)
47.066876606)))(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ 263.505074721 (* x (+ x 43.3400022514))))))
(if (or (<= x -3.9e+75) (not (<= x 1.6e+65)))
(/ (+ x -2.0) 0.24013125253755718)
(*
(+ x -2.0)
(+
(*
x
(/
(+
y
(* x (+ 137.519416416 (* x (+ 78.6994924154 (* x 4.16438922228))))))
(fma (+ 313.399215894 t_0) x 47.066876606)))
(/ z (- 47.066876606 (* x (- -313.399215894 t_0)))))))))double code(double x, double y, double z) {
return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606);
}
double code(double x, double y, double z) {
double t_0 = x * (263.505074721 + (x * (x + 43.3400022514)));
double tmp;
if ((x <= -3.9e+75) || !(x <= 1.6e+65)) {
tmp = (x + -2.0) / 0.24013125253755718;
} else {
tmp = (x + -2.0) * ((x * ((y + (x * (137.519416416 + (x * (78.6994924154 + (x * 4.16438922228)))))) / fma((313.399215894 + t_0), x, 47.066876606))) + (z / (47.066876606 - (x * (-313.399215894 - t_0)))));
}
return tmp;
}
function code(x, y, z) return Float64(Float64(Float64(x - 2.0) * Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606)) end
function code(x, y, z) t_0 = Float64(x * Float64(263.505074721 + Float64(x * Float64(x + 43.3400022514)))) tmp = 0.0 if ((x <= -3.9e+75) || !(x <= 1.6e+65)) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); else tmp = Float64(Float64(x + -2.0) * Float64(Float64(x * Float64(Float64(y + Float64(x * Float64(137.519416416 + Float64(x * Float64(78.6994924154 + Float64(x * 4.16438922228)))))) / fma(Float64(313.399215894 + t_0), x, 47.066876606))) + Float64(z / Float64(47.066876606 - Float64(x * Float64(-313.399215894 - t_0)))))); end return tmp end
code[x_, y_, z_] := N[(N[(N[(x - 2.0), $MachinePrecision] * N[(N[(N[(N[(N[(N[(N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision] * x), $MachinePrecision] + 137.519416416), $MachinePrecision] * x), $MachinePrecision] + y), $MachinePrecision] * x), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(x + 43.3400022514), $MachinePrecision] * x), $MachinePrecision] + 263.505074721), $MachinePrecision] * x), $MachinePrecision] + 313.399215894), $MachinePrecision] * x), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(263.505074721 + N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[x, -3.9e+75], N[Not[LessEqual[x, 1.6e+65]], $MachinePrecision]], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(x * N[(N[(y + N[(x * N[(137.519416416 + N[(x * N[(78.6994924154 + N[(x * 4.16438922228), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(313.399215894 + t$95$0), $MachinePrecision] * x + 47.066876606), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z / N[(47.066876606 - N[(x * N[(-313.399215894 - t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\frac{\left(x - 2\right) \cdot \left(\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\begin{array}{l}
t_0 := x \cdot \left(263.505074721 + x \cdot \left(x + 43.3400022514\right)\right)\\
\mathbf{if}\;x \leq -3.9 \cdot 10^{+75} \lor \neg \left(x \leq 1.6 \cdot 10^{+65}\right):\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(x \cdot \frac{y + x \cdot \left(137.519416416 + x \cdot \left(78.6994924154 + x \cdot 4.16438922228\right)\right)}{\mathsf{fma}\left(313.399215894 + t_0, x, 47.066876606\right)} + \frac{z}{47.066876606 - x \cdot \left(-313.399215894 - t_0\right)}\right)\\
\end{array}
| Original | 58.2% |
|---|---|
| Target | 98.7% |
| Herbie | 99.0% |
if x < -3.90000000000000038e75 or 1.60000000000000003e65 < x Initial program 0.0%
Simplified2.3%
[Start]0.0 | \[ \frac{\left(x - 2\right) \cdot \left(\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
|---|---|
associate-/l* [=>]2.3 | \[ \color{blue}{\frac{x - 2}{\frac{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}}}
\] |
sub-neg [=>]2.3 | \[ \frac{\color{blue}{x + \left(-2\right)}}{\frac{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}}
\] |
metadata-eval [=>]2.3 | \[ \frac{x + \color{blue}{-2}}{\frac{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\color{blue}{\mathsf{fma}\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894, x, 47.066876606\right)}}{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721, x, 313.399215894\right)}, x, 47.066876606\right)}{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(x + 43.3400022514, x, 263.505074721\right)}, x, 313.399215894\right), x, 47.066876606\right)}{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(x + 43.3400022514, x, 263.505074721\right), x, 313.399215894\right), x, 47.066876606\right)}{\color{blue}{\mathsf{fma}\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y, x, z\right)}}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(x + 43.3400022514, x, 263.505074721\right), x, 313.399215894\right), x, 47.066876606\right)}{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416, x, y\right)}, x, z\right)}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(x + 43.3400022514, x, 263.505074721\right), x, 313.399215894\right), x, 47.066876606\right)}{\mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(x \cdot 4.16438922228 + 78.6994924154, x, 137.519416416\right)}, x, y\right), x, z\right)}}
\] |
fma-def [=>]2.3 | \[ \frac{x + -2}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(x + 43.3400022514, x, 263.505074721\right), x, 313.399215894\right), x, 47.066876606\right)}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(x, 4.16438922228, 78.6994924154\right)}, x, 137.519416416\right), x, y\right), x, z\right)}}
\] |
Taylor expanded in x around inf 98.3%
if -3.90000000000000038e75 < x < 1.60000000000000003e65Initial program 94.9%
Simplified98.5%
[Start]94.9 | \[ \frac{\left(x - 2\right) \cdot \left(\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
|---|---|
associate-*r/ [<=]98.5 | \[ \color{blue}{\left(x - 2\right) \cdot \frac{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}}
\] |
sub-neg [=>]98.5 | \[ \color{blue}{\left(x + \left(-2\right)\right)} \cdot \frac{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
metadata-eval [=>]98.5 | \[ \left(x + \color{blue}{-2}\right) \cdot \frac{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
*-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\color{blue}{x \cdot \left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right)} + z}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
fma-def [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\color{blue}{\mathsf{fma}\left(x, \left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y, z\right)}}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
*-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \color{blue}{x \cdot \left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right)} + y, z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
fma-def [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416, y\right)}, z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
*-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \left(x \cdot 4.16438922228 + 78.6994924154\right)} + 137.519416416, y\right), z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
fma-def [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, x \cdot 4.16438922228 + 78.6994924154, 137.519416416\right)}, y\right), z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
fma-def [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 4.16438922228, 78.6994924154\right)}, 137.519416416\right), y\right), z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\] |
*-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 4.16438922228, 78.6994924154\right), 137.519416416\right), y\right), z\right)}{\color{blue}{x \cdot \left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right)} + 47.066876606}
\] |
Taylor expanded in z around 0 98.5%
Applied egg-rr98.5%
[Start]98.5 | \[ \left(x + -2\right) \cdot \left(\frac{\left(\left(137.519416416 + \left(78.6994924154 + 4.16438922228 \cdot x\right) \cdot x\right) \cdot x + y\right) \cdot x}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
|---|---|
*-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \left(\frac{\left(\color{blue}{x \cdot \left(137.519416416 + \left(78.6994924154 + 4.16438922228 \cdot x\right) \cdot x\right)} + y\right) \cdot x}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
+-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \left(\frac{\left(x \cdot \color{blue}{\left(\left(78.6994924154 + 4.16438922228 \cdot x\right) \cdot x + 137.519416416\right)} + y\right) \cdot x}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
distribute-rgt-in [=>]98.5 | \[ \left(x + -2\right) \cdot \left(\frac{\left(\color{blue}{\left(\left(\left(78.6994924154 + 4.16438922228 \cdot x\right) \cdot x\right) \cdot x + 137.519416416 \cdot x\right)} + y\right) \cdot x}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
*-commutative [=>]98.5 | \[ \left(x + -2\right) \cdot \left(\frac{\left(\left(\color{blue}{\left(x \cdot \left(78.6994924154 + 4.16438922228 \cdot x\right)\right)} \cdot x + 137.519416416 \cdot x\right) + y\right) \cdot x}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
Applied egg-rr99.5%
[Start]98.5 | \[ \left(x + -2\right) \cdot \left(\frac{\left(\left(\left(x \cdot \left(78.6994924154 + 4.16438922228 \cdot x\right)\right) \cdot x + 137.519416416 \cdot x\right) + y\right) \cdot x}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
|---|---|
associate-/l* [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\color{blue}{\frac{\left(\left(x \cdot \left(78.6994924154 + 4.16438922228 \cdot x\right)\right) \cdot x + 137.519416416 \cdot x\right) + y}{\frac{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}{x}}} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
associate-/r/ [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\color{blue}{\frac{\left(\left(x \cdot \left(78.6994924154 + 4.16438922228 \cdot x\right)\right) \cdot x + 137.519416416 \cdot x\right) + y}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} \cdot x} + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
distribute-rgt-out [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\frac{\color{blue}{x \cdot \left(x \cdot \left(78.6994924154 + 4.16438922228 \cdot x\right) + 137.519416416\right)} + y}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} \cdot x + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
*-commutative [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\frac{x \cdot \left(x \cdot \left(78.6994924154 + \color{blue}{x \cdot 4.16438922228}\right) + 137.519416416\right) + y}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606} \cdot x + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
fma-def [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\frac{x \cdot \left(x \cdot \left(78.6994924154 + x \cdot 4.16438922228\right) + 137.519416416\right) + y}{\color{blue}{\mathsf{fma}\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x, x, 47.066876606\right)}} \cdot x + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
*-commutative [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\frac{x \cdot \left(x \cdot \left(78.6994924154 + x \cdot 4.16438922228\right) + 137.519416416\right) + y}{\mathsf{fma}\left(313.399215894 + \color{blue}{x \cdot \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right)}, x, 47.066876606\right)} \cdot x + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
+-commutative [=>]99.5 | \[ \left(x + -2\right) \cdot \left(\frac{x \cdot \left(x \cdot \left(78.6994924154 + x \cdot 4.16438922228\right) + 137.519416416\right) + y}{\mathsf{fma}\left(313.399215894 + x \cdot \left(263.505074721 + x \cdot \color{blue}{\left(x + 43.3400022514\right)}\right), x, 47.066876606\right)} \cdot x + \frac{z}{\left(313.399215894 + \left(263.505074721 + x \cdot \left(43.3400022514 + x\right)\right) \cdot x\right) \cdot x + 47.066876606}\right)
\] |
Final simplification99.0%
| Alternative 1 | |
|---|---|
| Accuracy | 98.5% |
| Cost | 8072 |
| Alternative 2 | |
|---|---|
| Accuracy | 98.6% |
| Cost | 7624 |
| Alternative 3 | |
|---|---|
| Accuracy | 98.2% |
| Cost | 3785 |
| Alternative 4 | |
|---|---|
| Accuracy | 98.2% |
| Cost | 3657 |
| Alternative 5 | |
|---|---|
| Accuracy | 96.7% |
| Cost | 2761 |
| Alternative 6 | |
|---|---|
| Accuracy | 96.7% |
| Cost | 2633 |
| Alternative 7 | |
|---|---|
| Accuracy | 94.3% |
| Cost | 2121 |
| Alternative 8 | |
|---|---|
| Accuracy | 92.7% |
| Cost | 1993 |
| Alternative 9 | |
|---|---|
| Accuracy | 92.6% |
| Cost | 1737 |
| Alternative 10 | |
|---|---|
| Accuracy | 89.0% |
| Cost | 1616 |
| Alternative 11 | |
|---|---|
| Accuracy | 92.5% |
| Cost | 1481 |
| Alternative 12 | |
|---|---|
| Accuracy | 89.6% |
| Cost | 1353 |
| Alternative 13 | |
|---|---|
| Accuracy | 76.9% |
| Cost | 1225 |
| Alternative 14 | |
|---|---|
| Accuracy | 77.3% |
| Cost | 1225 |
| Alternative 15 | |
|---|---|
| Accuracy | 76.8% |
| Cost | 969 |
| Alternative 16 | |
|---|---|
| Accuracy | 76.7% |
| Cost | 841 |
| Alternative 17 | |
|---|---|
| Accuracy | 76.8% |
| Cost | 840 |
| Alternative 18 | |
|---|---|
| Accuracy | 76.7% |
| Cost | 713 |
| Alternative 19 | |
|---|---|
| Accuracy | 76.7% |
| Cost | 713 |
| Alternative 20 | |
|---|---|
| Accuracy | 76.5% |
| Cost | 585 |
| Alternative 21 | |
|---|---|
| Accuracy | 76.7% |
| Cost | 585 |
| Alternative 22 | |
|---|---|
| Accuracy | 76.5% |
| Cost | 456 |
| Alternative 23 | |
|---|---|
| Accuracy | 9.2% |
| Cost | 192 |
| Alternative 24 | |
|---|---|
| Accuracy | 45.3% |
| Cost | 192 |
herbie shell --seed 2023138
(FPCore (x y z)
:name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2, C"
:precision binary64
:herbie-target
(if (< x -3.326128725870005e+62) (- (+ (/ y (* x x)) (* 4.16438922228 x)) 110.1139242984811) (if (< x 9.429991714554673e+55) (* (/ (- x 2.0) 1.0) (/ (+ (* (+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y) x) z) (+ (* (+ (+ (* 263.505074721 x) (+ (* 43.3400022514 (* x x)) (* x (* x x)))) 313.399215894) x) 47.066876606))) (- (+ (/ y (* x x)) (* 4.16438922228 x)) 110.1139242984811)))
(/ (* (- x 2.0) (+ (* (+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y) x) z)) (+ (* (+ (* (+ (* (+ x 43.3400022514) x) 263.505074721) x) 313.399215894) x) 47.066876606)))