# Symplectic matrix

In mathematics, a symplectic matrix is a $2n\times 2n$ matrix $M$ with real entries that satisfies the condition
where $M^{\text{T}}$ denotes the transpose of $M$ and $\Omega$ is a fixed $2n\times 2n$ nonsingular, skew-symmetric matrix. This definition can be extended to $2n\times 2n$ matrices with entries in other fields, such as the complex numbers, finite fields, p-adic numbers, and function fields.
Typically $\Omega$ is chosen to be the block matrix $\Omega ={\begin{bmatrix}0&I_{n}\\-I_{n}&0\\\end{bmatrix}},$ where $I_{n}$ is the $n\times n$ identity matrix. The matrix $\Omega$ has determinant $+1$ and its inverse is $\Omega ^{-1}=\Omega ^{\text{T}}=-\Omega$.

## Properties
### Generators for symplectic matrices

Every symplectic matrix has determinant $+1$, and the $2n\times 2n$ symplectic matrices with real entries form a subgroup of the general linear group $\mathrm {GL} (2n;\mathbb {R} )$ under matrix multiplication since being symplectic is a property stable under matrix multiplication. Topologically, this symplectic group is a connected noncompact real Lie group of real dimension $n(2n+1)$, and is denoted $\mathrm {Sp} (2n;\mathbb {R} )$. The symplectic group can be defined as the set of linear transformations that preserve the symplectic form of a real symplectic vector space.
This symplectic group has a distinguished set of generators, which can be used to find all possible symplectic matrices. This includes the following sets ${\begin{aligned}D(n)=&\left\{{\begin{pmatrix}A&0\\0&(A^{T})^{-1}\end{pmatrix}}:A\in {\text{GL}}(n;\mathbb {R} )\right\}\\N(n)=&\left\{{\begin{pmatrix}I_{n}&B\\0&I_{n}\end{pmatrix}}:B\in {\text{Sym}}(n;\mathbb {R} )\right\}\end{aligned}}$ where ${\text{Sym}}(n;\mathbb {R} )$ is the set of $n\times n$ symmetric matrices. Then, $\mathrm {Sp} (2n;\mathbb {R} )$ is generated by the set$^{p.2}$ $\{\Omega \}\cup D(n)\cup N(n)$ of matrices. In other words, any symplectic matrix can be constructed by multiplying matrices in $D(n)$ and $N(n)$ together, along with some power of $\Omega$.

### Inverse matrix

Every symplectic matrix is invertible with the inverse matrix given by $M^{-1}=\Omega ^{-1}M^{\text{T}}\Omega .$ Furthermore, the product of two symplectic matrices is, again, a symplectic matrix. This gives the set of all symplectic matrices the structure of a group. There exists a natural manifold structure on this group which makes it into a (real or complex) Lie group called the symplectic group.

### Determinantal properties

It follows easily from the definition that the determinant of any symplectic matrix is ±1. Actually, it turns out that the determinant is always +1 for any field. One way to see this is through the use of the Pfaffian and the identity ${\mbox{Pf}}(M^{\text{T}}\Omega M)=\det(M){\mbox{Pf}}(\Omega ).$ Since $M^{\text{T}}\Omega M=\Omega$ and ${\mbox{Pf}}(\Omega )\neq 0$ we have that $\det(M)=1$.
When the underlying field is real or complex, one can also show this by factoring the inequality $\det(M^{\text{T}}M+I)\geq 1$.

### Block form of symplectic matrices

Suppose Ω is given in the standard form and let $M$ be a $2n\times 2n$ block matrix given by $M={\begin{pmatrix}A&B\\C&D\end{pmatrix}}$
where $A,B,C,D$ are $n\times n$ matrices. The condition for $M$ to be symplectic is equivalent to the two following equivalent conditions
   $A^{\text{T}}C,B^{\text{T}}D$ symmetric, and $A^{\text{T}}D-C^{\text{T}}B=I$
   $AB^{\text{T}},CD^{\text{T}}$ symmetric, and $AD^{\text{T}}-BC^{\text{T}}=I$
The second condition comes from the fact that if $M$ is symplectic, then $M^{T}$ is also symplectic. When $n=1$ these conditions reduce to the single condition $\det(M)=1$. Thus a $2\times 2$ matrix is symplectic iff it has unit determinant.

#### Inverse matrix of block matrix

With $\Omega$ in standard form, the inverse of $M$ is given by $M^{-1}=\Omega ^{-1}M^{\text{T}}\Omega ={\begin{pmatrix}D^{\text{T}}&-B^{\text{T}}\\-C^{\text{T}}&A^{\text{T}}\end{pmatrix}}.$ The group has dimension $n(2n+1)$. This can be seen by noting that $(M^{\text{T}}\Omega M)^{\text{T}}=-M^{\text{T}}\Omega M$ is anti-symmetric. Since the space of anti-symmetric matrices has dimension ${\binom {2n}{2}},$ the identity $M^{\text{T}}\Omega M=\Omega$ imposes $2n \choose 2$ constraints on the $(2n)^{2}$ coefficients of $M$ and leaves $M$ with $n(2n+1)$ independent coefficients.

## Symplectic transformations

In the abstract formulation of linear algebra, matrices are replaced with linear transformations of finite-dimensional vector spaces. The abstract analog of a symplectic matrix is a symplectic transformation of a symplectic vector space. Briefly, a symplectic vector space $(V,\omega )$ is a $2n$-dimensional vector space $V$ equipped with a nondegenerate, skew-symmetric bilinear form $\omega$ called the symplectic form.
A symplectic transformation is then a linear transformation $L:V\to V$ which preserves $\omega$, i.e.
    $\omega (Lu,Lv)=\omega (u,v).$
