Many real-world probability questions involve updated information: "Given that I already know this happened, what is the probability that something else also happened (or will happen)?" This is the domain of Conditional Probability — one of the most profound and counterintuitive ideas in mathematics. Bayes' Theorem builds on this: it provides a systematic way to reverse the direction of conditioning, allowing us to go from P(evidence | hypothesis) to P(hypothesis | evidence). From medical testing to spam filters to legal reasoning, Bayes' Theorem is among the most powerful and widely applied results in all of probability. For JEE and CBSE, Bayes' Theorem problems (especially involving bags and balls, defective items, and disease testing) appear almost every year.
1. Conditional Probability
The conditional probability of event B occurring given that event A has already occurred is:
Interpretation: Restricts the sample space from S to A, then measures B within that restricted space.
Properties of Conditional Probability
- 0 ≤ P(B|A) ≤ 1
- P(B'|A) = 1 − P(B|A)
- P(B₁ ∪ B₂ | A) = P(B₁|A) + P(B₂|A) − P(B₁ ∩ B₂|A)
- If A and B are independent: P(B|A) = P(B) and P(A|B) = P(A)
Worked Example
P(A) = 1/2, P(A ∩ B) = 1/6. Find P(B|A).
P(B|A) = P(A∩B)/P(A) = (1/6)/(1/2) = 1/3
2. Law of Total Probability
If B₁, B₂, …, Bₙ are mutually exclusive and exhaustive events (they partition the sample space S), then for any event A:
This decomposes a complex probability into weighted conditional probabilities over all possible "routes" to A.
Worked Example
Bag 1 has 3 red, 2 blue. Bag 2 has 2 red, 3 blue. A bag is chosen randomly and a ball drawn. Find P(red).
P(red) = P(Bag1)·P(red|Bag1) + P(Bag2)·P(red|Bag2) = (1/2)(3/5) + (1/2)(2/5) = 3/10 + 2/10 = 1/2
3. Bayes' Theorem
If B₁, B₂, …, Bₙ partition S, and A is any event with P(A) > 0, then:
Terminology
| Term | Meaning |
| Prior probability | P(Bₖ) — probability of hypothesis before observing evidence |
| Likelihood | P(A|Bₖ) — probability of evidence given hypothesis |
| Posterior probability | P(Bₖ|A) — updated probability of hypothesis after observing evidence |
Step-by-Step Method for Bayes' Theorem Problems
- Identify the partition: B₁, B₂, …, Bₙ (the "routes" or "causes")
- Write down the prior probabilities P(Bᵢ)
- Write down the likelihoods P(A|Bᵢ) for each route
- Compute P(A) using the Law of Total Probability
- Apply Bayes' formula for the required posterior P(Bₖ|A)
Worked Example — Bags and Balls
Continuing from above: A bag is chosen randomly (Bag 1: 3R 2B; Bag 2: 2R 3B) and a red ball is drawn. Find P(it came from Bag 1).
P(Bag1) = P(Bag2) = 1/2; P(red|Bag1) = 3/5; P(red|Bag2) = 2/5
P(red) = (1/2)(3/5) + (1/2)(2/5) = 1/2
P(Bag1|red) = [(1/2)(3/5)] / (1/2) = (3/10)/(1/2) = 3/5
4. Bayes' Theorem — 3-Bag Problem
Bag 1: 2W 3B (5 balls); Bag 2: 4W 2B (6 balls); Bag 3: 3W 4B (7 balls). A bag is selected at random and a white ball is drawn. Find P(selected from Bag 2).
P(each bag) = 1/3; P(W|B1) = 2/5; P(W|B2) = 4/6 = 2/3; P(W|B3) = 3/7
P(W) = (1/3)(2/5) + (1/3)(2/3) + (1/3)(3/7) = 2/15 + 2/9 + 1/7
LCM(15,9,7) = 315: = 42/315 + 70/315 + 45/315 = 157/315
P(B2|W) = [(1/3)(2/3)] / (157/315) = (2/9) / (157/315) = (2/9)(315/157) = 70/157 ≈ 0.446
Practice Questions
Q1 (Board): A box contains 4 red and 6 white balls. Two balls are drawn in succession without replacement. Given that the first ball was red, find the probability that the second is also red.
Explanation:
Initially, the box contains .
After drawing 1 red ball on the first draw, the box now contains and balls, making a total of .
Therefore, the conditional probability of drawing a second red ball is:
Note: The total probability of drawing both red balls would be .
Q2 (JEE Main / Board): There are two bags. Bag A contains 3 white and 2 red balls; Bag B contains 2 white and 4 red balls. A bag is selected randomly and a ball drawn at random. It turns out to be white. Find the probability that Bag A was selected.
Explanation:
Let and be the events of selecting Bag A and Bag B.
Let be the event of drawing a white ball.
The conditional probabilities of drawing a white ball from each bag are:
Using the Law of Total Probability to find :
Using Bayes' Theorem to find :
Q3 (JEE / Board): In a factory, machine A produces 60% of items and machine B produces 40%. Machine A produces 5% defective items and machine B produces 3% defective. An item is chosen at random and found defective. What is the probability it was produced by machine A?
Explanation:
Let and be the events that the item is produced by Machine A and Machine B respectively.
Let be the event that the item is defective.
,
,
Total probability of a defective item :
Using Bayes' Theorem to find :
Q4 (MCQ): Given , , and . Find .
Explanation:
Using the conditional probability formula, we can find the intersection :
We also know that the intersection can be expressed using :
Q5 (JEE Advanced): Let denote the complement of an event . Let , and be any pairwise independent events such that and . Then is equal to:
A)
B)
C)
D)
Answer: A)
Explanation:
By the definition of conditional probability:
Using set theory and De Morgan's Laws, the numerator can be expanded as the probability of occurring MINUS the probability of intersecting with either or :
We are given that the events are pairwise independent, meaning and . We are also given . Substituting these in:
Substitute this back into the conditional probability fraction:
Since , this simplifies to:
Q6 (JEE Advanced): A laboratory blood test is 99% effective in detecting a certain disease when it is, in fact, present. However, the test also yields a false positive result for 0.5% of the healthy persons tested. If 0.1% of the population actually has the disease, what is the probability that a person actually has the disease given that their test result is positive?
Explanation:
Let be the event that a person has the disease, and be the event that they are healthy (no disease).
Let be the event that the test result is positive.
True Positive Rate:
False Positive Rate:
We need to find the posterior probability . Using Bayes' Theorem:
Substitute the given values:
To simplify, multiply the numerator and denominator by 100,000:
Dividing both by 5:
Dividing both by 9:
(Note: This is a classic demonstration of the Base Rate Fallacy. Despite the test being 99% accurate, because the disease is so rare (0.1%), a person with a positive result still only has a ~16.5% chance of actually having the disease!)
Q7 (JEE Advanced): Three randomly chosen non-negative integers and satisfy the condition . Find the probability that is strictly greater than .
Explanation:
Step 1: Find total outcomes
The total number of non-negative integer solutions to is given by the stars and bars formula where and :
Total cases = .
Step 2: Find favorable outcomes
We require .
We know .
Substitute this into the inequality:
.
Since are non-negative integers summing to 10, the possible values for that satisfy are . We must count the number of non-negative integer solutions for for each valid :
- If , then → solutions (from )
- If , then → solutions
- If , then → solutions
- If , then → solutions
- If , then → solution
Total favorable cases = .
Step 3: Calculate final probability
Q8 (JEE Advanced): A player plays a game against a machine. At each turn, the player has a probability of of winning and of losing. The game ends either when the player wins two consecutive turns or loses two consecutive turns. Find the probability that the player wins the game (i.e., the game ends with two consecutive wins).
Explanation:
Let be the event of winning a turn and be losing. The game can end in a win via paths starting with a Win () or starting with a Loss ().
Case 1: Game starts with a Win
The sequence must alternate and suddenly end in .
Probability sum
This is an infinite geometric progression with first term and common ratio .
Case 2: Game starts with a Loss
The sequence must be exactly the same alternating pattern, just prefaced by one loss:
Probability sum
This is exactly times the series .
Total Probability of Winning the Game:
Substitute and :