\left(x \cdot x\right) \cdot \left(3 - x \cdot 2\right)
x \cdot \left(x \cdot 3\right) + \left(-2 \cdot {x}^{3}\right)double f(double x) {
double r766991 = x;
double r766992 = r766991 * r766991;
double r766993 = 3.0;
double r766994 = 2.0;
double r766995 = r766991 * r766994;
double r766996 = r766993 - r766995;
double r766997 = r766992 * r766996;
return r766997;
}
double f(double x) {
double r766998 = x;
double r766999 = 3.0;
double r767000 = r766998 * r766999;
double r767001 = r766998 * r767000;
double r767002 = 2.0;
double r767003 = 3.0;
double r767004 = pow(r766998, r767003);
double r767005 = r767002 * r767004;
double r767006 = -r767005;
double r767007 = r767001 + r767006;
return r767007;
}




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
rmApplied associate-*l*0.1
Final simplification0.1
herbie shell --seed 2020018
(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))))