x + \frac{y \cdot \left(z - t\right)}{z - a}\begin{array}{l}
\mathbf{if}\;\frac{y \cdot \left(z - t\right)}{z - a} \le -9.486502330729892 \cdot 10^{190} \lor \neg \left(\frac{y \cdot \left(z - t\right)}{z - a} \le 1.2468955882067589 \cdot 10^{290}\right):\\
\;\;\;\;x + y \cdot \frac{z - t}{z - a}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y \cdot \left(z - t\right)}{z - a}\\
\end{array}double code(double x, double y, double z, double t, double a) {
return ((double) (x + ((double) (((double) (y * ((double) (z - t)))) / ((double) (z - a))))));
}
double code(double x, double y, double z, double t, double a) {
double VAR;
if (((((double) (((double) (y * ((double) (z - t)))) / ((double) (z - a)))) <= -9.486502330729892e+190) || !(((double) (((double) (y * ((double) (z - t)))) / ((double) (z - a)))) <= 1.2468955882067589e+290))) {
VAR = ((double) (x + ((double) (y * ((double) (((double) (z - t)) / ((double) (z - a))))))));
} else {
VAR = ((double) (x + ((double) (((double) (y * ((double) (z - t)))) / ((double) (z - a))))));
}
return VAR;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a
Results
| Original | 10.1 |
|---|---|
| Target | 1.3 |
| Herbie | 0.6 |
if (/ (* y (- z t)) (- z a)) < -9.486502330729892e+190 or 1.2468955882067589e+290 < (/ (* y (- z t)) (- z a)) Initial program 51.9
rmApplied *-un-lft-identity51.9
Applied times-frac1.8
Simplified1.8
if -9.486502330729892e+190 < (/ (* y (- z t)) (- z a)) < 1.2468955882067589e+290Initial program 0.3
Final simplification0.6
herbie shell --seed 2020122 +o rules:numerics
(FPCore (x y z t a)
:name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTicks from plot-0.2.3.4, A"
:precision binary64
:herbie-target
(+ x (/ y (/ (- z a) (- z t))))
(+ x (/ (* y (- z t)) (- z a))))