\left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z
x - \left(\left(y + 0.5\right) \cdot \log y - \left(y - z\right)\right)
double f(double x, double y, double z) {
double r457579 = x;
double r457580 = y;
double r457581 = 0.5;
double r457582 = r457580 + r457581;
double r457583 = log(r457580);
double r457584 = r457582 * r457583;
double r457585 = r457579 - r457584;
double r457586 = r457585 + r457580;
double r457587 = z;
double r457588 = r457586 - r457587;
return r457588;
}
double f(double x, double y, double z) {
double r457589 = x;
double r457590 = y;
double r457591 = 0.5;
double r457592 = r457590 + r457591;
double r457593 = log(r457590);
double r457594 = r457592 * r457593;
double r457595 = z;
double r457596 = r457590 - r457595;
double r457597 = r457594 - r457596;
double r457598 = r457589 - r457597;
return r457598;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 0.1 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 0.1
rmApplied associate--l+0.1
rmApplied associate-+l-0.1
Final simplification0.1
herbie shell --seed 2020035
(FPCore (x y z)
:name "Numeric.SpecFunctions:stirlingError from math-functions-0.1.5.2"
:precision binary64
:herbie-target
(- (- (+ y x) z) (* (+ y 0.5) (log y)))
(- (+ (- x (* (+ y 0.5) (log y))) y) z))