\frac{a1 \cdot a2}{b1 \cdot b2}\begin{array}{l}
\mathbf{if}\;\frac{a1 \cdot a2}{b1 \cdot b2} \le -3.949560208634886 \cdot 10^{-267}:\\
\;\;\;\;\frac{a1 \cdot a2}{b1 \cdot b2}\\
\mathbf{elif}\;\frac{a1 \cdot a2}{b1 \cdot b2} \le 0.0:\\
\;\;\;\;\frac{\frac{a1}{\frac{b2}{a2}}}{b1}\\
\mathbf{elif}\;\frac{a1 \cdot a2}{b1 \cdot b2} \le 1.46049949258473444 \cdot 10^{301}:\\
\;\;\;\;\frac{a1 \cdot a2}{b1 \cdot b2}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{a1}{\sqrt[3]{b1} \cdot \sqrt[3]{b1}} \cdot \frac{a2}{\sqrt[3]{b1}}}{b2}\\
\end{array}double f(double a1, double a2, double b1, double b2) {
double r143973 = a1;
double r143974 = a2;
double r143975 = r143973 * r143974;
double r143976 = b1;
double r143977 = b2;
double r143978 = r143976 * r143977;
double r143979 = r143975 / r143978;
return r143979;
}
double f(double a1, double a2, double b1, double b2) {
double r143980 = a1;
double r143981 = a2;
double r143982 = r143980 * r143981;
double r143983 = b1;
double r143984 = b2;
double r143985 = r143983 * r143984;
double r143986 = r143982 / r143985;
double r143987 = -3.949560208634886e-267;
bool r143988 = r143986 <= r143987;
double r143989 = 0.0;
bool r143990 = r143986 <= r143989;
double r143991 = r143984 / r143981;
double r143992 = r143980 / r143991;
double r143993 = r143992 / r143983;
double r143994 = 1.4604994925847344e+301;
bool r143995 = r143986 <= r143994;
double r143996 = cbrt(r143983);
double r143997 = r143996 * r143996;
double r143998 = r143980 / r143997;
double r143999 = r143981 / r143996;
double r144000 = r143998 * r143999;
double r144001 = r144000 / r143984;
double r144002 = r143995 ? r143986 : r144001;
double r144003 = r143990 ? r143993 : r144002;
double r144004 = r143988 ? r143986 : r144003;
return r144004;
}




Bits error versus a1




Bits error versus a2




Bits error versus b1




Bits error versus b2
Results
| Original | 11.1 |
|---|---|
| Target | 11.2 |
| Herbie | 5.2 |
if (/ (* a1 a2) (* b1 b2)) < -3.949560208634886e-267 or 0.0 < (/ (* a1 a2) (* b1 b2)) < 1.4604994925847344e+301Initial program 4.5
rmApplied associate-/r*9.4
rmApplied clear-num9.6
rmApplied associate-/r/9.8
Applied associate-/r*9.9
Simplified9.5
Taylor expanded around 0 4.5
if -3.949560208634886e-267 < (/ (* a1 a2) (* b1 b2)) < 0.0Initial program 12.1
rmApplied associate-/r*6.8
rmApplied clear-num7.3
rmApplied associate-/r/7.3
Applied associate-/r*6.8
Simplified6.8
rmApplied associate-/l*4.5
if 1.4604994925847344e+301 < (/ (* a1 a2) (* b1 b2)) Initial program 62.4
rmApplied associate-/r*48.4
rmApplied add-cube-cbrt48.6
Applied times-frac14.1
Final simplification5.2
herbie shell --seed 2020062
(FPCore (a1 a2 b1 b2)
:name "Quotient of products"
:precision binary64
:herbie-target
(* (/ a1 b1) (/ a2 b2))
(/ (* a1 a2) (* b1 b2)))