Mathematical Physicsundergraduate

Bayes' Theorem

Also known as: Bayes' rule · Inverse probability

Bayes' theorem is how you update a belief when new evidence arrives. Start with a prior — how likely a hypothesis was before — multiply by how well the hypothesis predicts the new data (the likelihood), and renormalize. The counterintuitive punchline: even a very accurate test for a rare condition mostly returns false positives, because the tiny prior overwhelms the likelihood. It flips 'probability of data given hypothesis' into the thing you actually want: 'probability of hypothesis given data.'

P(AB)=P(BA)P(A)P(B)P(A\mid B)=\frac{P(B\mid A)\,P(A)}{P(B)}
Live simulation
warming up the physics…

As the prior slides from rare to common, the posterior probability given a positive test updates through Bayes' rule.

Equivalent forms

P(HD)=P(DH)P(H)iP(DHi)P(Hi)P(H\mid D)=\frac{P(D\mid H)P(H)}{\sum_i P(D\mid H_i)P(H_i)}
One line of algebra turns forward probabilities into inference — the engine behind spam filters, medical diagnosis, and modern data analysis.