Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Theorem 1 — Rank-sensitive distance lower bound

Proved
ZengPryadko2019.tensorProductDistance_lowerBound

by Rui Chao · Sep 10, 2026 · Mathlib 0df444a (Lean v4.33.1)

chaincomplexescodingtheoryhomologicalalgebraquantumerrorcorrectiontensorproducts

Let A\mathcal AA be a finite based binary chain complex, and let PPP be an r×cr\times cr×c binary matrix of rank uuu. Write δ=d1(K(P))\delta=d_1(\mathcal K(P))δ=d1​(K(P)), taking δ=∞\delta=\inftyδ=∞ when the kernel of PPP is trivial. Then the degree-jjj distance dj′=dj(A×K(P))d'_j=d_j(\mathcal A\times \mathcal K(P))dj′​=dj​(A×K(P)) satisfies both rank cases of Zeng--Pryadko's Theorem 1:

u<r⟹dj′≥min⁡ ⁣(dj(A),dj−1(A)δ),u<r\quad\Longrightarrow\quad d'_j\ge\min\!\left(d_j(\mathcal A),d_{j-1}(\mathcal A)\delta\right),u<r⟹dj′​≥min(dj​(A),dj−1​(A)δ),

and

u=r⟹dj′≥dj−1(A)δ.u=r\quad\Longrightarrow\quad d'_j\ge d_{j-1}(\mathcal A)\delta.u=r⟹dj′​≥dj−1​(A)δ.

The formal statement expresses uuu as the dimension of the range of the linear map PPP and rrr as the cardinality of its row-coordinate type. Empty endpoint chain groups and infinite component distances are included. At j=0j=0j=0, the predecessor distance d−1(A)d_{-1}(\mathcal A)d−1​(A) is interpreted as ∞\infty∞, matching the absent negative-degree group.

Preamble
import Definitions.Def_ZengPryadko2019
Formal statement

namespace ZengPryadko2019

/--
Theorem 1 of Zeng--Pryadko.  The first implication is the non-full-row-rank
case `u < r`; the second is the full-row-rank case `u = r`.  Here
`chainDistanceAt (oneComplex P) 1` is the paper's `δ`.
-/
theorem tensorProductDistance_lowerBound
    (A : BasedBinaryChainComplex) {r c : ℕ}
    (P : BinaryWord (Fin c) →ₗ[ZMod 2] BinaryWord (Fin r)) (j : ℕ) :
    ((Module.finrank (ZMod 2) (LinearMap.range P) < r) →
        min (chainDistanceAt A j)
            (chainDistanceBefore A j * chainDistanceAt (oneComplex P) 1) ≤
          tensorProductDistanceAt A (oneComplex P) j) ∧
      ((Module.finrank (ZMod 2) (LinearMap.range P) = r) →
        chainDistanceBefore A j * chainDistanceAt (oneComplex P) 1 ≤
          tensorProductDistanceAt A (oneComplex P) j) := by
  sorry

end ZengPryadko2019
Source
Weilei Zeng and Leonid P. Pryadko, Higher-dimensional quantum hypergraph-product codes, arXiv:1810.01519v2, Theorem 1, https://arxiv.org/abs/1810.01519
Read-back

What the Lean code literally says, in plain math · gpt-5.6-sol

For every based binary chain complex AAA, every pair of natural numbers r,cr,cr,c (although implicit in the notation, both are universally quantified), every F2\mathbb F_2F2​-linear map P:F2c→F2rP:\mathbb F_2^c\to\mathbb F_2^rP:F2c​→F2r​, and every natural-number degree jjj, let E=E(P)E=\mathcal E(P)E=E(P), let ρ=dim⁡F2(range⁡P)\rho=\dim_{\mathbb F_2}(\operatorname{range}P)ρ=dimF2​​(rangeP), let dk(A)d_k(A)dk​(A) denote the degree-kkk distance defined below, let dj−(A)=⊤d_j^-(A)=\topdj−​(A)=⊤ when j=0j=0j=0 and dj−(A)=dj−1(A)d_j^-(A)=d_{j-1}(A)dj−​(A)=dj−1​(A) when j≥1j\ge1j≥1, let δ=d1(E)\delta=d_1(E)δ=d1​(E), and let Dj=dj(A⊗E)D_j=d_j(A\otimes E)Dj​=dj​(A⊗E) be the tensor-product distance defined below. The theorem asserts the conjunction of the following two implications, with no unconditional rank hypothesis:

