Number of ways to arrange 12 distinguishable balls with restrictions There are $9$ red balls and $3$ yellows. All $12$ are distinguishable. How many ways to put them in a circle such that between every two consecutive yellow balls, there are at least two red balls.
My work:
It's easy to see that only $(3,3,3),(4,3,2),(5,2,2)$. So the answer is $9!\times 3!\left(\frac{1}{3} + 1 + 1\right)$.
is it right?
 A: First, let me explain your mistake. There are not three ways to break up the red balls, there are four ways. They are:
$$
(3,3,3), \qquad (5,2,2),\qquad (4,3,2),\qquad (4,2,3)
$$
With this change, your method becomes $9!\times 3!\times (\frac13+1+1+1)$, which agrees with your book.
You need to count $(4,3,2)$ and $(4,2,3)$ separately, since they are rotationally distinct.

The following reasoning confirms your book's answer.

*

*Choose a linear ordering of the yellow balls [$3!$ ways].


*Choose a linear ordering of red balls [$9!$ ways].


*Break the red line into three contiguous groups whose sizes are all at least $2$. There are [$10$ ways] to do this part: you can have

*

*$(3,3,3)$ [$1$ way],

*any rotation of $(5,2,2)$ [$3$ ways],

*any permutation of $(4,3,2)$ [$6$ ways].



*Interleave the yellow balls with the red groups, producing an arrangment like $$y_1\;R_1\;y_2\;R_2\;y_3\;R_3$$ There is no choice here, it can be done in [$1$ way].


*We know have a linear arrangement of red and yellow balls. The number of circular arrangements is the number of linear arrangements, divided by $3$. This is because  the following three linear arrangements all produce the same circular arrangement:
$$
y_1\;R_1\;y_2\;R_2\;y_3\;R_3,\qquad 
y_2\;R_2\;y_3\;R_3\;y_1\;R_1,\qquad 
y_3\;R_3\;y_1\;R_1\;y_2\;R_2\;
$$
Putting this altogether, the answer is
$$
3!\times 9! \times 10\times \frac13
$$
which is indeed equal to $9!\times 5!/3!$.
A: Let's create three orange balls, each consisting of a yellow ball with two red balls glued to it in the clockwise direction.  There are $\frac{9!}{3!}$ ways to create the three orange balls.  Now we have three red balls and three orange balls, with no constraints on how we arrange them.
By rotating if necessary, let's arbitrarily assign one specific ball to the top of the circle.  There are $5!$ ways to arrange the remaining balls.  Thus, assuming that rotations are indistinguishable, the answer is $\frac {9!5!}{3!}= 20 \cdot 9!$.  If rotations are distinguishable, the answer is $\frac{9!6!}{3!}=120 \cdot 9!$.
A: Let me put one yellow ball $(Y_1)$ at the head of the circle, two red balls on either side, and "straighten" the circle for easier depiction. So we have
$Y_1RR-------RRY_1$
Remove two red balls temporarily
$Y_1RR-----RRY_1$
so we have $2$ yellow and $3$ red balls to place in $\binom52 = 10$ combos, $20$ arrangements with the yellows labelled.
Insert back  the two reds immediately to the right of the first yellow in the line.
Finally, permuting  the reds, we get
ans = $9!\times 20$
