\frac{\left(\frac{\left(x.re \cdot y.re\right)}{\left(x.im \cdot y.im\right)}\right)}{\left(\frac{\left(y.re \cdot y.re\right)}{\left(y.im \cdot y.im\right)}\right)}\frac{\left(\mathsf{qma}\left(\left(\left(x.re \cdot y.re\right)\right), x.im, y.im\right)\right)}{\left(\mathsf{qma}\left(\left(\left(y.re \cdot y.re\right)\right), y.im, y.im\right)\right)}double f(double x_re, double x_im, double y_re, double y_im) {
double r542705 = x_re;
double r542706 = y_re;
double r542707 = r542705 * r542706;
double r542708 = x_im;
double r542709 = y_im;
double r542710 = r542708 * r542709;
double r542711 = r542707 + r542710;
double r542712 = r542706 * r542706;
double r542713 = r542709 * r542709;
double r542714 = r542712 + r542713;
double r542715 = r542711 / r542714;
return r542715;
}
double f(double x_re, double x_im, double y_re, double y_im) {
double r542716 = x_re;
double r542717 = y_re;
double r542718 = r542716 * r542717;
double r542719 = /*Error: no posit support in C */;
double r542720 = x_im;
double r542721 = y_im;
double r542722 = /*Error: no posit support in C */;
double r542723 = /*Error: no posit support in C */;
double r542724 = r542717 * r542717;
double r542725 = /*Error: no posit support in C */;
double r542726 = /*Error: no posit support in C */;
double r542727 = /*Error: no posit support in C */;
double r542728 = r542723 / r542727;
return r542728;
}



Bits error versus x.re



Bits error versus x.im



Bits error versus y.re



Bits error versus y.im
Initial program 1.1
rmApplied introduce-quire1.1
Applied insert-quire-fdp-add1.1
rmApplied introduce-quire1.1
Applied insert-quire-fdp-add1.0
Final simplification1.0
herbie shell --seed 2019154 +o rules:numerics
(FPCore (x.re x.im y.re y.im)
:name "_divideComplex, real part"
(/.p16 (+.p16 (*.p16 x.re y.re) (*.p16 x.im y.im)) (+.p16 (*.p16 y.re y.re) (*.p16 y.im y.im))))