I am looking for a closed expression for calculating the number of combinations of $n = n_1 + n_2 + n_3$ objects arranged in an ordered list, where there are $n_1$ $a$, $n_2$ $b$ and $n_3$ $c$, under the constraint that $a$ may not appear adjacent to $a$, $b$ not adjacent to $b$, and $c$ not adjacent to $c$.
If $n_1 = n_2 = n_3$, the following is an upper bound on the number of combinations:
$3$ ways of picking the first, and $2$ ways of picking all subsequent objects gives
$$3 \cdot 2^{n-1}$$
A solution only exists if $n_1$ is not greater than $1+n_2+n_3$ and similarly for $n_2$ and $n_3$
Thanks to @Byron Schmuland for pointing me to a general answer; the integral that needs to be evaluated looks a bit daunting.
Now I need a solution to the integral for three items like the one listed on page 9 of the paper cited in the answer for two items.