Average Error: 31.4 → 0.3
Time: 19.6s
Precision: 64
Ground Truth: 128
\[\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{\tan^{-1}_* \frac{im}{re}}{\log base} - 0\]

Error

Bits error versus re

Bits error versus im

Bits error versus base

Derivation

  1. Initial program 31.4

    \[\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 simplify 0.3

    \[\leadsto \color{blue}{\frac{\tan^{-1}_* \frac{im}{re}}{\log base} - 0}\]
  3. Removed slow pow expressions

Runtime

Total time: 19.6s Debug log

Please include this information when filing a bug report:

herbie --seed '#(616873541 1226626272 739434360 3707127916 2847377863 1425237259)'
(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))))