\frac{x - y}{2 - \left(x + y\right)}\mathsf{log1p}\left(\mathsf{expm1}\left(\frac{x - y}{2 - \left(x + y\right)}\right)\right)double f(double x, double y) {
double r888583 = x;
double r888584 = y;
double r888585 = r888583 - r888584;
double r888586 = 2.0;
double r888587 = r888583 + r888584;
double r888588 = r888586 - r888587;
double r888589 = r888585 / r888588;
return r888589;
}
double f(double x, double y) {
double r888590 = x;
double r888591 = y;
double r888592 = r888590 - r888591;
double r888593 = 2.0;
double r888594 = r888590 + r888591;
double r888595 = r888593 - r888594;
double r888596 = r888592 / r888595;
double r888597 = expm1(r888596);
double r888598 = log1p(r888597);
return r888598;
}




Bits error versus x




Bits error versus y
Results
| Original | 0.0 |
|---|---|
| Target | 0.0 |
| Herbie | 0.0 |
Initial program 0.0
rmApplied log1p-expm1-u0.0
Final simplification0.0
herbie shell --seed 2020036 +o rules:numerics
(FPCore (x y)
:name "Data.Colour.RGB:hslsv from colour-2.3.3, C"
:precision binary64
:herbie-target
(- (/ x (- 2 (+ x y))) (/ y (- 2 (+ x y))))
(/ (- x y) (- 2 (+ x y))))