Holevo Additivity Gap in Lean 4

Lean explorer

Exact Lean source

Nonadditivity.HaarPathCodes

Download original .lean · View on GitHub · Jump to source

Direct imports

Imported by project modules

2 direct reverse imports

Relationships above come from literal import commands. The declarations below link to types and references extracted from Lean’s environment. Source text is complete and unchanged.

Declarations in this module

12 project constants, including generated, internal and private declarations.

12 declarations

Full module

1/-2Copyright (c) 2026 the Nonadditivity project contributors.3All rights reserved. See COPYRIGHT.md for licensing and attribution.4-/56import Nonadditivity.HaarPathClassData7import Mathlib.Data.List.GetD89/-! # Finite sparse codes with literal position and local-color marks1011An event records its time, its target vertex, the endpoint of the following12old-tree run, and three independent local color labels. For two generators13this is exactly 64*m^3 possibilities. Padding by `none` handles the variable14number of events without an additional polynomial factor.15-/16noncomputable section17namespace Nonadditivity.HaarPathClasses18open HaarPathProfiles19variable {A : Type*}2021abbrev BoundedList (A : Type*) (q : ℕ) := {l : List A // l.length ≤ q}2223/-- A literal bounded list, padded with `none` to its length budget. -/24def paddedListCode (q : ℕ) (l : BoundedList A q) : Fin q → Option A :=25  fun i => l.val[i.val]?2627theorem paddedListCode_injective (q : ℕ) :28    Function.Injective (@paddedListCode A q) := by29  intro l s h30  apply Subtype.ext31  apply List.ext_getElem?32  intro i33  by_cases hi : i < q34  · exact congrFun h ⟨i,hi⟩35  · rw [List.getElem?_eq_none (by have := l.property; omega),36      List.getElem?_eq_none (by have := s.property; omega)]3738instance [Fintype A] (q : ℕ) : Fintype (BoundedList A q) :=39  Fintype.ofInjective (paddedListCode q) (paddedListCode_injective q)4041theorem card_boundedList_le [Fintype A] (q : ℕ) :42    Fintype.card (BoundedList A q) ≤ (Fintype.card A+1)^q := by43  calc44    _ ≤ Fintype.card (Fin q → Option A) :=45      Fintype.card_le_of_injective _ (paddedListCode_injective q)46    _ = _ := by simp4748/-- The three local colors are independent endpoint labels. This avoids49assuming that local normalization produces a globally colored path. -/50abbrev ExplorationMark (m : ℕ) :=51  Fin m × Fin m × Color 2 × Color 2 × Color 25253/-- Time, target vertex, end of old-tree run, and three local colors. -/54abbrev ExplorationEvent (m : ℕ) := Fin m × ExplorationMark m5556@[simp] theorem card_explorationEvent (m : ℕ) :57    Fintype.card (ExplorationEvent m)=64*m^3 := by58  simp only [ExplorationEvent,ExplorationMark,Color,Fintype.card_prod,59    Fintype.card_fin,Fintype.card_bool]60  ring6162/-- The fully explicit code-space bound, including padding and variable63length. It does not refer to the unknown final path graph. -/64theorem card_explorationCodes_le (m q : ℕ) (hm : 0 < m) :65    Fintype.card (BoundedList (ExplorationEvent m) q) ≤66      128^q*m^(3*q) := by67  have hc : 64*m^3+1 ≤ 128*m^3 := by68    have hp : 0 < m^3 := pow_pos hm _69    omega70  calc71    _ ≤ (Fintype.card (ExplorationEvent m)+1)^q := card_boundedList_le q72    _ = (64*m^3+1)^q := by rw [card_explorationEvent]73    _ ≤ (128*m^3)^q := Nat.pow_le_pow_left hc _74    _ = _ := by rw [mul_pow,←pow_mul]7576end Nonadditivity.HaarPathClasses