Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Section V A, Eqs.(19)–(20): worst-case function-computation error bounds

Proved
QAlgorithms.Papers.Independent.Advance50.P17.worstFunctionError

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

prove2quantum

Let E,F\mathcal E,\mathcal FE,F be fixed CPTP maps on a positive finite-dimensional register with computational basis indexed by xxx, and let f(x)f(x)f(x) be the desired basis outcome. For G∈{E,F}\mathcal G\in\{\mathcal E,\mathcal F\}G∈{E,F}, put eG=max⁡x[1−⟨f(x)∣G(∣x⟩⟨x∣)∣f(x)⟩]e_{\mathcal G}=\max_x[1-\langle f(x)|\mathcal G(|x\rangle\langle x|)|f(x)\rangle]eG​=maxx​[1−⟨f(x)∣G(∣x⟩⟨x∣)∣f(x)⟩]. With DstabD_{\rm stab}Dstab​ the input-sized-ancilla maximum of half trace norm, FstabF_{\rm stab}Fstab​ the corresponding minimum squared fidelity, and Cstab=1−FstabC_{\rm stab}=\sqrt{1-F_{\rm stab}}Cstab​=1−Fstab​​, both bounds hold:

eE≤eF+Dstab(E,F),eE≤(eF+Cstab(E,F))2.e_{\mathcal E}\le e_{\mathcal F}+D_{\rm stab}(\mathcal E,\mathcal F),\qquad e_{\mathcal E}\le\bigl(\sqrt{e_{\mathcal F}}+C_{\rm stab}(\mathcal E,\mathcal F)\bigr)^2.eE​≤eF​+Dstab​(E,F),eE​≤(eF​​+Cstab​(E,F))2.

These give worst-case operational error guarantees for a fixed real and ideal computation.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Advance50_P17
Formal statement
noncomputable section

open MeasureTheory Filter

open scoped Matrix ComplexConjugate Topology

namespace QAlgorithms.Papers.Independent.Advance50.P17

open QAlgorithms.Papers.Independent.Information100.P53 (fidelity)

open QAlgorithms.Papers.Independent.Information100.P08 (canonicalPurification)

open QAlgorithms.Papers.Independent.Information100.P75 (hermitianReal)

variable {I J K : Type} [Fintype I] [Fintype J] [Fintype K]
  [DecidableEq I] [DecidableEq J] [DecidableEq K]
  [Nonempty I] [Nonempty J] [Nonempty K]

/-- Section V A, PDF p.9, Eqs.(19)--(20), Appendix B1, p.13: BOTH worst-case
function-computation guarantees, using actual uniform worst-case ideal error. -/
theorem worstFunctionError (E F : FiniteProcess I I) (f : I → I) :
    worstFunctionErrorProbability E.val f ≤ worstFunctionErrorProbability F.val f + stabDistance (stateDistance .trace) E.val F.val ∧
    worstFunctionErrorProbability E.val f ≤ (Real.sqrt (worstFunctionErrorProbability F.val f) + stabC E.val F.val) ^ 2 := by sorry

end QAlgorithms.Papers.Independent.Advance50.P17

end
Source
Distance measures to compare real and ideal quantum processes, arXiv:quant-ph/0408063v2, PDF p. 9, Section V A, Eqs.(19)–(20): worst-case function-computation error bounds
Read-back

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

Let III be a finite nonempty index type with decidable equality, let E,FE,FE,F be channels on its complex matrices, and let f:I→If:I\to If:I→I be any function. A channel admits a finite representation X↦∑aKaXKa†X\mapsto\sum_aK_aXK_a^\daggerX↦∑a​Ka​XKa†​ with ∑aKa†Ka=1\sum_aK_a^\dagger K_a=1∑a​Ka†​Ka​=1. For the standard basis vector exe_xex​, define

w(G,f)=sup⁡x∈I(1−Re⁡(G(exex†))f(x),f(x)).w(G,f)=\sup_{x\in I}\left(1-\operatorname{Re}(G(e_xe_x^\dagger))_{f(x),f(x)}\right).w(G,f)=x∈Isup​(1−Re(G(ex​ex†​))f(x),f(x)​).

Write Pψ=ψψ†P_\psi=\psi\psi^\daggerPψ​=ψψ†, let identity extension apply a channel to each reference-indexed matrix block, and define

Dstab(E,F)=sup⁡∥ψ∥=1, ψ∈CI×I12Re⁡tr⁡(Aψ−Bψ)†(Aψ−Bψ),Fstab(E,F)=inf⁡∥ψ∥=1, ψ∈CI×I(Re⁡tr⁡Aψ BψAψ)2,\begin{aligned} D_{\mathrm{stab}}(E,F)&=\sup_{\|\psi\|=1,\ \psi\in\mathbb C^{I\times I}} \tfrac12\operatorname{Re}\operatorname{tr}\sqrt{(A_\psi-B_\psi)^\dagger(A_\psi-B_\psi)},\\ F_{\mathrm{stab}}(E,F)&=\inf_{\|\psi\|=1,\ \psi\in\mathbb C^{I\times I}} \left(\operatorname{Re}\operatorname{tr}\sqrt{\sqrt{A_\psi}\,B_\psi\sqrt{A_\psi}}\right)^2, \end{aligned}Dstab​(E,F)Fstab​(E,F)​=∥ψ∥=1, ψ∈CI×Isup​21​Retr(Aψ​−Bψ​)†(Aψ​−Bψ​)​,=∥ψ∥=1, ψ∈CI×Iinf​(RetrAψ​​Bψ​Aψ​​​)2,​

where Aψ=(id⁡I⊗E)(Pψ)A_\psi=(\operatorname{id}_I\otimes E)(P_\psi)Aψ​=(idI​⊗E)(Pψ​), Bψ=(id⁡I⊗F)(Pψ)B_\psi=(\operatorname{id}_I\otimes F)(P_\psi)Bψ​=(idI​⊗F)(Pψ​), and square roots use matrix functional calculus. Then both bounds hold:

w(E,f)≤w(F,f)+Dstab(E,F),w(E,f)≤(w(F,f)+1−Fstab(E,F))2.w(E,f)\le w(F,f)+D_{\mathrm{stab}}(E,F),\qquad w(E,f)\le\left(\sqrt{w(F,f)}+\sqrt{1-F_{\mathrm{stab}}(E,F)}\right)^2.w(E,f)≤w(F,f)+Dstab​(E,F),w(E,f)≤(w(F,f)​+1−Fstab​(E,F)​)2.
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