Calculus · Infinite series

Series of Functions: When Can You Add Up Infinitely Many Functions?

So far our series added up numbers. Now each term is a function of \(x\), and the sum is a new function. Is that sum continuous? Can we differentiate or integrate it term by term? The answer hinges on one concept, uniform convergence. This post explains it and shows how it leads to beautiful results like \( 1 - \frac13 + \frac15 - \cdots = \frac\pi4 \).

1. The domain of convergence

A series of functions is a series whose terms depend on a variable:

\[ \sum_{n=1}^\infty u_n(x) = u_1(x) + u_2(x) + u_3(x) + \cdots \tag{1} \]

For each fixed number \(x\), this is an ordinary numerical series, which may converge or diverge.

Definition The set \(X\) of those values of \(x\) for which the series (1) converges is called its domain of convergence. On \(X\), the series defines a function, its sum \( S(x) = \sum_{n=1}^\infty u_n(x) \).

To find the domain, fix \(x\) and use the tests from the earlier posts on numerical series (especially the ratio and root tests applied to \(|u_n(x)|\)), then check the boundary points separately.

Example 1
  • \( \sum_{n=0}^\infty x^n \) is a geometric series: it converges exactly for \( |x| < 1 \), with sum \( \frac{1}{1-x} \). Domain: \((-1, 1)\).
  • \( \sum_{n=1}^\infty \frac{1}{n^x} \) is a p-series with \(p = x\): domain \((1, \infty)\).
  • \( \sum_{n=1}^\infty \frac{x^n}{n} \): the ratio test gives \( \left|\frac{u_{n+1}}{u_n}\right| \to |x| \), so it converges for \(|x| < 1\) and diverges for \(|x| > 1\). At \(x = 1\): harmonic series, diverges. At \(x = -1\): alternating harmonic series, converges. Domain: \([-1, 1)\).

2. Uniform convergence

2.1 The problem with pointwise convergence

Convergence for each \(x\) separately (pointwise convergence) turns out to be too weak. Look at the sequence \( u_n(x) = x^n \) on \([0, 1]\):

\[ \lim_{n\to\infty} x^n = \begin{cases} 0, & 0 \le x < 1,\\ 1, & x = 1. \end{cases} \]

Every \(x^n\) is a perfectly continuous function, yet the limit jumps at \(x = 1\). The reason: for \(x\) close to \(1\), \(x^n\) approaches \(0\) very slowly. To get \(x^n < 0.01\) you need \( n > \frac{\ln 100}{-\ln x} \), and this number explodes as \(x \to 1\). No single \(N\) works for all \(x\).

x 0 1 1 n = 1 n = 20
Figure 1. \(y = x^n\) for \(n = 1, 2, 5, 20\). The graphs collapse onto \(0\), except near \(x = 1\), where they stay steep. The worst-case gap is always \(1\).

2.2 The definition

Uniform convergence of a sequence A sequence of functions \( u_1(x), u_2(x), u_3(x), \dots \) converges uniformly on a set \(X\) if for every \(x \in X\) the limit \( u(x) = \lim_{n\to\infty} u_n(x) \) exists, and for every \(\varepsilon > 0\) there is a number \(N = N(\varepsilon)\) such that \[ |u(x) - u_n(x)| < \varepsilon \] for every \(n > N\) and every \(x \in X\).
Uniform convergence of a series The series (1) converges uniformly on \(X\) if the sequence of its partial sums \[ S_n(x) = \sum_{\nu=1}^n u_\nu(x) \qquad (n = 1, 2, 3, \dots) \] converges uniformly on \(X\).

The key word is that \(N\) depends only on \(\varepsilon\), not on \(x\). Geometrically: draw a band of width \(\varepsilon\) above and below the graph of the limit \(u(x)\). Uniform convergence means that from some \(N\) on, the entire graph of \(u_n\) lies inside the band.

A practical reformulation, which is what you'll actually compute:

\[ \text{uniform convergence} \iff \sup_{x\in X}|u(x) - u_n(x)| \longrightarrow 0 \quad (n \to \infty). \]
Example 2 · It depends on the set For \(u_n(x) = x^n\) with limit \(0\) on \([0, 1)\):
  • On \([0, 1)\): \( \sup_{0\le x<1} x^n = 1 \) for every \(n\). Not uniform.
  • On \([0, q]\) with \(q < 1\): \( \sup_{0\le x\le q} x^n = q^n \to 0 \). Uniform.
The geometric series behaves the same way: on \([-q, q]\) its remainder is at most \( \frac{q^{n+1}}{1 - q} \to 0 \) (uniform), but on \((-1, 1)\) the remainder \( \frac{x^{n+1}}{1-x} \) is unbounded (not uniform). Trouble sits at the edge of the domain, and staying a fixed distance away from it restores uniformity.

3. The Cauchy criterion

