Another Math Question

There seems to be some pretty bright people here, and since neither me nor anyone I know can figure this out perhaps someone here can.

Q: In how many ways can 5 dice produce a total of 20?

At first I thought I could use the formula r + n - 1 choose r that pertains to integer combinations of the form x1 + x2 + x3+…+xn = r, but I realized that doesn’t account for the limitation that we always have 5 elements, so for instance that formula would count 19 + 1 = 20 as one possibility, but with 5 dice that’s not a valid roll. I’m more interested in the process involved as opposed to the actual answer if that matters at all.

You could make the sample space. simply write out all the possibilities and add up the ones that work. Also you could go with picking the first number and then do second and so on and figure out the ways to add up to 20. ex. 1,2,5,6,6. sorry for the brute force approach. I’ll try to grab another more elegant formula for you kinda running on fumes right now.

Yeah I started doing that, then I realized there would be a huge number, and on the exam coming up this Saturday that probably wouldn’t yield me many marks lol.

[quote]JLu wrote:
and on the exam coming up this Saturday that probably wouldn’t yield me many marks lol.[/quote]

gotta hate when that happens…

Well, 5 dice give 252 different combinations – (n+5)!/(n!5!) gives total different combinations, where n= number of dice – now I just have to figure a formula to find out how many are or aren’t 20.

Of course, I could be going about this the entirely wrong way. I’m a little rusty with these things.

damn i fucking hate math!!!

[quote]malonetd wrote:
now I just have to figure a formula to find out how many are or aren’t 20.

[/quote]

No shit! That’s the whole point of this problem. I’m retarded sometimes.

This fellow seems to explain it (have to admit, I only glanced and did not take the time to absorb):

Yeah he does a good job but you are left still doing some work. I’m toying with it but can’t get another way to get it directly

I wrote a really long reply but it was somewhat off point.
Basically take into account permutations and not combinations. Permutations means the order matters, where combination it does not.
Since what the value of the first few die will dictate what acceptable values remain for the other die.
That must be taken into account.
So you can have either
212
122
221

Same combination but different permutation.
This is alot of work though and you should ask your teacher. Even if the exam is saturday, he will be impressed with questions.
I like how at the end of the article Bill Roberts posted it says " Now if you really want a challenge here is one to try. How many ways are there to roll a total of 15 with 5 dice? You should get an answer of 651."

And we’re looking for total ways to roll 20 with 5 dice.
Holy fuck.
Good luck.

[quote]legendaryblaze wrote:
I like how at the end of the article Bill Roberts posted it says " Now if you really want a challenge here is one to try. How many ways are there to roll a total of 15 with 5 dice? You should get an answer of 651."

And we’re looking for total ways to roll 20 with 5 dice.
[/quote]

Let me preface by saying, I may be totally off base here. This just popped in my head and I haven’t really worked it out yet.

But, if there are 651 different ways to roll 15 with 5 dice, I think there would also be 651 for 20 with 5 dice. My thinking here is that if you chart the combinations to make 20, your “base” (for lack of a better term) will be 44444, or a set of five fours, and every permutation “above it”.

The opposite would be 33333, a set of five threes and every permutation below it, which the guy in the article calculated to be 651.

What I mean by “above” and “below” is, if you take the guy’s charting idea from the article, you start with the 6 as the first die and chart the dice in descending order to make the desired total. For example, the first few combinations of 20 would be:

6 6 6 1 1
6 6 5 2 1
6 6 4 3 1
6 6 4 2 2
etc, etc until you reach 4 4 4 4 4

Now I believe, and this is where I’m just guessing, that you come out with the same amount of combinations and permeations for a total of 15.

isnt there a formula for figuring out probability that involves multiplying all the numbers in linear form?

i took a math course last semester that focused on weird stuff like that and i remember we did something along those lines, i think we only worked on it like one morning so of course i dont remember any of it now.

You want the number of positive integer solutions to the equation

x1 + x2 + x3 + x4 + x5 = 20

subject to the constraints:

xi <= 6 for i = 1, 2, … , 5.

The number of positive integer solutions to the equation

x1 + x2 + x3 + x4 + x5 = 20

is C(19,4).

You have to use the Inclusion/Exclusion Principle to weed out the solutions you don’t want to finish off the original problem. I’ll try to put up a more detailed solution tomorrow if you still need it.

To add to my post above, the totals “20” and “15” both have the same number of combinations – 18. (Unless I’m completely fucking this up, which very well could be possible)

Here’s what I got for combinations of 20:

