Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 6: symmetric Haar twirl equals permutation twirl

Open
QAlgorithms.Papers.Independent.Extend50.P09.symmetric_haar_permutation_twirl

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

prove2quantum

Let d≥2d\ge2d≥2, n≥1n\ge1n≥1, and let MMM be any operator on (Cd)⊗n(\mathbb C^d)^{\otimes n}(Cd)⊗n. Let VVV have normalized Haar law on the actual determinant-one commutant of collective SU(d)SU(d)SU(d). For π∈Sn\pi\in S_nπ∈Sn​, let Oπ∣i1,…,in⟩=∣iπ−1(1),…,iπ−1(n)⟩O_\pi|i_1,\ldots,i_n\rangle=|i_{\pi^{-1}(1)},\ldots,i_{\pi^{-1}(n)}\rangleOπ​∣i1​,…,in​⟩=∣iπ−1(1)​,…,iπ−1(n)​⟩. Then

EVVMV†=1n!∑π∈SnOπMOπ†.\mathbb E_VVMV^\dagger=\frac1{n!}\sum_{\pi\in S_n}O_\pi MO_\pi^\dagger.EV​VMV†=n!1​π∈Sn​∑​Oπ​MOπ†​.

The operator need not be positive or normalized. Scalar phases repair determinants of permutation matrices and cancel in conjugation; independent special-unitary multiplicity-block sampling is not used.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Extend50_P09
Formal statement
noncomputable section

open scoped Matrix Matrix.Norms.Elementwise ComplexConjugate ENNReal ComplexOrder

open MeasureTheory Filter

namespace QAlgorithms.Papers.Independent.Extend50.P09

attribute [local instance] Classical.propDecidable Classical.decEq

-- Exact generic definitions from the pinned accepted library.

open QAlgorithms.Papers.Independent.Information100.P22 (Op mixed bell)

open QAlgorithms.Papers.Independent.Information100.P67 (conditionalMinEntropy)

open QAlgorithms.Papers.Independent.Advance50.P02 (negLog)

attribute [local instance] QAlgorithms.Papers.Independent.Extend50.P09.covariantMatrixMeasurable

attribute [local instance] QAlgorithms.Papers.Independent.Extend50.P09.covariantMatrixBorel

/-- Lemma 6, PDF p.21, (D1): arbitrary operator; actual determinant-one
commutant, with projective phases cancelling in conjugation. -/
theorem symmetric_haar_permutation_twirl (d n : ℕ) (hd : 2 ≤ d) (hn : 1 ≤ n)
    (mu : Measure (Op (CovariantWord d n))) (hmu : IsCommutantHaarLaw (SUGroup d n) mu)
    (M : Op (CovariantWord d n)) :
    (∫ V, V*M*Vᴴ ∂mu) = (n.factorial : ℂ)⁻¹ •
      ∑ pi : Equiv.Perm (Fin n), Schur.tensorPermutation d n pi * M *
        (Schur.tensorPermutation d n pi)ᴴ := by sorry

end QAlgorithms.Papers.Independent.Extend50.P09

end
Source
Near-optimal covariant quantum error-correcting codes from random unitaries with symmetries, arXiv:2112.01498v2, PDF p. 21, Lemma 6: symmetric Haar twirl equals permutation twirl
Read-back

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

For natural numbers d≥2d\ge2d≥2 and n≥1n\ge1n≥1, write Wd,n={0,…,d−1}nW_{d,n}=\{0,\ldots,d-1\}^nWd,n​={0,…,d−1}n. Let μ\muμ be a Borel probability measure on complex matrices indexed by Wd,nW_{d,n}Wd,n​, giving measure zero to matrices outside the set of matrices VVV satisfying V†V=IV^\dagger V=IV†V=I, det⁡V=1\det V=1detV=1, and

VU⊗n=U⊗nVfor every U∈Cd×d with U†U=I, det⁡U=1,VU^{\otimes n}=U^{\otimes n}V \quad\text{for every }U\in\mathbb C^{d\times d} \text{ with }U^\dagger U=I,\ \det U=1,VU⊗n=U⊗nVfor every U∈Cd×d with U†U=I, detU=1,

where (U⊗n)x,y=∏i=0n−1Uxi,yi(U^{\otimes n})_{x,y}=\prod_{i=0}^{n-1}U_{x_i,y_i}(U⊗n)x,y​=∏i=0n−1​Uxi​,yi​​. Assume also that μ\muμ is invariant under left multiplication by every such VVV. Then, for every complex matrix MMM indexed by Wd,nW_{d,n}Wd,n​, without any positivity or Hermiticity requirement,

∫VMV† dμ(V)=1n!∑π∈SnTπMTπ†,(Tπ)y,x=1y=x∘π−1.\int VMV^\dagger\,d\mu(V) = \frac1{n!}\sum_{\pi\in S_n}T_\pi MT_\pi^\dagger, \qquad (T_\pi)_{y,x}=\mathbf1_{y=x\circ\pi^{-1}}.∫VMV†dμ(V)=n!1​π∈Sn​∑​Tπ​MTπ†​,(Tπ​)y,x​=1y=x∘π−1​.
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