# How to evaluate integrals with infinite limits

I am trying to evaluate the integral: $$\int_0^\infty\frac{dx}{4x^2+4x+5}$$ However, the upper limit of infinity is causing me some confusion (I have never encountered infinity in a definite integral before).

I want to use the substitution $x+\frac{1}{2} = \tan\theta$, so that the integral (ignoring limits) becomes: $$\int\frac{dx}{4(x+\frac{1}{2})^2+4} = \int\frac{\sec^2\theta}{4(\tan^2\theta+1)} d\theta = \int\frac{1}{4} d\theta = \frac{\theta}{4} + c$$

However, I am unsure how to change limits. I can manage the lower one: $x = 0 \implies \theta = \arctan(\frac{1}{2})$. But for infinity, I don't know what to do. It seems to me that $\tan\theta = \infty$ has an infinite number of solutions ($\theta = \pm\frac{\pi}{2}, \pm\frac{3\pi}{2}, \pm\frac{5\pi}{2},...$), what does the upper limit become?

## 3 Answers

Please have a short look at the theorem for Substitution for single variable

I think your problem stems from the idea that your transformation function $\phi = \tan: \mathbb{R} \rightarrow \mathbb{R}$

However $\phi$ should be defined on some interval $I$ where it is differentiable. $\tan$ is not differentiable on whole $\mathbb{R}$ - it is if you choose just one section e.g. $(-0.5\pi, 0.5\pi)$

Hint. If one performs the change of variable $$\theta=\arctan \left(x+\frac12\right)$$ then $$\theta(0)=\arctan \left(\frac12\right), \qquad \theta(\infty)=\arctan \left(\infty\right)=\frac{\pi}2,$$ and, as wanted, $$x+\frac{1}{2} = \tan\theta,\qquad dx=\sec^2 \theta\:d\theta.$$

Remark. We have made the change of variable $$\theta=\arctan \left(x+\frac12\right)$$ rather than $$x+\frac{1}{2} = \tan\theta.$$

• The OP's question is not the change of variable. That was done correctly, the problem was to justify the choice of the upper limit. This does not answer that question. – Gregory Aug 23 '17 at 14:36
• @Gregory Please I invite you to read correctly my answer. – Olivier Oloa Aug 23 '17 at 14:37
• My understanding of arctan(x) is that it chooses the value closest to zero - as π/2 and -π/2 are equidistant from 0, why do we choose the positive value? It seems to me that choosing -π/2 is equally valid, but would yield a different result. – Adam Aug 23 '17 at 14:49
• @Adam That's not the standard understanding. We have $$y={\arctan}\ x\iff\tan x=y\text{ et }y\in\left]-\frac{\pi}2,\frac{\pi}2\right[,$$see for example the table here: en.wikipedia.org/wiki/Inverse_function#Generalizations – Olivier Oloa Aug 23 '17 at 15:23
• @OlivierOloa Ah, okay then. In that case, I must just be remembering a technically inexact mnemonic or simplification that I was taught in school. – Adam Aug 23 '17 at 16:28

By definition: $\int_0^\infty\frac{dx}{4x^2+4x+5}=\lim_{t \to \infty}\int_0^t\frac{dx}{4x^2+4x+5}$ , if this limit exists.