\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}\frac{\frac{y \cdot \frac{x}{x + y}}{x + y}}{\left(x + y\right) + 1}double f(double x, double y) {
double r224504 = x;
double r224505 = y;
double r224506 = r224504 * r224505;
double r224507 = r224504 + r224505;
double r224508 = r224507 * r224507;
double r224509 = 1.0;
double r224510 = r224507 + r224509;
double r224511 = r224508 * r224510;
double r224512 = r224506 / r224511;
return r224512;
}
double f(double x, double y) {
double r224513 = y;
double r224514 = x;
double r224515 = r224514 + r224513;
double r224516 = r224514 / r224515;
double r224517 = r224513 * r224516;
double r224518 = r224517 / r224515;
double r224519 = 1.0;
double r224520 = r224515 + r224519;
double r224521 = r224518 / r224520;
return r224521;
}




Bits error versus x




Bits error versus y
Results
| Original | 20.2 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 20.2
rmApplied distribute-lft-in20.2
rmApplied times-frac10.8
Simplified8.3
rmApplied *-un-lft-identity8.3
Applied times-frac0.2
Applied associate-*l*0.2
rmApplied associate-*r/0.2
Applied associate-*r/0.2
Simplified0.1
Final simplification0.1
herbie shell --seed 2019326
(FPCore (x y)
:name "Numeric.SpecFunctions:incompleteBetaApprox from math-functions-0.1.5.2, A"
:precision binary64
:herbie-target
(/ (/ (/ x (+ (+ y 1) x)) (+ y x)) (/ 1 (/ y (+ y x))))
(/ (* x y) (* (* (+ x y) (+ x y)) (+ (+ x y) 1))))