\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}{x + y}}{\left(x + y\right) + 1}double f(double x, double y) {
double r392498 = x;
double r392499 = y;
double r392500 = r392498 * r392499;
double r392501 = r392498 + r392499;
double r392502 = r392501 * r392501;
double r392503 = 1.0;
double r392504 = r392501 + r392503;
double r392505 = r392502 * r392504;
double r392506 = r392500 / r392505;
return r392506;
}
double f(double x, double y) {
double r392507 = x;
double r392508 = y;
double r392509 = r392507 + r392508;
double r392510 = r392507 / r392509;
double r392511 = r392508 / r392509;
double r392512 = 1.0;
double r392513 = r392509 + r392512;
double r392514 = r392511 / r392513;
double r392515 = r392510 * r392514;
return r392515;
}




Bits error versus x




Bits error versus y
Results
| Original | 20.1 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 20.1
rmApplied times-frac7.9
rmApplied *-un-lft-identity7.9
Applied times-frac0.2
Applied associate-*l*0.2
rmApplied associate-*r/0.2
Applied associate-*r/0.2
Simplified0.1
rmApplied *-un-lft-identity0.1
Applied *-un-lft-identity0.1
Applied times-frac0.1
Applied times-frac0.1
Simplified0.1
Final simplification0.1
herbie shell --seed 2020020 +o rules:numerics
(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))))