Probability & Combinatorics
Intermediate

Conditional Probability

Probability of A given that B has occurred.

Formula

P(A∣B)=P(A∩B)P(B)P(A|B) = \frac{P(A \cap B)}{P(B)}

Variables

A,BEvents
P(B)Nonzero

Example

Updates probability with new information

How it works

Conditional probability measures how likely event A is once you already know event B has happened. The key idea is that event B shrinks the sample space to only the outcomes where B is true, so we compare the overlap A ∩ B to the total chance of B. The formula works because P(A ∩ B) is exactly the part of B that also satisfies A, and dividing by P(B) rescales that overlap to a probability within the restricted set.

When to use it

Use this whenever new information changes the set of outcomes you should consider, such as drawing cards without replacement, medical test results, or reliability problems. It is especially useful when you know one event has occurred and want the probability of another event under that condition.

Worked example, step by step

A school has 200 students. 40 students play basketball (event B). 18 students both play basketball and are in the school band (event A ∩ B). We want the probability that a student is in the band given that they play basketball: P(A|B). Use the formula: P(A|B) = P(A ∩ B) / P(B) P(A ∩ B) = 18/200 P(B) = 40/200 So P(A|B) = (18/200) ÷ (40/200) = 18/40 = 9/20 = 0.45 Final answer: P(A|B) = 0.45, or 45%.

Common mistakes to avoid

  • Using P(A)/P(B) instead of the overlap P(A ∩ B)
  • Forgetting that P(B) must be nonzero
  • Reversing the condition and calculating P(B|A) instead of P(A|B)

Did You Know?

Conditional probability is the foundation of Bayesian reasoning.

Share this formula

Reviewed & maintained by the FormulaWon editorial teamLast reviewed September 2026