\frac{r \cdot \sin b}{\cos \left(a + b\right)}\left(r \cdot \sin b\right) \cdot \frac{-1}{\mathsf{fma}\left(-\cos b, \cos a, \sin a \cdot \sin b\right)}double f(double r, double a, double b) {
double r25533 = r;
double r25534 = b;
double r25535 = sin(r25534);
double r25536 = r25533 * r25535;
double r25537 = a;
double r25538 = r25537 + r25534;
double r25539 = cos(r25538);
double r25540 = r25536 / r25539;
return r25540;
}
double f(double r, double a, double b) {
double r25541 = r;
double r25542 = b;
double r25543 = sin(r25542);
double r25544 = r25541 * r25543;
double r25545 = -1.0;
double r25546 = cos(r25542);
double r25547 = -r25546;
double r25548 = a;
double r25549 = cos(r25548);
double r25550 = sin(r25548);
double r25551 = r25550 * r25543;
double r25552 = fma(r25547, r25549, r25551);
double r25553 = r25545 / r25552;
double r25554 = r25544 * r25553;
return r25554;
}



Bits error versus r



Bits error versus a



Bits error versus b
Initial program 15.5
rmApplied cos-sum0.3
rmApplied *-un-lft-identity0.3
Applied times-frac0.3
Simplified0.3
rmApplied frac-2neg0.3
Simplified0.3
rmApplied div-inv0.4
Applied associate-*r*0.4
Simplified0.4
Final simplification0.4
herbie shell --seed 2019322 +o rules:numerics
(FPCore (r a b)
:name "r*sin(b)/cos(a+b), A"
:precision binary64
(/ (* r (sin b)) (cos (+ a b))))