Introduction

Although most quantum computing architectures focus on two-level quantum systems for encoding qubits, the need for auxiliary quantum systems or extra quantum states is ubiquitous. These extra degrees of freedom are used to, e.g., mediate gates between qubits, perform measurements or cooling during a computation, or improve the qubit connectivity. For neutral atom and trapped ion quantum computers, these auxiliary degrees of freedom often take the form of a second atomic species1,2,3 and/or atoms that are moved during the circuit1,4,5,6,7. Recently, the potential of extra states within the atoms to address these needs has gained intense interest. The ability to use two or more portions of the atomic level structure to perform disparate functions simultaneously without crosstalk has recently enabled “mid-circuit” operations such as readout and cooling1,8,9,10,11,12,13,14. Additionally, it has been shown how the ability to programmably repurpose an atom for these roles by moving it between the different sets of levels opens the door to improved hardware efficiency and more flexible circuit compiling9,11,15.

When using auxiliary states within an atom to perform ancillary functions for our qubits, a natural question is whether it may be advantageous to include these states in the computational space and encode quantum information in a higher dimension. For instance, when using a pair of extra states to provide two distinct qubit encodings within one atom, we could alternatively think of this four-level system as a “ququart” composed of two qubits16. Higher-dimensional encodings with “qudits” have attracted much attention for neutral atoms14,17,18,19,20,21, trapped ions16,22,23,24,25,26 and superconducting circuits27,28,29,30. Qudit systems offer improved hardware efficiency including logical encoding31 and potentially have better performance if the intra-atom gates have higher fidelity than the inter-atom gates. However, the required intra-atom operations quickly become numerous and challenging as the dimension grows, and thus relatively small internal spaces whose states are already widely used for myriad qubit operations offer an attractive starting point for architectures with higher-dimensional encoding.

Here, we focus on a four-level “ququart” encoding of quantum information in neutral ytterbium-171 (171Yb) by employing the optical “clock” transition and the nuclear spin-1/2 degree of freedom. We show that this ququart can equivalently be represented as two qubits—the optical (“o”) qubit and the nuclear (“n”) qubit—with the full gate set of intra-atom one- and two-qubit gates, inter-atom two- and four-qubit gates, and measurements. We show several example applications of our encoding such as entanglement distillation, quantum error correction, and a new approach to interactive quantum circuits that leverages single-state quantum nondemolition readout. Our work builds upon the growing literature of higher-dimensional encoding schemes for neutral atoms14,17,19,20, trapped ions16,22,23,24,25 and superconducting circuits27,28,29,30, and presents a comprehensive blueprint for qudit encodings that are specifically focused on a direct mapping with qubit circuits16.

Results

Ququart operations in 171Yb atoms

We now focus on the level structure and operations surrounding the ququart encoding. Specifically, we focus on operations that are easily translated to the more widely used language of qubits because they allow us to apply our ququart system to any qubit-based algorithm. Figure 1a shows the relevant energy levels and the transitions related to our ququart operations. The ququart is encoded in the F = 1/2 1S0 (ground) and 6s 6p 3P0 (metastable) manifolds, each with two nuclear Zeeman substates. Transitions between the ground and metastable states are driven by a direct optical “clock” coupling, and transitions between nuclear Zeeman states are driven by a stimulated Raman coupling. The mapping between our ququart states and two-qubit states (\(\left\vert 00\right\rangle\), \(\left\vert 01\right\rangle\), \(\left\vert 10\right\rangle\) and \(\left\vert 11\right\rangle\)) is based on treating the ququart states as the tensor product of an optical clock (“o”) qubit and a nuclear Zeeman (“n”) qubit, as is shown in Fig. 1b. We discuss this mapping more formally and consider ququart state tomography in the Supplementary Materials (SM).

Fig. 1: Overview of ququart encoding architecture in the omg level structure of 171Yb atoms.
figure 1

a The relevant energy levels and operations. We encode a ququart in the 1S0 and 3P0 manifolds of 171Yb atom, each containing two nuclear Zeeman states. Qubit rotations of the states in the same manifold are performed with radio-frequency magnetic field or stimulated Raman transitions, while 1S0 and 3P0 states are connected through optical clock transitions. Readouts is performed on 1S0 substates using 1S03P1 transition. Inter-ququart entangling gates are driven by single-photon Rydberg excitation from 3P0 states to high-principle quantum number Rydberg states denoted as 3S1. b Two-qubit encoding in one ququart. The ququart can be treated naturally as the tensor product of an optical (“o”) and a nuclear (“n”) qubit.

Before going into detail on this encoding scheme and the required operations, we briefly summarize the state of the art and the primary challenges. The ground and metastable nuclear spin qubits have both been manipulated with gate fidelities of \({\mathcal{F}}\approx 0.999\) and have coherence times of \({T}_{2}^{* }\, >\, 7\) seconds12,32,33,34,35,36. The primary challenge centers around realizing fast, high-fidelity optical qubit operations with a long coherence time. Long-term phase stability is needed for running long circuits, high-frequency phase noise must be suppressed when performing fast gates, and deleterious motional effects from finite temperature and finite trap frequencies must be mitigated. Techniques have been devised to filter high-frequency phase noise on ultrastable lasers11,37,38,39, and motional ground-state cooling schemes11,14,34 combined with carefully chosen pulse design11,14 have been used to obviate the effects of atomic motion. Finally, we assume that the atoms are trapped at a “magic” wavelength for which the potential experienced for all four states is identical11,35,36,40. Optical clock transitions have been manipulated with gate fidelities of \({\mathcal{F}}\approx 0.998\) and have coherence times of \({T}_{2}^{* }\approx 3\) seconds11,14,41.

Intra-ququart gates

Using the two-qubit encoding described above, intra-ququart one- and two-qubit gates can be performed by driving optical clock or Raman transitions. Figure 2 shows four typical sets of intra-ququart gates, including single-qubit rotations, two-qubit swap, and CNOT gates. Further details on the intra-ququart gates can be found in the Supplementary Materials.

Fig. 2: Intra-ququart gates through clock and Raman transitions.
figure 2

a Single-qubit rotations \({R}_{\hat{n}}(\theta )\) of angle θ along rotation axis \(\hat{n}\) on the “o”-qubit via pairs of clock transitions. To ensure that the state of the other qubit is unaffected, the two transitions within a pair should perform the same rotations on each pair of states. b Single-qubit rotations \({R}_{\hat{n}}(\theta )\) on the “n”-qubit driven by pairs of stimulated Raman transitions. c The intra-ququart swap gate is achieved by applying a π-rotation between \(\left\vert 01\right\rangle\) and \(\left\vert 10\right\rangle\) states. This operation swaps the information encoded in “o”- and “n” qubits. d Intra-ququart CNOT gate is achieved by applying a π-rotation between \(\left\vert 10\right\rangle\) and \(\left\vert 11\right\rangle\) states. When the control qubit (“o”-qubit) is in \(\left\vert 1\right\rangle\) state, a bit-flip operation is applied to the target qubit (“n”-qubit).

The single-qubit gates on the “o”- or “n”-qubit require one pair of clock or Raman transitions mediated by different states (Fig. 2a, b). For the “o”-sector rotations, we assume that both transitions have the same resonance frequency. This is a good approximation in a small magnetic field11 or under application of a light shift on one of the four states when operating at a high field (see Supplementary Materials). However, even when this condition is not satisfied and the two sectors undergo a slow, passive entangling operation, this effect can be deterministically compensated. For the “n”-qubit rotations, the Raman transitions in the ground and metastable states do not have crosstalk since the wavelengths associated with the intermediate states are separated by ~102 THz. The Rabi frequencies of each Raman transition can be matched.

Intra-ququart two-qubit gates are often simpler than single-qubit gates: Fig. 2c, d shows the intra-ququart swap and CNOT operations. The swap gate is achieved by driving a π-pulse between \(\left\vert 01\right\rangle\) and \(\left\vert 10\right\rangle\) state, effectively swapping the information encoded in “o”-qubit and “n”-qubit. The CNOT gate with the control qubit “o” and the target qubit “o” is achieved by swapping the population in \(\left\vert 10\right\rangle\) and \(\left\vert 11\right\rangle\) states. Note that operations such as the CNOT gate induce a differential light shift in the ‘o’ sector, leading to a phase accumulation during its execution. This effect can be neutralized with an additional light shift or deliberately engineered to produce a trivial 2π phase shift.

Inter-ququart gates

For neutral atoms, entangling two physical qubits is commonly achieved through Rydberg blockade42,43,44,45,46,47. Specifically, two-qubit entangling gates between metastable nuclear spin qubits in 171Yb12 and optical clock qubits in strontium-8814,48 have been achieved with single-photon Rydberg excitations. To perform an entangling gate, one commonly used way is to selectively couple one of the two qubit states to a Rydberg state, such that due to Rydberg blockade between nearby atoms, the qubit states accumulate a state-dependent phase, generating a CZ gate under proper experimental settings47.

With our ququart encoding, we first consider a four-qubit CCCZ gate: the CZ gate that was recently demonstrated for the metastable nuclear spin qubit of 171Yb12 becomes a CCCZ gate directly with the inclusion of the two ground states into the computational space. As shown in Fig. 3a, the phase shift due to Rydberg interactions is only present in the \(\left\vert 11\right\rangle\) state of each ququart. The gate’s performance is simulated in the Supplementary Materials, where we demonstrate its theoretical maximum effectiveness at the 99.9% fidelity level.

