How to Calculate Probability of Getting Exactly 7 Heads?

In summary: P{have a 0.4-coin|first toss = H}; and the denominator is P{first = H & have a 0.4-coin}/P{first toss = H}...or are you trying to do everything at once?P{have a 0.4-coin|first toss = H}; and the denominator is P{first = H & have a 0.4-coin}/P{first toss = H}...or are you trying to do everything at once?
  • #1
CAF123
Gold Member
2,948
88

Homework Statement


I flip a coin 10 times and want to know the probability of getting exactly 7 heads given that the first flip is heads.

The Attempt at a Solution



The question above is part of a larger question involving the binomial RV, but I am only needing assistance here.

Using Bayes's Formula I get to the stage where I need to compute P(first one is heads| 7 heads out of 10 flips).

So what I said was there is 10 choose 7 different rearrangements of 7 heads out of 10 flips. (So this is the reduced sample space). Then I considered how many ways to get 7 heads out of 10 flips given that the first is a head. This implies there is one choice for the first flip and another 9 choose 6 ways to still attain 7 heads out of 10 flips. Therefore the probability I want is 1 x (9 choose 6)/(10 choose 7). I believe this is correct.

Someone else said this was equal to 7 x (9!)/(10!). I don't quite sure where this comes from. I think the 10! comes from the fact that you can rearrange the 10 flip outcomes 10! ways = |s|. Then if you glue the first head (flip 1) in place, then there are 9! different ways to rearrange the other flips. I don't see why this is multiplied by 7. If you consider another head out of the 7 heads, then you can't rearrange the other 9 members randomly since the first flip is fixed to be heads.
What have I missed?

Also how would I compute P(first one is heads and(intersect) we have 7 heads out of 10 flips) if I appealed to the definition of cond. prob explicitly?

thanks.
 
Physics news on Phys.org
  • #2
I don't see why you are invoking Bayes theorem. Given that the first one is heads, what you need is the probability of getting 6 heads in the remaining 9 tosses. Isn't the number of successes in 9 tosses a binomial distribution B(9, 1/2)?
 
  • #3
Sorry, I probably should have posted the whole question. we have 2 coins, one lands heads with prob 0.4 and the other 0.7. I randomly pick one of these coins and flip it 10 times.
a) What is the prob of 7 heads out of 10 flips? (got this)
b) What is the conditional prob of 7 heads out of 10 flips given the first one is heads?

P( 7 heads| first coin head) = P(first one heads| 7 heads) P(7 heads)/P(first one heads)
I have computed everything apart from P(first one heads|7heads). I have an answer as detailed by my previous post, but I would like to understand the alternate method.(as also detailed in my last post).
Many thanks.
 
  • #4
CAF123 said:
Sorry, I probably should have posted the whole question. we have 2 coins, one lands heads with prob 0.4 and the other 0.7. I randomly pick one of these coins and flip it 10 times.
a) What is the prob of 7 heads out of 10 flips? (got this)
b) What is the conditional prob of 7 heads out of 10 flips given the first one is heads?

P( 7 heads| first coin head) = P(first one heads| 7 heads) P(7 heads)/P(first one heads)
I have computed everything apart from P(first one heads|7heads). I have an answer as detailed by my previous post, but I would like to understand the alternate method.(as also detailed in my last post).
Many thanks.

For (a), did you get P{H = 7} = (1/2)*Bin(H=7|n=10, p=0.4)+(1/2)*Bin(H=7|n=10,p=0.7)? Here, the coefficients 1/2 and 1/2 are prior probabilities of the two coin types.

Let p = P{have a 0.4-coin|first toss = H}; this equals
P{first = H & have a 0.4-coin}/P{first toss = H}.
Can you work out the numerator? Can you work out the denominator? Now, if you know p, what should you do next?

RGV
 
  • #5
Hi RGV,
The denominator would be (1/2)(0.4) + (1/2)(0.7) = P(first =H)
As I said in my first post, I really seem to struggle with intersection and so I turn to Bayes's formula. Could you show me how to compute the intersection, P(first= H and have a 0.4 coin)?

After this presumably I compute the same for the 0.7 prob coin? And then add the results together?
 
  • #6
Am I along the right lines?
 
  • #7
CAF123 said:
Sorry, I probably should have posted the whole question. we have 2 coins, one lands heads with prob 0.4 and the other 0.7. I randomly pick one of these coins and flip it 10 times.
a) What is the prob of 7 heads out of 10 flips? (got this)
And I presume you got [itex]\begin{pmatrix}10 \\ 7\end{pmatrix}(0.5)^{10}[/itex].

b) What is the conditional prob of 7 heads out of 10 flips given the first one is heads?
As LCKurtz told you this is precisely the probability of getting 6 heads in the last 9 flips- it is [itex]\begin{pmatrix}9 \\ 6\end{pmatrix}(0.5)^9[/itex].

