\left(-x \cdot \frac{1}{\tan B}\right) + \frac{1}{\sin B}\mathsf{fma}\left(\frac{x \cdot 1}{\sin B}, -\cos B, \frac{1}{\sin B}\right)double f(double B, double x) {
double r36765 = x;
double r36766 = 1.0;
double r36767 = B;
double r36768 = tan(r36767);
double r36769 = r36766 / r36768;
double r36770 = r36765 * r36769;
double r36771 = -r36770;
double r36772 = sin(r36767);
double r36773 = r36766 / r36772;
double r36774 = r36771 + r36773;
return r36774;
}
double f(double B, double x) {
double r36775 = x;
double r36776 = 1.0;
double r36777 = r36775 * r36776;
double r36778 = B;
double r36779 = sin(r36778);
double r36780 = r36777 / r36779;
double r36781 = cos(r36778);
double r36782 = -r36781;
double r36783 = r36776 / r36779;
double r36784 = fma(r36780, r36782, r36783);
return r36784;
}



Bits error versus B



Bits error versus x
Initial program 0.2
rmApplied associate-*r/0.2
rmApplied tan-quot0.2
Applied associate-/r/0.2
Applied distribute-rgt-neg-in0.2
Applied fma-def0.2
Final simplification0.2
herbie shell --seed 2019346 +o rules:numerics
(FPCore (B x)
:name "VandenBroeck and Keller, Equation (24)"
:precision binary64
(+ (- (* x (/ 1 (tan B)))) (/ 1 (sin B))))