(ρ<r ⟹ min⁡{dj(A), dj−(A) δ}≤Dj)∧(ρ=r ⟹ dj−(A) δ≤Dj).\bigl(\rho<r\ \Longrightarrow\ \min\{d_j(A),\ d_j^-(A)\,\delta\}\le D_j\bigr) \quad\land\quad \bigl(\rho=r\ \Longrightarrow\ d_j^-(A)\,\delta\le D_j\bigr).(ρ<r ⟹ min{dj​(A), dj−​(A)δ}≤Dj​)∧(ρ=r ⟹ dj−​(A)δ≤Dj​).

A binary word on a coordinate type III is a function I→Z/2ZI\to\mathbb Z/2\mathbb ZI→Z/2Z. The complex AAA supplies a natural-number dimension aka_kak​ in every nonnegative degree, the standard-coordinate binary vector space Ak=F2akA_k=\mathbb F_2^{a_k}Ak​=F2ak​​, and for every k∈Nk\in\mathbb Nk∈N a linear boundary

∂kA:Ak⟶{0,k=0,Ak−1,k≥1,\partial_k^A:A_k\longrightarrow \begin{cases} 0,&k=0,\\ A_{k-1},&k\ge1, \end{cases}∂kA​:Ak​⟶{0,Ak−1​,​k=0,k≥1,​

where the degree-zero target is represented by words on the empty coordinate type. It also supplies the identities ∂kA∂k+1A=0\partial_k^A\partial_{k+1}^A=0∂kA​∂k+1A​=0 for all kkk, a natural number LLL, and the condition ak=0a_k=0ak​=0 whenever L<kL<kL<k. The number LLL is only required to be an upper bound on the support of the dimensions: it need not be minimal, and neither aLa_LaL​ nor any lower-degree dimension is required to be positive.

For linear maps d:F2I→F2Kd:\mathbb F_2^I\to\mathbb F_2^Kd:F2I​→F2K​ and dnext:F2M→F2Id_{\mathrm{next}}:\mathbb F_2^M\to\mathbb F_2^Idnext​:F2M​→F2I​, where III is finite with decidable equality, their homological distance is

inf⁡{wt⁡(x):x∈F2I, d(x)=0, x∉range⁡(dnext)}∈N∪{⊤},\inf\bigl\{\operatorname{wt}(x):x\in\mathbb F_2^I,\ d(x)=0,\ x\notin\operatorname{range}(d_{\mathrm{next}})\bigr\} \in\mathbb N\cup\{\top\},inf{wt(x):x∈F2I​, d(x)=0, x∈/range(dnext​)}∈N∪{⊤},

with wt⁡(x)=#{i∈I:xi≠0}\operatorname{wt}(x)=\#\{i\in I:x_i\ne0\}wt(x)=#{i∈I:xi​=0}. More literally, the set whose infimum is taken consists of extended natural numbers www for which there exists such an xxx and www equals the natural Hamming weight of xxx embedded into N∪{⊤}\mathbb N\cup\{\top\}N∪{⊤}. Its infimum is ⊤\top⊤ if there is no such xxx. Since zero lies in the range of every linear map, every admissible xxx is nonzero, so every finite value of this distance is a positive natural number and the value is never 000. The component distance used in the theorem is exactly

dk(A)=inf⁡{wt⁡(x):x∈Ak, ∂kAx=0, x∉im⁡∂k+1A}.d_k(A)=\inf\bigl\{\operatorname{wt}(x):x\in A_k,\ \partial_k^A x=0,\ x\notin\operatorname{im}\partial_{k+1}^A\bigr\}.dk​(A)=inf{wt(x):x∈Ak​, ∂kA​x=0, x∈/im∂k+1A​}.

Thus d0(A)d_0(A)d0​(A) minimizes over A0∖im⁡∂1AA_0\setminus\operatorname{im}\partial_1^AA0​∖im∂1A​, because ∂0A\partial_0^A∂0A​ is necessarily the zero map into the zero-dimensional target, while for k≥1k\ge1k≥1 it minimizes over ker⁡∂kA∖im⁡∂k+1A\ker\partial_k^A\setminus\operatorname{im}\partial_{k+1}^Aker∂kA​∖im∂k+1A​. If this difference is empty, including whenever the corresponding homology is trivial or AkA_kAk​ is the zero space, then dk(A)=⊤d_k(A)=\topdk​(A)=⊤.

The one-complex E=E(P)E=\mathcal E(P)E=E(P) has E0=F2rE_0=\mathbb F_2^rE0​=F2r​, E1=F2cE_1=\mathbb F_2^cE1​=F2c​, Ek=0E_k=0Ek​=0 for k≥2k\ge2k≥2, boundaries ∂0E=0\partial_0^E=0∂0E​=0, ∂1E=P\partial_1^E=P∂1E​=P, and ∂kE=0\partial_k^E=0∂kE​=0 for k≥2k\ge2k≥2, and declared length 111. Consequently, the sole distance from EEE that occurs in the theorem is

δ=d1(E)=inf⁡{wt⁡(x):x∈F2c, Px=0, x≠0}.\delta=d_1(E) =\inf\bigl\{\operatorname{wt}(x):x\in\mathbb F_2^c,\ P x=0,\ x\ne0\bigr\}.δ=d1​(E)=inf{wt(x):x∈F2c​, Px=0, x=0}.

The condition x≠0x\ne0x=0 here is exactly the condition that xxx not lie in the range of the zero boundary ∂2E\partial_2^E∂2E​. Hence δ=⊤\delta=\topδ=⊤ precisely when PPP is injective, including when c=0c=0c=0; otherwise δ\deltaδ is the least positive Hamming weight of a nonzero vector in ker⁡P\ker PkerP.

The degree-kkk tensor coordinate type used to define DkD_kDk​ is the disjoint union, over all ordered pairs of nonnegative integers (p,q)(p,q)(p,q) satisfying p+q=kp+q=kp+q=k, of

Fin⁡(ap)×Fin⁡(dim⁡Eq).\operatorname{Fin}(a_p)\times\operatorname{Fin}(\dim E_q).Fin(ap​)×Fin(dimEq​).

The pair (p,q)(p,q)(p,q) is represented by two elements of Fin⁡(k+1)\operatorname{Fin}(k+1)Fin(k+1) together with the proof that their natural-number values sum to kkk; thus all and only the decompositions p+q=kp+q=kp+q=k occur, including the endpoints (0,k)(0,k)(0,k) and (k,0)(k,0)(k,0). For E=E(P)E=\mathcal E(P)E=E(P), only q=0q=0q=0 and q=1q=1q=1 can contribute coordinates. Therefore tensor degree 000 has the component A0⊗F2rA_0\otimes\mathbb F_2^rA0​⊗F2r​, while tensor degree k≥1k\ge1k≥1 has the two potentially nonempty components Ak⊗F2rA_k\otimes\mathbb F_2^rAk​⊗F2r​ and Ak−1⊗F2cA_{k-1}\otimes\mathbb F_2^cAk−1​⊗F2c​; a component is actually empty whenever one of its displayed dimensions is zero.

The tensor boundary in degree 000 is the zero map from tensor degree 000 to the zero-dimensional space. For k≥1k\ge1k≥1, take an output coordinate in tensor degree k−1k-1k−1 described by p+q=k−1p+q=k-1p+q=k−1, a∈Fin⁡(ap)a\in\operatorname{Fin}(a_p)a∈Fin(ap​), and b∈Fin⁡(dim⁡Eq)b\in\operatorname{Fin}(\dim E_q)b∈Fin(dimEq​). For a tensor word eee in degree kkk, the value of its boundary at that coordinate is defined exactly by

(∂k⊗e)p,q,a,b=(∂p+1A(a′↦ep+1,q,a′,b))a+(∂q+1E(b′↦ep,q+1,a,b′))b,(\partial_k^{\otimes}e)_{p,q,a,b} = \left(\partial_{p+1}^A\bigl(a'\mapsto e_{p+1,q,a',b}\bigr)\right)_a + \left(\partial_{q+1}^E\bigl(b'\mapsto e_{p,q+1,a,b'}\bigr)\right)_b,(∂k⊗​e)p,q,a,b​=(∂p+1A​(a′↦ep+1,q,a′,b​))a​+(∂q+1E​(b′↦ep,q+1,a,b′​))b​,

