\[\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}\]
Test:
math.log10 on complex, imaginary part
Bits:
128 bits
Bits error versus re
Bits error versus im
Time: 3.7 s
Input Error: 0.8
Output Error: 0.5
Log:
Profile: 🕒
\(\log_* (1 + \log_* (1 + (e^{(e^{\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}} - 1)^*} - 1)^*))\)
  1. Started with
    \[\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}\]
    0.8
  2. Using strategy rm
    0.8
  3. Applied log1p-expm1-u to get
    \[\color{red}{\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}} \leadsto \color{blue}{\log_* (1 + (e^{\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}} - 1)^*)}\]
    0.7
  4. Using strategy rm
    0.7
  5. Applied log1p-expm1-u to get
    \[\log_* (1 + \color{red}{(e^{\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}} - 1)^*}) \leadsto \log_* (1 + \color{blue}{\log_* (1 + (e^{(e^{\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}} - 1)^*} - 1)^*)})\]
    0.5

  6. Removed slow pow expressions

Original test:


(lambda ((re default) (im default))
  #:name "math.log10 on complex, imaginary part"
  (/ (atan2 im re) (log 10)))