<s>[INST] Summation of simple sequence This is a fairly simple question, I'm sure, but I appear to be having trouble. What is the result of the following sequence:
$$\frac{1}{2}+\frac{2}{4}+\frac{3}{8}+ .... + \frac{n}{2^{n}}.$$ ?
Thanks
 [/INST] $$2S_n-S_n=\left(\frac11+\frac{2}{2}+\frac{3}{4}+\cdots+ \frac{n}{2^{n-1}}\right)-\left(\frac{1}{2}+\frac{2}{4}+\frac{3}{8}+ \cdots+ \frac{n}{2^{n}}\right)\\
=1+\frac{1}{2}+\frac{1}{4}+ \cdots+ \frac{1}{2^{n-1}}-\frac n{2^n}=2-\frac{n+2}{2^n}.$$
</s>