Science · Biology / Population Genetics

Hardy-Weinberg Calculator

Enter an allele frequency or a genotype frequency and get the full set — p, q, p², 2pq and q² — plus a check that the population is actually at equilibrium.

p + q = 1    p² + 2pq + q² = 1
p · allele A
Frequency of the dominant allele (0 to 1). q is derived as 1 − p.
p (allele A)
—
q (allele a)
—
p² (AA)
—
2pq (Aa)
—
q² (aa)
—
Hardy-Weinberg equilibrium
p + q = 1    p² + 2pq + q² = 1
For a two-allele locus with allele frequencies p and q, random mating keeps genotype frequencies at p² (AA), 2pq (Aa) and q² (aa) generation after generation. Equilibrium assumes no selection, mutation, migration or genetic drift — so real populations that deviate measurably from these values are evolving.

🧩 Two entry modes

Start from allele frequency p, or from the recessive genotype frequency q².

✅ Equilibrium check

Compare expected genotypes against your observed q² to spot deviations.

📈 Worked steps

Every derivation shown: q = 1 − p and p = √(1 − q²).

🧟 Carriers

2pq is the heterozygous carrier frequency — the value most genetic counselling questions ask for.

More biology & statistics

Chi-square tests quantify how far a population sits from equilibrium.

Chi-Square Calculator