x + \frac{x - y}{2}x + \frac{x - y}{2}double f(double x, double y) {
double r344627 = x;
double r344628 = y;
double r344629 = r344627 - r344628;
double r344630 = 2.0;
double r344631 = r344629 / r344630;
double r344632 = r344627 + r344631;
return r344632;
}
double f(double x, double y) {
double r344633 = x;
double r344634 = y;
double r344635 = r344633 - r344634;
double r344636 = 2.0;
double r344637 = r344635 / r344636;
double r344638 = r344633 + r344637;
return r344638;
}




Bits error versus x




Bits error versus y
Results
| Original | 0.1 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 0.1
Final simplification0.1
herbie shell --seed 2019326 +o rules:numerics
(FPCore (x y)
:name "Graphics.Rendering.Chart.Axis.Types:hBufferRect from Chart-1.5.3"
:precision binary64
:herbie-target
(- (* 1.5 x) (* 0.5 y))
(+ x (/ (- x y) 2)))