Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Permutations and Combinations Mathematics and Statistics Permuntation & Combination 1 • In this section, techniques will be introduced for counting • the unordered selections of distinct objects and • the ordered arrangements of objects • of a finite set. Mathematics and Statistics Permuntation & Combination 2 6.2.1 Arrangements • The number of ways of arranging n unlike objects in a line is n !. • Note: n ! = n (n-1) (n-2) ···3 x 2 x 1 Mathematics and Statistics Permuntation & Combination 3 Example • It is known that the password on a computer system contain • the three letters A, B and C • followed by the six digits 1, 2, 3, 4, 5, 6. • Find the number of possible passwords. Mathematics and Statistics Permuntation & Combination 4 Solution • There are 3! ways of arranging the letters A, B and C, and • 6! ways of arranging the digits 1, 2, 3, 4, 5, 6. • Therefore the total number of possible passwords is • 3! x 6! = 4320. • i.e. 4320 different passwords can be formed. Mathematics and Statistics Permuntation & Combination 5 Like Objects • The number of ways of arranging in a line • n objects, • of which p are alike, is n! p! Mathematics and Statistics Permuntation & Combination 6 The result can be extended as follows: • The number of ways of arranging in a line n objects • of which p of one type are alike, • q of a second type are alike, • r of a third type are alike, and so on, is n! p!q!r! Mathematics and Statistics Permuntation & Combination 7 Example • Find the number of ways that the letters of the word • STATISTICS • can be arranged. Mathematics and Statistics Permuntation & Combination 8 Solution • • • • The word STATISTICS contains 10 letters, in which S occurs 3 times, T occurs 3 times and • I occurs twice. Mathematics and Statistics Permuntation & Combination 9 • Therefore the number of ways is 10! 50400 3!3!2! • That is, there are 50400 ways of arranging the letter in the word STATISTICS. Mathematics and Statistics Permuntation & Combination 10 Example • A six-digit number is formed from the digits • 1, 1, 2, 2, 2, 5 and • repetitions are not allowed. • How many these six-digit numbers are divisible by 5? Mathematics and Statistics Permuntation & Combination 11 Solution • If the number is divisible by 5 then it must end with the digit • 5. • Therefore the number of these sixdigit numbers which are divisible by 5 is equal to the number of ways of arranging the digits • 1, 1, 2, 2, 2. Mathematics and Statistics Permuntation & Combination 12 • Then, the required number is 5! 10 2!3! • That is, there are 10 of these sixdigit numbers are divisible by 5. Mathematics and Statistics Permuntation & Combination 13 6.2.2 Permutations • A permutation of a set of distinct objects is an ordered arrangement of these objects. • An ordered arrangement of r elements of a set is called an rpermutation. • The number of r-permutations of a set with n distinct elements, Mathematics and Statistics Permuntation & Combination 14 • i.e. the number of permutations of r objects taken from n unlike objects is: n! nn 1n 2 n r 1 n Pr n r ! • Note: 0! is defined to 1, so n! n! n! n Pr n n ! 0! Mathematics and Statistics Permuntation & Combination 15 Example Find the number of ways of placing 3 of the letters A, B, C, D, E in 3 empty spaces. Mathematics and Statistics Permuntation & Combination 16 Solution • • • • • • The first space can be filled in 5 ways. The second space can be filled in 4 ways. The third space can be filled in 3 ways. Mathematics and Statistics Permuntation & Combination 17 • Therefore there are • 5 x 4 x 3 ways • of arranging 3 letters taken from 5 letters. • This is the number of permutations of 3 objects taken from 5 and • it is written as 5P3 • so 5P3 = 5 x 4 x 3 = 60. Mathematics and Statistics Permuntation & Combination 18 • On the other hand, 5 x 4 x 3 could be written as 5 4 3 2 1 5! 5! P5, 3 2 1 2! 5 3 ! • Notice that the order in which the letters are arranged is important --• ABC is a different permutation from ACB. Mathematics and Statistics Permuntation & Combination 19 Example • How many different ways are there to select • one chairman and • one vice chairman • from a class of 20 students. Mathematics and Statistics Permuntation & Combination 20 Solution • The answer is given by the number of 2-permutations of a set with 20 elements. • This is • Mathematics and Statistics 20P2 = 20 x 19 = 380 Permuntation & Combination 21 6.2.3 Combinations • An r-combination of elements of a set is an unordered selection of r elements from the set. • Thus, an r-combination is simply a subset of the set with r elements. Mathematics and Statistics Permuntation & Combination 22 • The number of r-combinations of a set with n elements, • where n is a positive integer and • r is an integer with 0 <= r <= n, • i.e. the number of combinations of r objects from n unlike objects is n! n Cr r! n r ! Mathematics and Statistics Permuntation & Combination 23 Example • How many different ways are there to select two class representatives from a class of 20 students? Mathematics and Statistics Permuntation & Combination 24 Solution • The answer is given by the number of 2-combinations of a set with 20 elements. • The number of such combinations is 20! 190 20C2 2! 18! Mathematics and Statistics Permuntation & Combination 25 Example • A committee of 5 members is chosen at random from • 6 faculty members of the mathematics department and • 8 faculty members of the computer science department. Mathematics and Statistics Permuntation & Combination 26 • In how many ways can the committee be chosen if • (a) there are no restrictions; • (b) there must be more faculty members of the computer science department than the faculty members of the mathematics department. Mathematics and Statistics Permuntation & Combination 27 Solution • (a) There are 14 members, from whom 5 are chosen. • The order in which they are chosen is not important. • So the number of ways of choosing the committee is • 14C5= 2002. Mathematics and Statistics Permuntation & Combination 28 • (b)If there are to be more • faculty members of the computer science department than • the faculty members of the mathematics department, • then the following conditions must be fulfilled. Mathematics and Statistics Permuntation & Combination 29 • (i) 5 faculty members of the computer science department. • The number of ways of choosing is • 8C5= 56. • (ii) 4 faculty members of the computer science department and • 1 faculty member of the mathematics department Mathematics and Statistics Permuntation & Combination 30 • • The number of ways of choosing is 8C4 x 6C1 = 70 x 6 = 420. • (iii) 3 faculty members of the computer science department and • 2 faculty members of the mathematics department • The number of ways of choosing is • 8C3 x 6C2 = 56 x 15 = 840 Mathematics and Statistics Permuntation & Combination 31 • Therefore the total number of ways of choosing the committee is • 56 + 420 + 840 = 1316. Mathematics and Statistics Permuntation & Combination 32