Documentation

CslibFrontier.Computability.Circuit.Boolean.XorPowerListSize

The list size of the k-fold XOR code #

The k-fold XOR g^{⊕k} of a Boolean function g on n bits (Cslib.Circuits.Boolean.xorPower) encodes the truth table of g, a message of M = 2 ^ n bits, as a word of 2 ^ (k n) bits. Read as signs, the XOR of the values of g on k blocks is the product of their signs (signVal_xorPower). Since the blocks of a uniform input are independent and uniform, the correlation of two encodings is the k-th power of the correlation of the messages (expect_signVal_xorPower_mul_signVal_xorPower): 𝔼 signVal (g^{⊕k}) signVal (g'^{⊕k}) = (𝔼 signVal g signVal g') ^ k for every k.

The code is not injective for even k, since g and its complement have the same encoding, and its distance is poor; still its lists are short. Let k be odd. Messages at relative distance at least δ₀ have correlation at most 1 - 2 δ₀, so their encodings have correlation at most (1 - 2 δ₀) ^ k, also when the messages are nearly complementary, because t ↦ t ^ k is monotone. If (1 - 2 δ₀) ^ k ≤ 2 ε ^ 2, the binary Johnson bound (Cslib.Code.card_filter_mul_two_mul_sq_le) shows that at most V / (2 ε ^ 2) functions g have encodings agreeing with a fixed word on a 1 / 2 + ε fraction of the inputs, where V = ∑_{j ≤ r} C(M, j) is the size of a Hamming ball of radius r ≥ δ₀ M - 1 among the messages (card_filter_xorPower_mul_two_mul_sq_le). With r = ⌊δ₀ M⌋ and the entropy bound on the ball, for δ₀ ≤ 1 / 2 the list has at most exp (M H(δ₀)) / (2 ε ^ 2) = 2 ^ (H₂(δ₀) M) / (2 ε ^ 2) functions, where H = Real.binEntropy is the binary entropy in nats (card_filter_xorPower_mul_two_mul_sq_le_exp).

Faithfulness: the correlation identity is the classical computation for XOR codes. The list size bound is a library result combining it with the binary Johnson bound and a covering argument; it is the list-size step of the library's route to the NP-hardness of partial MCSP (issue #4362, milestone H2), not a statement taken from a source.

Main results #

References #

The sign of the k-fold XOR is the product of the signs of the values on the blocks.

The sign correlation of two k-fold XORs is the k-th power of the sign correlation of the functions.

Correlation of k-fold XORs: under the uniform distribution, the correlation of two k-fold XORs is the k-th power of the correlation of the functions.

theorem Cslib.Circuits.Boolean.card_filter_xorPower_mul_two_mul_sq_le {n k : ℕ} (hk : Odd k) (w : BitString (k * n) → Bool) {ε δ₀ : ℝ} (hε : 0 ≤ ε) (hkε : (1 - 2 * δ₀) ^ k ≤ 2 * ε ^ 2) {r : ℕ} (hr : δ₀ * 2 ^ n ≤ ↑r + 1) :
↑{g : BooleanFunction n | (1 / 2 + ε) * 2 ^ (k * n) ≤ ↑{x : BitString (k * n) | xorPower g k x = w x}.card}.card * (2 * ε ^ 2) ≤ ↑(∑ j ∈ Finset.range (r + 1), (2 ^ n).choose j)

The list size of the k-fold XOR code (library result): let k be odd, ε ≥ 0, and (1 - 2 δ₀) ^ k ≤ 2 ε ^ 2. The Boolean functions g on n bits whose k-fold XORs agree with a word w on at least a 1 / 2 + ε fraction of the inputs number at most V / (2 ε ^ 2), where V = ∑_{j ≤ r} C(2 ^ n, j) is the size of a Hamming ball of radius r among them, for any r ≥ δ₀ 2 ^ n - 1.

theorem Cslib.Circuits.Boolean.card_filter_xorPower_mul_two_mul_sq_le_exp {n k : ℕ} (hk : Odd k) (w : BitString (k * n) → Bool) {ε δ₀ : ℝ} (hε : 0 ≤ ε) (hδ₀ : 0 ≤ δ₀) (hδ₀' : δ₀ ≤ 1 / 2) (hkε : (1 - 2 * δ₀) ^ k ≤ 2 * ε ^ 2) :
↑{g : BooleanFunction n | (1 / 2 + ε) * 2 ^ (k * n) ≤ ↑{x : BitString (k * n) | xorPower g k x = w x}.card}.card * (2 * ε ^ 2) ≤ Real.exp (2 ^ n * Real.binEntropy δ₀)

The list size of the k-fold XOR code, entropy form (library result): let k be odd, ε ≥ 0, 0 ≤ δ₀ ≤ 1 / 2 and (1 - 2 δ₀) ^ k ≤ 2 ε ^ 2. The Boolean functions on n bits whose k-fold XORs agree with a word on at least a 1 / 2 + ε fraction of the inputs number at most exp (2 ^ n H(δ₀)) / (2 ε ^ 2), where H = Real.binEntropy is the binary entropy in nats; that is, 2 ^ (H₂(δ₀) 2 ^ n) / (2 ε ^ 2) for the binary entropy H₂ in bits.