# Latest content was relocated to https://bintanvictor.wordpress.com. This old blog will be shutdown soon.

## Monday, November 5, 2012

### 2-headed coin - inherent "pool" distribution

Q1: Given a suspicious coin. You toss 5 times and get all tails. You suspect Tail is more than 50% chance. What's a fair estimate of that chance (K)?

Analysis: The value of K could be 51%, 97%, even 40%, so K is a continuous random variable whose PDF is unknown. What's a fair estimate of K? The Expected value of K? So the task is to estimate the PDF.

Might be too tough. Now look at a simpler version --

Q2: A suspicious coin is known as either fair (50/50) or 2-headed. 10 tosses, all heads. What's the probability of unfair? You could, if you like, imagine that you randomly pick one from a mixed pool of fair/unfair coins.

Q2b (equivalent to Q2): Given a pool of 3600 coins, each being either fair or 2-headed. You pick one at random and throw 5 times. All heads. What's the probability of unfair?

If you assume half the coins 2-headed then see answer to Q3b. But for now let's assume 36 (1% of population) are 2-headed, answer is much Lower.
U := unfair coin picked.
A := 5 tosses all head
P(U|A) is the goal of the quiz.

P(U|A) = P(U & A)/P(A). Now P(U&A) = P(U) = 1% and P(A) = 1% + 99%/2^5 = 1% + 99%/32 ~= 4%. Therefore,
P(U|A) ~= 25%.

The answer, the estimated probability, depends on the underlying pool distribution, so to estimate P(U|A), we must estimate that distribution P(U). Note the notations -- P(U) denotes pool-distribution inherent in the pool. P(U) is an unknown we are guessing. The goal of the quiz P(U|A) is an "educated guess" but never equal to the "guess" unless P(A)=100%. In fact, we are not trying to estimate P(U). Goal is P(U|A), a completely different entity.

Some say as we do more experiments our educated guess will get more accurate, but I don't think so.

Q3: Given 2 coins, 1 of them have no tail (i.e. unfair coin). You pick one and toss it 5 times and get all heads . What's the probability you picked a Unfair coin?
Much easier. I think P(U|A) = 32/33. Here's the calc

U := unfair coin picked.
A := 5 tosses all head

P(U|A) = P(U & A)/P(A). Now P(A) = 1/2 + 1/64 and P(U&A) = P(U) = 1/2.

Q3b (equivalent?) Given a pool of 3600 coins, half of them 2-headed. You pick one at random and throw 5 times. All heads. What's the probability of fair?