Tutorials › Real Analysis › Proof of the Integral Test

Infinite Series · Tutorial 518 of 1000

Proof of the Integral Test

See how finite comparisons prove the Integral Test and yield a bounded-error estimate relating partial sums to integrals.

Advanced 9 min read

What You'll Learn

  • Prove both directions of the Integral Test using finite sum–integral comparisons.
  • Identify where positivity is needed to pass from finite bounds to limits.
  • Apply the theorem to series with rational and exponential terms.
  • Prove a uniform bound on the difference between a partial sum and a nearby integral.
  • Recognize why eventual decreasingness is enough when only finitely many terms are excluded.

Turning Finite Comparisons into a Proof

The Integral Test relates two different limiting processes: the partial sums of a series and the values of an improper integral. The essential comparison is already visible on a single unit interval. For a decreasing function, its values on \([k,k+1]\) lie between the endpoint values, so the area over that interval is bounded by neighboring terms. The previous tutorial used these comparisons to state the Integral Test and to estimate remainders. Here we use finite comparisons to prove the test, paying particular attention to how the indices line up and how the limits are taken.

Recall the finite sum–integral comparison: if \(f\) is continuous and decreasing on \([1,\infty)\), then, for every positive integer \(N\),

$$ \sum_{n=2}^{N+1}f(n) \leq \int_1^{N+1} f(x)\,dx \leq \sum_{n=1}^{N}f(n). $$

We will use this result rather than repeat its interval-by-interval proof. For the Integral Test, \(f\) is also positive. This additional hypothesis ensures that the partial sums and the integrals increase as their endpoints increase. That monotonicity is what lets finite bounds give information about convergence.

Theorem (Integral Test): Suppose \(f:[1,\infty)\to\mathbb{R}\) is continuous, positive, and decreasing, and let \(a_n=f(n)\) for every positive integer \(n\). Then $$ \sum_{n=1}^{\infty}a_n \text{ converges} \quad\Longleftrightarrow\quad \int_1^\infty f(x)\,dx \text{ converges}. $$

Proof. Write \(S_N=\sum_{n=1}^{N}f(n)\) and \(I(B)=\int_1^B f(x)\,dx\) for \(B\geq1\). Since \(f\) is positive, the sequence \((S_N)\) is increasing, and \(I(B)\) is increasing as \(B\) increases.

First suppose that the improper integral converges. For every integer \(N\geq2\), apply the finite sum–integral comparison with \(N-1\) in place of \(N\). Its left-hand inequality gives

$$ \sum_{n=2}^{N} f(n)\leq\int_1^N f(x)\,dx. $$

Adding \(f(1)\) shows that

$$ S_N\leq f(1)+\int_1^N f(x)\,dx \leq f(1)+\int_1^\infty f(x)\,dx. $$

The last expression is finite and does not depend on \(N\). Thus the increasing sequence of partial sums is bounded above. By the earlier theorem on bounded increasing partial sums, \((S_N)\) converges, so the series converges.

Conversely, suppose the series converges. The right-hand inequality in the finite comparison gives, for every positive integer \(N\),

$$ \int_1^{N+1} f(x)\,dx\leq S_N. $$

The convergent series has bounded partial sums, so the integrals on the left are bounded above. Because \(f\) is positive, \(I(B)\) is increasing in \(B\). For any \(B\geq1\), choose an integer \(N\) with \(B\leq N+1\). Positivity then gives

$$ 0\leq \int_1^B f(x)\,dx \leq \int_1^{N+1} f(x)\,dx \leq S_N. $$

The partial sums are bounded, so the integrals \(\int_1^B f(x)\,dx\) are bounded above for all \(B\geq1\). An increasing function of \(B\) that is bounded above has a finite limit as \(B\to\infty\). By the definition of the improper integral, \(\int_1^\infty f(x)\,dx\) therefore converges. This proves both directions. \(\square\)

Why the Hypotheses Matter in the Proof

