\frac{x \cdot \left(y - z\right)}{t - z}\begin{array}{l}
\mathbf{if}\;z \le -6.5823688828081441 \cdot 10^{-185} \lor \neg \left(z \le 5.6298607401033476 \cdot 10^{-46}\right):\\
\;\;\;\;x \cdot \frac{y - z}{t - z}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot \left(\sqrt[3]{y - z} \cdot \sqrt[3]{y - z}\right)}{\frac{t - z}{\sqrt[3]{y - z}}}\\
\end{array}double code(double x, double y, double z, double t) {
return ((x * (y - z)) / (t - z));
}
double code(double x, double y, double z, double t) {
double temp;
if (((z <= -6.582368882808144e-185) || !(z <= 5.629860740103348e-46))) {
temp = (x * ((y - z) / (t - z)));
} else {
temp = ((x * (cbrt((y - z)) * cbrt((y - z)))) / ((t - z) / cbrt((y - z))));
}
return temp;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 11.5 |
|---|---|
| Target | 2.4 |
| Herbie | 2.2 |
if z < -6.582368882808144e-185 or 5.629860740103348e-46 < z Initial program 14.1
rmApplied *-un-lft-identity14.1
Applied times-frac1.0
Simplified1.0
if -6.582368882808144e-185 < z < 5.629860740103348e-46Initial program 5.3
rmApplied add-cube-cbrt6.2
Applied associate-*r*6.2
Applied associate-/l*5.2
Final simplification2.2
herbie shell --seed 2020066 +o rules:numerics
(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)))