Probability question - Bayes' Theorem biased coins

1.5k Views Asked by At

A bag contains 120 coins: 30 coins come up heads $40\%$ of the time (group a), 30 coins come up heads $20\%$ of the time (group b), and 60 coins have tails on both sides (group c).

I've calculated:

  1. I pick a coin at random, toss it, and it comes up tails. What is the probability that it is from group b? 0.2353
  2. I toss that same coin for the second time and it shows tails again. Now hat is the probability that it is from group b? 0.2215

The question I'm stuck on is: Flipping the same coin for the third time, now it comes up heads. What is the probability that is from group b? I calculated the answer to be 0.2953

This is my working

However, my professor has marked this wrong with the following working and answer:

Flipping the same coin for the third time. Now it comes up heads. What is the probability that is from group b?

P(Head | B) = 0.2

P(Tail) = 0.6 * 0.5 + 0.8 * 0.5 = 0.7

P(B | Tail) = 0.8 * 0.25 / 0.7 = 0.2887

P(Head) = 0.2*0.5 + 0.4 * 0.5 = 0.3

P(B | Tail, Tail) = P(Tail | B) / P(Tail) * P(Tail | B) = 0.8 / 0.7 * 0.2887 = 0.3299

P(B | Head, Tail, Tail) = P(Head | B) / P(Head) * P(B | Tail, Tail) = 0.2 / 0.3 * 0.3299 = 0.2199

I really don't understand how the answer is 0.2199? can someone explain this please? Thank you

1

There are 1 best solutions below

0
On BEST ANSWER

$$P(B|TTH) = \frac{P(TTH|B)P(B)}{P(TTH)}$$

$$ = \frac{P(TTH|B)P(B)}{P(TTH|A)P(A) + P(TTH|B)P(B) + P(TTH|C)P(C)}$$

Here $P(A)= P(B) = 1/4$, and $P(C) = 1/2$.

  • $P(TTH|A) = .8 \cdot .8 \cdot .2$
  • $P(TTH|B) = .6 \cdot .6 \cdot .4$
  • $P(TTH|C) = 0$

Substituting I get $P(B|TTH) = 0.470588$

And thus, of course $P(A|TTH) = 0.529412$ and $P(C|TTH) = 0$.


Your error was your denominator, i.e., your calculation of $P(TTH)$. Check that (conceptually), realizing the process: FIRST choose a coin, THEN flip it three times. You either chose an $A$ or a $B$ or a $C$ coin, and then were "stuck" with it for all the flippings. See?

The professor is simply confused. You never have to go through all those intermediate states (e.g., $TT$).