\frac{x - y}{x + y}\frac{\frac{x}{x + y} \cdot \frac{x}{x + y} - \frac{y}{x + y} \cdot \frac{y}{x + y}}{\frac{x}{x + y} + \frac{y}{x + y}}double f(double x, double y) {
double r738456 = x;
double r738457 = y;
double r738458 = r738456 - r738457;
double r738459 = r738456 + r738457;
double r738460 = r738458 / r738459;
return r738460;
}
double f(double x, double y) {
double r738461 = x;
double r738462 = y;
double r738463 = r738461 + r738462;
double r738464 = r738461 / r738463;
double r738465 = r738464 * r738464;
double r738466 = r738462 / r738463;
double r738467 = r738466 * r738466;
double r738468 = r738465 - r738467;
double r738469 = r738464 + r738466;
double r738470 = r738468 / r738469;
return r738470;
}




Bits error versus x




Bits error versus y
Results
| Original | 0.0 |
|---|---|
| Target | 0.0 |
| Herbie | 0.0 |
Initial program 0.0
rmApplied div-sub0.0
rmApplied flip--0.0
Final simplification0.0
herbie shell --seed 2019322
(FPCore (x y)
:name "Data.Colour.RGB:hslsv from colour-2.3.3, D"
:precision binary64
:herbie-target
(- (/ x (+ x y)) (/ y (+ x y)))
(/ (- x y) (+ x y)))