I have a faint idea that the question can be solved in the same manner as finding out the number of solutions to the equation - x + y + z + w = some number.....

The fundamental idea beneath both the questions is the same...

Logic tells that if you multiply out
[tex](1+x+x^2+x^3+\dotsb)(1+x+x^2+x^3+\dotsb)(1+x+x^2+x^3+\dotsb)(1+x+x^2+x^3+\dotsb)=\frac{1}{(1-x)^4}=1+4x+\dotsb+220x^9+\dotsb[/tex]
then the coefficient of x^9 is the answer to how many ways for
a+b+c+d=9 are possible (a,b,c,d are the powers picked out of each bracket and whenever they add up to 9, these terms contribute to the x^9 term).

I suppose one could find some "closed form expression" for that involving a complicating sum over a product of binomials, but that isn't much better than just using wolfram.

I have come up with an explanation. Can someone help me out in polishing this? Just wondering, because people roundh ere have far more composed solutions than the one that I have posted below.

I find it hard to follow the way you describe it. I can make a short try and you can combine it.

The problem is equivalent to find all possible ways to add for integers (determining the number of balls for each of the four colours) and get nine: a+b+c+d=9
To calculate the number of combinations, let us consider the following polynomial product. Later we will see that each braket corresponds to one colour of ball and the powers of the dummy variable x are the number of this ball colour taken.
When you multiply out the brakets completely then you get all possible combinations of four factors where each factor is from one braket. Let us call the powers of one such four factor combination a, b, c and d. Whenever these four factors yield x^9, i.e. a+b+c+d=9, you get a x^9 term in the total product. In the end you'd have to add up all x^9 terms (it will be 220 of these) ending up with a final expression 1+4x+...+220x^9+...
Thus, by solving the algebraic multiplication of polynomials, which a computer algebra system can do for you, you have found the number of ways of expression 9 as a sum of four integers.

My explanation is mathematical and boring. It should only serve as a guide to which information to present. Your's is more "classroom", but I find there are steps missing and there are some confusing remarks. That's why you can try to combine these ;)
Of course also an example would be useful, like doing the full multiplication for a smaller problem. Like having 3 times the numbers 1 to 3 only and counting powers in the end again.

Hard to say. Maybe you can go through my explanation sentence by sentence and write down the keywords and key statement I make. I was trying to be as concise as possible so each sentence could contain like 3 important informations. Then you could interweave these ideas into your text.

Good to know. Had not heard that before :)

One little advantage of the polynomials is that they easily generalize to arbitrary contraints and problems.

I mean say you want to pick one number out of each of the sets
{1,3,5} {2,3,5} {1,2,3} and their sum should be 5
(for example you could have funny dice)

This can be "solved" with polynomials by finding
[tex](1+x^3+x^4)(x^2+x^3+x^5)(x+x^2+x^3)=\dotsb+Ax^5+\dotsb[/tex]

For less random number sets one might be able to find a closed form expression for the final answer.

Thread moved to Homework & Coursework area. This covers any text-book style question, even if it is for independent study and not an actual school assignment.

Thanks. I was trying to close that knowledge gap. I think I memorized these forumlas by logic and forgot that there was another case which requires more thinking.

Hello!
Hey everyone, I find this thread very interesting, but I am having trouble follwing the idea. I hope someone will be kind enough to expound the reasoning for me.
I figure the answer would simply be 4^{9}, as there are four ways to choose the first colour, four the second, and so forth. This is clearly not the case, but I am having difficult understanding why.
A comprehensive explanation is not necessary, but any pointers would be helpful.
Many thanks,
Nobahar.

Short pointer: order doesn't matter.
Longer pointer: blue, blue, green, red, ..., red is to be considered the same as blue, green, blue, red, ..., red. In mathematical language, we're considering multisets.

You can pick the 9 balls as follows: a blue ones, b green ones, c red ones, d white ones.
The question is, how many different pairs (a,b,c,d) are there such that a+b+c+d=9.