x + \frac{\left(y - x\right) \cdot z}{t}x + \frac{y - x}{\frac{t}{z}}double f(double x, double y, double z, double t) {
double r339887 = x;
double r339888 = y;
double r339889 = r339888 - r339887;
double r339890 = z;
double r339891 = r339889 * r339890;
double r339892 = t;
double r339893 = r339891 / r339892;
double r339894 = r339887 + r339893;
return r339894;
}
double f(double x, double y, double z, double t) {
double r339895 = x;
double r339896 = y;
double r339897 = r339896 - r339895;
double r339898 = t;
double r339899 = z;
double r339900 = r339898 / r339899;
double r339901 = r339897 / r339900;
double r339902 = r339895 + r339901;
return r339902;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 7.0 |
|---|---|
| Target | 2.0 |
| Herbie | 1.9 |
if z < 3.721695370812968e-308Initial program 7.2
rmApplied associate-/l*1.5
if 3.721695370812968e-308 < z Initial program 6.8
rmApplied associate-/l*2.3
rmApplied clear-num2.3
rmApplied *-un-lft-identity2.3
Applied add-sqr-sqrt2.4
Applied *-un-lft-identity2.4
Applied times-frac2.4
Applied times-frac2.5
Applied associate-/r*2.5
Simplified2.5
Final simplification1.9
herbie shell --seed 2019303
(FPCore (x y z t)
:name "Numeric.Histogram:binBounds from Chart-1.5.3"
:precision binary64
:herbie-target
(if (< x -9.0255111955330046e-135) (- x (* (/ z t) (- x y))) (if (< x 4.2750321637007147e-250) (+ x (* (/ (- y x) t) z)) (+ x (/ (- y x) (/ t z)))))
(+ x (/ (* (- y x) z) t)))