\frac{\tan^{-1}_* \frac{im}{re}}{\log 10}\tan^{-1}_* \frac{im}{re} \cdot \frac{\sqrt{\frac{1}{\log 10}}}{\sqrt{\log 10}}(FPCore (re im) :precision binary64 (/ (atan2 im re) (log 10.0)))
(FPCore (re im) :precision binary64 (* (atan2 im re) (/ (sqrt (/ 1.0 (log 10.0))) (sqrt (log 10.0)))))
double code(double re, double im) {
return atan2(im, re) / log(10.0);
}
double code(double re, double im) {
return atan2(im, re) * (sqrt(1.0 / log(10.0)) / sqrt(log(10.0)));
}



Bits error versus re



Bits error versus im
Results
Initial program 0.9
rmApplied add-sqr-sqrt_binary64_1000.9
Applied *-un-lft-identity_binary64_780.9
Applied times-frac_binary64_840.8
Taylor expanded around 0 0.8
Simplified0.8
rmApplied associate-*l/_binary64_210.8
Simplified0.8
rmApplied pow1_binary64_1390.8
Applied log-pow_binary64_1670.8
Applied sqrt-prod_binary64_940.8
Applied times-frac_binary64_840.8
Final simplification0.8
herbie shell --seed 2021024
(FPCore (re im)
:name "math.log10 on complex, imaginary part"
:precision binary64
(/ (atan2 im re) (log 10.0)))