function H=hn(h,n) H = sum(h.^(0:n-1)); return