Foundations of Probability
4. Conditional Probability
Learning outcomes
- I can define conditional probability.
- I can calculate conditional probabilities.
- I can distinguish dependent and independent events.
- I can interpret conditional probability in context.
- I can solve practical problems involving conditional probability.
Conditional Probability
Probability often changes when we receive new information. Conditional probability describes the probability of an event occurring given that another event has already occurred or is known to be true.
For example, suppose a school has 200 students and 80 study chemistry. Of those 80 chemistry students, 30 also study physics.
If we randomly select a student from the whole school, the probability that the student studies physics is based on all 200 students.
But if we are told:
"The student studies chemistry."
our sample space has changed. We are now considering only the 80 chemistry students.
The probability that this student also studies physics is:
30/80 = 3/8 = 0.375
or:
37.5%
This is a conditional probability.
What Is Conditional Probability?
Conditional probability asks:
What is the probability of A if we already know that B has occurred?
The notation is:
P(A | B)
and is read:
"the probability of A given B."
The vertical line:
|
means:
given that
The important idea is that knowing B has occurred changes the sample space.
Instead of considering all possible outcomes, we consider only the outcomes contained in B.
The Conditional Probability Formula
Conditional probability compares the outcomes that belong to both A and B with all outcomes belonging to B.

In words:
conditional probability = probability of both events / probability of the given event
The condition B becomes our new reference group.
Understanding the Formula
Suppose:
P(B) = 0.60
and:
P(A ∩ B) = 0.30
Then:
P(A | B)
= 0.30/0.60
= 0.50
So once we know that B has occurred, there is a 50% probability that A also occurs.
Notice that we are no longer comparing the intersection with the entire original sample space.
We compare it only with B.
The Reduced Sample Space
Conditional probability can be understood as creating a new sample space.
Suppose a class contains:
| Plays Football | Does Not Play Football | Total | |
|---|---|---|---|
| Girls | 12 | 18 | 30 |
| Boys | 20 | 10 | 30 |
| Total | 32 | 28 | 60 |
If we ask:
What is the probability that a randomly selected student plays football?
we use all 60 students:
P(football) = 32/60
= 8/15
But suppose we ask:
What is the probability that a student plays football, given that the student is a girl?
Now we consider only the girls.
There are:
30 girls
and:
12 girls play football.
Therefore:
P(football | girl)
= 12/30
= 0.40
The original sample space of 60 has effectively been reduced to 30.
Conditional Probability from Counts
When a problem gives frequencies rather than probabilities, we can use:
P(A | B) = n(A ∩ B)/n(B)
where:
n(A ∩ B) = number of outcomes belonging to both A and B
n(B) = number of outcomes belonging to B
This is often easier than converting everything into probabilities first.
Worked Example: School Subjects
A school has:
120 students
70 study Biology
45 study Chemistry
30 study both Biology and Chemistry
Find:
P(Biology | Chemistry)
Since we know the student studies Chemistry, Chemistry becomes the restricted sample space.
There are:
45 Chemistry students
and:
30 study both subjects.
Therefore:
P(Biology | Chemistry)
= 30/45
= 2/3
≈ 0.667
So approximately:
66.7%
of Chemistry students also study Biology.
Reversing the Condition
Now calculate:
P(Chemistry | Biology)
There are:
70 Biology students
and:
30 study both subjects.
Therefore:
P(Chemistry | Biology)
= 30/70
= 3/7
≈ 0.429
or approximately:
42.9%
Notice:
P(Biology | Chemistry) ≠ P(Chemistry | Biology)
This is extremely important.
Changing the condition changes the denominator.
The Direction of the Condition Matters
Consider:
P(A | B)
and:
P(B | A)
These are usually different.
For:
P(A | B)
we restrict attention to B.
For:
P(B | A)
we restrict attention to A.
A useful reading strategy is:
P(A | B)
means:
"Among the outcomes where B occurred, what proportion also belong to A?"
Conditional Probability with Venn Diagrams
Venn diagrams provide a useful way to understand conditional probability.
Suppose:
n(A) = 35
n(B) = 40
n(A ∩ B) = 20
and we want:
P(A | B)
Once B is given, everything outside B becomes irrelevant.
Within B there are:
40 outcomes.
Of these:
20 also belong to A.
Therefore:
P(A | B)
= 20/40
= 1/2
Conditional Probability from a Two-Way Table
Suppose a survey gives:
| Owns a Pet | No Pet | Total | |
|---|---|---|---|
| Apartment | 24 | 36 | 60 |
| House | 56 | 34 | 90 |
| Total | 80 | 70 | 150 |
Find:
P(owns a pet | lives in an apartment)
We consider only the 60 apartment residents.
Of those:
24 own pets.
Therefore:
P(pet | apartment)
= 24/60
= 0.40
Now find:
P(apartment | owns a pet)
There are:
80 pet owners
and:
24 live in apartments.
Therefore:
P(apartment | pet)
= 24/80
= 0.30
Again, reversing the condition changes the probability.
Conditional Probability and the Multiplication Rule
Conditional probability leads directly to the general multiplication rule.
Starting from the conditional relationship, we can rearrange to obtain:
P(A ∩ B) = P(B) × P(A | B)
or equivalently:
P(A ∩ B) = P(A) × P(B | A)
This is extremely useful for multi-stage probability problems.
Worked Example: Drawing Marbles
A bag contains:
5 red marbles
3 blue marbles
Two marbles are drawn without replacement.
Find the probability that both are red.
First draw:
P(first red) = 5/8
If the first marble is red, then:
4 red marbles remain
7 total marbles remain.
Therefore:
P(second red | first red)
= 4/7
So:
P(both red)
= 5/8 × 4/7
= 20/56
= 5/14
The second probability is conditional on what happened during the first draw.
Dependent Events
Events are dependent when the occurrence of one event changes the probability of another.
Drawing objects without replacement is a common example.
Suppose a bag contains:
6 green marbles
4 yellow marbles
Initially:
P(green) = 6/10
If a green marble is selected and not replaced:
P(green on second draw | green first)
= 5/9
The probability changed from:
6/10 = 0.60
to:
5/9 ≈ 0.556
Therefore, the events are dependent.
Independent Events
Events are independent if the occurrence of one does not change the probability of the other.
For independent events:
P(A | B) = P(A)
and:
P(B | A) = P(B)
Knowing one event occurred gives us no useful information about the probability of the other.
For example:
- tossing a coin
- rolling a die
Knowing the coin landed heads does not affect the probability of rolling a 6.
Independent Events and Intersection
For independent events, the probability of both occurring is found by multiplying their individual probabilities.
