# Total probability law clarification

Suppose you roll a fair 6-sided dice three times. There are $6^3$ possible outcomes and each is equally likely.

Let $A_1$, $A_2$, $A_3$, $A_4$, $A_5$, and $A_6$ be the events that the last value is a $1$,$2$,$3$,$4$,$5$, and $6$ respectively. Let $B$ be the event that the first value is less or equal to the second value and the second value is less or equal to the third value.

What is $P(B)$?

The total probability law states that

$$P(B) = P(A_i)P(B|A_i)+....+P(A_n)P(B|A_n)$$

Let's assume that $x_i$ are values of $A_i\cap B$, then $$P(B|A_n) = \frac{x_i}{P(A_i)}$$

What I am getting confused at is that, if I substitute $P(B|A_n)$ in I'd get $$P(A_i)\frac{x_i}{P(A_i)} = x_i+...+x_n$$ which is just the addition of $x_i$'s.

I don't feel this is the correct way to simplify the total probability law. I am looking for some clarification.

• That formula is correct...All it says is that $P(B)=\sum P(B\cap A_i)$. As the $A_i$ are mutually exclusive and exhaustive that is certainly true. Not a bad way to do it! Fix the last entry and do the calculation. Another way might be to start with the number of triples with no duplicate...each has exactly one permutation which is in the desired order. Now suppose the triple has one duplicate and one different term. And then suppose all three match. – lulu Feb 7 '16 at 12:45
• Ok! Just to clarify @lulu. what do you mean by fixing the last entry? – user_123945839432 Feb 7 '16 at 12:51
• That's what $A_i$ does. Your (perfectly sensible) method says: count the $B$-cases by declaring that the last toss is $1$ and then counting those. Then declare the last toss is $2$ and count those. And so on. I'm writing up the other way to do it that I sketched in the comment. – lulu Feb 7 '16 at 12:52

To expand on the method I sketched in the comments:

There are $6^3=216$ possible ordered triples.

Consider first those triples with no duplicates. There are $\binom 63 = 20$ unordered such triples. As there are $3!=6$ permutations on three letters, there are $120$ ordered triples with no duplicates. Note that there is exactly one way to order such a triple that gives you a $B$ event, so this case gives us $20$ $B$-events and $120$ total triples.

Now suppose that there is one duplicate (and one different roll). There are $30$ unordered such rolls ($6$ possibilities for the duplicate, then $5$ for the other and $6\times 5=30$). There are $3$ ways to order such a triple, so we are looking at $90$ ordered rolls all in all. Again there is only one way to order such a triple that gives a $B$ event so this case gives us $30$ $B$-events and $90$ total triples.

Of course there are $6$ triples in which all three match. Ordering isn;t an issue and all are $B$ events.

Sanity check: Total number of rolls is $120+90+6=216$ as desired.

Probability: We have $20+30+6=56$ $B$-rolls out of $216$ total. Thus $$P(B)=\frac {56}{216}$$