Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Explicit six-qubit commutator identity

Open
QAlgorithms.Papers.Independent.Advance50.P49.six_wire_commutator

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

prove2quantum

Use the physical register Hn=(C2)⊗n\mathcal H_n=(\mathbb C^2)^{\otimes n}Hn​=(C2)⊗n. Rotational invariance means commuting with U⊗nU^{\otimes n}U⊗n for every one-qubit unitary UUU. The legal spins are j=n/2−rj=n/2-rj=n/2−r, r=0,…,⌊n/2⌋r=0,\ldots,\lfloor n/2\rfloorr=0,…,⌊n/2⌋, and Πj\Pi_jΠj​ is the actual spectral projector of J2J^2J2 at j(j+1)j(j+1)j(j+1). Write Rab=(XaXb+YaYb+ZaZb)/2R_{ab}=(X_aX_b+Y_aY_b+Z_aZ_b)/2Rab​=(Xa​Xb​+Ya​Yb​+Za​Zb​)/2 and Vk,vk\mathcal V_k,\mathfrak v_kVk​,vk​ for the group of finite compositions of kkk-local invariant gates and its generated real Lie algebra, including scalar phases. Exchange-only circuits contain finite products of e−itRabe^{-itR_{ab}}e−itRab​ with real ttt. Set C0=IC_0=IC0​=I and, for even l>0l>0l>0, Cl=(l/2)!−1∑i1,…,il distinctRi1i2⋯Ril−1ilC_l=(l/2)!^{-1}\sum_{i_1,\ldots,i_l\ \mathrm{distinct}}R_{i_1i_2}\cdots R_{i_{l-1}i_l}Cl​=(l/2)!−1∑i1​,…,il​ distinct​Ri1​i2​​⋯Ril−1​il​​. Extend Cl=0C_l=0Cl​=0 above 2⌊n/2⌋2\lfloor n/2\rfloor2⌊n/2⌋. Its sector eigenvalue is cl(j)=Tr⁡(ClΠj)/Tr⁡(Πj)c_l(j)=\operatorname{Tr}(C_l\Pi_j)/\operatorname{Tr}(\Pi_j)cl​(j)=Tr(Cl​Πj​)/Tr(Πj​). All body-index sums below are over even indices.

For any six distinct physical wires, let [A,B]=AB−BA[A,B]=AB-BA[A,B]=AB−BA. Then

4(R12R34−R34R56)=−[[[[R12,R23],R34],R45],R51]−[[[[R23,R34],R45],R56],R62]−[[R13,R23],R24]+[[R35,R45],R46].4(R_{12}R_{34}-R_{34}R_{56})=-[[[[R_{12},R_{23}],R_{34}],R_{45}],R_{51}]-[[[[R_{23},R_{34}],R_{45}],R_{56}],R_{62}]-[[R_{13},R_{23}],R_{24}]+[[R_{35},R_{45}],R_{46}].4(R12​R34​−R34​R56​)=−[[[[R12​,R23​],R34​],R45​],R51​]−[[[[R23​,R34​],R45​],R56​],R62​]−[[R13​,R23​],R24​]+[[R35​,R45​],R46​].

All brackets are left nested. Dividing the right side by four and preparing wires 5,6 in ∣00⟩|00\rangle∣00⟩ gives the action of R12R34−R34/2R_{12}R_{34}-R_{34}/2R12​R34​−R34​/2 on every four-qubit vector. Also S=I/4+(R12+R34)/2+R12R34S=I/4+(R_{12}+R_{34})/2+R_{12}R_{34}S=I/4+(R12​+R34​)/2+R12​R34​. These identities supply the explicit base construction up to the swap's scalar shift.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Advance50_P49
Formal statement
noncomputable section

namespace QAlgorithms.Papers.Independent.Advance50.P49

open scoped Classical Matrix ComplexConjugate Matrix.Norms.Frobenius

open MeasureTheory

attribute [local instance 100] LieRing.ofAssociativeRing

-- Specialize the frozen generic aliases without declaring new aliases.

local notation "Op" => (fun n : ℕ => QAlgorithms.Papers.Independent.Information100.P21.Op (Qubits n))

local notation "Vec" => (fun n : ℕ => QAlgorithms.Papers.Independent.Information100.P21.Vec (Qubits n))

-- The frozen support predicate takes the support before the operator.

local notation "WireSupported" => QAlgorithms.Papers.Independent.Information100.P69.Supported

