Holevo Additivity Gap in Lean 4

Lean explorer

Exact Lean source

Nonadditivity.NoncommutativeCSCrossing

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

Direct imports

Imported by project modules

1 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

Full module

1/-2Copyright (c) 2026 the Nonadditivity project contributors.3All rights reserved. See COPYRIGHT.md for licensing and attribution.4-/56import Nonadditivity.NoncommutativeCS78/-! # Crossing pair contractions910The two paired indices in `Aᵢ Bⱼ Cᵢ Dⱼ` cross. Applying ordinary11Cauchy--Schwarz separately to the two sums loses a cardinal factor. An actual12isometric permutation of the two memory registers avoids that loss.13-/1415noncomputable section1617namespace Nonadditivity.NoncommutativeCS1819open scoped BigOperators InnerProduct2021variable {𝕜 E : Type*} [RCLike 𝕜]22variable [NormedAddCommGroup E] [InnerProductSpace 𝕜 E] [CompleteSpace E]23variable {I J : Type*} [Fintype I] [Fintype J]2425/-- Swapping two finite Hilbert direct sums preserves the Hilbert norm. -/26def swap : DirectSum I (DirectSum J E) ≃ₗᵢ[𝕜] DirectSum J (DirectSum I E) where27  toFun x := WithLp.toLp 2 (fun j => WithLp.toLp 2 (fun i => x i j))28  invFun x := WithLp.toLp 2 (fun i => WithLp.toLp 2 (fun j => x j i))29  left_inv := by intro x; rfl30  right_inv := by intro x; rfl31  map_add' := by intros; rfl32  map_smul' := by intros; rfl33  norm_map' := by34    intro x35    apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp36    simp only [PiLp.norm_sq_eq_of_L2]37    exact Finset.sum_comm3839omit [CompleteSpace E] in40@[simp] theorem swap_apply (x : DirectSum I (DirectSum J E)) (j : J) (i : I) :41    swap (𝕜 := 𝕜) x j i = x i j := rfl4243/-- Both indices may remain open across a uniformly bounded middle factor. -/44theorem crossing_sum_norm_le45    (A C : I → E →L[𝕜] E) (B D : J → E →L[𝕜] E)46    (X : I → J → E →L[𝕜] E) (q : ℝ) (hq : 0 ≤ q)47    (hX : ∀ i j, ‖X i j‖ ≤ q) :48    ‖∑ i, ∑ j, A i ∘L B j ∘L X i j ∘L C i ∘L D j‖ ≤49      Real.sqrt ‖rowGram A‖ * Real.sqrt ‖rowGram B‖ * q *50        Real.sqrt ‖columnGram C‖ * Real.sqrt ‖columnGram D‖ := by51  let M : DirectSum I (DirectSum J E) →L[𝕜] DirectSum I (DirectSum J E) :=52    diagonal (fun i => diagonal (X i))53  have hM : ‖M‖ ≤ q := diagonal_norm_le _ q hq54    (fun i => diagonal_norm_le _ q hq (hX i))55  let S : DirectSum J (DirectSum I E) →L[𝕜] DirectSum I (DirectSum J E) :=56    (swap (𝕜 := 𝕜) (E := E) (I := J) (J := I)).toLinearIsometry.toContinuousLinearMap57  have hS : ‖S‖ ≤ 1 := LinearIsometry.norm_toContinuousLinearMap_le _58  let V := (amplify (I := J) (column C)) ∘L column D59  have hV : ‖V‖ ≤ Real.sqrt ‖columnGram C‖ * Real.sqrt ‖columnGram D‖ := by60    exact (ContinuousLinearMap.opNorm_comp_le _ _).trans61      (mul_le_mul ((amplify_norm_le _).trans (column_norm_le C)) (column_norm_le D)62        (norm_nonneg _) (Real.sqrt_nonneg _))63  let W := row A ∘L amplify (I := I) (row B)64  have hW : ‖W‖ ≤ Real.sqrt ‖rowGram A‖ * Real.sqrt ‖rowGram B‖ := by65    exact (ContinuousLinearMap.opNorm_comp_le _ _).trans66      (mul_le_mul (row_norm_le A) ((amplify_norm_le _).trans (row_norm_le B))67        (norm_nonneg _) (Real.sqrt_nonneg _))68  have hid : ∑ i, ∑ j, A i ∘L B j ∘L X i j ∘L C i ∘L D j = W ∘L M ∘L S ∘L V := by69    ext x70    simp [W, M, S, V, swap, map_sum]71  rw [hid]72  calc73    _ ≤ ‖W‖ * (‖M‖ * (‖S‖ * ‖V‖)) := by74      apply (ContinuousLinearMap.opNorm_comp_le _ _).trans75      apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)76      apply (ContinuousLinearMap.opNorm_comp_le _ _).trans77      exact mul_le_mul_of_nonneg_left (ContinuousLinearMap.opNorm_comp_le _ _) (norm_nonneg _)78    _ ≤ (Real.sqrt ‖rowGram A‖ * Real.sqrt ‖rowGram B‖) *79        (q * (1 * (Real.sqrt ‖columnGram C‖ * Real.sqrt ‖columnGram D‖))) :=80      mul_le_mul hW (mul_le_mul hM (mul_le_mul hS hV (norm_nonneg _) (by norm_num))81        (by positivity) hq) (by positivity) (by positivity)82    _ = _ := by ring8384/-- A crossing pair partition, with the exact four Gram factors. -/85theorem crossing_pair_norm_le86    (A C : I → E →L[𝕜] E) (B D : J → E →L[𝕜] E) :87    ‖∑ i, ∑ j, A i ∘L B j ∘L C i ∘L D j‖ ≤88      Real.sqrt ‖rowGram A‖ * Real.sqrt ‖rowGram B‖ *89        Real.sqrt ‖columnGram C‖ * Real.sqrt ‖columnGram D‖ := by90  simpa only [ContinuousLinearMap.id_comp, mul_one] using91    crossing_sum_norm_le A C B D (fun _ _ => ContinuousLinearMap.id 𝕜 E) 1 (by norm_num)92      (fun _ _ => ContinuousLinearMap.norm_id_le)9394end Nonadditivity.NoncommutativeCS