# How can I simulate the following 2×2 Hamiltonian $e^{i\begin{bmatrix} 8 & 6+i \\ 6-i & -1\end{bmatrix}}$?

How can I simulate the following 2×2 Hamiltonian $$e^{i\begin{bmatrix} 8 & 6+i \\ 6-i & -1\end{bmatrix}}|\Psi\rangle$$

ie. how to rewrite that matrix exponential in terms of other, well-used quantum gates such as X, Y, Z, CNOT, and other standard gates in quantum computing?

Proof of identity due to @DaftWullie's answer:

$$\boxed{(aX+bY+cZ)^2 = (a^2+b^2+c^2)I}$$

$$\left(a\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix} + b\begin{bmatrix} 0 & -i \\ i & 0 \end{bmatrix} + c\begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix}\right)^2 = \begin{bmatrix} c & a-bi \\ a+bi & -c \end{bmatrix}\begin{bmatrix} c & a-bi \\ a+bi & -c \end{bmatrix}$$

$$=\begin{bmatrix} c^2 + (a^2 - (bi)^2) & ca-cbi - ca + cbi \\ ca+cbi-ca-cbi & (a^2-(bi)^2 + c^2 \end{bmatrix}=\begin{bmatrix} a^2+b^2+c^2 & 0 \\ 0 & a^2+b^2+c^2 \end{bmatrix} = (a^2+b^2+c^2)I$$

Start by decomposing the Hamiltonian in terms of the Pauli matrices: $$\begin{bmatrix} 8 & 6+i \\ 6-i & -1\end{bmatrix}=6X-Y+\frac{7}{2}I+\frac{9}{2}Z.$$ Now, you can rewrite this as $$\frac{7}{2}I+\sqrt{6^2+1^2+\left(\frac{9}{2}\right)^2}\sigma$$ where $$\sigma=\frac{6X-Y+\frac{9}{2}Z}{\sqrt{6^2+1^2+\left(\frac{9}{2}\right)^2}}.$$ Why have I done it like this? The key property here is that $$\sigma^2=I$$, which means I can rewrite the whole evolution as $$e^{7i/2}e^{i\sigma\sqrt{229}/2}=e^{7i/2}\left(\cos(\sqrt{229}/2)I+i\sin(\sqrt{229}/2)\sigma\right).$$ This is a rotation by an angle $$\sqrt{229}\text{ mod }2\pi$$ about the axis $$\sigma$$. You can neglect the global phase has have no relevance (unless you intend this to be a controlled-unitary). You can now directly decompose this in terms of Euler anglers, i.e. a $$Z$$ rotation, followed by and $$X$$ rotation followed by a $$Z$$ rotation. You just have to find the correct angles.
• thank you very much! Just 1 small question about $\sigma^2=I$, are you using here some kind of Pauli matrices identity that $(aX+bY+cZ)^2 = (\sqrt{a^2+b^2+c^2})I$ for all $a,b,c$? Commented Jun 21, 2023 at 8:05
• $(aX+bY+cZ)^2=(a^2+b^2+c^2)I$ Commented Jun 21, 2023 at 8:07
• I'm not good at names of things! You may be able to find a more general statement more easily: $(\vec{n}\cdot\vec{\sigma})\cdot (\vec{m}\cdot\vec{\sigma})=(\vec{n}\cdot\vec{m})I+(\vec{n}\times\vec{m})\cdot\vec{\sigma}$. Commented Jun 21, 2023 at 8:13