Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I am given 3 loaded dice $D_1$, $D_2$ and $D_3$ and their probability tables $P(D_i = k), 1 \leq k \leq 6$.

I ought to write an algorithm that computes $P(\text{Sum} \mid D_1)$, the sum of all three dice conditioned on the value of the first die.

My intuition lead to the following solution:

For each possible sum of two dice ($2,\ldots,12$) I collected the different possibilities of dice numbers in a table $T$, for instance for the sum $4$ it is $(1,3) (2,2) (3,1)$.

To compute now the probability $P(\text{Sum} = n\mid D_1 = v)$ I sum up the multiplications of $P(D_2 = x)$ and $P(D_3 = y)$ where $x$ and $y$ are taken from the table $T$ I have computed for the sum value $n - v$.

The final result is computed by multiplying this sum with $P(D_1 = v)$.

So why do I post this on Mathematics StackExchange? Here are my questions:

1. Is this approach correct after all?

2. This approach seems very unmathematical, is there a trick to replace one step by a formula? For instance I wondered whether I could use the formula

$$P(Sum|D_1) = \frac{P(D_1|Sum) \cdot P(Sum)}{P(D_1)}$$

But I didn't find that easier.

share|improve this question
1  
You have not stated conditions such as independent rolls for the three dice that you are using (or seem to be using) in your approach, but what you have done sounds close to correct. You correctly compute $P\{\text{sum} = n\mid D_1 = \nu\} = P\{D_2 + D_3 = n-\nu\}$ but there is no need to multiply the result by $P\{D_1 = \nu\}$. This last multiplication will give you the joint probability $P\{\text{sum}=n, D_1 = \nu\}$ rather than the conditional probability $P\{\text{sum} = n\mid D_1 = \nu\}$ –  Dilip Sarwate May 14 '12 at 12:16
    
@DilipSarwate Okay in $P(A|B)$ we take into account that $B$ has already happened, but it does not affect the probability of $A$ and joint probability means the probability that both occurs? For whether the rolls are independent or not I have no information, but they are probably independent of each other. –  Mahoni May 14 '12 at 12:25
2  
One die, two dice. –  Gerry Myerson May 14 '12 at 12:34
    
@GerryMyerson Thanks I correct that –  Mahoni May 14 '12 at 12:42
    
The title, too. –  Gerry Myerson May 14 '12 at 12:54

2 Answers 2

up vote 2 down vote accepted

The burden is reduced if one notes that, considering $S=D_1+D_2+D_3$, $$ \mathrm P(S=n\mid D_1=v)=\mathrm P(D_2+D_3=n-v\mid D_1=v)=\mathrm P(D_2+D_3=n-v), $$ since $D_1$ and $D_2+D_3$ are independent, and that, for every $2\leqslant k\leqslant12$, $$ \mathrm P(D_2+D_3=k)=\sum_{i=1}^{k-1}\mathrm P(D_2=i)\mathrm P(D_3=k-i). $$

share|improve this answer

Intuitively you can treat the question as though it is asking about the sum of the second and third dice (since you are given the value of the first die)

i.e.

$P(D_1+D_2+D_3=n | D_1=v) = P(D_2+D_3=n-v)$

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.