\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 r826769 = x;
double r826770 = r826769 * r826769;
double r826771 = 3.0;
double r826772 = 2.0;
double r826773 = r826769 * r826772;
double r826774 = r826771 - r826773;
double r826775 = r826770 * r826774;
return r826775;
}
double f(double x) {
double r826776 = x;
double r826777 = r826776 * r826776;
double r826778 = 3.0;
double r826779 = r826777 * r826778;
double r826780 = 2.0;
double r826781 = 3.0;
double r826782 = pow(r826776, r826781);
double r826783 = r826780 * r826782;
double r826784 = -r826783;
double r826785 = r826779 + r826784;
return r826785;
}




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