1=2-1
1+1/2=2-1/2
1+1/2+1/4=2-1/4
1+1/2+1/4+1/8=2-1/8
……
1+1/2+1/4+……+1/2^(n-1)=2-1/2^(n-1)
上述各式相加得
数列:1,1+1/2,1+1/2+1/4,1+1/2+1/4+1/8+……的前n项和
=1+(1+1/2)+(1+1/2+1/4)+(1+1/2+1/4+1/8)+……+[1+1/2+1/4+……+1/2^(n-1)]
=(2-1)+(2-1/2)+(2-1/4)+(2-1/8)+……+[2-1/2^(n-1)]
=2n-[1+1/2+1/4+……+1/2^(n-1)]
=2n-[2-1/2^(n-1)]
=2(n-1)+1/2^(n-1)