Sunday, January 29, 2012

Permutations and Combinations!

Permutation: when the order is important or different.
nPr=n!/(n-r)!

Combination: when the order is not important or identical.
nCr=n!/(n-r)!r!

Example 1:
In how many ways can a club with 13 members choose 4 different officers?
13P4
13!/9!=13*12*11*10*9*8*7*6*5*4*3*2*1/9*8*7*6*5*4*3*2*1
both 9*8*7*6*5*4*3*2*1 cancel out, so you are left with
13*12*11*10
=17160
In how many ways can the club choose a 4-person governing council?
13C4
13!/9!4!=13*12*11*10*9*8*7*6*5*4*3*2*1/9*8*7*6*5*4*3*2*1*4*3*2*1
both 9*8*7*6*5*4*3*2*1 cancel out, so you are left with
13*12*11*10/4*3*2*1
=715

Example 2:
A teacher has a collection of 20 true-false questions and wishes to choose 5 of them for a quiz. How many quizzes can be made if the order of the questions is considered important?
20P5
20!/15!=20*19*18*17*16*15*14*13*12*11*10*9*8*7*6*5*4*3*2*1/15*14*13*12*11*10*9*8*7*6*5*4*3*2*1
both 15*14*13*12*11*10*9*8*7*6*5*4*3*2*1 cancel out, so you are left with
20*19*18*17*16
=1860480
Considered unimportant?
20C5
20!/15!5!
=20*19*18*17*16*15*14*13*12*11*10*9*8*7*6*5*4*3*2*1/15*14*13*12*11*10*9*8*7*6*5*4*3*2*1*5*4*3*2*1
both 15*14*13*12*11*10*9*8*7*6*5*4*3*2*1 cancel out, so you are left with
20*19*18*17*16/5*4*3*2*1
=15504

Example 3:
Suppose you bought 4 books and gave one to each of 4 friends. In how many ways can the books be given if they are all different?
4P4
4!/0!
4*3*2*1/1
(((0!=1)))
=24
If they are all identical?
4C4
4!0!4!=4*3*2*1/1*4*3*2*1
both 4*3*2*1 cancel out, so
=1

No comments:

Post a Comment