taocp

This site has no text of the book. Keep your own copy of TAOCP next to it. See what is checked.

Exercise · Volume 1 · 1.2.3-9

Exercise 1.2.3-9

not stated yet in Lean solution written

Rating05
Markersrecommended
KindK2, decide: say whether a claim holds from the written solution
SectionSection 1.2.3 of Volume 1. Companion chapter: Sums and products

The task

Decide whether the derivation of the geometric sum, Eq. (14), is correct when n=−1n = -1.

The exact wording is in your copy of the book.

Hints

Open one hint at a time. Try the exercise again after each.

Hint 1

Go through the steps of Example 3 and ask for each step which values of nn it needs. The step that splits off the term j=0j = 0 is the first to check.

Solution

Show the solution

The answer is no. The derivation splits ∑0≤j≤naxj\sum_{0 \le j \le n} ax^j into the term j=0j = 0 and the sum over 1≤j≤n1 \le j \le n by rule (d). That rule needs the relations "j=0j = 0" and "1≤j≤n1 \le j \le n" to combine to "0≤j≤n0 \le j \le n". For n=−1n = -1 this is false: the relation 0≤j≤−10 \le j \le -1 holds for no jj, but "j=0j = 0 or 1≤j≤−11 \le j \le -1" holds for j=0j = 0. In numbers, the left side of the step is 00 and the right side is a+0=aa + 0 = a.

The last step of the derivation has the same flaw: it adds and subtracts the term axnax^n to extend ∑0≤j≤n−1\sum_{0 \le j \le n-1} to ∑0≤j≤n\sum_{0 \le j \le n}, which needs n≥0n \ge 0.

The formula itself is correct for n=−1n = -1. The left side is the empty sum 00, and the right side is a(1−x0)/(1−x)=0a(1 - x^{0})/(1 - x) = 0. So the result is right, but the derivation does not prove it.

Check

For n=−1n = -1, the failing step reads ∑0≤j≤−1axj=a+∑1≤j≤−1axj\sum_{0 \le j \le -1} ax^j = a + \sum_{1 \le j \le -1} ax^j, that is 0=a0 = a, false for a≠0a \ne 0. For n=0n = 0 it reads a=a+0a = a + 0, true.

Remarks

Exercise 1.2.3-10 shows that for n=−2n = -2 the result itself is wrong, so the condition n≥0n \ge 0 matters there. The C1 chapter on Section 1.2.3 gives the derivation with the range of nn stated at each step.

This solution is checked, and a person has not reviewed it yet. The source.

In Lean

not stated yet The exercise is not stated in Lean yet.

The status is computed from the Lean build. The node of the map.

Something is wrong? Report it.