Cauchy criterion for uniform convergence The series (1) converges uniformly on \(X\) if and only if for every \(\varepsilon > 0\) there is \(N = N(\varepsilon)\) such that for \(n > N\) and \(p > 0\) \[ |S_{n+p}(x) - S_n(x)| = \left|\sum_{\nu=n+1}^{n+p} u_\nu(x)\right| < \varepsilon \qquad (x \in X). \]

This is the Cauchy criterion for numerical series from the first post, with one addition: the same \(N\) must work for all \(x\). Its advantage is that it doesn't require knowing the sum \(S(x)\) in advance. It is the main tool for proving the tests below.

4. Tests for uniform convergence

4.1 Weierstrass's test

Weierstrass's test (M-test) The series (1) converges absolutely and uniformly on \(X\) if there is a convergent numerical series \( \sum_{n=1}^\infty c_n \) such that for every \(x \in X\) \[ |u_n(x)| \le c_n \qquad (n = 1, 2, \dots). \]

Why it works: \( \left|\sum_{\nu=n+1}^{n+p} u_\nu(x)\right| \le \sum_{\nu=n+1}^{n+p} c_\nu \), and the right side doesn't depend on \(x\) and is small by the Cauchy criterion for \(\sum c_n\). In practice, take \( c_n = \sup_{x\in X}|u_n(x)| \) and check whether \(\sum c_n\) converges. This is by far the most used test.

Example 3
  • \( \sum\frac{\sin nx}{n^2} \) converges uniformly on \(\mathbb R\): \( \left|\frac{\sin nx}{n^2}\right| \le \frac1{n^2} \).
  • \( \sum\frac{x^n}{n^2} \) converges uniformly on \([-1, 1]\): \( \left|\frac{x^n}{n^2}\right| \le \frac1{n^2} \).
  • \( \sum x^n \) converges uniformly on \([-q, q]\), \(q < 1\): \( |x^n| \le q^n \).

4.2 Abel's and Dirichlet's tests

Like their numerical versions in the previous post, these handle series that converge only thanks to cancellation, of the form

\[ \sum_{n=1}^\infty a_n(x)\,b_n(x). \tag{2} \]
Abel's test The series (2) converges uniformly on \(X\) if \( \sum a_n(x) \) converges uniformly on \(X\), and the sequence \(b_n(x)\) is monotone (in \(n\)) for every \(x \in X\) and uniformly bounded: \( |b_n(x)| \le M \) for all \(n\) and all \(x \in X\).
Dirichlet's test The series (2) converges uniformly on \(X\) if the partial sums \( \sum_{\nu=1}^n a_\nu(x) \) are uniformly bounded on \(X\), and the sequence \(b_n(x)\) is monotone for every \(x \in X\) and converges uniformly to zero as \(n \to \infty\).
Example 4 · Dirichlet: \( \sum\frac{\sin nx}{n} \) On \( [\delta, 2\pi - \delta] \) with \( 0 < \delta < \pi \): \[ \left|\sum_{k=1}^n \sin kx\right| \le \frac{1}{\left|\sin\frac x2\right|} \le \frac{1}{\sin\frac\delta2}, \] a bound independent of \(x\), and \(b_n = \frac1n\) decreases uniformly to \(0\). So the series converges uniformly there. Near \(x = 0\) it does not: its sum equals \( \frac{\pi - x}{2} \) on \((0, 2\pi)\) but \(0\) at \(x = 0\), a jump that uniform convergence would forbid (see Section 5).

5. Properties: limits, derivatives and integrals term by term

Here is why uniform convergence matters. For finite sums, limits, derivatives and integrals can always be taken term by term. For infinite sums this is a swap of two limiting processes, and uniform convergence is what makes the swap legal.

5.1 Continuity

Property 1 The sum of a uniformly convergent series of continuous functions is a continuous function.

Read backwards, it's a quick test for non-uniform convergence: if continuous terms add up to a discontinuous sum, the convergence cannot be uniform (Example 2 on \([0,1]\), Example 4 near \(0\)).

5.2 Limits term by term

Property 2 If the series (1) converges uniformly on the interval \((a, b)\), and the limits \( \lim_{x\to a} u_n(x) = A_n \) \((n = 1, 2, \dots)\) exist, then
  1. the series \( \sum_{n=1}^\infty A_n \) converges, and
  2. \( \displaystyle\lim_{x\to a}\Big\{\sum_{n=1}^\infty u_n(x)\Big\} = \sum_{n=1}^\infty\Big\{\lim_{x\to a}u_n(x)\Big\}. \)

This is especially useful at an endpoint \(a\) of the interval, where the series may not even be defined, as we'll see in Section 6.

5.3 Differentiation term by term

