An efficient algorithm for computing the entropy of output sequences for bitshift channels