1.15

From The Algorithm Design Manual Solution Wiki
Revision as of 12:18, 1 September 2020 by Algowikiadmin (talk | contribs) (Created page with "Call the statement <math>S_n</math> and the general term <math>a_n</math><br> <b>Step 1:</b> Show that the statement holds for the basis case <math>n = 0</math><br> :<math>a...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Call the statement [math]\displaystyle{ S_n }[/math] and the general term [math]\displaystyle{ a_n }[/math]

Step 1: Show that the statement holds for the basis case [math]\displaystyle{ n = 0 }[/math]

[math]\displaystyle{ a_0 = 0 \cdot (0 + 1)(0 + 2) = 0 }[/math]



[math]\displaystyle{ S_0 = \frac {0 \cdot (0 + 1)(0 + 2)(0 + 3)} {4} = \frac {0} {4} = 0 }[/math]

Since [math]\displaystyle{ a_n = S_n }[/math], the basis case is true.

Step 2: Assume that [math]\displaystyle{ n = k }[/math] holds.

[math]\displaystyle{ S_k = \frac {k(k + 1)(k + 2)(k + 3)} {4} }[/math]

Step 3: Show that on the assumption that the summation is true for k, it follows that it is true for k + 1.

[math]\displaystyle{ \begin{align} S_{k + 1} & = \sum_{i = 1}^k i(i + 1)(i + 2) + a_{k + 1} \\ & = \frac{k(k + 1)(k + 2)(k + 3)} {4} + (k + 1)((k + 1) + 1)((k + 1) + 2) \\ & = \frac{k(k + 1)(k + 2)(k + 3)} {4} + (k + 1)(k + 2)(k + 3) \\ & = \frac{k(k + 1)(k + 2)(k + 3)}{4} + \frac{4 \cdot (k + 1)(k + 2)(k + 3)} {4} \\ \end{align} }[/math]

It's easier to factor than expand. Notice the common factor of (k + 1)(k + 2)(k + 3).

[math]\displaystyle{ S_{k + 1} = \frac{(k + 1)(k + 2)(k + 3)(k + 4)}{4} }[/math]

This should be equal to the formula [math]\displaystyle{ S_k = \frac{k(k + 1)(k + 2)(k + 3)}{4} }[/math] when k = k + 1:

[math]\displaystyle{ \frac{(k + 1)((k + 1) + 1)((k + 2) + 2)((k + 1) + 3)} {4} = \frac{(k + 1)(k + 2)(k + 3)(k + 4)} {4} }[/math]

Since both the basis and the inductive step have been proved, it has now been proved by mathematical induction that S_n holds for all natural n.

Back to Chapter 1.