Attic › Mathematics › Claude Shannon

Information is a measure of surprise, and its unit is the bit

About Information theory

In his 1948 paper, Shannon defined information mathematically by separating a message from its human meaning. He showed that the amount of information in a message depends only on how surprising it is, and he introduced the bit as the universal unit to measure it.

For a communication engineer, what a message means does not matter. The goal is simply to reproduce at Point B the exact sequence of symbols that was chosen at Point A. Shannon realized that communication only happens when the receiver does not already know which message the sender will choose.

Therefore, Shannon defined information through probability:

1. Certainty gives zero information: If a weather station only ever sends the message "It is sunny," the receiver already knows what is coming. Receiving the message resolves no uncertainty and gives no information.

2. Equal choices give basic units: Suppose a sender flips a fair coin. There are two equally likely outcomes: heads or tails. Learning the result cuts the possibilities in half. Shannon called this single two-way choice (represented as 1 or 0) a bit, short for binary digit (a term he formally introduced).

3. More choices require more bits: If there are 8 equally likely messages, you can find the chosen one by asking 3 yes-or-no questions, where each answer cuts the remaining choices in half (8 → 4 → 2 → 1). Mathematically, 2³ = 8, so the base-2 logarithm of 8 is 3: choosing one message out of 8 gives 3 bits of information.

4. Unequal probabilities lower the average: Real messages are not equally likely. In English, the letter "E" appears much more often than "Z", and "Q" is almost always followed by "U". Because "U" is expected after "Q", seeing it is not surprising and carries very little new information.

To measure the average information produced by any source—such as an English writer or a microphone—Shannon used a formula from physics called entropy, written as H:

H = −∑ pᵢ log₂(pᵢ)

In this formula, pᵢ is the probability of each possible symbol, and ∑ means to add the results for all symbols. Entropy measures the average number of bits of actual information per symbol.

This formula created the science of data compression. Shannon's source coding theorem proves that you can compress any file without losing data by using short binary codes for common symbols (like "E") and long codes for rare ones (like "Z"), down to the exact limit of the source's entropy, and no further.

Fact-checked against Claude Shannon on Wikipedia

Part of the Mathematics syllabus: Computation, Information, and Strategy

See it on the timeline of Computation, Information, and Strategy