Fig. 3: Inter-ququart gates based on Rydberg transitions.
figure 3

Rydberg coupling is accessed is accessed through a single-photon transition of λ = 302 nm from 3P0 states to high-principle quantum number states. a One stretched Rydberg transition is driven on two nearby atoms, achieving inter-atom entanglement via Rydberg blockade. With the two-qubit encoding, this inter-ququart gate performs a CCCZ gate. b Inter-ququart CZ gates on the “o”-qubits of two ququarts. Both stretched Rydberg transitions are driven with the same Rabi frequency, detuning, and phase such that both 3P0 states can couple to Rydberg states.

We also demonstrate an inter-ququart CZ gate between the two “o”-qubits of the ququarts. Figure 3b shows the gate scheme of this “o”-sector inter-ququart CZ gate, which must be agnostic to the “n” sector. To excite both the states in the optical \(\left\vert 1\right\rangle\) state to the Rydberg manifold, we drive two stretched Rydberg transitions between \(6s\,6{p}{{3}\atop}{P}_{0}\left\vert {m}_{F}=\pm 1/2\right\rangle\) and \(6sn{s}{{3}\atop}{S}_{1}\left\vert {m}_{F}=\pm 3/2\right\rangle\) states with the same Rabi frequency, detuning, and phase. Apart from the necessity of these dual-tone Rydberg excitation, our approach adheres to the standard Rydberg CZ gate protocol47,49. This gate scheme requires Rydberg states of different mF’s to blockade each other. In the Supplementary Materials, we show that the blockade strengths between Rydberg states of different mF’s are expected to be of the same order of magnitude (limited spectroscopic data is available), and we perform a numerical simulation of this (2 × 8)-dimensional space for realistic parameters. We believe that, by adding a sideband to the Rydberg laser pulse, it is relatively straightforward to achieve this CZ ququart gate with a performance matching that of the ‘standard’ two-qubit CZ gate.

Notably, we can also perform gates between an atom with ququart encoding and an atom functioning only as a qubit which is encoded in the metastable nuclear spin. There are two approaches: One option is to apply only one Rydberg drive (σ+ or σ) to the qubit atom but apply both (σ+ and σ) to the ququart atom. This will perform a CZ gate between the metastable nuclear spin of the qubit atom and the “o”-qubit of the ququart atom. A second option is to first convert the metastable nuclear spin of the qubit atom into an optical qubit via the swap gate in Fig. 2c, then apply the CZ gate with both Rydberg tones on each atom (global pulses), and then swap the qubit-atom’s encoding back to the metastable nuclear spin.

Readout

The readout of higher-dimensional spaces like qudits can be cumbersome. In neutral atoms and trapped ions, the ground state manifold typically exhibits fluorescence (“bright”), in contrast to the non-fluorescent (“dark”) metastable manifolds. The usual method for qudit readout in such cases involves ‘shelving’ all but one basis state into the metastable manifold, with the chosen state transitioned (mapped) into the ground state for readout. Following fluorescence readout, this ground state is reset and then shelved into the metastable manifold, with the process sequentially repeated for each state24. Hence, readout of a d-level qudit usually involves up to d − 1 iterations of this cycle as only one state is probed at a time. This approach is exponentially less efficient than measuring multiple qubits in parallel.

Instead, here we perform a 2-round deterministic readout of the ququart states based on the quantum nondemolition (QND) readout of the 1S0 nuclear spin ground states35,36, which reduces the upper limit of the required number of measurement operations from 3 to 2. Figure 4a shows the 2-round ququart readout scheme. This readout protocol requires simultaneously probing on two 1S03P1 stretched transitions and collecting the scattered photons. Both stretched transitions are closed (“cycling”) under a magnetic field of 102 G, which allows us to perform readout of the “o”-qubit without transferring the population between “n” qubit states. We apply two rounds of the dual-stretched readout with an intra-qubit SWAP operation sandwiched in between. Conceptually, the first readout measures the “o” qubit while the second readout measures the “n”-qubit. The two bits of information from the readout process determine the projective measurement outcome and post-measurement state. For instance, “bright”-“bright” refers to \(\left\vert 00\right\rangle\) while “bright”-“dark” refers to \(\left\vert 01\right\rangle\), etc.

Fig. 4: Different ququart readout schemes.
figure 4

a Two-round deterministic readout of ququart states. Two stretched transitions 1S03P1 are simultaneously driven, and the resultant photons are detected in an indistinguishable manner, effectively measuring the “o”-qubit. Note that the cyclicity of the transitions ensures that the population in 1S0 substates remains in the same state after measurement. Afterward, an intra-ququart SWAP is applied, swapping the populations in \(\left\vert 01\right\rangle\) and \(\left\vert 10\right\rangle\) states. Finally, the same two stretched transitions are used to effectively measure the “n”-qubit before the swap operation. The four combinations of two readout results can thus be mapped to the four ququart states. b Single-state QND readout of \(\left\vert 00\right\rangle\), within the 1S0 ground state manifold. c The two-qubit analogue of the single-state QND measurement via an ancilla qubit and a Toffoli gate.

Note that readout of only one qubit within the ququart without affecting the other qubit remains challenging with this readout scheme. One exception is that if the “o”-qubit QND readout measures \(\left\vert 1\right\rangle\), then the “n”-qubit is encoded only in the 3P0 states, which is left unaffected. Therefore, the information encoded in the “n” qubit is preserved. As described below, this condition is sufficient for an entanglement distillation protocol in which “o”-qubit readout with outcome \(\left\vert 1\right\rangle\) heralds the generation of purified entanglement in the “n”-sector. Accordingly, although an “o”-qubit readout outcome of \(\left\vert 0\right\rangle\) would collapse the “n”-qubit, the distillation protocols fail anyway and must be re-attempted. We also note that by separately detecting the fluoresced light from the left- and right-stretched transitions using polarization or frequency filtering, it would be possible to fully determine the ququart state in one measurement round when the “o”-qubit is in \(\left\vert 0\right\rangle\).

Finally, we consider a unique opportunity for qudit readout. The typical shelving-probing protocol discussed above that requires d − 1 rounds is cumbersome if all basis states must be measured. However, this scenario presents a unique opportunity to perform a QND readout of a portion of the computational space. Specifically, we propose to perform single-state QND readout via probing with only one stretched transition from the ground manifold35,36 (see Fig. 4b). In this case, \(\left\vert 00\right\rangle\) will be “bright” while all other ququart states will be “dark”. A measurement outcome of “bright” will collapse the ququart to \(\left\vert 00\right\rangle\), while an outcome of “dark” allows a re-normalized superposition of \(\left\vert 01\right\rangle\), \(\left\vert 10\right\rangle\), and \(\left\vert 11\right\rangle\) to survive. Naturally, we must be aware of light shifts on the \(\left\vert 01\right\rangle\) state due to the probe light as discussed in Supplementary Materials. The two-qubit analog of this single-state QND readout paradigm requires an ancilla qubit and a non-Clifford gate, as shown in Fig. 4c. As shown below, this paradigm provides new opportunities for interactive circuits.

Applications

Qudit architectures offer improved hardware efficiency, enabling the encoding of more quantum information—potentially including logical qubits—within a single atom. Moreover, the fidelity of two-atom gates often still lags behind that of one-atom gates in both trapped ion and neutral atom systems. Consequently, the proposed ququart architecture promises potential performance enhancements over traditional qubit systems. This potential is contingent upon maintaining the quality of one-atom gates amidst the complexities introduced by the ququart’s expanded gate set and its additional constraints. However, we note that a portion of the required gate set falls within the toolbox of the ‘omg’ qubit-based architecture. Moreover, the requirements for light shifts and local control are not enormously beyond those required for qubit-based architectures. As such, we believe that intra- and inter-ququart operations could match the performance of ‘standard’ intra- and inter-qubit operations, for which single-atom gates still outperform two-atom gates.

In this section, we focus on leveraging this improved hardware efficiency, enhanced effective connectivity, and potentially superior performance, as well as on applications that exploit the unique readout properties of qudit systems for interactive circuits. In the discussions that follow, we use black lines in the circuit diagrams to represent standard qubits, while two adjacent lines, colored yellow and orange, denote the “o”- and “n”-qubits of a ququart, respectively.

Quantum information processing

Entanglement distillation

Entanglement distillation is a protocol to generate a high-fidelity entangled two-qubit state from two low-fidelity entangled two-qubit states using local operations and classical communication50,51, which has been demonstrated in several physical platforms with qubit architectures52,53,54.

Within our proposed ququart architecture, the distillation protocol is executed more efficiently, requiring only two atoms with operations internal to the ququart and a global readout mechanism. This contrasts with traditional qubit systems, where the distillation necessitates four atoms, the application of inter-atomic gates, and mid-circuit (local) readout techniques.

As illustrated in Fig. 5a, the entanglement distillation protocol begins with a pair of two-qubit entangled states. In our ququart architecture, we assume that the pre-distilled state is given as follows:

$$\left\vert {{\Psi }}_{0}\right\rangle =\mathop{\bigotimes}\limits_{i\in \{{\rm{o}},{\rm{n}}\}}\frac{1}{\sqrt{2}}\left(\,{\left\vert {0}_{1}\right\rangle }^{i}{\left\vert {0}_{2}\right\rangle }^{i}+{\left\vert {1}_{1}\right\rangle }^{i}{\left\vert {1}_{2}\right\rangle }^{i}\,\right).$$
(1)

