Labs / Mathematics
Law of Large Numbers
Every trial adds one more roll to the pile, and the pink line tracks the average of every roll so far. Early on it lurches around wildly, but as the number of trials climbs it is pulled toward the expected value E — the shaded funnel shows how fast the wiggle room shrinks. Turn up the rolls per second or fire off a thousand at once and watch the gap close.
trials 0avg —E 3.50gap —
What to try
- Why does the average swing so violently in the first few dozen rolls, then barely move at all after a few thousand?
- Switch to the coin. Does "heads or tails" converge to its expected value faster or slower than a 20-sided die?
- Hit Reset a few times — does the line always approach E from the same side, or is the path different every run?
- Roll 1000 in one burst. How much does the gap between the average and E shrink with each extra thousand trials?
- The funnel narrows like one-over-square-root-of-n. To halve the typical gap, how many more times do you need to roll?