Express arccos in terms of arctan I'm trying to express $\arccos(x)$ in terms of $\arctan$ because the software I'm using only recognizes $\arctan$.
I know that $\arcsin(x)+\arccos(x)=\frac{\pi}{2}$
and $\arcsin(x)=2\arctan\left(\frac{x}{1+\sqrt{1-x^2}}\right)$.
Does that mean that $\arccos(x)=\frac{\pi}{2}-2\arctan\left(\frac{x}{1+\sqrt{1-x^2}}\right)$?

$y = \arccos x\\
\cos y = x\\
\sec^2 y = \frac {1}{x^2}\\
\tan^2 y + 1 = \frac {1}{x^2}\\
\tan y  = \sqrt {\frac {1}{x^2} - 1} = \frac {\sqrt {1-x^2}}{x}\\
\arccos x = \arctan \frac {\sqrt{1-x^2}}{x}$
Except the range of $\arccos x$ will be $[0, \pi]$ and the range of $\arctan x$ is $(-\frac {\pi}{2}, \frac{\pi}{2})$ if that is relavant you may need to play some games if $x<0$
