Im solving this problem in two ways but i don't know which is correct, because they give different results.
First Way
- I calculate the number of hands for the 4 possible forms of accepting hands:
- (aaa - bbb - c) : $\binom{13}{2} \binom{4}{3}^2~\binom{11}{1} \binom{4}{1} $
- (aaa - bb - cc) : $\binom{13}{1} \binom{4}{3}~\binom{12}{2} \binom{4}{2}^2 $
- (aaa - bb - c - d): $\binom{13}{1} \binom{4}{3} ~\binom{12}{1} \binom{4}{2} ~\binom{11}{2} \binom{4}{1}^2$
- (aaa - b - c - d - e): $\binom{13}{1} \binom{4}{3} ~\binom{12}{4} \binom{4}{1}^4$
- Add all of them and I get: $\left| A \right| = 10062624$
Second Way
I calculate all the unordered seven card hands of the form {aaa - ****}:
$\left| A_1 \right| = \binom{13}{1} \binom{4}{3} \binom{48}{4}$
Choose 1 from the 13 ranks, choose 3 from 4 of the cards in that rank and then choose 4 of the 48 remaining cards.
I calculate all the unordered seven card hands of the form {aaa - bbbb}:
$\left| A_2 \right| = \binom{13}{1} \binom{4}{3} \binom{12}{1} \binom{4}{4}$
Choose 1 from the 13 ranks, choose 3 from 4 of the cards in that rank, choose 1 from the 12 remaining ranks and then choose 4 of the 4 cards in that rank.
And then I subtract $\left| A_2 \right|$ from $\left| A_1 \right|$ and I get: $\left| A_2 \right| - \left| A_1 \right| = 10117536$
It seems that when using the second method, I might be counting the (aaa - bbb - c) sequence in 7-card hands twice, because when I subtract it from the total count, I end up with the same result as the first method. Can someone explain why this is happening?
As you noticed : $10117536 - \underbrace{\binom{13}2\binom 4 3^2\binom {11}1\binom 41}_{\large 54912} =10062624$
So indeed your second method was overcounted the pattern aaa-bbb-c .
Why? After selecting a triple of one rank, $\big(\binom{12*4}{4}-\binom{12}1\binom 44\big)$ tries to count selection of 4 cards from the remaining ranks that are not all the same rank, but this includes the possibility of selecting a second triple. Thus overcounting like so:
$\therefore$ You do need to discount having that second triple.