# A urn has 2 “A” coins & 1 “B” coin. “A” is heads with p=1/4. “B” is heads with p=3/4. Given heads what is probability that we chose an “A” coin?

Stating the problem more clearly:

An urn contains two type A coins and one type B coin. When a type A coin is flipped, it comes up heads with probability 1/4, whereas when a type B coin is flipped, it comes up heads with probability 3/4. A coin is randomly chosen from the urn and flipped. Given that the flip landed on heads, what is the probability that it was a type A coin?

This is from Sheldon Ross (example 3i). They give the answer to be:

$$\frac{P(A|heads)}{P(A^c|heads)}= \frac{P(A)P(heads|A)}{P(B)P(heads|B)} = \frac{2/3 \times 1/4}{1/3 \times 3/4} = \frac{2}{3}$$

Which is all fine and dandy and fits with their theorem or whatever. But why doesn't classic Bayes Rule work here?

$$P(A|heads) = \frac{P(heads|A)P(A)}{P(heads)}$$

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

$$P(A|heads) = \frac{1/4 \times 2/3}{1/4 \times 2/3 + 3/4 \times 1/3}$$

$$P(A|heads) = \frac{1/6}{1/6 + 1/4} = \frac{2}{5} = 0.4$$

Here is the assumption that is probably wrong, please tell me why it is because I cannot see why it is the case:

$$P(heads) = P(heads|A)P(A) + P(heads|A^c)P(A^c)$$ $$P(heads) = P(heads|A)P(A) + P(heads|B)P(B)$$

You misunderstood the text. The probability is indeed $\frac25$. (The text says so itself at the top of p. $73$ of the $8$th edition.) The calculation that yields $\frac23$ is the calculation of the odds, not of the probability.