Journal · Probability

The Galton board: a simulation, and the history of Galton's quincunx

Drop balls down a Galton board, first with a coin at every peg, then with nothing but bounces. Then the history: lead shot, a Victorian lecture, a trap door, and a word Galton should be remembered for less fondly.

A Galton board is a sloping board of pegs with a row of slots at the bottom. Pour balls in at the top and each one rattles down through the pegs, bouncing left or right, and lands in a slot. One ball tells you nothing. A few thousand build the same shape every time: a heap in the middle that falls away on both sides, the bell curve. It is also called a bean machine, and its inventor, Francis Galton, called it a quincunx.

Below are two versions of the board. In the first, every peg is a fair coin. In the second, nobody flips a coin at all: the balls fall and bounce off round pegs, and the only chance anywhere is a tiny difference in where each ball starts. Then the history of the thing, which is stranger and darker than a desk toy suggests.

Drop some balls

Try it: a Galton board simulation

Bars: where the balls landed. Dots: what coin flips predict for that many balls.

The board needs JavaScript. Without it, the answer in words: with 12 rows of fair pegs, 924 of the 4,096 possible paths end in the middle slot, and the counts fall away on both sides in the shape of a bell.

Start with Coin flips and Drop 100, then Add 10,000 at once. The bars climb towards the gold dots, which are what coin flips predict. Move the chance of bouncing right away from 50% and the whole heap slides sideways but keeps its shape. Change the number of rows and the heap widens or narrows.

Then switch to Bounces. The board restarts with a wider field of pins. The balls now obey a small physics engine: gravity, round pins and a bounciness. Add 10,000 at the settings shown and you get a bell again, though not the same bell. Now move the bounciness and add 10,000 again. That is the part of this page we found most interesting, and it has its own section below.

Why the bell appears

Take the coin version with 12 rows. At each row the ball goes left or right, so a ball's whole journey is a list of 12 lefts and rights, and there are 2 × 2 × … twelve times, 4,096, possible lists. The slot a ball lands in depends only on how many of its 12 bounces went right. Only one path ends in the far left slot: left every time. But 924 different paths end in the middle slot, six rights and six lefts in some order. So with fair pegs the middle slot catches 924 balls in every 4,096, about 22.6%, and the far left slot catches 1.

The number of paths into each slot is a row of Pascal's triangle: 1, 12, 66, 220, 495, 792, 924, 792, 495, 220, 66, 12, 1. The five middle slots hold 85.4% of the paths between them. Nothing pushes a ball towards the middle. There are simply far more ways to get there.

The spread of a pile like this, its standard deviation, is the square root of the number of rows times the chance of going right times the chance of going left. For 12 fair rows that is 1.73 slots. Quadruple the rows and the spread only doubles, which is why a long run of coin flips is more predictable as a share than a short one.

The bell shape itself was found long before Galton. In November 1733 the mathematician Abraham de Moivre circulated a short Latin paper among friends showing that the counts in a row of Pascal's triangle, for a large number of coins, follow a smooth curve, the one we now call the normal curve. He printed it in English in the second edition of The Doctrine of Chances in 1738. Galton's contribution was to make the arithmetic visible, in wood and glass, so that a room could watch it happen.

No coins, just bounces

The coin version is the textbook ideal: every peg an independent, fair fifty-fifty. A wooden board has no coins in it. A ball falls, strikes a pin slightly off centre, and goes where the geometry sends it. Physics like this has no randomness of its own: drop two balls from exactly the same spot and they take exactly the same path. So where does the bell come from?

From amplification. A ball that strikes a pin a hair to the left of centre leaves at a slightly different angle, so it meets the next pin further off centre, and so on down the board. In the Bounces version each ball starts within 2 hundredths of a peg gap of the centre line. Narrow that to a millionth of a peg gap and 10,000 balls still spread out, with a spread of 2.11 slots, wider than fair coins give. The pins turn a difference far too small to see into a pile many slots wide.

The Bounces board is laid out as Galton laid out his: a full-width field of pins rather than a triangle, with side walls far enough out that balls almost never reach them. At the settings in the text, bounciness 0.35 and 12 rows, 10,000 balls land with an average slot of 6.02 and a spread of 2.38 slots, and not one touches a wall. Fair coins predict a spread of 1.73. At this setting the bounce bell is more than a third wider, and its middle slot holds 1,650 balls where coins would put about 2,256.

