Real World Maths Busters

The Maths Behind Everyday Life

The story, the formula and a worked example — see exactly where this maths shows up in the world around you.

Back to all stories
Technology 4 min read

QR Code Error Correction

How QR codes work even when damaged.

At Level H, 30% of the data modules can be corrupted and the code still scans. That’s why you can put a logo over the centre.

Error correction capacity

Each level defines how many codewords can be corrected.

Correctable errors=t2 (where t=redundant codewords)\text{Correctable errors} = \frac{t}{2} \text{ (where } t = \text{redundant codewords)}

Level H with 100 codewords

  1. 1

    Step

    Redundant: 30 codewords

  2. 2

    Step

    Correctable: up to 15 damaged codewords

  3. 3

    Step

    Or 30 erasures (known positions)

Answer

30% damage tolerance

The formula behind it

Combinations

(nr)=n!r!(n−r)!\binom{n}{r} = \frac{n!}{r!(n-r)!}
See the full formula, variables and more examples

The takeaway

The logo in the middle of a QR code? It’s not a hack — it’s error correction doing its job.

Back to all stories