# Number of combinations with limited repetition

1. Dec 12, 2013

### EmileMaras

Hello

I have the following combinatoric problem :
I want to distribute n (equivalent) atoms among M distinct objects. Each object can contain from 0 to nlim atoms. How many combination do I have for this system?

If nlim>n, this problem actually corresponds to the classical "Number of combinations with repetition". But in my case nlim<n. In fact, I am interested in the limit of (lnΩ)/n (Ω beeing the number of combination) when M and n tend toward infinity (with n=a M where a is a constant) while nlim is finite (and actually rather small)..

I found a solution for that problem using some series of summations but it will be impossible to caculate as soon as M and n become large (even for M=100, n=300 and nmax=10, it took my laptop more than one hour to solve it).
Is there a simple analytical solution to this problem?

Emile Maras

2. Dec 12, 2013

### ShayanJ

For the first atom,there is M choices...for the second,again M choices...for the third,again M choices...and so on!
So there is always M possible choices and all that we should do is to multiply the number of choices for each of the atoms which becomes $M^n$. But because the atoms are identical,we should decrease this amount by dividing it by $n!$.

3. Dec 12, 2013

### EmileMaras

I guess that it is not the correct answer. Maybe I did not state my problem properly, so I will just give an exemple.
Let's say I have n=3 atoms and M=3 object. An object can contain at max nmax=2 atoms. Then the possible combinations are 111, 012, 021, 102, 120, 201, 210 (where xyz gives the number of atom in each object) which corresponds to 7 combinations.

4. Dec 12, 2013

### ShayanJ

Yeah,my answer is wrong.It even gives a non-integral value!
Anyway,Check here!