\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 r751767 = x;
double r751768 = r751767 * r751767;
double r751769 = 3.0;
double r751770 = 2.0;
double r751771 = r751767 * r751770;
double r751772 = r751769 - r751771;
double r751773 = r751768 * r751772;
return r751773;
}
double f(double x) {
double r751774 = x;
double r751775 = r751774 * r751774;
double r751776 = 3.0;
double r751777 = r751775 * r751776;
double r751778 = 2.0;
double r751779 = 3.0;
double r751780 = pow(r751774, r751779);
double r751781 = r751778 * r751780;
double r751782 = -r751781;
double r751783 = r751777 + r751782;
return r751783;
}




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 2020046
(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))))