A628 of 55
0 XP
  1. Hook
  2. Play
  3. Predict
  4. Name it
  5. Check
  6. Explain

A6 · Lesson 28 · Alternating series

Overshooting your way to the answer

Evaluate a square wave's Fourier series at the middle of a pulse and you get 1−13+15−17+⋯, which adds up to π4. The signs alternate, so each partial sum overshoots, then undershoots, closing in from both sides. That back-and-forth gives you something rare: an exact, easy bound on the error after any number of terms. Calculators and microcontrollers that compute sines and cosines rely on exactly this bound to know when to stop.

  • The staircase is the partial sums of 1−r+r2−r3+⋯. The flat line is the true sum, 11+r.
  • The partial sums land alternately above and below the line. Each one is closer than the last.
  • The readout compares the actual error after N terms with the bound, the size of the next term. Is the bound ever wrong?

Predict

You add the first 3 terms of 1−12!+14!−16!+⋯ (the series for cos⁡1). What's the most your answer can be off by?

Name it

The alternating series test

A series b1−b2+b3−b4+⋯ with bn>0 converges if

  1. the terms shrink: bn+1≤bn, and
  2. they approach zero: bn→0.

The partial sums step back and forth across the limit with ever-shorter steps, so they must close in on it.

The error bound

If you stop after N terms, the error is at most the next term:

|S−SN|≤bN+1

and the true sum lies between SN and SN+1. This is one of the few places in mathematics where the error of an infinite process is this easy to bound.

Absolute and conditional convergence

A series converges absolutely if ∑|an| converges; then it converges whatever the signs. A series that converges only because of its alternating signs converges conditionally. The alternating harmonic series 1−12+13−⋯=ln⁡2 is the standard example: ∑1n diverges.

Conditionally convergent series are fragile. Reorder their terms and you can make them add up to any number you like, so never rearrange one. Absolutely convergent series can be rearranged freely.

Worked example

How many terms of 1−13+15−⋯=π4 guarantee an error below 0.001?

Show the solution
  1. Find the first term left out. The (N+1)th term is 12N+1.
  2. Make it small enough. 12N+1<0.001so2N+1>1000 giving N=500 terms.
  3. Interpret. That's slow: the terms shrink like 1n. Series whose terms shrink like factorials, as in the cosine example, need only a handful.

Answer 500 terms.

Worked example

Estimate ln⁡1.5 from ln⁡(1+x)=x−x22+x33−⋯ with four terms, and bound the error.

Show the solution
  1. Add four terms. With x=0.5: 0.5−0.125+0.041667−0.015625=0.401042
  2. Bound the error. The next term is 0.555=0.00625 so ln⁡1.5 lies between 0.401042 and 0.407292.
  3. Check. The true value is 0.405465, inside that range.

Answer ln⁡1.5≈0.401042, and the true value lies between 0.401042 and 0.407292.

Worked example

Estimate ∑n=1∞(−1)n+1n2 (exactly π2/12=0.8225) with five terms, and bound the error.

Show the solution
  1. Add five terms. 1−14+19−116+125=0.8386
  2. Bound the error. The alternating series bound says the error is less than the next term: 136=0.0278
  3. Compare with the true error. The true error is 0.0161. The partial sum overshoots because the last term added was positive.

Answer five terms give 0.8386, with an error bound of 0.0278; the true error is 0.0161.

Check

You add the first 10 terms of ∑n=1∞(−1)n+1n1. What is the alternating series bound on the error?

Check

How many terms of 1−13+15−⋯ guarantee an error below 0.01?

Check

What is 1−0.2+0.22−0.23+⋯?

Check

You estimate cos⁡1 with 1−x22+x424. What is the alternating series bound on the error?

Check

How does ∑(−1)nn converge?

Check

How does ∑(−1)nn2 converge?

Check

Bound the error of ∑(−1)n+1n1 after 5 terms.

(a)

What is the alternating-series bound?

(b)

How many terms guarantee an error below 0.0001?

Check

Use the alternating series for ln⁡(1+x) to bound an error.

Step 1

Write the first three terms of ln⁡(1+x).

Type it the way you would write it, like 3sin(2πft) or 3*sin(2*pi*f*t). Angles can be in radians or carry a degree sign, like 45°.

Explain why

Why is the error of an alternating series smaller than the first term you leave out?

Practice

Keep practicing

8 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.