\frac{x \cdot y - z \cdot t}{a}\begin{array}{l}
\mathbf{if}\;x \cdot y - z \cdot t \le -1.337162358091865 \cdot 10^{282}:\\
\;\;\;\;x \cdot \frac{y}{a} - z \cdot \frac{t}{{\left(\sqrt[3]{a}\right)}^{3}}\\
\mathbf{elif}\;x \cdot y - z \cdot t \le -2.5522379957491985 \cdot 10^{-254}:\\
\;\;\;\;\frac{x \cdot y}{a} - \frac{t \cdot z}{a}\\
\mathbf{elif}\;x \cdot y - z \cdot t \le 0.0:\\
\;\;\;\;x \cdot \frac{y}{a} - \frac{z}{\sqrt[3]{a} \cdot \sqrt[3]{a}} \cdot \frac{t}{\left(\sqrt[3]{\sqrt[3]{a}} \cdot \sqrt[3]{\sqrt[3]{a}}\right) \cdot \sqrt[3]{\sqrt[3]{a}}}\\
\mathbf{elif}\;x \cdot y - z \cdot t \le 6.9748358176334352 \cdot 10^{251}:\\
\;\;\;\;\frac{1}{a} \cdot \left(x \cdot y - z \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{y}{a} - z \cdot \frac{t}{{\left(\sqrt[3]{a}\right)}^{3}}\\
\end{array}double f(double x, double y, double z, double t, double a) {
double r1467832 = x;
double r1467833 = y;
double r1467834 = r1467832 * r1467833;
double r1467835 = z;
double r1467836 = t;
double r1467837 = r1467835 * r1467836;
double r1467838 = r1467834 - r1467837;
double r1467839 = a;
double r1467840 = r1467838 / r1467839;
return r1467840;
}
double f(double x, double y, double z, double t, double a) {
double r1467841 = x;
double r1467842 = y;
double r1467843 = r1467841 * r1467842;
double r1467844 = z;
double r1467845 = t;
double r1467846 = r1467844 * r1467845;
double r1467847 = r1467843 - r1467846;
double r1467848 = -1.337162358091865e+282;
bool r1467849 = r1467847 <= r1467848;
double r1467850 = a;
double r1467851 = r1467842 / r1467850;
double r1467852 = r1467841 * r1467851;
double r1467853 = cbrt(r1467850);
double r1467854 = 3.0;
double r1467855 = pow(r1467853, r1467854);
double r1467856 = r1467845 / r1467855;
double r1467857 = r1467844 * r1467856;
double r1467858 = r1467852 - r1467857;
double r1467859 = -2.5522379957491985e-254;
bool r1467860 = r1467847 <= r1467859;
double r1467861 = r1467843 / r1467850;
double r1467862 = r1467845 * r1467844;
double r1467863 = r1467862 / r1467850;
double r1467864 = r1467861 - r1467863;
double r1467865 = 0.0;
bool r1467866 = r1467847 <= r1467865;
double r1467867 = r1467853 * r1467853;
double r1467868 = r1467844 / r1467867;
double r1467869 = cbrt(r1467853);
double r1467870 = r1467869 * r1467869;
double r1467871 = r1467870 * r1467869;
double r1467872 = r1467845 / r1467871;
double r1467873 = r1467868 * r1467872;
double r1467874 = r1467852 - r1467873;
double r1467875 = 6.974835817633435e+251;
bool r1467876 = r1467847 <= r1467875;
double r1467877 = 1.0;
double r1467878 = r1467877 / r1467850;
double r1467879 = r1467878 * r1467847;
double r1467880 = r1467876 ? r1467879 : r1467858;
double r1467881 = r1467866 ? r1467874 : r1467880;
double r1467882 = r1467860 ? r1467864 : r1467881;
double r1467883 = r1467849 ? r1467858 : r1467882;
return r1467883;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a
Results
| Original | 7.9 |
|---|---|
| Target | 6.0 |
| Herbie | 0.4 |
if (- (* x y) (* z t)) < -1.337162358091865e+282 or 6.974835817633435e+251 < (- (* x y) (* z t)) Initial program 45.2
rmApplied div-sub45.2
rmApplied add-cube-cbrt45.4
Applied times-frac23.6
rmApplied *-un-lft-identity23.6
Applied times-frac0.8
Simplified0.8
rmApplied div-inv0.8
Applied associate-*l*0.8
Simplified0.8
if -1.337162358091865e+282 < (- (* x y) (* z t)) < -2.5522379957491985e-254Initial program 0.2
rmApplied div-sub0.2
rmApplied add-cube-cbrt0.8
Applied times-frac4.0
Taylor expanded around 0 0.2
if -2.5522379957491985e-254 < (- (* x y) (* z t)) < 0.0Initial program 18.0
rmApplied div-sub18.0
rmApplied add-cube-cbrt18.1
Applied times-frac9.8
rmApplied *-un-lft-identity9.8
Applied times-frac0.6
Simplified0.6
rmApplied add-cube-cbrt0.7
if 0.0 < (- (* x y) (* z t)) < 6.974835817633435e+251Initial program 0.3
rmApplied div-sub0.3
rmApplied div-inv0.4
Applied div-inv0.4
Applied distribute-rgt-out--0.4
Final simplification0.4
herbie shell --seed 2020047
(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))