Average Error: 31.5 → 0.5
Time: 19.2s
Precision: 64
Internal Precision: 384
\[\frac{\tan^{-1}_* \frac{im}{re} \cdot \log base - \log \left(\sqrt{re \cdot re + im \cdot im}\right) \cdot 0}{\log base \cdot \log base + 0 \cdot 0}\]
\[\frac{1}{\frac{\log base}{\tan^{-1}_* \frac{im}{re} - 0}}\]

Error

Bits error versus re

Bits error versus im

Bits error versus base

Derivation

  1. Initial program 31.5

    \[\frac{\tan^{-1}_* \frac{im}{re} \cdot \log base - \log \left(\sqrt{re \cdot re + im \cdot im}\right) \cdot 0}{\log base \cdot \log base + 0 \cdot 0}\]
  2. Applied simplify0.3

    \[\leadsto \color{blue}{\frac{\tan^{-1}_* \frac{im}{re} - 0}{\log base}}\]
  3. Using strategy rm
  4. Applied clear-num0.5

    \[\leadsto \color{blue}{\frac{1}{\frac{\log base}{\tan^{-1}_* \frac{im}{re} - 0}}}\]

Runtime

Time bar (total: 19.2s)Debug logProfile

herbie shell --seed '#(1070227846 1561819246 480764335 4016816270 2602869839 2117310382)' +o rules:numerics
(FPCore (re im base)
  :name "math.log/2 on complex, imaginary part"
  (/ (- (* (atan2 im re) (log base)) (* (log (sqrt (+ (* re re) (* im im)))) 0)) (+ (* (log base) (log base)) (* 0 0))))