[Math] Number of ways to form a 3-letter word with repetition allowed

combinatorics

The additional rule is: no letter can be used more often than it appears in MILLENNIUM? (Which is pretty logical I guess)

MILLENNIUM = MM, II, LL, NN, E, U

My logic:

Case 1: Double letters + 1 distinct letters (choose pair from M, I, L, N + 1 from E, U)

$$\dbinom{4}{1} \dbinom{2}{1} \frac{3!}{2!} = 24$$

Case 2: All 3 distinct letters (permute 3 from M,I,L,E,N,U)

$$_6P_3 = 120$$

Sum = 24 + 120 = 144

Part (b): What about a four-letter word?

My logic:

Case 1: Double letters + Double letters (choose two from M, I, L, N)

$$\dbinom{4}{2} \frac{4!}{2! 2!} = 36$$

Case 2: Double letters + 2 distinct letters (choose 1 from M, I, L, N)

$$\dbinom{4}{1} \frac{4!}{2!} = 48$$

Case 3: All 4 distinct letters (permute 4 from M,I,L,E,N,U)

$$_6P_4 = 360$$

Sum = 36+48+360 = 444

However my answer is incorrect for both. Is there a mistake I made somewhere?

Best Answer

For both parts, the problem is with case 2 with one double letter: The letters MM, II, LL, NN are being prevented from being used as a single.

As B.A. noted in the comments Part a) Case 2 should be

$$\displaystyle\binom{4}{1}\binom{5}{1}\dfrac{3!}{2!},$$

and Part b) Case 2 should be:

$$\displaystyle\binom{4}{1}\binom{5}{2}\dfrac{4!}{2!}$$