Exact Lean source
Nonadditivity.SmallEnvironment
Download original .lean · View on GitHub · Jump to source
Direct imports
Nonadditivity.GeneralBellNonadditivity.PositiveHolevoMathlib.LinearAlgebra.Matrix.ToLinearEquivdependency
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
16 project constants, including generated, internal and private declarations.
16 declarations
Nonadditivity.Channels.pureState.congr_simpNonadditivity.SmallEnvironment.converted_holevo_posNonadditivity.SmallEnvironment.entropy_le_of_singularNonadditivity.SmallEnvironment.environmentMatrixNonadditivity.SmallEnvironment.exists_output_entropy_ltNonadditivity.SmallEnvironment.exists_output_entropy_lt._proof_1_1internal/detail/privateNonadditivity.SmallEnvironment.exists_output_entropy_lt._proof_1_2internal/detail/privateNonadditivity.SmallEnvironment.exists_singular_outputNonadditivity.SmallEnvironment.exists_singular_output._simp_1_2internal/detail/privateNonadditivity.SmallEnvironment.normalized_kernelNonadditivity.SmallEnvironment.normalized_kernel._simp_1_1internal/detail/privateNonadditivity.SmallEnvironment.output_entryNonadditivity.SmallEnvironment.shannon_le_log_card_sub_oneNonadditivity.SmallEnvironment.shannon_le_log_card_sub_one._proof_1_1internal/detail/privateNonadditivity.SmallEnvironment.square_pair_dependentNonadditivity.SmallEnvironment.square_pair_dependent._simp_1_1internal/detail/private
Full module
1/-2Copyright (c) 2026 the Nonadditivity project contributors.3All rights reserved. See COPYRIGHT.md for licensing and attribution.4-/56import Nonadditivity.GeneralBell7import Nonadditivity.PositiveHolevo8import Mathlib.LinearAlgebra.Matrix.ToLinearEquiv910/-! # Positive Holevo information for channels with a small environment1112A channel with equally sized input and Kraus-label spaces, and at least two13output coordinates, has a pure input whose output is singular. This gives14a positive Holevo denominator after the switch/Weyl conversion.15-/1617noncomputable section18set_option maxHeartbeats 80000019set_option backward.isDefEq.respectTransparency false2021namespace Nonadditivity.SmallEnvironment2223open Entropy Channels Channels.KrausChannel24open scoped BigOperators Matrix ComplexOrder2526theorem shannon_le_log_card_sub_one {ι : Type*} [Fintype ι] [DecidableEq ι]27(p : ι → ℝ) (hp : ∀ i, 0 ≤ p i) (hs : ∑ i, p i = 1)28(j : ι) (hj : p j = 0) (hd : 2 ≤ Fintype.card ι) :29shannon p ≤ Real.log (Fintype.card ι - 1 : ℕ) := by30let J := {i : ι // i ≠ j}31have hc : Fintype.card J = Fintype.card ι - 1 := by32simp [J, Fintype.card_subtype_compl]33letI : Nonempty J := Fintype.card_pos_iff.mp (by rw [hc]; omega)34have hsum : ∑ i : J, p i.val = 1 := by35have h := Fintype.sum_eq_add_sum_subtype_ne p j36rw [hs, hj, zero_add] at h37exact h.symm38have he : shannon p = shannon (fun i : J => p i.val) := by39unfold shannon40rw [Fintype.sum_eq_add_sum_subtype_ne (fun i => p i * Real.log (p i)) j]41simp only [hj, zero_mul, zero_add]42rfl43rw [he, ← hc]44exact shannon_le_log_card _ (fun i => hp i.val) hsum4546theorem entropy_le_of_singular {ι : Type*} [Fintype ι] [DecidableEq ι]47(ρ : DensityMatrix ι) (hd : 2 ≤ Fintype.card ι) (hdet : ρ.matrix.det = 0) :48ρ.vonNeumann ≤ Real.log (Fintype.card ι - 1 : ℕ) := by49rw [ρ.positive.isHermitian.det_eq_prod_eigenvalues] at hdet50obtain ⟨j, _, hj⟩ := Finset.prod_eq_zero_iff.mp hdet51apply shannon_le_log_card_sub_one ρ.weights ρ.weights_nonneg ρ.weights_sum j _ hd52change (ρ.weights j : ℂ) = 0 at hj53exact Complex.ofReal_eq_zero.mp hj5455section Square56variable {ι : Type*} [Fintype ι] [DecidableEq ι] [Nonempty ι]5758omit [Nonempty ι] in59lemma normalized_kernel (M : Matrix ι ι ℂ) (hd : M.det = 0) :60∃ v : ι → ℂ, (∑ i, Complex.normSq (v i)) = 1 ∧ M *ᵥ v = 0 := by61obtain ⟨x, hx, he⟩ := Matrix.exists_mulVec_eq_zero_iff.mpr hd62obtain ⟨j,hj⟩ := Function.ne_iff.mp hx63have hS : 0 < ∑ i, Complex.normSq (x i) := by64apply Finset.sum_pos'65· intro i _; exact Complex.normSq_nonneg _66· exact ⟨j, Finset.mem_univ _, Complex.normSq_pos.mpr hj⟩67let r : ℝ := Real.sqrt (∑ i, Complex.normSq (x i))68have hr : 0 < r := Real.sqrt_pos.mpr hS69refine ⟨Complex.ofReal (r⁻¹) • x, ?_, ?_⟩70· simp only [Pi.smul_apply, smul_eq_mul, Complex.normSq_mul,71Complex.normSq_ofReal, ← Finset.mul_sum]72have hs : r * r = ∑ i, Complex.normSq (x i) := Real.mul_self_sqrt hS.le73rw [← hs]74field_simp75· rw [Matrix.mulVec_smul, he, smul_zero]7677lemma square_pair_dependent (A B : Matrix ι ι ℂ) :78∃ v : ι → ℂ, (∑ i, Complex.normSq (v i)) = 1 ∧79(B *ᵥ v = 0 ∨ ∃ z : ℂ, A *ᵥ v = z • (B *ᵥ v)) := by80by_cases hB : B.det = 081· obtain ⟨v,hv,he⟩ := normalized_kernel B hB82exact ⟨v,hv,Or.inl he⟩83· obtain ⟨z,v,hv,he⟩ := PositiveHolevo.exists_normalized_eigenvector (B⁻¹ * A)84refine ⟨v,hv,Or.inr ⟨z,?_⟩⟩85have h := congrArg (fun w => B *ᵥ w) he86simpa only [Matrix.mulVec_mulVec, ← Matrix.mul_assoc,87Matrix.mul_nonsing_inv B (isUnit_iff_ne_zero.mpr hB), Matrix.one_mul,88Matrix.mulVec_smul] using h8990variable {ο : Type*} [Fintype ο] [DecidableEq ο]9192def environmentMatrix (T : KrausChannel ι ο ι) (a : ο) : Matrix ι ι ℂ :=93fun e i => T.kraus e a i9495omit [Nonempty ι] in96lemma output_entry (T : KrausChannel ι ο ι) (v : ι → ℂ)97(hv : ∑ i, Complex.normSq (v i) = 1) (a b : ο) :98(T.output (pureState v hv)).matrix a b =99∑ e, ((environmentMatrix T a) *ᵥ v) e * star (((environmentMatrix T b) *ᵥ v) e) := by100simp only [KrausChannel.output_matrix, KrausChannel.map, pureState,101BellOutput.conjugation_vecMulVec, Matrix.sum_apply, Matrix.vecMulVec_apply,102Pi.star_apply]103rfl104105/-- The matrix-pencil argument constructs a pure input with dependent106environment vectors in two output coordinates. -/107theorem exists_singular_output (T : KrausChannel ι ο ι) (a b : ο) (hab : a ≠ b) :108∃ ρ : DensityMatrix ι, (T.output ρ).matrix.det = 0 := by109obtain ⟨v,hv,hdep⟩ := square_pair_dependent (environmentMatrix T a) (environmentMatrix T b)110refine ⟨pureState v hv, Matrix.exists_vecMul_eq_zero_iff.mp ?_⟩111rcases hdep with hb | ⟨z,hz⟩112· refine ⟨Pi.single b 1, ?_, ?_⟩113· intro h114have := congrFun h b115simp at this116· ext c117simp only [Matrix.vecMul, dotProduct, Pi.zero_apply]118simp only [Pi.single_apply, ite_mul, one_mul, zero_mul, Finset.sum_ite_eq',119Finset.mem_univ, if_true]120rw [output_entry, hb]121simp122· refine ⟨(Pi.single a (1:ℂ) : ο → ℂ) - z • (Pi.single b (1:ℂ) : ο → ℂ), ?_, ?_⟩123· intro h124have := congrFun h a125simp [hab] at this126· ext c127simp only [Matrix.vecMul, dotProduct, Pi.zero_apply, Pi.sub_apply,128Pi.smul_apply, smul_eq_mul, sub_mul, Finset.sum_sub_distrib]129simp only [Pi.single_apply, ite_mul, one_mul, zero_mul, mul_ite, mul_one, mul_zero,130Finset.sum_ite_eq', Finset.mem_univ, if_true]131rw [output_entry, output_entry, hz]132simp [Pi.smul_apply, smul_eq_mul, Finset.mul_sum, mul_assoc]133134theorem exists_output_entropy_lt (T : KrausChannel ι ο ι)135(hd : 2 ≤ Fintype.card ο) :136∃ ρ : DensityMatrix ι, (T.output ρ).vonNeumann < Real.log (Fintype.card ο : ℝ) := by137obtain ⟨a,b,_,_,hab⟩ := Finset.one_lt_card_iff.mp138(show 1 < (Finset.univ : Finset ο).card by simpa using hd)139obtain ⟨ρ,hρ⟩ := exists_singular_output T a b hab140refine ⟨ρ, (entropy_le_of_singular _ hd hρ).trans_lt ?_⟩141apply Real.log_lt_log142· exact_mod_cast (show 0 < Fintype.card ο - 1 by omega)143· exact_mod_cast (show Fintype.card ο - 1 < Fintype.card ο by omega)144145theorem converted_holevo_pos {K : ℕ} [NeZero K] (hK : 2 ≤ K)146(T : KrausChannel ι (ZMod K) ι) : 0 < (Conversion.converted T).holevo := by147obtain ⟨ρ,hρ⟩ := exists_output_entropy_lt T (by simpa using hK)148have hmin : T.minimumEntropy ≤ (T.output ρ).vonNeumann :=149StateEnsembles.minimumEntropy_le (outputs := T.outputs) ⟨ρ,rfl⟩150rw [Conversion.converted_holevo]151simp only [ZMod.card] at hρ152linarith153154end Square155end Nonadditivity.SmallEnvironment