Quantum Gilbert–Varshamov, quantum Hamming, and asymptotic rate bounds
OpenQAlgorithms.GottesmanIntro.codeBoundsAn code is a subspace of of dimension such that every operator acting on at most qubits satisfies for all unit vectors , with independent of (eq. (34)); that is, has distance at least . Put . The code is nondegenerate if, for every unit vector , the Gram matrix over the phase-free Pauli operators of weight at most is nonsingular. Let .
- (Quantum Gilbert–Varshamov bound.) If and
then an code exists. 2. (Quantum Hamming bound.) Every nondegenerate code satisfies
- (Asymptotic rates.) Let and . There is such that for every :
- every nondegenerate code with has ;
- if , there is a nondegenerate code with and .
The first two bounds are counting arguments. The third gives the rate window, eq. (37), between which the best nondegenerate codes lie.
Formalization Note The source's 'distance ' is read as distance at least , so existence is meaningful also for . The hypothesis excludes , where (36) is an empty sum and the claim would demand a -dimensional code for every . The asymptotic clause is read as an – statement. The lower rate bound is asserted only when it is positive.
import Definitions.Def_QAlgorithms_Defs_FTCircuit set_option autoImplicit false
namespace QAlgorithms.GottesmanIntro
open scoped Matrix
open QAlgorithms Stabilizer
/-- Gottesman intro p.7–8, Theorem 4. (1) Quantum Gilbert–Varshamov: if
`(∑_{j=0}^{d-1} 3^j C(n,j)) 2^k ≤ 2^n` (eq. (36)) and `d ≥ 1`, an `[[n, k, d]]` code exists.
(2) Quantum Hamming bound: every nondegenerate `[[n, k, d]]` code satisfies
`(∑_{j=0}^{t} 3^j C(n,j)) 2^k ≤ 2^n` (eq. (35)), `t = ⌊(d-1)/2⌋`. (3) Asymptotics (eq. (37)):
for fixed `p ∈ (0, 1/2)` and every `ε > 0`, for all large `n`, every nondegenerate `[[n, k, d]]`
code with `d ≥ 2pn` has `k/n ≤ 1 - p log₂ 3 - H(p) + ε`, and, when `1 - 2p log₂ 3 - H(2p) > 0`,
some nondegenerate `[[n, k, d]]` code with `d ≥ 2pn` has `k/n ≥ 1 - 2p log₂ 3 - H(2p) - ε`. -/
theorem codeBounds :
(∀ n k d : ℕ, 1 ≤ d →
(∑ j ∈ Finset.range d, 3 ^ j * n.choose j) * 2 ^ k ≤ 2 ^ n →
∃ C : Submodule ℂ (EuclideanSpace ℂ (Qubits n)), IsQCode n k d C) ∧
(∀ (n k d : ℕ) (C : Submodule ℂ (EuclideanSpace ℂ (Qubits n))), IsQCode n k d C →
IsNondegenerate C ((d - 1) / 2) →
(∑ j ∈ Finset.range ((d - 1) / 2 + 1), 3 ^ j * n.choose j) * 2 ^ k ≤ 2 ^ n) ∧
∀ p : ℝ, 0 < p → p < 1 / 2 → ∀ ε : ℝ, 0 < ε → ∃ N : ℕ, ∀ n ≥ N,
(∀ (k d : ℕ) (C : Submodule ℂ (EuclideanSpace ℂ (Qubits n))), IsQCode n k d C →
IsNondegenerate C ((d - 1) / 2) → 2 * p * n ≤ d →
(k : ℝ) / n ≤ 1 - p * Real.logb 2 3 - binEntropy2 p + ε) ∧
(0 < 1 - 2 * p * Real.logb 2 3 - binEntropy2 (2 * p) →
∃ (k d : ℕ) (C : Submodule ℂ (EuclideanSpace ℂ (Qubits n))), IsQCode n k d C ∧
IsNondegenerate C ((d - 1) / 2) ∧ 2 * p * n ≤ d ∧
1 - 2 * p * Real.logb 2 3 - binEntropy2 (2 * p) - ε ≤ (k : ℝ) / n) := by
sorry
end QAlgorithms.GottesmanIntro
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Codes. For , " is an code" means is a complex subspace of the -qubit space satisfying two conditions.
- .
- Every complex matrix acting on at most qubits is detectable, i.e. there is a constant with for all unit .
Two clarifications:
- Acting on few qubits. " acts on at most qubits" means for an arbitrary matrix placed on some set of at most wires, as in the previous entry.
- Truncated subtraction. is truncated, so behaves like . In that case only scalar multiples of the identity must be detected, which always holds.
The condition says "distance at least ". It does not say the distance is exactly .
Nondegeneracy. Write for the phase-free Pauli products () with at most non-identity factors. " is nondegenerate at " means: for every unit , the Gram matrix
has nonzero determinant. Equivalently, the vectors , , are linearly independent.
Notation.
- is the binary entropy in bits.
- uses truncated subtraction and floor division of natural numbers.
The theorem is a conjunction of three statements.
- Existence (Gilbert–Varshamov form). Let with . If
then some subspace is an code.
- Hamming bound. Let and . Every code that is nondegenerate at satisfies
-
Asymptotic rates. For every real with and every real , there exists such that every satisfies both (i) and (ii).
(i) Upper bound. For all and every code that is nondegenerate at and has :
(ii) Achievability. Suppose
Then there exist and an code that is nondegenerate at , has , and satisfies
Here is real division. If were allowed (i.e. ), evaluates to .
When , the term is evaluated by the same total formula: and, for , logarithms of negative arguments are taken as . However, holds here because .
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.