Holevo Additivity Gap in Lean 4

Lean explorer

Exact Lean source

Nonadditivity.OperationalBlockingFlatten

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

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

19 declarations

Full module

1/-2Copyright (c) 2026 the Nonadditivity project contributors.3All rights reserved. See COPYRIGHT.md for licensing and attribution.4-/56import Nonadditivity.OperationalBlockingCodes78/-! # Exact flattening of physical block-channel codes -/9noncomputable section10namespace Nonadditivity.Operational11open Entropy Channels RegularizedHolevo12open scoped BigOperators Matrix ComplexOrder Kronecker13set_option backward.isDefEq.respectTransparency false1415/-- The positive tensor index of `n+1` consecutive blocks of `k+1` uses. -/16def blockedIndex (k : ℕ) : ℕ → ℕ17  | 0 => k18  | n+1 => blockedIndex k n+k+11920@[simp] theorem blockedIndex_add_one (k n : ℕ) :21    blockedIndex k n+1=(k+1)*(n+1) := by22  induction n with23  | zero => simp [blockedIndex]24  | succ n ih =>25    simp only [blockedIndex]26    nlinarith2728/-- Regroup consecutive channel coordinates into genuine tensor blocks. -/29def blockedEquiv (ι : Type*) (k : ℕ) : (n : ℕ) →30    PositiveTensorIndex ι (blockedIndex k n) ≃31      PositiveTensorIndex (PositiveTensorIndex ι k) n32  | 0 => Equiv.refl _33  | n+1 => (positiveTensorSplit ι (blockedIndex k n) k).trans34      ((blockedEquiv ι k n).prodCongr (Equiv.refl _))3536variable {ι ο κ : Type*} [Fintype ι] [DecidableEq ι]37  [Fintype ο] [DecidableEq ο] [Fintype κ]3839/-- The block equivalence exactly identifies every actual Kraus coefficient. -/40theorem blockedEquiv_kraus (T : KrausChannel ι ο κ) (k n : ℕ)41    (e : PositiveTensorIndex κ (blockedIndex k n))42    (a : PositiveTensorIndex ο (blockedIndex k n))43    (b : PositiveTensorIndex ι (blockedIndex k n)) :44    (positiveTensorPower T (blockedIndex k n)).kraus e a b =45      (positiveTensorPower (positiveTensorPower T k) n).kraus46        (blockedEquiv κ k n e) (blockedEquiv ο k n a) (blockedEquiv ι k n b) := by47  induction n with48  | zero => rfl49  | succ n ih =>50    change (positiveTensorPower T (blockedIndex k n+k+1)).kraus e a b = _51    rw [positiveTensorSplit_kraus T (blockedIndex k n) k]52    simp only [KrausChannel.tensor, Matrix.kroneckerMap_apply]53    rw [ih]54    rfl5556/-- The entire block channel equals the flat channel after relabeling actual57input, output, and Kraus coordinates. -/58theorem blockedPower_eq (T : KrausChannel ι ο κ) (k n : ℕ) :59    (((positiveTensorPower T (blockedIndex k n)).reindex60      (blockedEquiv ι k n) (blockedEquiv ο k n)).reindexKraus (blockedEquiv κ k n)) =61      positiveTensorPower (positiveTensorPower T k) n := by62  apply KrausChannel.ext63  funext e64  ext a b65  have h := blockedEquiv_kraus T k n ((blockedEquiv κ k n).symm e)66    ((blockedEquiv ο k n).symm a) ((blockedEquiv ι k n).symm b)67  simpa only [Equiv.apply_symm_apply] using h6869/-- The reverse regrouping identity for actual density matrices. -/70theorem blockedPower_map (T : KrausChannel ι ο κ) (k n : ℕ)71    (X : Matrix (PositiveTensorIndex (PositiveTensorIndex ι k) n)72      (PositiveTensorIndex (PositiveTensorIndex ι k) n) ℂ) :73    (positiveTensorPower T (blockedIndex k n)).map74      (Matrix.reindex (blockedEquiv ι k n).symm (blockedEquiv ι k n).symm X) =75      Matrix.reindex (blockedEquiv ο k n).symm (blockedEquiv ο k n).symm76        ((positiveTensorPower (positiveTensorPower T k) n).map X) := by77  apply (Matrix.reindex (blockedEquiv ο k n) (blockedEquiv ο k n)).injective78  rw [←KrausChannel.reindex_map (positiveTensorPower T (blockedIndex k n))79    (blockedEquiv ι k n) (blockedEquiv ο k n)80    (Matrix.reindex (blockedEquiv ι k n).symm (blockedEquiv ι k n).symm X)]81  have hi : Matrix.reindex (blockedEquiv ι k n) (blockedEquiv ι k n)82      (Matrix.reindex (blockedEquiv ι k n).symm (blockedEquiv ι k n).symm X)=X := by83    ext a b84    simp [Matrix.reindex_apply]85  rw [hi]86  rw [←KrausChannel.reindexKraus_map _ (blockedEquiv κ k n),blockedPower_eq]87  ext a b88  simp [Matrix.reindex_apply]8990namespace Code9192/-- Decode a block-channel code on precisely its consecutive elementary uses. -/93def flatten (T : KrausChannel ι ο κ) (k n : ℕ) {M : ℕ}94    (C : Code (positiveTensorPower (positiveTensorPower T k) n) M) :95    Code (positiveTensorPower T (blockedIndex k n)) M :=96  C.transport _ (blockedEquiv ι k n).symm (blockedEquiv ο k n).symm9798@[simp] theorem flatten_error (T : KrausChannel ι ο κ) (k n : ℕ) {M : ℕ}99    (C : Code (positiveTensorPower (positiveTensorPower T k) n) M) :100    (C.flatten T k n).error=C.error :=101  transport_error C _ _ _ (blockedPower_map T k n)102103end Code104end Nonadditivity.Operational