Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Four opposite phase rotations: exact symmetric matrix average and polar form

Proved
QAlgorithms.Papers.Independent.Advance50.P42.fourPhase_matrix_average

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

prove2quantum

Let σ=(σij)i,j=14\sigma=(\sigma_{ij})_{i,j=1}^4σ=(σij​)i,j=14​ be an arbitrary symmetric real matrix and let

X(ϕ)=(cos⁡ϕsin⁡ϕ00−sin⁡ϕcos⁡ϕ0000cos⁡ϕ−sin⁡ϕ00sin⁡ϕcos⁡ϕ).X(\phi)=\begin{pmatrix} \cos\phi&\sin\phi&0&0\\-\sin\phi&\cos\phi&0&0\\ 0&0&\cos\phi&-\sin\phi\\0&0&\sin\phi&\cos\phi \end{pmatrix}.X(ϕ)=​cosϕ−sinϕ00​sinϕcosϕ00​00cosϕsinϕ​00−sinϕcosϕ​​.

Its average over the four phases is exactly

14∑k=03X(πk/2)σX(πk/2)T=12(σ11+σ220σ13−σ24σ14+σ230σ11+σ22σ14+σ23−(σ13−σ24)σ13−σ24σ14+σ23σ33+σ440σ14+σ23−(σ13−σ24)0σ33+σ44).\frac14\sum_{k=0}^{3}X(\pi k/2)\sigma X(\pi k/2)^{T} =\frac12\begin{pmatrix} \sigma_{11}+\sigma_{22}&0&\sigma_{13}-\sigma_{24}&\sigma_{14}+\sigma_{23}\\ 0&\sigma_{11}+\sigma_{22}&\sigma_{14}+\sigma_{23}&-(\sigma_{13}-\sigma_{24})\\ \sigma_{13}-\sigma_{24}&\sigma_{14}+\sigma_{23}&\sigma_{33}+\sigma_{44}&0\\ \sigma_{14}+\sigma_{23}&-(\sigma_{13}-\sigma_{24})&0&\sigma_{33}+\sigma_{44} \end{pmatrix}.41​k=0∑3​X(πk/2)σX(πk/2)T=21​​σ11​+σ22​0σ13​−σ24​σ14​+σ23​​0σ11​+σ22​σ14​+σ23​−(σ13​−σ24​)​σ13​−σ24​σ14​+σ23​σ33​+σ44​0​σ14​+σ23​−(σ13​−σ24​)0σ33​+σ44​​​.

Equivalently this matrix is (a0c2c10ac1−c2c2c1b0c1−c20b)\begin{pmatrix}a&0&c_2&c_1\\0&a&c_1&-c_2\\c_2&c_1&b&0\\c_1&-c_2&0&b\end{pmatrix}​a0c2​c1​​0ac1​−c2​​c2​c1​b0​c1​−c2​0b​​, where a=(σ11+σ22)/2a=(\sigma_{11}+\sigma_{22})/2a=(σ11​+σ22​)/2, b=(σ33+σ44)/2b=(\sigma_{33}+\sigma_{44})/2b=(σ33​+σ44​)/2, c1=(σ14+σ23)/2c_1=(\sigma_{14}+\sigma_{23})/2c1​=(σ14​+σ23​)/2, and c2=(σ13−σ24)/2c_2=(\sigma_{13}-\sigma_{24})/2c2​=(σ13​−σ24​)/2. With z=c12+c22z=\sqrt{c_1^2+c_2^2}z=c12​+c22​​ there exists θ∈R\theta\in\mathbb Rθ∈R such that c1=zsin⁡θc_1=z\sin\thetac1​=zsinθ and c2=zcos⁡θc_2=z\cos\thetac2​=zcosθ, giving the entire polar matrix in (157), including z=0z=0z=0.

This identity describes the finite matrix average in Appendix B. For an arbitrary real symmetric matrix no uncertainty constraint or bounds a,b≥1a,b\ge1a,b≥1 are asserted. Applying it to the centered covariance of a mixed quantum state requires a separate means argument.

Formalization Note Coordinates are zero-based in Lean. The printed formula θ=arctan⁡(c1/c2)\theta=\arctan(c_1/c_2)θ=arctan(c1​/c2​) is replaced by existence of a polar angle, avoiding division by zero and the wrong quadrant. This is the pinned correction for the algebraic node; independent moderation is pending.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Advance50_P42
Formal statement
noncomputable section

open scoped BigOperators Matrix

namespace QAlgorithms.Papers.Independent.Advance50.P42

/-- Appendix B, (153)--(157), PDF pp.20--21: the full four-phase real-matrix
identity, parameter identifications, and polar representation.
Source correction: the printed arctan(c1/c2) is replaced by existence of an angle,
which is the polar-representation claim used by (157), valid also when c2=0
or both mixed entries vanish. The arbitrary symmetric-matrix scope does not imply
these matrices are quantum covariances, nor the physical bounds a,b >= 1. -/
theorem fourPhase_matrix_average
    (sigma : Matrix (Fin 4) (Fin 4) ℝ) (hsigma : sigma.IsSymm) :
    let a := (sigma 0 0 + sigma 1 1) / 2
    let b := (sigma 2 2 + sigma 3 3) / 2
    let c1 := (sigma 0 3 + sigma 1 2) / 2
    let c2 := (sigma 0 2 - sigma 1 3) / 2
    let z := Real.sqrt (c1 ^ 2 + c2 ^ 2)
    fourPhaseAverage sigma = (1 / 2 : ℝ) •
      !![sigma 0 0 + sigma 1 1, 0, sigma 0 2 - sigma 1 3, sigma 0 3 + sigma 1 2;
         0, sigma 0 0 + sigma 1 1, sigma 0 3 + sigma 1 2, -(sigma 0 2 - sigma 1 3);
         sigma 0 2 - sigma 1 3, sigma 0 3 + sigma 1 2, sigma 2 2 + sigma 3 3, 0;
         sigma 0 3 + sigma 1 2, -(sigma 0 2 - sigma 1 3), 0, sigma 2 2 + sigma 3 3] ∧
    fourPhaseAverage sigma = phaseSymmetricMatrix a b c1 c2 ∧
    ∃ theta : ℝ, c1 = z * Real.sin theta ∧ c2 = z * Real.cos theta ∧
      fourPhaseAverage sigma =
        phaseSymmetricMatrix a b (z * Real.sin theta) (z * Real.cos theta) := by sorry

