Math paradoxes

Benford's law 2, 4, 8, 16, 32… How many start with 1?Almost a third start with 1.

Take the powers of two from 2 to 21000 and look only at the first digit of each number. What share of them start with 1? Lock in your answer, then test it on a bank deposit and on a million products, and read why it works.

Take the powers of two from 2 to 21000 and look at the first digit. Of the 1,000 numbers, 301 start with 1, or 30%, and only 4.5% start with 9. A deposit earning interest, the Fibonacci numbers and products of random numbers behave the same way. This is Benford's law: P(d) = log10(1 + 1/d).

Make a guess
11.1%if all digits were equally likely
30.1%actually start with 1
The puzzle

A thousand numbers and their first digits

There is no mysterious data here. Every number on this page is generated by a simple rule: doubling, compound interest, Fibonacci numbers, products of random numbers. So you can check every result yourself.

  1. 1

    The numbers

    Start with 2 and keep doubling: 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024 and so on, all the way to 21000. The last one has 302 digits. That makes 1,000 numbers.

  2. 2

    The first digit

    From each number keep only the leftmost digit: for 16 it is 1, for 512 it is 5, for 1024 it is 1 again. A first digit is never 0, so there are nine options, 1 to 9.

    2481632641282565121024
  3. 3

    Not only powers of two

    You can ask the same question about a deposit growing 7% every year, or about the product of several random numbers between 1 and 10. Round 3 checks all of these sets.

  4. 4

    The question

    What share of the 1,000 powers of two start with the digit 1?

Intuition says

"There are nine digits, so each gets 1/9, about 11%"

In fact there are almost three times as many 1s: 30.1%. And 9 leads only 4.5% of the numbers. The digits are not equally likely, and the lead of 1 is no accident.

What matters

  • We count all 1,000 numbers from 21 to 21000, none skipped.
  • The numbers are exact, not rounded: a computer can handle whole numbers of any length.
  • Benford's law does not hold for every dataset. Rounds 3 and 4 show where it holds and where it fails.
Round 1 · Guess

What share start with 1?

Lock in your answer before reading on.

Lock in your answer before reading on. Then compare it with the exact count.

20%
0%10%20%30%40%50%

A breakdown of your answer will appear here.

Round 2 · Grow your money

A deposit with interest and a ruler from 1 to 10

Put money on deposit and watch the first digit of the balance year after year. The ruler below the chart shows where the balance is inside its current tenfold range: between 1,000 and 10,000, between 10,000 and 100,000 and so on. The ruler is logarithmic: multiplying by the same number always moves the marker by the same step.

Year0
Balance–
Years with first digit 1–

How to read the ruler

The ruler is split into nine zones by the balance's first digit. Zone "1" runs from 1 to 2, a full doubling. Zone "9" runs from 9 to 10, just +11%. That is why zone "1" takes 30% of the ruler and zone "9" only 4.6%.

The balance is multiplied by the same number every year, so the marker makes the same step to the right every year. When it reaches 10 it wraps around to the start of the next tenfold range, and the first digit is 1 again. The grey dots show the steps of recent years.

The histogram counts every year from zero. The bars show the share of years with each first digit, the black dots show Benford's law. With a small rate the Benford shape takes a while: the balance has to pass through several full tenfold ranges. Compound growth is also the engine of the duckweed lake puzzle.

Multiply random numbers

Multiplications0
Start with 1–
Exact at this step–

1,000 players

Each of 1,000 players starts with the number 1. On every press each player multiplies their number by a fresh random number, drawn uniformly between 1 and 10. The histogram shows the first digits of all 1,000 numbers. Here are five of the players:

After the first multiplication the numbers are uniform between 1 and 10, and every digit has a 1/9 chance. After just three multiplications the share of 1s is close to 30%. "Exact" is the exact distribution of a product of that many uniform numbers, computed with the formula from round 4.

Round 3 · Simulation

Four sets that follow Benford and one that does not

The first three sets are exact: the computer works out every number in full, with every digit. The fourth set is a simulation, because the products are random. The fifth set shows that the law does not always work.

Powers of two, 21…21000

Fibonacci numbers, F1…F1000

$100 at 7% a year, 1,000 years

Product of 10 random numbers from 1 to 10

Counterexample: whole numbers 1 to 999

Benford's law for digit 1
log10 2
= 0.30103 ≈ 30.1%
Equal digits
1/9
≈ 11.1% each
share of numbers starting with 1 share for digits 2–9 dots: Benford's law

