Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Weighted quantum testing inequality

Open
QAlgorithms.Papers.Independent.Intakethird100.P04.weighted_testing_inequality

by Gohan · Nov 1, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

Let ρ,σ\rho,\sigmaρ,σ be positive trace-class operators of trace one on an arbitrary complex Hilbert space HHH. Choose complete orthonormal eigenbases xi,yjx_i,y_jxi​,yj​, including their kernels, with eigenvalues λi,γj≥0\lambda_i,\gamma_j\ge0λi​,γj​≥0. On Ω={(i,j)}\Omega=\{(i,j)\}Ω={(i,j)} define p(i,j)=λi∣⟨xi,yj⟩∣2p(i,j)=\lambda_i|\langle x_i,y_j\rangle|^2p(i,j)=λi​∣⟨xi​,yj​⟩∣2 and q(i,j)=γj∣⟨xi,yj⟩∣2q(i,j)=\gamma_j|\langle x_i,y_j\rangle|^2q(i,j)=γj​∣⟨xi​,yj​⟩∣2. For every bounded Hermitian effect 0≤T≤I0\le T\le I0≤T≤I and every real δ>0\delta>0δ>0, put α[T]=1−Tr⁡(ρT)\alpha[T]=1-\operatorname{Tr}(\rho T)α[T]=1−Tr(ρT) and β[T]=Tr⁡(σT)\beta[T]=\operatorname{Tr}(\sigma T)β[T]=Tr(σT). Then

α[T]+δβ[T]≥12(∑ω:p(ω)≤δq(ω)p(ω)+δ∑ω:p(ω)>δq(ω)q(ω)).\alpha[T]+\delta\beta[T]\ge\frac12\left(\sum_{\omega:p(\omega)\le\delta q(\omega)}p(\omega)+\delta\sum_{\omega:p(\omega)>\delta q(\omega)}q(\omega)\right).α[T]+δβ[T]≥21​​ω:p(ω)≤δq(ω)∑​p(ω)+δω:p(ω)>δq(ω)∑​q(ω)​.

The two sums are nonnegative event masses; equality in the threshold belongs to the first event. This bound extends the projection comparison to every binary quantum test.

Formalization Note The inequality is embedded in the extended nonnegative reals. All its terms are finite for the stated states and effects, so this embedding preserves the exact real inequality.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Intakethird100_P04
Formal statement
noncomputable section

open Filter

open scoped ENNReal NNReal BigOperators ComplexOrder

namespace QAlgorithms.Papers.Independent.Intakethird100.P04

attribute [local instance] Classical.propDecidable Classical.decEq

attribute [local instance] IsStarNormal.instContinuousFunctionalCalculus

open QAlgorithms.Papers.Independent.Dependency50.P13
  (State operatorTrace relativeEntropy)

open QAlgorithms.Papers.Independent.Support50.P20
  (Effect traceAcceptance IsHilbertCPTP BlockHilbert blockBasis)

open QAlgorithms.Papers.Independent.Frontier18.P18 (boundedOperator)

variable {H K : Type*}

variable [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H]

variable [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K]

/-- Lemma 1, PDF p.4, (18), with spectral data from p.3, (12)--(13).
All bounded effects and delta>0 are permitted. The RHS factor is one half;
equality belongs to the p event. -/
theorem weighted_testing_inequality {I J L : Type*} (b : HilbertBasis I ℂ H)
    (rho sigma : State b) (x : DensitySpectrum rho J) (y : DensitySpectrum sigma L)
    (T : Effect H) (delta : ℝ) (hdelta : 0 < delta) :
    (1 / 2 : ℝ≥0∞) *
        (lowerMass (spectralP x y) (spectralQ x y) (ENNReal.ofReal delta) +
          ENNReal.ofReal delta *
            upperMass (spectralP x y) (spectralQ x y) (ENNReal.ofReal delta)) ≤
      ENNReal.ofReal (1 - traceAcceptance b T.val rho.val.val) +
        ENNReal.ofReal delta * ENNReal.ofReal (traceAcceptance b T.val sigma.val.val) := by sorry

end QAlgorithms.Papers.Independent.Intakethird100.P04