Here, the subscript indicates the atom, while the superscript distinguishes whether the qubit is optical (o) or nuclear (n). We highlight the presence of entanglement between the optical qubits across two distinct atoms, as well as between their nuclear qubits. This arrangement, comprising a pair of Bell states, can be efficiently produced using inter-ququart gates.

Fig. 5: Entanglement distillation with two ququarts.
figure 5

a Circuit diagram of entanglement distillation, with two nearby yellow and red qubit as a ququart. The two curved lines denote entanglement between two qubits in two ququarts. After the entanglement generation, intra-ququart two-qubit gates are applied, followed by a measurement on the “o”-qubits. We only keep the post-distilled state when both “o”-qubits measure \(\left\vert 1\right\rangle\), which indicates that the entanglement purification succeeds and the “n”-qubit coherence is unaffected. b Simulation results of Bell state infidelities before and after distillation assuming depolarization and Pauli-X errors. c Simulation results of distilled state infidelity and yield under different local two-qubit gate infidelities. Here the pre-distilled state is generated through a depolarization channel with pre-distilled state infidelity of 3%.

We want the final two-qubit state to be encoded in the nuclear qubits of two atoms. Hence, we apply SWAP operations to both ququarts so that we preserve “n” qubits rather than “o” qubits. Finally, the “o” qubit in each ququart is measured in the Pauli Z-basis and the success of the distillation protocol is heralded by an outcome of \(\left\vert 1\right\rangle\) (dark) for both, such that the resulting two-qubit state is indeed encoded in nuclear qubits. We emphasize that this “o”-qubit readout is performed globally as the optical qubit state \(\left\vert 1\right\rangle\) can be measured without interfering with nuclear qubits as discussed in the section “Readout”.

In Fig. 5b, we present the infidelities between both pre-distilled and distilled states compared to the ideal Bell state, aiming to showcase the circuit’s efficacy in distillation. To this end, we consider two distinct error models impacting the inter-ququart gates during the entanglement generation step: the depolarization channel and Pauli-X noise. For both scenarios, we factor in a consistent measurement error rate of 1% and an intra-ququart gate infidelity of 0.1%, with both types of errors simulated via the depolarization channel. The yield under these two types of errors is shown in Fig. 10 in Methods.

The distillation circuit is specifically designed to mitigate Pauli-X errors on Bell states. However, it does not address Pauli-Z errors, leading to its diminished effectiveness in combating depolarization errors, as illustrated by the plot. Given the varied nature of inter-ququart gate errors, which realistically may fall between these two models, we anticipate an improvement in Bell state fidelity under certain conditions. Naturally, higher fidelity local operations in the distillation protocol will lead to higher yield and lower distilled state infidelity. In Fig. 5c, we plot both these metrics as a function of local two-qubit gate infidelity for a 3% depolarization infidelity on the pre-distilled Bell pairs. Under a realistic assumption that our intra-ququart two-qubit gates have higher fidelity than inter-atom two-qubit gates, our ququart distillation protocol can significantly outperform the standard, qubit-based approach. Consequently, the post-distillation states are expected to provide high-fidelity entangled qubit pairs, proving beneficial for a range of applications involving metastable qubits.

Flag-based quantum error correction

For large-scale quantum computing, quantum error correction (QEC) becomes necessary to overcome hardware imperfections55,56,57,58. QEC is achieved by encoding logical qubits using multiple physical data qubits. With this redundancy, one can measure specific multi-body operators called stabilizers to identify errors in the physical qubits without interfering with logical qubits, thereby determining the necessary corrections. When the error rate of the physical qubits and their associated operations are below a specific threshold, logical qubits can achieve an error rate lower than the base error rate of the physical qubits. A QEC code that employs n physical qubits to encode k logical qubits with code distance d is denoted as a n, k, d code.

However, QEC is effective only if the quantum circuits that identify and correct errors do not proliferate those errors across physical qubits—a requirement called fault-tolerance (FT)59,60. Unfortunately, a straightforward approach using a single ancilla qubit (syndrome qubit) for stabilizer measurement generally fails to meet this FT standard. To address this, various strategies have been proposed, including the use of a block of ancilla qubits61,62,63.

More recently, a novel approach emerged to minimize the large number of ancilla qubits traditionally needed. By introducing one extra flag qubit in stabilizer measurements, one can track and contain an error that could have proliferated through the circuit64,65,66 with relatively low qubit overhead (only two auxiliary qubits are required). This concept has shown promising results in solid-state spin qubits67.

With ququarts, this flag-based QEC can be naturally implemented as illustrated in Fig. 6a. The “o”-qubit serves as the ancilla qubit while the “n”-qubit serves as the flag qubit. Two-qubit gates between a normal qubit and the “o”-qubit within a ququart can be performed directly if the qubit is encoded in the optical transition, or by swapping its nuclear spin encoding to the optical sector before and after the gate (see section “Inter-ququart gates”). With high-fidelity intra-ququart two-qubit gates between the ancilla and flag qubits, an increase in the error correction performance is possible. Additionally, using just a single auxiliary atom for fault-tolerant operations reduces the number of atoms and shuttling operations that are required to achieve a specified level of qubit connectivity, thereby reducing the hardware overhead.

Fig. 6: Flag-based QEC with ququarts.
figure 6

a Circuit to fault-tolerantly extract the stabilizer XXXX. Black lines are data qubits and yellow and red lines are syndrome and flag qubits encoded in a ququart. The CNOTs between syndrome and flag qubits are performed with intra-ququart gates, which should suppress the infidelity to the same level as single-qubit gates. b Simulated threshold for 5, 1, 3 and Steane 7, 1, 3 codes. Circles represent normal flag EC and triangles represent flag EC with ququart by assuming intra-ququart gates have perfect fidelity. The intersection of the gray line (physical error rate) and the curve representing logical error rate of a certain case gives the physical error rate, below which the QEC code outperforms the bare qubit. Using a ququart flag improves the threshold, and in practice, the threshold should lie in between the normal flag case and the ququart flag case.

To demonstrate the advantage of having ququarts in flag-based QEC, we calculated logical error rates with gates of an error rate p for two different scenarios in Fig. 6b: In the first scenario, the error rate between flag and syndrome qubits is also p, while in the second scenario, the error rate is zero. The latter case corresponds to the ququart implementation with an almost-perfect intra-ququart gate. In practice, the intra-ququart gates generally have higher fidelity than the gates between ququart and qubit, so the ququart flag performance should lie in the shaded region in Fig. 6b. We compared the performance using two types of QEC code: the five-qubit 5, 1, 3 code and Steane seven-qubit 7, 1, 3 code. Details about the simulation can be found in Methods. For both QEC codes, using a ququart flag increases the error threshold due to the higher-fidelity intra-ququart gates.

Four-qubit code error detection

Another useful direction towards fault-tolerant quantum computation is the quantum error detection code. One example of quantum error detection code is the smallest instance of surface codes, the four-qubit 4, 2, 2 code68. Unlike QEC codes that can correct errors on physical qubits, the four-qubit code can detect errors on a single qubit but is not able to correct the errors. The four-qubit code can act as a building block for large-scale fault-tolerant quantum computations63, and fault-tolerant operations on the four-qubit code have been demonstrated in several physical platforms69,70,71.

The four-qubit code is defined by the stabilizers:

$$\begin{array}{r}\begin{array}{ll}{S}_{X}\,=\,{X}_{1}{X}_{2}{X}_{3}{X}_{4},\\ {S}_{Z}\,=\,{Z}_{1}{Z}_{2}{Z}_{3}{Z}_{4}.\end{array}\end{array}$$
(2)

Here Xi and Zi are Pauli X and Z operators on the i-th physical qubit. The logical operators assigned to two logical qubits are:

$$\begin{array}{r}\begin{array}{ll}{X}_{L1}\,=\,{X}_{1}{X}_{3},\,{Z}_{L1}={Z}_{1}{Z}_{2},\\ {X}_{L2}\,=\,{X}_{1}{X}_{2},\,{Z}_{L2}={Z}_{1}{Z}_{3}.\end{array}\end{array}$$
(3)

The logical states are:

$$\begin{array}{r}\begin{array}{ll}{\left\vert 00\right\rangle }_{L}\,=\,\left(\left\vert 0000\right\rangle +\left\vert 1111\right\rangle \right)/\sqrt{2},\\ {\left\vert 01\right\rangle }_{L}\,=\,\left(\left\vert 0011\right\rangle +\left\vert 1100\right\rangle \right)/\sqrt{2},\\ {\left\vert 10\right\rangle }_{L}\,=\,\left(\left\vert 0101\right\rangle +\left\vert 1010\right\rangle \right)/\sqrt{2},\\ {\left\vert 11\right\rangle }_{L}\,=\,\left(\left\vert 0110\right\rangle +\left\vert 1001\right\rangle \right)/\sqrt{2}.\end{array}\end{array}$$
(4)

Specifically, one can fix the first logical qubit as a gauge and the code turns into a 4, 1, 2 subsystem code.

