Great question! Let's analyze the case for three random variables (X, Y, Z).
Claim:
[
\sum_{X,Y,Z} P(X|Y,Z)P(Y|X,Z)P(Z|X,Y) = 1 \quad \text{if and only if} \quad X, Y, Z \text{ are mutually independent.}
]
Proof:
1. If (X, Y, Z) are mutually independent, then the sum equals 1:
If (X, Y, Z) are independent, then:
[
P(X,Y,Z) = P(X)P(Y)P(Z),
]
and the conditional probabilities simplify to:
[
P(X|Y,Z) = P(X), \quad P(Y|X,Z) = P(Y), \quad P(Z|X,Y) = P(Z).
]
Thus:
[
\sum_{X,Y,Z} P(X|Y,Z)P(Y|X,Z)P(Z|X,Y) = \sum_{X,Y,Z} P(X)P(Y)P(Z) = 1.
]
2. If the sum equals 1, then (X, Y, Z) are mutually independent:
We need to show that:
[
\sum_{X,Y,Z} \frac{P(X,Y,Z)^3}{P(Y,Z)P(X,Z)P(X,Y)} = 1 \quad \implies \quad P(X,Y,Z) = P(X)P(Y)P(Z).
]
Step 1: Rewrite the sum in terms of joint probabilities:
[
P(X|Y,Z) = \frac{P(X,Y,Z)}{P(Y,Z)}, \quad P(Y|X,Z) = \frac{P(X,Y,Z)}{P(X,Z)}, \quad P(Z|X,Y) = \frac{P(X,Y,Z)}{P(X,Y)}.
]
Thus:
[
\sum_{X,Y,Z} \frac{P(X,Y,Z)^3}{P(Y,Z)P(X,Z)P(X,Y)} = 1.
]
Step 2: Apply the generalized Hölder's inequality (or the AM-GM inequality for probabilities):
For non-negative numbers, the product ( \frac{a^3}{bc} ) (where (a = P(X,Y,Z)), (b = P(Y,Z)), etc.) satisfies:
[
\frac{a^3}{bc} \geq a \left( \frac{a}{b} + \frac{a}{c} - 1 \right),
]
but a more precise tool is needed. Instead, consider the log-sum inequality or KL divergence perspective.
Step 3: Use the log-sum inequality to enforce equality:
The sum can be interpreted as a kind of "cross-entropy" term. For equality to hold, we must have:
[
\frac{P(X,Y,Z)^2}{P(Y,Z)P(X,Z)P(X,Y)} = \text{constant for all } X,Y,Z.
]
But since probabilities must normalize, the only possible constant is 1, meaning:
[
P(X,Y,Z)^2 = P(Y,Z)P(X,Z)P(X,Y).
]
This is a factorization condition that implies mutual independence.
Verification of independence:
Suppose (X, Y, Z) are not independent. Then, for some ((x,y,z)):
[
P(X=x,Y=y,Z=z) \neq P(X=x)P(Y=y)P(Z=z).
]
But the sum condition requires:
[
P(X,Y,Z)^2 = P(Y,Z)P(X,Z)P(X,Y).
]
Taking marginals, this enforces:
[
P(X,Y) = P(X)P(Y), \quad P(Y,Z) = P(Y)P(Z), \quad P(X,Z) = P(X)P(Z),
]
and thus:
[
P(X,Y,Z) = P(X)P(Y)P(Z).
]
Conclusion:
[
\sum_{X,Y,Z} P(X|Y,Z)P(Y|X,Z)P(Z|X,Y) = 1 \quad \text{if and only if} \quad X, Y, Z \text{ are mutually independent.}
]
Key Insight:
- For two variables, the condition reduces to pairwise independence.
- For three variables, the condition enforces mutual independence (stronger than pairwise independence).
- The proof relies on factorization and inequality constraints (Hölder/log-sum) to ensure no dependencies exist.
This generalizes nicely to (n) variables, where the product of (n) conditional probabilities sums to 1 iff all variables are mutually independent.