Let T={1,2,…,n}. For a subset S={s1,s2,…,sk}⊆T where s1>s2>⋯>sk, define
f(S)=s1−s2+s3−s4+…;
g(S)=s1−s3+s5−s7+…,
that is, g is the weighted sum obtained by giving weights 1,0,−1,0 in order and cyclically, while f is the weighted sum obtained by giving weights 1,−1 in order and cyclically; clearly, f(∅)=g(∅)=0.
a. Find a formula for ∑S⊆Tf(S), that is, the sum of f(S) over all subsets S⊆T.
b. Find a formula for ∑S⊆Tg(S).
c. If you cannot solve (b), then likewise find ∑S⊆Tg(S), but this time let T={1,2,…,8}.