Learn
Lesson · Discrete Probability · Conditioning

Conditional Probability

P(A | B) = P(A ∩ B)/P(B) is not a new axiom: it is the original counting restricted to the outcomes where B holds. The traps are all about which of P(A|B) and P(B|A) you have computed.

P(A | B) = P(A ∩ B) / P(B) requires P(B) > 0 P(A ∩ B) = P(A | B) · P(B) the multiplication rule P(A | B) ≠ P(B | A) in general conditioning SHRINKS the sample space to B
A smaller sample space

Core ideas

What this lesson establishes

Conditioning is re-counting inside a subset. Everything difficult about it is about interpretation, not arithmetic.

1

Conditioning restricts the space

P(A|B) counts the outcomes in A among those in B. The denominator is |B|, not |S|.

2

The two conditionals are different numbers

P(test positive | disease) and P(disease | test positive) differ by the base rate, often by orders of magnitude.

3

The multiplication rule chains

P(A ∩ B ∩ C) = P(A)P(B|A)P(C|A∩B) — useful for sequential draws, where each step conditions on the previous ones.

The material

Conditioning

The definition, why it is a definition rather than a theorem, and the standard traps.

Definition · Conditional probability

For events A, B with P(B) > 0, P(A | B) = P(A ∩ B) / P(B).

In the equally-likely model this is transparent: P(A|B) = (|A ∩ B|/|S|)/(|B|/|S|) = |A ∩ B|/|B|. The outcomes outside B have been discarded, and B is now the sample space.

Theorem · Conditional probability is a probability

For fixed B with P(B) > 0, the function A ↦ P(A|B) satisfies all three axioms. So every theorem about probability holds for conditional probability too.

Theorem · Multiplication rule

P(A ∩ B) = P(A|B)P(B) = P(B|A)P(A), and more generally P(A₁ ∩ ⋯ ∩ A_n) = P(A₁)P(A₂|A₁)P(A₃|A₁∩A₂)⋯.

Example · Sequential draws

Two cards from a deck without replacement. P(both aces) = P(first ace) · P(second ace | first ace) = (4/52)(3/51) = 1/221. Conditioning is exactly what handles "without replacement": the second probability changes because the first draw changed the deck.

The two conditionals are different

Example · Dice

Roll two dice. P(sum is 7 | first die is 4) = 1/6, since among the six outcomes with a 4 first, exactly one has sum 7. But P(first die is 4 | sum is 7) = 1/6 too — a coincidence arising from symmetry, not a rule.

Example · Where they differ wildly

P(is a mammal | is a dog) = 1, while P(is a dog | is a mammal) is small. The two conditionals share a numerator P(A ∩ B) and have different denominators, and the ratio of the denominators is exactly how much they differ.

The Monty Hall problem

Three doors, a prize behind one. You pick door 1. The host, who knows where the prize is, opens a different door with no prize behind it — say door 3 — and offers you a switch. Should you?

prize behind your choice host must open switching wins? door 1 door 1 door 2 or 3 NO door 2 door 1 door 3 YES door 3 door 1 door 2 YES Each row has probability 1/3, so switching wins with probability 2/3.

The step people miss is that the host's action is not random: he knows and is constrained to open a losing door. That constraint is information, and conditioning on it is what makes switching better. If the host opened a door at random and it happened to be empty, the answer would be 1/2 — a different problem with the same picture.

Interactive

Sample space, event, condition

Exact fractions, every outcome listed

Sample space
in Ain Bin both

Method

Conditioning correctly

Say which event is the condition, out loud.

1

Identify the conditioning event

P(A|B) conditions on B. Writing the sentence "given that B happened" prevents the swap.

2

Restrict the sample space

In the equally-likely model, count within B. The denominator changes and the numerator becomes |A ∩ B|.

3

Use the multiplication rule for sequences

Each draw conditions on the previous ones. Without replacement, the denominators shrink.

4

Ask whether you wanted the other conditional

The two are related by Bayes, which is “Bayes' Theorem”. Computing the wrong one is the most consequential error in this course.

Conditioning

Score 0 / 0

The two-child problem

A family has two children. The sample space is {BB, BG, GB, GG}, equally likely.

"At least one is a boy." What is P(both boys)? B = {BB, BG, GB} |B| = 3 A ∩ B = {BB} |A ∩ B| = 1 P(A | B) = 1/3 "The ELDER is a boy." What is P(both boys)? B' = {BB, BG} |B'| = 2 A ∩ B' = {BB} |A ∩ B'| = 1 P(A | B') = 1/2 Same family, two different pieces of information, two answers.

The difference is real and not a trick: "at least one is a boy" and "the elder is a boy" restrict the sample space to sets of different sizes. Almost every disputed probability puzzle turns out to be an ambiguity about which restriction was intended.

Common mistakes

1
Swapping the two conditionalsP(A|B) and P(B|A) are different numbers with the same numerator. “Bayes' Theorem” gives the exact relationship.
2
Forgetting the denominator changedConditioning restricts the sample space. Dividing by |S| instead of |B| gives P(A ∩ B), not P(A|B).
3
Ignoring how the information arrivedMonty Hall and the two-child problem both hinge on it. "At least one boy" and "the elder is a boy" are different conditions.

Check your understanding

✓
Finish when you can state the restricted sample space.

For each conditional probability you compute, write down explicitly which outcomes remain. That sentence catches the swap, the wrong denominator and the ambiguity all at once.

Note: Conditional probability is where probability stops being counting and starts being modelling. The arithmetic never gets harder than division; deciding what to condition on is where the difficulty lives.

Kept in this browser only, for you. Nothing is sent anywhere and nothing checks it. Carry it to another device.

Feedback and recommendations

Something to change about this lesson? Write it down, tick it off when it is handled, and export the list when you want to act on it. Kept in this browser only: nothing is sent anywhere, and nobody is notified.

No recommendations yet for this lesson.