You are on page 1of 3

2.

Conditional Probability

Example 2.3.1 An experiment consists of dealing two cards from a pack, one after the
other. Find the probability that both cards are diamonds.
Solution : Events :
1D : 1st card is a diamond 2D : 2nd card is a diamond
We need P (ID 2D).
We have P (1D) = 1/4. This means - we expect that the 1st card will be a diamond in 1/4
of all repetitions of the experiment. In how many of these cases do we expect that the 2nd
card will be a diamond?
After the first is dealt there are 51 cards remaining, of which 12 are diamonds. Thus,
in 12/51 of those 1/4 of all cases in which the 1st card is a diamond, the second is also a
diamond, i.e. in
12 1
1
=
51 4
17
of all cases.
1
We conclude that P (1D and 2D) = 17
.
Terminology: 12/51 = 4/17 is the conditional probability of 2D given the 1D occurs. It is
denoted by P (2D|1D).
This is not the same as P (2D) which is 1/4.
Nor is it the same as P (2D|1D) which is 13/51.
Formula 2.3.2 Let A and B be events associated to an experiment. Then
P (A and B) = P (A B) = P (A)P (B|A) = P (B)P (A|B).
Alternatively
P (B|A) =

P (A B)
P (A B)
andP (A|B) =
.
P (A)
P (B)

Example 2.3.3 Two fair dice are rolled. Find the probability that the total score is at least
8, given that it is an even number.
Solution: Events : A - total score 8; B - total score even. We need P (A|B) and we know
P (A|B) =

P (A B)
.
P (B)

There are 36 outcomes in 18 of which the total score is even. Thus P (B) = 18/36 = 1/2.
There are 9 outcomes in which the total score is even and at least 8. Thus
P (A B) = 9/36 = 1/4.
Now
P (A|B) =

1/4
= 1/2.
1/2

Note: This is not equal to P (A) which is 15/36.


Exercise: Show that P (B|A) = 3/5.

Definition 2.3.4 Events A and B are called independent if


P (A B) = P (A)P (B).
This means P (B) = P (B|A) and P (A) = P (A|B), i.e. the probability of one of these events
occurring is unaffected by whether the other occurs or not.
Example 2.3.5 A factory has machines A and B making 60% and 40% respectively of
total production. 3% of the items produced by Machine A and 5% of the items produced by
Machine B are defective.
(a) Find the probability that a randomly selected item is defective.
(b) Given that an item is defective, find the probability that it came from Machine A.
Solution: Events :
A
B
D

- (randomly selected) item came from Machine A


- (randomly selected) item came from Machine B
- (randomly selected) item is defective

We know : P (A) = 0.6, P (B) = 0.4, P (D|A) = 0.03, P (D|B) = 0.05.


(a) We need P (D). The event D is the union of the mutually exclusive events D A
(defective and from A) and D B (defective and from B). Thus
P (D) = P (D A) + P (D B)
= P (A)P (D|A) + P (B)P (D|B)
= 0.6(0.03) + 0.4(0.05)
= 0.038
(Alternatively - 3% of the 60% of items from Machine A are defective, or 1.8% of all
items, and 5% of items from Machine B, or 2% of all items, are defective - this is 3.8%
of all items in total.)
(b) We need P (A|D). This is found by
P (A|D) =
=
=
=

P (A D)
P (D)
P (A)P (D|A)
P (A)P (D|A) + P (B)P (D|B)
0.6(0.03)
0.038
0.4737

Example 2.3.6 A motor insurance company insures drivers in age groups A, B and C.
40% of the companys customers are in age group A, 25% are in B and 35% are in C.
The companys records show that on average 2% of customers in age group A, 1% of
those in age group B, and 1.5% of those in age group C make a claim each year.
(a) What is the probability that a randomly selected driver will make a claim next year?
(b) If a driver is selected at random, what is the probability that this person is from age
group C and will not make a claim in the next year?

(c) Given that a driver has made a claim in the past year, what is the probability that this
person is from age group C?
Solution: Events :
A : Randomly selected person is from age group A.
B : Randomly selected person is from age group B.
C : Randomly selected person is from age group C.
Cl : Randomly selected person will make a claim in the next year.
We know

P (A) = 0.4
P (B) = 0.25
P (C) = 0.35
P (Cl|A) = 0.02 P (Cl|B) = 0.01 P (Cl|C) = 0.015

(a) P (Cl) = P (Cl A) + P (Cl B) + P (Cl C)


= P (A)P (Cl|A) + P (B)P (Cl|B) + P (C)P (Cl|C)
= 0.04(0.02) + 0.25(0.01) + 0.35(0.015)
= 0.01575
(b) P (Cl C) = P (C)P (Cl|C)
= 0.35(0.985) = 0.34475

(c) P (A|Cl) =

P (A Cl)
P (Cl)
P (A)P (Cl|A)
P (Cl)

0.4(0.02)
= 0.5079
0.01575
In the above examples we have used Bayess Theorem, which states the following.
Theorem 2.3.7 (Bayes) Let E1 , . . . , Ek be subsets of a sample space S with the property
that every element of S belongs to exactly one of the Ei . Let A be any event (subset of S).
Then
P (Ei )P (A|Ei )
P (Ei |A) = Pk
.
j=1 P (Ej )P (A|Ej )

You might also like