\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 r1032159 = x;
double r1032160 = y;
double r1032161 = r1032159 - r1032160;
double r1032162 = r1032159 + r1032160;
double r1032163 = r1032161 / r1032162;
return r1032163;
}
double f(double x, double y) {
double r1032164 = x;
double r1032165 = y;
double r1032166 = r1032164 + r1032165;
double r1032167 = r1032164 / r1032166;
double r1032168 = r1032167 * r1032167;
double r1032169 = r1032165 / r1032166;
double r1032170 = r1032169 * r1032169;
double r1032171 = r1032168 - r1032170;
double r1032172 = r1032167 + r1032169;
double r1032173 = r1032171 / r1032172;
return r1032173;
}




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 2020034
(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)))