Fixing a basis for $V$, $\omega$ can be written as a matrix $\Omega$ and $L$ as a matrix $M$. The condition that $L$ be a symplectic transformation is precisely the condition that M be a symplectic matrix:
    $M^{\text{T}}\Omega M=\Omega .$
Under a change of basis, represented by a matrix A, we have
    $\Omega \mapsto A^{\text{T}}\Omega A$
    $M\mapsto A^{-1}MA.$
One can always bring $\Omega$ to either the standard form given in the introduction or the block diagonal form described below by a suitable choice of A.

## The matrix Ω

Symplectic matrices are defined relative to a fixed nonsingular, skew-symmetric matrix $\Omega$. As explained in the previous section, $\Omega$ can be thought of as the coordinate representation of a nondegenerate skew-symmetric bilinear form. It is a basic result in linear algebra that any two such matrices differ from each other by a change of basis.
The most common alternative to the standard $\Omega$ given above is the block diagonal form
    $\Omega ={\begin{bmatrix}{\begin{matrix}0&1\\-1&0\end{matrix}}&&0\\&\ddots &\\0&&{\begin{matrix}0&1\\-1&0\end{matrix}}\end{bmatrix}}.$
This choice differs from the previous one by a permutation of basis vectors.
Sometimes the notation $J$ is used instead of $\Omega$ for the skew-symmetric matrix. This is a particularly unfortunate choice as it leads to confusion with the notion of a complex structure, which often has the same coordinate expression as $\Omega$ but represents a very different structure. A complex structure $J$ is the coordinate representation of a linear transformation that squares to $-I_{n}$, whereas $\Omega$ is the coordinate representation of a nondegenerate skew-symmetric bilinear form. One could easily choose bases in which $J$ is not skew-symmetric or $\Omega$ does not square to $-I_{n}$.
Given a hermitian structure on a vector space, $J$ and $\Omega$ are related via
    $\Omega _{ab}=-g_{ac}{J^{c}}_{b}$
where $g_{ac}$ is the metric. That $J$ and $\Omega$ usually have the same coordinate expression (up to an overall sign) is simply a consequence of the fact that the metric g is usually the identity matrix.

## Diagonalization and decomposition

* For any positive definite symmetric $2n\times 2n$ real symplectic matrix $S$, there is a symplectic unitary $U$, $U\in \mathrm {U} (2n,\mathbb {R} )\cap \operatorname {Sp} (2n,\mathbb {R} )=\mathrm {O} (2n)\cap \operatorname {Sp} (2n,\mathbb {R} ),$such that$S=U^{\text{T}}DU\quad {\text{for}}\quad D=\operatorname {diag} (\lambda _{1},\ldots ,\lambda _{n},\lambda _{1}^{-1},\ldots ,\lambda _{n}^{-1}),$where the diagonal elements of $D$ are the eigenvalues of $S$.
* Any real symplectic matrix S has a polar decomposition of the form:$S=UR,$where$U\in \operatorname {Sp} (2n,\mathbb {R} )\cap \operatorname {U} (2n,\mathbb {R} ),$ and$R\in \operatorname {Sp} (2n,\mathbb {R} )\cap \operatorname {Sym} _{+}(2n,\mathbb {R} ).$
* Any real symplectic matrix can be decomposed as a product of three matrices:$S=O{\begin{pmatrix}D&0\\0&D^{-1}\end{pmatrix}}O',$where $O$ and $O'$ are both symplectic and orthogonal, and $D$ is positive-definite and diagonal. This decomposition is closely related to the singular value decomposition of a matrix and is known as an 'Euler' or 'Bloch-Messiah' decomposition.
* The set of orthogonal symplectic matrices forms a (maximal) compact subgroup of the symplectic group. This set is isomorphic to the set of unitary matrices of dimension $n$, $\mathrm {U} (2n,\mathbb {R} )\cap \operatorname {Sp} (2n,\mathbb {R} )=\mathrm {O} (2n)\cap \operatorname {Sp} (2n,\mathbb {R} )\cong \mathrm {U} (n,\mathbb {C} )$. Every symplectic orthogonal matrix can be written as
with $V\in \mathrm {U} (n,\mathbb {C} )$. This equation implies that every symplectic orthogonal matrix has determinant equal to +1 and thus that this is true for all symplectic matrices as its polar decomposition is itself given in terms symplectic matrices.

## Complex matrices

If instead M is a 2n × 2n matrix with complex entries, the definition is not standard throughout the literature. Many authors adjust the definition above to
where M$^*$ denotes the conjugate transpose of M. In this case, the determinant may not be 1, but will have absolute value 1. In the 2×2 case (n=1), M will be the product of a real symplectic matrix and a complex number of absolute value 1.
Other authors retain the definition (1) for complex matrices and call matrices satisfying (3) conjugate symplectic.

## Applications

Transformations described by symplectic matrices play an important role in quantum optics and in continuous-variable quantum information theory. For instance, symplectic matrices can be used to describe Gaussian (Bogoliubov) transformations of a quantum state of light. In turn, the Bloch-Messiah decomposition (2) means that such an arbitrary Gaussian transformation can be represented as a set of two passive linear-optical interferometers (corresponding to orthogonal matrices O and O' ) intermitted by a layer of active non-linear squeezing transformations (given in terms of the matrix D). In fact, one can circumvent the need for such in-line active squeezing transformations if two-mode squeezed vacuum states are available as a prior resource only.