x + \frac{x - y}{2}x + \frac{x - y}{2}double f(double x, double y) {
double r391043 = x;
double r391044 = y;
double r391045 = r391043 - r391044;
double r391046 = 2.0;
double r391047 = r391045 / r391046;
double r391048 = r391043 + r391047;
return r391048;
}
double f(double x, double y) {
double r391049 = x;
double r391050 = y;
double r391051 = r391049 - r391050;
double r391052 = 2.0;
double r391053 = r391051 / r391052;
double r391054 = r391049 + r391053;
return r391054;
}




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