Bayes Theorem: coin flips and posterior predictive distribution

In summary, the probability of drawing a coin twice and getting heads the first time is approximately 46%.
  • #1
Master1022
611
117
Homework Statement
A bag has three coins in it which are visually indistinguishable, but when flipped, one coin has a 10% chance of coming up heads, another as a 30% chance of coming up heads, and the last has 60% chance of coming up heads. I randomly draw a coin from the bag and flip it, and the result comes up heads. What is the probability that if I reflip this coin, it will come up heads again? Why?
Relevant Equations
Bayes Theorem
Hi,

I was attempting the following question and just wanted to check whether my working was correct:

Question: A bag has three coins in it which are visually indistinguishable, but when flipped, one coin has a 10% chance of coming up heads, another as a 30% chance of coming up heads, and the last has 60% chance of coming up heads. I randomly draw a coin from the bag and flip it, and the result comes up heads. What is the probability that if I reflip this coin, it will come up heads again? Why?

Attempt:
Let us denote the coins A, B, and C with probabilities of getting a head as follows: ##p(H|A) = 0.1##, ##p(H|B) = 0.3##, and ##p(H|C) = 0##. Each coin is equally likely to be chosen: ##p(A) = p(B) = p(C) = \frac{1}{3} ##.

Thus, we can find:
$$ p(A|H) = \frac{p(H|A) p(A)}{p(H|A) p(A) + p(H|B) p(B) + p(H|C) p(C)} = \frac{0.1 \cdot \frac{1}{3}}{0.1 \cdot \frac{1}{3} + 0.3 \cdot \frac{1}{3} + 0.6 \cdot \frac{1}{3}} = 0.1 $$
$$ p(B|H) = \frac{p(H|B) p(B)}{p(H|A) p(A) + p(H|B) p(B) + p(H|C) p(C)} = \frac{0.3 \cdot \frac{1}{3}}{0.1 \cdot \frac{1}{3} + 0.3 \cdot \frac{1}{3} + 0.6 \cdot \frac{1}{3}} = 0.3 $$
$$ p(C|H) = \frac{p(H|C) p(C)}{p(H|A) p(A) + p(H|B) p(B) + p(H|C) p(C)} = \frac{0.6 \cdot \frac{1}{3}}{0.1 \cdot \frac{1}{3} + 0.3 \cdot \frac{1}{3} + 0.6 \cdot \frac{1}{3}} = 0.6 $$

So now we can find posterior probability:
$$ p(H|H) = p(H|A)p(A|H) + p(H|B)p(B|H) + p(H|C)p(C|H) = (0.1)^2 + (0.3)^2 + (0.6)^2 = 0.46 $$

Does this look correct?
 
  • Like
Likes PeroK
Physics news on Phys.org
  • #2
Looks good to me.
 
  • Like
Likes Master1022
  • #3
I know I always have alternatives, but using a probability tree is a really simple and neat way of doing these problems. Especially if they get more complicated, with more than one factor. In this case we would have:

C1 (1/3) - C1 Heads (1/3 * 1/10 = 1/30) - C1 Heads-Heads (1/300)

C2 (1/3) - C2 Heads (1/3 * 3/10 = 1/10) - C2 Heads-Heads (3/100)

C3 (1/3) - C3 Heads (1/3 * 6/10 = 1/5) - C3 Heads-Heads (12/100)

Heads on first toss (total) = 1/30 + 1/10 + 1/5 = 1/3; Heads on second toss = 46/300

Probability two-heads given first toss is a head = (46/300)/(1/3) = 46/100.
 
  • Informative
Likes Master1022
  • #4
PeroK said:
I know I always have alternatives, but using a probability tree is a really simple and neat way of doing these problems. Especially if they get more complicated, with more than one factor. In this case we would have:

C1 (1/3) - C1 Heads (1/3 * 1/10 = 1/30) - C1 Heads-Heads (1/300)

C2 (1/3) - C2 Heads (1/3 * 3/10 = 1/10) - C2 Heads-Heads (3/100)

C3 (1/3) - C3 Heads (1/3 * 6/10 = 1/5) - C3 Heads-Heads (12/100)

Heads on first toss (total) = 1/30 + 1/10 + 1/5 = 1/3; Heads on second toss = 46/300

Probability two-heads given first toss is a head = (46/300)/(1/3) = 46/100.
Thanks @PeroK ! Always great to see other ways to approach a problem; I tend to overcomplicate things. As they say, all roads lead to Rome (however, I guess there are some wrong roads in probability :) ).
 
  • #5
Master1022 said:
Thanks @PeroK ! Always great to see other ways to approach a problem; I tend to overcomplicate things. As they say, all roads lead to Rome (however, I guess there are some wrong roads in probability :) ).
Just to illustrate the point. Suppose we change the problem so that the three coins are in the proportions ##a_1, a_2, a_3##. You can see immediately how to update the tree structure - and it would only take a few seconds to get the new answer. Whereas, with the raw Bayes Theorem you'd have a bit of work to do.
 
  • Like
Likes Master1022

1. What is Bayes Theorem?

Bayes Theorem is a mathematical formula that describes the probability of an event based on prior knowledge or information. It allows us to update our beliefs about the likelihood of an event occurring as we gather new evidence.

2. How does Bayes Theorem apply to coin flips?

Bayes Theorem can be used to calculate the probability of getting a certain outcome in a series of coin flips. For example, if we know the prior probability of getting a heads or tails, and we flip the coin multiple times, Bayes Theorem can help us update our belief about the probability of getting a heads or tails based on the new evidence.

3. What is the posterior predictive distribution?

The posterior predictive distribution is the probability distribution for a future outcome, taking into account both prior knowledge and new evidence. In the context of coin flips, it can be used to predict the probability of getting a certain outcome in future flips based on the results of previous flips.

4. How can Bayes Theorem be used in real-life scenarios?

Bayes Theorem has various applications in real-life scenarios, such as in medical diagnosis, spam filtering, and weather forecasting. It allows us to make more accurate predictions and decisions by incorporating new evidence into our prior beliefs.

5. What are the limitations of Bayes Theorem?

One limitation of Bayes Theorem is that it assumes the prior and new evidence are independent of each other. This may not always be the case in real-life scenarios. Additionally, the accuracy of the predictions relies heavily on the accuracy of the prior knowledge and the quality of the new evidence.

Similar threads

  • Precalculus Mathematics Homework Help
Replies
18
Views
481
  • Precalculus Mathematics Homework Help
Replies
7
Views
1K
  • Precalculus Mathematics Homework Help
Replies
8
Views
913
  • Precalculus Mathematics Homework Help
Replies
2
Views
835
  • Precalculus Mathematics Homework Help
Replies
5
Views
3K
  • Precalculus Mathematics Homework Help
Replies
2
Views
1K
  • Precalculus Mathematics Homework Help
Replies
1
Views
1K
  • Precalculus Mathematics Homework Help
Replies
1
Views
1K
  • Precalculus Mathematics Homework Help
Replies
5
Views
1K
  • Precalculus Mathematics Homework Help
Replies
12
Views
2K
Back
Top