people. I have a question regarding the following improper integral, and others like it: $$\int_{-\infty}^\infty \frac{dx}{1+x^2}$$ The end result of that are the two limits: $$\lim_{a\to -\infty} \big(\arctan(0)-\arctan(a)\big)$$ and $$\lim_{b\to \infty} \big(\arctan(b)-\arctan(0)\big)$$ Now, $\arctan(-\infty)$ is $\frac{3\pi}{2}$ and $\arctan(\infty)$ is $\frac{\pi}{2}$.
Applying those values to the formula would give a result of $-\pi$, but that makes no sense. In this particular case, the issue is resolved by rewriting $\frac{3\pi}{2}$ as $-\frac{\pi}{2}$.
My question is, is there a rule of thumb to picking radian values when dealing with integrals like this one or do simply pick whatever fits the specific problem to avoid ending up with a negative end value?