Exact Lean source
Nonadditivity.WeightedPositivity
Download original .lean · View on GitHub · Jump to source
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
20 project constants, including generated, internal and private declarations.
20 declarations
Nonadditivity.WeightedPositivity.converted_damped_holevoBits_pos_of_diagonalNonadditivity.WeightedPositivity.converted_damped_weightedBlock_holevoBits_posNonadditivity.WeightedPositivity.pow_ne_uniformNonadditivity.WeightedPositivity.pow_ne_uniform._proof_1_1internal/detail/privateNonadditivity.WeightedPositivity.repeatedIndexNonadditivity.WeightedPositivity.repeatedIndex._sunfoldinternal/detail/privateNonadditivity.WeightedPositivity.repeatedIndex._unsafe_recinternal/detail/privateNonadditivity.WeightedPositivity.repeatedIndex.eq_1internal/detail/privateNonadditivity.WeightedPositivity.repeatedIndex.eq_2internal/detail/privateNonadditivity.WeightedPositivity.repeatedIndex.eq_defNonadditivity.WeightedPositivity.repeatedIndex.match_1internal/detail/privateNonadditivity.WeightedPositivity.state_ne_maximallyMixed_of_diagonalNonadditivity.WeightedPositivity.tensorChain_repeated_diagonalNonadditivity.WeightedPositivity.weightedBlock_exists_output_ne_maximallyMixedNonadditivity.WeightedPositivity.weightedBlock_product_output_diagonalNonadditivity.WeightedPositivity.weightedBlock_product_output_ne_maximallyMixedNonadditivity.WeightedPositivity.weightedComplementary_product_output_diagonal_private.Nonadditivity.WeightedPositivity.0.Nonadditivity.WeightedPositivity.repeatedIndex.match_1.eq_1internal/detail/private_private.Nonadditivity.WeightedPositivity.0.Nonadditivity.WeightedPositivity.repeatedIndex.match_1.eq_2internal/detail/private_private.Nonadditivity.WeightedPositivity.0.Nonadditivity.WeightedPositivity.repeatedIndex.match_1.splitterinternal/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.DampedPositivity7import Nonadditivity.WeightedBell8import Nonadditivity.WeightedBlock910/-! # Strict positivity from nonuniform diagonal output weights1112A diagonal entry different from the uniform value witnesses a nonuniform13output. Such a witness survives every invertible input damping filter.14-/1516noncomputable section17set_option backward.isDefEq.respectTransparency false1819namespace Nonadditivity.WeightedPositivity2021open Entropy Channels Channels.KrausChannel DampedChannel22open scoped BigOperators Matrix ComplexOrder2324theorem state_ne_maximallyMixed_of_diagonal {ο : Type*} [Fintype ο]25[DecidableEq ο] [Nonempty ο] (ρ : DensityMatrix ο) (a : ο) (r : ℝ)26(hdiag : ρ.matrix a a = (r : ℂ))27(hr : r ≠ 1 / (Fintype.card ο : ℝ)) : ρ ≠ maximallyMixed ο := by28intro he29have hh := congrArg (fun σ : DensityMatrix ο => σ.matrix a a) he30dsimp only at hh31rw [hdiag] at hh32apply hr33apply Complex.ofReal_injective34simpa only [maximallyMixed, Matrix.smul_apply, Matrix.one_apply_eq,35smul_eq_mul, mul_one] using hh3637theorem pow_ne_uniform {K n : ℕ} (hn : 1 ≤ n) {r : ℝ} (hr : 0 ≤ r)38(hne : r ≠ 1 / (K : ℝ)) : r^n ≠ 1 / ((K^n : ℕ) : ℝ) := by39intro hh40apply hne41apply (pow_left_inj₀ hr (by positivity : 0 ≤ 1 / (K : ℝ)) (by omega : n ≠ 0)).mp42simpa only [Nat.cast_pow, div_pow, one_pow] using hh4344/-- The constant word in the recursively associated tensor basis. -/45def repeatedIndex {ο : Type*} (a : ο) : (n : ℕ) → TensorChainIndex ο n46| 0 => PUnit.unit47| n+1 => (repeatedIndex a n, a)4849/-- Equal local diagonal values multiply to the corresponding power. -/50theorem tensorChain_repeated_diagonal {ο : Type*} [Fintype ο] [DecidableEq ο]51(ρ : ℕ → DensityMatrix ο) (a : ο) (r : ℝ)52(hdiag : ∀ j, (ρ j).matrix a a = (r : ℂ)) (n : ℕ) :53(DensityMatrix.tensorChain ρ n).matrix (repeatedIndex a n) (repeatedIndex a n) =54(r^n : ℝ) := by55induction n with56| zero => simp [DensityMatrix.tensorChain, emptyTensorState, repeatedIndex]57| succ n ih =>58change (DensityMatrix.tensorChain ρ n).matrix (repeatedIndex a n) (repeatedIndex a n) *59(ρ n).matrix a a = ((r^(n+1) : ℝ) : ℂ)60rw [ih, hdiag n, ← Complex.ofReal_mul, pow_succ]6162theorem converted_damped_holevoBits_pos_of_diagonal63{ι κ : Type*} [Fintype ι] [DecidableEq ι] [Nonempty ι] [Fintype κ]64{d : ℕ} [NeZero d] (T : KrausChannel ι (ZMod d) κ)65(F G : Matrix ι ι ℂ) (hF : F.IsHermitian)66(hres : (1-F*F).PosSemidef) (hGF : G*F=1)67(ρ : DensityMatrix ι) (a : ZMod d) (r : ℝ)68(hdiag : (T.output ρ).matrix a a = (r : ℂ)) (hr : r ≠ 1 / (d : ℝ)) :690 < (Conversion.converted (damped T F hF hres)).holevoBits := by70apply DampedPositivity.converted_damped_holevoBits_pos T F G hF hres hGF71refine ⟨ρ, state_ne_maximallyMixed_of_diagonal (T.output ρ) a r hdiag ?_⟩72simpa only [ZMod.card] using hr7374section WeightedBlock7576open BlockConstruction WeightedBlock7778variable {ι : Type*} [Fintype ι] [DecidableEq ι] [Nonempty ι]79{K : ℕ} [NeZero K]8081/-- Product inputs exhibit the exact product of the local branch probabilities. -/82theorem weightedComplementary_product_output_diagonal83(U : ℕ → Fin K → unitary (Matrix ι ι ℂ))84(p : Fin K → ℝ) (hp : ∀ a, 0 ≤ p a) (hsum : ∑ a, p a=1)85(ρ : ℕ → DensityMatrix ι) (a : Fin K) (n : ℕ) :86((weightedComplementary U p hp hsum n).output (DensityMatrix.tensorChain ρ n)).matrix87(repeatedIndex a n) (repeatedIndex a n) = ((p a)^n : ℝ) := by88change ((tensorChain (fun j => (randomUnitary p hp hsum (U j)).complementary) n).output89(DensityMatrix.tensorChain ρ n)).matrix _ _ = _90rw [tensorChain_output]91exact tensorChain_repeated_diagonal _ a (p a)92(fun j => WeightedBell.complementary_output_diagonal p hp hsum (U j) (ρ j) a) n9394/-- The same diagonal witness in the standardized block output coordinates. -/95theorem weightedBlock_product_output_diagonal96(U : ℕ → Fin K → unitary (Matrix ι ι ℂ))97(p : Fin K → ℝ) (hp : ∀ a, 0 ≤ p a) (hsum : ∑ a, p a=1)98(ρ : ℕ → DensityMatrix ι) (a : Fin K) (n : ℕ) :99((weightedBlock U p hp hsum n).output (DensityMatrix.tensorChain ρ n)).matrix100(blockOutputEquiv K n (repeatedIndex a n))101(blockOutputEquiv K n (repeatedIndex a n)) = ((p a)^n : ℝ) := by102have he := reindex_output_eq (weightedComplementary U p hp hsum n)103(Equiv.refl _) (blockOutputEquiv K n) (DensityMatrix.tensorChain ρ n)104rw [DensityMatrix.reindex_refl] at he105change (((weightedComplementary U p hp hsum n).reindex (Equiv.refl _)106(blockOutputEquiv K n)).output (DensityMatrix.tensorChain ρ n)).matrix _ _ = _107rw [he]108simpa only [DensityMatrix.reindex, Matrix.reindex_apply, Matrix.submatrix_apply,109Equiv.symm_apply_apply] using110weightedComplementary_product_output_diagonal U p hp hsum ρ a n111112/-- Every product input has a nonuniform output when the branch weights are nonuniform. -/113theorem weightedBlock_product_output_ne_maximallyMixed114(U : ℕ → Fin K → unitary (Matrix ι ι ℂ))115(p : Fin K → ℝ) (hp : ∀ a, 0 ≤ p a) (hsum : ∑ a, p a=1)116(ρ : ℕ → DensityMatrix ι) {n : ℕ} (hn : 1 ≤ n)117(hne : ∃ a, p a ≠ 1 / (K : ℝ)) :118(weightedBlock U p hp hsum n).output (DensityMatrix.tensorChain ρ n) ≠119maximallyMixed (ZMod (K^n)) := by120obtain ⟨a, ha⟩ := hne121apply state_ne_maximallyMixed_of_diagonal _122(blockOutputEquiv K n (repeatedIndex a n)) ((p a)^n)123(weightedBlock_product_output_diagonal U p hp hsum ρ a n)124simpa only [ZMod.card] using pow_ne_uniform hn (hp a) ha125126theorem weightedBlock_exists_output_ne_maximallyMixed127(U : ℕ → Fin K → unitary (Matrix ι ι ℂ))128(p : Fin K → ℝ) (hp : ∀ a, 0 ≤ p a) (hsum : ∑ a, p a=1)129{n : ℕ} (hn : 1 ≤ n) (hne : ∃ a, p a ≠ 1 / (K : ℝ)) :130∃ ρ, (weightedBlock U p hp hsum n).output ρ ≠ maximallyMixed (ZMod (K^n)) := by131exact ⟨DensityMatrix.tensorChain (fun _ => maximallyMixed ι) n,132weightedBlock_product_output_ne_maximallyMixed U p hp hsum _ hn hne⟩133134/-- Nonuniform weighted blocks retain a positive Holevo denominator after any135invertible damping and the actual switch/Weyl conversion. -/136theorem converted_damped_weightedBlock_holevoBits_pos137(U : ℕ → Fin K → unitary (Matrix ι ι ℂ))138(p : Fin K → ℝ) (hp : ∀ a, 0 ≤ p a) (hsum : ∑ a, p a=1)139{n : ℕ} (hn : 1 ≤ n) (hne : ∃ a, p a ≠ 1 / (K : ℝ))140(F G : Matrix (TensorChainIndex ι n) (TensorChainIndex ι n) ℂ)141(hF : F.IsHermitian) (hres : (1-F*F).PosSemidef) (hGF : G*F=1) :1420 < (Conversion.converted (damped (weightedBlock U p hp hsum n) F hF hres)).holevoBits :=143DampedPositivity.converted_damped_holevoBits_pos _ F G hF hres hGF144(weightedBlock_exists_output_ne_maximallyMixed U p hp hsum hn hne)145146end WeightedBlock147148end Nonadditivity.WeightedPositivity