Introduction

Among various expected use-cases of quantum computation, digital quantum simulation of fermionic many-body systems stands out as one of the most promising prospects1,2,3. Quantum simulations of electronic structure problems4 are expected to yield unprecedented insight in fields ranging from quantum chemistry to materials science and engineering or drug discovery5,6,7,8. This expectation stems from the capability of quantum computers to exhibit superposition and entanglement, thus efficiently storing a combinatorially large number of electronic configurations, which is the bottleneck of many classical methods1,2,4.

Electronic structure problems are typically mapped to quantum computers using a fermion-to-qubit mapping. In this formalism, the state of the system is encoded as a multi-qubit state and the Hamiltonian governing the problem is encoded as a weighted sum of Pauli operators. A large focus on fermionic mappings is dedicated to the optimization of mappings towards limited connectivity devices, where typically only interactions of one or two qubits are possible. One of the most popular approaches, the Jordan-Wigner (JW) transformation9, is highly limited in its applicability on such devices due to its linear Pauli weight scaling. More sophisticated mappings can be used to tackle this obstacle, e.g., the Bravyi-Kitaev (BK) mapping10,11 which achieves logarithmic localities. However, in practice, the benefit of logarithmic Pauli weight scaling is mitigated due to the need for many SWAP gates in the transpilation for a limited hardware connectivity12. Among numerous other approaches13,14,15,16,17, tree-based mappings have recently proven to be particularly effective at simultaneously mitigating the Pauli weight and number of SWAP gates for specific connectivities12,18.

The necessity for SWAP gates vanishes if one instead assumes a quantum device offering up-to-global interactions. Such interactions are provided on ion trap simulators19,20 featuring the Mølmer-Sørensen (MS) gate21,22, which can be used to efficiently implement non-local Pauli rotations arising under the chosen fermionic mapping. Most importantly, any Pauli rotation can be implemented using two MS gates regardless of the underlying locality23. In the context of fermionic systems, simulations leveraging the MS gate using the JW or BK mapping have been studied for dynamics in lattice models24,25,26 and ground state computations in quantum chemistry27,28,29 based on Unitary Coupled Cluster (UCC) theory30,31,32.

The task of implementing arbitrary quantum circuits in terms of MS gates has been studied in Refs. 33,34. While ref. 34 already provides tight bounds on the number of MS gates for generic circuits, their algorithm gets outperformed by handcrafted results for specific unitaries33,35,36. The schemes presented in our work are specific to classes of unitaries in fermionic systems.

In this work, we show how the MS gate naturally implements the Pauli operator pool of fermionic and qubit excitation operators with maximum parallelism. Our approach exploits that specific types of MS gates perform simultaneous diagonalization of certain Pauli operators arising for excitation operators under the JW transformation. Using this feature, we leverage previous works, where each non-local Pauli operator is realized by its own pair of MS gates23,24,25,28, and achieve an MS gate reduction by a factor of 2 for quadratic terms, and a factor of 4 for quartic terms. Our technique is also ancilla-free, making it not only faster, but also cheaper in terms of qubit requirements. By exploiting the local fermionic equivalences between (anti-)symmetrized excitation operators, we can use our circuits as building blocks for both UCC calculations, as well as the time evolution of electronic structure Hamiltonians in second quantization37. This enables the study of mixed quantum-classical dynamics within the Born-Oppenheimer approximation, thus providing an hybrid framework for studying time-dependent properties in molecules6,37,38,39. After introducing the fermionic building blocks, we explicitly outline our techniques at hand of the \({{H}_{3}}^{+}\) molecule by showing how UCCSD-, and time evolution circuits can be efficiently assembled. Finally, we demonstrate the efficiency of our circuit decompositions by characterizing the circuits via noisy simulations of molecular ground states of various molecules on an 12-qubit ion trap emulator at the pulse level.

Before presenting the results, we provide short introductions into general digital quantum simulations with MS gates, and the classes of fermionic operators used in UCCSD and Hamiltonian simulation. Readers with strong familiarity with those subjects are encouraged to skip to the results.

We first introduce the core properties of the MS gate and how to employ it to implement arbitrary Pauli rotations. For now, it is instructive to treat the MS gate as an idealized theoretical building block for quantum circuits, while an experimental description of the MS gate and its experimental challenges is later introduced in the results section. The MS gate captures all pairwise two-qubit interactions and is parametrized by the two parameters θ and ϕ,

$${U}_{MS}(\theta ,\phi )=\exp [-i\frac{\theta }{4}{(\cos (\phi ){S}_{x}+\sin (\phi ){S}_{y})}^{2}].$$
(1)

Here, θ is the phase and ϕ determines the type of interaction. The collective spin operators Sx and Sy are defined as the sum over all n qubits involved in the gate, e.g., \({S}_{x}={\sum }_{i=1}^{n}{X}_{i}\). Through the course of this work, we are concerned with two special cases where the MS gate is a non-identity Clifford operation, namely the XX- and YY-type interactions:

$${\bf{XX}}:={U}_{{\text{MS}}}\left(\frac{\pi }{2},0\right)=\exp \left(-i\frac{\pi }{4}\mathop{\sum }\limits_{j < k}{X}_{j}{X}_{k}\right),$$
(2)
$${\bf{Y\; Y}}:={U}_{{\text{MS}}}\left(\frac{\pi }{2},\frac{\pi }{2}\right)=\exp \left(-i\frac{\pi }{4}\mathop{\sum }\limits_{j < k}{Y}_{j}{Y}_{k}\right).$$
(3)

The inverse gates XX and YY are obtained with θ = − π/2, and due to the negative sign of θ sometimes referred to as “Backward” MS gates23. Experimentally speaking, sign changes of θ are inconvenient since they require frequency changes of the driving field23. This issue can be addressed by exploiting the local unitary equivalence between forward and backward MS gates, as detailed in the methods section. However, for the sake of a compact circuit notation, we use both the forward- and backward MS gates for our circuits in this work.

While the MS gate in equation (1) is globally defined, we typically do not want all qubits to interact at once. Instead, we need targeted MS gates acting on problem-specific subsets of qubits. From an experimental point of view, numerous approaches exist to restrict the MS interaction to subsets of the qubit array23,40,41,42,43. Alternatively, ions can be effectively decoupled by interspersing global MS gates with single-qubit gates34,44. Through this work, we make use of targeted MS gates, with the assumed experimental realization later outlined in the results section.

We now outline how any unitary Pauli rotation \(U=\exp (-i\varphi /2{\mathcal{P}})\), where \({\mathcal{P}}\) is an N-qubit Pauli string \({\mathcal{P}}\in {\{I,X,Y,Z\}}^{\otimes N}\), is decomposed into a sequence of three gate operations up to local Clifford transformations – namely two MS gates and one local parameterized rotation. We mostly follow the same derivation as in ref. 23, however with an ancilla-free approach. For that purpose, we assume that \({\mathcal{P}}\) is n-local (with nN) and, w.l.o.g. always acts non-trivially on some qubit j. Let us consider the unitary operator

$${U}^{(j)}(\varphi )={\bf{XX}}{R}_{z}^{(j)}(\varphi ){{\bf{XX}}}^{\dagger },$$
(4)

where XX acts on all n qubits affected by the Pauli string \({\mathcal{P}}\), and \({R}_{z}^{(j)}(\varphi )=\exp (-i\varphi /2{Z}_{j})\) is the single-qubit Z-rotation gate acting on qubit j. Since XX is Clifford, we may rewrite equation (4) as

$${U}^{(j)}(\varphi )=\exp \left(-i\frac{\varphi }{2}{{\mathcal{P}}}^{(j)}\right),$$
(5)

where the generating Pauli string is given by \({{\mathcal{P}}}^{(j)}={\bf{XX}}{Z}_{j}{{\bf{XX}}}^{\dagger }\). The structure of \({{\mathcal{P}}}^{(j)}\) is intrinsically linked to the locality n of the MS gate and the qubit j on which the Rz rotation is carried out,

