Conditional probability
Conditional probability P(A | B) from two-way tables, Venn diagrams and the formula P(A ∩ B) ÷ P(B).
Extra information changes probabilities. The chance a random person is over $180$ cm tall is small. The chance given that they play professional basketball is much bigger. Conditional probability is how we update a probability once we know something has happened.
Shrinking the sample space
$P(A \mid B)$ is read "the probability of $A$ given $B$". Once we know $B$ has happened, every outcome outside $B$ is off the table. So we count only inside $B$.
A die is rolled and shows an even number. What is the probability it is a $6$?
Without the extra information, $P(6) = \tfrac16$. Knowing the roll was even doubled the chance.
From a two-way table
$50$ students were asked whether they own a pet ($P$) and whether they learn a musical instrument ($M$).
| $M$ | $M'$ | Total | |
|---|---|---|---|
| $P$ | $12$ | $18$ | $30$ |
| $P'$ | $8$ | $12$ | $20$ |
| Total | $20$ | $30$ | $50$ |
Find (a) $P(M \mid P)$ (b) $P(P \mid M)$.
The formula
Example 2 used $\dfrac{n(A \cap B)}{n(B)}$. Divide the top and bottom by the total, and the counts become probabilities:
$P(A) = 0.5$, $P(B) = 0.4$ and $P(A \cup B) = 0.7$. Find $P(A \mid B)$.
Your turn
Two coins are tossed. Given that at least one shows a head, what is the probability that both are heads?
Show the working
The outcomes are HH, HT, TH, TT. "At least one head" removes TT, leaving three equally likely outcomes. Only HH has two heads, so the probability is $\dfrac13$, not $\dfrac12$.
A die shows an even number. What is the probability it is a $6$?
Given even, the outcomes are $2$, $4$, $6$. One of the three is a $6$.
$P(A \cap B) = 0.12$ and $P(B) = 0.4$. Find $P(A \mid B)$.
$P(A \mid B) = \dfrac{0.12}{0.4} = 0.3$.
Of $80$ people, $32$ wear glasses ($G$), $20$ are left-handed ($L$) and $8$ are both. Find $P(L \mid G)$ as a decimal.
Given glasses: $32$ people, of whom $8$ are left-handed. $\dfrac{8}{32} = 0.25$.
Using the same $80$ people, find $P(G \mid L)$ as a decimal.
Given left-handed: $20$ people, of whom $8$ wear glasses. $\dfrac{8}{20} = 0.4$.
Two coins are tossed. Given that at least one is a head, the probability of two heads is:
Remaining outcomes: HH, HT, TH. Only HH works: $\dfrac13$.
$P(A) = 0.6$ and $P(A \cap B) = 0.3$. Find $P(B \mid A)$.
Now $A$ is given, so divide by $P(A)$: $\dfrac{0.3}{0.6} = 0.5$.
In a two-way table, to find $P(\text{Year 10} \mid \text{plays sport})$ you divide by:
The given event is "plays sport", so the sample space shrinks to that group.
$P(A) = 0.5$, $P(B) = 0.4$ and $P(A \cup B) = 0.75$. Find $P(A \mid B)$.
$P(A \cap B) = 0.5 + 0.4 - 0.75 = 0.15$. Then $P(A \mid B) = \dfrac{0.15}{0.4} = 0.375$.
Challenge: two dice are rolled and the total is $8$. Find the probability that at least one die shows a $6$, as a decimal.
Totals of $8$: $(2,6), (3,5), (4,4), (5,3), (6,2)$, so $5$ outcomes. Two of them contain a $6$. $P = \dfrac25 = 0.4$.
Challenge: $P(A) = 0.5$, $P(B) = 0.25$ and $P(B \mid A) = 0.3$. Find $P(A \mid B)$.
$P(A \cap B) = P(B \mid A) \times P(A) = 0.3 \times 0.5 = 0.15$. Then $P(A \mid B) = \dfrac{0.15}{0.25} = 0.6$.
Coaching Centre