Each hypothesis has a particular role. Continuity ensures that \(f\) is Riemann integrable on every bounded interval used in the comparisons. Decreasingness puts the graph between the endpoint heights on each unit interval, which is the source of the finite inequalities. Positivity ensures that adding terms or extending an integral endpoint cannot decrease the quantities being bounded.

The proof also explains why the indices in the finite comparison cannot simply be ignored. The bound \(\int_1^{N+1}f(x)\,dx\leq S_N\) compares the integral through \(N+1\) with the sum through \(N\). In the other direction, the bound for the terms from \(2\) to \(N\) involves the integral only through \(N\). The shift by one unit is harmless for deciding convergence, but keeping track of it makes the limit argument valid.

Worked Example: A Convergent Rational Series

Consider

$$ \sum_{n=1}^{\infty}\frac{1}{n^2+2n+2}. $$

Set \(f(x)=1/(x^2+2x+2)\) for \(x\geq1\). The denominator is positive, so \(f\) is positive and continuous. Differentiation gives

$$ f'(x)=-\frac{2x+2}{(x^2+2x+2)^2}<0 \quad (x\geq1), $$

so \(f\) is decreasing. Completing the square gives \(x^2+2x+2=(x+1)^2+1\), and therefore

$$ \int_1^B\frac{dx}{x^2+2x+2} = \arctan(B+1)-\arctan 2. $$

As \(B\to\infty\), this tends to \(\pi/2-\arctan 2\), a finite number. All the hypotheses of the Integral Test hold, so the series converges.

Worked Example: A Divergent Rational Series

Now consider the tail of the series

$$ \sum_{n=3}^{\infty}\frac{n}{n^2+9}. $$

Define \(g(x)=x/(x^2+9)\) for \(x\geq3\). It is positive and continuous, and

$$ g'(x)=\frac{9-x^2}{(x^2+9)^2}\leq0 \quad (x\geq3). $$

Thus \(g\) is decreasing, including at the initial endpoint where its derivative is zero. An antiderivative is \(\tfrac12\log(x^2+9)\), since its derivative is \(x/(x^2+9)\). Hence

$$ \int_3^B\frac{x}{x^2+9}\,dx = \frac12\log(B^2+9)-\frac12\log 18. $$

This expression tends to infinity as \(B\to\infty\). The Integral Test shows that the series beginning at \(n=3\) diverges. Adding or removing its first two terms cannot change that conclusion, by the earlier theorem on finite changes to a series.

Worked Example: A Convergent Series with an Exponential Term

Consider

$$ \sum_{n=1}^{\infty}e^{-\sqrt{n}}. $$

Let \(h(x)=e^{-\sqrt{x}}\) for \(x\geq1\). This function is positive and continuous, and

$$ h'(x)=-\frac{e^{-\sqrt{x}}}{2\sqrt{x}}<0 \quad (x\geq1), $$

so it is decreasing. To evaluate the improper integral, set \(u=\sqrt{x}\), so \(x=u^2\) and \(dx=2u\,du\). Then

$$ \int_1^B e^{-\sqrt{x}}\,dx = 2\int_1^{\sqrt{B}}u e^{-u}\,du = 2\left[-(u+1)e^{-u}\right]_{1}^{\sqrt{B}}. $$

Since \((u+1)e^{-u}\to0\) as \(u\to\infty\), the improper integral converges and equals \(4/e\). The Integral Test therefore proves that the series converges.

A Bounded Difference Between Sums and Integrals

The same comparisons give more than a yes-or-no convergence test. They show that the partial sum and a nearby integral remain within a fixed distance of one another. This holds whether those quantities converge or grow without bound.

Theorem (Bounded Sum–Integral Difference): Suppose \(f:[1,\infty)\to\mathbb{R}\) is continuous, positive, and decreasing. For every positive integer \(N\), $$ 0\leq \sum_{n=1}^{N}f(n)-\int_1^{N+1}f(x)\,dx \leq f(1). $$

Proof. The right-hand inequality in the finite sum–integral comparison gives

$$ \int_1^{N+1} f(x)\,dx\leq\sum_{n=1}^{N}f(n), $$