end
Source
The Converse Part of The Theorem for Quantum Hoeffding Bound, arXiv:quant-ph/0611289v1, PDF p. 4, Lemma 1, (18)–(19)
Read-back

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

Let HHH be a complete complex inner-product space, let I,J,LI,J,LI,J,L be arbitrary index types, and let b=(bi)i∈Ib=(b_i)_{i\in I}b=(bi​)i∈I​ be a Hilbert basis. Let ρ,σ\rho,\sigmaρ,σ be states with underlying bounded operators R,SR,SR,S: both are self-adjoint with nonnegative quadratic forms and trace one relative to bbb, meaning ∑i⟨bi,Rbi⟩=∑i⟨bi,Sbi⟩=1\sum_i\langle b_i,Rb_i\rangle=\sum_i\langle b_i,Sb_i\rangle=1∑i​⟨bi​,Rbi​⟩=∑i​⟨bi​,Sbi​⟩=1; each also admits a representation Av=∑r∈N⟨vr,v⟩urAv=\sum_{r\in\mathbb N}\langle v_r,v\rangle u_rAv=∑r∈N​⟨vr​,v⟩ur​ with ∑r∥ur∥∥vr∥<∞\sum_r\|u_r\|\|v_r\|<\infty∑r​∥ur​∥∥vr​∥<∞. Let xxx provide a Hilbert basis (ej)j∈J(e_j)_{j\in J}(ej​)j∈J​ and finite nonnegative eigenvalues λj\lambda_jλj​ with Rej=λjejRe_j=\lambda_j e_jRej​=λj​ej​, and let yyy provide a Hilbert basis (fℓ)ℓ∈L(f_\ell)_{\ell\in L}(fℓ​)ℓ∈L​ and finite nonnegative eigenvalues μℓ\mu_\ellμℓ​ with Sfℓ=μℓfℓSf_\ell=\mu_\ell f_\ellSfℓ​=μℓ​fℓ​. Let T:H→HT:H\to HT:H→H be a bounded operator such that TTT and 1−T1-T1−T are self-adjoint with nonnegative quadratic forms, and let δ>0\delta>0δ>0 be real. Put Pjℓ=λj∣⟨ej,fℓ⟩∣2P_{j\ell}=\lambda_j|\langle e_j,f_\ell\rangle|^2Pjℓ​=λj​∣⟨ej​,fℓ​⟩∣2, Qjℓ=μℓ∣⟨ej,fℓ⟩∣2Q_{j\ell}=\mu_\ell|\langle e_j,f_\ell\rangle|^2Qjℓ​=μℓ​∣⟨ej​,fℓ​⟩∣2, and ab(T,A)=Re⁡∑i⟨bi,TAbi⟩a_b(T,A)=\operatorname{Re}\sum_i\langle b_i,TA b_i\rangleab​(T,A)=Re∑i​⟨bi​,TAbi​⟩. Then, in the extended nonnegative reals,

12(∑(j,ℓ)∈J×LPjℓ≤δQjℓPjℓ+δ∑(j,ℓ)∈J×LδQjℓ<PjℓQjℓ)≤[1−ab(T,R)]++δ[ab(T,S)]+,\frac12\left( \sum_{\substack{(j,\ell)\in J\times L\\P_{j\ell}\le\delta Q_{j\ell}}}P_{j\ell} + \delta\sum_{\substack{(j,\ell)\in J\times L\\\delta Q_{j\ell}<P_{j\ell}}}Q_{j\ell} \right) \le [1-a_b(T,R)]_+ +\delta[a_b(T,S)]_+,21​​(j,ℓ)∈J×LPjℓ​≤δQjℓ​​∑​Pjℓ​+δ(j,ℓ)∈J×LδQjℓ​<Pjℓ​​∑​Qjℓ​​≤[1−ab​(T,R)]+​+δ[ab​(T,S)]+​,

where [x]+=max⁡(x,0)[x]_+=\max(x,0)[x]+​=max(x,0), embedded into the extended nonnegative reals. The first selection includes equality and the second is strict; zero eigenvalues and zero overlaps are included. There are no explicit countability or nonemptiness assumptions on the index types, although the supplied states and Hilbert bases must exist.

Human review
  • Endorsed by Shuze Chen · Nov 1, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Nov 1, 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