with addition in F2\mathbb F_2F2​. In particular, on the output component with q=0q=0q=0, the second summand applies ∂1E=P\partial_1^E=P∂1E​=P to the input component Ap⊗E1A_p\otimes E_1Ap​⊗E1​, while on the output component with q=1q=1q=1 the second summand applies the zero map ∂2E\partial_2^E∂2E​; the first summand always uses the boundary ∂p+1A:Ap+1→Ap\partial_{p+1}^A:A_{p+1}\to A_p∂p+1A​:Ap+1​→Ap​. The coordinate injections on the two input slices increase respectively the left degree from (p,q)(p,q)(p,q) to (p+1,q)(p+1,q)(p+1,q) and the right degree from (p,q)(p,q)(p,q) to (p,q+1)(p,q+1)(p,q+1). Consecutive tensor boundaries compose to zero. The tensor-product distance in the theorem is then

Dj=inf⁡{wt⁡(e):e is a word on the degree-j tensor coordinates, ∂j⊗e=0, e∉im⁡∂j+1⊗},D_j =\inf\bigl\{\operatorname{wt}(e):e\text{ is a word on the degree-}j\text{ tensor coordinates},\ \partial_j^{\otimes}e=0,\ e\notin\operatorname{im}\partial_{j+1}^{\otimes}\bigr\},Dj​=inf{wt(e):e is a word on the degree-j tensor coordinates, ∂j⊗​e=0, e∈/im∂j+1⊗​},

