1. Meaning of Bayes' Theorem
Bayes' Theorem helps find the probability of an event when some related outcome is already known. It is used to update earlier beliefs using new information.
It answers questions like: “Given that B has happened, what is the updated probability that A was the cause?”
This is very useful when an event can happen in more than one way and we want to find which way is most likely after seeing some evidence.
2. Understanding the Idea Behind Bayes' Rule
Imagine an event B that can occur because of different possible events \(A_1, A_2, A_3, ...\). When B happens, we want to know which \(A_i\) is most likely behind it.
Bayes' Theorem gives a way to compute the updated probability by combining:
- The prior chance of each \(A_i\)
- The chance that B happens if \(A_i\) occurs
2.1. Example Idea (No Calculation)
Suppose there are two boxes:
- Box 1 has mostly red balls.
- Box 2 has mostly blue balls.
If you draw a red ball, Bayes' Theorem helps find which box the ball most likely came from.
3. The Formula for Bayes' Theorem
If there are events \(A_1, A_2, ..., A_n\) that form a partition of the sample space (i.e., one of them must occur), then Bayes' rule is:
\( P(A_i|B) = \dfrac{P(A_i)P(B|A_i)}{\sum_{j=1}^{n} P(A_j)P(B|A_j)} \)
This formula allows us to “reverse” conditional probabilities.
4. Total Probability Needed Before Bayes' Rule
Before applying Bayes' theorem, we often calculate:
\( P(B) = \sum P(A_j)P(B|A_j) \)
This is the total probability of B based on all possible ways B can occur.
5. Worked Example
Suppose there are two bags:
- Bag A: 3 red, 2 blue
- Bag B: 2 red, 4 blue
A bag is chosen at random, and a red ball is drawn. What is the probability that the red ball came from Bag A?
5.1. Step-by-Step Solution
Step 1: Compute prior probabilities.
- \( P(A) = 1/2 \)
- \( P(B) = 1/2 \)
Step 2: Compute conditional probabilities.
- \( P(\text{Red}|A) = 3/5 \)
- \( P(\text{Red}|B) = 2/6 = 1/3 \)
Step 3: Apply Bayes' theorem.
\( P(A|\text{Red}) = \dfrac{P(A)P(\text{Red}|A)}{P(A)P(\text{Red}|A) + P(B)P(\text{Red}|B)} \)
\( = \dfrac{(1/2)(3/5)}{(1/2)(3/5) + (1/2)(1/3)} \)
\( = \dfrac{3/10}{3/10 + 1/6} = \dfrac{3/10}{(9/30 + 5/30)} \)
\( = \dfrac{3/10}{14/30} = \dfrac{3}{10} \cdot \dfrac{30}{14} = \dfrac{9}{14} \)
The red ball is more likely to have come from Bag A.