\[\left(-x \cdot \cot B\right) + \frac{1}{\sin B}\]
Test:
VandenBroeck and Keller, Equation (24)
Bits:
128 bits
Bits error versus B
Bits error versus x
Time: 5.2 s
Input Error: 0.2
Output Error: 0.2
Log:
Profile: 🕒
\(\frac{-x}{\tan B} + \frac{1}{\sin B}\)
  1. Started with
    \[\left(-x \cdot \cot B\right) + \frac{1}{\sin B}\]
    0.2
  2. Applied simplify to get
    \[\color{red}{\left(-x \cdot \cot B\right) + \frac{1}{\sin B}} \leadsto \color{blue}{(x * \left(-\cot B\right) + \left(\frac{1}{\sin B}\right))_*}\]
    0.2
  3. Using strategy rm
    0.2
  4. Applied fma-udef to get
    \[\color{red}{(x * \left(-\cot B\right) + \left(\frac{1}{\sin B}\right))_*} \leadsto \color{blue}{x \cdot \left(-\cot B\right) + \frac{1}{\sin B}}\]
    0.2
  5. Using strategy rm
    0.2
  6. Applied cotan-tan to get
    \[x \cdot \left(-\color{red}{\cot B}\right) + \frac{1}{\sin B} \leadsto x \cdot \left(-\color{blue}{\frac{1}{\tan B}}\right) + \frac{1}{\sin B}\]
    0.2
  7. Applied distribute-neg-frac to get
    \[x \cdot \color{red}{\left(-\frac{1}{\tan B}\right)} + \frac{1}{\sin B} \leadsto x \cdot \color{blue}{\frac{-1}{\tan B}} + \frac{1}{\sin B}\]
    0.2
  8. Applied associate-*r/ to get
    \[\color{red}{x \cdot \frac{-1}{\tan B}} + \frac{1}{\sin B} \leadsto \color{blue}{\frac{x \cdot \left(-1\right)}{\tan B}} + \frac{1}{\sin B}\]
    0.2
  9. Applied simplify to get
    \[\frac{\color{red}{x \cdot \left(-1\right)}}{\tan B} + \frac{1}{\sin B} \leadsto \frac{\color{blue}{-x}}{\tan B} + \frac{1}{\sin B}\]
    0.2

Original test:


(lambda ((B default) (x default))
  #:name "VandenBroeck and Keller, Equation (24)"
  (+ (- (* x (cotan B))) (/ 1 (sin B))))