Card Draw Probability Calculator

Calculate the probability of drawing at least a certain number of desired cards when drawing from a deck (hypergeometric distribution).

Results will appear here.

Formula

This calculator uses the Hypergeometric Distribution:

P(X = k) = C(K, k) × C(N−K, n−k) / C(N, n)

  • N = total cards in the deck
  • K = total desired cards in the deck
  • n = number of cards drawn
  • k = desired number of successes in the draw
  • C(a, b) = binomial coefficient = a! / (b! × (a−b)!)

Mean: μ = n × (K / N)

Variance: σ² = n × (K/N) × ((N−K)/N) × ((N−n)/(N−1))

Log-space computation is used to handle large factorials accurately.

Assumptions & References

  • Drawing is done without replacement (hypergeometric model). For drawing with replacement, use the binomial distribution instead.
  • All cards are equally likely to be drawn at any point.
  • The deck is well-shuffled (uniform random distribution).
  • N, K, n, k must all be non-negative integers with K ≤ N and n ≤ N.
  • Floating-point precision: log-space arithmetic is used to avoid overflow for large decks.
  • Reference: Hypergeometric distribution — Feller, W. (1968). An Introduction to Probability Theory and Its Applications.
  • Common use cases: trading card games (MTG, Pokémon), poker hand analysis, quality control sampling.

In the network