\left(x \cdot x\right) \cdot \left(3 - x \cdot 2\right)
\left(x \cdot x\right) \cdot 3 + \left(-2 \cdot {x}^{3}\right)double f(double x) {
double r787785 = x;
double r787786 = r787785 * r787785;
double r787787 = 3.0;
double r787788 = 2.0;
double r787789 = r787785 * r787788;
double r787790 = r787787 - r787789;
double r787791 = r787786 * r787790;
return r787791;
}
double f(double x) {
double r787792 = x;
double r787793 = r787792 * r787792;
double r787794 = 3.0;
double r787795 = r787793 * r787794;
double r787796 = 2.0;
double r787797 = 3.0;
double r787798 = pow(r787792, r787797);
double r787799 = r787796 * r787798;
double r787800 = -r787799;
double r787801 = r787795 + r787800;
return r787801;
}




Bits error versus x
Results
| Original | 0.2 |
|---|---|
| Target | 0.2 |
| Herbie | 0.1 |
Initial program 0.2
rmApplied sub-neg0.2
Applied distribute-lft-in0.2
Simplified0.1
Final simplification0.1
herbie shell --seed 2020036
(FPCore (x)
:name "Data.Spline.Key:interpolateKeys from smoothie-0.4.0.2"
:precision binary64
:herbie-target
(* x (* x (- 3 (* x 2))))
(* (* x x) (- 3 (* x 2))))