Allele Frequency Calculator
Free Allele frequency Calculator for genetics. Enter variables to compute results with formulas and detailed steps. See charts, tables, and visual results.
Calculator
Adjust values & calculateObserved vs Expected Genotype Frequencies
Formula
Where p is the frequency of the dominant allele, q is the frequency of the recessive allele, AA is the count of dominant homozygous individuals, Aa is heterozygous count, aa is recessive homozygous count, and N is total individuals. For Hardy-Weinberg equilibrium, expected genotype frequencies are p squared, 2pq, and q squared.
Last reviewed: December 2025
Worked Examples
Example 1: MN Blood Group Allele Frequencies
Example 2: Testing for Hardy-Weinberg Equilibrium
Background & Theory
The Allele Frequency Calculator applies the following established principles and formulas. Biology is the scientific study of life, encompassing the structure, function, growth, evolution, and distribution of living organisms. At the cellular level, all life is composed of cells, the basic structural and functional units of organisms. Prokaryotic cells lack a membrane-bound nucleus, while eukaryotic cells possess a nucleus and membrane-bound organelles including mitochondria, which generate ATP through oxidative phosphorylation, and ribosomes, which synthesize proteins. Genetics quantifies the inheritance of traits. Gregor Mendel's laws describe how alleles segregate during gamete formation and assort independently for genes on different chromosomes. Punnett squares provide a visual method for calculating the probability of offspring genotypes and phenotypes from known parental genotypes. For a monohybrid cross of two heterozygotes (Aa ร Aa), the expected phenotypic ratio is 3 dominant to 1 recessive. 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 forces. If p and q are the frequencies of two alleles at a locus, then p + q = 1 and genotype frequencies are pยฒ, 2pq, and qยฒ for the three possible genotypes. Deviations from equilibrium signal the action of natural selection, genetic drift, mutation, migration, or non-random mating. Population growth follows two primary models. Exponential growth, N = Nโeสณแต, describes unlimited growth where Nโ is the initial population, r is the intrinsic rate of increase, and t is time. Logistic growth incorporates carrying capacity K, describing how growth slows as population approaches the environment's maximum sustainable size: dN/dt = rN(1 โ N/K). Enzyme kinetics describes the rate of enzyme-catalyzed reactions. The Michaelis-Menten equation, v = Vmax[S]/(Km + [S]), relates reaction velocity v to substrate concentration [S], maximum velocity Vmax, and the Michaelis constant Km, which equals the substrate concentration at half-maximal velocity. DNA replication relies on complementary base pairing: adenine pairs with thymine (two hydrogen bonds) and guanine with cytosine (three hydrogen bonds), ensuring faithful copying of genetic information.
History
The history behind the Allele Frequency Calculator traces back through the following developments. The systematic study of living things began with Aristotle (384โ322 BCE), who classified over 500 animal species and wrote foundational texts on anatomy, reproduction, and animal behavior. His scala naturae ranked organisms in a hierarchy from simple to complex and influenced biological thought for two millennia. Theophrastus, his student, applied similar methods to plants. Carl Linnaeus established modern taxonomy in Systema Naturae (1735), introducing the binomial nomenclature system that assigns each organism a genus and species name. His hierarchical classification system โ species, genus, family, order, class, phylum, kingdom โ provided the organizational framework that biologists still use, now extended to seven ranks and supplemented by cladistics. Charles Darwin and Alfred Russel Wallace independently developed the theory of evolution by natural selection, which Darwin published in On the Origin of Species in 1859. Darwin argued that heritable variation exists within populations, that organisms with advantageous traits survive and reproduce at higher rates, and that this differential reproduction gradually changes the character of populations over generations. This unified all of biology under a single explanatory framework. Gregor Mendel's meticulous pea plant experiments, conducted from 1856 to 1863 and published in 1866, established the particulate nature of inheritance and the laws of segregation and independent assortment. Overlooked until 1900, when three botanists independently rediscovered his work, Mendel's laws laid the foundation for the science of genetics. James Watson and Francis Crick, building on Rosalind Franklin's X-ray crystallography data, determined the double-helix structure of DNA in 1953, revealing the physical basis of heredity and the mechanism by which genetic information is stored and copied. The Human Genome Project, a 13-year international collaboration, published the complete sequence of the human genome in 2003, comprising approximately 3.2 billion base pairs. The development of CRISPR-Cas9 gene editing by Jennifer Doudna, Emmanuelle Charpentier, and colleagues from 2012 onward opened an era of precise genome modification with transformative implications for medicine, agriculture, and basic research.
Frequently Asked Questions
Formula
p = (2 x AA + Aa) / (2 x N) ; q = (2 x aa + Aa) / (2 x N) ; p + q = 1
Where p is the frequency of the dominant allele, q is the frequency of the recessive allele, AA is the count of dominant homozygous individuals, Aa is heterozygous count, aa is recessive homozygous count, and N is total individuals. For Hardy-Weinberg equilibrium, expected genotype frequencies are p squared, 2pq, and q squared.
Worked Examples
Example 1: MN Blood Group Allele Frequencies
Problem: In a population of 1,000 people, 360 have genotype MM, 480 have MN, and 160 have NN. Calculate the allele frequencies of M and N.
Solution: Total alleles = 1,000 x 2 = 2,000\nFrequency of M (p) = (2 x 360 + 480) / 2,000 = 1,200 / 2,000 = 0.60\nFrequency of N (q) = (2 x 160 + 480) / 2,000 = 800 / 2,000 = 0.40\nCheck: p + q = 0.60 + 0.40 = 1.00
Result: p(M) = 0.60, q(N) = 0.40
Example 2: Testing for Hardy-Weinberg Equilibrium
Problem: Observed: 50 AA, 40 Aa, 10 aa (total 100). Is this population in HWE?
Solution: p = (2x50 + 40) / 200 = 0.70, q = 0.30\nExpected: AA = 0.49 x 100 = 49, Aa = 0.42 x 100 = 42, aa = 0.09 x 100 = 9\nChi-square = (50-49)^2/49 + (40-42)^2/42 + (10-9)^2/9 = 0.0204 + 0.0952 + 0.1111 = 0.2268\n0.2268 < 3.841 critical value
Result: Chi-square = 0.2268, population IS in Hardy-Weinberg equilibrium (p > 0.05)
Frequently Asked Questions
What is allele frequency and why does it matter?
Allele frequency is the proportion of a specific allele (variant of a gene) within a population's gene pool. It is calculated by counting the number of copies of that allele and dividing by the total number of alleles at that locus in the population. Allele frequencies are fundamental to population genetics because changes in these frequencies over generations indicate evolution. If allele frequencies remain constant, the population is said to be in Hardy-Weinberg equilibrium, meaning no evolutionary forces are acting on that gene.
How do you calculate allele frequency from genotype counts?
To calculate allele frequency, count the total number of each allele in the population. For a two-allele system (A and a): the frequency of A (p) = (2 x number of AA individuals + number of Aa individuals) / (2 x total individuals). Similarly, q = (2 x number of aa individuals + number of Aa individuals) / (2 x total individuals). The factor of 2 accounts for diploid organisms carrying two alleles per locus. The frequencies p and q must always sum to 1.0, which serves as a useful check on your calculations.
What does the chi-square test tell us about allele frequencies?
The chi-square goodness-of-fit test compares observed genotype counts with those expected under Hardy-Weinberg equilibrium. A chi-square value less than 3.841 (the critical value at 1 degree of freedom and alpha = 0.05) means the population does not significantly deviate from HWE. A value above this threshold suggests evolutionary forces such as natural selection, genetic drift, non-random mating, or migration may be influencing the allele frequencies. This test is one of the most commonly used statistical tools in population genetics research.
Can allele frequency change over time?
Yes, allele frequencies change over time through several mechanisms collectively known as evolutionary forces. Natural selection favors alleles that increase fitness, causing their frequency to rise. Genetic drift causes random changes in small populations. Mutation introduces new alleles at very low rates. Gene flow (migration) between populations can introduce or remove alleles. Non-random mating (such as inbreeding or assortative mating) changes genotype frequencies without directly altering allele frequencies. Tracking these changes across generations is central to the study of evolution and conservation biology.
How do I get the most accurate result?
Enter values as precisely as possible using the correct units for each field. Check that you have selected the right unit (e.g. kilograms vs pounds, meters vs feet) before calculating. Rounding inputs early can reduce output precision.
How do I verify Allele Frequency Calculator's result independently?
The Formula section on this page shows the equation used. You can reproduce the calculation manually or in a spreadsheet using those steps. Compare your answer against the worked examples in the Examples section, which use known reference values so you can confirm the calculator is behaving as expected.
References
Reviewed by Daniel Agrici, Founder & Lead Developer ยท Editorial policy