The XOR construction for statistical distance #
Given two distributions p₀ and p₁ on a finite type, xorMix p₀ p₁ k c draws selector bits
b : BitString k uniformly among those of parity c, then draws coordinate i from p_{b i},
independently. Statistical distance between c = false and c = true is multiplicative:
for k ≥ 1,
dist (xorMix p₀ p₁ k false) (xorMix p₀ p₁ k true) = dist p₀ p₁ ^ k (dist_xorMix).
This is the XOR Lemma of Sahai and Vadhan [SahaiVadhan2003, Lemma 3.5]. The construction pushes
small distances towards 0. The proof writes the difference of the two masses at x as a signed
sum over selectors and factors it as ∏ i, (p₀ (x i) - p₁ (x i)) / 2 ^ (k - 1)
(toReal_xorMix_sub); summing absolute values factors again over the coordinates.
When k = 0 there are no selectors of parity true, and xorMix returns the product of copies of
p₀ on both sides; the identity then fails, since dist p₀ p₁ ^ 0 = 1.
Main definitions #
Cslib.Probability.PMF.xorMix: the XOR construction.
Main results #
Cslib.Probability.PMF.toReal_xorMix: masses of the construction.Cslib.Probability.PMF.toReal_xorMix_sub: the difference of masses factors over coordinates.Cslib.Probability.PMF.dist_xorMix: the XOR Lemma.
References #
The XOR construction [SahaiVadhan2003, Lemma 3.5]: draw selector bits b of k coordinates
uniformly among those of parity c, then draw coordinate i from p₀ or p₁ according to
b i, independently. With no selector of parity c (only when k = 0 and c = true), it draws
from p₀ in every coordinate.