Simulation lab
Hardy-Weinberg Equilibrium Breakdown Lab
Hardy-Weinberg equilibrium says that with random mating and no selection, mutation, migration or drift, allele and genotype frequencies stay constant at p-squared, 2pq and q-squared. The catch is the hidden assumption of an effectively infinite population. Real populations are finite, so drift nudges p every generation, and genotype frequencies can no longer sit at their Hardy-Weinberg predictions. Use this panel to watch p wander from its starting value in small populations while holding nearly still in large ones.
Genetic Drift Simulator
Random sampling alone changes allele frequencies — no selection involved.
Shrink N to 5–10 and drift dominates: alleles fix or vanish within a few dozen generations purely by chance. Raise N to 200 and frequencies barely move — drift is weak in large populations. Every replicate starts identically yet ends differently: that randomness is genetic drift.
Wright–Fisher ideal population: discrete generations, random mating, constant size N, no selection, mutation or migration. Each generation's 2N alleles are a binomial sample of the previous generation's gene pool. Real populations add all the complications this model leaves out.
How to use it
Set N = 200, p0 = 0.5, 1 replicate, 100 generations: p barely moves, approximating Hardy-Weinberg constancy.
Set N = 10, p0 = 0.5, 5 replicates and press 'Run again': p wanders and often fixes, breaking equilibrium.
Note the panel tracks ALLELE frequencies only; the drifting p is what would drag genotype frequencies off their p-squared, 2pq, q-squared predictions.
Try p0 = 0.2 at N = 10 and observe how often the rare allele is lost entirely.
Conclude: Hardy-Weinberg needs effectively infinite N; finite N means drift, and drift means disequilibrium.
Be clear about what is shown: the panel tracks allele frequencies only and provides no genotype-frequency readouts, so the p-squared, 2pq, q-squared predictions must be computed by hand from the wandering p. Selection, mutation and migration have no terms in this model, so only the finite-size assumption is tested here. The model assumes ideal random mating and constant N, which real populations rarely meet.
What you will learn
- List the assumptions of Hardy-Weinberg equilibrium.
- Identify finite population size as the assumption this experiment violates.
- Explain why drift breaks the constancy of allele and genotype frequencies.
- Predict that Hardy-Weinberg holds approximately in large populations but fails in small ones.