x \cdot \left(1 + y \cdot y\right)
x \cdot 1 + \left(x \cdot y\right) \cdot y
double f(double x, double y) {
double r469326 = x;
double r469327 = 1.0;
double r469328 = y;
double r469329 = r469328 * r469328;
double r469330 = r469327 + r469329;
double r469331 = r469326 * r469330;
return r469331;
}
double f(double x, double y) {
double r469332 = x;
double r469333 = 1.0;
double r469334 = r469332 * r469333;
double r469335 = y;
double r469336 = r469332 * r469335;
double r469337 = r469336 * r469335;
double r469338 = r469334 + r469337;
return r469338;
}




Bits error versus x




Bits error versus y
Results
| Original | 5.3 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 5.3
rmApplied distribute-lft-in5.3
Simplified5.3
rmApplied unpow25.3
Applied associate-*r*0.1
Final simplification0.1
herbie shell --seed 2020047 +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))))