Put chance to the test.
One coin, many trials. Watch the proportion of heads change as the sample grows.
CUMULATIVE PROPORTION OF HEADSDashed line: theoretical probability
Heads—
Tails—
Observed frequency—
What we are testing
P(cara) = p
Frecuencia observada = caras / n
Caras esperadas = n × p
Frecuencia observada = caras / n
Caras esperadas = n × p
Each toss is an independent Bernoulli trial. Frequency can differ from probability in small samples. Larger samples usually reduce relative variation but do not guarantee an exact result.
| Expected heads | — |
|---|---|
| Observed − expected difference | — |
What a simulation cannot prove
The generator is reproducible and pseudorandom (Mulberry32), not physical randomness or a cryptographic generator. Results do not predict the next toss or prove a real coin is fair. Change the seed to compare samples.
Reference: OpenStax · Binomial Distribution