Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Remark 2: finite quadrature for compact-group tests

Open
QAlgorithms.Papers.Independent.Extend50.P47.compact_quadrature

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

prove2quantum

Every register has a fixed finite nonempty computational basis. States are positive semidefinite trace-one matrices, and pure vectors have norm one. Write F(ρ,σ)=∥ρσ∥12F(\rho,\sigma)=\|\sqrt\rho\sqrt\sigma\|_1^2F(ρ,σ)=∥ρ​σ​∥12​ for squared fidelity.

For a continuous ordinary unitary representation of a compact Lie group on a nonzero finite register, normalized Haar average Π has a finite convex-combination expression Σj pj U(gj). Preparing Σj sqrt(pj)|j⟩, controlling U(gj), and projecting back gives probability Tr(Πρ) for a density input (pure-state form as printed); no efficient construction of p or its state preparation is asserted.

Π=∫GU(g) dμ(g)=∑i=1NpiU(gi),pi≥0,∑ipi=1,pacc=Tr⁡(Πρ).\Pi=\int_G U(g)\,d\mu(g)=\sum_{i=1}^N p_iU(g_i),\qquad p_i\ge0,\quad\sum_i p_i=1,\quad p_{\rm acc}=\operatorname{Tr}(\Pi\rho).Π=∫G​U(g)dμ(g)=i=1∑N​pi​U(gi​),pi​≥0,i∑​pi​=1,pacc​=Tr(Πρ).

μ\muμ is normalized Haar measure on a compact finite-dimensional real Lie group, and UUU is continuous. The controlled test prepares ∑ipi∣i⟩\sum_i\sqrt{p_i}|i\rangle∑i​pi​​∣i⟩ and projects back to that same control state.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Extend50_P47
Formal statement
noncomputable section

namespace QAlgorithms.Papers.Independent.Extend50.P47

open scoped ComplexConjugate ComplexOrder Matrix Matrix.Norms.L2Operator Manifold ContDiff

open MeasureTheory

open QAlgorithms.Papers.Independent.Information100.P60 (Mat)

open QAlgorithms.Papers.Independent.Information100.P56 (normalizedChoi)

variable {G S R P T A B C D R2 S2 : Type*}

variable [Fintype G] [Group G] [DecidableEq G]

variable [Fintype S] [DecidableEq S] [Nonempty S]

variable [Fintype R] [DecidableEq R] [Nonempty R]

variable [Fintype P] [DecidableEq P] [Nonempty P]

variable [Fintype T] [DecidableEq T] [Nonempty T]

variable [Fintype A] [DecidableEq A] [Nonempty A]

variable [Fintype B] [DecidableEq B] [Nonempty B]

variable [Fintype C] [DecidableEq C] [Nonempty C]

variable [Fintype D] [DecidableEq D] [Nonempty D]

variable [Fintype R2] [DecidableEq R2] [Nonempty R2]

variable [Fintype S2] [DecidableEq S2] [Nonempty S2]

/-- PDF pp.12–13, Remark 2: exact finite probability quadrature of the Haar
average of a continuous finite-dimensional unitary representation. No synthesis
or preparation complexity is asserted. Haar measure is normalized to total mass one. -/
theorem compact_quadrature [Nonempty S] {H E : Type*}
    [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E]
    [Group H] [TopologicalSpace H] [T2Space H] [SecondCountableTopology H]
    [ChartedSpace E H] [LieGroup (𝓘(ℝ, E)) ∞ H]
    [IsTopologicalGroup H] [CompactSpace H] [MeasurableSpace H] [BorelSpace H]
    (mu : Measure H) [Measure.IsHaarMeasure mu] [IsProbabilityMeasure mu]
    (U : H →* Matrix.unitaryGroup S ℂ)
    (hcont : Continuous (fun g => (U g : Mat S))) :
    ∃ (n : ℕ) (g : Fin n → H) (p : Fin n → ℝ),
      (∀ i, 0 ≤ p i) ∧ (∑ i, p i = 1) ∧
      (∫ h, (U h : Mat S) ∂mu) = ∑ i, (p i : ℂ) • (U (g i) : Mat S) ∧
      ∀ rho : Mat S, IsDensityMatrix rho →
        controlReturnProbability (∑ i, (p i : ℂ) • (U (g i) : Mat S)) rho =
          effectProb (∫ h, (U h : Mat S) ∂mu) rho := by sorry

end QAlgorithms.Papers.Independent.Extend50.P47

end
Source
Testing symmetry on quantum computers, arXiv:2105.12758v3, PDF p. 12, Remark 2: finite quadrature for compact-group tests
Read-back

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

Let SSS be a nonempty finite index type with decidable equality. Let EEE be a finite-dimensional real normed vector space, and let HHH be a group equipped with a compact, Hausdorff, second-countable topology, a charted-space structure modeled on EEE, and a smooth real Lie-group structure; assume also that its group operations are continuous and that its measurable structure is the Borel structure. Let μ\muμ be a Haar measure on HHH that is a probability measure, and let U:H→U(CS)U:H\to\mathrm U(\mathbb C^S)U:H→U(CS) be a group homomorphism whose underlying matrix-valued function is continuous. There exist a natural number nnn, elements g0,…,gn−1∈Hg_0,\ldots,g_{n-1}\in Hg0​,…,gn−1​∈H, and real weights pi≥0p_i\ge0pi​≥0 with ∑ipi=1\sum_i p_i=1∑i​pi​=1, such that, writing K=∑ipiU(gi)K=\sum_i p_iU(g_i)K=∑i​pi​U(gi​),

∫HU(h) dμ(h)=K,Re⁡Tr⁡(K†Kρ)=Re⁡Tr⁡ ⁣[(∫HU(h) dμ(h))ρ]\int_H U(h)\,d\mu(h)=K, \qquad \operatorname{Re}\operatorname{Tr}(K^\dagger K\rho) = \operatorname{Re}\operatorname{Tr}\!\left[\left(\int_HU(h)\,d\mu(h)\right)\rho\right]∫H​U(h)dμ(h)=K,ReTr(K†Kρ)=ReTr[(∫H​U(h)dμ(h))ρ]

for every positive semidefinite matrix ρ\rhoρ on CS\mathbb C^SCS with trace 111. The integrals are matrix-valued Bochner integrals. Although nnn is quantified over all natural numbers, the weight-sum condition excludes n=0n=0n=0.

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

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Oct 30, 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