how can I calculate the sum of the n first elements :
$$ 1\cdot 2 +2\cdot2^2 +3\cdot2^3+4\cdot2^4+\cdots+k\cdot2^k+\cdots$$
I don't have idea although I tried some tricks.
I will be happy for help from you
how can I calculate the sum of the n first elements :
$$ 1\cdot 2 +2\cdot2^2 +3\cdot2^3+4\cdot2^4+\cdots+k\cdot2^k+\cdots$$
I don't have idea although I tried some tricks.
I will be happy for help from you
Hint:
Simple answers are already provided which are most general. There is another approach:
$$S = \sum_{k=1}^{n} k \cdot 2^k\\ 2S = \sum_{k=1}^{n} k\cdot 2^{k+1} = \sum_{k=1}^{n} (k+1)\cdot 2^{k+1} - \sum_{k=1}^{n}2^{k+1} = S-2+(n+1)\cdot 2^{n+1} - \sum_{k=1}^{n}2^{k+1}$$
Now use the formula of Gp to get $\sum_{k=1}^{n}2^{k+1} = 4(2^{n}-1)$
$$S = -2 + n\cdot 2^{n+1}+2^{n+1}-2^{n+2}+4 \\ = 2 + (n-1)\cdot2^{n+1}$$
$$\sum_{k=1}^nk2^k=2\sum_{k=1}^nk2^{k-1}=2\left(\sum_{k=1}^nx^n\right)'_{x=2}=2\left(\frac{x^{n+1}-1}{x-1}\right)'_{x=2}=$$ $$=2((n+1)2^n-2^{n+1}+1)=n2^{n+1}-2^{n+1}+2.$$