Are you interpreting "conditional probability" to mean that you are required to us Baye's formula? This is a "conditional probability" simply because it says "given that ...". That has nothing to do with how you are to calculate it.

If you want to see the connection between the two methods, observe that the conditional probability is just the original probability of 7 heads in 10 flips divided by (10/7)(0.5).
P( 7 heads| first coin head) = P(first one heads| 7 heads) P(7 heads)/P(first one heads)
I have computed everything apart from P(first one heads|7heads). I have an answer as detailed by my previous post, but I would like to understand the alternate method.(as also detailed in my last post).
Many thanks.
 
  • #8
HallsofIvy said:
And I presume you got [itex]\begin{pmatrix}10 \\ 7\end{pmatrix}(0.5)^{10}[/itex].


As LCKurtz told you this is precisely the probability of getting 6 heads in the last 9 flips- it is [itex]\begin{pmatrix}9 \\ 6\end{pmatrix}(0.5)^9[/itex].

Are you interpreting "conditional probability" to mean that you are required to us Baye's formula? This is a "conditional probability" simply because it says "given that ...". That has nothing to do with how you are to calculate it.

If you want to see the connection between the two methods, observe that the conditional probability is just the original probability of 7 heads in 10 flips divided by (10/7)(0.5).

The quantities
[tex] {10 \choose 7}(0.50)^{10} = 0.1171875 \;\text{ and } {9 \choose 6} (0.5)^9[/tex] are not correct in this problem. In the first case, the probability of 7 heads is
[tex] P\{ 7\, H\} = (1/2){10 \choose 7} (0.4)^7 (0.6)^3
+ (1/2) {10 \choose 7} (0.7)^7 (0.3)^3 = 0.15464763,[/tex]
because there is a 50-50 chance of having chosen either a 0.4-coin or a 0.7-coin, and the binomial probabilities go along with the coin type. The second case is similar, but we need to use the revised probabilities of the two coin types (after observing that the first toss is heads).

RGV
 
Last edited:
  • #9
Hi RGV,
I have done everything except i have difficulty in finding P(first one heads and have 0.4 coin). (As you advised me to calculate before). If these two events were independent, then I know I could do P(EF) = P(E)P(F), but I don't think they are since the probability of getting a head is dependent on what coin you have. Can you assist here?
Also, after I do this, presumably I do exactly the same method for the 0.7 prob coin and add the two answers together?
 
  • #10
CAF123 said:
Hi RGV,
I have done everything except i have difficulty in finding P(first one heads and have 0.4 coin). (As you advised me to calculate before). If these two events were independent, then I know I could do P(EF) = P(E)P(F), but I don't think they are since the probability of getting a head is dependent on what coin you have. Can you assist here?
Also, after I do this, presumably I do exactly the same method for the 0.7 prob coin and add the two answers together?

Sorry, I really cannot do more. All I can say is: think about what conditional probabilities mean, and how they are calculated.

RGV
 

Related to How to Calculate Probability of Getting Exactly 7 Heads?

1. What is conditional probability?

Conditional probability is the likelihood of an event occurring given that another event has already occurred. It takes into account the additional information or conditions that may affect the outcome.

2. How is conditional probability calculated?

Conditional probability can be calculated by dividing the probability of the two events occurring together by the probability of the event that has already occurred. In mathematical notation, it is written as P(A|B) = P(A and B) / P(B).

3. What is the difference between conditional and unconditional probability?

Unconditional probability is the likelihood of an event occurring without any additional information or conditions. Conditional probability, on the other hand, takes into account the additional information or conditions that may affect the outcome.

4. What are some real-world applications of conditional probability?

Conditional probability has many real-world applications, such as in weather forecasting, medical diagnoses, and risk assessment. It is also commonly used in fields such as finance, insurance, and marketing to make informed decisions based on available data.

5. How does Bayes' theorem relate to conditional probability?

Bayes' theorem is a mathematical formula that describes the relationship between conditional and unconditional probability. It allows us to update our beliefs about the likelihood of an event occurring as we receive new information or evidence. Bayes' theorem is often used in decision making and data analysis.

Similar threads

  • Precalculus Mathematics Homework Help
Replies
4
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
3
Views
1K
  • Precalculus Mathematics Homework Help
Replies
5
Views
1K
  • Precalculus Mathematics Homework Help
Replies
12
Views
2K
  • Precalculus Mathematics Homework Help
Replies
1
Views
1K
  • Precalculus Mathematics Homework Help
Replies
2
Views
860
  • Precalculus Mathematics Homework Help
Replies
4
Views
1K
  • Precalculus Mathematics Homework Help
Replies
12
Views
2K
  • Precalculus Mathematics Homework Help
Replies
8
Views
4K
  • Precalculus Mathematics Homework Help
Replies
3
Views
905
Back
Top