x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\begin{array}{l}
\mathbf{if}\;z \le -5.9869550139449346 \cdot 10^{183} \lor \neg \left(z \le 1.3812002330627112 \cdot 10^{209}\right):\\
\;\;\;\;y \cdot \left(\frac{x}{z} - \frac{t}{z}\right) + t\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{y - z}{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}} \cdot \left(\sqrt[3]{\frac{t - x}{\sqrt[3]{a - z}}} \cdot \sqrt[3]{\frac{t - x}{\sqrt[3]{a - z}}}\right)\right) \cdot \sqrt[3]{\frac{t - x}{\sqrt[3]{a - z}}}\\
\end{array}double code(double x, double y, double z, double t, double a) {
return (x + (((y - z) * (t - x)) / (a - z)));
}
double code(double x, double y, double z, double t, double a) {
double VAR;
if (((z <= -5.986955013944935e+183) || !(z <= 1.3812002330627112e+209))) {
VAR = ((y * ((x / z) - (t / z))) + t);
} else {
VAR = (x + ((((y - z) / (cbrt((a - z)) * cbrt((a - z)))) * (cbrt(((t - x) / cbrt((a - z)))) * cbrt(((t - x) / cbrt((a - z)))))) * cbrt(((t - x) / cbrt((a - z))))));
}
return VAR;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a
Results
| Original | 24.0 |
|---|---|
| Target | 11.7 |
| Herbie | 10.4 |
if z < -5.986955013944935e+183 or 1.3812002330627112e+209 < z Initial program 48.9
rmApplied add-cube-cbrt49.2
Applied times-frac24.3
rmApplied add-cube-cbrt24.6
Applied associate-*r*24.6
Taylor expanded around inf 25.2
Simplified15.0
if -5.986955013944935e+183 < z < 1.3812002330627112e+209Initial program 17.6
rmApplied add-cube-cbrt18.1
Applied times-frac9.1
rmApplied add-cube-cbrt9.2
Applied associate-*r*9.2
Final simplification10.4
herbie shell --seed 2020106
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3"
:precision binary64
:herbie-target
(if (< z -1.2536131056095036e+188) (- t (* (/ y z) (- t x))) (if (< z 4.446702369113811e+64) (+ x (/ (- y z) (/ (- a z) (- t x)))) (- t (* (/ y z) (- t x)))))
(+ x (/ (* (- y z) (- t x)) (- a z))))