x + \frac{x - y}{2}\left(x + \frac{x}{2}\right) - \frac{y}{2}double f(double x, double y) {
double r681203 = x;
double r681204 = y;
double r681205 = r681203 - r681204;
double r681206 = 2.0;
double r681207 = r681205 / r681206;
double r681208 = r681203 + r681207;
return r681208;
}
double f(double x, double y) {
double r681209 = x;
double r681210 = 2.0;
double r681211 = r681209 / r681210;
double r681212 = r681209 + r681211;
double r681213 = y;
double r681214 = r681213 / r681210;
double r681215 = r681212 - r681214;
return r681215;
}




Bits error versus x




Bits error versus y
Results
| Original | 0.1 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 0.1
rmApplied div-sub0.1
Applied associate-+r-0.1
Final simplification0.1
herbie shell --seed 2019356
(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)))