Put and let be the largest length. Expanding sums over all strings of source symbols, where is the total code length. By unique decodability, the concatenations of length in this sum are all distinct, so there are at most of them. Since ,
Taking th roots and sending to infinity proves the Kraft–McMillan inequality
Now is a probability distribution. With base-two logarithms, Gibbs inequality gives
Terms with contribute zero. Therefore
The normalization by is important: the raw numbers need not sum to one.

Articles by others on the same topic (0)

There are currently no matching articles.