Find the number of permutations of the 8 letters AABBCCDD, taken all at a time, such that no two adjacent letters are alike.

2.6k Views Asked by At

This appears to be an inclusion/exclusion problem. My first step was to find the total permutations with no restrictions, using $\frac{8!}{2!2!2!2!} = 2520$.

What would be the permutation formulas for all adjacent A's, B's, C's, and D's? Furthermore, how do I know what is added and subtracted?

2

There are 2 best solutions below

1
On

To count the cases where, say $AA$ and $CC$ (and possibly more) are adjacent, count the permutations of $\bar A,B,B,\bar C,D,D$ and imagine barred letters stand for double letters.

1
On

First lets find the total number of permutations without the given condition.

The total number of permutations are $N=\dfrac{8!}{2!2!2!2!}=2250$

Now, by applying the inclusion exclusion principle, a permutation has a property $\alpha$ in case $A's$ are adjacent, and $\beta$ for $B's$ and $\gamma$ for $C's$

$$N(\alpha)=\dfrac{7!}{2!2!2!}=630$$$$N(\alpha,\beta)=\dfrac{6!}{2!2!}=180$$$$N(\alpha,\beta,\gamma)=60$$$$N(\alpha,\beta,\gamma,\delta)=24$$ Therefore,$$N-4N(\alpha)+6N(\alpha,\beta)-4N(\alpha,\beta,\gamma)+N(\alpha,\beta,\gamma,\delta)=864$$