Home/Biology/Genetics/Hardy-Weinberg Equilibrium

Formula & Calculator

Hardy-Weinberg Equilibrium

Describes allele and genotype frequencies in a non-evolving population.

BiologyGeneticsPopulation Genetics

Hardy-Weinberg Equilibrium Calculator p² + 2pq + q² = 1

p² + 2pq + q² = 1
p = frequency of dominant allele  ·  q = frequency of recessive allele  ·  = AA genotype  ·  2pq = Aa genotype  ·  = aa genotype
⟹ Auto‑Solve p, q, p², 2pq, q²
Allele Frequencies
Genotype Frequencies
Please fix the errors above.
Presets:
Equilibrium Status
p: q: p²: 2pq: q²:
✓ Copied!
Genotype Distribution
p + q = 1  ·  p² + 2pq + q² = 1  ·  Assumes random mating, no mutation, no migration, no selection, and large population size.

Interpretation

p² + 2pq + q² = 1. Describes allele and genotype frequencies in a non‑evolving population. Assumes random mating, no mutation, no selection, large population, and no migration. Used in population genetics.

p² + 2pq + q² = 1
Hardy-Weinberg Equilibrium

Variables

SymbolQuantityUnit
pDominant allele frequency
qRecessive allele frequency

What it means

The Hardy‑Weinberg equilibrium principle states that allele and genotype frequencies in a population remain constant from generation to generation in the absence of evolutionary influences. For a gene with two alleles (A and a) with frequencies p and q (p + q = 1), the genotype frequencies are AA = p², Aa = 2pq, and aa = q². This provides a null model for detecting evolution; significant deviations indicate factors like selection, mutation, or genetic drift. It is widely used in population genetics to estimate allele frequencies, to study genetic disorders, and to assess the impact of non‑random mating. In conservation biology, it helps monitor genetic diversity. Understanding this law is essential for evolutionary biology, medicine (carrier frequencies), and forensic science.

Worked example

Hardy‑Weinberg Equilibrium – Two Detailed Examples

Real‑World
Scenario: A population of wild rabbits has a gene for fur colour where the dominant allele (A) codes for brown fur and the recessive allele (a) codes for white fur. A biologist samples the population and finds that the frequency of the recessive allele (q) is 0.3. Using the Hardy‑Weinberg principle, she calculates the expected genotype frequencies to see if the population is in equilibrium. This helps her determine whether evolutionary forces like natural selection or genetic drift are acting on the population.
ParameterValue
q (frequency of recessive allele)0.3
1p = 1 − q = 0.7
2p² = (0.7)² = 0.49 (homozygous dominant)
32pq = 2 × 0.7 × 0.3 = 0.42 (heterozygous)
4q² = (0.3)² = 0.09 (homozygous recessive)
Result AA: 0.49, Aa: 0.42, aa: 0.09 ✓ Expected genotype frequencies
Scenario: In a human population, the frequency of the recessive allele for a rare genetic disorder (cystic fibrosis) is known to be 0.02. A genetic counsellor uses the Hardy‑Weinberg equation to estimate the proportion of carriers (heterozygotes) in the population. This information is crucial for assessing the risk of passing the disorder to offspring and for making informed reproductive decisions.
ParameterValue
q0.02
1p = 1 − 0.02 = 0.98
22pq = 2 × 0.98 × 0.02 = 0.0392 ≈ 3.9%
Result ~3.9% carriers ✓ Carrier frequency
Insight: The Hardy‑Weinberg principle predicts that allele frequencies remain constant in a large, random‑mating population with no evolutionary forces. It provides a null model for detecting evolutionary change.

Common mistakes

  • Allele frequencies: p and q represent the frequencies of the two alleles (p + q = 1). Ensure they sum to 1 before using.
  • Genotype frequencies: p² (AA), 2pq (Aa), q² (aa) – they must sum to 1.
  • Assumptions: Random mating, no mutation, no migration, no selection, large population – deviations affect equilibrium.
  • Chi‑square test: Use to test if observed genotype frequencies differ significantly from expected.
  • Multiple alleles: The formula extends to multiple alleles (p+q+r+...=1) – not just two.

Applications

The Hardy‑Weinberg equilibrium principle describes how allele and genotype frequencies remain constant in a population from generation to generation in the absence of evolutionary forces. The equation p² + 2pq + q² = 1 relates allele frequencies (p and q) to genotype frequencies for a single gene with two alleles. This is a foundational concept in population genetics, used to estimate carrier frequencies for recessive diseases, to test whether a population is evolving, and to study genetic diversity. Public health researchers use it to predict the prevalence of genetic disorders in populations. Conservation biologists apply it to monitor genetic health in endangered species. By understanding Hardy‑Weinberg equilibrium, professionals can assess the impact of migration, mutation, selection, and genetic drift on populations. It is a key tool in genetic counseling, epidemiology, and evolutionary biology.

  • Estimation of carrier frequencies for recessive genetic diseases (e.g., cystic fibrosis)
  • Testing for evolutionary forces (selection, drift, migration) in populations
  • Genetic counseling and risk assessment for hereditary conditions
  • Conservation genetics – monitoring genetic diversity in endangered species
  • Population genetics research and education

Frequently Asked Questions

Q01What is the Hardy‑Weinberg Equilibrium formula used for?
A01

The Hardy‑Weinberg equation (p² + 2pq + q² = 1) describes allele and genotype frequencies in a non‑evolving population. It serves as a null model against which evolutionary changes can be tested.

Q02What do the variables p and q represent?
A02

p = frequency of the dominant allele (A)
q = frequency of the recessive allele (a)
and p + q = 1.

Q03What do p², 2pq, and q² represent?
A03

= frequency of homozygous dominant (AA)
2pq = frequency of heterozygous (Aa)
= frequency of homozygous recessive (aa)

Q04What are the five assumptions of the Hardy‑Weinberg principle?
A04

  • No mutation
  • Random mating
  • No natural selection
  • Infinite population size (no genetic drift)
  • No gene flow (migration)

Q05How is the Hardy‑Weinberg equilibrium used in population genetics?
A05

By comparing observed genotype frequencies with expected frequencies from the equation. Deviations indicate that one of the assumptions is violated, pointing to evolutionary forces acting on the population.

Q06How do you calculate allele frequencies from genotype frequencies?
A06

p = f(AA) + ½ f(Aa)
q = f(aa) + ½ f(Aa)

Q07Give a worked example of Hardy‑Weinberg calculations.
A07

In a population, 36% show a recessive trait (aa). Then q² = 0.36 → q = 0.6, p = 0.4. Expected genotype frequencies: p² = 0.16 (AA), 2pq = 0.48 (Aa), q² = 0.36 (aa).

Q08What happens when selection acts on a locus?
A08

Allele frequencies change over time, and the population no longer fits Hardy‑Weinberg expectations. The equilibrium is disrupted, and evolution occurs.

Q09What is the difference between Hardy‑Weinberg equilibrium and genetic drift?
A09

Hardy‑Weinberg assumes an infinite population; genetic drift causes random fluctuations in allele frequencies, especially in small populations, violating the equilibrium.

Q10What are the limitations of the Hardy‑Weinberg model?
A10

It is an idealised model; real populations rarely meet all assumptions. However, it provides a useful baseline for detecting evolutionary change.