# Conditional and Marginal Independence

Let $$A, B, C$$ be three random variables. Consider the following dependency structures modeled with Bayesian networks.

1. $$A \leftarrow B \rightarrow C$$
2. $$A \rightarrow B \rightarrow C$$
3. $$A \rightarrow B \leftarrow C$$

The first two cases both say that $$A$$ and $$C$$ are conditionally independent given $$B$$. The last case says that $$A$$ and $$C$$ are marginally independent (when $$B$$ is marginalized out); however, they are dependent conditioning on $$B$$.

The following are the precise descriptions using the probability notion.

1. $$P(A, B, C) = P(B)P(A|B)P(C|B)$$
2. $$P(A, B, C) = P(A)P(B|A)P(C|B)$$
3. $$P(A, B, C) = P(A)P(C)P(B|A, C)$$