We encode the four-qubit code using the “o” and “n” qubits of two ququarts, as shown in Fig. 7a. To avoid correlated two-qubit errors from stabilizer measurement, an auxiliary ququart is implemented to function as the ququart flag discussed in the section “Flag-based quantum error correction” (see Fig. 7b). Therefore, the fault-tolerant operations on the four-qubit code can be demonstrated using only three individual atoms. We further highlight that the specific logical states:

$$\begin{array}{r}\left\vert 0\pm \right\rangle ={\left(\left\vert 00\right\rangle \pm \left\vert 11\right\rangle \right)}^{\otimes 2}/2,\end{array}$$
(5)

can be easily prepared with two ququarts by applying clock π/2-rotations between the \(\left\vert 00\right\rangle\) and \(\left\vert 11\right\rangle\) states. Additionally, the use of fewer atoms in the ququart protocol increases the effective connectivity such that the need for coherent transport is obviated.

Fig. 7: Four-qubit code encoded in two ququarts.
figure 7

a The “o”-qubit and “n”-qubit of two ququarts are used to encode the four-qubit code”. b Measurement of the stabilizer SX using an extra ancilla ququart. The extra ququart flag is implemented to fault-tolerantly measure the stabilizer without introducing logical errors into the state.

Interactive circuits

Realizing topological phases

One fascinating aspect of ququarts is that a natural measurement does not bisect the local Hilbert space unlike in a system made up of qubits (for a quantum circuit consisting of qubits, such a measurement operation would require introducing an extra ancilla qubit and applying a non-Clifford gate). The quantum channel for measuring \(\left\vert 00\right\rangle\) in a ququart is expressed as:

$$\begin{array}{ll}\rho \otimes \left\vert 0\right\rangle {\left\langle 0\right\vert }_{E}\,\mapsto\, {{\mathcal{P}}}_{0}\rho {{\mathcal{P}}}_{0}\otimes \left\vert 0\right\rangle {\left\langle 0\right\vert }_{E}+{{\mathcal{P}}}_{\bar{0}}\rho {{\mathcal{P}}}_{\bar{0}}\otimes \left\vert {\bar{0}}\right\rangle {\left\langle \bar{0}\right\vert }_{E}\\ {{\mathcal{P}}}_{0}=\left\vert 00\right\rangle \left\langle 00\right\vert \\ {{\mathcal{P}}}_{\bar{0}}=\left\vert 01\right\rangle \left\langle 01\right\vert +\left\vert 10\right\rangle \left\langle 10\right\vert +\left\vert 11\right\rangle \left\langle 11\right\vert ,\end{array}$$
(6)

where \({\left\vert 0\right\rangle }_{E}\) and \({\left\vert 1\right\rangle }_{E}\) are the states of a measurement apparatus. Using any intra-qubit unitary transformation U rotating \(\left\vert 00\right\rangle\) into \((\left\vert 10\right\rangle -\left\vert 01\right\rangle )/\sqrt{2}\), through this measurement one can distinguish spin-singlet (s = 0) and spin-triplet (s = 1) sectors of a given ququart. This leads to a new protocol to prepare interesting quantum many-body wavefunctions.

To illustrate our approach, consider a spin-1 chain model by Affleck, Kennedy, Lieb, and Tasaki (AKLT)72,73 defined by the following Hamiltonian:

$$\begin{array}{r}{H}_{{\rm{AKLT}}}=\sum\limits_{i}\left[({\overrightarrow{{\boldsymbol{S}}}}_{i}\cdot {\overrightarrow{{\boldsymbol{S}}}}_{i+1})+\frac{1}{3}{({\overrightarrow{{\boldsymbol{S}}}}_{i}\cdot {\overrightarrow{{\boldsymbol{S}}}}_{i+1})}^{2}\right],\end{array}$$
(7)

where \({\overrightarrow{{\boldsymbol{S}}}}_{i}=({S}_{i}^{x},{S}_{i}^{y},{S}_{i}^{z})\) is the spin-1 operator at site i. Its ground state is a canonical example of nontrivial symmetry protected topological (SPT) order, exhibiting several interesting properties74,75,76: (i) Non-local order parameter: For any arbitrary length ij, the expectation value of the following string of operators takes a finite value:

$${O}_{ij}^{\alpha }:= {S}_{i}^{\alpha }{e}^{i\pi \mathop{\sum\limits}\limits_{l = i+1}^{j-1}{S}_{l}^{\alpha }}{S}_{j}^{\alpha },\qquad \alpha =x,y,z.$$
(8)

The finite expectation value of a nonlocal operator \({O}_{ij}^{\alpha }\) implies that the state can be utilized as an entanglement resource for quantum computation77,78,79,80. (ii) Anomalous boundary modes: In the open boundary condition, effective spin-1/2 edge degrees of freedom exist at each edge albeit consisting of spin-1 in the microscopic model.

There are various protocols suggested to realize this state using qubits and local unitary gates. However, these schemes require a gate depth linearly scaling81,82,83,84,85,86,87 with the system size due to a finite correlation length of the AKLT state, which requires some exponential tail of unitary gates. As we will show, this can be circumvented by our novel approach.

A schematic diagram for our protocol is shown in Fig. 8a. First, we prepare a wavefunction where an “o”-qubit at the ith site and a “n”-qubit at the (i+1)th site form a singlet \(\frac{1}{\sqrt{2}}({\left\vert 0\right\rangle }_{i}^{{\rm{o}}}{\left\vert 1\right\rangle }_{i+1}^{{\rm{n}}}\,-\,{\left\vert 1\right\rangle }_{i}^{{\rm{o}}}{\left\vert 0\right\rangle }_{i+1}^{{\rm{n}}})\). Second, we project each ququart onto its spin-triplet (S = 1) manifold via measurement. If all ququarts are properly projected, they immediately form the AKLT state, which is the ground state of Eq. (7). However, each ququart Hilbert space decomposes into spin-singlet and triplet sectors, and the probability of getting a spin-0 measurement outcome is 25%. Thus, it is natural to ask whether we can get a whole chain of the AKLT state instead of a set of small AKLT islands.

Fig. 8: AKLT state preparation protocol.
figure 8

a Within each ququart, there are two qubits (optical and nuclear). Starting from a chain of singlets between optical and nuclear qubits across different sites, we project each ququart onto the spin-1 subspace. The projected wavefunction is the exact ground state of the AKLT Hamiltonian. b If the i-th ququart is projected onto the spin-0 subspace instead, the “o”-qubit of the (i − 1)-th ququart and “n”-qubit of the (i + 1)-th ququart automatically forms a maximally entangled singlet. c The quantum circuit of the actual experimental procedure consists of three steps. (i) Initialize the system into the product state of a particular pattern, which is followed by the intra-ququart SWAP and inter-ququart CNOT to create a chain of singlets. (ii) Apply individual qubit rotations and intra-ququart gates to rotate \(\left\vert 01\right\rangle -\left\vert 10\right\rangle\) into \(\left\vert 00\right\rangle\), measure \(\left\vert 00\right\rangle\), and then apply the reverse operation. This sequence effectively performs singlet/triplet projections. (iii) After the measurement, ququarts projected onto the spin-1 subspace automatically form the AKLT state, while spin-0 ququarts completely disentangle. One can rearrange neutral atoms to throw away spin-0 ququarts.

The solution to this problem is straightforward: by discarding neutral atoms that are projected onto spin-singlets, we can ensure that the remaining ququarts will form a single AKLT state. To elucidate this idea, let us examine the scenario illustrated in Fig. 8b, where we label qubits as 1, 2, 3, and 4 in a cardinal manner. Initially, the qubits (1, 2) and (3, 4) are in singlet states, resulting in a zero total spin. Now, we project the pair (2, 3) onto a singlet. Given that the initial total spin is zero and that the conservation of total spin is a requisite in each projected component, it logically follows that the pair (1, 4) must also be in a spin-singlet state. As a result, while ququarts projected onto spin-singlets become disentangled from the rest of the system, those projected onto spin-triplets contribute to forming a single AKLT state. Therefore, our approach is distinguished from other proposals, such as ref. 88.

Using experimental controls discussed in the previous section, the protocol consisting of three parts can be directly implemented as shown in Fig. 8c:

  • Inter-ququart Singlet Formation: As our inter-ququart operations are limited among optical qubits, we have to introduce SWAP operations. Using intra-ququart SWAP and inter-ququart CNOT operations in a parallel manner, this step can be done within five steps.

  • Triplet Projection: To perform this projection, we have to conjugate our \(\left\vert 00\right\rangle\) measurement by the basis rotation using single-qubit rotations and intra-ququart CNOT gates.

  • Rearrangement: Conditioned on the measurement outcomes, we can remove atoms projected onto spin-singlet states either virtually (through post-processing) or physically (through the optical tweezer technique7).

The size of this resultant AKLT state is approximately 3/4 of the original system, and most importantly, there is no exponential overhead in this protocol.

Although the proposed method is inherently stochastic, we can also create an AKLT state of a specific size through an additional step. The key idea is that any two-qubit state can be projected into a singlet, up to a Pauli operator, by Bell state measurement, and this Pauli operator can be corrected by a local unitary that depends on the measurement outcome. In achieving a target size, there are two approaches, bottom-up and top-down. In the bottom-up approach, we use a fusion protocol to merge two different AKLT segments. In the top-down approach, we use a fission protocol to remove sites from a single AKLT segment. The details of fusion and fission protocols are elaborated in Methods.

