\frac{x \cdot y - z \cdot t}{a}\begin{array}{l}
\mathbf{if}\;x \cdot y - z \cdot t \leq -\infty:\\
\;\;\;\;\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \left(\sqrt[3]{x} \cdot \frac{y}{a}\right) - z \cdot \frac{t}{a}\\
\mathbf{elif}\;x \cdot y - z \cdot t \leq 9.781667072520984 \cdot 10^{+296}:\\
\;\;\;\;\frac{x \cdot y - z \cdot t}{a}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{y}{a} - \sqrt[3]{z \cdot \frac{t}{a}} \cdot \left(\sqrt[3]{z \cdot \frac{t}{a}} \cdot \sqrt[3]{z \cdot \frac{t}{a}}\right)\\
\end{array}double code(double x, double y, double z, double t, double a) {
return (((double) (((double) (x * y)) - ((double) (z * t)))) / a);
}
double code(double x, double y, double z, double t, double a) {
double VAR;
if ((((double) (((double) (x * y)) - ((double) (z * t)))) <= ((double) -(((double) INFINITY))))) {
VAR = ((double) (((double) (((double) (((double) cbrt(x)) * ((double) cbrt(x)))) * ((double) (((double) cbrt(x)) * (y / a))))) - ((double) (z * (t / a)))));
} else {
double VAR_1;
if ((((double) (((double) (x * y)) - ((double) (z * t)))) <= 9.781667072520984e+296)) {
VAR_1 = (((double) (((double) (x * y)) - ((double) (z * t)))) / a);
} else {
VAR_1 = ((double) (((double) (x * (y / a))) - ((double) (((double) cbrt(((double) (z * (t / a))))) * ((double) (((double) cbrt(((double) (z * (t / a))))) * ((double) cbrt(((double) (z * (t / a)))))))))));
}
VAR = VAR_1;
}
return VAR;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a
Results
| Original | 7.8 |
|---|---|
| Target | 5.7 |
| Herbie | 0.8 |
if (- (* x y) (* z t)) < -inf.0Initial program 64.0
rmApplied div-sub64.0
Simplified31.5
Simplified0.2
rmApplied add-cube-cbrt0.8
Applied associate-*l*0.8
Simplified0.8
if -inf.0 < (- (* x y) (* z t)) < 9.78166707252098428e296Initial program 0.8
if 9.78166707252098428e296 < (- (* x y) (* z t)) Initial program 59.4
rmApplied div-sub59.4
Simplified31.2
Simplified0.3
rmApplied add-cube-cbrt0.8
Final simplification0.8
herbie shell --seed 2020196
(FPCore (x y z t a)
:name "Data.Colour.Matrix:inverse from colour-2.3.3, B"
:precision binary64
:herbie-target
(if (< z -2.468684968699548e+170) (- (* (/ y a) x) (* (/ t a) z)) (if (< z 6.309831121978371e-71) (/ (- (* x y) (* z t)) a) (- (* (/ y a) x) (* (/ t a) z))))
(/ (- (* x y) (* z t)) a))