Combinations and permutations

  • View

  • Download

Embed Size (px)

Text of Combinations and permutations

  • 1.Combinations and PermutationsWhats the Difference? In English we use the word "combination" loosely, without thinking if the order of things is important. In other words:"My fruit salad is a combination of apples, grapes andbananas" We dont care what order the fruits are in,they could also be "bananas, grapes and apples" or"grapes, apples and bananas", its the same fruit salad."The combination to the safe was 472". Now we docare about the order. "724" would not work, nor would"247". It has to be exactly 4-7-2.So, in Mathematics we use more precise language:If the order doesnt matter, it is a Combination.If the order does matter it is a Permutation.A Permutation is an ordered Combination.Permutation : Permutation means arrangement of things. Theword arrangement is used, if the order of things is considered.Combination: Combination means selection of things. The wordselection is used, when the order of things has no importance.Definition:Permutation:An arrangement is called a Permutation. It is therearrangement of objects or symbols into distinguishable sequences.When we set things in order, we say we have made an arrangement.When we change the order, we say we have changed the

2. arrangement. So each of the arrangement that can be made bytaking some or all of a number of things is known as Permutation.Combination:A Combination is a selection of some or all of a number ofdifferent objects. It is an un-ordered collection of unique sizes.In apermutation the order of occurence of the objects or thearrangement is important but in combination the order of occurenceof the objects is not important.Formula:Permutation = nPr = n! / (n-r)!Combination = nCr = nPr / r!where, n, r are non negative integers and 0 rn. r is the size of each permutation. n is the size of the set from which elements are permuted. ! is the factorial operator.Example: Suppose we have to form a number of consistingof three digits using the digits 1,2,3,4, To form this number thedigits have to be arranged. Different numbers will get formeddepending upon the order in which we arrange the digits. Thisis an example of Permutation.Now suppose that we have to make a team of 11 players out of20 players, This is an example of combination, because theorder of players in the team will not result in a change in theteam. No matter in which order we list out the players the teamwill remain the same! For a different team to be formed at leastone player will have to be changed.Now let us look at two fundamental principles of counting: 3. Addition rule : If an experiment can be performed in n ways, &another experiment can be performed in m ways then either ofthe two experiments can be performed in (m+n) ways. This rulecan be extended to any finite number of experiments.Example: Suppose there are 3 doors in a room, 2 on oneside and 1 on other side. A man wants to go out from the room.Obviously he has 3 options for it. He can come out by door Aor door B or door C.Multiplication Rule : If a work can be done in m ways, anotherwork can be done in n ways, then both of the operations canbe performed in m x n ways. It can be extended to any finitenumber of operations.Example.:Suppose a man wants to cross-out a room, whichhas 2 doors on one side and 1 door on other site. He has 2 x1 = 2 ways for it.Factorial n : The product of first n natural numbers is denotedby n!. n! = n(n-1) (n-2) ..3.2.1. Ex. 5! = 5 x 4 x 3 x 2 x 1 =120 Note0! = 1 4. Proof n! =n, (n-1)!Or (n-1)! = [n x (n-1)!]/n = n! /nPutting n = 1, we haveO! = 1!/1 = 1PermutationNumber of permutations of n different things taken r at a time is given by:- n Pr = n!/(n-r)!Proof:Say we have n different things a1, a2, an.Clearly the first place can be filled up in n ways. Number ofthings left after filling-up the first place = n-1So the second-place can be filled-up in (n-1) ways. Nownumber of things left after filling-up the first and secondplaces = n - 2Now the third place can be filled-up in (n-2) ways.Thus number of ways of filling-up first-place = nNumber of ways of filling-up second-place = n-1Number of ways of filling-up third-place = n-2Number of ways of filling-up r-th place = n (r-1) = n-r+1By multiplication rule of counting, total no. of ways of fillingup, first, second -- rth-place together :- 5. n (n-1) (n-2) ------------ (n-r+1) Hence:nPr= n (n-1)(n-2) --------------(n-r+1)= [n(n-1)(n-2)----------(n-r+1)] [(n-r)(n-r-1)-----3.2.1.] / [(n-r)(n-r-1)] ----3.2.1 n Pr = n!/(n-r)! Number of permutations of n different things taken all at atime is given by:-nPn=n!Proof :Now we have n objects, and n-places.Number of ways of filling-up first-place = nNumber of ways of filling-up second-place = n-1Number of ways of filling-up third-place = n-2Number of ways of filling-up r-th place, i.e. last place =1Number of ways of filling-up first, second, --- n th place= n (n-1) (n-2) ------ 2.1. n Pn = n!Concept. nWe havePr = n!/n-rPutting r = n, we have :- 6. n Pr = n! / (n-r) n But Pn = n!Clearly it is possible, only when n! = 1Hence it is proof that 0! = 1Note : Factorial of negative-number is not defined. Theexpression 3! has no meaning.ExamplesQ. How many different signals can be made by 5 flags from 8-flags of different colours?Ans.Number of ways taking 5 flags out of 8-flage = 8P5= 8!/(8-5)!= 8 x 7 x 6 x 5 x 4 = 6720Q. How many words can be made by using the letters of theword SIMPLETON taken all at a time?Ans. There are 9 different letters of the word SIMPLETONNumber of Permutations taking all the letters at a time = 9P9= 9!= 362880.Number of permutations of n-thing, taken all at a time, in which P are of one type, q of them are of second-type, r of them are of third-type, and rest are all different is given by :- n!/(p! x q! xr!) 7. Example: In how many ways can the letters of the word Pre-University be arranged?13!/(2! X 2! X 2!)Number of permutations of n-things, taken r at a time when each thing can be repeated r-times is given by = nr.Proof.Number of ways of filling-up first place = nSince repetition is allowed, so Number of ways of filling-up second-place = nNumber of ways of filling-up third-placeNumber of ways of filling-up r-th place = nHence total number of ways in which first, second ----r th, places can be filled-up= n x n x n ------------- r factors.= nrExample: John has 8 friends. In how many ways can he inviteone or more of them to dinner?Ans. John can select one or more than one of his 8 friends.=> Required number of ways = 28 1= 255. 8. (iv) Number of ways of selecting zero or more things from nidentical things is given by :- n+1Example:In how many ways, can zero or more letters beselected form the letters AAAAA?Ans. Number of ways of : Selecting zero As = 1 Selecting one As = 1 Selecting two As =1 Selecting three As = 1 Selecting four As = 1 Selecting five As= 1=> Required number of ways = 6[5+1](V) Number of ways of selecting one or more things from pidentical things of one type q identical things of anothertype, r identical things of the third type and n differentthings is given by :-(p+1) (q+1) (r+1)2n 1 9. Example:Find the number of different choices that can be made from 3 apples, 4 bananas and 5 mangoes, if at least one fruit is to be chosen.Ans:Number of ways of selecting apples = (3+1) = 4 ways.Number of ways of selecting bananas = (4+1) = 5 ways.Number of ways of selecting mangoes = (5+1) = 6 ways.Total number of ways of selecting fruits = 4 x 5 x 6But this includes, when no fruits i.e. zero fruits is selected=> Number of ways of selecting at least one fruit = (4x5x6) -1 = 119Note :- There was no fruit of a different type, hence here n=o=> 2n = 20=1(VI) Number of ways of selecting r things from n identical things is 1.Example: In how many ways 5 balls can be selected from 12 identical red balls?Ans. The balls are identical, total number of ways of selecting 5 balls = 1.Example: How many numbers of four digits can be formed with digits 1, 2, 3, 4 and 5? 10. Ans. Here n = 5 [Number of digits]And r = 4[ Number of places to be filled-up]5Required number isP4 = 5!/1! = 5 x 4 x 3 x 2 x 1Example: A child has 3 pocket and 4 coins. In how manyways can he put the coins in his pocket.Ans. First coin can be put in 3 ways, similarly second, third and forth coins also can be put in 3 ways.So total number of ways = 3 x 3 x 3 x 3 = 34 = 81So, we should really call this a "PermutationLock"! Permutations There are basically two types of permutation: 1. Repetition is Allowed: such as the lock above. It could be"333". 2. No Repetition: for example the first three people in a running race. You cant be first and second. 11. 1. Permutations with Repetition These are the easiest to calculate.When you have n things to choose from ... you have n choices each time!When choosing r of them, the permutations are: n n ... (r times) (In other words, there are n possibilities for the first choice, THENthere are n possibilites for the second choice, and so on, multplying each time.) Which is easier to write down using an exponent of r:n n ... (r times) = nr Example: in the lock above, there are 10 numbers to choose from (0,1,..9) and you choose 3 of them:10 10 ... (3 times) = 103 = 1,000 permutations So, the formula is simply:nr where n is the number ofthings to choose from, and you choose r of them(Repetition allowed, ordermatters) 12. 2. Permutations without RepetitionIn this case, you have to reduce the number of available choices eachtime.For example, what order could 16pool balls be in?After choosing, say, number "14"you cant choose it again.So, your first choice would have 16 possibilites, and your next choice would then have 15 possibilities, then 14, 13, etc. And the total permutations would be:16 15 14 13 ... = 20,922,789,888,000But maybe you dont want to choose them all, just 3 of them, so thatwould be only:16 15 14 = 3,360In other words, there are 3,360 different ways that 3 pool balls could be selected out of 16 balls. But how do we write that mathematically?