Dihybrid Cross Calculator
Cross two parents at two genes, such as AaBb × AaBb, for the 9:3:3:1 phenotype ratio, the nine-class genotype ratio and expected offspring counts.
Dihybrid Cross Calculator
Background.
Gregor Mendel crossed pea plants grown from round yellow seeds with plants from angular green ones, let the hybrids self-pollinate, and sorted the next generation's 556 seeds: 315 round yellow, 108 round green, 101 angular yellow and 32 angular green. Those counts sit close to nine, three, three and one parts in sixteen, and the pattern told him that seed shape and seed colour were being passed on independently of each other.
Enter two genotypes written over two genes — AaBb and AaBb for Mendel's hybrids — and the calculator lists each parent's gametes, crosses them in a sixteen-cell grid, and reports the four visible classes as percentages, the phenotype and genotype ratios in lowest whole numbers, and the expected count in each class for any number of offspring. It works for any combination, not only the double heterozygote: a testcross against aabb, a parent homozygous at one gene, or a cross in which some classes cannot appear at all.
The arithmetic rests on two assumptions. Each gene must show complete dominance, so that AA and Aa look alike. And the two genes must assort independently, which physically means lying on different chromosomes or far enough apart on one that crossing over separates them freely. Genes close together on a chromosome are linked: the allele combinations the parents carried come out more often than the ratio predicts and new combinations less often. When one gene masks the other — epistasis — visible classes merge, and 9:3:3:1 turns into 9:7, 9:3:4, 12:3:1, 13:3 or 15:1.
Those departures are why the expected ratio is worth computing. Scaled to the number of offspring actually scored, the expected counts are what a chi-square test compares your observations with, and the test says whether the gap between them looks like chance or like linkage, epistasis or a lethal allele.
What is dihybrid cross calculator?
A dihybrid cross follows two genes in the same mating. Each parent has two alleles at each gene, written as four letters — AaBb has alleles A and a at the first gene and B and b at the second, with capitals for the dominant allele. Mendel's law of segregation says each gamete receives one allele from each gene; his law of independent assortment says which allele it receives at one gene has no bearing on the other. A parent heterozygous at both genes therefore makes four gamete types, AB, Ab, aB and ab, in equal numbers.
The underscore notation describes what you can see: A_ means AA or Aa, both of which show the dominant phenotype. Crossing two double heterozygotes gives 9 A_B_ : 3 A_bb : 3 aaB_ : 1 aabb in phenotypes, and nine genotypes in the ratio 1:2:1:2:4:2:1:2:1, the product of a 1:2:1 ratio at each gene.
Mendel spelled out the general pattern for hybrids differing in n characters: 4ⁿ combinations in the full series, 3ⁿ distinct genotypes among them, and 2ⁿ that breed true. The same 2ⁿ is the number of gamete types made by a parent heterozygous at n genes. For two genes those numbers are 16, 9 and 4; for three, 64, 27 and 8.
How to use this calculator.
- Type parent 1's genotype as four letters: the two alleles of gene 1, then the two alleles of gene 2, such as AaBb, RrYy or AABb. Capitals are dominant alleles. The order within a gene does not matter, so aA is read as Aa.
- Type parent 2's genotype using the same two letters in the same order. A parent written BbAa against AaBb, or a different letter for one gene, is refused rather than guessed at. For a testcross, enter aabb.
- Set the offspring count. Leave 16 to see the ratio directly as expected counts; enter the number of offspring you actually scored if you plan a chi-square test. Expected counts are left as fractions on purpose.
- Read the four percentages, which always total 100, then the phenotype and genotype ratios. Classes that cannot occur are dropped from the ratio text.
- Check the gamete counts: 4 for a parent heterozygous at both genes, 2 at one, 1 at neither. A parent showing 1 contributes no variation, so every difference among the offspring comes from the other parent.
The formula.
Two rules generate everything. Segregation: a parent passes on one of its two alleles at each gene, each with probability ½. Independent assortment: the choice at gene 1 is unrelated to the choice at gene 2. Combining one allele from each gene gives four gametes per parent, each with probability ¼, counted with repeats — AABb yields AB, Ab, AB and Ab, which is four gametes but two distinct types.
Fertilisation pairs a gamete from each parent independently, so the 4 × 4 grid has 16 equally likely cells, and the probability of any genotype is the number of cells holding it divided by 16. An offspring shows the dominant phenotype at a gene if it carries at least one capital letter there. For AaBb × AaBb:
A_B_ = 9/16 = 56.25% A_bb = 3/16 = 18.75% aaB_ = 3/16 = 18.75% aabb = 1/16 = 6.25%
The product rule reaches the same numbers without the grid. Each gene on its own gives ¾ dominant and ¼ recessive, so A_B_ = ¾ × ¾ = 9/16 and A_bb = ¾ × ¼ = 3/16. For other crosses the per-gene fractions change — Aa × aa gives ½ and ½ — but the multiplication works the same way.
Expected counts are probability × offspring total, with no rounding to whole offspring. The model assumes both genes show complete dominance and assort independently, that every genotype survives equally, and that each genotype always shows its expected phenotype. Linkage breaks the independence; epistasis, lethal alleles and incomplete penetrance break the link between genotype and visible class. In each of those cases the grid is still right about genotypes, but the four visible classes no longer follow from it.
Genotypes must be four letters, two per gene, with different letters for the two genes and the same genes in the same order for both parents. The offspring count can be any number from zero up.
A worked example.
Mendel's F1 hybrids for seed shape and seed colour were AaBb, with A = round over angular and B = yellow over green. Self-pollinating them is the cross AaBb × AaBb, and he scored 556 seeds, so enter 556 as the offspring count. Each parent makes four gamete types — AB, Ab, aB, ab — giving 16 equally likely cells and nine genotypes in the ratio 1 AABB : 2 AABb : 1 AAbb : 2 AaBB : 4 AaBb : 2 Aabb : 1 aaBB : 2 aaBb : 1 aabb. Grouped by appearance: 9 of 16 cells are round yellow (56.25%), 3 are round green (18.75%), 3 angular yellow (18.75%) and 1 angular green (6.25%). Multiplying by 556 gives expected counts of 312.75, 104.25, 104.25 and 34.75. Against Mendel's observed 315, 108, 101 and 32, the chi-square terms are (315 − 312.75)² ÷ 312.75 = 0.0162, (108 − 104.25)² ÷ 104.25 = 0.1349, (101 − 104.25)² ÷ 104.25 = 0.1013 and (32 − 34.75)² ÷ 34.75 = 0.2176, totalling 0.470. With four classes there are three degrees of freedom, and the 5% critical value is 7.815, so his counts fit independent assortment comfortably. The largest term comes from the smallest class, where a shortfall of under three seeds weighs most.
Frequently asked questions.
Why does a cross of two double heterozygotes give 9:3:3:1?
What ratio does AaBb × Aabb give?
What does a testcross against aabb tell you?
How would linked genes change the result?
Were all seven of Mendel's traits on separate chromosomes?
What is epistasis, and how does it change 9:3:3:1?
Why aren't the expected counts whole numbers?
How do I test my own dihybrid results?
Does it matter which parent I enter first?
Can a dihybrid cross predict traits in a human family?
References& sources.
- [1]Abbott S. & Fairbanks D. J. (2016). Experiments on Plant Hybrids by Gregor Mendel. Genetics 204(2):407–422. doi:10.1534/genetics.116.195198. Peer-reviewed modern English translation of Mendel (1866) published by the Genetics Society of America. Source for the two-character experiment — 556 seeds, 315 round yellow, 101 angular yellow, 108 round green, 32 angular green — and for the 2ⁿ / 3ⁿ / 4ⁿ series. Open access, not paywalled. Retrieved 2026-07-29.
- [2]OpenStax, Biology 2e, section 12.3 'Laws of Inheritance'. Rice University, 2018, CC BY 4.0. Independent derivation of the same result by the product rule: 'the proportion of round and yellow F2 offspring is expected to be (3/4) × (3/4) = 9/16', and the 4 × 4 Punnett square giving '16 equally likely genotypic combinations' and 'a phenotypic ratio of 9 round/yellow:3 round/green:3 wrinkled/yellow:1 wrinkled/green'. Free, openly licensed. Retrieved 2026-07-29.
- [3]Reid J. B. & Ross J. J. (2011). Mendel's genes: toward a full molecular characterization. Genetics 189(1):3–10. doi:10.1534/genetics.111.132118. Places Mendel's seven traits on only five of the seven pea linkage groups, with le and v roughly 12.6 map units apart on linkage group III, and concludes 'an element of luck was involved with his choice of characters'. This page follows Reid & Ross where it conflicts with the textbook account — see the FAQ on Mendel's chromosomes. Open access via PMC. Retrieved 2026-07-29.
- [4]OpenStax, Biology 2e, section 13.1 'Chromosomal Theory and Genetic Linkage'. Rice University, 2018, CC BY 4.0. Source for the linkage mechanism — 'linked genes disrupt Mendel's predicted outcomes' and recombination frequency correlating with genetic distance — and, in its account of Mendel's traits, the simplification this page records as conflicting with Reid & Ross (2011). Free, openly licensed. Retrieved 2026-07-29.
- [5]MedlinePlus Genetics, US National Library of Medicine. Inheritance Patterns, page last updated 19 April 2021. Source for the classical inheritance-mode definitions used in the scope statements, and for the position that most visible human traits are not single-gene. Free. Retrieved 2026-07-29.
- [6]Gulani A. & Weiler T. Genetics, Autosomal Recessive. StatPearls, NCBI Bookshelf ID NBK546620, last update 1 May 2023. Source for the per-gene 25 % / 50 % / 25 % monohybrid figures that this page multiplies together, and for the product-rule statement '50% x 50% = 25%'. Free full text. Retrieved 2026-07-29.
How this page was produced
- Published by
- Quanta Calculator
- Overseen by
- Daniel, Quanta Calculator Researcher
- Primary sources
- 6 cited below
- Method
- P(A_B_) = P(A_) × P(B_) = ¾ × ¾ = 9⁄16
- Published
- Last verified
Built with AI assistance and verified by automated tests against the cited sources — every worked example on this page is computed by the same code that runs the calculator. How we build and check calculators.
In this category
Embed
Quanta Pro
Paid features are coming later.
- All 1560 calculators remain free
- No billing is enabled