🧬">

Allele Frequency Calculator

Hardy-Weinberg analysis tool • 2026 edition

Hardy-Weinberg Equilibrium:

Show the calculator

\( p + q = 1 \)

\( p^2 + 2pq + q^2 = 1 \)

Where:

  • \( p \) = Frequency of dominant allele
  • \( q \) = Frequency of recessive allele
  • \( p^2 \) = Homozygous dominant frequency
  • \( 2pq \) = Heterozygous frequency
  • \( q^2 \) = Homozygous recessive frequency

These equations describe genetic equilibrium in populations.

Example: If p = 0.7, then q = 0.3

Genotype frequencies: AA = 0.49, Aa = 0.42, aa = 0.09

Population Data

Advanced Settings

Results

0.70
Allele Frequency (A)
0.30
Allele Frequency (a)
0.49
Genotype Frequency (AA)
0.42
Genotype Frequency (Aa)

Population Genetics Fundamentals

What is Allele Frequency?

Allele frequency is the relative frequency of an allele at a particular gene locus in a population. It's calculated as the number of copies of the allele divided by the total number of alleles in the population.

Hardy-Weinberg Equations

Allele frequencies: \( p + q = 1 \)

Genotype frequencies: \( p^2 + 2pq + q^2 = 1 \)

Key Rules:
  • Allele frequencies sum to 1
  • Genotype frequencies sum to 1
  • Hardy-Weinberg requires 5 assumptions

Comprehensive Population Genetics Guide

Hardy-Weinberg Equilibrium

The Hardy-Weinberg principle states that allele and genotype frequencies in a population will remain constant from generation to generation in the absence of evolutionary influences. The conditions required are:

  • No mutations
  • Random mating
  • No gene flow (migration)
  • No genetic drift (large population)
  • No natural selection

When these conditions are met, \( p + q = 1 \) and \( p^2 + 2pq + q^2 = 1 \).

Frequency Calculations

Allele frequencies are calculated as:

\( p = \frac{2 \times AA + Aa}{2 \times \text{Total Individuals}} \)

Genotype frequencies are calculated as:

\( f(AA) = \frac{\text{Number of AA individuals}}{\text{Total individuals}} \)

These calculations help determine if a population is evolving.

Evolutionary Forces

Deviations from Hardy-Weinberg equilibrium indicate evolutionary forces:

  • Genetic Drift: Random changes in small populations
  • Gene Flow: Migration introducing new alleles
  • Mutation: Creating new alleles
  • Selection: Differential survival/reproduction
Practical Applications
1
Conservation: Assessing genetic diversity in endangered populations.
2
Medical Genetics: Predicting carrier frequencies for genetic diseases.
3
Forensics: Calculating DNA profile probabilities.
Evolutionary Studies: Detecting selection pressures in populations.

Population Genetics Learning Quiz

Question 1: Multiple Choice - Hardy-Weinberg Conditions

Which of the following is NOT a condition required for Hardy-Weinberg equilibrium?

Solution:

The answer is C) Natural selection. Hardy-Weinberg equilibrium requires the absence of natural selection. All other conditions (random mating, large population, no mutations) must be met for equilibrium. Natural selection causes changes in allele frequencies, violating the equilibrium.

Pedagogical Explanation:

The Hardy-Weinberg principle describes an idealized population where no evolutionary forces act. Natural selection is an evolutionary force that changes allele frequencies by favoring certain genotypes. When selection is present, allele frequencies change over time, violating the equilibrium. The five conditions must all be met simultaneously for Hardy-Weinberg equilibrium to hold.

Key Definitions:

Hardy-Weinberg Equilibrium: Stable allele frequencies over generations

Evolutionary Force: Factor that changes allele frequencies

Natural Selection: Differential survival and reproduction

Important Rules:

• Equilibrium requires absence of evolutionary forces

• Selection changes allele frequencies

• Five conditions must all be met

Tips & Tricks:

• Remember: Evolutionary forces disrupt equilibrium

• H-W equilibrium = no evolution occurring

Common Mistakes:

• Confusing conditions that maintain vs disrupt equilibrium

• Thinking selection helps maintain equilibrium

Question 2: Detailed Answer - Frequency Calculation

In a population of 500 individuals, 180 are homozygous dominant (AA), 240 are heterozygous (Aa), and 80 are homozygous recessive (aa). Calculate the allele frequencies and verify Hardy-Weinberg equilibrium.

Solution:

First, calculate total number of alleles: 500 × 2 = 1000

Number of A alleles: (180 × 2) + 240 = 600

Number of a alleles: (80 × 2) + 240 = 400

Frequency of A: p = 600/1000 = 0.6

Frequency of a: q = 400/1000 = 0.4

Expected frequencies: AA = p² = 0.36, Aa = 2pq = 0.48, aa = q² = 0.16

Expected counts: AA = 180, Aa = 240, aa = 80

The observed and expected match perfectly, confirming equilibrium.

Pedagogical Explanation:

This example demonstrates how to calculate allele frequencies from genotype counts. The key insight is that each individual carries two alleles, so the total number of alleles is twice the population size. We count A alleles as 2 per AA individual plus 1 per Aa individual. The verification confirms that the population is in Hardy-Weinberg equilibrium since observed and expected values match.

Key Definitions:

Allele Frequency: Proportion of an allele in a population

Genotype Frequency: Proportion of a genotype in a population

Equilibrium: Stable frequencies over generations

Important Rules:

• Count alleles, not individuals

• Total alleles = 2 × population size

• Expected = calculated from Hardy-Weinberg equations

Tips & Tricks:

• Use p + q = 1 to verify calculations

• Check that p² + 2pq + q² = 1

Common Mistakes:

• Forgetting to count alleles (not individuals)

• Miscalculating heterozygote contributions

FAQ

Q: Why is Hardy-Weinberg equilibrium important in population genetics?

A: Hardy-Weinberg equilibrium provides a null hypothesis for population genetics. It establishes what allele and genotype frequencies would be in the absence of evolutionary forces. When observed frequencies deviate from expected Hardy-Weinberg frequencies, it indicates that evolutionary processes are acting on the population.

Mathematically, if p and q are allele frequencies, then under equilibrium:

  • AA genotype frequency = p²
  • Aa genotype frequency = 2pq
  • aa genotype frequency = q²

This framework allows researchers to detect selection, genetic drift, migration, or mutation in natural populations.

Q: How do you test if a population is in Hardy-Weinberg equilibrium?

A: The Chi-square goodness-of-fit test compares observed and expected genotype frequencies:

χ² = Σ[(Observed - Expected)² / Expected]

Steps:

  1. Calculate allele frequencies from observed genotypes
  2. Calculate expected genotype frequencies using p², 2pq, q²
  3. Calculate expected counts (expected frequency × total sample size)
  4. Compute chi-square statistic
  5. Compare to critical value (df = 1 for 2 alleles)

If χ² > critical value, reject the null hypothesis of equilibrium, indicating evolutionary forces are acting on the population.

About

Genetics Team
This calculator was created
This calculator was created by our Biology & Genetics Team , may make errors. Consider checking important information. Updated: April 2026.