Allele Frequency Calculator
Counted straight from the genotypes, with a chi-squared test against what equilibrium predicts.
The formula
p + q = 1 ; p^2 + 2pq + q^2 = 1
What equilibrium actually claims
Hardy-Weinberg says that in a large, randomly mating population with no selection, mutation or migration, allele frequencies do not change from one generation to the next, and the genotype frequencies follow directly from them. It is the null hypothesis of population genetics: not a description of any real population, but the baseline against which real ones are measured.
Carriers vastly outnumber sufferers
For a rare recessive disorder the arithmetic is striking. If one person in 10,000 is affected, q is 0.01 and the carrier frequency 2pq is about 0.0198 — roughly one person in fifty. Carriers outnumber affected individuals by about 198 to one, and the rarer the condition the more extreme that ratio becomes. This is why recessive alleles persist: selection barely sees them, because almost every copy is hidden in a heterozygote.
Departure from it is the signal
Because equilibrium is what happens when nothing is going on, a population that departs from it is telling you something is: selection, assortative mating, population structure, or an error in the genotyping. A chi-squared test against the expected frequencies is the standard first check on any genotype dataset.
Ratios are expectations, not promises
Every genetic ratio on these pages is a probability distribution, not a guarantee. A 3:1 cross does not produce three dominant offspring for every recessive one in a litter of four — it produces each offspring independently with a three-quarters chance. Small families depart from the expected ratio routinely, and that is the reason Mendel needed thousands of pea plants rather than dozens.