Locally testable codes
AbbreviationBinary code#βfully proved
A binary code of length \(n\) is a linear subspace of \(\mathbb{F}_2^n\), the vector space of words of length \(n\) over the two-element field \(\mathbb{F}_2\).
Used by 9
DefinitionDimension of a binary code#βfully proved
The dimension of a binary code \(C \subseteq \mathbb{F}_2^n\) is its dimension as a vector space over \(\mathbb{F}_2\).
noncomputable def dim : β := Module.finrank (ZMod 2) C
Uses 1 Β· Used by 1
DefinitionRate of a binary code#βfully proved
The rate of a binary code \(C \subseteq \mathbb{F}_2^n\) is its dimension over \(\mathbb{F}_2\) divided by its length \(n\), as a real number; it is \(0\) when \(n = 0\).
noncomputable def rate : β := dim C / n
noncomputable def dim : β := Module.finrank (ZMod 2) C
WantedExt/Combinatorics/GoodLTCodesWanted.lean:69
Uses 2 Β· Used by 2
DefinitionMinimum distance of a binary code#βfully proved
The distance of a binary code \(C \subseteq \mathbb{F}_2^n\) is the smallest Hamming weight (number of nonzero coordinates) of a nonzero codeword of \(C\), and is \(0\) if \(C = \{0\}\).
When \(C \neq \{0\}\), since \(C\) is linear, this is the minimum Hamming distance between two distinct codewords.
noncomputable def distance : β :=
sInf {d | β c β C, c β 0 β§ hammingNorm c = d}
Uses 1 Β· Used by 1
DefinitionNormalised distance of a binary code#βfully proved
The normalised distance of a binary code \(C \subseteq \mathbb{F}_2^n\) is its distance divided by its length \(n\), as a real number; it is \(0\) when \(n = 0\).
noncomputable def normalisedDistance : β := distance C / n
noncomputable def distance : β :=
sInf {d | β c β C, c β 0 β§ hammingNorm c = d}
WantedExt/Combinatorics/GoodLTCodesWanted.lean:76
Uses 2 Β· Used by 1
DefinitionDistance from a word to a binary code#βfully proved
For a binary code \(C \subseteq \mathbb{F}_2^n\) and a word \(f \in \mathbb{F}_2^n\), the distance from \(f\) to \(C\) is the minimum, over all codewords \(c \in C\), of the Hamming distance between \(f\) and \(c\), that is, the number of coordinates in which \(f\) and \(c\) differ.
noncomputable def distanceFrom (f : π½ββΏ) : β :=
sInf {d | β c β C, hammingNorm (f - c) = d}
Uses 1 Β· Used by 1
DefinitionNormalised distance from a word to a binary code#βfully proved
For a binary code \(C \subseteq \mathbb{F}_2^n\) and a word \(f \in \mathbb{F}_2^n\), the normalised distance from \(f\) to \(C\) is the distance from \(f\) to \(C\) (the Hamming distance from \(f\) to a closest codeword) divided by the length \(n\), as a nonnegative real number; it is \(0\) when \(n = 0\).
noncomputable def normalisedDistanceFrom (f : π½ββΏ) : ββ₯0 := β¨distanceFrom C f / n, by positivityβ©
noncomputable def distanceFrom (f : π½ββΏ) : β :=
sInf {d | β c β C, hammingNorm (f - c) = d}
WantedExt/Combinatorics/GoodLTCodesWanted.lean:84
Uses 2 Β· Used by 1
DefinitionGood family of codes#βfully proved
Let \((n_i)_{i \in \mathbb{N}}\) be natural numbers and, for each \(i\), let \(C_i \subseteq \mathbb{F}_2^{n_i}\) be a binary code of length \(n_i\). The family \((C_i)\) is good if \(n_i \to \infty\) as \(i \to \infty\) and there is a real number \(\varepsilon > 0\) such that for every \(i\) both the rate and the normalised distance of \(C_i\) are at least \(\varepsilon\).
def IsGood {n : β β β} (π : (i : β) β BinaryCode (n i)) : Prop :=
Filter.Tendsto n Filter.atTop Filter.atTop β§
β Ξ΅ > 0, β i, Ξ΅ β€ rate (π i) β§ Ξ΅ β€ normalisedDistance (π i)
abbrev BinaryCode : Type := Submodule (ZMod 2) π½ββΏ
WantedExt/Combinatorics/GoodLTCodesWanted.lean:64
noncomputable def rate : β := dim C / n
WantedExt/Combinatorics/GoodLTCodesWanted.lean:72
noncomputable def normalisedDistance : β := distance C / n
WantedExt/Combinatorics/GoodLTCodesWanted.lean:80
Uses 3 Β· Used by 1
AbbreviationSubsets with at most \(q\) elements#βfully proved
For natural numbers \(n\) and \(q\), this is the collection of all subsets \(S \subseteq \{0, 1, \dots, n - 1\}\) with at most \(q\) elements.
Used by 1
StructureLocally testable code#βfully proved
Let \(C \subseteq \mathbb{F}_2^n\) be a binary code, let \(q\) be a natural number and let \(\kappa \ge 0\) be a real number. A \(\kappa\)-local tester for \(C\) with \(q\) queries consists of a probability distribution on the subsets \(S \subseteq \{0, 1, \dots, n - 1\}\) with at most \(q\) elements, together with, for each such \(S\), a set \(V_S \subseteq \mathbb{F}_2^S\) of allowed local views, such that: * if \(f \in C\), then \(f|_S \in V_S\) for every such \(S\); * for every \(f \in \mathbb{F}_2^n\), the probability that \(f|_S \notin V_S\) for a random \(S\) is at least \(\kappa\) times the normalised distance from \(f\) to \(C\).
The code \(C\) is \(\kappa\)-locally testable with \(q\) queries exactly when such a tester exists.
structure LTC (q : β) (ΞΊ : ββ₯0) (C : BinaryCode n) where
/-- The probability distribution on the collection of `q`-element (or less) subsets of `Fin n`. -/
prob : PMF (cardLE n q)
/-- The set `V_S β π½β^S` of allowed local views associated to a given subset `S β Fin n`. -/
views (S : cardLE n q) : Set (S.val β ZMod 2)
cond1 (f : π½ββΏ) (hf : f β C) (S : cardLE n q) : Set.domRestrict S f β views S
cond2 (f : π½ββΏ) :
prob.toMeasure {S | Set.domRestrict S f β views S} β₯ ΞΊ * normalisedDistanceFrom C f
abbrev BinaryCode : Type := Submodule (ZMod 2) π½ββΏ
WantedExt/Combinatorics/GoodLTCodesWanted.lean:64
abbrev cardLE (q : β) : Type :=
{S : Set (Fin n) // S.ncard β€ q}
WantedExt/Combinatorics/GoodLTCodesWanted.lean:99
views (S : cardLE n q) : Set (S.val β ZMod 2)
WantedExt/Combinatorics/GoodLTCodesWanted.lean:115
prob : PMF (cardLE n q)
WantedExt/Combinatorics/GoodLTCodesWanted.lean:113
noncomputable def normalisedDistanceFrom (f : π½ββΏ) : ββ₯0 := β¨distanceFrom C f / n, by positivityβ©
WantedExt/Combinatorics/GoodLTCodesWanted.lean:89
Sources
- Definition 2.3 in
Locally Testable Codes with constant rate, distance, and localityby I. Dinur, S. Evra, R. Livne, A. Lubotzky and S. Mozes. This probability distribution formulation is also mentioned immediately after Definition 1.1 in the original paperGood Locally Testable Codes.
Uses 3 Β· Used by 1
TheoremGood locally testable codes of every rate below one#βready to prove
For every real number \(\rho\) with \(0 \le \rho < 1\) there exist a natural number \(q\), a real number \(\kappa > 0\), lengths \(n_i \in \mathbb{N}\) and binary codes \(C_i\) of length \(n_i\) for \(i \in \mathbb{N}\) such that the family \((C_i)_{i \in \mathbb{N}}\) is good and, for every \(i\), the code \(C_i\) is \(\kappa\)-locally testable with \(q\) queries and has rate at least \(\rho\).
The source's theorem also asserts that the codes are explicit; explicitness is not part of this statement.
public theorem_wanted theorem_1_2 (Ο : ββ₯0) (hΟ : Ο < 1) :
β q, β ΞΊ β 0, β (n : β β β), β (π : (i : β) β BinaryCode (n i)), IsGood π β§
β i, Nonempty (LTC q ΞΊ (π i)) β§ rate (π i) β₯ Ο
abbrev BinaryCode : Type := Submodule (ZMod 2) π½ββΏ
WantedExt/Combinatorics/GoodLTCodesWanted.lean:64
def IsGood {n : β β β} (π : (i : β) β BinaryCode (n i)) : Prop :=
Filter.Tendsto n Filter.atTop Filter.atTop β§
β Ξ΅ > 0, β i, Ξ΅ β€ rate (π i) β§ Ξ΅ β€ normalisedDistance (π i)
WantedExt/Combinatorics/GoodLTCodesWanted.lean:93
structure LTC (q : β) (ΞΊ : ββ₯0) (C : BinaryCode n) where
/-- The probability distribution on the collection of `q`-element (or less) subsets of `Fin n`. -/
prob : PMF (cardLE n q)
/-- The set `V_S β π½β^S` of allowed local views associated to a given subset `S β Fin n`. -/
views (S : cardLE n q) : Set (S.val β ZMod 2)
cond1 (f : π½ββΏ) (hf : f β C) (S : cardLE n q) : Set.domRestrict S f β views S
cond2 (f : π½ββΏ) :
prob.toMeasure {S | Set.domRestrict S f β views S} β₯ ΞΊ * normalisedDistanceFrom C f
WantedExt/Combinatorics/GoodLTCodesWanted.lean:111
noncomputable def rate : β := dim C / n
WantedExt/Combinatorics/GoodLTCodesWanted.lean:72
Sources
- I. Dinur, S. Evra, R. Livne, A. Lubotzky, and S. Mozes,
Good Locally Testable Codes, Annals of Math, 203 (2) 2026. Statement taken from https://github.com/ImperialCollegeLondon/AnnalsChallenge. Problemannals_good_lt_codesof the lean-eval benchmark.
Uses 4
Loading dependency explorerβ¦
The dependency explorer needs JavaScript and its graph data.