Stage 2: Foundations: the two-particle case#

For starters, we focus on the \(N = 2\) case with two lattice sites. Our work here motivates the derivation in the next phase. When \(N = 2\), the spin interaction Hamiltonian becomes

\[\mathcal{H}_S = \frac{1}{2} \left( J_x \sigma_0^x \sigma_1^x + J_y \sigma_0^y \sigma_1^y + J_z \sigma_0^z \sigma_1^z \right)\]

Here we have labeled the relevant spins by \(0\) and \(1\), for consistency with Python and Qiskit.

We will refer to the two-qubit time propagator \(U(t) = e^{-i \mathcal{H}_S t}\) as the block operator \(B(\theta)\), with \(\theta = \frac{t}{2} \begin{bmatrix} J_x & J_y & J_z \end{bmatrix}^T\). Explicitly,

\[\begin{split}B(\theta) = \prod_\alpha e^{-it J_\alpha \sigma_0^\alpha \sigma_1^\alpha} = \begin{bmatrix} e^{-i \theta_z} \cos(\gamma) & 0 & 0 & -e^{-i \theta_z} \sin(\gamma) \\ 0 & e^{i \theta_z} \cos(\delta) & -e^{i\theta_z} \sin(\delta) & 0 \\ 0 & -ie^{i \theta_z} \sin(\delta) & e^{i\theta_z} \cos(\delta) & 0 \\ -ie^{-i \theta_z} \sin(\gamma) & 0 & 0 & e^{-i \theta_z} \cos(\gamma) \end{bmatrix},\end{split}\]

with \(\delta = \theta_x + \theta_y\) and \(\gamma = \theta_x - \theta_y\).

Time propagation blocks#

The good news is that each \(4 \times 4\) block operator can be efficiently implemented on a quantum computer using a two-qubit circuit with at most \(3\) CNOT gates Peng et al. [PGAG22]. In particular, we use the following circuit for the general XYZ case.

The two-qubit general XYZ propagator The two-qubit general XYZ propagator

The case \(J_x \cdot J_y \cdot J_z = 0\), where at least one of the coupling constants is zero, will be important later. Thus we consider it separately, and note that in this case there is an optimized quantum circuit that only requires \(2\) CNOT gates Peng et al. [PGAG22]. In particular, if \(J_y = 0\), the following circuit implements time propagation under

\[H_x + H_z = \frac{J_x}{2}\sigma_0^x \sigma_1^x + \frac{J_z}{2} \sigma_0^z \sigma_1^z.\]
The two-qubit general XYZ propagator The two-qubit general XYZ propagator

Begin by implementing these optimized \(2\)-qubit circuits, corresponding to the block operators on a pair of sites. In particular, implement the UXYZGate and UXZGate constructors defined in src/propagators.py. Be sure to test your implementation using XYZEvolutionTestSuite.test_uxyz() and XYZEvolutionTestSuite.test_uxz().

class src.propagators.UXYZGate(thetax, thetay, thetaz)[source]#

Bases: QuantumCircuit

Construct a QuantumCircuit implementing the block operator \(U_{XYZ}(\theta)\) describing evolution according to the the Heisenberg \(XYZ\)-Hamiltonian

\[H_{XYZ} = \frac{1}{2} \sum_{\alpha \in \{X, Y, Z\}} \theta_\alpha \, \sigma_0^\alpha \sigma_1^\alpha.\]

Here thetax, thetay, and thetaz can be of type float or qiskit.circuit.Parameter.

EXAMPLES:

>>> from qiskit.circuit import ParameterVector
>>> theta = ParameterVector("t", 3)
>>> UXYZGate(*theta).draw()
          ┌──────────┐┌───┐           ┌───┐      ┌───┐     ┌──────────┐
q_0: ──■──┤ Rx(t[0]) ├┤ H ├──■────────┤ S ├──────┤ H ├──■──┤ Rx(-π/2) ├
     ┌─┴─┐├──────────┤└───┘┌─┴─┐┌─────┴───┴─────┐└───┘┌─┴─┐├─────────┬┘
q_1: ┤ X ├┤ Rz(t[2]) ├─────┤ X ├┤ Rz(-1.0*t[1]) ├─────┤ X ├┤ Rx(π/2) ├─
     └───┘└──────────┘     └───┘└───────────────┘     └───┘└─────────┘ 
class src.propagators.UXZGate(gamma, delta)[source]#

Bases: QuantumCircuit

Construct a QuantumCircuit implementing the block operator \(U_{XZ}(\gamma, \delta)\) describing time evolution under

\[H_X + X_Z = \frac{\gamma}{2} \sigma_0^X \sigma_1^X + \frac{\delta}{2} \sigma_0^Z \sigma_1^Z.\]

The parameters \(\gamma\) and \(\delta\) can be of type float or qiskit.circuit.Parameter.

EXAMPLES:

>>> from qiskit.circuit import Parameter
>>> gamma, delta = Parameter("gamma"), Parameter("delta")
>>> UXZGate(gamma, delta).draw()
          ┌───────────┐     
q_0: ──■──┤ Rx(gamma) ├──■──
     ┌─┴─┐├───────────┤┌─┴─┐
q_1: ┤ X ├┤ Rz(delta) ├┤ X ├
     └───┘└───────────┘└───┘