Hypergeometric Distribution Calculator
This hypergeometric distribution calculator needs the population size, the number of successes, the sample size and the successes you want. Example: 10 winners among 50 tickets, 5 drawn – exactly 2 winners has probability 0.20984.
Example: Population size N 50 · Successes K in the population 10 · Sample size n (without replacement) 5 · Successes wanted k 2 → Result: P(X = 2) = 0.20984 (N = 50, K = 10, n = 5). Source: Wikipedia – Hypergeometric distribution. Updated: .
How it is calculated
The hypergeometric distribution gives the probability of k successes when you draw from a finite population without replacement.
Formula
The population has N items, K of them successes. You draw n items without replacement. Then P(X = k) = C(K, k) · C(N − K, n − k) / C(N, n): count the favourable selections (k successes out of K, n − k failures out of N − K) and divide by all possible selections. The mean is n · K / N and the variance n · (K/N) · (1 − K/N) · (N − n)/(N − 1). The last factor is the finite-population correction and makes the variance smaller than in the binomial case.
Worked example
A raffle drum holds 50 tickets, 10 of them winners. You draw 5 tickets. Exactly 2 winners: C(10, 2) = 45, C(40, 3) = 9880 and C(50, 5) = 2118760, so P = 45 · 9880 / 2118760 = 444600 / 2118760 = 0.20984. At most 2 winners has probability 0.95174, at least 2 winners 0.2581. On average you expect 5 · 10 / 50 = 1 winner, and the variance is 5 · 0.2 · 0.8 · 45/49 = 0.734694.
- Typical uses are lotteries, quality-control sampling and card games.
- Without replacement the draws depend on each other, which is why it is not the binomial distribution.
- Only success counts from max(0, n − (N − K)) to min(n, K) are possible.
Frequently asked questions
How do you calculate the hypergeometric distribution?
With P(X = k) = C(K, k) · C(N − K, n − k) / C(N, n). For N = 50, K = 10, n = 5 and k = 2 this gives 0.20984.
How does it differ from the binomial distribution?
The binomial applies when drawing with replacement, the hypergeometric without. If the sample is small compared with N, the two are close.
How do you calculate P(X ≥ k)?
Add the single probabilities from k up to the largest possible value. Here P(X ≥ 2) = 0.2581.
Sources and legal basis
As of: · Editorial policy
Related tools
- Binomial Distribution CalculatorBinomial distribution calculator: P(X = k), at most, at least and between from n and p, with mean, standard deviation and a full table. Free, no sign-up.
- Combination CalculatorCombination calculator for nCr and nPr, with or without repetition: exact results even for huge numbers, the formula, working and all four cases side by side.
- Probability calculatorProbability calculator: favourable over possible outcomes, two events, repeated trials (binomial) and drawing without replacement, like a lottery.
- Lottery number generator: random picks with bonus ballsFree lottery number generator for Powerball, Mega Millions, EuroMillions, UK Lotto and more: up to 24 random picks with bonus balls and the exact jackpot odds.
- Poisson Distribution CalculatorPoisson distribution calculator: probability of exactly, at most, at least or between k events at average rate λ, with the steps and a table of values.
- Geometric Distribution CalculatorGeometric distribution calculator for the number of trials until the first success: P(X = k), P(X ≤ k), mean and variance with the working shown.
- Online CalculatorCalculator online, free and instant: type or tap and see the answer as you go – order of operations, brackets, percent, square root, steps and a history list.
- Double integral calculatorDouble integral calculator: integrate f(x, y) over rectangles, regions with curved limits or in polar coordinates – result, error estimate, area and average.
- Octagon calculatorOctagon calculator for a regular octagon: enter the side, the width across flats or corners, the area or perimeter and get all dimensions and the miter angle.