Property 3 If the terms of the convergent series (1) are continuously differentiable on \((a, b)\), and the series of derivatives \( \sum_{n=1}^\infty u_n'(x) \) converges uniformly on \((a, b)\), then for \(x \in (a, b)\) \[ \Big[\sum_{n=1}^\infty u_n(x)\Big]' = \sum_{n=1}^\infty u_n'(x). \]
Check the series of derivatives, not the original The series \( \sum_{n=1}^\infty \frac{\sin(n^2x)}{n^2} \) converges uniformly on \(\mathbb R\) (Weierstrass, with \(c_n = \frac1{n^2}\)). But differentiating term by term gives \( \sum\cos(n^2x) \), whose terms don't even tend to zero: it diverges everywhere. Uniform convergence of \(\sum u_n\) is not enough; the condition is on \(\sum u_n'\).
Example 5 Differentiate \( \sum_{n=0}^\infty x^n = \frac{1}{1 - x} \) term by term. The derived series \( \sum nx^{n-1} \) converges uniformly on every \([-q, q]\), \(q < 1\) (majorant \(nq^{n-1}\), convergent by the ratio test). Since every \(x \in (-1, 1)\) lies in such an interval: \[ \sum_{n=1}^\infty nx^{n-1} = \frac{1}{(1 - x)^2} \qquad (|x| < 1). \] This agrees with the result we got in the previous post by swapping the order in a double series.

5.4 Integration term by term

Property 4 If the terms of the series (1) are continuous and the series converges uniformly on a finite segment \([a, b]\), then \[ \int_a^b\Big\{\sum_{n=1}^\infty u_n(x)\Big\}dx = \sum_{n=1}^\infty\int_a^b u_n(x)\,dx. \tag{3} \] If \( \displaystyle\int_a^b\Big\{\sum_{i=n+1}^\infty u_i(x)\Big\}dx \to 0 \) as \(n \to \infty\), then formula (3) is also valid for infinite limits of integration.

The last condition says the integral of the remainder must tend to zero. On a finite segment, uniform convergence guarantees this automatically: \( \left|\int_a^b R_n\,dx\right| \le (b - a)\sup|R_n| \to 0 \). On an infinite interval, the factor \(b - a\) is infinite, so the condition has to be checked directly.

Without uniformity, integration can fail The functions \( f_n(x) = 2n\,x\,e^{-nx^2} \) tend to \(0\) at every \(x \in [0, 1]\). But \[ \int_0^1 f_n(x)\,dx = 1 - e^{-n} \longrightarrow 1 \ne 0 = \int_0^1 0\,dx. \] Each \(f_n\) has a tall, narrow bump (maximum \( \sqrt{2n}\,e^{-1/2} \) at \(x = \frac{1}{\sqrt{2n}}\)) that slides towards \(0\) while keeping area close to \(1\). The convergence is not uniform, and the area "escapes" in the limit.

6. The payoff: \(\ln 2\) and \(\frac\pi4\)

Put all the tools together. These two classic results were quoted in earlier posts; now we can prove them.

Example 6 · \( 1 - \frac12 + \frac13 - \cdots = \ln 2 \)

Step 1 (integrate a geometric series). For \(|t| < 1\), \( \frac{1}{1 + t} = \sum_{n=0}^\infty (-1)^nt^n \). For \(0 \le x < 1\), this series converges uniformly on \([0, x]\) (majorant \(x^n\)), so by Property 4:

\[ \ln(1 + x) = \int_0^x \frac{dt}{1 + t} = \sum_{n=0}^\infty (-1)^n\frac{x^{n+1}}{n+1} = \sum_{n=1}^\infty \frac{(-1)^{n-1}x^n}{n}. \]

Step 2 (uniform convergence up to \(x = 1\)). Apply Abel's test on \([0, 1]\) with \( a_n = \frac{(-1)^{n-1}}{n} \) (constant in \(x\), and \(\sum a_n\) converges by Leibniz, hence uniformly) and \( b_n(x) = x^n \) (monotone in \(n\), bounded by \(1\)). So the series converges uniformly on \([0, 1]\).

Step 3 (pass to the limit). By Property 2 (or Property 1, continuity), let \(x \to 1^-\):

\[ \sum_{n=1}^\infty \frac{(-1)^{n-1}}{n} = \lim_{x\to1^-}\ln(1 + x) = \ln 2. \]
Example 7 · Leibniz's series \( 1 - \frac13 + \frac15 - \cdots = \frac\pi4 \)

The same three steps with \( \frac{1}{1 + t^2} = \sum_{n=0}^\infty (-1)^nt^{2n} \):

\[ \operatorname{arctg}x = \int_0^x\frac{dt}{1 + t^2} = \sum_{n=0}^\infty \frac{(-1)^nx^{2n+1}}{2n + 1} \qquad (0 \le x < 1). \]

Abel's test (with \(b_n = x^{2n+1}\)) gives uniform convergence on \([0, 1]\), and letting \(x \to 1^-\):

