Shannon's source coding theorem
Statement
Let a discrete memoryless source emit symbols from an alphabet according to a probability distribution with entropy (in bits, using ). Then for any , there exists a lossless block code with average length per symbol below for block length large enough; conversely, no lossless code can achieve an average length per symbol below . In short, the entropy is exactly the minimal achievable average number of bits per symbol.
Why is it true?
A message is only as long as the surprise it carries: a symbol that occurs with near certainty needs almost no bits to convey, while a rare symbol needs many. Entropy averages this 'surprise' (measured as ) over the whole source, giving a hard floor: you can compress common patterns away, but you can never compress a random source below the true unpredictability baked into its own statistics.
Proof sketch
For long blocks of i.i.d. symbols, the asymptotic equipartition property shows that almost all probability mass concentrates on a 'typical set' of roughly sequences, each with probability close to . Assigning short codewords (about bits) only to this typical set, and longer codewords to the negligible remainder, achieves average length close to per symbol; the converse follows because any code assigning fewer than bits on average would have too few codewords to cover the typical set without collisions, by a counting argument.
Stated by
Topics that use this theorem
Step-by-step proofs
No step-by-step proof yet for this theorem.
References
- Claude E. Shannon (1948). A Mathematical Theory of Communication
- Thomas M. Cover, Joy A. Thomas (2006). Elements of Information Theory