again with value ⊤\top⊤ when this witness set is empty. At j=0j=0j=0, the cycle condition is automatic because ∂0⊗=0\partial_0^{\otimes}=0∂0⊗​=0, and only nonmembership in im⁡∂1⊗\operatorname{im}\partial_1^{\otimes}im∂1⊗​ remains.

All inequalities, products, minima, and infima in the theorem are in N∪{⊤}\mathbb N\cup\{\top\}N∪{⊤}. A finite distance factor is positive; therefore a product of the displayed distance factors is finite exactly when both factors are finite, and it is ⊤\top⊤ when either factor is ⊤\top⊤. Formally, multiplication by 000 would make a product 000 even in the presence of ⊤\top⊤, but none of these distance factors can equal 000. A lower bound of ⊤≤Dj\top\le D_j⊤≤Dj​ is equivalent to Dj=⊤D_j=\topDj​=⊤, whereas every finite value is automatically at most ⊤\top⊤.

The endpoint j=0j=0j=0 is included. Since d0−(A)=⊤d_0^-(A)=\topd0−​(A)=⊤ and δ\deltaδ is nonzero, d0−(A)δ=⊤d_0^-(A)\delta=\topd0−​(A)δ=⊤. Thus the first implication specializes literally to

ρ<r ⟹ d0(A)≤D0,\rho<r\ \Longrightarrow\ d_0(A)\le D_0,ρ<r ⟹ d0​(A)≤D0​,

