>>906
a(n) = Σ[k=0〜(n-1)]2^k
S(n) = Σ[k=1〜n]a(k)