Skip to main content

Section 4.2 Comparison Test for Integrals

While the value of an improper integral may be hard to pin down, its convergence is often much easier to decide by comparing the integral with another improper integral whose convergence is known.
We begin with an observation: if the graph of \(f\) never dips below the \(x\)-axis on the interval \([a,b]\text{,}\) the area bounded between the graph of \(f\) and the \(x\)-axis cannot be negative (it can be zero though). Hence,
Consequently, if \(f \le g\) on \([a,b]\text{,}\) then \(g-f \ge 0\) (which is also integrable) on \([a,b]\) and so
\begin{equation*} 0 \le \int_a^b g(x)-f(x) dx = \int_a^b g(x)dx - \int_a^b f(x)dx. \end{equation*}
That is, \(\int_a^b f(x)dx \le \int_a^b g(x)dx\text{.}\) Note also that if \(f \ge 0\text{,}\) the function \(A(t) = \int_a^t f(x)dx\) is an increasing function of \(t\text{.}\) Therefore, if \(A(t)\) is bounded above on \([a,\infty)\text{,}\) then \(\int_a^{\infty} f(x)dx = \lim_{t\to \infty} \int_a^t f(x)dx\) exists. From this we conclude that
The same results hold for improper integrals with bounded domain of integration (see Exercise 4.3.1).
Let \(f\) be a function on \([a,\infty)\) such that \(\int_a^b f(x)dx\) exists for every \(b \ge a\text{.}\) So, the improper integrals \(\int_a^{\infty} f(x)dx\) and \(\int_b^{\infty} f(x)dx\) either both converge, in that case their values differ by the value of the integral \(\int_a^b f(x) dx\text{,}\) or both diverge. Consequently, when deciding convergence of the improper integral \(\int_a^{\infty} f(x)dx\) one only needs to focus on the eventual behavior of \(f(x)\text{.}\) We say that a function \(f\) is eventually positive (resp. eventually negative), if there exists some real number \(a\) such that \(f(x) \gt 0\) (resp. \(f(x) \lt 0\)) for all \(x \in [a,\infty)\text{.}\) A polynomial (strictly speaking the function defined by a polynomial on the real line) eventually has the same sign as its leading term.
Now let us put the comparison test into action.

Example 4.12.

Consider the improper integral \(\int_0^{\infty} \frac{1}{1+ x^3} dx\text{.}\) Since
\begin{equation*} \int_1^{\infty} \frac{1}{1+x^3} dx \lt \int_1^{\infty} \frac{1}{x^3} dx \end{equation*}
and the last integral converges according to the p-test, it follows from the comparison test for improper integrals Proposition 4.11 that \(\int_1^{\infty} \frac{1}{1+x^3} dx\) converges. And hence so is the improper integral \(\int_0^{\infty} \frac{1}{1+x^3} dx\text{.}\) Also follows from this observation is the following simple-minded estimation of the integral:
\begin{equation*} \int_0^{\infty} \frac{1}{1+x^3} \le \int_0^1 \frac{1}{1+x^3} dx + \int_1^{\infty} \frac{1}{x^3} dx \lt 1 + \frac{1}{2} = \frac{3}{2}. \end{equation*}

Checkpoint 4.13.

Show that
\begin{equation*} \int_1^{\infty} \frac{\cos^2(x)}{1+x^2} dx \le \frac{\pi}{4} \end{equation*}
Solution.
Since \(0 \le \cos^2(x) \le 1\text{,}\) \(0 \le \frac{\cos^2(x)}{1+x^2} \le \frac{1}{1+x^2}\text{,}\) it follows from the comparison test for integrals that
\begin{align*} 0 & \le \int_1^{t} \frac{\cos^2(x)}{1+x^2}dx \le \int_1^{t} \frac{1}{1+x^2}dx \\ & = \arctan(t)-\frac{\pi}{4} \end{align*}
which tends to \(\pi/2 - \pi/4 = \pi/4\) as \(t\) tends to \(\infty\text{.}\) This establishes the inequality.
Let \(f(x)\) and \(g(x)\) be eventually positive functions. Suppose the there exist positive constants \(\alpha\) and \(\beta\) such that for all sufficiently large \(x\text{,}\)
\begin{equation*} \alpha g(x) \le f(x) \le \beta g(x). \end{equation*}
Then we say that \(f(x)\) is big-theta of \(g(x)\) (written as \(f(x) = \Theta(g(x))\text{.}\) Note that the above inequalities are equivalent to
\begin{equation*} (1/\beta) f(x) \le g(x) \le (1/\alpha) f(x). \end{equation*}
So \(f(x) = \Theta(g(x))\) if and only if \(g(x) = \Theta(f(x))\text{.}\)
If \(f(x) = \Theta(g(x))\text{,}\) then according to the comparison test for improper integrals Proposition 4.11, \(\ds \int_a^{\infty} f(x) dx\) converges if and only if \(\ds \int_a^{\infty} g(x) dx\) converges. We say that \(f\) is asymptotic to \(g\text{,}\) written as \(f \sim g\text{,}\) if
\begin{equation*} \lim_{x \to \infty} \frac{f(x)}{g(x)} = 1. \end{equation*}
Note that if \(f\sim g\text{,}\) then for all sufficient large \(x\text{,}\)
\begin{equation*} \frac{1}{2} \lt \frac{f(x)}{g(x)} \lt \frac{3}{2}. \end{equation*}
Therefore, \(f(x) = \Theta(g(x))\) for \(f \sim g\text{.}\)
It is plain to see that a polynomial with positive leading coefficient is asymptotic to its leading term. Combining this observation with the p-test, we can decide the convergence of \(\ds \int_a^{\infty} R(x) dx \) where \(R(x)\) is a rational function.

Example 4.14.

Consider the improper integral \(\int_1^\infty \frac{-2x+1}{x^3-x+1} dx.\) It has the same convergence as the integral \(\int_1^\infty \frac{2x-1}{x^3-x+1} dx\text{.}\) Since
\begin{equation*} \frac{2x-1}{x^3-x+1} \sim \frac{2x}{x^3} = \frac{2}{x^2} \end{equation*}
and \(\int_1^\infty \frac{2}{x^2} dx\) converges according to the p-test, the integral \(\int_1^\infty \frac{-2x+1}{x^3-x+1}dx \) converges as well.

Checkpoint 4.15.

Find the constant \(C\) so that the integral
\begin{equation*} \int_0^{\infty} \left(\frac{x}{x^2+1} - \frac{C}{3x+1}\right) dx \end{equation*}
converges. Evaluate the integral for this value of \(C\text{.}\)
Hint.
The integrand is
\begin{equation*} \frac{(3-C)x^2 +x - C}{(x^2+1)(3x+1)} \end{equation*}
By degree consideration and Proposition 4.11, we know that \(C\) must be \(3\text{.}\) The integral now can be handled by trigonometric substitutions.