The sets compared with Benford's law

SetStart with 1Largest gap

Largest gap: the largest of the nine differences between the set's share and Benford's law, in percentage points. For a product of 10 uniform numbers the exact distribution differs from Benford's law by less than 0.01 points, so the gap in the simulation is just random noise.

Round 4 · Explanations

Why 1 comes first

The key is that these numbers grow by multiplying, not by adding. And the natural scale for multiplying is logarithmic.

1 · The log scale

From 1 to 2 is 30% of the way to 10

Mark the stretch from 1 to 10 so that multiplying by 10 takes the full length. Then the point x sits at distance log10 x from the start. The zone of first digit 1 runs from 1 to 2, and its length is log10 2 ≈ 0.301. The zone of digit 9, from 9 to 10, has length log10(10/9) ≈ 0.046.

If numbers are spread evenly on this ruler, each digit's share equals the length of its zone. That is Benford's law.

2 · Growth lingers on 1

1,000 to 2,000 is slow, 9,000 to 10,000 is quick

At 7% a year, $1,000 becomes $2,000 in 10.2 years, and the whole time the balance starts with 1. Going from $9,000 to $10,000 takes only +11%, which is 1.6 years. The balance takes 34 years to cross a full tenfold range, from $1,000 to $10,000, and for 10.2 of those years (30%) it starts with 1.

3 · Changing units

Multiply everything by 3 and the law stays

First digit1239
2n30117612545
3 · 2n30117612546
1…999111111111111
3 · (1…999)3693693939

Imagine a first-digit law for prices. It cannot depend on the currency: converting dollars to another currency multiplies every price by the same number. The first digits of uniform numbers from 1 to 999 stop being uniform after multiplying by 3. A Benford set barely changes, because multiplying just shifts every point on the ruler by one step, and an even spread around a circle does not care about a shift.

4 · Products

Logs add up and smear out

The log of a product is the sum of the logs. On the ruler from 1 to 10 every multiplication adds a random step, and when the marker passes 10 it wraps to the start. A few random steps around a circle leave an almost even position. The share of 1s for a product of 1, 2, 3 and 10 uniform numbers from 1 to 10 is 11.1%, 24.1%, 30.1% and 30.10%.

A sum of many random quantities is approximately normal. So a sum of random numbers, unlike a product, does not give Benford's distribution: it stays inside one narrow range.

5 · Where it fails

Narrow ranges and assigned numbers

The law needs numbers spread over several orders of magnitude. Do not expect it from adult heights (almost all between 1.5 and 2 metres), ages, grades, phone numbers, apartment numbers or prices like 9.99. The uniform numbers from 1 to 999 in round 3 give every digit exactly 111 numbers, that is 11.1%.

And the other way round: a wide range is no guarantee. Powers of ten all start with 1. Powers of two written in base 8 start only with 1, 2 or 4. Round 5 shows this.

Why powers of two exactly

log10 2 is irrational

Each doubling moves the marker on the ruler by log10 2 ≈ 0.30103. If that step were a fraction p/q, the marker would return to the same spot after q steps and cycle through q points. But log10 2 is irrational: 2a never equals 10b. So, by Weyl's equidistribution theorem, the marker's positions cover the circle evenly, and the share of steps in zone "1" tends to 0.30103.

For formula lovers

The first digit depends only on the fractional part of the log

first digit of x = d  ⇔  {log10 x} ∈ [log10 d, log10(d + 1))   where {·} is the fractional part
P(d) = log10(d + 1) − log10 d = log10(1 + 1/d)  →  P(1) = log10 2 = 30.10%,  P(9) = log10(10/9) = 4.58%
First two digits: P(12) = log10(1 + 1/12) ≈ 3.48%,  P(99) = log10(100/99) ≈ 0.44%
Second digit: P₂(k) = Σd=1…9 log10(1 + 1/(10d + k))  →  P₂(0) ≈ 11.97%,  P₂(9) ≈ 8.50%
Base b: P(d) = logb(1 + 1/d),  d = 1…b − 1
Product of k uniform numbers on [1, 10]: E[e2πin·log10U] = ln 10 / (ln 10 + 2πin)  →  coefficients (ln 10 / (ln 10 + 2πin))k → 0

The last formula explains round 2: the deviation from Benford's law for a product of k numbers is controlled by Fourier coefficients whose size is (ln 10 / √(ln²10 + 4π²n²))k, about 0.34k for n = 1. Each new multiplication shrinks the deviation roughly threefold.

