"Nicer Version" of Bayes' Theorem?

108 Views Asked by At

My Textbook says this for Bayes' Theorem

For any two events $A$ and $B$ with nonzero probabilities

$$P(A \mid B) = \frac{P(A)P(B\mid A)}{P(B)}$$

This is the standard formula for Bayes' theorem that I know and am familiar with, but the textbook says that the following is another alternative "nicer" formula of Bayes' Theorem:

If $P(B) \neq 0 $ and $0 < P(A) < 1$ then,

$$P(A\mid B) = \frac{P(A)P(B\mid A)}{P(A)P(B\mid A) + P(A^C)P(B\mid A^C)}$$

I see what they did, they just broke $P(B)$ into $$P(A\cap B) + P(A^C \cap B) = P(A)P(B\mid A)+P(A^C)P(B\mid A^C)$$ and substituted the denominator with this in the 2nd formula.

My question is, why is this version of the formula "nicer"? Is it in the case you don't know what $P(B)$ is? But know $P(A)$ and $P(B\mid A)$ (which naturally gives you $P(A^C)$ and $P(B\mid A^C)$)?