x \cdot \left(1 + y \cdot y\right)
\mathsf{fma}\left(y, y, 1\right) \cdot xdouble f(double x, double y) {
double r510009 = x;
double r510010 = 1.0;
double r510011 = y;
double r510012 = r510011 * r510011;
double r510013 = r510010 + r510012;
double r510014 = r510009 * r510013;
return r510014;
}
double f(double x, double y) {
double r510015 = y;
double r510016 = 1.0;
double r510017 = fma(r510015, r510015, r510016);
double r510018 = x;
double r510019 = r510017 * r510018;
return r510019;
}




Bits error versus x




Bits error versus y
| Original | 5.3 |
|---|---|
| Target | 0.1 |
| Herbie | 5.3 |
Initial program 5.3
Simplified5.3
Final simplification5.3
herbie shell --seed 2020043 +o rules:numerics
(FPCore (x y)
:name "Numeric.Integration.TanhSinh:everywhere from integration-0.2.1"
:precision binary64
:herbie-target
(+ x (* (* x y) y))
(* x (+ 1 (* y y))))