Professional Documents
Culture Documents
Probability: Counting Principle and Its Applications
Probability: Counting Principle and Its Applications
Mujahid Abbas
Department of Mathematics
Email address: mujahid@lums.edu.pk
M. Abbas (Institute)
Math 230
1 / 24
Second Session
Counting:
M. Abbas (Institute)
Math 230
2 / 24
Second Session
Counting:
M. Abbas (Institute)
Math 230
2 / 24
Second Session
Counting:
M. Abbas (Institute)
Math 230
2 / 24
Second Session
M. Abbas (Institute)
Math 230
3 / 24
Second Session
Question:
Example
In how many dierent ways can one answer all the question of true false
test consisting of n questions?
M. Abbas (Institute)
Math 230
4 / 24
Second Session
Continued:
Solution
What is a task in this case?
1
To answer n questions!
M. Abbas (Institute)
Math 230
5 / 24
Second Session
Continued:
Solution
What is a task in this case?
1
To answer n questions!
M. Abbas (Institute)
Math 230
5 / 24
Second Session
Continued:
Solution
What is a task in this case?
1
To answer n questions!
= 2n ways
M. Abbas (Institute)
Math 230
5 / 24
Second Session
Example:
Example
How many licence plates of 3 letters followed by 3 numbers are possible?
M. Abbas (Institute)
Math 230
6 / 24
Second Session
Continued:
Solution
The task in this case is to ll six empty spaces on a licence plate.
1
We have six places, three places for letters and three places for
numbers.
M. Abbas (Institute)
Math 230
7 / 24
Second Session
Continued:
Solution
The task in this case is to ll six empty spaces on a licence plate.
1
We have six places, three places for letters and three places for
numbers.
Three places reserved for letters can be lled with (26)3 ways
M. Abbas (Institute)
Math 230
7 / 24
Second Session
Continued:
Solution
The task in this case is to ll six empty spaces on a licence plate.
1
We have six places, three places for letters and three places for
numbers.
Three places reserved for letters can be lled with (26)3 ways
Three places reserved for numbers can be lled with (10)3 ways
M. Abbas (Institute)
Math 230
7 / 24
Second Session
Continued:
Solution
The task in this case is to ll six empty spaces on a licence plate.
1
We have six places, three places for letters and three places for
numbers.
Three places reserved for letters can be lled with (26)3 ways
Three places reserved for numbers can be lled with (10)3 ways
M. Abbas (Institute)
Math 230
7 / 24
Second Session
Continued:
Solution
The task in this case is to ll six empty spaces on a licence plate.
1
We have six places, three places for letters and three places for
numbers.
Three places reserved for letters can be lled with (26)3 ways
Three places reserved for numbers can be lled with (10)3 ways
M. Abbas (Institute)
Math 230
7 / 24
Second Session
Examples:
Example
In how many ways can one arrange a, b and c?
M. Abbas (Institute)
Math 230
8 / 24
Second Session
Examples:
Solution
1
M. Abbas (Institute)
Math 230
9 / 24
Second Session
Examples:
Solution
1
M. Abbas (Institute)
Math 230
9 / 24
Second Session
Examples:
Solution
1
M. Abbas (Institute)
Math 230
9 / 24
Second Session
Examples:
Solution
1
M. Abbas (Institute)
Math 230
9 / 24
Second Session
Permutation:
M. Abbas (Institute)
Math 230
10 / 24
Second Session
Permutation:
M. Abbas (Institute)
Math 230
10 / 24
Second Session
Permutation:
M. Abbas (Institute)
Math 230
10 / 24
Second Session
Permutation:
M. Abbas (Institute)
Math 230
10 / 24
Second Session
Explanation:
1
M. Abbas (Institute)
Math 230
11 / 24
Second Session
Explanation:
1
M. Abbas (Institute)
Math 230
11 / 24
Second Session
Explanation:
1
2
3
M. Abbas (Institute)
Math 230
11 / 24
Second Session
Explanation:
1
2
3
M. Abbas (Institute)
Math 230
11 / 24
Second Session
Explanation:
1
2
3
M. Abbas (Institute)
Math 230
11 / 24
Second Session
Explanation:
1
2
3
Math 230
11 / 24
Second Session
Permutation:
M. Abbas (Institute)
Math 230
12 / 24
Second Session
Permutation:
M. Abbas (Institute)
Math 230
12 / 24
Second Session
Explanation:
n (n
1)(n
M. Abbas (Institute)
2)...(n
(r
1)) ways or
Math 230
13 / 24
Second Session
Explanation:
n (n
1)(n
2)...(n
(r
1)) ways or
M. Abbas (Institute)
ways or
Math 230
13 / 24
Second Session
Explanation:
n (n
1)(n
2)...(n
(r
1)) ways or
M. Abbas (Institute)
ways or
Math 230
13 / 24
Second Session
Explanation:
n (n
1)(n
Thus n Pr =
2)...(n
(r
1)) ways or
M. Abbas (Institute)
ways or
n!
(n
r )!
Math 230
13 / 24
Second Session
Cyclic Permutation:
Denition
The number of permutations of n distinct objects arranged in a circle
(called circular permutation) is
(n
1
1) !
M. Abbas (Institute)
Math 230
14 / 24
Second Session
Cyclic Permutation:
Denition
The number of permutations of n distinct objects arranged in a circle
(called circular permutation) is
(n
1) !
Two permutations are not considered dierent and are counted only
once if corresponding objects in the two arrangements have the same
object to their left and to their right. ( Fix one element and permute
the remaining elements).
M. Abbas (Institute)
Math 230
14 / 24
Second Session
Combinations:
1
M. Abbas (Institute)
n!
(r !)(n r )!
n
=n Cr = n choose r
r
Math 230
15 / 24
Second Session
Combinations:
1
=
2
n!
(r !)(n r )!
n
=n Cr = n choose r
r
M. Abbas (Institute)
Math 230
15 / 24
Second Session
Combinations:
1
=
2
3
n!
(r !)(n r )!
n
=n Cr = n choose r
r
M. Abbas (Institute)
Math 230
15 / 24
Second Session
Combinations:
1
=
2
3
n!
(r !)(n r )!
n
=n Cr = n choose r
r
M. Abbas (Institute)
Math 230
15 / 24
Second Session
Combinations:
1
=
2
3
4
5
n!
(r !)(n r )!
n
=n Cr = n choose r
r
Math 230
15 / 24
Second Session
If the order does matter, then you are counting permutations; answer
n!
is
(n r ) !
M. Abbas (Institute)
Math 230
16 / 24
Second Session
If the order does matter, then you are counting permutations; answer
n!
is
(n r ) !
if order does not matter, then you are counting combinations; answer
n!
is
r ! (n r ) !
M. Abbas (Institute)
Math 230
16 / 24
Second Session
If the order does matter, then you are counting permutations; answer
n!
is
(n r ) !
if order does not matter, then you are counting combinations; answer
n!
is
r ! (n r ) !
This is how lotteries work. The numbers are drawn one at a time, and
if you have the lucky numbers (no matter what order) you win! ( we
just want to know which r persons are chosen not the order in which
they are chosen).
M. Abbas (Institute)
Math 230
16 / 24
Second Session
If the order does matter, then you are counting permutations; answer
n!
is
(n r ) !
if order does not matter, then you are counting combinations; answer
n!
is
r ! (n r ) !
This is how lotteries work. The numbers are drawn one at a time, and
if you have the lucky numbers (no matter what order) you win! ( we
just want to know which r persons are chosen not the order in which
they are chosen).
How many subsets of r elements can be formed from the set of n
elements.
M. Abbas (Institute)
Math 230
16 / 24
Second Session
We derive a formula:
M. Abbas (Institute)
Math 230
17 / 24
Second Session
We derive a formula:
M. Abbas (Institute)
Math 230
17 / 24
Second Session
We derive a formula:
M. Abbas (Institute)
Math 230
17 / 24
Second Session
We derive a formula:
M. Abbas (Institute)
Math 230
17 / 24
Second Session
We derive a formula:
M. Abbas (Institute)
Math 230
17 / 24
Second Session
M. Abbas (Institute)
Math 230
18 / 24
Second Session
M. Abbas (Institute)
Math 230
18 / 24
Second Session
M. Abbas (Institute)
Math 230
18 / 24
Second Session
M. Abbas (Institute)
Math 230
18 / 24
Second Session
Math 230
18 / 24
Second Session
Combinatorial Identities
n
r
n
n
n
8
r (
n
12
Then n = 20.
M. Abbas (Institute)
Math 230
19 / 24
Second Session
M. Abbas (Institute)
Math 230
20 / 24
Second Session
M. Abbas (Institute)
Math 230
20 / 24
Second Session
Math 230
20 / 24
Second Session
:
Continued
1 If we take n = n = n = ... = n = 1 then it is total number of
1
2
3
k
permutations of n objects.
M. Abbas (Institute)
Math 230
21 / 24
Second Session
:
Continued
1 If we take n = n = n = ... = n = 1 then it is total number of
1
2
3
k
permutations of n objects.
2 If we take k = 2, it reduces to binomial coe cient: Divide the players
into two groups or partition them into two cells. One cell consists of r
elements and other cell consists of n r elements. Then using
multinomial coe cient technique, the total number of ways we can
n!
as
select r objects out of n objects is given by
r !.(n r )!
r + (n r ) = n
M. Abbas (Institute)
Math 230
21 / 24
Second Session
:
Continued
1 If we take n = n = n = ... = n = 1 then it is total number of
1
2
3
k
permutations of n objects.
2 If we take k = 2, it reduces to binomial coe cient: Divide the players
into two groups or partition them into two cells. One cell consists of r
elements and other cell consists of n r elements. Then using
multinomial coe cient technique, the total number of ways we can
n!
as
select r objects out of n objects is given by
r !.(n r )!
r + (n r ) = n
n!
3
(x1 + x2 + ... + xk )n = (
)x1n1 x2n2 x3n3 ...xknk , where the
n1 !n2 !...nk !
sum is taken over all tuples (n1 , n2 , , , , nk ) which add up to n.
M. Abbas (Institute)
Math 230
21 / 24
Second Session
:
Continued
1 If we take n = n = n = ... = n = 1 then it is total number of
1
2
3
k
permutations of n objects.
2 If we take k = 2, it reduces to binomial coe cient: Divide the players
into two groups or partition them into two cells. One cell consists of r
elements and other cell consists of n r elements. Then using
multinomial coe cient technique, the total number of ways we can
n!
as
select r objects out of n objects is given by
r !.(n r )!
r + (n r ) = n
n!
3
(x1 + x2 + ... + xk )n = (
)x1n1 x2n2 x3n3 ...xknk , where the
n1 !n2 !...nk !
sum is taken over all tuples (n1 , n2 , , , , nk ) which add up to n.
4
(x1 + x2 + x3 )2 = x12 + x22 + x32 + 2x1 x2 + 2x1 x3 + 2x2 x3 =
x12 x20 x30 + x10 x22 x30 + x10 x20 x32 + 2x11 x21 x30 + 2x1 x20 x3 + 2x10 x2 x3
M. Abbas (Institute)
Math 230
21 / 24
Second Session
:
Continued
1 If we take n = n = n = ... = n = 1 then it is total number of
1
2
3
k
permutations of n objects.
2 If we take k = 2, it reduces to binomial coe cient: Divide the players
into two groups or partition them into two cells. One cell consists of r
elements and other cell consists of n r elements. Then using
multinomial coe cient technique, the total number of ways we can
n!
as
select r objects out of n objects is given by
r !.(n r )!
r + (n r ) = n
n!
3
(x1 + x2 + ... + xk )n = (
)x1n1 x2n2 x3n3 ...xknk , where the
n1 !n2 !...nk !
sum is taken over all tuples (n1 , n2 , , , , nk ) which add up to n.
4
(x1 + x2 + x3 )2 = x12 + x22 + x32 + 2x1 x2 + 2x1 x3 + 2x2 x3 =
x12 x20 x30 + x10 x22 x30 + x10 x20 x32 + 2x11 x21 x30 + 2x1 x20 x3 + 2x10 x2 x3
5 Note that (2, 0, 0), (0, 2, 0), (0, 0, 2), (1, 1, 0), (1, 0, 1), (0, 1, 1) add up
to 2
M. Abbas (Institute)
Math 230
First week 2015
21 / 24
Second Session
Explanation:
In how many distinct ways can one arrange the letters P, E , P, P, E , and R
1
M. Abbas (Institute)
Math 230
22 / 24
Second Session
Explanation:
In how many distinct ways can one arrange the letters P, E , P, P, E , and R
1
M. Abbas (Institute)
Math 230
22 / 24
Second Session
Explanation:
In how many distinct ways can one arrange the letters P, E , P, P, E , and R
1
P1 P2 E1 P3 E2 R
M. Abbas (Institute)
Math 230
22 / 24
Second Session
Permutation:
1
If we had distinct letters we would have written 720 words ( possibilities) but 12 possibilities
reduces in to one word. 720 possibilities reduce into 60 words
M. Abbas (Institute)
Math 230
23 / 24
Second Session
Permutation:
1
If we had distinct letters we would have written 720 words ( possibilities) but 12 possibilities
reduces in to one word. 720 possibilities reduce into 60 words
M. Abbas (Institute)
Math 230
23 / 24
Second Session
Permutation:
1
If we had distinct letters we would have written 720 words ( possibilities) but 12 possibilities
reduces in to one word. 720 possibilities reduce into 60 words
M. Abbas (Institute)
Math 230
23 / 24
Second Session
Explanation:
n
n1
n1
n2
M. Abbas (Institute)
(n1 + n2 )
n3
Math 230
6
3
3
2
1
1
= 60
24 / 24