because min⁡{d0(A),⊤}=d0(A)\min\{d_0(A),\top\}=d_0(A)min{d0​(A),⊤}=d0​(A), while the second specializes to

ρ=r ⟹ ⊤≤D0,\rho=r\ \Longrightarrow\ \top\le D_0,ρ=r ⟹ ⊤≤D0​,

which forces D0=⊤D_0=\topD0​=⊤. For j≥1j\ge1j≥1, the shifted quantity is exactly dj−(A)=dj−1(A)d_j^-(A)=d_{j-1}(A)dj−​(A)=dj−1​(A), so the two implications become

ρ<r ⟹ min⁡{dj(A), dj−1(A)δ}≤Dj,ρ=r ⟹ dj−1(A)δ≤Dj.\rho<r\ \Longrightarrow\ \min\{d_j(A),\ d_{j-1}(A)\delta\}\le D_j, \qquad \rho=r\ \Longrightarrow\ d_{j-1}(A)\delta\le D_j.ρ<r ⟹ min{dj​(A), dj−1​(A)δ}≤Dj​,ρ=r ⟹ dj−1​(A)δ≤Dj​.

The rank ρ\rhoρ is specifically the finite module rank of the range subspace of PPP over F2\mathbb F_2F2​, not an additional integer supplied as data. Since that range is a subspace of F2r\mathbb F_2^rF2r​, one has ρ≤r\rho\le rρ≤r: the two antecedents ρ<r\rho<rρ<r and ρ=r\rho=rρ=r are mutually exclusive and exhaust the possible ranks, although the theorem presents them as two separate implications joined by conjunction. If an antecedent is false, its implication is vacuously true and imposes no bound. The first antecedent says that the range is a proper subspace of the codomain; the second says that the range has the full codomain dimension. No relation between rrr and ccc is assumed. In particular, if r>cr>cr>c, then ρ=r\rho=rρ=r is impossible and the second implication is vacuous; if r=0r=0r=0, then ρ<r\rho<rρ<r is impossible, ρ=r=0\rho=r=0ρ=r=0 automatically, and only the second implication is substantive. If c=0<rc=0<rc=0<r, then ρ=0<r\rho=0<rρ=0<r and δ=⊤\delta=\topδ=⊤, so the first implication reduces to dj(A)≤Djd_j(A)\le D_jdj​(A)≤Dj​ for every jjj. If r=c=0r=c=0r=c=0, then the second antecedent holds and δ=⊤\delta=\topδ=⊤, so its lower bound forces Dj=⊤D_j=\topDj​=⊤ for every jjj.

No hypothesis requires jjj to lie at or below the declared length of AAA, requires LLL to be positive or minimal, requires any coordinate set or chain group to be nonempty, requires any homology group or distance to be finite, constrains the ranks of the boundaries of AAA, or assumes that PPP is injective, surjective, square, nonzero, or of a prescribed rank. The rank conditions occur only as the antecedents of the two implications. If j>L+1j>L+1j>L+1, both potentially nonempty tensor components use Aj=0A_j=0Aj​=0 or Aj−1=0A_{j-1}=0Aj−1​=0, so the degree-jjj tensor coordinate type is empty and Dj=⊤D_j=\topDj​=⊤; also dj(A)=dj−(A)=⊤d_j(A)=d_j^-(A)=\topdj​(A)=dj−​(A)=⊤, so either active rank implication has lower bound ⊤\top⊤. The conclusion is therefore still an assertion in these out-of-range and all other degenerate cases, with false rank antecedents producing vacuous implications and empty homological witness sets producing the value ⊤\top⊤.

Human review
  • Endorsed by Shuze Chen · Sep 11, 2026

  • Endorsed by Rui Chao · Sep 11, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me