Probability
2. Discrete Distributions
Hypergeometric

Hypergeometric Distribution

The Hypergeometric distribution models the number of successes when you sample without replacement from a finite population.

Setup

  • Population size: NN
  • Number of successes in population: KK
  • Draws (sample size): nn
  • Random variable: XX = number of successes in the sample

Then:

XHypergeometric(N,K,n)X \sim \mathrm{Hypergeometric}(N, K, n)

PMF

P(X=k)=(Kk)(NKnk)(Nn)P(X=k) = \frac{\binom{K}{k}\binom{N-K}{n-k}}{\binom{N}{n}}

Intuition

You’re counting: “choose kk successes” and “choose nkn-k failures”, divided by “choose nn total”.

Hypergeometric vs Binomial

  • Hypergeometric: without replacement → probabilities change after each draw.
  • Binomial: with replacement / independent trials → probability stays constant.

If the population is huge relative to the sample (e.g., nNn \ll N), Hypergeometric is often well-approximated by a Binomial with p=K/Np=K/N.

Key facts

  • Mean: E[X]=nKNE[X] = n\frac{K}{N}
  • Variance:
Var(X)=nKN(1KN)NnN1\mathrm{Var}(X)=n\frac{K}{N}\left(1-\frac{K}{N}\right)\frac{N-n}{N-1}

The factor NnN1\frac{N-n}{N-1} is the finite population correction (variance is smaller than Binomial because you’re not sampling independently).

When to use

  • Cards without replacement
  • Auditing / QA sampling from a finite batch
  • Any “draw nn items from NN without putting them back” scenario

Test Your Knowledge

Example: Hypergeometric (without replacement)

A deck of 52 cards contains 4 Aces. You draw 5 cards from the deck without replacement. What is the probability you draw exactly 2 Aces?

View Step-by-Step Solution

Because we are drawing without replacement from a finite population, this is Hypergeometric.

Formula: (Kk)(NKnk)(Nn)\frac{\binom{K}{k} \binom{N-K}{n-k}}{\binom{N}{n}}

  • Total population N=52N = 52
  • Total successes K=4K = 4 (Aces)
  • Sample size n=5n = 5
  • Desired successes k=2k = 2

(42)(483)(525)\frac{\binom{4}{2} \binom{48}{3}}{\binom{52}{5}}

  • (42)=6\binom{4}{2} = 6
  • (483)=17,296\binom{48}{3} = 17,296
  • (525)=2,598,960\binom{52}{5} = 2,598,960

P(X=2)=6×17,2962,598,9600.0399P(X=2) = \frac{6 \times 17,296}{2,598,960} \approx 0.0399

There is a 3.99% chance of drawing exactly 2 Aces in a 5-card hand.