\left|\frac{x + 4}{y} - \frac{x}{y} \cdot z\right|\begin{array}{l}
\mathbf{if}\;x \leq -5.511667067808331 \cdot 10^{+24} \lor \neg \left(x \leq 5.59511929295642 \cdot 10^{+52}\right):\\
\;\;\;\;\left|\frac{x + 4}{y} - x \cdot \frac{z}{y}\right|\\
\mathbf{else}:\\
\;\;\;\;\left|\frac{\left(x + 4\right) - x \cdot z}{y}\right|\\
\end{array}(FPCore (x y z) :precision binary64 (fabs (- (/ (+ x 4.0) y) (* (/ x y) z))))
(FPCore (x y z) :precision binary64 (if (or (<= x -5.511667067808331e+24) (not (<= x 5.59511929295642e+52))) (fabs (- (/ (+ x 4.0) y) (* x (/ z y)))) (fabs (/ (- (+ x 4.0) (* x z)) y))))
double code(double x, double y, double z) {
return fabs(((x + 4.0) / y) - ((x / y) * z));
}
double code(double x, double y, double z) {
double tmp;
if ((x <= -5.511667067808331e+24) || !(x <= 5.59511929295642e+52)) {
tmp = fabs(((x + 4.0) / y) - (x * (z / y)));
} else {
tmp = fabs(((x + 4.0) - (x * z)) / y);
}
return tmp;
}



Bits error versus x



Bits error versus y



Bits error versus z
Results
if x < -5.511667067808331e24 or 5.59511929295642046e52 < x Initial program 0.1
rmApplied div-inv_binary64_750.2
Applied associate-*l*_binary64_190.1
Simplified0.1
if -5.511667067808331e24 < x < 5.59511929295642046e52Initial program 2.3
Simplified0.2
Final simplification0.2
herbie shell --seed 2020353
(FPCore (x y z)
:name "fabs fraction 1"
:precision binary64
(fabs (- (/ (+ x 4.0) y) (* (/ x y) z))))