6
$\begingroup$

There exists many different matrices square root. For instance I can define either of the two for square root of $X$:

$$\sqrt{X}^{(1)} \equiv \frac{1}{\sqrt{2 i}} \begin{pmatrix} 1 & i \\ i & 1 \end{pmatrix}$$

Or as suggested on wikipedia:

$$\sqrt{X}^{(2)} \equiv \sqrt{NOT} = \frac{1}{2} \begin{pmatrix} 1+i & 1-i \\ 1-i & 1+i \end{pmatrix} \neq \sqrt{X}^{(1)} $$

We notice that those two matrices do not differ by a global phase: they really act differently on quantum state.

Now, it is frequent in the litterature to simply see $\sqrt{X}$ or $\sqrt{Y}$ without further explanations. To be generic I consider $M$ a matrix in which I will consider its square root.

As long as we do $\sqrt{M} \sqrt{M}$ whatever the definition taken it doesn't matter. However I if we have calculations involving $\sqrt{M}$ without having it directly squared, the result might depend on the choice we took for the square root.

My question

Is there a uniform convention in quantum information to define square root of matrices ? Or more specifically square roots of Pauli ? Or each reference must specify which convention they take ?

$\endgroup$
3
$\begingroup$

In Quirk and in Cirq, the convention used is that the +1 eigenvalue square roots into 1 (as opposed to -1) and that the -1 eigenvalue square roots into $i$ (as opposed to $-i$). More generally, you pick some convention for mapping a unitary eigenvalue $c$ into an angle $\theta$ where $e^{i \theta} = c$, and then define the gate raised to the power $p$ to use the corresponding eigenvalue $e^{i p \theta}$.

For example, the Z operation decomposes like this:

$Z = \begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix} = (+1) |0\rangle \langle 0| + (-1) |1\rangle \langle 1|$

Where the +1 and the -1 on the right hand side are the eigenvalues.

Square rooting the operation will square root the eigenvalues. +1 says +1 and -1 becomes $i$:

$\sqrt{Z} = \sqrt{+1} |0\rangle \langle 0| + \sqrt{-1} |1\rangle \langle 1| = (+1) |0\rangle \langle 0| + (i) |1\rangle \langle 1| = \begin{bmatrix} 1 & 0 \\ 0 & i\end{bmatrix}$

Now let's do $X$:

$X = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix} = (+1) |+\rangle \langle +| + (-1) |-\rangle \langle -|$

where $|+\rangle = \frac{1}{\sqrt{2}}(|0\rangle + |1\rangle)$ and $|-\rangle = \frac{1}{\sqrt{2}}(|0\rangle - |1\rangle)$

So:

$\sqrt{X} = (+1) |+\rangle \langle +| + (i) |-\rangle \langle -| = \begin{bmatrix} 0.5 + 0.5i & 0.5 - 0.5i \\ 0.5 - 0.5i & 0.5 + 0.5i\end{bmatrix}$

And now $Y$:

$Y = \begin{bmatrix} 0 & -i \\ i & 0 \end{bmatrix} = (+1) |i\rangle \langle i| + (-1) |-i\rangle \langle -i|$

where $|i\rangle = \frac{1}{\sqrt{2}}(|0\rangle + i|1\rangle)$ and $|-i\rangle = \frac{1}{\sqrt{2}}(|0\rangle - i|1\rangle)$

So:

$\sqrt{Y} = (+1) |i\rangle \langle i| + (i) |-i\rangle \langle -i| = \begin{bmatrix} 0.5 + 0.5i & -0.5 - 0.5i \\ 0.5 + 0.5i & 0.5 + 0.5i\end{bmatrix}$


Another way to end up at the same convention is to start from the convention that $\sqrt{Z} = S = \begin{bmatrix} 1 & 0 \\ 0 & i \end{bmatrix}$, extend to other exponents using continuity and $Z^{a+b} = Z^{a} Z^{b}$, extend to $X$ by declaring that $X = HZH$ generalizes into $X^t = H Z^t H$, and extend to $Y$ using the right hand rule. Alternatively, you can extend to $Y$ by defining the "swap Y for Z" operation $H_{yz} = (Y + Z) / \sqrt{2}$ and declaring $Y^t = H_{yz} Z^t H_{yz}$.

$\endgroup$
2
  • $\begingroup$ In other words, you're taking the principal square root of the eigenvalues. $\endgroup$ – Mateus Araújo Jan 4 at 18:01
  • $\begingroup$ @MateusAraújo And more generally that's how one usually defines functions on bounded normal operator spaces. You use the spectral theorem (diagonalize), apply the function $f(\lambda_j)$ (defined as the principal branch of the corresponding complex relation) to all diag. elements, then diagonalize back, i.e. $f(T)=\sum_j f(\lambda_j)|t_j><t_j|$, where $|t_j>$ are the eigenvectors. So the choice of the principal branch makes it unique. In a sense, the exact same ambiguity arises when you define functions on complex numbers, and that's why one usually chooses a principal branch and sticks to it. $\endgroup$ – vsoftco Jan 29 at 17:39
5
$\begingroup$

Mathematically a natural choice is to take the square root of the Polar decomposition $A=UP$. Recalling that any complex matrix $A$ can be written as $UP$ for unitary $U$ and positive-semidefinite matrix $P$. The polar decomposition is unique so $P$ has a unique well-defined square root as a positive hermitian matrix. As the convention here is to take the square root of the positive real eigenvalues, which gives a unique square root matrix $P^\tfrac{1}{2}$ (up to change of basis of course). As for the unitary $U$, its eigenvalues are all of the form $e^{i\theta}$ and so taking the square root takes them all to $e^{i\theta/2}$.

However, in quantum computing number theory starts to come into play. It turns out that depending on your choice of universal gate set it's better to perform your arithmetic (gates) over certain number fields. This means that picking the best square root matrix comes down to finding one in the number field that you are working over, which may not be the one that comes from the approach above. So it really depends on the audience you are trying to reach and the type of work you are doing.

$\endgroup$
2
$\begingroup$

You can also characterise the full set of (normal) square roots of a normal matrix via its eigendecomposition. Let $\newcommand{\ketbra}[1]{\lvert #1\rangle\!\langle #1\rvert}A=\sum_k \lambda_k \ketbra{\lambda_k}$ be a matrix with eigenvalues $\lambda_k\in\mathbb C$ and eigenvectors $|\lambda_k\rangle$. Then $$\sqrt A = \sum_k \sqrt{\lambda_k} \ketbra{\lambda_k}.$$ You should now notice that $\sqrt{\lambda_k}$ are not uniquely defined (cue the usual considerations of complex analysis). Different choices of square roots for the eigenalues correspond to (potentially) different square roots of $A$.

As an example, consider $A=X$ (the Pauli $X$ matrix). You have $X=\ketbra+-\ketbra-$, and therefore the four possible normal square roots $$\sqrt X = \pm\ketbra+ \pm i\ketbra-.$$ One can then choose any convention to decide which root to take.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.