\frac{x \cdot y}{y + 1}x \cdot \frac{1}{\frac{y + 1}{y}}double f(double x, double y) {
double r538225 = x;
double r538226 = y;
double r538227 = r538225 * r538226;
double r538228 = 1.0;
double r538229 = r538226 + r538228;
double r538230 = r538227 / r538229;
return r538230;
}
double f(double x, double y) {
double r538231 = x;
double r538232 = 1.0;
double r538233 = y;
double r538234 = 1.0;
double r538235 = r538233 + r538234;
double r538236 = r538235 / r538233;
double r538237 = r538232 / r538236;
double r538238 = r538231 * r538237;
return r538238;
}




Bits error versus x




Bits error versus y
Results
| Original | 8.0 |
|---|---|
| Target | 0.0 |
| Herbie | 0.1 |
Initial program 8.0
rmApplied *-un-lft-identity8.0
Applied times-frac0.0
Simplified0.0
rmApplied clear-num0.1
Final simplification0.1
herbie shell --seed 2019235
(FPCore (x y)
:name "Diagrams.Trail:splitAtParam from diagrams-lib-1.3.0.3, B"
:precision binary64
:herbie-target
(if (< y -3693.84827882972468) (- (/ x (* y y)) (- (/ x y) x)) (if (< y 6799310503.41891003) (/ (* x y) (+ y 1)) (- (/ x (* y y)) (- (/ x y) x))))
(/ (* x y) (+ y 1)))