Small-bias distributions and the XOR lemma #
The bias of a distribution X on the cube ι → Bool at a set S of coordinates is the
expectation of the character χ_S under X (Cslib.BitString.bias), which is
Pr[⊕_{i ∈ S} xᵢ = 0] - Pr[⊕_{i ∈ S} xᵢ = 1] (Cslib.BitString.bias_eq_one_sub_two_mul).
The uniform distribution has bias zero at every nonempty set. A distribution is ε-biased
(Cslib.BitString.IsSmallBias) if its bias at every nonempty set is at most ε in absolute value
Naor and Naor, and k-wise ε-biased (Cslib.BitString.IsKWiseSmallBias) if
this holds for the nonempty sets of at most k coordinates
Alon, Goldreich, Håstad and Peralta.
The bias at S is 2 ^ n times the Fourier coefficient of the mass function of X at S, so
Parseval's identity gives ∑_S bias X S ^ 2 = 2 ^ n cp(X) for the collision probability cp
(Cslib.BitString.sum_bias_sq). Combined with the collision bound on the distance to uniform,
this is Vazirani's XOR lemma Vazirani
(Cslib.BitString.four_mul_dist_uniform_sq_le_sum_bias_sq): the statistical distance of X from
uniform is at most half the root of the sum of the squared biases at the nonempty sets. An
ε-biased distribution on n bits is therefore within √(2 ^ n - 1) ε / 2 of uniform
(Cslib.BitString.IsSmallBias.dist_uniform_le). The marginal of X on a set T of coordinates
has the biases of X at the subsets of T (Cslib.BitString.bias_map_restrict), so a k-wise
ε-biased distribution is almost k-wise independent: its marginal on any k coordinates is
within √(2 ^ k - 1) ε / 2 of uniform (Cslib.BitString.IsKWiseSmallBias.dist_map_restrict_le).
Reading a distribution through n parities y_j = c_j ⬝ᵥ x of its bits turns the bias at a set
T of outputs into the bias at the support of ∑_{j ∈ T} c_j
(Cslib.BitString.bias_map_dotProduct). If the vectors c_j are k-wise linearly independent,
an ε-biased distribution is read as a k-wise ε-biased one
(Cslib.BitString.IsSmallBias.isKWiseSmallBias_map_dotProduct), the linear composition of
Naor and Naor.
Main definitions #
Cslib.BitString.bias: the bias of a distribution on the cube at a set of coordinates.Cslib.BitString.IsSmallBias:ε-biased distributions.Cslib.BitString.IsKWiseSmallBias:k-wiseε-biased distributions.
Main results #
Cslib.BitString.bias_eq_one_sub_two_mul: the bias in terms of the probability of odd parity.Cslib.BitString.bias_uniformOfFintype: the uniform distribution is unbiased.Cslib.BitString.sum_bias_sq: Parseval's identity for the biases.Cslib.BitString.four_mul_dist_uniform_sq_le_sum_bias_sq,Cslib.BitString.dist_uniform_le_sqrt_sum_bias_sq: Vazirani's XOR lemma.Cslib.BitString.IsSmallBias.dist_uniform_le:ε-biased distributions are close to uniform.Cslib.BitString.IsKWiseSmallBias.dist_map_restrict_le:k-wiseε-biased distributions are almostk-wise independent.Cslib.BitString.IsSmallBias.isKWiseSmallBias_map_dotProduct:k-wise independent parities of anε-biased distribution arek-wiseε-biased.
References #
The bias of a distribution X on the cube at a set S of coordinates: the expectation of the
character χ_S under X, which is Pr[⊕_{i ∈ S} xᵢ = 0] - Pr[⊕_{i ∈ S} xᵢ = 1]
(bias_eq_one_sub_two_mul).
Instances For
Every distribution has bias one at the empty set.
The bias of the image of a distribution is the expectation of the character of the image.
The bias of a sample space g, with a uniformly random seed, is the average of the character
over the seeds.
The uniform distribution has bias zero at every nonempty set.
Parseval's identity for the biases: the squared biases of X sum to 2 ^ n times its
collision probability.
Vazirani's XOR lemma, squared form: four times the squared statistical distance of X
from uniform is at most the sum of the squared biases of X at the nonempty sets.
Vazirani's XOR lemma: the statistical distance of X from uniform is at most half the
square root of the sum of the squared biases of X at the nonempty sets.
A distribution X on the cube is ε-biased if its bias at every nonempty set of
coordinates is at most ε in absolute value Naor and Naor.
Instances For
A distribution X on the cube is k-wise ε-biased if its bias at every nonempty set of at
most k coordinates is at most ε in absolute value
Alon, Goldreich, Håstad and Peralta.
Instances For
The uniform distribution is 0-biased.
Every distribution is 1-biased.
An ε-biased distribution is δ-biased for every δ ≥ ε.
An ε-biased distribution is k-wise ε-biased for every k.
Small bias implies closeness to uniform: an ε-biased distribution on n bits is within
statistical distance √(2 ^ n - 1) ε / 2 of uniform.
A distribution is n-wise ε-biased on n bits exactly when it is ε-biased.
The character of a set S of coordinates in T at the restriction of x to T is the
character of S, as a set of coordinates of x.
The marginal of X on a set T of coordinates has the biases of X at the subsets of T.
A k-wise ε-biased distribution is k'-wise ε-biased for every k' ≤ k.
The marginal of a k-wise ε-biased distribution on a set of at most k coordinates is
ε-biased.
Almost k-wise independence: the marginal of a k-wise ε-biased distribution on a set
T of at most k coordinates is within statistical distance √(2 ^ #T - 1) ε / 2 of uniform
Alon, Goldreich, Håstad and Peralta.
Reading X through the parities y_j = c j ⬝ᵥ x turns the bias at a set T of outputs into
the bias of X at the coordinates where ∑_{j ∈ T} c j is true.
Linear composition Naor and Naor: if every nonempty set of at most k of
the vectors c j has a nonzero sum, then the parities c j ⬝ᵥ x of an ε-biased distribution are
k-wise ε-biased.