Talk:Introduction-TADM2E

From Algorithm Wiki
Revision as of 08:18, 9 October 2015 by Parth (talk | contribs) (Solution for TADM2E 1.10 and 1.12)
Jump to: navigation, search

As some even number problem's solution has already been provided so please find solution for following


TADM2E 1.10

First we'll verify the base case for $ n = 1 $ :

$ \sum_{i=1}^1 i = \frac{1(1+1)}{2} = 1 $

Now, we'll assume given statement is true up to $ n - 1 $.

So,

$ \sum_{i=1}^{n-1} i = \frac{(n-1)(n-1+1)}{2} = \frac{(n-1)n}{2} $

To prove for the general case $ n $,

$ \sum_{i=1}^n i = \sum_{i=1}^{n-1} i + n = \frac{(n-1)n}{2} + n = \frac{n^2 - n + 2n}{2} = \frac{n^2 + n}{2} = \frac{n(n+1)}{2} $

TADM2E 1.12

First we'll verify the base case for $ n = 1 $ :

$ \sum_{i=1}^1 i^3 = 1^3 = \frac{(1)^2(1+1)^2}{4} = 1 $

Now, we'll assume given statement is true up to $ n - 1 $.
So, following statement is true.

$ \sum_{i=1}^{n-1} i^3 = \frac{(n-1)^2(n-1+1)^2}{4} = \frac{(n-1)^2n^2}{4} $

To prove for the general case $ n $,

$ \begin{align} \sum_{i=1}^{n} i^3 & = \sum_{i=1}^{n-1} i^3 + n^3 \\ & = \frac{(n-1)^2n^2}{4} + n^3 \\ & = \frac{(n^2 - 2n + 1)n^2 + 4n^3}{4} \\ & = \frac{n^4 - 2n^3 + n^2 + 4n^3}{4} \\ & = \frac{n^4 + 2n^3 + n^2}{4} \\ & = \frac{n^2(n^2 + 2n + 1)}{4} \\ \sum_{i=1}^{n} i^3 & = \frac{n^2(n + 1)^2}{4} \\ \end{align} $