Therefore, our protocol combines local unitary gates, measurements, and feedback to create an AKLT state in a constant depth, offering a novel experimental route to realize exotic topological systems in quantum simulator platforms. We note that the proposed method can be readily extended for various one and two-dimensional fixed-point SPT states where symmetry actions on bulk degrees of freedom can be pushed to fractional degrees of freedom at its boundaries89,90,91,92.

Interestingly, the illustrated protocol can be considered as a particular experimental implementation of a so-called parton construction, which is heavily utilized in the theoretical study of quantum many-body physics. In this construction, an exotic quantum state is created by starting from a simple wavefunction consisting of fractional degrees of freedom and then projecting it onto physical degrees of freedom93,94,95,96,97. Therefore, our approach paves the road to implement this parton construction in experiments.

Adaptive dynamics: absorbing transitions

The capacity to perform mid-circuit measurements and feedback operations based on the outcomes in ququarts offers experimental access to adaptive dynamics, where the system evolves under random local unitaries, measurement, and local feedback operations based on measurement outcomes. In recent years, the entanglement structure of such adaptive dynamics has been theoretically explored where the measurement probability p of each qubit for each cycle of the circuit has been the main tuning knob. In particular, two interesting transitions have been theoretically discussed: the volume to area-law entanglement transition across a critical measurement rate98,99, and directed percolation or steering transitions between two distinct area law phases across another critical tuning parameter100,101,102.

Our ququart encoding, or more generically higher-dimensional encodings offer a unique opportunity to explore these phenomena. In fact, the qudit single-state QND readout discussed above has been utilized in recent theoretical proposals for studying directed percolation transitions100. Our single-state QND readout of \(\left\vert 00\right\rangle\) makes it an “absorbing state”: A ququart that is measured to be in this state becomes “inactive” and does not participate in subsequent unitary operations. Conversely, if the ququart is measured to be not in \(\left\vert 00\right\rangle\), then it remains “active” and its Hilbert space dimension reduces from four to three. Accordingly, above a certain measurement rate, the system transitions into a many-body absorbing state whose universality class is given as a directed percolation transition.

We now outline an exemplary circuit to study measurement-induced phase transitions (MIPTs) with qudits as introduced in ref. 100. We perform a \(\left\vert 00\right\rangle\)-state measurement of all ququarts in each cycle. After the first measurement layer, the active and inactive sectors remain separated. The knob that we will use to re-couple the sectors and introduce phase transitions are “reset” operations in which select ququarts are re-initialized to \(\left\vert 00\right\rangle\), which can be achieved via local optical pumping. Note that single-ququart dissipative operations can be performed without deleterious effects on the other ququarts by trapping the target ququart(s) in tweezers of a different clock-magic wavelength than the other ququarts for which the probe/reset transition is sufficiently light-shifted from that of the nominal tweezers. Mid-circuit readout has already been demonstrated via this technique36. The probability p of performing such a reset operation on each ququart in each cycle is the parameter that allows us to traverse the phase diagram.

This architecture presents a relatively simple approach to studying MIPTs, specifically directed percolation transitions. Since it is known to be very challenging to study entanglement transitions between volume and area law phases in large systems due to the exponential post-selection problem98,99, the study of percolation transitions between area law phases appears to be a better target for large-scale quantum hardware100,101,102. Hence, a concrete and feasible route towards this realization constitutes an important development for interactive quantum circuits.

Discussion

We have presented a toolbox for encoding two qubits within the four-level structure of alkaline earth-like atom isotopes with nuclear spin-1/2 like 171Yb. We focused on the application of this ququart encoding to entanglement distillation and quantum error correction. We have also discussed how the higher-dimensional encoding offers new opportunities for interactive circuits to prepare topological phases and study measurement-induced phase transitions. This ququart architecture is a natural extension of the ‘omg’ architecture11,15,103 in which all pairs of states within the four-level system are used to encode qubits with various functionalities. We believe the use of ququarts does not require further capabilities than the ‘omg’ scheme yet offers a significant hardware advantage in terms of atom count and effective connectivity as well as new opportunities. We believe that the performance of our ququart operations can potentially match those of qubit-based operations, and we note that many of our required operations are also required in the ‘omg’ architecture. Additionally, we anticipate that single-atom gates will continue to outperform two-atom gates, and thus larger code spaces can offer improved circuit performance. We note that while the use of the optical qubit is perhaps the largest challenge in our protocol, it could be possible to instead use larger nuclear spin manifolds in, e.g., 173Yb and 87Sr to realize a similar multi-qubit architecture.

