6
$\begingroup$

I would like to know if there is reasonably fast converging method for computing large arguments of arctan.

Until now I've came across Taylor series that converges only on interval $(-1,1)$ and for increasing $|x|$ the rate decreases. Also I've found about continued fractions for arctan, which seems to converge more rapidly and can be used for any real number, but again with increasing $|x|$ I need to perform way too much iterations until I get at least 3 digits precision.

I'm therefore looking for a method that would allow me to compute arctan for large arguments with good precision and in reasonable amount of iterations.

  • 0
    I wonder if this works: expand sine and cosine in Taylor series at $\pi/2$; divide to get an expansion for tangent; invert to get an expansion for arctangent.2012-10-06

1 Answers 1

24

Why don't you consider that $ \arctan x + \arctan \frac{1}{x}=\frac{\pi}{2}, $ so that, for large values of $x>0$, $ \arctan x = \frac{\pi}{2}-\arctan {1 \over x} = \frac{\pi}{2}-\frac{1}{x}+\frac{1}{3x^3}-\frac{1}{5x^5} +\ldots ? $ See also this discussion.

  • 0
    Thanks! I forgot about this law.. elegant and easy2012-10-06