\[ 1 - \frac13 + \frac15 - \frac17 + \cdots = \operatorname{arctg}1 = \frac\pi4. \]

7. Summary

Concept / propertyStatementKey condition
Domain of convergenceset \(X\) where \(\sum u_n(x)\) convergestest each \(x\), check endpoints
Uniform convergence\( \sup_X|S(x) - S_n(x)| \to 0 \)\(N\) depends only on \(\varepsilon\)
Weierstrass\( |u_n(x)| \le c_n,\ \sum c_n < \infty \)absolute + uniform
Abel\(\sum a_n\) uniform, \(b_n\) monotone, uniformly boundeduniform
Dirichletpartial sums of \(\sum a_n\) uniformly bounded, \(b_n \searrow 0\) uniformlyuniform
Continuitysum of continuous terms is continuousuniform convergence
Limit term by term\( \lim\sum = \sum\lim \)uniform convergence
Differentiation\( (\sum u_n)' = \sum u_n' \)\(\sum u_n'\) uniform
Integration\( \int\sum = \sum\int \)uniform on \([a, b]\); remainder integral \(\to 0\) for infinite limits

8. Practice problems

Try each one before opening the solution. More solved problems from this topic are in Series.

Problem 1: Find the domain of convergence of \( \displaystyle\sum_{n=1}^\infty \frac{1}{1 + x^{2n}} \).

For \(|x| \le 1\), the terms are at least \(\frac12\), so they don't tend to zero: divergence. For \(|x| > 1\), \( \frac{1}{1 + x^{2n}} < \big(\frac{1}{x^2}\big)^n \), a convergent geometric series. Domain: \( |x| > 1 \).

Problem 2: Does \( \displaystyle\sum_{n=1}^\infty \frac{\cos nx}{n^3 + 1} \) converge uniformly on \(\mathbb R\)?

Yes, by Weierstrass: \( \left|\frac{\cos nx}{n^3 + 1}\right| \le \frac{1}{n^3} \).

Problem 3: Does \( \displaystyle\sum_{n=1}^\infty x^n(1 - x) \) converge uniformly on \([0, 1]\)?

Its sum is \( (1 - x)\frac{x}{1 - x} = x \) for \(0 \le x < 1\), and \(0\) at \(x = 1\). The terms are continuous but the sum is discontinuous at \(1\), so by Property 1 the convergence is not uniform.

Problem 4: Compute \( \displaystyle\sum_{n=1}^\infty \frac{1}{n\,2^n} \).

Integrating \( \frac{1}{1 - t} = \sum t^n \) from \(0\) to \(x\) (\(|x| < 1\)) gives \( -\ln(1 - x) = \sum_{n=1}^\infty\frac{x^n}{n} \). At \(x = \frac12\): \( \sum\frac{1}{n2^n} = -\ln\frac12 = \ln 2 \).

Problem 5: Compute \( \displaystyle\sum_{n=1}^\infty \frac{n}{3^n} \).

Multiply Example 5 by \(x\): \( \sum nx^n = \frac{x}{(1-x)^2} \). At \(x = \frac13\): \( \frac{1/3}{4/9} = \frac34 \).

Problem 6: Compute \( \displaystyle\int_0^\pi \sum_{n=1}^\infty \frac{\sin nx}{n^3}\,dx \).

The series converges uniformly (Weierstrass, \(\frac1{n^3}\)), so integrate term by term: \( \int_0^\pi \sin nx\,dx = \frac{1 - \cos n\pi}{n} \), which is \(\frac2n\) for odd \(n\) and \(0\) for even \(n\). The result is \( \sum_{n\ \text{odd}}\frac{2}{n^4} = 2\cdot\frac{\pi^4}{96} = \frac{\pi^4}{48} \) (using the known value \( \sum_{n\ \text{odd}}\frac1{n^4} = \frac{\pi^4}{96} \)).

Problem 7: Explain why \( \displaystyle\sum_{n=1}^\infty \frac{\sin nx}{n} \) cannot converge uniformly on \((0, 2\pi)\).

On \((0, 2\pi)\) its sum is \( \frac{\pi - x}{2} \), which tends to \(\frac\pi2\) as \(x \to 0^+\). If the convergence were uniform, Property 2 would give \( \lim_{x\to0^+}\sum\frac{\sin nx}{n} = \sum\lim_{x\to0^+}\frac{\sin nx}{n} = 0 \), a contradiction.

Final thoughts

Uniform convergence is the passport that lets limits, derivatives and integrals travel through an infinite sum. The intuition to keep: the error must become small at the same rate everywhere on the set. Check it with Weierstrass's test whenever you can; fall back on Abel and Dirichlet for oscillating terms; and remember that for differentiation it is the derived series that must converge uniformly.

Next in the series: power series and Taylor series.