Statistics & Simulation — TNT Interactive

Galton Board Simulator

Drop balls through a rectangular quincunx of pegs. Watch the Central Limit Theorem emerge before your eyes — or switch to the classic triangular layout to see Galton’s original design.

About this simulation — Sir Francis Galton’s Bell Curve Machine

The Galton Board (also called a bean machine or quincunx) was invented by Sir Francis Galton in 1889 to demonstrate how random processes naturally produce the bell-shaped normal distribution. Balls are dropped from the top and fall through an array of pegs. At each peg, a ball has a 50/50 chance of bouncing left or right — just like flipping a coin.

After passing through many rows of pegs, the balls collect in bins at the bottom. With enough balls, the height of each bin’s pile traces out a binomial distribution — which, by the Central Limit Theorem, converges to the Normal (Gaussian) bell curve as the number of rows grows.

The math in one line: The probability a ball lands in bin k after n peg rows is P(k) = C(n,k) × (1/2)n, where C(n,k) is “n choose k.” The gold curve overlay shows this theoretical binomial PMF scaled to the live data.

AP Statistics connection: This IS the bell curve in motion. Each ball is a sequence of independent coin flips. The bin it lands in equals the number of right-bounces out of n flips. The sum of many independent random variables converges to Normal — and you can watch it happen in real time.

Simulator Settings — Quick Reference

  • Default layout — Rectangle: Rows alternate n and n+1 pegs, filling the full board width. Bell Curve Priority (default) places edge pegs near the walls for cleaner containment — occasional sticking possible. Anti-Stuck insets edge pegs so no ball can be pinched — no sticking, but slight edge leakage. Switch to Triangle to see Galton’s original design with its characteristic edge-leakage effect.
  • Canvas size — Computed vs Fixed: Computed (default) scales the canvas height so row spacing is always dense enough for reliable peg interactions at any row count. Fixed keeps the classic 720 px board — useful for comparing the effect of row spacing on the distribution shape, especially at small row counts (≤ 10) where the wider gaps let diagonal balls skip rows. Toggling between the two is a classroom demonstration of how a single simulation parameter affects statistical validity.
  • Ball–Ball Physics: When on, balls exchange momentum on contact — useful for physics demonstrations, but this breaks the statistical independence assumption. The distribution will deviate from the theoretical binomial/Normal model.
  • Snapshot: Captures the board mid-run. Click Open in New Tab in the modal to park the image safely without interrupting the simulation. See the Chat Log for every design decision.

Ball Controls

Board Configuration
Triangle
Rectangle

Switch before dropping balls.

Anti-Stuck
Bell Curve
0 = 14-row fixed spacing. Fine-tune from this base.
0 = calculated. Negative = tighter pegs (recommended for 1–4 rows).

Physics
Ball–Ball Physics
Off
On

Statistics — Empirical
Total Balls 0
Mean Bin —
Median Bin —
Mode Bin —
Std Dev —
Shape —

Gold Curve — Theoretical

The gold curve is the exact binomial PMF:
P(k) = C(n,k) × (½)n
for n = 14 peg rows, p = ½. It uses none of the empirical data — it is the mathematically predicted shape. As more balls fall, the histogram above converges toward this curve (Central Limit Theorem).

Predicted Mean 7.00
Predicted σ 1.87