Alkaline earth-like atoms without nuclear spin may still provide access to our ququart encoding. For instance, we could replace the nuclear spin-1/2 degree of freedom with two harmonic motional states14. Motional ground state preparation via Raman sideband cooling11,34 or optically-resolved sideband cooling techniques104,105 including erasure cooling14 have provided access to temperatures for which this encoding is realistic. Indeed, there is at least one scenario in which the motional encoding may offer an advantage: A crucial capability that is proposed in this work is the inter-ququart gate that performs a CZ gate between the optical qubit (“o”) sector of each ququart without affecting the nuclear qubit ("n”) sector. If we instead encode the second qubit in the motional sector and do not have nuclear spin, then this inter-ququart gate between “o”-sectors would be given for free with a single-tone Rydberg excitation. In other words, the standard Rydberg-mediated gate is already agnostic to the motional state in the low temperature regime.

Methods

Two-ququart Rydberg-based gates

We propose two flavors of inter-ququart gates using the single-photon Rydberg coupling from the 3P0 nuclear spin states. Both gate protocols extend that detailed in ref. 47 to the two-ququart computational space. Operating on the space of states \(\{\left\vert 00\right\rangle \otimes \left\vert 00\right\rangle ,\,\left\vert 00\right\rangle \otimes \left\vert 01\right\rangle ,\,\left\vert 00\right\rangle \otimes \left\vert 10\right\rangle ,\,\ldots ,\left\vert 11\right\rangle \otimes \left\vert 11\right\rangle \}\), the first is a CCCZ gate that applies a phase shift φ to all states for which exactly one atom is in the \(\left\vert 11\right\rangle\) ququart state, a different phase shift \({\varphi }^{{\prime} }\) to the \(\left\vert 11\right\rangle \otimes \left\vert 11\right\rangle\) state such that \(2\varphi -\pi ={\varphi }^{{\prime} }\), and zero phase shift to the remaining states. The second gate is a CZ gate between only the “o” sectors of the two ququarts, applying φ to any states of the forms \(\left\vert 1a\right\rangle \otimes \left\vert 0b\right\rangle\) or \(\left\vert 0a\right\rangle \otimes \left\vert 1b\right\rangle\), \({\varphi }^{{\prime} }\) to any states of the form \(\left\vert 1a\right\rangle \otimes \left\vert 1b\right\rangle\), and zero phase shift to the remaining states.

The CCCZ gate has the simpler of the two implementations, requiring a drive on only a single transition from the 3P0 mF = +1/2 clock state to the n3S1 F = 3/2, mF = +3/2 (n = 59, for example) Rydberg state (see Fig. 3a). The protocol itself has been experimentally realized using this transition in ref. 33; we only analyze its effects on the total ququart space. The analysis of this gate is straightforward through numerical simulation (see below).

On the other hand, the CZ gate requires the applied phase shifts to be fully agnostic to the “n” sectors of both ququarts, for which the pulse sequence must then be duplicated with identical detuning and power on the transition between the 3P0 mF = −1/2 and n3S1 mF = −3/2 states (Fig. 3b). This second configuration also requires that atoms in states of different mF in the n3S1 manifold experience an energy shift that is similar to that for states of identical mF—a configuration that has not yet been explicitly studied to our knowledge.

In the sections that follow, we perform numerical simulations of the proposed ququart CZ and CCCZ protocols. In our calculations, we neglect effects from laser phase noise and Doppler shifts due to finite temperature since we seek to only highlight challenges arising from the higher-dimensional encoding. For the ququart CZ gate, we examine interactions between Rydberg states of differing mF values and use the results in our simulations.

Rydberg interactions for multiple Zeeman states

Determination of the σz-type interaction strength between Rydberg states of differing mF values amounts to a calculation of the C6 van der Waals interaction potential coefficient. We base our calculations on the perturbative treatment of the problem in ref. 106 for I = 0 bosonic species, which gives the value of the C6 coefficient for different pair states as the eigenvalues of a \({{\mathcal{C}}}_{6}\) matrix whose elements are calculated as:

$${({{\mathcal{C}}}_{6})}_{ij}=-\sum\limits_{p}\left[\frac{| {{\mathcal{R}}}_{11}({s}_{0},{s}_{p}){| }^{2}}{{E}_{0}-{E}_{p}}{{\mathcal{D}}}_{11}({s}_{i},{s}_{p},\hat{\rho }){{\mathcal{D}}}_{11}({s}_{p},{s}_{j},\hat{\rho })\right].$$
(9)

This sum runs over p indexing pair states of the form sp = (n, α, mJ) where n and mJ are the principal and total electronic angular momentum projection quantum numbers and, for brevity, α is a vector containing all other relevant total-spin quantum numbers. Ep is the energy of state sp, and the subscript 0 denotes the initial eigenstate of the unperturbed Hamiltonian. \(\hat{\rho }\) is a unit vector \(\hat{\rho }=(\theta ,\varphi )\) describing the angles in spherical coordinates between the two atoms relative to the quantization axis.

The functions \({{\mathcal{R}}}_{11}\) and \({{\mathcal{D}}}_{11}\) are the appropriate radial and angular parts of the matrix elements of the electric dipole operator:

$$\begin{array}{ll}{{\mathcal{R}}}_{{k}_{1},{k}_{2}}({s}^{{\prime} },s)\\ \qquad\approx \left(\mathop{\int}\nolimits_{0}^{\infty }{\rm{d}}{r}_{1}\,{R}_{{n}_{1}^{{\prime} },{L}_{1}^{{\prime} }}({r}_{1}){R}_{{n}_{1},{L}_{1}}({r}_{1}){r}_{1}^{2+{k}_{1}}\right)\\ \qquad\qquad\times \left(\mathop{\int}\nolimits_{0}^{\infty}{\rm{d}}{r}_{2}\,{R}_{{n}_{2}^{{\prime} },{L}_{2}^{{\prime} }}({r}_{2}){R}_{{n}_{2},{L}_{2}}({r}_{2}){r}_{2}^{2+{k}_{2}}\right)\end{array}$$
(10)
$$\begin{array}{ll}{{\mathcal{D}}}_{{k}_{1},{k}_{2}}({s}^{{\prime} },s,{\hat{\rho}})\\ ={(-1)}^{{k}_{2}}{\left[4\pi \frac{(2{k}_{1}+2{k}_{2})!}{(2{k}_{1})!(2{k}_{2})!}\frac{(2{L}_{1}+1)(2{L}_{2}+1)}{(2{k}_{1}+2{k}_{2}+1)}\right]}^{1/2}\\ \quad\times \,{\left[(2{J}_{1}+1)(2{J}_{2}+1)\right]}^{1/2}{C}_{{L}_{1}0,{k}_{1}0}^{{L}_{1}^{{\prime} }0}{C}_{{L}_{2}0,{k}_{2}0}^{{L}_{2}^{{\prime} }0}\\ \quad\times \left\{\begin{array}{l}{J}_{1}\qquad{k}_{1}\qquad{J}_{1}^{{\prime} }\\ {L}_{1}^{{\prime} }\qquad{S}\qquad{L}_{1}\end{array}\right\}\left\{\begin{array}{ll}{J}_{2}\qquad{k}_{2}\qquad{J}_{2}^{{\prime} }\\ {L}_{2}^{{\prime} }\qquad{S}\qquad{L}_{2}\end{array}\right\}\\ \quad\times \mathop{\sum}\limits_{q=-({k}_{1}+{k}_{2})}^{{k}_{1}+{k}_{2}}\mathop{\sum}\limits_{{q}_{1}=-{k}_{1}}^{{k}_{1}}\mathop{\sum}\limits_{{q}_{2}=-{k}_{2}}^{{k}_{2}}\\\quad\left[{C}_{{k}_{1}{q}_{1},{k}_{2}{q}_{2}}^{({k}_{1}+{k}_{2})q}{C}_{{J}_{1}{m}_{J1},{k}_{1}{q}_{1}}^{{J}_{1}{m}_{J1}}{C}_{{J}_{2}{m}_{J2},{k}_{2}{q}_{2}}^{{J}_{2}{m}_{J2}}{Y}_{{k}_{1}+{k}_{2},q}({\hat{\rho }})\right]\end{array}$$
(11)

where Rn,(r) is a Hydrogen radial wavefunction, \({C}_{{J}_{1},{m}_{1};{J}_{2},{m}_{2}}^{{J}_{3},{m}_{3}}\) is the Clebsch-Gordan coefficient 〈J1, m1; J2, m2J3, m3〉, and Y,m is a spherical harmonic. At the time of writing, the Rydberg states of 171Yb are not yet well-studied, and we lack sufficient quantum defect data for a proper calculation of \({{\mathcal{R}}}_{11}\). Given the results of refs. 12,33, however, we assume a nominal Rydberg interaction following \({C}_{6}^{{\prime} }=5\,{\rm{THz}}\,\mu {{\rm{m}}}^{6}\) for n = 74, scaled down to the n = 59, 3S1F = 3/2 Rydberg states, and focus on only the angular factors in (9). Thus we reduce the calculation to:

$${({\tilde{{\mathcal{C}}}}_{6})}_{ij}=-\sum\limits_{p}\left[{{\mathcal{D}}}_{11}({s}_{i},{s}_{p},\hat{\rho }){{\mathcal{D}}}_{11}({s}_{p},{s}_{j},\hat{\rho })\right]$$
(12)

in order to show only that the expected variation in the size of the Rydberg interaction within the targeted manifold would not be disruptive to the implementation of the CZ gate.

We therefore rewrite Eq. (11) by way of the Wigner-Eckart theorem as:

$$\begin{array}{lll}{{\mathcal{D}}}_{{k}_{1},{k}_{2}}\to {\tilde{{\mathcal{D}}}}_{{k}_{1},{k}_{2}}({s}^{{\prime} },s,{\hat{\rho}})\\ ={(-1)}^{-{F}_{1}+{k}_{1}-{m}_{F1}^{{\prime} }-{F}_{2}+{k}_{2}-{m}_{F2}^{{\prime} }+{J}_{1}^{{\prime} }+{J}_{2}^{{\prime} }-{L}_{1}-{L}_{2}+2I+2S+{k}_{1}+{k}_{2}}\\ \quad\times \,{(-1)}^{{k}_{2}}{\left[\frac{4\pi }{(2{k}_{1}+2{k}_{2}+1)}\frac{(2{k}_{1}+2{k}_{2})!}{(2{k}_{1})!(2{k}_{2})!}\right]}^{1/2}\\ \quad\times \,\left[(2{F}_{1}^{{\prime} }+1)(2{F}_{2}^{{\prime} }+1)(2{J}_{1}^{{\prime} }+1)(2{J}_{2}^{{\prime} }+1)(2{L}_{1}^{{\prime} }+1)(2{L}_{2}^{{\prime} }+1)\right.\\ \quad{\left.\times (2{F}_{1}+1)(2{F}_{2}+1)(2{J}_{1}+1)(2{J}_{2}+1)(2{L}_{1}+1)(2{L}_{2}+1)\right]}^{1/2}\\ \quad\times \left\{\begin{array}{ccc}{J}_{1}^{{\prime} }&{F}_{1}^{{\prime} }&I\\ {F}_{1}&{J}_{1}&{k}_{1}\end{array}\right\}\left\{\begin{array}{ccc}{J}_{2}^{{\prime} }&{F}_{2}^{{\prime} }&I\\ {F}_{2}&{J}_{2}&{k}_{2}\end{array}\right\}\left\{\begin{array}{ccc}{L}_{1}^{{\prime} }&{J}_{1}^{{\prime} }&S\\ {J}_{1}&{L}_{1}&{k}_{1}\end{array}\right\}\\\quad\left\{\begin{array}{ccc}{L}_{2}^{{\prime} }&{J}_{1}^{{\prime} }&S\\ {J}_{2}&{L}_{2}&{k}_{2}\end{array}\right\}\left(\begin{array}{rcl}{L}_{1}^{{\prime} }&{k}_{1}&{L}_{1}\\ 0&0&0\end{array}\right)\left(\begin{array}{rcl}{L}_{2}^{{\prime} }&{k}_{2}&{L}_{2}\\ 0&0&0\end{array}\right)\\ \quad\times \mathop{\sum\limits}\limits_{q=-({k}_{1}+{k}_{2})}^{{k}_{1}+{k}_{2}}\mathop{\sum\limits}\limits_{{q}_{1}=-{k}_{1}}^{{k}_{1}}\mathop{\sum\limits}\limits_{{q}_{2}=-{k}_{2}}^{{k}_{2}}\left(\begin{array}{rcl}{F}_{1}^{{\prime} }&{k}_{1}&{F}_{1}\\ -{m}_{F1}^{{\prime} }&{q}_{1}&{m}_{F1}\end{array}\right)\\\qquad\left(\begin{array}{rcl}{F}_{2}^{{\prime} }&{k}_{2}&{F}_{2}\\ -{m}_{F2}^{{\prime} }&{q}_{2}&{m}_{F2}\end{array}\right){C}_{{k}_{1}{q}_{1},{k}_{2}{q}_{2}}^{({k}_{1}+{k}_{2})q}{Y}_{({k}_{1}+{k}_{2})q}(\hat{\rho })\end{array}$$
(13)

using the particular choices \({S}_{1}={S}_{2}={S}_{1}^{{\prime} }={S}_{2}^{{\prime} }\equiv S=1\) and \({I}_{1}={I}_{2}={I}_{1}^{{\prime} }={I}_{2}^{{\prime} }\equiv I=1/2\), which are motivated below. Following the diagonalization of Eq. (12), we calculate \({\tilde{C}}_{6}\) values for all possible pair states in a chosen basis. These values are dimensionless and act only as a weighting factor to estimate the strength of the Rydberg interaction between a given pair of states in the n3S1 manifold. Specifically, the \({\tilde{C}}_{6}\) value for the k-th pair state is calculated as:

$${\tilde{C}}_{6}^{(k)}=\sum\limits_{j}\left\langle k| j\right\rangle \left\langle j\right\vert {\tilde{C}}_{6}\left\vert j\right\rangle \left\langle j| k\right\rangle$$
(14)

where \(\left\vert j\right\rangle\) is the j-th eigenvector of \(\tilde{{\mathcal{C}}_{6}}\). The final C6 value for the k-th pair state used in numerical simulations (see below) is then \({C}_{6}^{(k)}=({C}_{6}^{{\prime} }/\mathop{\max }\limits_{k}| {\tilde{C}}_{6}^{(k)}| )\times {\tilde{C}}_{6}^{(k)}\).

Although we only consider these angular weighting factors for interactions between states within the targeted Rydberg manifold, the calculation as a whole still depends critically on effects from other, nearby Rydberg states whose contributions to Eq. (9) eventually vanish as the energy difference factors in the denominator become large and the overlaps between radial wavefunctions become small. Lacking both in Eq. (12), we are then forced to decide independently on a particular basis over which the sum is carried out. From the analysis in previous work103, we also restrict the basis to states for which S = 1 and F = I + J. Thus the chosen basis comprises all hyperfine states associated with the manifolds {3S1F = 3/2, 3P0F = 1/2, 3P1F = 3/2, 3P2F = 5/2, 3D1F = 3/2, … } which we choose to cut off at 3D1F = 3/2 (for a total of 20 states) as an estimated threshold for where contributions to Eq. (9) would mostly vanish in an ideal calculation. Note that Eq. (12) does not depend on the principal quantum number n because we have discarded all energy and radial factors. The results of the full calculation for the targeted 3S1F = 3/2 manifold are shown in Table 1.

Table 1 \({C}_{6}/{C}_{6}^{{\prime} }\) weighting factors between 3S1F = 3/2 hyperfine states calculated from Eq. (12), normalized to their largest-magnitude value

Numerical simulations of Rydberg gates

We examine both the CCCZ and CZ ququart gate protocols by numerically simulating the ground-clock-Rydberg state manifold using the methods from previous work103 under the application of the pulse sequence described in ref. 47. The actions and fidelities of the gate protocols were evaluated by simulating the appropriate pulse sequence with the two-ququart system initialized in each computational basis state. The simulations were performed for a typical Rabi frequency ΩRyd = 2π × 3 MHz on the targeted Rydberg transitions (with laser detuning determined by the Rabi frequency; Δ/ΩRyd ≈ 0.375 for both protocols) and nominal interaction strength 2 GHz in the presence of a magnetic field B = 120 G. The authors of ref. 47 cite finite atom temperature and off-resonant scattering as major limitations to the fidelity of their experimental realization. The CZ and CCCZ protocols presented here inherit these limitations; however to examine effects arising purely due to the extension of the original protocol to the ququart space, our simulations are conducted with effects from neither of these sources, nor from e.g., laser phase noise. For both CZ and CCCZ, all excitation pulses were performed for horizontally polarized light with angle of incidence perpendicular to the quantization axis. This adds extra couplings to those shown in Fig. 3; namely \(\left\vert 11\right\rangle {\leftrightarrow }^{3}{{\rm{S}}}_{1}\,\left\vert {m}_{F}=-1/2\right\rangle\) for both CCCZ and CZ, and \(\left\vert 10\right\rangle {\leftrightarrow }^{3}{{\rm{S}}}_{1}\,\left\vert {m}_{F}=+1/2\right\rangle\) for CZ. Both are far off resonance, detuned by approximately twice the Zeeman splitting in the Rydberg manifold.

Notably, the forms of both gates are defined in terms of two phases φ and \({\varphi }^{{\prime} }=2\varphi -\pi\) where φ can in general be any real number modulo 2π, which leaves the “ideal” form of the gate (in the case of perfect fidelity) parameterized by φ. We therefore calculate the fidelity of our simulated gates according to:

$${{\mathcal{F}}}_{{\rm{CCCZ}}}=\mathop{\max }\limits_{\varphi }\frac{1}{16}| {\rm{tr}}\,\left({{\rm{CCCZ}}}^{\dagger }(\varphi )\,{{\rm{CCCZ}}}^{{\prime} }\right)|$$
(15)
$${{\mathcal{F}}}_{{\rm{CZ}}}=\mathop{\max }\limits_{\varphi }\frac{1}{16}| {\rm{tr}}\,\left({{\rm{CZ}}}^{\dagger }(\varphi )\,{{\rm{CZ}}}^{{\prime} }\right)|$$
(16)

where CCCZ(φ) and CZ(φ) are the ideal realizations of the gates, \({{\rm{CCCZ}}}^{{\prime} }\) and \({{\rm{CZ}}}^{{\prime} }\) are the forms of the gates realized from simulation, and we normalize by the identity operator on the total (4 × 4)-state two-ququart basis. It was assumed that the two ground states would not have significant coupling to any other nearby states from the Rydberg excitation pulses, and it was calculated that any associated light shifts from dipole-allowed transitions could be neglected at the ~10−5 Hz level. Under the conditions identified above, we find \({{\mathcal{F}}}_{{\rm{CCCZ}}}\,\gtrsim\, 0.999\) and \({{\mathcal{F}}}_{{\rm{CZ}}}\,\gtrsim\, 0.999\). We do not identify additional limitations in \({{\mathcal{F}}}_{{\rm{CCCZ}}}\) associated with the ququart encoding; however, \({{\mathcal{F}}}_{{\rm{CZ}}}\) depends on the assumed Rydberg interactions, as we now describe.

Although the CCCZ protocol merely extends that identified in ref. 47 to include effects on additional states in the ququart encoding scheme, the CZ protocol requires consideration of the magnitude of the Rydberg interaction between different states in the n3S1 manifold. Specifically, we consider effects from non-uniform energy shifts on the \(\vert {m}_{F}^{(1)},{m}_{F}^{(2)} \rangle \in \{\vert -3/2,-3/2\rangle ,\vert +3/2,+3/2\rangle ,\vert +3/2,-3/2\rangle ,\vert -3/2,+3/2\rangle \}\) two-ququart Rydberg states. We parameterize their C6 values by η as:

$${C}_{6}^{(-3/2,+3/2)}\to \eta {C}_{6}^{{\prime} }$$
(17)
$${C}_{6}^{(+3/2,-3/2)}\to \eta {C}_{6}^{{\prime} }$$
(18)
$${C}_{6}^{(+3/2,+3/2)}\to \,{C}_{6}^{{\prime} }$$
(19)
$${C}_{6}^{(-3/2,-3/2)}\to \,{C}_{6}^{{\prime} }$$
(20)

where η = 1 corresponds to perfect uniformity, and η = 0.989 to the result of the calculations from the previous section. Here we assume that the size of the shifts for the \(\left\vert \pm 3/2,\pm 3/2\right\rangle\) states are equal due to symmetry, and neglect parameterization of all other pairs of Rydberg states due to selectivity in the applied pulses’ detunings and polarizations. We vary η from − 1 to + 1 as well as the overall magnitude of the Rydberg shift. η affects the accumulation of phase between computational states due to off-resonant excitation. This phase shift also varies with the array spacing, and the chosen range of shift magnitudes corresponds to spacings from ≈2.4 μm to ≈ 6.8 μm. We note that this issue can be avoided through the use of purely circular polarizations (rather than linear polarization perpendicular to the magnetic field) such that only the transitions shown in Fig. 3b are driven. We show the simulated phase accrual of all two-ququart states for η = 0.989 in Fig. 9a, and gate infidelity as a function of η and overall shift magnitude in Fig. 9b. In particular, we see that the gate fidelity is more robust to effects from non-uniform interactions for larger shift sizes. For expected interaction shifts of ~GHz, we can tolerate an interaction disparity of 1 − η 0.95 between the two pair-states to still obtain a gate fidelity of \({\mathcal{F}}\approx 0.999\).

Fig. 9: Inter-ququart CZ gate performance.
figure 9

a Accrued phases φ for all two-ququart basis states in units of π as a function of Δ/Ω for η = 0.989, corresponding to the weighting values shown in Table 1, and overall Rydberg energy shift 2 GHz. Lines are colored by the number of 1's in the “o” positions of both atoms' ququart bitstrings—0 (purple), 1 (blue), and 2 (orange), giving distinct accruals φ0, φ1, and φ2, respectively. The dot-dash patterns of each of the lines correspond to their associated states' two-ququart bitstrings. The CZ gate protocol from ref. 47 is implemented for 2φ1 − π = φ2 (red points). b CZ gate infidelities as a function of η [−1, 1], parameterizing the uniformity of the Rydberg interaction between the various states of the 59 3S1 manifold. The lines of different opacities show the gate infidelity for varied overall energy shift from 30 GHz (most opaque) to 50 MHz (least opaque), with equal logarithmic spacing. The condition used in (a) is shown in red. Note that the authors of ref. 33 estimate their shift to be of size ≈26 GHz.

Simulating entanglement distillation and flag-based FTQEC

In section “Applications”, we proposed several possible applications related to the ququart architecture and simulated how the behavior gets improved when using ququarts. Here we discuss several details about the simulations, including error models for gates, circuit-level error models for QEC simulations, and the stabilizer lists and logical operators for the QEC code we used to perform simulations.

Entanglement distillation

Figure 5a shows the circuit of entanglement distillation, with the entanglement generation presented as two wavy lines. We simulate the pre- and post-distillation entanglement infidelity and yield of the circuit in Fig. 5a, whose result is shown in Figs. 5b and 10. Here we fix the measurement error rate to 1% and the intra-ququart gate infidelity to 0.1%, and vary the error rate in the two different error models to change the pre-distillation entanglement infidelity.

Fig. 10: The yield of imperfect distillation with respect to different values entanglement generation infidelity for different error models.
figure 10

The initial deviation from 0.5 is due to the assumed 1% measurement error.

Flag-based FTQEC

Figure 6b simulates how the threshold for certain codes under flag-based QEC can increase by replacing the ancilla and flag qubits with one ququart. We performed a circuit-level simulation, using the Pauli frame to track how single-qubit faults propagate through two-qubit CNOT gates during the whole circuit. The faults on physical qubits/ququarts are generated via the depolarization channel: During the state preparation each physical qubit has a probability p to be replaced with a maximally mixed state, but post-selection by measuring the stabilizers ensures that the state preparation process is fault-tolerant. The measurement has probability p to be faulty, and after each inter-qubit (ququart) gate the state is replaced with a totally mixed two-qubit state with probability p. To show the improvement from using ququarts and due to the limitations of the Pauli frame (only uncorrelated Pauli errors on each qubit can be tracked), we treat intra-ququart CNOT gates as perfect, but existing single-qubit faults can still propagate through intra-ququart CNOT gates. After one round of circuit-level error correction, we perform another round of perfect decoding. The circuit-level decoding is denoted as successful if, after the perfect decoding, the logical state gives no logical errors.

Using the model described above, we simulate the logical error rate of 5, 1, 3 and Steane 7, 1, 3 codes using flag-based error correction scheme under different values of p. For convenience, we list out the stabilizers and logical operators for the 5, 1, 3 and 7, 1, 3 codes respectively:

5, 1, 3:

$$\begin{array}{r}\begin{array}{ll}{S}_{1}\,=\,{X}_{1}{Z}_{2}{Z}_{3}{X}_{4},\\ {S}_{2}\,=\,{X}_{2}{Z}_{3}{Z}_{4}{X}_{5},\\ {S}_{3}\,=\,{X}_{1}{X}_{3}{Z}_{4}{Z}_{5},\\ {S}_{4}\,=\,{Z}_{1}{X}_{2}{X}_{4}{Z}_{5},\\ {X}_{L}\,=\,{X}_{1}{X}_{2}{X}_{3}{X}_{4}{X}_{5},\\ {Z}_{L}\,=\,{Z}_{1}{Z}_{2}{Z}_{3}{Z}_{4}{Z}_{5}.\end{array}\end{array}$$
(21)

7, 1, 3:

$$\begin{array}{r}\begin{array}{ll}{S}_{1}\,=\,{X}_{1}{X}_{2}{X}_{3}{X}_{4},\\ {S}_{2}\,=\,{X}_{2}{X}_{3}{X}_{5}{X}_{6},\\ {S}_{3}\,=\,{X}_{3}{X}_{4}{X}_{6}{X}_{7},\\ {S}_{4}\,=\,{Z}_{1}{Z}_{2}{Z}_{3}{Z}_{4},\\ {S}_{5}\,=\,{Z}_{2}{Z}_{3}{Z}_{5}{Z}_{6},\\ {S}_{6}\,=\,{Z}_{3}{Z}_{4}{Z}_{6}{Z}_{7},\\ {X}_{L}\,=\,{X}_{1}{X}_{2}{X}_{3}{X}_{4}{X}_{5}{X}_{6}{X}_{7},\\ {Z}_{L}\,=\,{Z}_{1}{Z}_{2}{Z}_{3}{Z}_{4}{Z}_{5}{Z}_{6}{Z}_{7}.\end{array}\end{array}$$
(22)

The ququart flag shows an improved threshold, making the logical qubit more robust against the physical error rate p as shown in Fig. 6.

Fusion and fission protocol

In the main text, we discussed a method to realize an AKLT state. Starting from L ququarts, on average we would obtain an AKLT state of length 3L/4 with a standard deviation of \(\sqrt{3L}/4\) from the Bernoulli distribution. Due to the stochastic nature of the proposed protocol, an additional step is required to achieve a specific length. There are two different approaches, bottom-up and top-down.

In the bottom-up approach, we employ a fusion process. Consider two AKLT segments C1 and C2 of lengths l1 and l2, respectively, prepared from initial spin-1/2 chains with edge states (L1, R1) and (L2, R2). These segments would form a single AKLT chain if the edge states R1 and L2 were in a singlet state before the triplet projection. This can be achieved in two steps, as illustrated in Fig. 11a. First, we perform a singlet projection on (R1, L2). Second, since this singlet projection affects triplet conditions for the two ququarts to which R1 and L2 belong, we have to perform the triplet projection measurement again for these two ququarts. This protocol properly fuses two AKLT segments into one since this singlet projection does not affect the short-range entangled structure of other ququarts. The resulting state becomes a single AKLT chain with length L = l1 + l2m, where m is the number of atoms projected onto singlet states. Note that P(m = 0) = 9/16, P(m = 1) = 6/16, and P(m = 2) = 1/16.

Fig. 11: Fusion and fission protocols.
figure 11

a We perform an inter-ququart Bell-basis measurement between the nuclear qubit for C1 and optical qubit for C2, which is followed by measurements on two ququarts that project each ququart on a singlet or triplet. Finally, we perform local unitary operations based on the Bell-basis measurement outcome i (and the rearrangement based on the triplet measurement outcomes). b We perform a Bell-basis measurement on the last ququart. This will disentangle the last ququart from the others, leaving the remaining L − 1 ququarts in an AKLT state. This AKLT state is as if the initial right boundary state was \({O}_{i}\left\vert R\right\rangle\), where Oi is X, Y, or Z depending on the measurement outcome.

One way to realize the singlet projection in (R1, L2) is by performing an inter-ququart Bell measurement on (R1, L2) and applying an on-site unitary gate depending on the measurement outcome. If the Bell measurement yields \(\left\vert {{\Psi }}_{S = 0}\right\rangle := \left\vert 01\right\rangle -\left\vert 10\right\rangle\), we achieve a successful singlet projection. However, there are three other possible outcomes: \({X}_{{R}_{1}}\left\vert {{\Psi }}_{S = 0}\right\rangle\), \({Y}_{{R}_{1}}\left\vert {{{\Psi }}}_{S = 0}\right\rangle\), or \({Z}_{{R}_{1}}\left\vert {{\Psi }}_{S = 0}\right\rangle\), which are equivalent to the singlet projection up to a local unitary Oi {X, Y, Z} on R1 before the triplet projection. We utilize the property of an SPT wavefunction: applying a symmetry transformation ∏iUi(g) for g G is equivalent to applying symmetry transformations on the left and right edge modes UL(g) and \({U}_{R}^{-1}(g)\), respectively107. Therefore, we can “undo” a Pauli operator on R1 by applying a product of local unitaries ∏iUi(g) on the spin-1 subspace of ququarts, and the only consequence is that \(\left\vert {L}_{1}\right\rangle\) would be transformed into \({U}_{L}(g)\left\vert {L}_{1}\right\rangle\). Note that g for UR(g) ~ X, Y, Z corresponds to π-rotation around \(\hat{x}\), \(\hat{y}\), and \(\hat{z}\) axis respectively, and Ui(g) can be easily implemented using intra-ququart gates. This deterministic procedure allows us to fuse two AKLT segments into a single AKLT chain, irreversibly removing information about R1 and L2. A similar concept has been discussed in ref. 88.

In the top-down approach, we employ a fission process to reduce the AKLT state from an initial length \({L}^{{\prime} }\) to the desired smaller length L. The idea is to convert the right-most triplet site into a singlet and remove it from the chain, as shown in Fig. 11b. This can be achieved by performing an intra-ququart Bell measurement on optical and nuclear qubits within the right-most site. Since the ququart is already in a state with S = 1, the Bell basis measurement can collapse it into three possible states: \({X}_{1}\left\vert {{\Psi }}_{S = 0}\right\rangle\), \({Y}_{1}\left\vert {{\Psi }}_{S = 0}\right\rangle\), and \({Z}_{1}\left\vert {{\Psi }}_{S = 0}\right\rangle\). This implies that the Bell basis measurement makes it as if the last ququart was projected onto singlet up to a Pauli correction after the Bell state measurement. Furthermore, this will automatically teleport the edge state \(\left\vert R\right\rangle\) in the nuclear qubit at the site-\({L}^{{\prime} }\) to the site-\(({L}^{{\prime} }-1)\).

More precisely, the right-most edge state for the AKLT segment with length \(({L}^{{\prime} }-1)\) is now labeled by \(O\left\vert R\right\rangle\) where O is X, Y or Z depending on the measurement outcome. Through this fission process, we can deterministically remove each right-most ququart, resulting in a new AKLT state with a shorter length and an edge state \({O}_{i}\left\vert R\right\rangle\), modified according to the measurement outcome. We emphasize that this fission protocol (or removal protocol) can be applied in parallel for any number of ququarts. By performing intra-ququart Bell-basis measurements on the last \({L}^{{\prime} }-L\) ququarts to be removed, the resulting state will be an AKLT state derived from the initial state, with the right edge mode labeled as \(\mathop{\prod }\nolimits_{i = 1}^{{L}^{{\prime} }-L}{O}_{i}\left\vert R\right\rangle\).