An archived instance of a Discrete forum

01 Binomial Coefficients: Problem 2

Eli

The question asks how many anagrams can be created from the word ‘accommodate’. I was wondering how would the process of getting the solution change if there was a letter in the word that was repeated 3 times instead of only twice.

mark

Good question!

First off, I guess your answer to the number of anagrams of ‘accommodate’ must be

\frac{11!}{2\cdot2\cdot2\cdot2} = 2494800.

The reasoning comes in a couple of parts:

  1. There are 11 letters in ‘accommodate’. If they were all distinct, we could simply consider the number of ways we can line them up in order to get 11!.
  2. Since the letters are not distinct, we must divide by the number of ways they can be permuted without changing the word. For example, we could swap the ‘a’ at the beginning with the ‘a’ near the end. Thus, accounting for only the ‘a’, our 11! overcounts by the factor 2. Of course, we could just as easily swap the ‘c’, the ‘o’, or the ‘m’; that’s where the 2\cdot2\cdot2\cdot2 comes from.

Now, if there were three occurrences of the same letter, we would have to divide by the number of permutations of three things - namely, 3!. For example, suppose we wanted to find the number of anagrams of BABB, which happens to be the name of a city adjacent to Glacier National Park in Northwest Montana. Since there’s one A and three Bs, the answer should be

\frac{4!}{3!} = 4.

In this particular example, it’s quite easy to list out all four anagrams:

  • ABBB
  • BABB
  • BBAB
  • BBBA

This example is also simple enough to illustrate why dividing by the number of permutations of works. Let’s start by writing down the 3! ways to order three Bs. We’ll distinguish the Bs by writing them as follows:

  • \textcolor{red}{\text{B}}: A red, capital B,
  • \textcolor{green}{\beta}: A green, Greek \beta, or
  • \textcolor{blue}{\cal{B}}: A blue, calligraphic {\cal B}.

With those distinctions, here are all the permutations of BBB:

\textcolor{red}{\text{B}} \textcolor{green}{\beta} \textcolor{blue}{\cal{B}}, \: \textcolor{red}{\text{B}} \textcolor{blue}{\cal{B}} \textcolor{green}{\beta}, \: \textcolor{green}{\beta} \textcolor{red}{\text{B}} \textcolor{blue}{\cal{B}}, \: \textcolor{green}{\beta} \textcolor{blue}{\cal{B}} \textcolor{red}{\text{B}}, \: \textcolor{blue}{\cal{B}} \textcolor{red}{\text{B}} \textcolor{green}{\beta}, \: \textcolor{blue}{\cal{B}} \textcolor{green}{\beta} \textcolor{red}{\text{B}}. \:

Now, for each of these You’ve got 4 choices where you might insert the A:

A first A second A third A fourth
First permutation A\textcolor{red}{\text{B}}\textcolor{green}{\beta}\textcolor{blue}{\cal{B}} \textcolor{red}{\text{B}}A\textcolor{green}{\beta}\textcolor{blue}{\cal{B}} \textcolor{red}{\text{B}}\textcolor{green}{\beta}A\textcolor{blue}{\cal{B}} \textcolor{red}{\text{B}}\textcolor{green}{\beta}\textcolor{blue}{\cal{B}}A
Second permutation A\textcolor{red}{\text{B}}\textcolor{blue}{\cal{B}}\textcolor{green}{\beta} \textcolor{red}{\text{B}}A\textcolor{blue}{\cal{B}}\textcolor{green}{\beta} \textcolor{red}{\text{B}}\textcolor{blue}{\cal{B}}A\textcolor{green}{\beta} \textcolor{red}{\text{B}}\textcolor{blue}{\cal{B}}\textcolor{green}{\beta}A
Third permutation A\textcolor{green}{\beta}\textcolor{red}{\text{B}}\textcolor{blue}{\cal{B}} \textcolor{green}{\beta}A\textcolor{red}{\text{B}}\textcolor{blue}{\cal{B}} \textcolor{green}{\beta}\textcolor{red}{\text{B}}A\textcolor{blue}{\cal{B}} \textcolor{green}{\beta}\textcolor{red}{\text{B}}\textcolor{blue}{\cal{B}}A
Fourth permutation A\textcolor{green}{\beta}\textcolor{blue}{\cal{B}}\textcolor{red}{\text{B}} \textcolor{green}{\beta}A\textcolor{blue}{\cal{B}}\textcolor{red}{\text{B}} \textcolor{green}{\beta}\textcolor{blue}{\cal{B}}A\textcolor{red}{\text{B}} \textcolor{green}{\beta}\textcolor{blue}{\cal{B}}\textcolor{red}{\text{B}}A
FIfth permutation A\textcolor{blue}{\cal{B}}\textcolor{red}{\text{B}}\textcolor{green}{\beta} \textcolor{blue}{\cal{B}}A\textcolor{red}{\text{B}}\textcolor{green}{\beta} \textcolor{blue}{\cal{B}}\textcolor{red}{\text{B}}A\textcolor{green}{\beta} \textcolor{blue}{\cal{B}}\textcolor{red}{\text{B}}\textcolor{green}{\beta}A
Sixth permutation A\textcolor{blue}{\cal{B}}\textcolor{green}{\beta}\textcolor{red}{\text{B}} \textcolor{blue}{\cal{B}}A\textcolor{green}{\beta}\textcolor{red}{\text{B}} \textcolor{blue}{\cal{B}}\textcolor{green}{\beta}A\textcolor{red}{\text{B}} \textcolor{blue}{\cal{B}}\textcolor{green}{\beta}\textcolor{red}{\text{B}}A

Now, since the original three Bs are really indistinguishable, this grouping shows why you divide the 24=4! strings shown in the table by 6=3! to get the anagrams of BABB.