Pratik Patil

SubentropyMaximum.lean

1module23public import SubentropyCertificates.QuantumModulus45/-! The maximally mixed state is the unique maximizer of ordinary subentropy. -/6@[expose] public section7noncomputable section8open Matrix Set9open scoped BigOperators ComplexOrder MatrixOrder1011namespace SubentropyCertificates.SpectralContinuity12open D5.S3.Quantum.Foundation.FiniteStateChannel13open D5.S3.Quantum.Information.PartialTraceMutualInformation14open D5.S3.Quantum.Subentropy.Basic15open D5.S3.Quantum.Subentropy.DensityKernel16open SubentropyCertificates.ClassicalCurve17open SubentropyCertificates.BinarySpectra (densityMatrix)18open SubentropyCertificates.Subadditivity (subentropy_of_spectrum)1920variable {D : Type*} [Fintype D] [DecidableEq D] [Nonempty D]2122theorem uniform_simplex (D : Type*) [Fintype D] [Nonempty D] :23    (fun _ : D ↦ 1 / (Fintype.card D : ℝ)) ∈ probabilitySimplex D := by24  have hn : (Fintype.card D : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero25  exact ⟨fun _ ↦ by positivity, by simp [nsmul_eq_mul, hn]⟩2627/-- The density state I/d on a nonempty finite coordinate type. -/28def maximallyMixed (D : Type*) [Fintype D] [DecidableEq D] [Nonempty D] : DensityState D :=29  diagonalDensity _ (uniform_simplex D)3031theorem maximallyMixed_matrix (D : Type*) [Fintype D] [DecidableEq D] [Nonempty D] :32    densityMatrix (maximallyMixed D) = (1 / (Fintype.card D : ℂ)) • (1 : Matrix D D ℂ) := by33  change diagonal (fun _ : D ↦ ((1 / (Fintype.card D : ℝ) : ℝ) : ℂ)) = _34  ext i j35  by_cases h : i = j36  · subst j37    simp38  · simp [h]3940private theorem classical_uniform_max :41    IsMaxOn classicalSubentropy (probabilitySimplex D) (fun _ : D ↦ 1 / (Fintype.card D : ℝ)) := by42  obtain ⟨k, hk⟩ : ∃ k, Fintype.card D = k + 1 :=43    ⟨Fintype.card D - 1, by have := Fintype.card_pos (α := D); omega⟩44  let e : Fin (k + 1) ≃ D := Fintype.equivOfCardEq (by simp [hk])45  intro p hp46  have h := fin_subentropy_le_uniform k (p ∘ e) (simplex_reindex _ hp e)47  rw [classical_subentropy_reindex] at h48  have hu := classical_subentropy_reindex (fun _ : D ↦ 1 / (Fintype.card D : ℝ)) e49  change classicalSubentropy p ≤ classicalSubentropy (fun _ : D ↦ 1 / (Fintype.card D : ℝ))50  rw [← hu]51  simpa only [Function.comp_def, hk] using h5253/-- The subentropy upper endpoint and its equality condition on the original density matrix. -/54theorem subentropy_maximum_iff (ρ : DensityState D) :55    subentropy ρ ≤ subentropy (maximallyMixed D) ∧56    (subentropy ρ = subentropy (maximallyMixed D) ↔ ρ = maximallyMixed D) := by57  let hA := (density_posSemidef ρ).isHermitian58  let p := hA.eigenvalues59  let u := fun _ : D ↦ 1 / (Fintype.card D : ℝ)60  have hp : p ∈ probabilitySimplex D := spectral_prob (density_posSemidef ρ) ρ.2.261  have hs : subentropy ρ = classicalSubentropy p := subentropy_of_spectrum hA62  have hm : subentropy (maximallyMixed D) = classicalSubentropy u := rfl63  refine ⟨hs.le.trans ((classical_uniform_max hp).trans_eq hm.symm), ⟨?_, fun h ↦ h ▸ rfl⟩⟩64  intro he65  have eq : classicalSubentropy p = classicalSubentropy u := hs.symm.trans (he.trans hm)66  have hpm : IsMaxOn classicalSubentropy (probabilitySimplex D) p :=67    fun q hq ↦ (classical_uniform_max hq).trans_eq eq.symm68  have hpu : p = u :=69    classical_subentropy_strictConcave.eq_of_isMaxOn hpm classical_uniform_max hp70      (uniform_simplex D)71  have hmat : densityMatrix ρ = Unitary.conjStarAlgAut ℂ _ hA.eigenvectorUnitary72      (diagonal (fun i ↦ (p i : ℂ))) := hA.spectral_theorem73  apply Subtype.ext74  apply CStarMatrix.ofMatrix.symm.injective75  change densityMatrix ρ = densityMatrix (maximallyMixed D)76  rw [hmat, hpu]77  change Unitary.conjStarAlgAut ℂ _ _ (densityMatrix (maximallyMixed D)) = _78  rw [maximallyMixed_matrix, map_smul, map_one]7980end SubentropyCertificates.SpectralContinuity

Axioms used

Choose a statement to see which axioms its proof uses.