Round 5 · Going further

Scale, the second digit and other bases

Test three properties of the law: it survives a change of scale, it has a version for the second digit, and it works in other bases.

Multiply the whole set by a number

Powers of two × c

Numbers 1…999 × c

Scale invariance

The law does not know the units

Move the slider. The left histogram barely moves for any factor: first digit 1 stays near 30%. The right one jumps: at ×2 the numbers from 5 to 9, from 50 to 99 and from 500 to 999 all start with 1 once doubled. That is 555 numbers out of 999, or 55.6%.

The converse can be proved too: if the distribution of first digits does not change when the data are multiplied by any number, it has to be Benford's law. That is why it shows up where data are not tied to particular units.

Counts are exact: the factor has two decimals, so c = m/100, and the first digit of 2n · c is the same as that of the whole number 2n · m.

The second digit

The second-digit law

The second digit is almost even

The second digit can be 0, so there are ten options. Zero is a little more common (11.97%) and 9 a little rarer (8.50%), but the gap is much smaller than for the first digit. For the third and later digits the distribution approaches a flat 10% even faster.

The dots show the law, the bars show the count for numbers of 10 and above: 997 powers of two (from 24 = 16), 994 Fibonacci numbers (from F7 = 13) and 1,000 deposit balances.

Other bases

Base b

The same ruler, a different length

In base b the first digit d has share logb(1 + 1/d). In base 8 the digit 1 gets 1/3, in base 16 it gets 1/4. In base 2 every number starts with 1, so the law holds there but says nothing.

Pick powers of two and base 8. Each doubling moves the marker by log8 2 = 1/3, a rational number. The marker cycles through three points, and the numbers start only with 1, 2 or 4. The same happens in bases 4 and 16. Fibonacci numbers fall into no such trap in any base.

Auditing and data checks

A reason to look closer, not proof

Auditors use Benford's law as a rough filter. If a dataset that usually follows the law shows first digits that clearly deviate from it, some of the records deserve a manual check. The best-known advocate of this approach, the accounting researcher Mark Nigrini, described it in his book "Benford's Law: Applications for Forensic Accounting, Auditing, and Fraud Detection" (2012).

But a deviation proves nothing by itself. Plenty of honest data does not follow the law: narrow ranges, assigned numbers, prices with thresholds like 9.99. And a forger who knows about the law can stick to it. So a deviation is only a reason to ask questions.

Bonus · Fun facts

Things to tell your friends

1881

Worn pages

The astronomer Simon Newcomb noticed that in books of logarithm tables the first pages, with numbers starting with 1, were much more worn than the rest. In 1881 he published a note in the "American Journal of Mathematics" with the rule: the first digit N appears with probability log(N + 1) − log N.

20,229

Benford's observations

In 1938 the physicist Frank Benford tested the law on 20,229 numbers from 20 different sources: the areas of 335 rivers, 3,259 US population figures, 104 physical constants, 1,800 molecular weights, 418 death rates and more. The paper was called "The Law of Anomalous Numbers".

57 years

Stigler's law

Newcomb described the law 57 years earlier, yet it was named after Benford. That makes it an example of Stigler's law: scientific discoveries are often named after someone other than the person who made them first.

1995

Hill's explanation

In 1995 the mathematician Theodore Hill proved that the law arises when data from many different distributions are mixed: first a distribution is picked at random, then a number from it. The same year he showed that invariance under a change of base also leads to Benford's law.

2n · Fn · n!

Sequences that obey exactly

For some infinite sequences Benford's law is proved rigorously: the Fibonacci numbers, the factorials, the powers of two and the powers of almost any number k. The condition for powers is that log10 k be irrational. Powers of 10 or 100 fail it.

2020

A failed election check

After the 2020 US election, Benford's law was applied to precinct results in Chicago, Milwaukee and other places. That was a misuse: precinct vote counts rarely go beyond the range from a few dozen to a few thousand, and in such a narrow range the law should not be expected to hold.

Discussion

What do you think?

Share your own explanation, an objection or a variant of the puzzle. You need a GitHub account to comment.

Newsletter

New puzzles, explanations and discussions

I keep adding new puzzles, new ways to explain them and write-ups of the discussions they start. Leave your email and I'll write when something new is out. No spam, one-click unsubscribe.

The sign-up form will appear here soon.