Average Error: 0 → 0
Time: 1.1s
Precision: 64
\[\tan^{-1}_* \frac{im}{re}\]
\[\tan^{-1}_* \frac{im}{re}\]
\tan^{-1}_* \frac{im}{re}
\tan^{-1}_* \frac{im}{re}
double f(double re, double im) {
        double r26855 = im;
        double r26856 = re;
        double r26857 = atan2(r26855, r26856);
        return r26857;
}

double f(double re, double im) {
        double r26858 = im;
        double r26859 = re;
        double r26860 = atan2(r26858, r26859);
        return r26860;
}

Error

Bits error versus re

Bits error versus im

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0

    \[\tan^{-1}_* \frac{im}{re}\]
  2. Final simplification0

    \[\leadsto \tan^{-1}_* \frac{im}{re}\]

Reproduce

herbie shell --seed 2019323 +o rules:numerics
(FPCore (re im)
  :name "math.arg on complex"
  :precision binary64
  (atan2 im re))