summation of (16^i)(n/(4^i))^2 from 0 to k-1