Counting Theore.
Counting Theore.
Semester 1
Example
A simple survey consists of three multiple choice questions. The
first question has 3 possible answers, the second has 4 possible
answers and the third has 3 possible answers. What is the total
number of different ways in which this survey could be completed?
3 × 4 × 3 = 36.
Example
A simple survey consists of three multiple choice questions. The
first question has 3 possible answers, the second has 4 possible
answers and the third has 3 possible answers. What is the total
number of different ways in which this survey could be completed?
3 × 4 × 3 = 36.
Example
A circuit board contains 4 relays each of which can be set to any
of three positions. What is the total number of distinct
configurations for the 4 relays?
Each relay can be set in 3 ways and we have 4 relays.
So the total number of configurations is (3)(3)(3)(3) = 81.
n · (n − 1) · (n − 2) · · · 3 · 2 · 1
Or compactly, n! (n factorial).
Example
How many different ways can we arrange the letters BBBACDE?
Answer 7!
3! = (7)(6)(5)(4) = 840.
Example
How many different numbers can be formed by rearranging
2212562?
Answer 7!
4! = 210.
Example
How many different ways can we rearrange the letters of
MISSISSIPPI?
M I S P
I S P
I S
I S
We have 11 letters in total, of which 4 are ‘I’, 4 are ‘S’ and ‘2’ are
‘P’. In this situation, the total number of different rearrangements
is
11!
.
4!4!2!
r -Permutations
How many permutations of n distinct objects, taken r at a time
are possible?
Again, we have n ways of choosing the first object.
We then have n − 1 ways of choosing the second object and
so on.
When choosing the r th object, we have already chosen r − 1
objects, so there are still n − (r − 1) = n − r + 1 possible
choices.
n · (n − 1) · · · (n − r + 1).
Example
In a race with eight competitors, how many different
possibilities are there for who finishes finish first, second and
third?
Three major new roads are to be constructed and eight
companies have tendered for the three projects. If at most one
construction project is to be given to any one company, what
is the total number of ways in which the three contracts can
be awarded?
Example
In a race with eight competitors, how many different
possibilities are there for who finishes finish first, second and
third?
Three major new roads are to be constructed and eight
companies have tendered for the three projects. If at most one
construction project is to be given to any one company, what
is the total number of ways in which the three contracts can
be awarded?
Both of these have the same answer - 8 P3 .
Combinations
How many different ways can we select a set of size r from a larger
set of n distinguishable objects? The order of selection does not
matter.
We are asking for the number of combinations of n objects taken r
at a time. This number is written as nr .
Example
How many ways can a company select 3 candidates to
interview from a short list of 15?
Answer
15 (15)(14)(13)
= = 455
3 (3)(2)(1)
In how many ways can a subcommittee of 5 be chosen from a
panel of 20?
Answer
20 (20)(19)(18)(17)(16)
= = 15504.
5 (5)(4)(3)(2)(1)
Example
A drum contains 3 black balls, 5 red balls and 6 green balls. If 4
balls are selected at random what is the probability that the 4
selected contain
(i) No red ball?
(ii) Exactly 1 black ball?
(iii) Exactly 1 red ball and exactly 2 green balls?
Example
(i) Total number of ways of choosing 4 balls from 14 is 14
4 .
Total
number of ways of choosing 4 balls, none of which is red is
9
4 .
So the probability that the 4 balls contain no red ball is
9
4
14
.
4
(ii) 1 black ball can be chosen in 31 ways, while the other three
Example
Probability of choosing 1 red ball and two green balls is
5 6 3
1 2 1
14
.
4
Example
A hand of 5 cards is dealt from a well-shuffled deck. What is the
probability that the hand contains:
(i) No aces?
(ii) 5 clubs?
(iii) At least one ace?
(iv) 3 clubs and 2 hearts?
Example
(485)
(i) Answer: .
(525)
(13)
(ii) Answer: 525 .
(5)
(485)
(iii) Answer: 1 − .
(525)
13 13
( )( )
(iv) Answer: 3 52 2 .
(5)