Comparison Test for Improper Integrals
The comparison test for improper integrals decides convergence without integrating. If 0 ≤ g(x) ≤ f(x) and the integral of the bigger function f converges, then the integral of g converges too. If the integral of the smaller function g diverges, then the integral of f diverges too.
Before this lesson: Improper Integrals and Improper Integrals with Infinite Discontinuities
Trapping an area
Many improper integrals, like \int_1^{\infty} e^{-x^2}\,dx, have no antiderivative you can write down. You can still tell whether the area is finite by comparing the function with one you know.
If a region sits inside a region of finite area, it has finite area too. If a region contains a region of infinite area, its area is infinite. The comparison test is just this idea written with integrals.
Comparison test for improper integrals
Suppose f and g are continuous and 0 ≤ g(x) ≤ f(x) for all x ≥ a.
| If you know… | Then… |
|---|---|
| \int_a^{\infty} f(x)\,dx converges (bigger one) | \int_a^{\infty} g(x)\,dx converges |
| \int_a^{\infty} g(x)\,dx diverges (smaller one) | \int_a^{\infty} f(x)\,dx diverges |
The same rule works for integrals with an infinite discontinuity. The other two cases tell you nothing: being smaller than something divergent, or bigger than something convergent, proves nothing.
Good functions to compare with: \dfrac{1}{x^p} on [1, ∞), which converges only when p is greater than 1; \dfrac{1}{x^p} on (0, 1], which converges only when p is less than 1; and e^{-ax} with a positive, which converges on [0, ∞).
Comparison test examples
Example 1: Smaller than a convergent integral
Does \int_1^{\infty} \dfrac{1}{x^2 + 3}\,dx converge?
x^2 + 3 \gt x^2
Adding 3 makes the bottom bigger.
0 \lt \dfrac{1}{x^2 + 3} \lt \dfrac{1}{x^2}A bigger bottom makes a smaller fraction.
\int_1^{\infty} \dfrac{1}{x^2}\,dx = 1Converges by the p-rule, with p = 2.
Answer: the integral converges, and its value is less than 1.
Example 2: Bigger than a divergent integral
Does \int_2^{\infty} \dfrac{1}{\sqrt{x} - 1}\,dx converge?
0 \lt \sqrt{x} - 1 \lt \sqrt{x} \text{ for } x \ge 2Subtracting 1 makes the bottom smaller, and it stays positive.
\dfrac{1}{\sqrt{x} - 1} \gt \dfrac{1}{\sqrt{x}}A smaller positive bottom makes a bigger fraction.
\int_2^{\infty} \dfrac{1}{\sqrt{x}}\,dx = \lim_{t \to \infty} (2\sqrt{t} - 2\sqrt{2}) = \inftyDiverges, since p = 1/2.
Answer: the integral diverges, because it is bigger than a divergent integral.
Example 3: A bounded top
Does \int_1^{\infty} \dfrac{\sin^2 x}{x^2}\,dx converge?
0 \le \sin^2 x \le 1
A square of sine is between 0 and 1 (see graphs of sine and cosine).
0 \le \dfrac{\sin^2 x}{x^2} \le \dfrac{1}{x^2}Divide by x², which is positive.
\int_1^{\infty} \dfrac{1}{x^2}\,dx = 1Converges.
Answer: the integral converges.
Example 4: The bell curve integral
Does \int_1^{\infty} e^{-x^2}\,dx converge?
x^2 \ge x \text{ for } x \ge 1Multiply both sides of x ≥ 1 by x.
-x^2 \le -x
Multiply by −1 and flip the sign.
e^{-x^2} \le e^{-x}eᵘ grows as u grows, so the order stays the same.
\int_1^{\infty} e^{-x}\,dx = \lim_{t \to \infty} (e^{-1} - e^{-t}) = e^{-1}The bigger integral converges.
Answer: the integral converges, and its value is less than 1/e ≈ 0.368. Its actual value is about 0.1394.
Example 5: Bounding the energy from a machine
After its first hour, a cooling machine gives off heat at a rate of E(t) = \dfrac{40}{t^2 + 2t} kilojoules per hour. Is the total heat given off after t = 1 finite? Bound it, then find it exactly.
\dfrac{40}{t^2 + 2t} \le \dfrac{40}{t^2} \text{ for } t \ge 1Dropping 2t makes the bottom smaller and the fraction bigger.
\int_1^{\infty} \dfrac{40}{t^2}\,dt = 4040 times the p-integral with p = 2.
\dfrac{40}{t(t + 2)} = \dfrac{20}{t} - \dfrac{20}{t + 2}Now find it exactly with partial fractions (see integration by partial fractions).
\int_1^{b} \left(\dfrac{20}{t} - \dfrac{20}{t + 2}\right)dt = 20\ln\dfrac{b}{b + 2} - 20\ln\dfrac{1}{3}Integrate and combine the logs (see properties of logarithms).
\lim_{b \to \infty} 20\ln\dfrac{b}{b + 2} = 20\ln 1 = 0b/(b + 2) → 1 (see limits at infinity).
0 - 20\ln\dfrac{1}{3} = 20\ln 3 \approx 21.97−ln(1/3) = ln 3.
Answer: the total is finite. The comparison shows it is at most 40 kJ, and the exact total is 20 ln 3 ≈ 22.0 kJ.
Common mistakes
| Mistake | Example of the error | Fix |
|---|---|---|
| Comparing in the wrong direction | \dfrac{1}{x^2 + 1} \le \dfrac{1}{x}, and ∫1/x diverges, so it diverges | Smaller than divergent proves nothing. Compare with 1/x² instead: it converges. |
| An inequality that fails somewhere | \dfrac{1}{x - 1} \le \dfrac{1}{x} on [2, ∞) | It’s backward: 1/(x − 1) is bigger. Check the inequality before you use it. |
| Using it on negative functions | Comparing \dfrac{\sin x}{x^2} with 1/x² directly | The test needs g(x) ≥ 0. Compare \left|\dfrac{\sin x}{x^2}\right| with 1/x² instead. |
| Picking a divergent benchmark | Using \dfrac{1}{x} as the bigger function | Bigger functions must have convergent integrals. Use 1/xᵖ with p greater than 1, or e⁻ˣ. |
| Limit comparison with L = 0 | \lim \dfrac{f}{g} = 0, so both act the same | Limit comparison needs a finite, positive limit L. |
Related methods
Limit comparison test
If f and g are positive and \lim_{x \to \infty} \dfrac{f(x)}{g(x)} = L with L finite and positive, then the two integrals both converge or both diverge. For example, \dfrac{2x + 1}{x^3 + 5} behaves like \dfrac{2}{x^2}, since the ratio of the two approaches 1. So \int_1^{\infty} \dfrac{2x + 1}{x^3 + 5}\,dx converges.
Absolute convergence
If \int_a^{\infty} |f(x)|\,dx converges, then \int_a^{\infty} f(x)\,dx converges too. This handles integrands that change sign, like sin x / x².
The same idea for series
Infinite series have their own comparison tests, which work the same way. You’ll see them later in this course.
Practice problems
Decide whether each integral converges or diverges, and say what you compared it with.
- \int_1^{\infty} \dfrac{1}{x^3 + 1}\,dx
- \int_1^{\infty} \dfrac{1 + e^{-x}}{x}\,dx
- \int_1^{\infty} \dfrac{\cos^2 x}{x^2 + 1}\,dx
- \int_2^{\infty} \dfrac{1}{\ln x}\,dx
- \int_1^{\infty} \dfrac{x}{x^3 + 2}\,dx (use limit comparison)
- \int_1^{\infty} \dfrac{\sqrt{x}}{x + 1}\,dx (use limit comparison)
- \int_1^{\infty} \dfrac{e^{-x}}{x}\,dx
- \int_0^{1} \dfrac{e^{x}}{\sqrt{x}}\,dx
- \int_0^{1} \dfrac{1}{x^2 + x}\,dx
- Show that \int_1^{\infty} \dfrac{1}{x^4 + x}\,dx converges to a number at most 1/3.
Show answers
1.
x^3 + 1 \gt x^3, \text{ so } \dfrac{1}{x^3 + 1} \lt \dfrac{1}{x^3}A bigger bottom gives a smaller fraction.
\int_1^{\infty} \dfrac{1}{x^3}\,dx = \dfrac{1}{2}Converges (p = 3).
Answer: converges
2.
1 + e^{-x} \gt 1, \text{ so } \dfrac{1 + e^{-x}}{x} \gt \dfrac{1}{x}e⁻ˣ is positive.
\int_1^{\infty} \dfrac{1}{x}\,dx = \inftyDiverges (p = 1).
Answer: diverges
3.
0 \le \dfrac{\cos^2 x}{x^2 + 1} \le \dfrac{1}{x^2 + 1} \lt \dfrac{1}{x^2}cos²x is at most 1, and a bigger bottom gives a smaller fraction.
\int_1^{\infty} \dfrac{1}{x^2}\,dx = 1Converges.
Answer: converges
4.
0 \lt \ln x \lt x \text{ for } x \ge 2ln x grows more slowly than x.
\dfrac{1}{\ln x} \gt \dfrac{1}{x}Flip both sides of a positive inequality.
\int_2^{\infty} \dfrac{1}{x}\,dx = \inftyDiverges.
Answer: diverges
5.
\lim_{x \to \infty} \dfrac{x/(x^3 + 2)}{1/x^2} = \lim_{x \to \infty} \dfrac{x^3}{x^3 + 2} = 1Compare with 1/x²; divide by x³ to find the limit.
\int_1^{\infty} \dfrac{1}{x^2}\,dx \text{ converges}L = 1 is finite and positive.
Answer: converges
6.
\lim_{x \to \infty} \dfrac{\sqrt{x}/(x + 1)}{1/\sqrt{x}} = \lim_{x \to \infty} \dfrac{x}{x + 1} = 1Compare with 1/√x.
\int_1^{\infty} \dfrac{1}{\sqrt{x}}\,dx \text{ diverges}p = 1/2.
Answer: diverges
7.
0 \lt \dfrac{e^{-x}}{x} \le e^{-x} \text{ for } x \ge 1Dividing by x ≥ 1 makes it no bigger.
\int_1^{\infty} e^{-x}\,dx = e^{-1}Converges.
Answer: converges
8.
0 \lt \dfrac{e^{x}}{\sqrt{x}} \le \dfrac{e}{\sqrt{x}} \text{ on } (0, 1]eˣ ≤ e when x ≤ 1.
\int_0^{1} \dfrac{e}{\sqrt{x}}\,dx = 2eConverges (p = 1/2 near 0).
Answer: converges
9.
x^2 + x \le 2x \text{ on } (0, 1]x² ≤ x when x ≤ 1.
\dfrac{1}{x^2 + x} \ge \dfrac{1}{2x}A smaller positive bottom gives a bigger fraction.
\int_0^{1} \dfrac{1}{2x}\,dx = \inftyDiverges (p = 1 near 0).
Answer: diverges
10.
\dfrac{1}{x^4 + x} \lt \dfrac{1}{x^4}A bigger bottom gives a smaller fraction.
\int_1^{\infty} \dfrac{1}{x^4}\,dx = \dfrac{1}{4 - 1} = \dfrac{1}{3}p-rule with p = 4.
Answer: converges, to a number less than 1/3
Comparison test FAQ
What is the comparison test for improper integrals?
It compares a positive function with one whose integral you know. Below a convergent integral means convergent; above a divergent integral means divergent.
What functions should I compare with?
Use 1/xᵖ or e⁻ᵃˣ. Look at what the function acts like for large x, or near the bad point, and keep only the strongest terms.
What is the limit comparison test for integrals?
If f/g approaches a finite, positive number, the integrals of f and g both converge or both diverge. It saves you from proving an exact inequality.
What if my inequality goes the wrong way?
Then the test tells you nothing. Pick a different comparison function, or try limit comparison.
Summary
- The comparison test needs 0 ≤ g(x) ≤ f(x).
- If the bigger integral converges, so does the smaller one.
- If the smaller integral diverges, so does the bigger one.
- Compare with 1/xᵖ or e⁻ᵃˣ.
- Limit comparison: a finite, positive limit of f/g means both act the same.
Previous lesson: Improper Integrals with Infinite Discontinuities
Next lesson: Shell Method
Back to the Calculus 2 Index