1.4. Conditional Probability and Independence¶
1.4.1. Conditional Probability and Bayes' Theorem¶
Definition 1.4.1 : Conditional probability
Let \(B\) and \(A\) be events with \(P(A)>0\). The conditional probability of \(B\) given \(A\) is defined as
Theorem 1.4.2 : Properties of conditional probability
Let \(A\) be an event with \(P(A)>0\). Conditional probability has the following properties:
- (1) \(P(B \mid A) \geq 0\).
- (2) \(P(A \mid A)=1\).
-
(3) If \(B_{1}, B_{2}, \ldots\) are mutually exclusive events, then
\[ P\left(\cup_{n=1}^{\infty} B_{n} \mid A\right)=\sum_{n=1}^{\infty} P\left(B_{n} \mid A\right). \]
These are precisely the conditions that a probability set function must satisfy. Thus \(P(B \mid A)\) is a probability set function defined for subsets of \(A\), called the conditional probability set function relative to the hypothesis \(A\), or given \(A\). This function is defined here only when \(P(A)>0\).
Proof
Properties (1) and (2) follow immediately from the definition of conditional probability. For Property (3), suppose that \(B_{1}, B_{2}, \ldots\) are mutually exclusive. Then \((B_{n} \cap A) \cap (B_{m} \cap A)=\phi\) for \(n \neq m\). Using the first distributive law for countable unions in Theorem 1.2.7 and countable additivity, we obtain
Theorem 1.4.3 : Multiplication rule for probabilities
For events \(A\) and \(B\) with \(P(A)>0\), the multiplication rule for probabilities is
For three events, provided \(P(A\cap B)>0\),
More generally, for \(k\geq 2\) events \(A_1,\ldots,A_k\) with \(P(A_1\cap\cdots\cap A_{k-1})>0\),
Proof
By the conditional probability set function in Theorem 1.4.2,
which gives the multiplication rule for two events. Applying this rule twice gives
For \(k\) events, apply the two-event rule to \(A_1\cap\cdots\cap A_{k-1}\) and \(A_k\):
Substituting the multiplication rule for the first \(k-1\) events proves the general formula by mathematical induction, with the two-event rule as the base case.
Theorem 1.4.4 : Law of total probability
Let \(A_{1}, A_{2}, \ldots, A_{k}\) be mutually exclusive and exhaustive events forming a partition of \(\mathcal{C}\), with \(P(A_i)>0\) for \(i=1,2,\ldots,k\). These events need not be equally likely. If \(B\) is another event with \(P(B)>0\), then
Proof
Since \(A_{1}, A_{2}, \ldots, A_{k}\) form a partition of \(\mathcal{C}\),
The events \(B\cap A_i\), \(i=1,2,\ldots,k\), are mutually exclusive, and \(P(B\cap A_i)=P(A_i)P(B\mid A_i)\). Therefore,
Theorem 1.4.5 : Bayes' theorem
Let \(A_1, A_2, \ldots, A_k\) be events such that \(P(A_i)>0\), \(i=1,2,\ldots,k\). Assume that \(A_1, A_2, \ldots, A_k\) form a partition of the sample space \(\mathcal{C}\). Let \(B\) be an event such that \(P(B)>0\). Then
Proof
By the definition of conditional probability,
The result follows by the law of total probability (Theorem 1.4.4).
Example 1.4.6 : Application of Baye's theorem
Bowl \(A_{1}\) contains three red and seven blue chips, and bowl \(A_{2}\) contains eight red and two blue chips. All chips are identical in size and shape. A die is cast, and bowl \(A_{1}\) is selected if five or six spots show; otherwise, bowl \(A_{2}\) is selected. Assign
The selected bowl is handed to another person, who takes one chip at random. Let \(B\) be the event that the chip is red. From the contents of the bowls,
The conditional probability that bowl \(A_{1}\) was selected, given that a red chip is drawn, is
Similarly,
Concept 1.4.7 : Prior and posterior probabilities
In Example 1.4.6, the probabilities \(P\left(A_{1}\right)=\frac{2}{6}\) and \(P\left(A_{2}\right)=\frac{4}{6}\) are called prior probabilities of \(A_{1}\) and \(A_{2}\), respectively, because they are known from the random mechanism used to select the bowls. After the chip is taken and observed to be red, the conditional probabilities \(P\left(A_{1} \mid B\right)=\frac{3}{19}\) and \(P\left(A_{2} \mid B\right)=\frac{16}{19}\) are called posterior probabilities. Thus, the prior probabilities describe the bowl selection before observing the chip's color, while the posterior probabilities condition on the observed red chip.
1.4.2. Independence¶
Definition 1.4.8 : Independent events
Let \(A\) and \(B\) be two events. We say that \(A\) and \(B\) are independent if
Theorem 1.4.9 : Independence of complementary events
Suppose \(A\) and \(B\) are independent events. Then the following three pairs of events are independent: \(A^{c}\) and \(B\), \(A\) and \(B^{c}\), and \(A^{c}\) and \(B^{c}\).
Proof
Using the disjoint union \(B=(A^{c} \cap B) \cup (A \cap B)\) and the independence of \(A\) and \(B\), we have
Hence, \(A^{c}\) and \(B\) are independent.
Similarly, using the disjoint union \(A=(A \cap B) \cup (A \cap B^{c})\), we obtain
Thus, \(A\) and \(B^{c}\) are independent.
Finally, the disjoint union \(A^{c}=(A^{c} \cap B) \cup (A^{c} \cap B^{c})\) and the independence of \(A^{c}\) and \(B\) give
Therefore, \(A^{c}\) and \(B^{c}\) are independent.
Definition 1.4.10 : Mutually independent events
Three events \(A_1, A_2, A_3\) are mutually independent if and only if they are pairwise independent and their triple intersection also satisfies the product rule:
More generally, \(n\) events \(A_1, A_2, \ldots, A_n\) are mutually independent if and only if, for every collection of \(k\) of these events with \(2 \leq k \leq n\), indexed by distinct \(d_1, d_2, \ldots, d_k \in \{1, 2, \ldots, n\}\),
If there is no possibility of misunderstanding, independent is often used without the modifier mutually when considering more than two events.
Theorem 1.4.11 : Independence of combinations and complements
Let \(A_1,\ldots,A_n\) be mutually independent events, so that for every nonempty \(S\subseteq\{1,\ldots,n\}\),
Let \(I_1,\ldots,I_m\) be pairwise disjoint, nonempty subsets of \(\{1,\ldots,n\}\). For each \(r\in\{1,\ldots,m\}\), let \(B_r\) be any event obtained from the events \(A_i\), \(i\in I_r\), by finitely many unions, intersections, and complements. Then \(B_1,\ldots,B_m\) are mutually independent: for every nonempty \(R\subseteq\{1,\ldots,m\}\),
In particular, whenever the indicated indices belong to \(\{1,\ldots,n\}\):
- (a) The events \(A_1^c\) and \(A_2\cup A_3^c\cup A_4\) are independent.
- (b) The events \(A_1\cup A_2^c\), \(A_3^c\), and \(A_4\cap A_5^c\) are mutually independent.
Proof
For disjoint subsets \(I,J\subseteq\{1,\ldots,n\}\), inclusion-exclusion and mutual independence give
Here an intersection over an empty index set is the whole sample space, and an empty product is \(1\). For each \(r\) and each \(H\subseteq I_r\), define
The events \(E_{r,H}\), \(H\subseteq I_r\), form a finite partition of the sample space, with empty members allowed. Every event obtained from the \(A_i\), \(i\in I_r\), by unions, intersections, and complements is a union of members of this partition. Thus there is a collection \(\mathcal H_r\subseteq\{H:H\subseteq I_r\}\) such that
where the union is disjoint. Fix a nonempty \(R\subseteq\{1,\ldots,m\}\). Since the index sets \(I_r\) are pairwise disjoint, the first identity gives, for every choice of \(H_r\in\mathcal H_r\),
Expanding the intersection of the \(B_r\) as a disjoint union and summing these products yields
Because this holds for every nonempty \(R\), the events \(B_1,\ldots,B_m\) are mutually independent. Taking the index groups \(\{1\}\) and \(\{2,3,4\}\) gives (a), and taking \(\{1,2\}\), \(\{3\}\), and \(\{4,5\}\) gives (b).