x \cdot \left(1 + y \cdot y\right)
x \cdot 1 + y \cdot \left(x \cdot y\right)
double f(double x, double y) {
double r624614 = x;
double r624615 = 1.0;
double r624616 = y;
double r624617 = r624616 * r624616;
double r624618 = r624615 + r624617;
double r624619 = r624614 * r624618;
return r624619;
}
double f(double x, double y) {
double r624620 = x;
double r624621 = 1.0;
double r624622 = r624620 * r624621;
double r624623 = y;
double r624624 = r624620 * r624623;
double r624625 = r624623 * r624624;
double r624626 = r624622 + r624625;
return r624626;
}




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-*l*0.1
Simplified0.1
Final simplification0.1
herbie shell --seed 2020042 +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))))