which proves the lower bound. For \(N\geq2\), apply the left-hand inequality of that comparison with \(N-1\) in place of \(N\):

$$ \sum_{n=2}^{N}f(n)\leq\int_1^N f(x)\,dx. $$

Adding \(f(1)\) to both sides and using positivity of \(f\) gives

$$ \sum_{n=1}^{N}f(n) \leq f(1)+\int_1^N f(x)\,dx \leq f(1)+\int_1^{N+1} f(x)\,dx. $$

For \(N=1\), the same final bound holds because \(\int_1^2 f(x)\,dx\geq0\), so \(f(1)\leq f(1)+\int_1^2 f(x)\,dx\). Subtracting the integral from the sum in the established bounds proves the result for every positive integer \(N\). \(\square\)

The error bound \(f(1)\) does not depend on \(N\). Consequently, the integral and partial sum have the same behavior in a broad sense: if one stays bounded, so does the other; if one grows without bound, so does the other. The Integral Test gives the precise convergence equivalence, while this estimate records how closely the finite quantities track each other.

Worked Example: Using the Difference Bound

For \(f(x)=e^{-\sqrt{x}}\), the theorem gives, for every positive integer \(N\),

$$ 0\leq \sum_{n=1}^{N}e^{-\sqrt{n}} - \int_1^{N+1}e^{-\sqrt{x}}\,dx \leq e^{-1}. $$

The integral can be evaluated by the same substitution used above:

$$ \int_1^{N+1}e^{-\sqrt{x}}\,dx = \frac{4}{e} - 2(\sqrt{N+1}+1)e^{-\sqrt{N+1}}. $$

The second term on the right tends to zero, so the integral tends to \(4/e\). The bounded-difference estimate is consistent with the convergence of the partial sums established by the Integral Test; it also supplies a uniform bound on their difference from these finite integrals.

Using the Proof in Practice

A proof by the Integral Test should establish the hypotheses before evaluating the integral. It is not enough that the formula looks positive at integer inputs: the function must be positive, continuous, and decreasing throughout the interval on which the integral is considered. When these conditions hold only after some integer \(m\), apply the test to the tail beginning at \(m\). The omitted initial segment contains finitely many terms and does not affect convergence.

1
Match terms to a function.
Choose \(f\) so that \(a_n=f(n)\) on the relevant integer tail.
2
Verify the hypotheses.
Check positivity, continuity, and nonincreasing behavior on the full interval used for the integral.
3
Evaluate the improper integral.
Use its limit as the upper endpoint tends to infinity; a finite limit gives convergence, while unbounded growth gives divergence.
4
Keep the finite bounds in view.
The index shift between the integral and the sum is controlled, and the bounded-difference estimate can quantify their relationship.

A common pitfall is to invoke the Integral Test based only on an antiderivative calculation. If the function is not decreasing, the finite comparisons used in the proof may fail, and the integral alone may not decide the series. Another is to treat convergence of \(\int_1^\infty f(x)\,dx\) as a statement about a signed integral with possible cancellation. Positivity is essential here: it ensures that the partial sums and accumulated areas increase, allowing boundedness and limits to settle the question.

Takeaway: The Integral Test follows by combining finite sum–integral comparisons with the fact that positive partial sums and accumulated integrals are increasing. The comparisons also show that the partial sum through \(N\) differs from the integral through \(N+1\) by at most \(f(1)\).

Check Your Understanding

Use the hypotheses and finite comparisons in the proof to answer the following questions.

  1. In the convergence direction of the proof, why does an upper bound on all partial sums imply convergence?
  2. When the series converges, how does the inequality \(\int_1^{N+1}f(x)\,dx\leq S_N\) help establish convergence of the improper integral?
  3. For \(f(x)=e^{-\sqrt{x}}\), what substitution evaluates the improper integral, and what is its value?
  4. Why does the bounded sum–integral difference theorem require positivity as well as decreasingness?
  5. If \(f\) becomes decreasing only after an integer \(m\), why can the Integral Test still be applied to the series tail?