Number of combinations colouring 10 eggs with 4 colours if one or 2 colours can be used at the same time

coloringcombinatorics

I started to solve this question and realised, that if I just add up all the possibilities, it is going to take a lot of time:
Here is the complete question from the textbook:

Eggs that are all of the same size and shape are painted for Easter, and we are interested in how many eggs have which colour combination. Suppose each egg is painted with either a single colour or with two different colours. Compute the number of possibilities to:

a) Paint ten eggs if four colours are available,

b) Paint four eggs if ten colours are available.

I have started this way: all the eggs can be coloured in one colour,
all the eggs can be coloured in two colours, 3 and 4. After that: all the eggs can be coloured in 2 colours and so on. But that seems to get a long journey. Is there any faster possibility solving this problem?
I think, that those 2 problems are related. So solving the first is crucial for the second.

Thanks a lot.

Best Answer

If there are $c$ actual colors available there are $c_*:=c+{c\choose2}$ distinguishable ways to color an egg with one or two colors. Given $n$ eggs we then have to find the number of nonnegative integer $c_*$-tuples $\bigl(x_k\bigr)_{1\leq k\leq c_*}$ satisfying $$x_1+x_2+\ldots+ x_{c_*}=n\ .$$ This is a stars and bars problem.