One thing going on is that bounces are not independent coin flips. In this engine a ball's moves are linked: over 2,000 balls at those settings, the move from one row to the next went the same way as the move before it 64% of the time, where fair coins would give 50%. That is not the whole story, because the moves are also smaller than a coin's half-gap step, and the two pull in opposite directions. Make the board taller and the bounce pile stays the wider of the two: at 16 rows its spread is 2.88 against 2.00 for coins.

How wide the bell comes out depends on the bounciness, and not smoothly. At 0.35 the spread is 2.38, but at 0.3 it is 1.83, at 0.4, 2.02, and at 0.7, 3.51, by which point a few dozen balls in every 10,000 bounce far enough out to touch a wall. Turn the bounciness right down to 0.1 and on this short board the bell does not form at all: nearly all of 10,000 balls fall into four slots, two on each side of the middle, and the middle slot itself gets fewer than any of them. Try the slider; the shape changes at almost every step.

Physicists have studied the Galton board as a problem in mechanics. Valery Kozlov and Marina Mitrofanova, modelling frictionless balls on boards far larger than this one and wide enough that the balls never reach the walls, found in 2003 that the final pile depends on how bouncy the balls are, how big the pins are and how widely the balls leave the funnel. With a narrow funnel and moderate bounciness they got piles practically indistinguishable from the normal curve, while a wide, even start gave side peaks and gaps. Our four channels at low bounciness are not their finding: they are an effect of our short, twelve-row board. Whatever bell a real board makes depends on choices its maker made, in the pins, the balls and the spacing. Our own first attempt, on an off-the-shelf physics engine in a notebook, took a good deal of tuning of bounciness and friction before it made one.

What the bounce engine is

A small two-dimensional model written for this page: round pins, two far side walls, one bounciness for every touch, and fixed time steps. It has no friction, because its balls cannot spin, and a ball with friction but no spin sticks on the shoulder of a pin where a real one would roll off. Balls also pass through one another, which real ones do not. Every claim about it above was also checked with a time step three times smaller, and holds there; the spread at the settings in the text moves from 2.38 to 2.42. Exact counts at other settings do change with the step, which is one more reason to read them as this model's, not any wooden board's. To check the text against the board, choose Bounces, press Back to the settings in the text, then Add 10,000 at once: the line under the board should read Middle slot: 1,650.

The man and the machine

Francis Galton (1822–1911) was an English explorer, statistician and inveterate measurer, and a half-cousin of Charles Darwin: they shared a grandfather, Erasmus Darwin. After Darwin published On the Origin of Species in 1859, Galton turned to heredity, and to the question of how variation in a population could stay the same from one generation to the next.

He had the board built to his own design in 1873 by Tisley and Spiller, instrument makers in London. It was filled not with balls but with small lead shot, and he used it to illustrate a lecture at the Royal Institution in 1874. That instrument survives in the Galton Collection at University College London. The collection's catalogue transcribes its handwritten label as "Instrument to illustrate the Law of Error on Dispersion".

He described it again in his book Natural Inheritance in 1889, plainly enough to build from:

"It is a frame glazed in front, leaving a depth of about a quarter of an inch behind the glass. Strips are placed in the upper part to act as a funnel. Below the outlet of the funnel stand a succession of rows of pins stuck squarely into the backboard, and below these again are a series of vertical compartments. A charge of small shot is inclosed."

Francis Galton, Natural Inheritance, 1889, chapter V

The pins, he wrote, "are disposed in a quincunx fashion". A quincunx is five points arranged like the five on a die, four at the corners and one in the middle. The word is Latin, the name of a Roman coin worth five twelfths, and English writers used it for that pattern long before Galton: Thomas Browne wrote a whole book about quincunx plantings in 1658. Tilt a grid of quincunxes and you get rows of pegs, each one sitting over the gap in the row above. That is the Galton board's layout, and the name stuck to the device.

Galton was moved by what it showed. A few pages on, under the heading "Order in Apparent Chaos", he wrote that he knew of "scarcely anything so apt to impress the imagination" as the bell curve, and that the Greeks would have made it a god if they had known of it.

The trap door: from a bell to regression

