Fixed-alphabet families, linear yield and physical circuit depth
DefinitionQuantumCupGates644_ConstantWeight_Supplement_familiesA finite alphabet is a field of size p^u for a positive exponent u, fixed for the entire family. A quantum family stores its lengths, r-tuples of published CSS subsystem carriers, and executable decoders. All parameter assertions are separate. Unbounded lengths means that for every L all sufficiently late family lengths are at least L.
The formal-family predicate requires positive length, valid subsystems, protected dimension and logical yield at least c_K N, both distances at least c_D N^{1/r}, separate source locality and gate sparsity at most N^ε, and strict-radius c_ρ N^{1/r} decoding within one polynomial clock for all lengths and inputs.
The headline-family predicate additionally specifies an actual physical gate schedule of depth at most N^ε, for the same form that has the required logical phase action, and inclusive adversarial correction at its own positive constant. Schedule layers separate any two nonzero gates sharing a qudit. The constants and the fixed field are controlled by the theorem's quantifiers, not by definition fields that assume existence.
import Definitions.Def_QuantumCupGates644_ConstantWeight_Supplement_cup
import Definitions.Def_QuantumCupGates644_ConstantWeight_Supplement_decoder
noncomputable section
namespace QuantumCupGates644.ConstantWeight.Supplement
open scoped BigOperators
open Classical
/-- A fixed finite field for a whole family. Its exponent is positive;
no family index appears in the alphabet. -/
structure FiniteAlphabet (p : ℕ) [Fact p.Prime] where
F : Type
[field : Field F]
[finite : Fintype F]
[algebra : Algebra (ZMod p) F]
exponent : ℕ
positive : 0 < exponent
size : Nat.card F = p ^ exponent
attribute [instance] FiniteAlphabet.field FiniteAlphabet.finite FiniteAlphabet.algebra
/-- Code and executable-decoder data, with all parameter guarantees separate. -/
structure QuantumFamily {p : ℕ} [Fact p.Prime] (A : FiniteAlphabet p) (r : ℕ) where
length : ℕ → ℕ
code : (m : ℕ) → Fin r → CSSSubsystem A.F (length m)
decoder : ℕ → Fin r → DecoderProgram A.F
def UnboundedLengths (N : ℕ → ℕ) : Prop :=
∀ L : ℕ, ∃ m₀ : ℕ, ∀ m ≥ m₀, L ≤ N m
/-- A physical circuit schedule: nonzero coefficient gates sharing a
physical coordinate must occupy different layers. -/
def ScheduleDepth {F : Type} [Field F] {r n : ℕ} (f : GateForm F r n) (D : ℕ) : Prop :=
∃ color : {a : Fin r → Fin n // f (basisWords a) ≠ 0} → Fin D,
∀ a b, color a = color b → (∃ i, a.val i = b.val i) → a = b
/-- Logical yield and actual physical depth for the SAME physical form. -/
def SupportsDepthGate {F : Type} [Field F] [Fintype F] (p : ℕ)
[Fact p.Prime] [Algebra (ZMod p) F] {r n : ℕ}
(Q : Fin r → CSSSubsystem F n) (D s : ℕ) : Prop :=
∃ (f : GateForm F r n) (v : Fin r → Fin s → Fin n → F),
ScheduleDepth f D ∧ f.CohomologyInvariant Q ∧
(∀ i l, v i l ∈ (Q i).LZ) ∧
(∀ i, LinearIndependent F (fun l => (dual (Q i).QX).mkQ (v i l))) ∧
(∀ l : Fin r → Fin s,
f (fun i => v i (l i)) = if ∀ i j, l i = l j then 1 else 0) ∧
∀ (y : Fin r → Fin s → F) (x : Fin r → Fin n → F),
physicalPhase p f x * encodedAmplitude Q v y x =
fieldPhase p (∑ l, ∏ i, y i l) * encodedAmplitude Q v y x
/-- Full formal family of Corollary 5.3. Constants are arguments, so their
placement before primes and family indices is controlled by the theorem.
The displayed real-power locality and sparsity bounds have coefficient one. -/
def FormalLinearYieldFamily {p : ℕ} [Fact p.Prime] {r : ℕ}
(A : FiniteAlphabet p) (ε cK cD cρ : ℝ) : Prop :=
∃ C : QuantumFamily A r, UnboundedLengths C.length ∧
∃ timeConstant timeExponent : ℕ, 0 < timeConstant ∧ 0 < timeExponent ∧
∀ m : ℕ, 0 < C.length m ∧
(∀ i : Fin r,
(C.code m i).Valid ∧
cK * (C.length m : ℝ) ≤ (C.code m i).logicalDimension ∧
(C.code m i).XDistanceAtLeast (cD * (C.length m : ℝ) ^ (1/(r : ℝ))) ∧
(C.code m i).ZDistanceAtLeast (cD * (C.length m : ℝ) ^ (1/(r : ℝ))) ∧
HasSourceLocality (C.code m i) ((C.length m : ℝ)^ε) ∧
(C.decoder m i).Decodes (C.code m i)
(cρ * (C.length m : ℝ) ^ (1/(r : ℝ)))
(timeConstant * (C.length m)^timeExponent)) ∧
∃ w s : ℕ, (w : ℝ) ≤ (C.length m : ℝ)^ε ∧
cK * (C.length m : ℝ) ≤ (s : ℝ) ∧ SupportsGate p (C.code m) w s
/-- Theorem 1.2, including every target alphabet, physical depth and
inclusive adversarial error correction (using its own smaller Ω constant). -/
def HeadlineLinearYieldFamily {p : ℕ} [Fact p.Prime] {r : ℕ}
(A : FiniteAlphabet p) (ε : ℝ) : Prop :=
∃ cK cD cρ : ℝ, 0 < cK ∧ 0 < cD ∧ 0 < cρ ∧
∃ C : QuantumFamily A r, UnboundedLengths C.length ∧
∃ timeConstant timeExponent : ℕ, 0 < timeConstant ∧ 0 < timeExponent ∧
∀ m : ℕ, 0 < C.length m ∧
(∀ i : Fin r,
(C.code m i).Valid ∧
cK * (C.length m : ℝ) ≤ (C.code m i).logicalDimension ∧
(C.code m i).XDistanceAtLeast (cD * (C.length m : ℝ)^(1/(r : ℝ))) ∧
(C.code m i).ZDistanceAtLeast (cD * (C.length m : ℝ)^(1/(r : ℝ))) ∧
HasSourceLocality (C.code m i) ((C.length m : ℝ)^ε) ∧
(C.decoder m i).Decodes (C.code m i)
(cρ * (C.length m : ℝ)^(1/(r : ℝ)))
(timeConstant * (C.length m)^timeExponent) true) ∧
∃ D s : ℕ, (D : ℝ) ≤ (C.length m : ℝ)^ε ∧
cK * (C.length m : ℝ) ≤ (s : ℝ) ∧ SupportsDepthGate p (C.code m) D s
end QuantumCupGates644.ConstantWeight.Supplement