How Do You Calculate Dice Game Probabilities with Multiple Variables?

AI Thread Summary
The discussion focuses on calculating probabilities in a dice game involving multiple variables, specifically the number of red and blue dice and the desired scoring outcomes. A user seeks assistance in developing a formula to determine the probability of achieving a minimum number of successful scores based on the configuration of the dice. The conversation highlights the importance of breaking down the problem into disjoint cases to avoid double counting and emphasizes the use of combinatorial methods for accurate calculations. Additionally, suggestions for implementing the formula in software like Mathematica and Excel are provided. The thread concludes with a successful example calculation and a plan to adapt the solution for Excel use.
brebh
Messages
3
Reaction score
0
Hi!

I'm not very good with statistics and such but have been working on a problem for a month now and have finally gotten to a point where I'm ready to ask for help. I didn't really know where to go but found this forum and thought I'd give it a try here. =)

I'm working on a dice game and am looking to create a formula that I can use to plug in a few variables and have a probability of a certain result kicked back to me. Here's what I've got so far:

r = number of red dice in a single throw of all dice
b = number of blue dice in a single throw of all dice
pr = probability of "scoring a point" with a red die (1/6)
pb = probability of "scoring a point" with a blue die (3/6)
n = the minimum number of "points" desired in a single throw of all dice

To put some numbers to a sample situation... I've got 2 red dice and 1 blue die in a throw. I want to know the odds of at least 2 of the dice in the throw "scoring" (it's ok if all the dice are successful).

Rather than embarrass myself by showing you guys a formula that I know is clearly wrong, I will say that I think the result of the example I've provided should be 16.67%. I'm pretty sure that's accurate because I wrote out every combination and 36 of the 216 possible results score twice on 2 of the 3 dice.

Thanks in advance for any help and I apologize for being such a noob.
 
Physics news on Phys.org
A quicker way to calculate this
If 2 out of the 3 dice score, then:

Either 2 red dice scored, and the blue die didn't score: chance of this occurring is (1/6)2*1/2 (multiply the independent probabilities of each die doing what it does)

2 red dice score, and the blue die scores: (1/6)2*1/2

1 red die scores, the blue die scores

1/6*5/6*1/2*2 - multiply by 2 because there are two ways you can pick which red die scores

Add these up to get: 1/6 as you said

The principle is you break it up into disjoint cases (so no two cases occur at the same time), calculate the probability of each case occurring, then add them up at the end. Notice if your cases overlap, then you're essentially double counting the events that occur under both cases
 
Thanks!

That helps for sure.

Just wondering though, is it possible to build a formula that allows me to plug in any number of red dice (r), blue dice (b) and the minimum number of dice that score in a result (n) to get the probability of different situations?

Thanks again!
 
\sum_{x=0}^r\sum_{y=n-a}^b\binom rx\binom byp_r^xp_b^y(1-p_r)^{r-x}(1-p_b)^{b-y}=\sum_{x=0}^r\left(\binom rxp_r^x(1-p_r)^{r-x}\sum_{y=n-a}^b\binom byp_b^y(1-p_b)^{b-y}\right)

which with your probabilities is

\frac{1}{2^b6^r}\sum_{x=0}^r\left(\binom rx5^{r-x}\sum_{y=n-a}^b\binom by\right)

I'm sure this can be simplified further, but it's still going to be pretty ugly.

Edit: Mathematica can get it to a single sum, but it's hideous and probably harder to calculate for any values you'd care about:
\frac{1}{2^b6^r}\sum_{x=0}^r\left(\frac{5^{r-x}b!\,_2\!\tilde{\text{F}}_1(1,n-b-x; n-x+1; -1)}{(a+b-n)!}\right)

Edit 2: If you Google for and install Pari/GP, this will do it for you:
Code:
brebh(r,b,n)=sum(x=0,r,binomial(r,x)*5^(r-x)*sum(y=n-x,b,binomial(b,y)))/2^b/6^r
(15:32)brebh(2,1,2)
time = 0 ms.
%46 = 1/6
 
Last edited:
Holy crap!

I would have never figured that out. Thanks for the solution!

Now I need to start working on converting that into something excel can read. =)

Thanks again!
 
If you want to do this in Excel you'll either need to use a macro or to make a b by r grid and a calculation row beside it.
 
I was reading documentation about the soundness and completeness of logic formal systems. Consider the following $$\vdash_S \phi$$ where ##S## is the proof-system making part the formal system and ##\phi## is a wff (well formed formula) of the formal language. Note the blank on left of the turnstile symbol ##\vdash_S##, as far as I can tell it actually represents the empty set. So what does it mean ? I guess it actually means ##\phi## is a theorem of the formal system, i.e. there is a...
Back
Top