Trinomial Distribution Calculator

Find the exact probability of a specific three-category outcome.
Enter three event probabilities, total trial count, and counts for each category.

Trinomial Distribution

The trinomial distribution extends the binomial to three mutually exclusive outcomes. In n independent trials, each outcome falls into category A with probability p1, category B with probability p2, or category C with probability p3 = 1 - p1 - p2. The three probabilities must sum to 1.

The probability mass function is:

P(X=k, Y=m) = n! / (k! x m! x z!) x p1^k x p2^m x p3^z

where Z = n - k - m is the count of category C outcomes.

The fraction n!/(k! x m! x z!) is the multinomial coefficient — it counts the number of distinct orderings that produce exactly k A-results, m B-results, and z C-results out of n trials.

Classic example: rolling a six-sided die 10 times, grouping faces as A = {1,2} (prob 1/3), B = {3,4} (prob 1/3), C = {5,6} (prob 1/3). What is the probability of exactly 4 A-rolls and 3 B-rolls? That leaves 3 C-rolls. P(X=4, Y=3) = 10!/(4! x 3! x 3!) x (1/3)^4 x (1/3)^3 x (1/3)^3 = 4200 x (1/3)^10 = 4200/59049 ≈ 0.0711.

Applications: quality control with three defect grades, genetics for three genotypes, consumer surveys with three response categories, or any repeated experiment with exactly three outcomes.

This calculator uses logarithms internally to stay numerically stable for large n. Factorials of large numbers overflow standard floating point, but their logs sum safely. For n much above 50, individual probabilities shrink fast — a result of 1e-8 or smaller is normal and just means the specific outcome is rare.

Enter k and m such that k + m is at most n. The calculator fills in p3 and z automatically.


How we build and check this calculator

This calculator runs entirely in your browser, so the numbers you enter stay on your device. The math behind it is written by hand and tested against worked examples and standard references before the page goes live.

SuperGlobalCalculator is independently built and maintained. See how we build and verify our calculators.

Embed This Calculator

Copy the code below and paste it into your website or blog.
The calculator will work directly on your page.