|
Pooh-Bah
Join Date: Sep 2006
Posts: 3,655
|
Re: Putting 6 rings on 4 fingers
This is a well known problem which states that there are C(n+r -1, r-1) distinct number of nonnegative integer valued vectors (x1,x2,...,xr) satisfying x1 + x2 + ... + xr = n with "disregard to order". The formula where order matters (your example) is n!*C(n+r-1,r-1).
Plugging in the numbers where n = 6 and r = 4 gives us 60,480
Lets work this out in cases:
n(6,0,0,0) = C(4,1)*P(6,6)
n(5,1,0,0) = C(4,2)*2*P(6,5)*P(1,1)
n(4,2,0,0) = C(4,2)*2*P(6,5)*P(1,1)
n(3,3,0,0) = C(4,2)*2*P(6,5)*P(1,1)
n(4,1,1,0) = C(4,3)*3*P(6,4)*P(2,1)*P(1,1)
n(3,2,1,0) = C(4,3)*6*P(6,3)*P(3,2)*P(1,1)
n(2,2,2,0) = C(4,3)*1*P(6,2)*P(4,2)*P(2,2)
n(3,1,1,1) = C(4,1)*P(6,3)*P(3,1)*P(2,1)*P(1,1)
n(2,2,1,1) = C(4,2)*P(6,2)*P(4,2)*P(2,1)*P(1,1)
Add everything up and we get 60,480
Also notice that when you multiple the P's out, you always get 6! = 720 which becomes a common factor in the total sum. I wrote out the necessary steps so that it's easier to understand.
Last edited by jay_shark; 08-29-2008 at 11:05 PM.
|