Chuyển đến nội dung

Bài 32 · Sequences, Series and the Binomial Theorem

Arithmetic Sequences

Learn arithmetic sequences: common difference, the explicit and recursive formulas, finding terms, and Gauss's method for summing the first n terms.

A sequence is an ordered list of numbers: 2, 5, 8, 11, .... Each number is a term. Sequences describe stair-step patterns such as seat numbers in a theater, savings that grow by the same amount each month, or the cost of renting a bike for n days.

An arithmetic sequence is one where you add the same number each time. That number is the common difference d.

Formulas

Call the first term a₁ (or a). The recursive rule says how to get the next term from the previous one:

Text
a₁ = first term,   aₙ = aₙ₋₁ + d

The explicit rule jumps straight to term n. Term 2 adds d once, term 3 adds it twice, so term n adds it n - 1 times:

Text
aₙ = a₁ + (n - 1)·d

Example 1. For 2, 5, 8, 11, ...: a₁ = 2, d = 3, so aₙ = 2 + 3(n - 1) = 3n - 1. The 20th term: a₂₀ = 3·20 - 1 = 59.

Example 2. Is 100 in the sequence? Solve 3n - 1 = 100: n = 101/3, not a whole number, so no.

Example 3. An arithmetic sequence has a₃ = 11 and a₈ = 31. Between term 3 and 8 there are 5 steps, so 5d = 20, d = 4. Then a₁ = 11 - 2·4 = 3, and aₙ = 3 + 4(n - 1) = 4n - 1.

Notice that aₙ = dn + (a₁ - d) is a linear function of n. Its graph is a set of points on a line of slope d.

Adding the terms: arithmetic series

The sum of the first n terms is called a series, Sₙ = a₁ + a₂ + ... + aₙ.

The story goes that a young Carl Friedrich Gauss added 1 to 100 quickly by pairing the first and last, the second and second-to-last, and so on: each pair sums to 101, and there are 50 pairs, giving 5050. The same trick works for any arithmetic sequence. Write the sum forwards and backwards and add:

Text
Sₙ   = a₁ + a₂ + ... + aₙ
Sₙ   = aₙ + aₙ₋₁ + ... + a₁
2Sₙ  = n · (a₁ + aₙ)

So:

Text
Sₙ = n · (a₁ + aₙ) / 2  = n/2 · (2a₁ + (n - 1)d)

The sum equals the number of terms times the average of the first and last term.

Example 4. Sum of 2 + 5 + 8 + ... + 59 (20 terms): S₂₀ = 20·(2 + 59)/2 = 610.

Example 5. Total of 1 + 2 + ... + 100: 100·101/2 = 5050.

Example 6. A theater has 18 seats in row 1 and each next row has 2 more seats. With 25 rows, the last row has 18 + 24·2 = 66 seats, and the total is 25·(18 + 66)/2 = 1050 seats.

To find how many terms there are in a list such as 7, 11, ..., 143, use n = (last - first)/d + 1 = (143 - 7)/4 + 1 = 35.

Build the sequences with code

Python Explicit vs recursive vs sum formula

Press Run (or Ctrl + Enter) to see the result here.

Program input · what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Find a sequence from two terms

Python Recover an arithmetic sequence

Press Run (or Ctrl + Enter) to see the result here.

Program input · what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Check your understanding

Quick check · 4 questions

of 4 answered You scored / 4 · perfect!

  1. 1. What is the 15th term of 4, 9, 14, 19, ...?

    a₁ = 4, d = 5: a₁₅ = 4 + 14·5 = 74.
  2. 2. What is 1 + 2 + 3 + ... + 50?

    S = 50·51/2 = 1,275.
  3. 3. An arithmetic sequence has a₁ = 10 and d = -3. What is a₆?

    a₆ = 10 + 5·(-3) = -5.
  4. 4. Which formula gives the sum of the first n terms of an arithmetic sequence?

    The sum is the number of terms times the average of the first and last terms.

Summary

  • Arithmetic sequence: add the same d each time.
  • Explicit: aₙ = a₁ + (n - 1)d; recursive: aₙ = aₙ₋₁ + d.
  • Series: Sₙ = n(a₁ + aₙ)/2.
  • The terms lie on a straight line when graphed against n.

Next: Geometric Sequences

Theo dõi tiến độ của bạn

Tạo tài khoản miễn phí để đánh dấu bài đã học và tiếp tục từ chỗ bạn dừng lại trên mọi thiết bị.