Documentation

CslibFrontier.Computability.PolyTime.BitString.SmallBias

Uniform polynomial-time construction of small-bias families #

This is a construction milestone for the amplifying reduction in [Goldreich2007DraftR5, Exercise 10.6], not the gap-hardness result. The quadratic-system reduction and its violation-gap proof are separate objectives.

Given a width n and a positive reciprocal-error parameter k, use the explicit binary field of degree w = floor(log₂(max 1 (n*k))) + 1. Its size exceeds n*k and is at most 2*(n*k+1). Enumerating all pairs of field elements and applying the AGHP powering construction gives at most 4*(n*k+1)^2 masks, each of width n, with bias at most 1/k.

The constructor includes trial-division search for the irreducible modulus, construction of its multiplication table and every coordinate multiplication. Its inputs n,k are unary; the polynomial-time certificate is uniform in both parameters. There is no advice table or caller-supplied field operation.

Main definitions #

Main results #

References #

A power in coordinates, starting at the unit and multiplying i times by x.

Evaluate the powering construction using a multiplication table. Coordinates are padded to its degree before taking the inner product.

@[simp]
theorem Cslib.BitString.length_poweringWord (tab : List (List (List Bool))) (n : ℕ) (x y : List Bool) :
(poweringWord tab n x y).length = n

The executable evaluator agrees with the abstract powering map on every seed.

The positive field degree used for width n and reciprocal error k.

Enumerate the powering masks in binary seed order; repetitions are retained.

theorem Cslib.BitString.poweringMasks_size (n k : ℕ) :
(poweringMasks n k).length = (2 ^ smallBiasDegree n k) ^ 2 ∧ (poweringMasks n k).length ≤ 4 * (n * k + 1) ^ 2 ∧ ∀ row ∈ poweringMasks n k, row.length = n

The table has polynomial size and every mask has the requested width.

The coordinate evaluator is polynomial-time, uniformly in the table and all inputs.

The entire mask table is constructed in uniform polynomial time on unary (n,k). The certificate includes the exhaustive modulus search, its trial divisions, the multiplication table and all powering evaluations.

Under a uniform seed pair, the explicitly evaluated family is 1/k-biased. The uniform seed order is exactly the double enumeration used by poweringMasks.

The uniform distribution on the entries of the constructed mask list is 1/k-biased. Repeated masks are counted with their multiplicities.