Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Total Variance D2: total variance d2

Open
QAlgorithms.Papers.Independent.Bridge50.P50.total_variance_d2

by Gohan · Oct 29, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

Let S\mathcal SS be the density operators on a nonzero, finite-dimensional complex Hilbert space of dimension ddd. Logarithms are in bits, DDD is support-aware Umegaki relative entropy, and VVV is relative entropy variance in bits squared. Let PPP be any finite ensemble of states, allowing zero probabilities, with ρˉP=∑ρP(ρ)ρ\bar\rho_P=\sum_\rho P(\rho)\rhoρˉ​P​=∑ρ​P(ρ)ρ. Set ωP=⨁ρP(ρ)ρ\omega_P=\bigoplus_\rho P(\rho)\rhoωP​=⨁ρ​P(ρ)ρ, ζP=⨁ρP(ρ)ρˉP\zeta_P=\bigoplus_\rho P(\rho)\bar\rho_PζP​=⨁ρ​P(ρ)ρˉ​P​, and I(P)=∑ρP(ρ)D(ρ∥ρˉP)I(P)=\sum_\rho P(\rho)D(\rho\|\bar\rho_P)I(P)=∑ρ​P(ρ)D(ρ∥ρˉ​P​). Then

V(ωP∥ζP)=∑ρP(ρ)V(ρ∥ρˉP)+∑ρP(ρ)(D(ρ∥ρˉP)−I(P))2.V(\omega_P\|\zeta_P)=\sum_\rho P(\rho)V(\rho\|\bar\rho_P)+ \sum_\rho P(\rho)\bigl(D(\rho\|\bar\rho_P)-I(P)\bigr)^2.V(ωP​∥ζP​)=ρ∑​P(ρ)V(ρ∥ρˉ​P​)+ρ∑​P(ρ)(D(ρ∥ρˉ​P​)−I(P))2.

This is the complete law of total variance for block states. The second term disappears for peripheral center decompositions, yielding Lemma 15.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Bridge50_P50
Formal statement
noncomputable section

open scoped Topology BigOperators ComplexConjugate ComplexOrder ENNReal Matrix.Norms.L2Operator

open MeasureTheory Filter Set

namespace QAlgorithms.Papers.Independent.Bridge50.P50

attribute [local instance] Classical.propDecidable Classical.decEq

-- Exact accepted primitives; these names do not create local declarations.

open QAlgorithms.Papers.Independent.Information100.P63 (Mat logTwo testingBeta normalCDF normalQuantile)

open QAlgorithms.Papers.Independent.Information100.P08 (Ensemble ensembleAverage)

open QAlgorithms.Papers.Independent.Information100.P69 (entropy)

open QAlgorithms.Papers.Independent.Dependency50.P35 (Dominates)

open QAlgorithms.Papers.Independent.Dependency50.P36 (pairInformationVariance)

open QAlgorithms (vnEntropy traceDistance minEigenvalue)

attribute [local instance] QAlgorithms.Papers.Independent.Bridge50.P50.matrixBorelMeasurable

attribute [local instance] QAlgorithms.Papers.Independent.Bridge50.P50.matrixBorelSpace

/-- Appendix D1, PDF p.30, (D1)–(D2): FULL law of total variance for any finite ensemble.
No equal-relative-entropy invariant is assumed. Zero-weight blocks contribute zero. -/
theorem total_variance_d2 {I : Type} [Fintype I] [DecidableEq I] [Nonempty I]
    (E : Ensemble I) :
    pairInformationVariance (cqJointState E) (referenceState E) = ensembleVariance E +
      ∑ i, E.prob i * ((entropy (E.state i) (ensembleAverage E)).toReal -
        finiteHolevoInformation E)^2 := by sorry

end QAlgorithms.Papers.Independent.Bridge50.P50

end
Source
Second-Order Asymptotics for the Classical Capacity of Image-Additive Quantum Channels, arXiv:1308.6503v3, PDF p. 30, Total Variance D2
Read-back

What the Lean code literally says, in plain math · gpt-6.1-sol

Let III be a finite, nonempty type with decidable equality, and let E=((pi,ρi))i=0s−1E=((p_i,\rho_i))_{i=0}^{s-1}E=((pi​,ρi​))i=0s−1​ be any finite ensemble: pi≥0p_i\ge0pi​≥0, ∑ipi=1\sum_i p_i=1∑i​pi​=1, and every ρi\rho_iρi​ is positive semidefinite with trace 111. Its size sss is a natural number; size 000 is excluded by the weight-sum condition. Put ρˉ=∑ipiρi\bar\rho=\sum_i p_i\rho_iρˉ​=∑i​pi​ρi​, and define matrices J,QJ,QJ,Q indexed by {0,…,s−1}×I\{0,\ldots,s-1\}\times I{0,…,s−1}×I by

J(i,a),(j,b)={pi(ρi)ab,i=j,0,i≠j,Q(i,a),(j,b)={piρˉab,i=j,0,i≠j.J_{(i,a),(j,b)}= \begin{cases}p_i(\rho_i)_{ab},&i=j,\\0,&i\ne j,\end{cases} \qquad Q_{(i,a),(j,b)}= \begin{cases}p_i\bar\rho_{ab},&i=j,\\0,&i\ne j.\end{cases}J(i,a),(j,b)​={pi​(ρi​)ab​,0,​i=j,i=j,​Q(i,a),(j,b)​={pi​ρˉ​ab​,0,​i=j,i=j.​

Define D(R∥T)∈[0,∞]D(R\|T)\in[0,\infty]D(R∥T)∈[0,∞] as +∞+\infty+∞ unless both arguments are density matrices and ker⁡T⊆ker⁡R\ker T\subseteq\ker RkerT⊆kerR, and otherwise as [Re⁡tr⁡(f(R)−Rlog⁡T)]+/ln⁡2[\operatorname{Re}\operatorname{tr}(f(R)-R\log T)]_+/\ln2[Retr(f(R)−RlogT)]+​/ln2, where f(x)=xln⁡xf(x)=x\ln xf(x)=xlnx and matrix functions use continuous functional calculus. Let di=(D(ρi∥ρˉ))Rd_i=(D(\rho_i\|\bar\rho))_{\mathbb R}di​=(D(ρi​∥ρˉ​))R​, with +∞+\infty+∞ converted to 000, and put χE=∑ipidi\chi_E=\sum_i p_id_iχE​=∑i​pi​di​. For arbitrary matrices on a common finite index set, define

V(R,T)=Re⁡tr⁡ ⁣(R(log⁡2R−log⁡2T)2)−(Re⁡tr⁡(f(R)−Rlog⁡T)ln⁡2)2.V(R,T)=\operatorname{Re}\operatorname{tr}\!\left(R(\log_2R-\log_2T)^2\right) -\left(\frac{\operatorname{Re}\operatorname{tr}(f(R)-R\log T)}{\ln2}\right)^2.V(R,T)=Retr(R(log2​R−log2​T)2)−(ln2Retr(f(R)−RlogT)​)2.

Then

V(J,Q)=∑ipiV(ρi,ρˉ)+∑ipi(di−χE)2.V(J,Q)=\sum_i p_iV(\rho_i,\bar\rho)+\sum_i p_i(d_i-\chi_E)^2.V(J,Q)=i∑​pi​V(ρi​,ρˉ​)+i∑​pi​(di​−χE​)2.

Zero ensemble weights are allowed, and the functional-calculus logarithms use log⁡0=0\log 0=0log0=0.

Human review
  • Endorsed by Shuze Chen · Oct 29, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Oct 29, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me