6 6 6 1 1
6 6 5 2 1
6 6 4 3 1
6 6 4 2 2
6 6 3 3 2
6 5 5 3 1
6 5 5 2 2
6 5 4 4 1
6 5 4 3 2
6 5 3 3 3
6 4 4 4 2
6 4 4 3 3
5 5 5 4 1
5 5 5 3 2
5 5 4 4 2
5 5 4 3 3
5 4 4 4 3
4 4 4 4 4

and here’s 15:

6 6 1 1 1
6 5 2 1 1
6 4 3 1 1
6 4 2 2 1
6 3 3 2 1
6 3 2 2 2
6 2 2 2 2
5 5 3 1 1
5 5 2 2 1
5 4 4 1 1
5 4 3 2 1
5 3 3 3 1
5 3 3 2 2
4 4 4 2 1
4 4 3 3 1
4 4 3 2 2
4 3 3 3 2
3 3 3 3 3

However, after typing this, I still don’t know how turn this into 651. And I still don’t see any way to make a formula out of it.

Why can’t the first die (for example) roll to a value of 1, 2, or 3 as part of a total of 20?

[quote]Bill Roberts wrote:
Why can’t the first die (for example) roll to a value of 1, 2, or 3 as part of a total of 20?[/quote]

It can, but every possible combination – not permutation – is already covered by the time you work your way down to 4 4 4 4 4

I should have thought longer before posting.

What you provided above was not what I thought it was intended to be – all the ways the individual dice could combine to 20, listed for each die – but rather as you say the possible combinations, with which one you figure how many ways each combination can be achieved, there you are.

I spent a few minutes doing what malonetd did (except I missed one of them, dang!). There are 18 different “ways” that 5 dice can add up to 20. But isn’t this basically the answer? Maybe? Permutations of each would not look “different”, presumably the dice look identical and we’re not tracking them.

It doesn’t tell you the probability, for that you’d need to find the permutations for each of the 18 patterns and add them up, then divide by 6^5, I guess.

[quote]malonetd wrote:
To add to my post above, the totals “20” and “15” both have the same number of combinations – 18. (Unless I’m completely fucking this up, which very well could be possible)

Here’s what I got for combinations of 20:

6 6 6 1 1
6 6 5 2 1
6 6 4 3 1
6 6 4 2 2
6 6 3 3 2
6 5 5 3 1
6 5 5 2 2
6 5 4 4 1
6 5 4 3 2
6 5 3 3 3
6 4 4 4 2
6 4 4 3 3
5 5 5 4 1
5 5 5 3 2
5 5 4 4 2
5 5 4 3 3
5 4 4 4 3
4 4 4 4 4

[/quote]

[quote]MarkT wrote:
I spent a few minutes doing what malonetd did (except I missed one of them, dang!). There are 18 different “ways” that 5 dice can add up to 20. But isn’t this basically the answer? Maybe? Permutations of each would not look “different”, presumably the dice look identical and we’re not tracking them.

It doesn’t tell you the probability, for that you’d need to find the permutations for each of the 18 patterns and add them up, then divide by 6^5, I guess.

malonetd wrote:
To add to my post above, the totals “20” and “15” both have the same number of combinations – 18. (Unless I’m completely fucking this up, which very well could be possible)

Here’s what I got for combinations of 20:

6 6 6 1 1
6 6 5 2 1
6 6 4 3 1
6 6 4 2 2
6 6 3 3 2
6 5 5 3 1
6 5 5 2 2
6 5 4 4 1
6 5 4 3 2
6 5 3 3 3
6 4 4 4 2
6 4 4 3 3
5 5 5 4 1
5 5 5 3 2
5 5 4 4 2
5 5 4 3 3
5 4 4 4 3
4 4 4 4 4

[/quote]

I found an interesting link.

5 means the number of dice and 6 is how many faces the dice have.
So props to malonetd. He is right.
There are 651 possible (permutations) ways for 5 dice to get 20 as an answer.
However to get the answer you can either do it his way or find as many combinations (as done by malonetd) and then find the possible permutations of.

For 66611 there are 8 different possible rearrangments (permutations).
Doing this for each combination, and then add them together and this will give you the value of 651.
Mathematically, you do what malonetd did to find the combinations and then for the permutations…i’m still trying to work it out.
The problem with the formulas given is they don’t take into account that you want to keep 3 of something and then 2 of something else.
You need to mix combination and permutation formulas.

[quote]MarkT wrote:
Permutations of each would not look “different”, presumably the dice look identical and we’re not tracking them.

[/quote]

I don’t know exactly what the original poster is looking for, but the permutations would look different if the dice were each a different color.