$${{\mathcal{P}}}^{(j)}={{\mathcal{X}}}^{(j)}\otimes \left\{\begin{array}{l}\begin{array}{cc}{(-1)}^{m}{Y}_{j}, & {\text{for}}\,n=2m,\end{array}\\ \begin{array}{cc}{(-1)}^{m}{Z}_{j}, & {\text{for}}\,n=2m+1,\end{array}\end{array}\right.$$
(6)

where \({{\mathcal{X}}}^{(j)}={\otimes }_{i\ne j}{X}_{i}\) and \(m\in {\mathbb{N}}\). For the proof, refer to Supplementary Note 1. Any n-local Pauli string \({\mathcal{P}}\) either directly assumes the form in equation (6) through a suitable choice of j (n choices), or can be adjusted through local Clifford transformations accordingly. By instead using YY-type interactions in equation (4), one reverses the roles of X and Y in equation (6). This proves to be particularly convenient for the string pool in double excitations (cf. results).

In Fig. 1, we show how the XX gate is used in a quantum circuit to achieve an n-qubit Pauli-Z rotation, i.e., a rotation generated by \({\mathcal{Z}}={\otimes }_{i=1}^{n}{Z}_{i}\). We compensate for the different cases in equation (6) by adjusting the rotation angle and/or adding local Cliffords based on the identity \(\sqrt{X}Y{\sqrt{X}}^{\dagger }=Z\).

Fig. 1: Circuit for digital quantum simulation with MS gates.
Fig. 1: Circuit for digital quantum simulation with MS gates.
Full size image

Circuit decomposition of the global rotation \(U(\varphi )=\exp (-i\varphi /2{\mathcal{Z}})\) using the XX gate. The rotation angle in the circuit is defined as \(\widetilde{\varphi }={(-1)}^{m}\varphi\), where m follows the distinction between even qubit numbers n = 2m and odd numbers n = 2m + 1 from equation (6). Gates with dashed lines are only required if n is even to turn Yj into Zj.

When instead decomposing an n-local Pauli rotation in terms of CNOT gates, a total number of 2(n − 1) CNOTs is needed. Assuming full connectivity, these CNOTs could be arranged in \({\mathcal{O}}(\log (n))\) depth. In practice, however, this property can hardly be utilized due to the SWAP overhead. Meanwhile, the number of MS gates remains constant at 2. It should be emphasized that the MS gate time also grows with the with the number of interacting qubits. Hence, despite a constant gate count, the increase in locality is still not for free.

Having set the scene for arbitrary quantum simulations with MS gates, we now explore the class of fermionic operations subject to this work. The Unitary Coupled Cluster (UCC) ansatz is of particular interest due to its preservation of symmetries in electronic systems45, such as the total particle number or the spin. In its most general form, it is defined as

$$| \psi \rangle =\exp \left(\mathop{\sum }\limits_{N}{T}_{N}\right)| {\psi }_{0}\rangle ,$$
(7)

where \(| {\psi }_{0}\rangle\) is an initial guess of the systems ground state – typically the Hartree-Fock ground state – and TN denotes the N-th cluster operator incorporating all possible excitations of N electrons from occupied to virtual orbitals. In practice, N is often truncated at 2, giving rise to the UCCSD ansatz \(\exp (i({T}_{1}+{T}_{2}))\), where the first- and second cluster operators

$${T}_{1}=\mathop{\sum }\limits_{\begin{array}{l}q\in {\text{virt}}.\\ p\in {\text{occ}}.\end{array}}{\theta }_{p}^{q}{G}_{p}^{q},\,{\text{and}}\,{T}_{2}=\mathop{\sum }\limits_{\begin{array}{l}r,s\in {\text{virt}}.\\ p,q\in {\text{occ}}.\end{array}}{\theta }_{pq}^{rs}{G}_{pq}^{rs}$$
(8)

entail all possible generators of single- and double excitation generators, which are defined by the antisymmetrized terms

$${G}_{p}^{q}=i({a}_{p}^{\dagger }{a}_{q}-{\text{H}}.{\text{c}}.),$$
(9)
$${G}_{pq}^{rs}=i({a}_{p}^{\dagger }{a}_{q}^{\dagger }{a}_{r}{a}_{s}-{\text{H}}.{\text{c}}.),$$
(10)

respectively. Next, \(\exp ({T}_{1}+{T}_{2})\) is typically approximated through a first-order Trotter-Suzuki product decomposition46,47, such that the ansatz is a sequence of the single- and double excitation operators

$$U({\boldsymbol{\theta }})=\mathop{\prod }\limits_{\begin{array}{l}q\in {\text{virt}}.\\ p\in {\text{occ}}.\end{array}}{U}_{p}^{q}({\theta }_{p}^{q})\mathop{\prod }\limits_{\begin{array}{l}r,s\in {\text{virt}}.\\ p,q\in {\text{occ}}.\end{array}}{U}_{pq}^{rs}({\theta }_{pq}^{rs}),$$
(11)

where

$${U}_{p}^{q}(\theta )=\exp (-i\theta {G}_{p}^{q}),$$
(12)
$${U}_{pq}^{rs}(\theta )=\exp (-i\theta {G}_{pq}^{rs})$$
(13)

are the single- and double excitation operators, respectively. The challenge of UCC(SD) then lies in determining the parameters θ to minimize the variational energy E(θ) = 〈ψ0U(θ)HU(θ)ψ0〉. Cost-efficient updating schemes exploiting the spectral properties of excitations are detailed in refs. 48,49. Our work deals with the efficient circuit decomposition of excitations and is compatible with these parameter optimization schemes.

To study the non-adiabatic dynamics of quantum many-body systems, the time-dependent Schrödinger equation has to be solved. The solution is given by the time evolution operator, which is generated by the electronic structure Hamiltonian describing the fermionic many-body system. The time-dependent electronic structure Hamiltonian can be expressed in terms of the second-quantized operators and is defined as

$${H}_{{\text{el}}.}=\mathop{\sum }\limits_{pq}{h}_{pq}{a}_{p}^{\dagger }{a}_{q}+\frac{1}{2}\mathop{\sum }\limits_{pqrs}{h}_{pqrs}{a}_{p}^{\dagger }{a}_{q}^{\dagger }{a}_{r}{a}_{s},$$
(14)

where the one- and two-electron integrals hpq and hpqrs are subject to the permutational symmetries \({h}_{pq}={h}_{qp}^{* }\) and \({h}_{pqrs}={h}_{qpsr}={h}_{rspq}^{* }={h}_{srqp}^{* }\)50. More information on these integrals is provided in Supplementary Note 2. Here, we drop the explicit time dependence to shorten the notation. However, one could consider an explicit time dependence in the electron integrals due to dynamics in the nuclear coordinates. If one further assumes a time-dependent basis set, the fermionic operators would be time-dependent as well. We exploit these symmetries to rewrite the electronic Hamiltonian as \({H}_{el.}=H+\widetilde{H}\), with the antisymmetrized Hamiltonian H and symmetrized Hamiltonian \(\widetilde{H}\)

$$H=\frac{1}{2}\mathop{\sum }\limits_{pq}\Im ({h}_{pq}){G}_{p}^{q}+\frac{1}{4}\mathop{\sum }\limits_{pqrs}\Im ({h}_{pqrs}){G}_{pq}^{rs},$$
(15)
$$\widetilde{H}=\frac{1}{2}\mathop{\sum }\limits_{pq}\Re ({h}_{pq}){\widetilde{G}}_{p}^{q}+\frac{1}{4}\mathop{\sum }\limits_{pqrs}\Re ({h}_{pqrs}){\widetilde{G}}_{pq}^{rs},$$
(16)

where ( ) and ( ) denote the real- and imaginary parts, respectively. The symmetrized Hermitian generators \(\widetilde{G}\) are given by

$${\widetilde{G}}_{p}^{q}={a}_{p}^{\dagger }{a}_{q}+{\text{H}}.{\text{c}}.,$$
(17)
$${\widetilde{G}}_{pq}^{rs}={a}_{p}^{\dagger }{a}_{q}^{\dagger }{a}_{r}{a}_{s}+{\text{H}}.{\text{c}}.,$$
(18)

while the antisymmetrized Hermitian generators G are the same as for the excitations in equations (9) and (10). For a detailed derivation, we refer the reader to Supplementary Note 3.

The time evolution of the electronic structure system is governed by the unitary time evolution operator \(U(t,{t}_{0})={\exp }_{{\mathcal{T}}}(-i{\int }_{{t}_{0}}^{t}d\tau {H}_{el.}(\tau ))\), where \({\exp }_{{\mathcal{T}}}\) denotes the time ordered operator exponential. For a small time step δt = tt0, we may approximate U(t, t0) through a first-order Trotter-Suzuki product formula

$$\begin{array}{rcl}U(\delta t) & = & \mathop{\prod }\limits_{pq}{U}_{p}^{q}(\Im ({h}_{pq})\delta t)\mathop{\prod }\limits_{pqrs}{U}_{pq}^{rs}(\Im ({h}_{pqrs})\delta t)\\ & \times & \mathop{\prod }\limits_{pq}{\widetilde{U}}_{p}^{q}(\Re ({h}_{pq})\delta t)\mathop{\prod }\limits_{pqrs}{\widetilde{U}}_{pq}^{rs}(\Re ({h}_{pqrs})\delta t),\end{array}$$
(19)

where \({U}_{p}^{q}\) and \({U}_{pq}^{rs}\) are the single- and double excitations from equations (12) and (13), and \({\widetilde{U}}_{p}^{q}\) and \({\widetilde{U}}_{pq}^{rs}\) are analogously defined with the symmetrized generators from equations (17) and (18). We want to highlight that the unitaries corresponding to the antisymmetrized Hamiltonian \({\prod }_{pq}{U}_{p}^{q}{\prod }_{pqrs}{U}_{pq}^{rs}\) are structurally similar to the UCCSD ansatz in equation (11), with the only differences being that no distinction between occupied and virtual orbitals is made and that shared indices (e.g., controlled excitations) are included.

Results

In this section, we first present our optimized circuits for antisymmetrized fermionic single- and double excitations. We then outline how our procedure generalizes to arbitrary excitation orders. We further discuss the applicability to other fermion-to-qubit mappings, and show how our techniques readily apply to qubit-excitations. We then show how the symmetrized fermionic terms for Hamiltonian simulation can be recovered from the previous circuits. We then give explicit circuit examples for UCCSD ansätze and Trotter steps. Last, we introduce a realistic pulse-level noise model, which we use to assess the practical improvements of our circuits in noisy scenarios.

Circuit for Single Excitations

Under the JW mapping (cf. methods), the generator of a single excitation between two orbitals p, q with p < q assumes the Pauli decomposition

$${G}_{p}^{q}\to \frac{1}{2}{{\mathcal{Z}}}_{p}^{q}({Y}_{p}{X}_{q}-{X}_{p}{Y}_{q}),$$
(20)

with the parity string \({{\mathcal{Z}}}_{p}^{q}:={\prod {}_{j\in \{p,q\}}\bigotimes }_{k < j}{Z}_{k}\). We now reproduce equation (20) in terms of local operators and MS gates based on equation (6) to infer the circuit decomposition of \({U}_{p}^{q}(\theta )\). Since each Pauli string in the single excitation generator from equation (20) consists of one X and Y, the choice of either the XX or YY gate is arbitrary. For the sake of simplicity, we only consider XX here.

We assume that the MS gate acts on all n = qp + 1 qubits affected by the single excitation. The core idea is that we can realize up to n Pauli rotations in parallel by interspersing two MS gates with Rz gates. The generator of the single excitation entails two Pauli strings always acting at least on the two qubits p and q, therefore we use these two qubits to place the Rz gates in parallel.

For an even number of qubits n = 2m, we use

$${\bf{XX}}({Z}_{p}-{Z}_{q}){{\bf{XX}}}^{\dagger }={(-1)}^{m}{{\mathcal{X}}}_{p}^{q}({Y}_{p}{X}_{q}-{X}_{p}{Y}_{q}),$$
(21)

where \({\mathcal{X}}\) is analogously defined to \({\mathcal{Z}}\) with Pauli-X instead. Note that this is already local Clifford equivalent to equation (20) up to a Hadamard transformation on the qubits p + 1, …, q − 1 and a prefactor of (−1)m/2. For an odd number of qubits n = 2m + 1, we find

$${\bf{XX}}({Z}_{p}-{Z}_{q}){{\bf{XX}}}^{\dagger }={(-1)}^{m}{{\mathcal{X}}}_{p}^{q}({Z}_{p}{X}_{q}-{X}_{p}{Z}_{q}).$$
(22)

Here, we obtain Z instead of Y. We circumvent that by exploiting that \({\sqrt{X}}^{\dagger }Z\sqrt{X}=Y\). By using this transformation on qubits p and q, we can change ZY without affecting X. Overall, this gives rise to

$$\begin{array}{rcl} & & {\sqrt{X}}_{p}^{\dagger }{\sqrt{X}}_{q}^{\dagger }{\bf{XX}}({Z}_{p}-{Z}_{q}){{\bf{XX}}}^{\dagger }{\sqrt{X}}_{p}{\sqrt{X}}_{q}\\ & & ={\bf{XX}}({Y}_{p}-{Y}_{q}){{\bf{XX}}}^{\dagger }={(-1)}^{m}{{\mathcal{X}}}_{p}^{q}({Y}_{p}{X}_{q}-{X}_{p}{Y}_{q})\end{array}$$
(23)

The prefactor of (−1)m can in theory be absorbed into the variational parameter θ and thus be ignored in the circuit decomposition. However, we keep track of it as it becomes crucial for time evolution. Equations (21) and (23) give rise to the circuit decompositions of a single excitation with XX gates depicted in Fig. 2(a). An equivalent decomposition in terms of YY gates is provided in Fig. 2(b). In ref. 24, where every Pauli string is implemented with its own pair of MS gates, a total of 4 MS gates is required. With our parallelization, we achieve the same operation with only 2 MS gates, which is optimal with respect to the assumed gate set of targeted Clifford MS gates and arbitrary local unitaries.

Fig. 2: Circuit decompositions of the single-excitation gate.
Fig. 2: Circuit decompositions of the single-excitation gate.
Full size image

Circuit decomposition of the single-excitation gate \({U}_{p}^{q}(\theta )=\exp (-i\theta {G}_{p}^{q})\) using (a) the XX gate and (b) the YY gate. The rotation angle in the circuits is defined as \(\widetilde{\theta }={(-1)}^{m}\theta\), where m follows the same distinction between even qubit numbers n = 2m and odd numbers n = 2m + 1 as before. Gates with dashed lines are only required if n is odd. The dots labeling the quantum wire bundle represent all qubits affected by the parity string \({{\mathcal{Z}}}_{p}^{q}\).

Circuit for Double Excitations

The generator of the double excitation from modes p, q to r, s is decomposed as

$$\begin{array}{rcl} & & {G}_{pq}^{rs}\to \frac{1}{8}{{\mathcal{Z}}}_{pq}^{rs}\\ & & \times ({X}_{p}{Y}_{q}{Y}_{r}{Y}_{s}+{Y}_{p}{X}_{q}{Y}_{r}{Y}_{s}-{Y}_{p}{Y}_{q}{X}_{r}{Y}_{s}-{Y}_{p}{Y}_{q}{Y}_{r}{X}_{s}\\ & & -{Y}_{p}{X}_{q}{X}_{r}{X}_{s}-{X}_{p}{Y}_{q}{X}_{r}{X}_{s}+{X}_{p}{X}_{q}{Y}_{r}{X}_{s}+{X}_{p}{X}_{q}{X}_{r}{Y}_{s}),\end{array}$$
(24)

with the parity string \({{\mathcal{Z}}}_{pq}^{rs}:={\prod {}_{j\in \{p,q,r,s\}}\bigotimes }_{k < j}{Z}_{k}\). It involves two different sorts of Pauli strings, namely all permutations of YXXX and XYYY across the four orbitals p, q, r, s.

In the following, we assume that p < q < r < s, thus the MS gates act on the n = (qp) + (sr) + 2 qubits affected by the double excitation. In case that q = p + 1 and s = r + 1, the double excitation acts precisely on the 4 qubits p, q, r, s. These are the qubits we can generally use to deploy the Rz gates. Since the generator entails 8 strings, which we have to distribute among 4 qubits, we can not implement all strings at once. Instead, we need to distribute the rotations among two different layers, amounting to a minimum of 4 MS gates.

As introduced in the introduction, for an even number of qubits n = 2m, the YXXX-type strings can be readily realized in three layers using the XX gate:

$$\begin{array}{rcl} & & {\bf{XX}}(-{Z}_{p}-{Z}_{q}+{Z}_{r}+{Z}_{s}){{\bf{XX}}}^{\dagger }={(-1)}^{m}{{\mathcal{X}}}_{pq}^{rs} \\ & & \times (-{Y}_{p}{X}_{q}{X}_{r}{X}_{s}-{X}_{p}{Y}_{q}{X}_{r}{X}_{s}+{X}_{p}{X}_{q}{Y}_{r}{X}_{s}+{X}_{p}{X}_{q}{X}_{r}{Y}_{s}).\end{array}$$
(25)

For the XYYY-type strings, the same result can be achieved using YY interactions instead, thus circumventing the need for additional local transformations on the qubits p, q, r, s:

$$\begin{array}{rcl} & & {\bf{Y\; Y}}(-{Z}_{p}-{Z}_{q}+{Z}_{r}+{Z}_{s}){{\bf{Y\; Y}}}^{\dagger }={(-1)}^{m}{{\mathcal{Y}}}_{pq}^{rs}\\ & & \times ({X}_{p}{Y}_{q}{Y}_{r}{Y}_{s}+{Y}_{p}{X}_{q}{Y}_{r}{Y}_{s}-{Y}_{p}{Y}_{q}{X}_{r}{Y}_{s}-{Y}_{p}{Y}_{q}{Y}_{r}{X}_{s}).\end{array}$$
(26)

For an odd number of qubits n = 2m + 1, the results of equations (25) and (26) can be achieved similarly to equation (23) by employing the identities X = HZH and \(Y={\sqrt{X}}^{\dagger }Z\sqrt{X}\). The resulting circuits can be inferred from Fig. 3. Compared to ref. 24, our technique reduces the number of MS gates from 16 down to 4, which is optimal.

Fig. 3: Circuit decomposition of the double-excitation gate.
Fig. 3: Circuit decomposition of the double-excitation gate.
Full size image

Circuit decomposition of the double-excitation gate \({U}_{pq}^{rs}(\theta )=\exp (-i\theta {G}_{pq}^{rs})\) using the XX and YY gates. The rotation angle in the circuits is defined as \(\widetilde{\theta }={(-1)}^{m}\theta /4\), where m follows the same distinction between even qubit numbers n = 2m and odd numbers n = 2m + 1 as before. Gates with dashed lines are only required if n is odd. The dots labeling the quantum wire bundle represent all qubits affected by the parity string \({{\mathcal{Z}}}_{pq}^{rs}\).

If we relieve the constraint that excitations shall only occur from occupied to virtual orbitals, we can employ additional parallelizations. All distinct permutations of \({G}_{pq}^{rs}\), i.e., \({G}_{pr}^{qs}\) and \({G}_{ps}^{qr}\) give rise to the same eight Pauli strings, hence they can be implemented with the same cost as one double excitation by adjusting the angles in Fig. 3. We stress that this observation is not unique to our circuits and has already been efficiently employed in, e.g., ref. 51.

A double excitation where two indices are identical effectively boils down to a controlled single excitation

$${G}_{pj}^{qj}=-i{a}_{j}^{\dagger }{a}_{j}({a}_{p}^{\dagger }{a}_{q}-{\text{H}}.{\text{c}})=-{n}_{j}{G}_{p}^{q},$$
(27)

where \({n}_{j}:={a}_{j}^{\dagger }{a}_{j}\) is the particle number operator, which makes j act as a control mode. While these types of excitations are typically neglected in UCCSD theory, they arise in generalized UCC theory, such as UCCGSD52. These terms further appear in the simulation of electronic structure Hamiltonians, which we will exploit later (cf. results). In addition, normal- and controlled single excitations are universal for particle-number preserving operations53. The controlled-singles circuits arise naturally from the regular singles circuits in Fig. 2 by replacing the Rz(θ) gates by controlled rotations. We leave the technical details to the methods section.

Circuit Costs for Higher Order Excitations

The expressivity of the UCCSD ansatz can be increased by including triple excitations (UCCSDT)54 or even higher order terms32. The generator of an N-th order excitation generally assumes the form of 22N−1 mutually commuting Pauli strings under the JW mapping, where each string consists of an odd number of X and Y operators28. Using the same parallelization strategy as for the singles and doubles, we can always implement subsets of N strings in parallel. Therefore, our approach reduces the MS count from 22N down to 222N−2/N, thus providing an \({\mathcal{O}}(N)\) speedup.

We note that for any excitation order N, in principle, it is possible to capture the non-locality of the JW strings using only 2 global MS gates, at the start and end of the decomposition. The difference to our approach with multiple global MS gates then lies in the fact that the two MS gates are interspersed with all odd-parity (1, 3, …, 2N − 1) non-local Pauli-Z rotations, which are however local to the 2N qubits subject to the excitation. These could then in return again be decomposed in terms of smaller MS gates. However, the exponential cost is not removed, but rather relegated to the inner decomposition. More details on this mixed approach are provided in Supplementary Note 4.

Applicability to other Fermion-To-Qubit Mappings

We now shortly address if and how our parallelization techniques can be applied to other fermion-to-qubit mappings. For a simple illustration, we consider the generator of a single-excitation \({G}_{1}^{3}\) for a system with 4 fermionic modes, e.g., the H2 molecule with a minimal active space of 2 electrons and four spin-orbitals, within the Parity11 and the Bravyi-Kitaev (BK)10 mappings. With the Parity mapping we obtain

$${G}_{1}^{3}=\frac{1}{2}({Z}_{0}{X}_{1}{Y}_{2}-{Y}_{1}{X}_{2}{Z}_{3}),$$
(28)

while the BK mapping yields

$${G}_{1}^{3}=\frac{1}{2}({Z}_{0}{Y}_{1}{Z}_{2}-{Y}_{1}{Z}_{3}).$$
(29)

The main insight is that for both mappings, a fermionic excitation potentially maps to Pauli strings acting on different subsets of qubits. In both examples, the two Pauli strings have different supports, and hence cannot be parallelized through means of equations (21) and (23). If one would like to implement the single excitation from equation (28) with MS gates using the decomposition technique from equation (6), one would need two MS gates for Z0X1Y2 and another pair of MS gates for Y1X2Z3. This results in more than the minimum amount of needed MS gates compared to JW. Since the Pauli strings in the parity mapping have the same \({\mathcal{O}}(N)\) locality scaling as in JW, we conclude that the parity mapping is less suitable for efficient simulations with global MS gates. Within the BK mapping, while the parallelization also fails, having more MS gates with only \({\mathcal{O}}(\log (N))\) locality might still prove beneficial, since the gates would be faster and less erroneous.

Applicability to Qubit Excitations

Qubit excitations have come up as a resource-friendly alternative to fermionic excitations for UCCSD theory55. In principle, qubit excitations differ from fermionic excitations in that they simply ignore the parity string in the generator, thus avoiding operations on the parity qubits of the excitations, and making the operation more resource-friendly. While this does not properly capture the fermionic character of the system, it works extremely well for variational problems such as UCCSD. We want to stress that all our circuits hold equivalently for qubit-excitations when removing the parity-qubits. Thus, our qubit single-excitations entails precisely two 2-qubit MS gates, and our qubit double-excitations consist of four 4-local MS gates. Our techniques are thus readily applicable to more hardware-friendly qubit excitation-based (QEB) notion of UCCSD.

Circuits for Hamiltonian Simulation

Concerning the symmetrized terms in the Hamiltonian from equation (16), we can trace them back to the antisymmetrized structure from UCCSD by exploiting the local equivalence of the antisymmetrized electron terms (single- and double- excitations) and the symmetrized electron terms in fermionic space:

$${\widetilde{G}}_{p}^{q}=\exp \,(-i\frac{\pi }{2}{n}_{p}){G}_{p}^{q}\exp (i\frac{\pi }{2}{n}_{p}),$$
(30)
$${\widetilde{G}}_{pq}^{rs}=\exp \,(-i\frac{\pi }{2}{n}_{p}){G}_{pq}^{rs}\exp (i\frac{\pi }{2}{n}_{p}).$$
(31)

Note that one could also use other particle number operators than np involved in the excitation (q for singles and q, r, s for doubles), but then for the orbitals in the superscript we have to replace π/2 → − π/2. Also, for a controlled excitation \({G}_{pj}^{qj}\), only the modes p and q can be used. For more details, refer to Supplementary Note 5. Under the JW mapping, this local fermionic equivalence manifests as a local Clifford equivalence, i.e., \(\exp (-i\pi /2{n}_{p})\to {S}_{p}\) (up to a global phase which cancels out with the conjugate term), where Sp is the S-gate acting on qubit p. This way, we entirely avoid mapping out \(\widetilde{G}\) with the JW mapping and instead can recycle the circuits from Figs. 2, 3, and 8. We point out that, unlike in variational applications, the phase (−1)m is important here to avoid accidentally performing backwards time evolution.

The only terms that can not be traced back to the excitation circuits are the density terms \({\widetilde{G}}_{p}^{p}\) and the Coulomb repulsion terms \({\widetilde{G}}_{pq}^{pq}\), which under the JW transformation map to

$${\widetilde{G}}_{p}^{p}=2{n}_{p}\to I-{Z}_{p},\,{\text{and}}$$
(32)
$${\widetilde{G}}_{pq}^{pq}=-2{n}_{p}{n}_{q}\to \frac{1}{2}(-I+{Z}_{p}+{Z}_{q}-{Z}_{p}{Z}_{q}).$$
(33)

These terms are at most 2-local, and the required Rzz gate for the ZZ terms can again be decomposed into MS gates as detailed in the introduction.

We supplement this section with the same remark as before - that all permutations of \({G}_{pq}^{rs}\) give rise to the same string pool, and can thus be fully parallelized (the same holds separately for \(\widetilde{G}\)). Since for the two-electron integrals we generally have hpqrshprqshpsqr, the Pauli strings corresponding to \({G}_{pq}^{rs}\), \({G}_{pr}^{qs}\) and \({G}_{ps}^{qr}\) will in general not cancel out.

Finally, it is worth pointing out that real-valued orbitals effectively remove the antisymmetrized terms (equation (15)), thus cutting the number of non-local terms by half. In addition, more symmetries can be exploited, which however only reduce the Rz count and not the number of MS gates. We provide the technical details in the methods section.

Computational Goals of the Circuits

Our circuits are applicable to both time-dependent and time-independent studies. However, the time dependency brings an additional computational difficulty due to the coupling of electronic- and nuclear states. To tackle down this obstacle, techniques were developed leading to two types of quantum dynamics56,57. Either only the electronic motion is treated with quantum mechanics and the nuclear motion is evaluated classically, or both electronic and nuclear motions are treated with quantum mechanics. In the following, these two case are referred to as mixed classical-quantum dynamics, and fully-quantum dynamics, respectively.

The first type of dynamics, the mixed classical-quantum dynamic (MCQD) method, differs from molecular dynamics methods where the system is only treated classically and interatomic potentials are used to mimic interatomic interactions58, whereas the electronic Schrödinger equation is not explicitly considered. For MCQD methods, the nuclei are also treated classically with Newton’s equation of motion, and the Schrödinger equation is solved solely for the electrons56. Among the MCQD methods, either the dynamic is performed within a single electronic state, or the electronic wave-function evolves onto several electronic states and non-adiabatic couplings are involved in order to transfer the wave-function from one state to another. In any case, all electronic states in a MCQD method are determined within the Born-Oppenheimer approximation.

When only a single adiabatic electronic state (usually the ground-state) is considered, the electronic wavefunction is propagated onto this single potential energy surface, and all nuclei have a classical motions. This can be applied to describe atomic interactions in ground states59, such as diffusion properties60, reaction processes61, and also the calculation of observables such as IR spectra62. One can use our UCCSD circuits to prepare a single adiabatic electronic state (usually the ground-state), and then slowly evolve it in a classical-quantum hybrid loop, where the UCCSD ansatz is used to update the electronic state based on the changed nuclear geometry.

When multiple adiabatic electronic states are considered63, the electronic wavefunction can propagate among them through classical motion of the nuclei. This is formalized as the trotterized time evolution of a time-dependent electronic Hamiltonian, as detailed in ref. 39. Among the wide range of applications of such method, one can name photoisomerization processes64, chemical processes in the atmosphere65, and simulating the behavior of molecular aggregates for optoelectronics66. For such cases, one could start with UCCSD to prepare the ground state, and then non-adiabatically evolve it in time using the circuits for Trotterized Hamiltonian simulation.

The second type of dynamics entails a fully quantum mechanical treatment of both electrons and nuclei, and the Born-Oppenheimer approximation is not considered. These methods are very attractive for the time-study of quantum systems in the realm of non-adiabatic processes among several electronic states67. They are well known for studying internal conversion in conjugated chromophores (chemical processes involving bond breaking68, carbon nanotube69, non-radiative relaxation in chlorophylls70), energy transfer in molecular aggregates (dendrimers71, or vibrational studies in OLEDs72). By encoding the vibrational modes of the nuclear motion into the normal modes of the ion chain of an ion trap computer73, one could employ our time evolution circuits in a digital-analog fashion, as detailed in refs.24,25. A state-of-the-art implementation of such procedure is provided in refs. 74.

Example 1: A UCCSD Layer

We now provide some illustrative examples on how to assemble practical fermionic circuits within our gate decompositions.

Here, we demonstrate our technique on the \({{H}_{3}}^{+}\) molecule in the STO-3G basis set. This system entails 2 electrons distributed among 6 spin-orbitals, and thus provides a minimalist example with non-localities arising from the JW mapping in both the single- and double-excitations (or quadratic and quartic Hamiltonian terms). Note that we alternate the spin-up (α) and spin-down (β) orbitals in our state and operator notation, i.e., \(| {\alpha }_{0},{\beta }_{0},{\alpha }_{1},{\beta }_{1},{\alpha }_{2},{\beta }_{2}\rangle\). We use the same order to enumerate the orbitals in the JW mapping.

We start off by constructing the circuit for one first-order Trotter step in UCCSD theory. For that purpose, we are not concerned with the precise structure of the Hamiltonian, but rather the Hartree-Fock ground state \({| \psi \rangle }_{HF}=| 110000\rangle\) and the eligible excitations starting from that state. Here, there are 4 unique spin-preserving single excitations \({G}_{{\alpha }_{0}}^{{\alpha }_{1}},{G}_{{\alpha }_{0}}^{{\alpha }_{2}},{G}_{{\beta }_{0}}^{{\beta }_{1}}\), and \({G}_{{\beta }_{0}}^{{\beta }_{2}}\). In addition, there exist 4 different spin-preserving double excitations \({G}_{{\alpha }_{0},{\beta }_{0}}^{{\alpha }_{1},{\beta }_{1}},{G}_{{\alpha }_{0},{\beta }_{0}}^{{\alpha }_{2},{\beta }_{1}},{G}_{{\alpha }_{0},{\beta }_{0}}^{{\alpha }_{1},{\beta }_{2}}\) and \({G}_{{\alpha }_{0},{\beta }_{0}}^{{\alpha }_{2},{\beta }_{2}}\). The quantum circuit corresponding to these excitations is schematically depicted in Fig. 4. Our circuit employs 24 MS gates while a string-by-string implementation amounts to 80 gates, hence we achieve a gate reduction by a factor of ~ 3.3.

Fig. 4: Schematic circuit decomposition of a UCCSD layer in first-order Trotterization.
Fig. 4: Schematic circuit decomposition of a UCCSD layer in first-order Trotterization.
Full size image

Schematic circuit decomposition of one layer of the UCCSD ansatz in first-order Trotterization. We use the same coloring scheme as for the previous figures; XX gates in green, YY gates in red, Rz gates in blue, local Cliffords in white if they are due to the parity string, gray if they account for odd numbers of qubits in the interaction. Note that some adjacent local Clifford gates cancel out and are only explicitly depicted for the sake of clarity.

Example 2: A Trotter Step of the Hamiltonian

We compute the one- and two-electron integrals with the STO-3G basis set in the equilibrium geometry, i.e., a bond distance of 0.784 Å and a bond angle of 60 using the pyscf package75,76. This gives rise to the Hamiltonian H = Hloc. + Hnon−loc. (we list the most significant terms in units of 1 Ha), where the local part containing terms of the type \({\widetilde{G}}_{p}^{p}\) and \({\widetilde{G}}_{pq}^{pq}\) is given by

$$\begin{array}{l}{H}_{\mathrm{loc}.}=-0.917({\widetilde{G}}_{{\alpha }_{0}}^{{\alpha }_{0}}+{\widetilde{G}}_{{\beta }_{0}}^{{\beta }_{0}})\\ \,\,\,\,\,\,\,\,\,\,\,\,-0.535({\widetilde{G}}_{{\alpha }_{1}}^{{\alpha }_{1}}+{\widetilde{G}}_{{\alpha }_{2}}^{{\alpha }_{2}}+{\widetilde{G}}_{{\beta }_{1}}^{{\beta }_{1}}+{\widetilde{G}}_{{\beta }_{2}}^{{\beta }_{2}})\\ \,\,\,\,\,\,\,\,\,\,\,\,-0.337({\widetilde{G}}_{{\alpha }_{1}{\beta }_{1}}^{{\alpha }_{1}{\beta }_{1}}+{\widetilde{G}}_{{\alpha }_{2}{\beta }_{2}}^{{\alpha }_{2}{\beta }_{2}})-0.307{\widetilde{G}}_{{\alpha }_{0}{\beta }_{0}}^{{\alpha }_{0}{\beta }_{0}}\\ \,\,\,\,\,\,\,\,\,\,\,\,-0.298({\widetilde{G}}_{{\alpha }_{0}{\beta }_{2}}^{{\alpha }_{0}{\beta }_{2}}+{\widetilde{G}}_{{\alpha }_{2}{\beta }_{0}}^{{\alpha }_{2}{\beta }_{0}}+{\widetilde{G}}_{{\alpha }_{0}{\beta }_{1}}^{{\alpha }_{0}{\beta }_{1}}+{\widetilde{G}}_{{\alpha }_{1}{\beta }_{0}}^{{\alpha }_{1}{\beta }_{0}})\\ \,\,\,\,\,\,\,\,\,\,\,\,-0.265({\widetilde{G}}_{{\alpha }_{1}{\beta }_{2}}^{{\alpha }_{1}{\beta }_{2}}+{\widetilde{G}}_{{\alpha }_{2}{\beta }_{1}}^{{\alpha }_{2}{\beta }_{1}})\\ \,\,\,\,\,\,\,\,\,\,\,\,-0.229({\widetilde{G}}_{{\alpha }_{1}{\alpha }_{2}}^{{\alpha }_{1}{\alpha }_{2}}+{\widetilde{G}}_{{\beta }_{1}{\beta }_{2}}^{{\beta }_{1}{\beta }_{2}})\\ \,\,\,\,\,\,\,\,\,\,\,\,-0.226({\widetilde{G}}_{{\alpha }_{0}{\alpha }_{1}}^{{\alpha }_{0}{\alpha }_{1}}+{\widetilde{G}}_{{\alpha }_{0}{\alpha }_{2}}^{{\alpha }_{0}{\alpha }_{2}}+{\widetilde{G}}_{{\beta }_{0}{\beta }_{1}}^{{\beta }_{0}{\beta }_{1}}+{\widetilde{G}}_{{\beta }_{0}{\beta }_{2}}^{{\beta }_{0}{\beta }_{2}}),\end{array}$$
(34)

while the non-local part reads

$$\begin{array}{l}{H}_{{\text{non}}-{\text{loc}}.}=-0.142({\widetilde{G}}_{{\alpha }_{0}{\beta }_{0}}^{{\alpha }_{1}{\beta }_{1}}+{\widetilde{G}}_{{\alpha }_{0}{\beta }_{1}}^{{\alpha }_{1}{\beta }_{0}}+{\widetilde{G}}_{{\alpha }_{0}{\beta }_{0}}^{{\alpha }_{2}{\beta }_{2}}+{\widetilde{G}}_{{\alpha }_{0}{\beta }_{2}}^{{\alpha }_{2}{\beta }_{0}})\\ \,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,-0.090({\widetilde{G}}_{{\alpha }_{0}{\beta }_{1}}^{{\alpha }_{1}{\beta }_{1}}+{\widetilde{G}}_{{\alpha }_{1}{\beta }_{0}}^{{\alpha }_{1}{\beta }_{1}}-{\widetilde{G}}_{{\alpha }_{0}{\beta }_{2}}^{{\alpha }_{1}{\beta }_{2}}-{\widetilde{G}}_{{\alpha }_{2}{\beta }_{0}}^{{\alpha }_{2}{\beta }_{1}})\\ \,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,+0.090({\widetilde{G}}_{{\alpha }_{0}{\beta }_{1}}^{{\alpha }_{2}{\beta }_{2}}+{\widetilde{G}}_{{\alpha }_{0}{\beta }_{2}}^{{\alpha }_{2}{\beta }_{1}}+{\widetilde{G}}_{{\alpha }_{1}{\beta }_{0}}^{{\alpha }_{2}{\beta }_{2}}+{\widetilde{G}}_{{\alpha }_{1}{\beta }_{2}}^{{\alpha }_{2}{\beta }_{0}})\\ \,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,-0.072({\widetilde{G}}_{{\alpha }_{1}{\beta }_{1}}^{{\alpha }_{2}{\beta }_{2}}+{\widetilde{G}}_{{\alpha }_{1}{\beta }_{2}}^{{\alpha }_{2}{\beta }_{1}}).\end{array}$$
(35)

Note that \(\exp (-i\delta t{H}_{loc})\) trivially boils down to Rz and Rzz rotations according to equations (32) and (33). For that reason, we focus on the circuit decomposition concerning the non-local interactions.

Due to the symmetries for real basis sets, every term \({G}_{pq}^{rs}\) with pqrs is accompanied by a term \({G}_{ps}^{rq}\) which can be included without any additional MS gates. We can further exploit that the terms \({\widetilde{G}}_{{\alpha }_{0}{\beta }_{1}}^{{\alpha }_{1}{\beta }_{1}}\) and \({\widetilde{G}}_{{\alpha }_{0}{\beta }_{2}}^{{\alpha }_{1}{\beta }_{2}}\) correspond to the same excitation controlled by different modes, and can thus be parallelized as well. Last, we want to emphasize the controlled excitation \({\widetilde{G}}_{{\alpha }_{1}{\beta }_{0}}^{{\alpha }_{1}{\beta }_{2}}\). Here, α1 is the control but simultaneously part of the JW string \({{\mathcal{Z}}}_{{\beta }_{0}}^{{\beta }_{1}}\). Using all these properties allows us to implement \(\exp (-i\delta t{H}_{{\text{non}}-{\text{loc}}.})\) with a total of 8 building blocks based on Figs. 3 and 8, as we depict in Fig. 5. Our circuit entails 26 MS gates whereas the implementation of each string separately (also using the symmetries and controlled rotations for the sake of comparability) amounts to 56, enabling a speedup of ~ 2.2. A naive implementation of each excitation separately without the use of symmetries gives rise to 176 MS gates, showcasing that the main benefit here stems from the symmetry exploitation rather than the parallelization.

Fig. 5: Schematic circuit decomposition of a Hamiltonian time step in first-order Trotterization.
Fig. 5: Schematic circuit decomposition of a Hamiltonian time step in first-order Trotterization.
Full size image

Schematic circuit decomposition of one Trotter step of \(\exp (-i\delta t{H}_{non-loc.})\) in first-order Trotterization. We use the same coloring scheme as for the previous figures; XX gates in green, YY gates in red, Rz gates in blue, local Cliffords in white if they are due to the parity string, gray if they account for odd numbers of qubits in the interaction. In addition, we introduce dark blue gates representing the S(†) gates ensuring the symmetrization. Note that some adjacent local Clifford gates cancel out and are only explicitly depicted for the sake of clarity.

Noise Modeling

So far, we have assumed ideal maximally entangling MS gates in our circuit decompositions. In practice on noisy quantum simulators, shorter circuits do not always guarantee results with higher fidelity. Our scenario is arguably more specific, given that we carry out the same types of gates on the same qubits as in ref. 24, just fewer times. Naively, one could estimate that we reduce the noise-strength for single,- and double excitations by factors of 2, and 4, respectively. Such simple scaling behavior holds, e.g. for depolarizing channels, but is not accurate for realistic noise models and experiments77. Therefore, the purpose of this section is to develop a realistic ion trap noise model, which we employ to assess if our reductions in MS gates actually result in higher fidelity building blocks for fermionic circuits.

We consider 12 171Yb+ ions trapped in a linear harmonic radio-frequency Paul trap78, with axial trap frequency ωz = 2π × 0.5 MHz and radial trap frequency ωx = 2π × 3.33 MHz, such that the distances between adjacent ions lie in the range of 2.22 μm to 3.21 μm. We assume that each ion in the chain can be individually addressed with its own pair of red- and blue side-band Raman beams with optical frequencies ω0 ± μi(t), where μi(t) is the time-dependent Raman detuning with respect to the spin resonance frequency ω0 = 2π × 12.643 GHz79 between the two spin-1/2 states which serve as the qubit computational basis states. We further assume that both Raman beams have equal time-dependent pulse amplitudes \({\Omega }_{i}^{(1)}(t)={\Omega }_{i}^{(2)}(t)\) and originate from the same pulse-modulated laser source. Thus, AC stark shifts due to laser power fluctuations may be neglected as the contribution from the red and blue shifted Raman beams cancel each other out80. Under the rotating approximation ω0 μ(t), and the Lamb-Dicke limit, the Hamiltonian of the experiment may be written as80,81

$$\begin{array}{rcl}{H}_{{\text{MS}}}(t) & = & \mathop{\sum }\limits_{i}\mathop{\sum }\limits_{p}{\eta }_{p}^{(i)}{g}^{(i)}(t)[{a}_{p}{e}^{-i{\omega }_{p}t}+{a}_{p}^{\dagger }{e}^{i{\omega }_{p}t}]\\ & & \times [\cos (\phi ){X}_{i}+\sin (\phi ){Y}_{i}],\end{array}$$
(36)

where the indices i and p label the qubits/ions and radial motional modes, respectively. The Lamb-Dicke parameters \({\eta }_{p}^{(i)}\propto {b}_{p}^{(i)}/\sqrt{{\omega }_{p}}\) describe the coupling strength between qubit i and radial mode p and entail the normal mode transformation matrix \({b}_{p}^{(i)}\) of ion i and motional mode p with frequency ωp, and ap and \({a}_{p}^{\dagger }\) are the normal mode phonon creation- and annihilation operators. The \({g}^{(i)}(t):={\Omega }^{(i)}(t)\sin ({\int }_{0}^{t}d\tau {\mu }^{(i)}(\tau ))\) are the pulse functions defined through the aforementioned amplitudes and detunings. The phase ϕ is determined by the phase of the two Raman beams and is chosen such that either ϕ = 0 for the XX-, or ϕ = π/2 for the YY-interaction. The full experimental MS gate unitary corresponding to the Hamiltonian from equation (36) is described in the methods section.

For the modeling of different experimental error sources, we mostly follow ref. 82, which introduces a noise model for the global MS gate showing good agreement with experimental data. In particular, the authors consider vibrational mode frequency fluctuations ωpωp + Δωp, which lead to instabilities in both the geometric phases and displacements. Assuming thermal initial states of the vibrations83, the decoherence from residual entanglement between electronic and vibrational states is further amplified. Laser power fluctuations of the two laser beams driving the MS interaction lead to fluctuations in the Rabi rates Ω(i)(t) → Ω(i)(t)(1 + ΔΩ(i))81,82. In addition, state preparation and measurement (SPAM) errors are considered. In their experiments, the authors find that vibrational frequency fluctuations and SPAM errors are the dominant sources of error. We focus on the former, given that scalable readout error mitigation methods exist84, which could in principle handle the fundamental detection infidelity limit of 171Yb+ ions which is about 10−385. We therefore consider a pulse modulation scheme which is robust against vibrational frequency fluctuations81. We provide a qualitative description in the methods section, whereas an in-depth guide is provided in Supplementary Note 7. For solving the optimization problem outlined in Sec. Pulse Modulation and Gate Stabilization, we use PyOptInferface86,87 in combination with the Ipopt88 software.

Assuming frequency fluctuations of 1 kHz81 and power fluctuations of 0.5%, we find a two-qubit gate fidelity of \({{\mathcal{F}}}_{2}=99.97 \%\), and observe an exponential decay in fidelity when increasing the number of qubits, up to a fidelity of \({{\mathcal{F}}}_{12}=98.27 \%\). We find that the decay is well described by \({{\mathcal{F}}}_{2}^{N(N-1)/2}\), which is motivated by the fact that an N-qubit MS gate implicitly entails N(N − 1)/2 two-qubit MS gates. Another important feature is that the gate time of our optimized MS gates scales sub-linearly in the number of qubits, which conveniently yields sub-linear circuit times despite the linear locality of the JW mapping. A full characterization of the noise model is provided in Supplementary Note 8. More specifically, the assumed Lamb-Dicke parameters are shown in Supplementary Table 1, the optimized pulses are displayed in Supplementary Fig. 1, the gate fidelities as a function of the number of qubits are provided in Supplementary Fig. 2, and last the average laser power as a function of the number of qubits and gate time is analyzed in Supplementary Fig. 3.

Excitation Circuit Benchmarks

We first benchmark individual excitation gate decompositions, and, second, benchmark approximate ground state preparation of various molecules. We assume that single-qubit gate errors would be negligible and only apply noise to the MS gates according to the results section. We keep the frequency fluctuations Δωp fixed for every MS gate during one circuit execution, but assume different laser power fluctuations ΔΩ(i) for each MS gate within that circuit. This is motivated by the fact that the frequency fluctuations can be assumed constant on the timescale of minutes81. For all following simulations, we approximate the infinite sampling limit by computing expectation values based on statevector simulations for M noisy realizations of the circuits using Qiskit89.

For benchmarking the individual excitation gates, we evaluate the average circuit infidelity \(1-{\mathcal{F}}\) with

$${\mathcal{F}}=\frac{1}{2\pi }{\int }_{-\pi }^{\pi }d\theta {| \langle {\psi }_{{\text{HF}}}| {U}^{\dagger }(\theta )\widetilde{U}(\theta )| {\psi }_{{\text{HF}}}\rangle | }^{2}\,,$$
(37)

for single and double excitations. Here, \(\widetilde{U}(\theta )\) is a noisy excitation gate and U(θ) is an ideal excitation gate without noise. \(| {\psi }_{{\text{HF}}}\rangle\) is the state where the qubits p, for \({U}_{p}^{q}\), or p and q, for \({U}_{pq}^{rs}\), are in state \(| 1\rangle\) while all others are in state \(| 0\rangle\). We benchmark excitation gates that act on different number of qubits, from two to twelve, on arbitrary subsets of the linear ion trap. The results of our simulations are shown in Fig. 6. The statistics in Fig. 6 come from sampling the frequency noise parameters (Δωp) M = 5000 different times for each locality, and then applying laser power fluctuations ΔΩ(i) to each MS gate separately. We see about half-an-order of magnitude improvements in the circuit infidelity for single excitations, when using our decomposition compared to the decomposition of ref. 24. For double excitations, this improvement increases to about one order of magnitude. These relative improvements are rather independent of the number of qubits the excitation gates act on, yet slowly decrease with increasing number of qubits. The stronger improvement for double excitations is naturally attributed to that fact that our decomposition reduces the number of MS gates by a factor of 4 instead of 2 for single excitations.

Fig. 6: Benchmarks of the excitation-gate fidelities.
Fig. 6: Benchmarks of the excitation-gate fidelities.
Full size image

Circuit infidelities for (a) single excitations, and (b) double excitations, for different number of qubits the gates act on, once with our decompositions (blue), and once with the one presented in ref. 24 (red). The statistics come from first sampling the frequency noise parameters paired with random excitation angles M = 5000 different times for each number of qubits. We then consider laser power fluctuations for each MS gate separately, thus resulting in averages over 10,000, and 20,000 experimental realizations of MS gates in our circuits for singles-, and doubles, respectively. Consequently, for the reference, we consider 20 000, and 80 000 realizations of MS gates. The markers show the mean of the respective distributions.

UCCSD Benchmarks

Further, we benchmark 11 molecules (H2, HeH+, H3+, H4, He2, OH, HF, NeH+, LiH, BeH2, and H2O), which geometries and electronic structure Hamiltonians are taken from the Pennylane dataset90. The Hartree-Fock ground state of diatomic He2 has been calculated in the 6-31G basis set, while for all other molecules, the basis set STO-3G was used. We apply the frozen core approximation to the molecules H2O and BeH2, in each case freezing two electrons associated to the spatial orbital with the lowest single-particle energy.

In order to apply our noise model, we first run a noiseless statevector calculation with the UCCSD ansatz optimized with ExcitationSolve49 to find the optimal parameters for each molecule. We then build a new ansatz consisting of only excitations present in the UCCSD that have optimal parameter values with absolute values above a threshold of 10−2. We note that in practice, one would pick the most important excitations either classically, e.g., based on second order Møller-Plesset perturbation theory (MP2) for double excitations28, or on a quantum device using notions of ADAPT-VQE91 specifically tailored for arbitrary excitations49. The combination of classical selection and warm-start strategies and adaptive quantum algorithms enables not only shallow circuits, but also significant speed-ups in convergence92. However, given that the goal of this section is to assess the quality of shallow UCCSD circuits under noise, the selection strategy to obtain the shallow circuit in the first place is secondary, and our brute-force selection based on a full UCCSD calculation is sufficient. The UCCSD ansatz is build once with fermionic excitations, and once with qubit excitations55. We use these parameter-truncated ansätze to perform our noisy simulations. We have verified that for both fermionic- and qubit excitations, the truncated ansätze can achieve chemical accuracy of 10−3 Ha31 on an ideal device.

In Fig. 7 we present energy differences to the FCI result, state infidelities w.r.t. to noiseless parameter-truncated states, absolute errors in the particle number operator, absolute errors in the Sz spin projection, and absolute errors in the total spin S2. This data is reported for the various molecules listed above. The statistics in Fig. 7 come from sampling the frequency noise parameters between M = 10 000 for the smallest molecular systems, down to M = 1000 times for the largest molecules, and then applying laser power fluctuations to each MS gate within the UCCSD circuits. We perform our noisy simulations once with our decomposition of fermionic- and qubit excitations, and once with the decomposition presented in ref. 24.

Fig. 7: Benchmarks of UCCSD circuits for various molecules.
Fig. 7: Benchmarks of UCCSD circuits for various molecules.
Full size image

Results from the molecular benchmarks. a Energy differences to the FCI result, (b) state infidelities w.r.t. to noiseless parameter-truncated states, (c) absolute errors in the particle number operator, (d) absolute errors in the Sz spin projection, and (e) absolute errors in the total spin S2 for various molecules. The statistics are gathered by sampling the frequency noise parameters M = 10 000 times for H2, HeH+, H3+, then M = 2500 times for H4, and M = 1000 times for He2, OH, HF, NeH+, LiH, BeH2, and H2O. Laser power fluctuations are then applied individually to each MS gate within each circuit execution. The markers show the mean of the respective distributions. We use our decompositions of fermionic excitations (blue) the decomposition from ref. 24 (red). In addition, we use our decomposition in combination with qubit excitations (green) instead of fermionic excitations. For H2O and BeH2 we use the frozen core approximation to reduce the needed qubits by two. The black horizontal lines show Hartree-Fock energy errors with respect to the FCI solution.

In terms of energy error, we see consistent improvements between about half-an-order and one order of magnitude for all molecules when using our decomposition. For the state infidelities we outperform the decomposition of ref. 24 by up to one order of magnitude as well. Concerning the violation of conserved quantities, we also observe significant improvements for all tested molecules. All energy errors when using our fermionic decomposition, except for the molecules H2, HeH+, and H3+, are still above the Hartree-Fock energy errors. This shows that the simulated noise significantly degrades the state even when only considering the most important excitations within our optimized circuit decompositions. This effect of the noise is less pronounced for the QEB circuits, where the energy error of the 12-qubit system LiH is below the Hartree-Fock error even under noise. In general, we observe mostly small but consistent improvements for qubit excitations over fermionic excitations across all larger systems. This is particularly pronounced on the electron number error which is consistently closer to zero, which we attribute to the QEB disturbing occupation numbers on less qubits in general. On the other hand, there is only little improvement for the spin projection error and total spin error when using QEB circuits, revealing that the occupation numbers within the individual spin-sectors are more prone to errors, which in the total electron number mostly cancel out. Overall, the advantage of using QEB circuits is less pronounced than on limited-connectivity hardware, since here the number of entangling gates and circuit depth remains identical, although the locality of the MS gates is reduced depending on the type of excitation. For the considered molecules, the list of important excitations is typically dominated by doubles acting on two spatial orbitals p, q, i.e., \({G}_{{\alpha }_{p}{\beta }_{p}}^{{\alpha }_{q}{\beta }_{q}}\), where fermionic- and qubit excitations turn out to be equivalent when the spin-orbitals are enumerated in alternating order (α0, β0, α1, β1, … ). In fact, for H2 and \({{H}_{3}}^{+}\), our fermionic- and QEB circuits are identical. The advantage of qubit excitations becomes most pronounced on the larger molecules HF, NeH+, LiH, BeH2, and H2O, where long-range single-excitations and doubles involving more than two spatial orbitals play significant roles. The largest benefit can be seen for LiH, which is due to the long-range fermionic double excitations α1, β1, α2, β5, and α1, β1, β2, α5, now acting on 4 instead of 10 and 8 qubits, respectively.

Overall, we conclude that our techniques provide significant improvements over the reference with respect to every metric. We also want to stress that our circuits could be readily paired with error mitigation techniques, likely leading accurate estimates of energy errors below the HF error. Since the focus of this work is on circuit decomposition techniques and the corresponding circuit quality improvements, we have deliberately refrained from using such techniques in order to isolate the influence of our methods.

Discussion

In this work, we introduced a parallelization scheme to reduce the number of MS gates for the implementation of fermionic excitations. Compared to previous works24,25, we achieve a speedup of 2 and 4, for single- and double excitations, respectively. We further generalized our parallelization strategy to qubit single- and double excitations. We then studied our circuits in the presence of realistic experimental noise by emulating a 12-qubit linear ion trap at the pulse level, showcasing significant improvements over24 across various molecular benchmarks, leading to fidelity improvements of up to one order of magnitude. We do however note that even with our improvements, meaningful accuracy improvements beyond HF theory would be tricky to achieve with the noise levels of current state-of-the-art quantum computers. Still, looking at the relative improvements in fidelity, our circuits hold the prospect of significantly improving fermionic simulations on real ion trap devices. And for near-term quantum hardware, pairing our technique with QEB ansätze is a promising avenue.

We note that our techniques could be readily extended to the simulation of fermion-boson interactions in a digital-analog fashion by encoding the bosonic operators into the vibrational modes of the ion chain93, as it has been suggested in refs. 24,25. This gives access to systems such as the Fröhlich model94, which captures the properties of polarons in some crystal structures95,96. Such simulations would extend the utility of our method beyond purely fermionic static- and dynamic properties to e.g., more complex phenomena in photochemistry6,97,98, or the study of non-adiabatic electron-nuclear dynamics74.

As we have pointed out, the parallelization techniques presented in this work are not readily applicable to other fermionic mappings. Meanwhile, the development of more efficient hardware-agnostic mappings is a flourishing field of ongoing research12,18. However, such mappings are typically developed with limited qubit connectivity in mind, and more importantly decompositions in terms of two-qubit gates. This raises the questions whether similar endeavors could lead to more efficient parallelizable mappings within the targeted MS gate set.

Last, we want to emphasize that our pulse simulations suggest that the MS gate time scales sub-linearly in the number of qubits, thus effectively achieving sub-linear circuit times even within linear-locality mapping such as JW, which ultimately highlights that trapped ions are promising platform for fermionic simulation.

Methods

The Backward MS Gate

One can entirely avoid Backward MS Gates by exploiting that MS Gates are equivalent to their “forward” counterparts23. Here, we assume an MS interaction acting on n qubits.

$${U}_{{\rm{M}}{\rm{S}}}(-\theta ,\phi )=\{\begin{array}{cc}{U}_{{\rm{M}}{\rm{S}}}(\pi -\theta ,\phi ), & {\text{for}}\,n\,{\text{odd}},\\ {U}_{{\rm{M}}{\rm{S}}}{(\pi -\theta ,\phi )\bigotimes }_{i}{\sigma }_{i}(\phi ), & {\text{for}}\,n\,{\text{even}}.\end{array}$$
(38)

For even n, this equivalence only holds up to local unitaries of the form \({\sigma }_{i}(\phi ):=\cos (\phi ){X}_{i}+\sin (\phi ){Y}_{i}\). For the fully entangling MS gates XX and YY from equations (2) and (3), this boils down to a self-inverse property U = U up to local Paulis for an odd number of qubits. More preciseliy, we have

$${{\bf{XX}}}^{\dagger }={\bf{XX}}\left\{\begin{array}{ll}{\rm{I}}, & \mathrm{for}\,{\rm{n}}\,\mathrm{odd},\\ {\bigotimes }_{{\rm{i}}}{{\rm{X}}}_{{\rm{i}}},\, & \mathrm{for}\,{\rm{n}}\,\mathrm{even},\end{array}\right.$$
(39)

and

$${{\bf{YY}}}^{\dagger }={\bf{YY}}\left\{\begin{array}{ll}{\rm{I}}, & \mathrm{for}\,{\rm{n}}\,\mathrm{odd},\\ {\bigotimes }_{{\rm{i}}}{{\rm{Y}}}_{{\rm{i}}},\, & \mathrm{for}\,{\rm{n}}\,\mathrm{even}.\end{array}\right.$$
(40)

The Jordan-Wigner Mapping

In order to emulate fermionic systems on a quantum computer, one needs a mapping between fermionic operators and qubit operators, i.e., a representation of fermionic operators in the Pauli basis. In this work, we focus on the Jordan-Wigner (JW) mapping. While often employed due to its inherent simplicity, the JW mapping faces the drawback of mapping fermionic operators on an n-mode system to terms with linear locality \({\mathcal{O}}(n)\). However, the linear locality of the JW mapping is to be seen as less problematic for ion trap quantum computers due to the all-to-all connectivity and native global interactions.

The fermionic (creation) annihilation operators a(†) satisfy the canonical commutation relations \(\{{a}_{p},{a}_{q}^{\dagger }\}={\delta }_{pq}\) and \(\{{a}_{p},{a}_{q}\}=\{{a}_{p}^{\dagger },{a}_{q}^{\dagger }\}=0\). Under the JW mapping, these fermionic operators take the following form:

$${a}_{p}^{(\dagger )}\to \frac{1}{2}\left(\mathop{\bigotimes }\limits_{k < p}{Z}_{k}\right)\otimes ({X}_{p}(\mathop{-}\limits^{+}){\mathcal{I}}{Y}_{p}).$$
(41)

Note that the non-locality arises from the \({\mathcal{O}}(n)\)-local parity strings consisting of Pauli-Z operators, which ensure the proper anticommutation relations. Through the course of this work, we use the MS gate to efficiently take these contributions into account.

Circuits for Controlled Single Excitations

When considering the JW-mapped expression for the controlled single excitation

$${G}_{pj}^{qj}\to -\frac{1}{4}({I}_{j}-{Z}_{j}){{\mathcal{Z}}}_{p}^{q}({Y}_{p}{X}_{q}-{X}_{p}{Y}_{q}),$$
(42)

where we again assumed p < q, we must distinguish between two cases.

Case 1: If j < p or j > q, the control qubit j is not affected by the single-excitation generator \({G}_{p}^{q}\). Therefore, we can simply obtain the circuit by replacing the Rz(θ) gates in Fig. 2 by controlled Z-rotations CjRz( − θ), as depicted in Fig. 8. Alternatively, one may implement \({G}_{p}^{q}\) and \({Z}_{j}{G}_{p}^{q}\) separately. The latter can be achieved by adding j to the MS interaction.

Fig. 8: Circuit decomposition of the controlled single-excitation gate.
Fig. 8: Circuit decomposition of the controlled single-excitation gate.
Full size image

Circuit decomposition of the controlled single-excitation gate \({U}_{pj}^{qj}(\theta )=\exp (-i\theta {G}_{pj}^{qj})\) using the XX gate in terms of two MS gates and two CjRz gates. The dots labeling the quantum wire bundle represent all qubits affected by the parity string \({{\mathcal{Z}}}_{p}^{q}\), except j if p < j < q. The light-gray dashed gates are used if the number of qubits in the wire bundle is odd. The signs in brackets account for the sign flip for p < j < q.

Case 2: If p < j < q, equation (42) contains the expression − (IjZj)Zj = IjZj. When using controlled rotations, this effectively removes qubit j from the MS interaction in Fig. 2 and turns it into a control qubit (Fig. 8a). Optionally, the separate decomposition of \({G}_{p}^{q}\) and \({Z}_{j}{G}_{p}^{q}\) also works, though now the latter term is achieved by removing j from the MS interaction.

Compared to the technique from ref. 24, our circuits once again cut the number of MS gates by half as for the regular single excitations.

Simulation with Real-Valued Orbitals

For real orbitals, the one- and two-electron terms are real, thus simplifying the symmetries to hpq = hqp and hpqrs = hqpsr = hrspq = hsrqp. This changes the electronic Hamiltonian to

$${H}_{el.}=\frac{1}{2}\mathop{\sum }\limits_{pq}{h}_{pq}{\widetilde{G}}_{p}^{q}+\frac{1}{4}\mathop{\sum }\limits_{pqrs}{h}_{pqrs}{\widetilde{G}}_{pq}^{rs},$$
(43)

thus removing all the antisymmetric terms from equation (15). At the same time, real orbitals introduce four additional permutation symmetries to the two-electron integrals, namely hpqrs = hrqps = hspqr = hpsrq = hqrsp50. This allows as to further simplify the Hamiltonian to

$${H}_{{\text{el}}.}=\frac{1}{2}\mathop{\sum }\limits_{pq}{h}_{pq}{\widetilde{G}}_{p}^{q}+\frac{1}{8}\mathop{\sum }\limits_{pqrs}{h}_{pqrs}({\widetilde{G}}_{pq}^{rs}+{\widetilde{G}}_{ps}^{rq}).$$
(44)

A derivation is provided in Supplementary Note 6. The term \({\widetilde{G}}_{pq}^{rs}+{\widetilde{G}}_{ps}^{rq}\) boils down to 4 Pauli strings instead of 8, which we can use to simplify the circuit structure. We use the antisymmetrized version \({G}_{pq}^{rs}+{G}_{ps}^{rq}\) to derive the corresponding circuit. From equation (24), we conclude that

$$\begin{array}{rcl} & & {G}_{pq}^{rs}+{G}_{ps}^{rq}\to \frac{1}{4}{{\mathcal{Z}}}_{pq}^{rs}\\ & & \times ({X}_{p}{X}_{q}{X}_{r}{Y}_{s}-{X}_{p}{Y}_{q}{X}_{r}{X}_{s}+{Y}_{p}{X}_{q}{Y}_{r}{Y}_{s}-{Y}_{p}{Y}_{q}{Y}_{r}{X}_{s}).\end{array}$$
(45)

We can implement this term using the circuit from Fig. 3 by removing the Rz gates on qubits qp and qr and adjusting the angles of the Rz gates on qubits qq and qs. Despite the reduction in Pauli strings, it still requires 4 MS gates. Hence, the four additional symmetries do not benefit the runtime of our quantum simulation scheme. However, assuming that hpqrshprsq ≠ 0, the full 8 strings will be restored. Nonetheless, the use of real orbitals halves the number of terms in the Hamiltonian and followingly the depth of the Trotter step circuit. On a side note, linear combinations of the type \({G}_{pq}^{rs}\pm {G}_{ps}^{rq}\), also referred to as coupled exchange operators, have recently proven to be useful in variations of UCCSD theory99.

The Experimental MS Gate

In the following, we focus on the XX gate with ϕ = 0 to simplify the notation. All considerations hold equivalently for the YY gate. The unitary operator corresponding to the experimental MS gate is obtained exactly by solving the time evolution operator via second-order Magnus expansion82,100, and reads

$$\begin{array}{l}{U}_{\mathrm{MS}}(t)=\exp \left(-i\mathop{\sum }\limits_{i < j}^{N}{\chi }^{(i,j)}(t){X}_{i}{X}_{j}\right)\\ \,\,\,\,\,\,\,\,\,\,\,\,\,\,\times \exp \left(\mathop{\sum }\limits_{i}^{N}\mathop{\sum }\limits_{p}^{N}[{\alpha }_{p}^{(i)}(t){a}_{p}^{\dagger }-{\rm{H}}.{\rm{c}}.]{X}_{i}\right).\end{array}$$
(46)

The first part implements the spin-spin interaction between the ions electronic states/logical qubit states, whereas the second part captures the spin-displacement coupling between the electronic states and vibrational mode coherent states. Note that for χ(i, j) = θ/2, the first term corresponds to the ideal MS gate assumed in equation (1). The geometric phases defining the Ising evolution are given by

$$\begin{array}{l}{\chi }^{(i,j)}(t)=\mathop{\sum }\limits_{p}{\eta }_{p}^{(i)}{\eta }_{p}^{(j)}{\int }_{0}^{t}d{\tau }_{2}{\int }_{0}^{{\tau }_{2}}d{\tau }_{1}{g}^{(i)}({\tau }_{1}){g}^{(j)}({\tau }_{2})\\ \,\,\,\,\,\,\,\,\,\,\,\,\,\,\times \sin ({\omega }_{p}({\tau }_{2}-{\tau }_{1})),\end{array}$$
(47)

and the phase space displacements of the vibrational modes are

$${\alpha }_{p}^{(i)}(t)={\int }_{0}^{t}d\tau {g}^{(i)}(\tau ){e}^{i{\omega }_{p}\tau }.$$
(48)

By tracing out the phonon modes, one can quantify the decoherence from residual ion-vibration entanglement82 and obtain the quantum channel acting solely on the qubit states.

Pulse Modulation and Gate Stabilization

In the following, we briefly recap the power-optimal stabilized entangling gate scheme from ref. 81. A more detailed elaboration is provided in Supplementary Note 7. The pulse functions (which entail both the amplitude and detuning) are expanded in a Fourier-sine basis. The pulse acting on the ith ion is defined as

$${g}^{(i)}(t)=\mathop{\sum }\limits_{n=1}^{{N}_{A}}{A}_{n}^{(i)}\sin \left(2\pi n\frac{t}{T}\right)$$
(49)

where T is the gate time, \({A}_{n}^{(i)}\) the nth Fourier coefficient and NA the total amount of Fourier coefficients. By construction, the pulse vanishes at t = 0 and t = T. To ensure experimental viability of the pulses, the highest Fourier frequency is restricted to \({\omega }_{{N}_{A}}=2\pi \times {N}_{A}/T\le 2\pi \times 5\,MHz\), which is well within the capabilities of acusto-optical or electro-optical modulators typically used to modulate the laser beams. To avoid residual ion-vibration entanglement, the pulses must satisfy the property \({\alpha }_{p}^{(i)}(T)=0\), which translates into N linear constraints of the type \({\sum }_{n=1}^{{N}_{A}}{M}_{pn}{A}_{n}^{(i)}=0\) with \({M}_{pn}={\int }_{0}^{t}d\tau \sin (2\pi n\tau /T){e}^{i{\omega }_{p}\tau }\). To additionally stabilize this condition against vibrational mode fluctuations Δωp up to order S, the conditions \({\partial }^{s}/\partial {\omega }_{p}^{s}\,{\alpha }_{p}^{(i)}(T)=0\) must be satisfied, which translates into N × S additional linear constraints \({\sum }_{n=1}^{{N}_{A}}{M}_{pn}^{(s)}{A}_{n}^{(i)}=0\). By computing an orthonormal basis of the nullspace of M, one restricts the pulse-space basis to only such solutions which ensure vanishing residual ion-vibration entanglement, and reduces the dimension of our optimization problem. This then conveniently removes the second term of equation (46). In our simulations, we use S = 10 as we find that the dimension of the nullspace does not decrease beyond that.

Next, we require that all pair-wise entanglement degrees satisfy χ(i, j)(T) = π/4 for qubits i and j participating in the maximally entangling MS interaction. For a global MS interaction, this translates into N × (N − 1)/2 quadratic constraints of the type \({\sum }_{n,m=1}^{{N}_{A}}{A}_{n}^{(i)}{S}_{nm}{A}_{m}^{(j)}=\pi /4\) (cf. Supplementary Note 7). To make the entanglement degree robust against motional frequency fluctuations, one can again enforce vanishing derivatives up to some order K, which then yields K × N × (N − 1)/2 additional quadratic constraints of the type \({\sum }_{n,m=1}^{{N}_{A}}{A}_{n}^{(i)}{S}_{nm}^{(k)}{A}_{j}^{(m)}=0\). According to ref. 81, the average laser power grows exponentially in K, which is why we choose the lowest stabilization order K = 1 in our simulations.

The objective of finding power-optimal stabilized gates then boils down to minimizing the average laser power per ion \({\gamma }^{2}:=1/N{\sum }_{i}{\sum }_{n}{({A}_{n}^{(i)})}^{2}\) under the quadratic constraints, which belongs to a class of optimization problems referred to as quadratically constrained quadratic program (QCQP)101. For experimental application, optimizing the maximum instead of the average power would be more relevent. However,43 show that both objectives lead to similar pulse shapes, with optimization on average power being more numerically stable. For two-qubit MS gates, the globally optimal solution can be efficiently constructed43,81. While the procedure does not generalize to global MS gates, it serves as a valuable initialization strategy in our simulations.