\frac{r \cdot \sin b}{\cos \left(a + b\right)}
\begin{array}{l}
t_0 := \sin b \cdot \sin a\\
\frac{r \cdot \sin b}{\mathsf{fma}\left(\cos a, \cos b, -t_0\right) + \mathsf{fma}\left(-\sin a, \sin b, t_0\right)}
\end{array}
(FPCore (r a b) :precision binary64 (/ (* r (sin b)) (cos (+ a b))))
(FPCore (r a b)
:precision binary64
(let* ((t_0 (* (sin b) (sin a))))
(/
(* r (sin b))
(+ (fma (cos a) (cos b) (- t_0)) (fma (- (sin a)) (sin b) t_0)))))double code(double r, double a, double b) {
return (r * sin(b)) / cos(a + b);
}
double code(double r, double a, double b) {
double t_0 = sin(b) * sin(a);
return (r * sin(b)) / (fma(cos(a), cos(b), -t_0) + fma(-sin(a), sin(b), t_0));
}



Bits error versus r



Bits error versus a



Bits error versus b
Initial program 15.1
Applied cos-sum_binary640.3
Applied *-un-lft-identity_binary640.3
Applied times-frac_binary640.3
Simplified0.3
Simplified0.3
Applied associate-*r/_binary640.3
Applied prod-diff_binary640.3
Final simplification0.3
herbie shell --seed 2022104
(FPCore (r a b)
:name "rsin A"
:precision binary64
(/ (* r (sin b)) (cos (+ a b))))