\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{\frac{x}{x + y} \cdot y}{x + y}}{\left(x + y\right) + 1}double f(double x, double y) {
double r399207 = x;
double r399208 = y;
double r399209 = r399207 * r399208;
double r399210 = r399207 + r399208;
double r399211 = r399210 * r399210;
double r399212 = 1.0;
double r399213 = r399210 + r399212;
double r399214 = r399211 * r399213;
double r399215 = r399209 / r399214;
return r399215;
}
double f(double x, double y) {
double r399216 = x;
double r399217 = y;
double r399218 = r399216 + r399217;
double r399219 = r399216 / r399218;
double r399220 = r399219 * r399217;
double r399221 = r399220 / r399218;
double r399222 = 1.0;
double r399223 = r399218 + r399222;
double r399224 = r399221 / r399223;
return r399224;
}




Bits error versus x




Bits error versus y
Results
| Original | 20.2 |
|---|---|
| Target | 0.2 |
| Herbie | 0.1 |
Initial program 20.2
rmApplied times-frac8.0
rmApplied *-un-lft-identity8.0
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 2020100
(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))))