Conditional probability
Definition taught in Random experiments and probability, part of Probability
Conditional probability

| Type | Definition |
| Taught in | Random experiments and probability |
| Part | Probability |
| Properties | 2 |
| Worked examples | 4 |
| Questions using it | 1 |
If \mathbb{P}(B)>0, the conditional probability of A given B is
\mathbb{P}(A\mid B)=\frac{\mathbb{P}(A\cap B)}{\mathbb{P}(B)}.
Properties
Product rule
Main article: Product rule
If \mathbb{P}(A_1\cap\cdots\cap A_{n-1})>0, then
\mathbb{P}(A_1\cap\cdots\cap A_n) =\mathbb{P}(A_1)\,\mathbb{P}(A_2\mid A_1)\,\mathbb{P}(A_3\mid A_1\cap A_2)\cdots\mathbb{P}(A_n\mid A_1\cap\cdots\cap A_{n-1}).
Each factor is the definition of conditional probability, and the intermediate intersections cancel.
Law of total probability
Main article: Law of total probability
If B_1,\ldots,B_n are disjoint and their union is \Omega, then for every event A
\mathbb{P}(A)=\sum_{i=1}^n \mathbb{P}(A\mid B_i)\,\mathbb{P}(B_i).
The events A\cap B_i are disjoint and exhaust A, so the sum rule applies, and each term is the product rule.
Examples
The Monty Hall problem
Worked example from Random experiments and probability
A prize is equally likely behind curtain A, B or C. The contestant picks A. The host, who knows where the prize is, always opens a different curtain that has no prize, choosing at random when both remaining curtains are empty.
Question. Suppose the host opens B. Should the contestant switch to C?
Solution. The definition of conditional probability settles it without any story about psychology. The four atoms that can occur, with their probabilities, are: prize behind A and host opens B (1/6), prize behind A and host opens C (1/6), prize behind B and host opens C (1/3), prize behind C and host opens B (1/3). The observed event is the two atoms in which B is opened, with total probability 1/6+1/3=1/2. The prize is behind A in only the first of those atoms, so
\mathbb{P}(\text{prize behind }A\mid \text{host opens }B)=\frac{1/6}{1/2}=\frac13,
and the probability it is behind C is 2/3. Switching wins with probability 2/3.
The tempting answer, one half each, forgets that the host’s choice depends on where the prize is. When the contestant’s first pick is wrong, which happens two times in three, the host is forced to reveal the only other empty curtain.
Three factories
Worked example from Random experiments and probability
A chip is made in factory 1, 2 or 3 with probabilities 0.15, 0.35 and 0.50, and the defective rates are 0.01, 0.05 and 0.02.
Question. A chip in hand is defective. What is the probability that it came from factory 1?
Solution. By Bayes’ rule, the probability it came from factory 1 is
\frac{0.15\times 0.01}{0.15\times 0.01+0.35\times 0.05+0.50\times 0.02}=\frac{0.0015}{0.029}\approx 0.052.
The rare factory is unlikely to be the source, because the two larger factories produce more defectives in total even though each chip from factory 1 is less often defective.
The same calculation gives 0.0175/0.029=0.603 for factory 2 and 0.010/0.029=0.345 for factory 3. The denominator, 0.029, is the overall defective rate, from the law of total probability.
Information about one die
Question page: Information about one die
Two fair dice are thrown in order.
Find the probability that the second face is 3, given that the sum is 6.
Find the probability that the first face is 3 and the second face is not 3.
The pairs with sum 6 are (1,5),(2,4),(3,3),(4,2),(5,1). Exactly one of the five has second coordinate 3, so the conditional probability is 1/5.
The faces are independent, so the probability is (1/6)\times(5/6)=5/36.
A one received on a noisy channel
Question page: A one received on a noisy channel
A binary channel sends a 1 with probability 2/3 and a 0 with probability 1/3. A sent 1 is received as 1 with probability 0.95. A sent 0 is received as 0 with probability 0.90. A 1 is received. Find the probability that a 1 was sent.
Let B be the event that a 1 was sent and A the event that a 1 was received. Then \mathbb{P}(A\mid B)=0.95, \mathbb{P}(A\mid B^c)=0.10, \mathbb{P}(B)=2/3 and \mathbb{P}(B^c)=1/3. Bayes’ rule for events gives
\mathbb{P}(B\mid A)=\frac{0.95\times 2/3}{0.95\times 2/3+0.10\times 1/3}=\frac{1.9}{2}=0.95.
Used in
- Taught in Random experiments and probability, where the derivation and examples are.
- Also used in Joint distributions
- Questions that use it (1) — Information about one die (answer)
- All 17 questions on Random experiments and probability
See also
Product rule · Sample space · Event · Probability measure · Properties of a probability · Equally likely outcomes · Four ways of counting draws · Law of total probability