Permutation is all about ordering objects in certain ways.

For an example, it is possible to order letters A B C D into 24 words. General form is n!. Since there are 4 distinct letters number of ways are 4! which is 24. But what if there are identical objects. For an example lets say we need to order following letters, A B B C D, note that there are 2 Bs.

Such situations are termed as “Permutations with Repetitions”.

Taking the above example of 5 letters, A B B C D. If the letters were distinct then there should be 5! ways of ordering them. But as it got 2 Bs the number of ways should get reduced, because it doesn’t really matter which B comes first and which B comes next. Both are identical. As a result we need to filter-out such occurrences.

In order to achieve the correct result, the total number of permutations which is 5! should be divided by the number of ways that the identical objects can be arranged. In this case it is 2Bs, 2!. So the answer is 5!/2!

### EXAMPLES

**Lets see how the word “R E F E R E N C E” can be written in different ways.**

Note that it has 9 letters. R is repeated twice, E is repeated four-times. Therefore if there were no identical letters then number of ways are 9!. But since there are 2 Rs and 4 Es, 9! should be divided by the number of ways that the identical letters can be arranges which is 2! for R and 4! for E. So the number of ways are 9! / (2! 4!) = 7560

**Lets see how following digits can be arranged 2, 2, 2, 7, 7, 8, 8, 8, 9**

There are three 2s, two 7s, three 8s and one 9. Again 9 digits therefore total number of ways are 9!, but it should be divided by the repeating digits. Therefore the total number of ways are 9!/(3! 2! 3!) = 5040

## Selecting and Arranging

Sometimes we need to order objects, first selecting them from a pool of objects and then arrange them in an order. Lets assume we are given 4 distinct letters and we need to group them and create two letter words. Then we have total number of ways of 4! / (4-2)! = 12

It can be termed as **nPr = n! / (n-r)!**, where the n is the pool size and the r is the number of objects that can be selected.

If there are identical objects them as we did early we need to divide the total number of ways from the number of ways that he identical objects can be arranged.

### EXAMPLE

**If the object pool is “A B B C C C D E”, how many ways are there to construct 4 letter words out of them?**

Since there are 8 letters in the pool and as we get 4 letters out of it, total number of arrangements are 8! / (8 – 4) ! = 1680

Then as there are identical objects, 2Bs and 3Cs, total number of ways 1680 / (2! 3!) = 140

In other words: 8 ! / {(8 -4)! * 2! * 3!} = 140

**If you are interested consider taking up following quizzes:**

Some worked-out examples

http://www.vitutor.com/statistics/combinatorics/permutations_repetition.html

Calculator

http://www.dcode.fr/permutations-with-repetitions