# Why is the range of arctan $[ -\frac{\pi}{2} , \frac{\pi}{2}]$?

I've been taught in school and it says on Wikipedia that the range of arctan is $[ -\frac{\pi}{2} , \frac{\pi}{2} ]$.

Why isn't it $[0,\pi]$ ?

-
It's a convention. It's nice to have $\arctan(-x) = -\arctan x$ but really $\arctan$ shouldn't take real number values at all; it should take values in the unit circle (en.wikipedia.org/wiki/Unit_circle). – Qiaochu Yuan Jun 11 '12 at 2:46
Wikipedia correctly gives the range as $\left(-\frac{\pi}2,\frac{\pi}2\right)$, not $\left[-\frac{\pi}2,\frac{\pi}2\right]$, and I certainly hope that that’s also what you were taught: $\frac{\pi}2$ and $-\frac{\pi}2$ are definitely not in the range of the arctangent function. – Brian M. Scott Jun 11 '12 at 10:01

As the graph of the function $\,\tan x\,$ show, this is a very not $\,1-1\,$ function onto the reals, so just as it's done with $\,\sin x\,,\,\cos x\,$ we limit its range in order to get a $\,1-1\,$ onto, and thus invertible, function. As the period of $\,\tan x\,$ is $\,\pi\,$ , we can take any interval of length $\,\pi\,$ to do this...but...if the interval contains a point of the form $\,\displaystyle{x=\frac{(2n+1)\pi}{2}}\,n\in\mathbb{Z}$ we're going to have an ugly vertical asympote there, so we choose an interval of the form $$\left(\frac{(2n-1)\pi}{2}\,,\,\frac{(2n+1)\pi}{2}\right)\,\,,\,n\in\mathbb{Z}$$withy $\,n=0\,$ being customary.
It's simpler because it makes the function continuous. In a sense, arctan is a "multiple-valued function" (but the prevailing modern definitions of function consider such things to be something other than functions). I.e., there is more than one number whose tangent is $x$. So which one do you call $\arctan x$? The answer is, in a sense: the simplest one.
Draw a right triangle showing sides suitably labeled "adj", "opp", and "hyp". Recall that tan = opp/adj. Let adj = 1, so that tan = opp. As opp goes up to $\infty$, look at what happens to the angle: you see it going up to a right angle, i.e. to $\pi/2$. Now look at what happens as "opp" becomes negative, and then goes down to $-\infty$, and watch the angle going down to $-\pi/2$.