end QAlgorithms.Papers.Independent.Advance50.P42

end
Source
Asymptotic security of discrete-modulation protocols for continuous-variable quantum key distribution, arXiv:1901.10099v4, PDF p. 21, Appendix B, (153)–(157)
Read-back

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

For every real 4×44\times44×4 matrix σ=(σij)i,j=03\sigma=(\sigma_{ij})_{i,j=0}^{3}σ=(σij​)i,j=03​ satisfying σT=σ\sigma^{\mathsf T}=\sigmaσT=σ, set

a=σ00+σ112,b=σ22+σ332,c1=σ03+σ122,c2=σ02−σ132,z=c12+c22.a=\frac{\sigma_{00}+\sigma_{11}}2,\qquad b=\frac{\sigma_{22}+\sigma_{33}}2,\qquad c_1=\frac{\sigma_{03}+\sigma_{12}}2,\qquad c_2=\frac{\sigma_{02}-\sigma_{13}}2,\qquad z=\sqrt{c_1^2+c_2^2}.a=2σ00​+σ11​​,b=2σ22​+σ33​​,c1​=2σ03​+σ12​​,c2​=2σ02​−σ13​​,z=c12​+c22​​.

Define the notation

R(ϕ)=(cos⁡ϕsin⁡ϕ00−sin⁡ϕcos⁡ϕ0000cos⁡ϕ−sin⁡ϕ00sin⁡ϕcos⁡ϕ),A(σ)=14∑k=03R ⁣(πk2)σR ⁣(πk2)T,R(\phi)= \begin{pmatrix} \cos\phi&\sin\phi&0&0\\ -\sin\phi&\cos\phi&0&0\\ 0&0&\cos\phi&-\sin\phi\\ 0&0&\sin\phi&\cos\phi \end{pmatrix}, \qquad A(\sigma)=\frac14\sum_{k=0}^{3} R\!\left(\frac{\pi k}{2}\right)\sigma R\!\left(\frac{\pi k}{2}\right)^{\mathsf T},R(ϕ)=​cosϕ−sinϕ00​sinϕcosϕ00​00cosϕsinϕ​00−sinϕcosϕ​​,A(σ)=41​k=0∑3​R(2πk​)σR(2πk​)T,

and, for real x,y,u,vx,y,u,vx,y,u,v,

M(x,y,u,v)=(x0vu0xu−vvuy0u−v0y).M(x,y,u,v)= \begin{pmatrix} x&0&v&u\\ 0&x&u&-v\\ v&u&y&0\\ u&-v&0&y \end{pmatrix}.M(x,y,u,v)=​x0vu​0xu−v​vuy0​u−v0y​​.

Then all three of the following assertions hold:

A(σ)=12(σ00+σ110σ02−σ13σ03+σ120σ00+σ11σ03+σ12−(σ02−σ13)σ02−σ13σ03+σ12σ22+σ330σ03+σ12−(σ02−σ13)0σ22+σ33),A(\sigma)=\frac12 \begin{pmatrix} \sigma_{00}+\sigma_{11}&0&\sigma_{02}-\sigma_{13}&\sigma_{03}+\sigma_{12}\\ 0&\sigma_{00}+\sigma_{11}&\sigma_{03}+\sigma_{12}&-(\sigma_{02}-\sigma_{13})\\ \sigma_{02}-\sigma_{13}&\sigma_{03}+\sigma_{12}&\sigma_{22}+\sigma_{33}&0\\ \sigma_{03}+\sigma_{12}&-(\sigma_{02}-\sigma_{13})&0&\sigma_{22}+\sigma_{33} \end{pmatrix},A(σ)=21​​σ00​+σ11​0σ02​−σ13​σ03​+σ12​​0σ00​+σ11​σ03​+σ12​−(σ02​−σ13​)​σ02​−σ13​σ03​+σ12​σ22​+σ33​0​σ03​+σ12​−(σ02​−σ13​)0σ22​+σ33​​​, A(σ)=M(a,b,c1,c2),A(\sigma)=M(a,b,c_1,c_2),A(σ)=M(a,b,c1​,c2​),

and there exists a real number θ\thetaθ such that

c1=zsin⁡θ,c2=zcos⁡θ,A(σ)=M(a,b,zsin⁡θ,zcos⁡θ).c_1=z\sin\theta,\qquad c_2=z\cos\theta,\qquad A(\sigma)=M(a,b,z\sin\theta,z\cos\theta).c1​=zsinθ,c2​=zcosθ,A(σ)=M(a,b,zsinθ,zcosθ).

The assertion includes the case c1=c2=0c_1=c_2=0c1​=c2​=0, where z=0z=0z=0 and every real θ\thetaθ satisfies the stated conditions; uniqueness of θ\thetaθ is not asserted.

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