\frac{x \cdot \left(y - z\right)}{t - z}\begin{array}{l}
\mathbf{if}\;z \le -2.42187688089345209 \cdot 10^{-242} \lor \neg \left(z \le 1.3626492206831902 \cdot 10^{-72}\right):\\
\;\;\;\;x \cdot \frac{y - z}{t - z}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{t - z} \cdot \left(y - z\right)\\
\end{array}double code(double x, double y, double z, double t) {
return (((double) (x * ((double) (y - z)))) / ((double) (t - z)));
}
double code(double x, double y, double z, double t) {
double VAR;
if (((z <= -2.421876880893452e-242) || !(z <= 1.3626492206831902e-72))) {
VAR = ((double) (x * (((double) (y - z)) / ((double) (t - z)))));
} else {
VAR = ((double) ((x / ((double) (t - z))) * ((double) (y - z))));
}
return VAR;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 12.1 |
|---|---|
| Target | 2.0 |
| Herbie | 2.1 |
if z < -2.42187688089345209e-242 or 1.3626492206831902e-72 < z Initial program 13.9
rmApplied *-un-lft-identity13.9
Applied times-frac1.0
Simplified1.0
if -2.42187688089345209e-242 < z < 1.3626492206831902e-72Initial program 6.0
rmApplied associate-/l*5.3
rmApplied associate-/r/5.8
Final simplification2.1
herbie shell --seed 2020182
(FPCore (x y z t)
:name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
:precision binary64
:herbie-target
(/ x (/ (- t z) (- y z)))
(/ (* x (- y z)) (- t z)))