/-- PDF pp.5,34, I32: exact left-nested six-wire identity, and the corresponding
four-qubit action when wires 5,6 are prepared in |00⟩. -/
theorem six_wire_commutator (n : ℕ) (w : Fin 6 ↪ Fin n) :
    (4 : ℂ) • (heisenbergExchange (w 0) (w 1)*heisenbergExchange (w 2) (w 3) -
      heisenbergExchange (w 2) (w 3)*heisenbergExchange (w 4) (w 5)) =
      commutatorTemplate w (templateSeeds w) ∧
    multiSwap 2 = (1/4 : ℂ) • (1 : Op 4) +
      (1/2 : ℂ) • (heisenbergExchange (0 : Fin 4) 1+heisenbergExchange (2 : Fin 4) 3) + standardQ 4 4 ∧
    (∀ psi : Vec 4,
      act ((1/4 : ℂ) • commutatorTemplate (Function.Embedding.refl (Fin 6))
        (templateSeeds (Function.Embedding.refl (Fin 6)))) (tensorState psi (zeroKet 2)) =
        tensorState (act (standardQ 4 4-(1/2 : ℂ) • heisenbergExchange (2 : Fin 4) 3) psi) (zeroKet 2)) := by sorry

end QAlgorithms.Papers.Independent.Advance50.P49

end
Source
Rotationally-Invariant Circuits: Universality with the exchange interaction and two ancilla qubits, arXiv:2202.01963v1, PDF p. 34, Explicit six-qubit commutator identity
Read-back

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

For every natural number nnn and every injection w:{0,…,5}↪{0,…,n−1}w:\{0,\ldots,5\}\hookrightarrow\{0,\ldots,n-1\}w:{0,…,5}↪{0,…,n−1}, put Eab=12(XaXb+YaYb+ZaZb)E_{ab}=\tfrac12(X_aX_b+Y_aY_b+Z_aZ_b)Eab​=21​(Xa​Xb​+Ya​Yb​+Za​Zb​), where X,Y,ZX,Y,ZX,Y,Z are the Pauli matrices acting on the indicated wires, and write Rab=Ew(a),w(b)R_{ab}=E_{w(a),w(b)}Rab​=Ew(a),w(b)​. For matrices let [A,B]=AB−BA[A,B]=AB-BA[A,B]=AB−BA, and define

Cw(F)=−[[[[F0,R12],R23],R34],R40]−[[[[F1,R23],R34],R45],R51]−[[F2,R12],R13]+[[F3,R34],R35],F=(R01,R12,R02,R24).\mathcal C_w(F)= -[[[[F_0,R_{12}],R_{23}],R_{34}],R_{40}] -[[[[F_1,R_{23}],R_{34}],R_{45}],R_{51}] -[[F_2,R_{12}],R_{13}] +[[F_3,R_{34}],R_{35}], \qquad F=(R_{01},R_{12},R_{02},R_{24}).Cw​(F)=−[[[[F0​,R12​],R23​],R34​],R40​]−[[[[F1​,R23​],R34​],R45​],R51​]−[[F2​,R12​],R13​]+[[F3​,R34​],R35​],F=(R01​,R12​,R02​,R24​).

The declaration asserts all three identities

4(R01R23−R23R45)=Cw(F),S01S23=14I+12(E01+E23)+E01E23,4(R_{01}R_{23}-R_{23}R_{45})=\mathcal C_w(F),\qquad S_{01}S_{23}=\tfrac14 I+\tfrac12(E_{01}+E_{23})+E_{01}E_{23},4(R01​R23​−R23​R45​)=Cw​(F),S01​S23​=41​I+21​(E01​+E23​)+E01​E23​,

and

14Cid(E01,E12,E02,E24)(ψ⊠∣02⟩)=((E01E23−12E23)ψ)⊠∣02⟩for every ψ∈C{0,1}4.\frac14\mathcal C_{\mathrm{id}}(E_{01},E_{12},E_{02},E_{24}) \bigl(\psi\boxtimes|0_2\rangle\bigr) = \bigl((E_{01}E_{23}-\tfrac12E_{23})\psi\bigr)\boxtimes|0_2\rangle \quad\text{for every }\psi\in\mathbb C^{\{0,1\}^4}.41​Cid​(E01​,E12​,E02​,E24​)(ψ⊠∣02​⟩)=((E01​E23​−21​E23​)ψ)⊠∣02​⟩for every ψ∈C{0,1}4.

Here the second identity is on four wires, SabS_{ab}Sab​ exchanges wires a,ba,ba,b, and the third identity uses the identity injection on six wires; ⊠\boxtimes⊠ concatenates registers and ∣02⟩|0_2\rangle∣02​⟩ is the basis vector indexed by 000000. There is no normalization assumption on ψ\psiψ. An injection www cannot exist when n<6n<6n<6, so those values of nnn supply no instance of the hypotheses.

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