Probability to pick up biased coin

bayesianprobability

I have two identical looking coins, one is fair and has an equal chance of coming up heads or tails, but the other is weighted and will always land on heads. You pick one of the coins at random, toss it three times and get three heads. Given this, what is the chance that you've picked the weighted coin?

My way of solution is the following one.

With the fair coin, the probability that you get heads triple times is $1/8$.

With the biased coin, it is $1$.
What's the total probability that you get three heads on three tosses?
$1/8 + 1 = 9/8$

Now, assume you got your three heads. $\dfrac{\dfrac{1}{8}}{\dfrac{9}{8}} = 0.1111$ for fair coin and $0.888$ for biased one.

So the chance that I pick up biased coin is $0.888$.

Is my solution is correct?

Best Answer

Using Bayes rule.

$F$: denote the event you picked the fair coin

$B$: denote the event you picked the biased coin

$D$: Data collected, i.e., observed 3 heads in 3 tosses

We want to calculate: $P(F|D)$ and $P(B|D)$

Assume that the trials are independent. This is equivalent to saying: $P(D|F)=1/8$

$P(D|B)=1$

Let us also assume that $P(F)=P(B)=0.5$, implying that "you randomly pick coin" with equal chances of picking either one.

Apply Bayes theorem, which basically starts from:

$P(B|D)P(D)=P(D|B)P(B)$

Bring over the second term on the left hand side to the right hand side and expand by considering total probability as:

$P(D)=P(D|F)P(F)+P(D|B)P(B) = 1/8*1/2+1*1/2$

$P(B|D) = [P(D|B)P(B)]/[(P(D|F)P(F)+P(D|B)P(B))]$

I have got $\dfrac{8}{9}$ for biased coin.