Allele frequency is the starting point for almost every calculation in population genetics — it's the p and q that feed directly into the Hardy-Weinberg equation, selection models, and drift simulations. This calculator turns either genotype counts or raw allele counts into p and q instantly, so you can move on to the analysis that actually depends on them.

Why divide by 2N, not N?

Each diploid individual carries two copies of every gene — one from each parent. So a population of N individuals has a gene pool of 2N allele copies for that gene, not N. An AA individual contributes 2 copies of allele A; an aa individual contributes 2 copies of allele a; a heterozygous Aa individual contributes exactly one of each. Adding up every individual's contribution and dividing by the total pool size (2N) gives the true frequency of each allele in the population — not just the frequency of a genotype.

Genotype counts vs. direct allele counts

Most textbook problems hand you genotype counts (how many AA, Aa, and aa individuals were observed), because that's what phenotyping or genotyping actually measures in the field. Some datasets — especially from sequencing pipelines — instead report a raw tally of allele copies directly. Both routes to p and q are mathematically equivalent once you account for the fact that heterozygotes contribute one copy of each allele; this calculator supports both so you don't have to convert by hand.

What allele frequency feeds into next

p and q are not usually the final answer — they're the inputs to Hardy-Weinberg equilibrium (p^2 + 2pq + q^2 = 1), which predicts the expected genotype frequencies if the population is not evolving at that gene. Comparing your observed genotype counts against the Hardy-Weinberg expectation is how geneticists detect selection, non-random mating, or genetic drift acting on a gene. This calculator focuses purely on getting p and q right from your data; use it as the input step before an equilibrium check.