The board's most important use was not the single bell. In a letter to George Darwin on 12 January 1877, Galton described how he might cut the apparatus across and insert, halfway down, a row of compartments with trap door bottoms. Shot falls through the top half and is caught in the middle compartments, in a bell. Open one trap door and the shot from that compartment falls through the bottom half and makes a small bell of its own. Open them all and the small bells add up to one large bell, wider than the first. He printed the design, with a diagram, in Natural Inheritance in 1889, together with the rule behind it: add two independent normal scatters and the result is normal, with a spread whose square is the sum of their squares.

The point was heredity, and it posed a problem. Think of each compartment as parents of one size and its small bell as the scatter of their children. If every family scattered like that and nothing pulled back, each generation would be more spread out than the last, and populations do not widen like that from one generation to the next. So something must pull offspring back towards the average. Galton called that pull reversion, borrowing a word that Darwin and animal breeders used for a return to ancestral forms. In his Royal Institution lecture "Typical Laws of Heredity", on 9 February 1877, Galton used a quincunx with sloping chutes to illustrate that pull.

The historian of statistics Stephen Stigler has traced how Galton, thinking about such boards and about running one in reverse (given where a child landed, where did its parents probably sit?), came by 1885, working from measurements of families, to what he called regression towards mediocrity, now regression to the mean, and from there to correlation. A good deal of modern statistics passes through that trap door.

The part of the record that is not a toy

Galton also coined the word eugenics, in a footnote to his 1883 book Inquiries into Human Faculty, and spent much of the rest of his life promoting the idea that human populations should be improved by controlling who has children. The same pages that describe the quincunx use it to explain, in his words, "the reason why mediocrity is so common". His statistics were real and lasting. The uses he wanted them put to were not, and the movement he named went on to support forced sterilisation and worse in the twentieth century.

On 19 June 2020 University College London, which holds his quincunx, took Galton's name off a lecture theatre, and Karl Pearson's, the first holder of the eugenics chair Galton endowed there, off another lecture theatre and a building. A board of pegs proves nothing about people, and Galton's own trap door shows the limit: the bell describes a whole population, and for any one ball, or any one child, it gives odds, never a destiny.

What this page does not show

The coin board shows the binomial distribution exactly, and how it approaches the normal curve. It does not show that everything in nature is normal; many things are not, from incomes to the sizes of cities. The bounce board shows that mechanics alone can make a bell, that it need not match the coin bell, and that on a short board it can fail to appear. It is a two-dimensional model with no friction and balls that pass through one another, so its exact counts belong to this model, not to any board you can buy. And a bell in the slots is a statement about thousands of balls together, never a prediction for the next one.

If you like this kind of thing, our voter turnout simulation drops whole elections down a Galton board, and Benford's law is another shape that numbers make on their own.

Sources

  1. Galton, F. (1877). "Typical laws of heredity." Proceedings of the Royal Institution of Great Britain 8, from p. 282. Lecture of Friday 9 February 1877. Scans at galton.org.
  2. Galton, F. to George Darwin, 12 January 1877. Printed in K. Pearson, The Life, Letters and Labours of Francis Galton, vol. IIIB (1930), pp. 465–466.
  3. Galton, F. (1889). Natural Inheritance. Macmillan. Chapter V, "Normal Variability," pp. 63–68, figures 7 and 8. galton.org.
  4. Galton, F. (1883). Inquiries into Human Faculty and its Development. Macmillan. The footnote that introduces the word eugenics.
  5. Stigler, S. M. (2010). "Darwin, Galton and the statistical enlightenment." Journal of the Royal Statistical Society, Series A 173(3), 469–482.
  6. UCL Science Collections. Galton Collection, quincunx, LDUGC-063. Tisley and Spiller, London, 1873, made to Galton's design. collections.ucl.ac.uk.
  7. de Moivre, A. (1733). Approximatio ad Summam Terminorum Binomii (a+b)n in Seriem expansi. Privately printed, November 1733. English version in The Doctrine of Chances, 2nd edition (1738), pp. 235–243. Helen Walker's edition, University of York.
  8. Browne, T. (1658). The Garden of Cyrus, or the Quincunciall Lozenge, or Net-work Plantations of the Ancients.
  9. Kozlov, V. V. and Mitrofanova, M. Yu. (2003). "Galton board." Regular and Chaotic Dynamics 8(4), 431–439. arXiv: nlin/0503024.
  10. University College London (2020). "UCL denames buildings named after eugenicists," 19 June 2020. ucl.ac.uk.

The board runs entirely in your browser. Nothing you press in it is sent anywhere.