\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}\frac{x}{x + y} \cdot \frac{\frac{y}{\left(x + y\right) + 1}}{x + y}double f(double x, double y) {
double r320002 = x;
double r320003 = y;
double r320004 = r320002 * r320003;
double r320005 = r320002 + r320003;
double r320006 = r320005 * r320005;
double r320007 = 1.0;
double r320008 = r320005 + r320007;
double r320009 = r320006 * r320008;
double r320010 = r320004 / r320009;
return r320010;
}
double f(double x, double y) {
double r320011 = x;
double r320012 = y;
double r320013 = r320011 + r320012;
double r320014 = r320011 / r320013;
double r320015 = 1.0;
double r320016 = r320013 + r320015;
double r320017 = r320012 / r320016;
double r320018 = r320017 / r320013;
double r320019 = r320014 * r320018;
return r320019;
}




Bits error versus x




Bits error versus y
Results
| Original | 19.4 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 19.4
rmApplied times-frac8.0
rmApplied associate-/r*0.2
rmApplied div-inv0.2
Applied associate-*l*0.2
Simplified0.1
Final simplification0.1
herbie shell --seed 2019212
(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))))