Quantum logic with spin qubits crossing the surface code threshold

High-fidelity control of quantum bits is paramount for the reliable execution of quantum algorithms and for achieving fault tolerance—the ability to correct errors faster than they occur1. The central requirement for fault tolerance is expressed in terms of an error threshold. Whereas the actual threshold depends on many details, a common target is the approximately 1% error threshold of the well-known surface code2,3. Reaching two-qubit gate fidelities above 99% has been a long-standing major goal for semiconductor spin qubits. These qubits are promising for scaling, as they can leverage advanced semiconductor technology4. Here we report a spin-based quantum processor in silicon with single-qubit and two-qubit gate fidelities, all of which are above 99.5%, extracted from gate-set tomography. The average single-qubit gate fidelities remain above 99% when including crosstalk and idling errors on the neighbouring qubit. Using this high-fidelity gate set, we execute the demanding task of calculating molecular ground-state energies using a variational quantum eigensolver algorithm5. Having surpassed the 99% barrier for the two-qubit gate fidelity, semiconductor qubits are well positioned on the path to fault tolerance and to possible applications in the era of noisy intermediate-scale quantum devices.

High-fidelity control of quantum bits is paramount for the reliable execution of quantum algorithms and for achieving fault tolerance-the ability to correct errors faster than they occur 1 . The central requirement for fault tolerance is expressed in terms of an error threshold. Whereas the actual threshold depends on many details, a common target is the approximately 1% error threshold of the well-known surface code 2,3 . Reaching two-qubit gate fidelities above 99% has been a long-standing major goal for semiconductor spin qubits. These qubits are promising for scaling, as they can leverage advanced semiconductor technology 4 . Here we report a spin-based quantum processor in silicon with single-qubit and two-qubit gate fidelities, all of which are above 99.5%, extracted from gate-set tomography. The average single-qubit gate fidelities remain above 99% when including crosstalk and idling errors on the neighbouring qubit. Using this high-fidelity gate set, we execute the demanding task of calculating molecular ground-state energies using a variational quantum eigensolver algorithm 5 . Having surpassed the 99% barrier for the two-qubit gate fidelity, semiconductor qubits are well positioned on the path to fault tolerance and to possible applications in the era of noisy intermediate-scale quantum devices.
Quantum computation involves the execution of a large number of elementary operations that take a qubit register through the steps of a quantum algorithm 6 . A major challenge is to implement these operations with sufficient accuracy to arrive at a reliable outcome, even in the presence of decoherence and other error sources. The higher the accuracy, or fidelity, of the operations, the higher the likelihood that near-term applications for quantum computers come within reach 7 . Furthermore, for most presently known algorithms, the number of operations that must be concatenated will unavoidably lead to excessive accumulation of errors, and these errors must be removed using quantum error correction 1 . Correcting quantum errors faster than they occur is possible when the error probability per operation is below a certain threshold, known as the fault-tolerance threshold. For the widely considered surface code, for instance, the fault-tolerance threshold is between 0.6% and 1%, under certain assumptions, albeit at the cost of a large redundancy in the number of physical qubits 2,3 .
Among all the candidate platforms, electron spins in semiconductor quantum dots have advantages, such as their long coherence times 8 , small footprint 9 , the potential for scaling up 10 and the compatibility with advanced semiconductor manufacturing technology 4 . Single-qubit operations of spin qubits in quantum dots achieve fidelities of 99.9% (refs. 11,12 ) but the two-qubit gate fidelities reported vary from 92% to 98% (refs. 13,14 ). This has limited the two-qubit Bell-state fidelities to 94% (ref. 15 ) and quantum algorithms implemented with spin qubits gave only coarsely accurate outcomes 16,17 . Pushing the two-qubit gate fidelity well beyond 99% requires not only low charge-noise levels and the elimination of nuclear spins by isotopic enrichment but also careful Hamiltonian engineering.
In this paper, using a precisely engineered two-qubit interaction Hamiltonian, we report the demonstration of single-qubit and two-qubit gates with fidelities above 99.5%. We use gate-set tomography (GST) not only to characterize the gates and to quantify the fidelity but also to improve the gate calibration. The high-fidelity gates allow us to compute the dissociation energy of molecular hydrogen with a variational quantum eigensolver (VQE) algorithm, reaching an accuracy for the dissociation energy of around 20 mHa, limited by readout errors.
We use a gate-defined double quantum dot in an isotopically enriched 28 Si/SiGe heterostructure 17 (Fig. 1a), with each dot occupied by a single electron (see Methods). The spin states of the electrons serve as qubits. The spin states are measured with the help of a sensing quantum dot (SQD), which is capacitively coupled to the qubit dots 18 . A micromagnet on top of the device provides a magnetic field gradient enabling electric-dipole spin resonance 19 and separates the resonance frequencies of the qubits in the presence of an external magnetic field (~320 mT) to 11.993 GHz (Q 1 ) and 11.890 GHz (Q 2 ). Single-qubit X and Y gates are implemented by frequency-multiplexed microwave signals applied to gate MW and virtual Z gates are implemented by a phase update of the reference frame 20 . The plunger gates (LP and RP) control the chemical potentials of the quantum dots.
The native two-qubit gate for spin qubits uses the exchange interaction 21,22 , originating from the wave-function overlap of electrons in neighbouring dots. This selectively shifts the energy of the antiparallel spin states and, thus, enables an electrically pulsed adiabatic conditional Z (CZ) gate 8,16,23 . The barrier gate (B) controls the tunnel coupling between the dots, allowing the precise tuning of the exchange coupling from <100 kHz to 20 MHz. To minimize the sensitivity to charge noise, we activate the Article exchange coupling while avoiding a tilt in the double-dot potential 24,25 (Fig. 1a). This symmetric condition can be determined accurately by decoupled adiabatic exchange pulses inside a Ramsey sequence (Fig. 1c, d). The tunnel barrier is controlled by simultaneously pulsing gate B and compensating LP and RP to avoid shifts in the electrochemical potentials 24 , constituting a virtual barrier gate. The detuning between quantum dots is controlled by additional offsets to the LP and RP pulses in opposite directions. As the decoupling pulses remove additional single-qubit phase accumulation from electron movement in the magnetic field gradient, the spin-up probability of Q 1 results in a symmetric chevron pattern, with the symmetry point at the centre (Fig. 1d).
Among the various quantum benchmarking techniques, quantum process tomography (QPT) is designed to reconstruct all details in a target process 6 . Owing to the susceptibility of QPT to state preparation and measurement (SPAM) errors, self-consistent benchmarking techniques such as GST 26 and alternative techniques such as randomized benchmarking 27 have been developed. In contrast to randomized benchmarking, GST inherits the advantage of QPT in that it reports the detailed process, which allows us to isolate Hamiltonian errors from stochastic errors and to correct for such errors in the control signals (Extended Data Fig. 5). In addition, GST accounts for gate-dependent errors. We benchmark the fidelities of a universal gate set using GST 26,28 (Fig. 2a). The gate set we choose contains an idle gate (I), sequentially operated single-qubit π/2 rotations about the x and ŷ axes for each qubit (X Q 1 , Y Q 1 , X Q 2 and Y Q 2 ) and a two-qubit controlled-phase (CZ) gate. A total of 36 fiducial sequences containing {null, X ,Y } n n Q =1,2,3 Q =1,3 i j on each qubit, where null (unlike the idle gate) has no waiting time, are used to tomographically measure the two-qubit state. These fiducials are interleaved by germ sequences and their powers up to a sequence depth of 16. Germs are short sequences of gates taken from the universal gate set (see Methods). They are repetitively executed to amplify different types of gate errors in the gate set, such that SPAM errors can be isolated. GST allows using a maximum-likelihood estimator to compute completely positive and trace-preserving process matrices for each element of the gate set 6 . The gate fidelity can be calculated by comparing the measured process using the Pauli transfer matrix (PTM), M exp , with the ideal PTM, where d is the dimension of the Hilbert space. These process matrices provide a detailed error diagnosis of the gate set, allowing for efficient feedback calibration 29 (Fig. 2a). Analysing the error generator = log( ) exp ideal −1 L M M provides easy access to information. For example, coherent Hamiltonian errors can be isolated from incoherent stochastic errors and single-qubit errors can be isolated from each other and from two-qubit errors 30 . Figure 2b, c shows the reduced PTMs of X Q 1 and Y Q 1 operations in the Q 1 subspace and Fig. 2d shows the full PTM of Y Q 1 in two-qubit space (Y ⊗ I Q Q 2 1 ) containing additional errors from decoherence and crosstalk on Q 2 while operating Q 1 (see Extended Data Figs. 1 and 2 for other PTMs) and from unintentional entanglement due to a residual exchange interaction. The average single-qubit gate fidelity is 99.72% in the single-qubit subspace (X Q 1 : 99.68%; Y Q 1 : 99.73%; X Q 2 : 99.61%; Y Q 2 : 99.87%; see Extended Data Fig. 2 for all error bars). A metric that is rarely reported is the single-qubit gate fidelity in the full two-qubit space, here 99.16% on average (see Methods and Extended Data Fig. 1). These results highlight that single-qubit benchmarking is not sufficient to identify all errors occurring during single-qubit operations. By analysing the error generators, we find that errors from uncorrelated dephasing of the idling qubit dominate the drop in single-qubit gate fidelity when characterized in the two-qubit space. Coherent, microwave-induced phase shifts-the main source of crosstalk errors-have been corrected by applying a compensating phase gate to the idling qubit (Extended Data Fig. 4). The elimination of idling errors and other crosstalk errors from the microwave drive, such as through heating effects, will be a crucial step to improve the quality of the single-qubit operations further. For a high-fidelity adiabatic CZ gate, precise control of the exchange coupling, J, between the two qubits is required. Specifically, in order to avoid unintended state transitions due to non-adiabatic dynamics, we must be able to carefully shape the envelope of J. We characterize J over a wide range using a Ramsey sequence interleaved by a virtual barrier pulse with incremental amplitude v B . Figure 3a shows the measured frequency shift of each qubit as functions of the barrier pulse amplitude and the state of the other qubit. The exchange interaction is modelled to be exponentially dependent on the barrier pulse amplitude J v ( )∝ e αv B 2 B (refs. 31,32 ). The micromagnet-induced single-qubit frequency shifts are approximated by linear functions within the voltage window of the CZ gate in the numerical simulations. By fitting the measured datasets simultaneously to theoretical models (see Methods), J can be extracted very precisely as the difference between the two conditional frequencies of each qubit 16,33 (Fig. 3b). The barrier pulse v A t t ∝ log( (1 − cos(2π / ))/2) v B g ate B (Fig. 3d) compensates the exponential dependence such that J ∝ (1 − cos(2πt/t gate )) follows a cosine window function, which ensures good adiabaticity 34 (Fig. 3e). In addition, the virtual gates are calibrated such that the symmetric operation point is maintained for each barrier setting, minimizing the influence of charge noise via the double-dot detuning. The most relevant remaining noise sources include charge noise, affecting J through fluctuations in the virtual barrier gate δv B , and fluctuating qubit frequencies δf Q 1 and δf Q 2 from charge noise entering through artificial spin-orbit coupling from the micromagnet and residual nuclear spin noise coupling through the hyperfine interaction. By analysing the decay of the Ramsey oscillations at each transition frequency, individual dephasing times T 2 can be extracted and, from there, also δv B , δf Q 1 and δf Q 2 (Fig. 3c). Figure 4a shows an example GST pulse sequence that contains twice in a row the germ [CZ, X ,Y , CZ, Y , X ] 1 . The PTM of the CZ gate obtained from GST is shown in Fig. 4b. Using the detailed information from the error generator to fine-tune the calibration parameters, we can achieve a CZ fidelity of 99.65 ± 0.15% (Extended Data Figs. 4 and 5). Error bars included here and elsewhere are the 2σ ≈ 95% confidence intervals computed using the Hessian of the loglikelihood function 35 . The CZ error generator reveals that, at this point, incoherent errors dominate. The virtual barrier gate technique used here efficiently suppresses crosstalk errors during two-qubit gates. Therefore, we expect the CZ fidelity to be mostly affected by dephasing errors of idling qubits in a larger space, which can be corrected for using decoupling pulses. From the obtained PTMs, we can numerically estimate Bell-state fidelities by multiplications of the PTMs necessary to construct the corresponding state, giving an estimate of 97.75%-98.42%, neglecting SPAM errors, for the four Bell states ( Fig. 4c and Extended Data Fig. 3).    and δv B = 0.4 mV. d, Shape of the barrier pulse, designed to achieve a high-fidelity CZ gate. e, The cosine-shaped J envelope seen by the qubits during the pulse shown in d.

Article
Next, we use the high-fidelity gate set in the context of an actual application, in order to provide a quantitative benchmark for future work under realistic conditions. Specifically, we implement a VQE algorithm to compute the ground-state energy of molecular hydrogen (H 2 ) (Fig. 5a). In a VQE algorithm, a quantum processor is used to implement a classically inefficient subroutine (see Methods and Extended Data Fig. 6). The second quantized H 2 Hamiltonian can be mapped onto two qubits under the Bravyi-Kitaev (BK) transformation H = h 0 II + h 1 ZI + h 2 IZ + h 3 ZZ + h 4 X X + h 5 YY. Here I, X, Y and Z are Pauli operators, for example, ZI is shorthand for Z ⊗ I, and the coefficients h 0 -h 5 are classically computable functions of the internuclear distance, R. Figure 5b shows the schematic of the VQE algorithm and its circuit implementation for a H 2 molecule. The qubit is initialized in |01⟩, which represents double occupation of the lowest molecular orbital, corresponding to the Hartree-Fock (HF) ground state. A parameterized ansatz state is then prepared by considering single and double excitation, which, after the BK transformation, yields ψ θ ( ) = e 01 θ −i XY , with θ the parameter to variationally optimize. By performing partial tomography on the ansatz state with an initial guess θ 0 , the expectation value of the Hamiltonian for |ψ(θ 0 )⟩ can be calculated. A classical computer can efficiently compute the next guess θ 1 as the new input for the quantum computer. This loop is iterated until the result converges. For a H 2 molecule, there is only one parameter θ to optimize, thus, a scan of the entire parameter range of 2π with finite samples is sufficient to interpolate the smoothly changing measured expectation values. This emulates a real variational algorithm, where θ can be estimated to arbitrary precision by increasing the number of repetitions to suppress statistical fluctuations 36 . Figure 5c shows the partial tomography result after normalization of the visibility window. The data demonstrate high-quality phase control in the quantum circuits. The deviations in the odd-parity expectation values indicate correlations in the readout of the two qubits 37 . Figure 5d shows the energy curves of the H 2 molecule from both theory 38 and the VQE experiment. We observe a minimum energy at around 0.72 Å and an error of approximately 20 mHa at the theoretical bond length 0.7414 Å, mainly attributed to slow drift in the readout parameters. This accuracy matches the results obtained using superconducting and trapped ion qubits with comparable gate fidelities 36,39 .
The two-qubit gate with fidelity above 99.5% and single-qubit gate fidelities in the two-qubit gate space above 99% on average place semiconductor spin qubit logic at the error threshold of the surface code. Recently, a two-qubit operation between nuclear spin qubits in silicon, mediated by an electron spin qubit, has been demonstrated to surpass 99% fidelity as well, further highlighting that semiconductor spin qubits offer precise two-qubit logic 40 . Independent studies have shown spin qubit readout with a fidelity above 98% in only a few μs (ref. 41 ), with further improvements underway 42 . Combining high-fidelity initialization, readout and control into a demonstration of fault tolerance poses several key challenges to be overcome. First, sufficiently large and reliable quantum dot arrays must be constructed, with good connectivity between the qubits. Second, the fidelities achieved in small-scale systems must be maintained across such larger systems, which will require reducing idling and crosstalk errors. The same advances will allow us to implement more sophisticated algorithms in the noisy intermediate-scale quantum era, such as solving energies involving excited states of more complex molecules.

Online content
Any methods, additional references, Nature Research reporting summaries, source data, extended data, supplementary information, acknowledgements, peer review information; details of author contributions and competing interests; and statements of data and code availability are available at https://doi.org/10.1038/s41586-021-04273-w.

Measurement setup
The measurement setup and device are similar to those used in ref. 17 . We summarize a few key points and all the differences here. The gates LP, RP and B are connected to arbitrary waveform generators (AWGs, Tektronix 5014C) via coaxial cables. The position in the charge-stability diagram of the quantum dots is controlled by voltage pulses applied to LP and RP. Linear combinations of the voltage pulses applied to B, LP and RP are used to control the exchange coupling between the two qubits at the symmetry point. The compensation coefficients are v LP /v B = −0.081 and v RP /v B = 0.104. A vector signal generator (VSG, Keysight E8267D) is connected to gate MW and sends frequency-multiplexed microwave bursts (not necessarily time-multiplexed) to implement electric-dipole spin resonance (EDSR). The VSG has two I/Q input channels, receiving I/Q modulation pulses from two channels of an AWG. I/Q modulation is used to control the frequency, phase and length of the microwave bursts. The current signal of the sensing quantum dot is converted to a voltage signal and recorded by a digitizer card (Spectrum M4i.44), and then converted into 0 or 1 by comparing it to a threshold value.
Two differences between the present setup and that in ref. 17 are that (1) the programmable mechanical switch is configured such that gate MW is always connected to the VSG and not to the cryo-CMOS control chip and (2) a second AWG of the same model is connected to gate B, with its clock synchronized to the first AWG.

Gate calibration
In the gate set used in this work, {I, X ,Y , X ,Y ,CZ} , the duration of the I gate and the CZ gate are set to 100 ns, and we calibrate and keep the amplitudes of the single-qubit drives fixed and in the linear-response regime, where the Rabi frequency is linearly dependent on the driving amplitude. The envelopes of the single-qubit gates are shaped following a 'Tukey' window, as it allows adiabatic single-qubit gates with relatively small amplitudes, thus, avoiding the distortion caused by a nonlinear response. The general Tukey window of length t p is given by where r = 0.5 for our pulses. Apart from these fixed parameters, there are 11 free parameters that must be calibrated: single-qubit frequencies f Q 1 and f Q 2 , burst lengths for single-qubit gates t XY1 and t XY2 , phase shifts caused by single-qubit gates on the addressed qubit itself ϕ 11 and ϕ 22 , phase shifts caused by single-qubit gates on the unaddressed 'victim qubit' ϕ 12 and ϕ 21 (ϕ 12 is the phase shift on Q 1 induced by a gate on Q 2 and similar for ϕ 21 ), the peak amplitude of the CZ gate A v B and phase shifts caused by the gate voltage pulses used for the CZ gate on the qubits θ 1 and θ 2 (in addition, we absorb into θ 1 and θ 2 the 90° phase shifts needed to transform diag(1, i, i, 1) into diag (1, 1, 1, −1)).
For single-qubit gates, f Q 1 and f Q 2 are calibrated by standard Ramsey sequences, which are automatically executed every 2 h, at the beginning and in the middle (after 100 times the average of each sequence) of the GST experiment. The EDSR burst times t XY1 and t XY2 are initially calibrated by an AllXY calibration protocol 43 . The phases ϕ 11 , ϕ 12 , ϕ 21 and ϕ 22 are initially calibrated by measuring the phase shift of the victim qubit (Q 1 for ϕ 11 and ϕ 21 ; Q 2 for ϕ 22 Fig. 4).
The optimal pulse design presented in Fig. 3 gives a rough guidance of the pulse amplitude A v B . In a more precise calibration of the CZ gate, an optional π-rotation is applied to the control qubit (for example, Q 1 ) to prepare it into the |0⟩ or |1⟩ state, followed by a Ramsey sequence on the target qubit (Q 2 ) interleaved by an exchange pulse. The amplitude is precisely tuned to bring Q 2 completely out of phase (by 180°) between the two measurements (Extended Data Fig. 4d, e). The phase θ 2 is determined such that the phase of Q 2 changes by zero (π) when Q 1 is in the state |0⟩ (|1⟩), corresponding to CZ = diag(1, 1, 1, −1) in the standard basis. The same measurement is then performed again with Q 2 as the control qubit and Q 1 as the target qubit to determine θ 1 (ref. 16 ).
In such a 'conventional' calibration procedure of the CZ gate, we notice that the two qubits experience different conditional phases (Extended Data Fig. 4). We believe that this effect is caused by off-resonant driving from the optional π-rotation on the control qubit. Similar effects can also affect the calibration of the phase crosstalk from single-qubit gates.
This motivates us to use the results from GST as feedback to adjust the gate parameters. The error generators not only describe the total errors of the gates but also distinguish Hamiltonian errors (coherent errors) from stochastic errors (incoherent errors). We use the information on seven different Hamiltonian errors (IX, IY, XI, YI, ZI, IZ and ZZ) of each gate to correct all 11 gate parameters (Extended Data Fig. 5), except f Q 1 and f Q 2 , for which calibrations using standard Ramsey sequences are sufficient. For single-qubit gates, t XY1 and t XY2 are adjusted according to the IX, IY, XI and YI errors. The phases ϕ 11 , ϕ 12 , ϕ 21 and ϕ 22 are adjusted according to the ZI and IZ errors. For the CZ gate, θ 1 and θ 2 are adjusted according to the ZI and IZ errors, and A v B is adjusted according to the ZZ error. The adjusted gates are then used in a new GST experiment.

Theoretical model
In this section, we describe the theoretical model used for the fitting, the pulse optimization and the numerical simulations. The dynamics of two electron spins in the (1,1) charge configuration can be accurately described by an extended Heisenberg model 21 , and the energy difference between the qubits ΔE z = gμ B (B z,2 − B z,1 ). The last term in the Hamiltonian of equation (2) describes the exchange interaction J between the spins in neighbouring dots. The exchange interaction originates from the overlap of the wave functions through virtual tunnelling events and is, in general, a nonlinear function of the applied barrier voltage v B . We note that v B determines the compensation pulses applied to LP and RP for virtual barrier control. We model J as an exponential function 31,32 where J res ≈ 20-100 kHz is the residual exchange interaction during idle and single-qubit operations and α is the lever arm. In general, the magnetic fields j B depend on the exact position of the electron. We include this in our model where β j accounts for the impact of the barrier voltage on the resonance frequency of qubit j. The transition energies described in the main text are now given by diagonalizing the Hamiltonian from equation (2) and computing the energy difference between the eigenstates corresponding to the computational basis states {|00⟩, |01⟩, |10⟩, |11⟩} (ref. 44 ). We have E denotes the eigenenergy of eigenstate |ξ ⟩ and |0⟩ = |↓⟩ is defined by the magnetic field direction.
In the presence of noise, qubits start to lose information. In silicon, charge noise and nuclear noise are the dominating sources of noise. In the absence of two-qubit coupling and correlated charge noise, both qubits decohere largely independently of each other, giving rise to a decoherence time set by the interaction with the nuclear spins and charge noise coupling to the qubit via intrinsic and artificial (via the inhomogeneous magnetic field) spin-orbit interaction. We describe this effect by , where δf Q 1 and δf Q 2 are the single-qubit frequency fluctuations. Charge noise can additionally affect both qubits via correlated frequency shifts and the exchange interaction through the barrier voltage, which we model as v B → v B + δv B .
In the presence of finite exchange coupling, one can define four distinct, pure dephasing times, each corresponding to the dephasing of a single qubit with the other qubit in a specific basis state. In a quasistatic approximation, the four dephasing times are then given by

Fitting qubit frequencies and dephasing times
The transition energies in equations (4)- (7) are fitted simultaneously to the measured results from the Ramsey experiment (see Fig. 3a).
The dephasing times in equations (8)- (11) are fitted simultaneously to the measured results from the Ramsey experiment (see Fig. 3c) using the same method. The best fits yield the following parameters: δv B = 0.40 ± 0.01 mV, δf = 11± 0.1kHz

Numerical simulations
For all numerical simulations, we solve the time-dependent Schrödinger equation and iteratively compute the unitary propagator according to where ħ h = /(2π) is the reduced Planck's constant. Here H(t + Δt) is discretized into N segments of length Δt such that H(t) is constant in the time interval [t, t + Δt]. All simulations are performed in the rotating frame of the external magnetic field (B z,1 + B z,2 )/2 and neglecting the counter-rotating terms, making the so-called rotating-wave approximation. This allows us to choose Δt = 10 ps as a sufficiently small time step.
For the noise simulations, we included classical fluctuations of and v B → v B + δv B . We assume the noise coupling to the resonance frequencies δf Q 1 and δf Q 2 to be quasistatic and assume 1/f noise for v B , which we describe by its spectral density S ω δv ω where ω is the angular frequency. To compute time traces of the fluctuation, we use the approach introduced in refs. 45,46 to generate time-correlated time traces. The fluctuations are discretized into N segments with time Δt such that δv B (t) is constant in the time interval [t, t + Δt), with the same Δt as above. Consequently, fluctuations that are faster than f = t max 1 ∆ are truncated.
z z x sub B B In order to investigate the adiabatic behaviour, it is convenient to switch into the adiabatic frame defined by U = e .
σ ad − tan The Hamiltonian accordingly transforms asḢ z z z y B 2ẇ here the first term is unaffected and describes the global phase accumulation due to the exchange interaction, the second term describes the single-qubit phase accumulations and the last term, ḟ t h J E ( ) = /(4πΔ ) z 2 , describes the diabatic deviation proportional to the derivative of the exchange pulse. From equation (15) and equation (16), we assumed a constant ΔE z (t) ≈ ΔE z and hJ(t) ≪ ΔE z . The transition probability from state |↑↓⟩ to |↓↑⟩ using a pulse of length t p is then given by 34 s From the first to the second line, we identify the integral by the (short-timescale) Fourier transform, allowing us to describe the spin-flip error probability by the energy spectral density S s of the input signal f(t). Minimizing such errors is, therefore, identical to minimizing the energy spectral density of a pulse, a well-known and solved problem from classical signal processing and statistics. Optimal shapes are commonly referred to as window functions W(t) due to their property of restricting the spectral resolution of signals. A high-fidelity exchange pulse is consequently given by J(0) = J(t p ) and , with a scaling factor A v B that is to be determined. In this work, we have chosen the cosine window from signal processing, which has a high spectral resolution. The amplitude A v B follows from condition equation (19). For a pulse length of t p = 100 ns and a cosine pulse shape, we find A J = 10.06 MHz v res B . As explained in the main text, owing to the exponential voltage-exchange relation, the target pulse shape for J(t) must be converted to a barrier gate pulse, following 47 Our numerical simulations predict an average gate infidelity 1 − F gate < 10 −6 without noise and 1 − F = 0.22 × 10 −3 with the inclusion of noise through the fluctuations δf Q 1 , δf Q 2 and δv B , discussed in the previous section. The measured PTMs reveal much higher rates of incoherent errors, which we attribute to drifts in the barrier voltage on a timescale much longer than the timescale on which δf Q 1 , δf Q 2 and δv B were determined.

Gate-set tomography analysis
We designed a GST experiment using the gate set {I, X ,Y ,X ,Y ,CZ}, where I is a 100-ns idle gate, X Q 1 (Y Q 1 ) and X Q 2 (Y Q 2 ) are single-qubit π/2 gates with rotation axis x ( ŷ) on Q 1 and Q 2 , with durations of 150 ns and 200 ns, respectively, and CZ = diag(1, 1, 1, −1). A classic two-qubit GST experiment consists of a set of germs designed to amplify all types of error in the gate set when repeated and a set of 36 fiducials composed by the 11 elementary operations {null, X ,X X ,X X X , Q   1  1  1  1  2  2  2  2  2  2  2  2  2  2 required to carry out quantum process tomography of the germs 48 . We use a set of 16 germs {I, X ,Y ,X ,Y ,CZ, X Y ,X Y , X X Y , X X 35 ). Note that the null gate is the instruction for doing nothing in zero time, different from the idle gate. Simple errors such as errors in the rotation angle of a particular gate can be amplified by simply repeating the same gate. More complicated errors such as tilts in rotation axes can only be amplified by a combination of different gates. The germs and fiducials are then compiled into GST sequences, such that each sequence consists of two fiducials interleaved by a single germ or power of germs 35 (as illustrated in Fig. 2a). The GST sequences are classified by their germ powers into lengths L = 1, 2, 4, 8, 16…, where a sequence of length n consists of n gates plus the fiducial gates. We note that the sequences used in GST are shorter than the sequences involved in other methods to self-consistently estimate the gate performance, such as randomized benchmarking. As a result, GST suffers less from drift in qubit frequencies and readout windows induced by long sequences of microwave bursts.
After the execution of all sequences, a maximum-likelihood estimation is performed to estimate the process matrices of each gate in the gate set and the SPAM probabilities. We use the open source pyGSTi Python package 49,50 to perform the maximum-likelihood estimation, as well as to design an optimized GST experiment by eliminating redundant circuits and to provide statistical error bars by computing all involved Hessians. The circuit optimization allows us to perform GST with a maximum sequence length L max = 16 using 1,685 different sequences in total. The pyGSTi package quantifies the Markovian-model violation of the experimental data, counting the number of standard deviations exceeding their expectation values under the χ 2 hypothesis 50 . This model violation is internally translated into a more accessible goodness ratio from 0 to 5, with 5 being the best 49 , where we obtain a 4 out of 5 rating, indicating remarkably small deviations from expected results. The total number of standard deviations exceeding the expected results for each L, as well as the contribution of each sequence to this number, can be found in the pyGSTi report, along with the supporting data. . The PTM is isomorphically related to the conventionally used χ matrix describing a quantum process. A completely positive, trace-preserving, two-qubit PTM has 240 parameters describing the process. To obtain insight into the errors of the gates in the experiment, we first compute the error in the PTM given by E = exp ideal It is related to the entanglement fidelity via ( ) where d is the dimension of the two-qubit Hilbert space. Although the PTM M perfectly describes the errors, it is more intuitive to analyse the corresponding error generator L E = log( ) of the process 30 . The error generator L relates to the error PTM E in a similar way as a Hamiltonian H relates to a unitary operation U = e −iH . The error generator can be separated into several blocks. A full discussion about the error generator can be found in ref. 30 . In this work, we have used the error generator to distinguish the dynamics originating from coherent Hamiltonian errors, which can be corrected by adjusting gate parameters (see Extended Data Fig. 5), and from noisy/stochastic dynamics, which cannot be corrected easily. The coherent errors can be extracted by projecting L onto the 4 × 4-dimensional Hamiltonian space H. In the Hilbert-Schmidt space, the Hamiltonian projection is given by 30 which describes the amount of incoherent error in the process, and the Jamiołkowski amplitude L is the Jamiołkowski state and |Ψ⟩ is a maximally entangling four-qubit state that originates from the relation of quantum processes to states in a Hilbert space twice the dimension via the Choi-Jamiołkowski isomorphism 52 . For small errors, the average gate infidelity can be approximated by 30 For a comparison of the performance of the single-qubit gates with previous experiments reporting single-qubit gate fidelities, we compute the fidelities projected to the single-qubit space from the PTMs or the error generators. In Fig. 2 and Extended Data Fig. 2, single-qubit gate fidelities are estimated by projecting the PTMs onto the corresponding subspace. Let j P be the projector on the subspace of qubit j, then the fidelity is given by Error bars for the fidelity projected to the subspace are computed using standard error propagation of the confidence intervals of exp M provided by the pyGSTi package. A more optimistic estimation for the fidelities in the single-qubit subspace is given by projecting the error generators instead of the PTMs.

Variational quantum eigensolver
We follow the approach of ref. 36 to using the VQE algorithm to compute the ground-state energy of molecular hydrogen, after mapping this state onto the state of two qubits. We include this information here for completeness. The Hamiltonian of a molecular system in atomic units is i i i is a multi-index describing the position r i and the spin s i of electron i. Such a second-quantized molecular Hamiltonian can be mapped onto qubits using the Jordan-Wigner ( JW) or the BK transformation 5 . The JW transformation directly encodes the occupation number (0 or 1) of the ith spin orbital into the state (|0⟩ or |1⟩) of the ith qubit. The number of qubits required after JW transformation is, thus, the same as the number of spin orbitals that are of interest. The BK transformation, on the other hand, encodes the information in both the occupation number and parities, whether there is an even or odd occupation in a subset of spin orbitals.
Taking molecular hydrogen in the HF basis as an example, we are interested in investigating the bonding (|O 1 ↑⟩, |O 1 ↓⟩) and the antibonding orbital state (|O 2 ↑⟩, |O 2 ↓⟩). The initial guess of the solution is the HF state in which both electrons occupy the |O 1

Article
The subscripts are used to label the qubits. We see that, owing to the symmetry of the represented system in H BK , qubit 2 and qubit 4 are never flipped, allowing us to reduce the dimension of the where qubit 1 has been relabelled as qubit 2 and qubit 3 has been relabelled as qubit 1. The HF initial state is, therefore, reduced to |01⟩ and the Hamiltonian is rephrased to be consistent with the partial tomography expression in Fig. 5. This reduced representation requires only two qubits to simulate the hydrogen molecule. We emphasize that such a reduction of the BK Hamiltonian is not a special case for the H 2 molecule but is connected to symmetry considerations to reduce the complexity of systems, in a scalable way. VQE is a method to compute the ground-state energy of the Hamiltonian. The total energy can be directly calculated by measuring the expectation value of each Hamiltonian term. This can be done easily by partial quantum state tomography. All the expectation values are then added up with a set of weights (h 0 through h 5 ). The weights are only functions of the internuclear separation (R) and can be computed efficiently by a classical computer. Here we use the OpenFermion Python package to compute these weights 38 .
The main task of the quantum processor is, then, to encode the molecular spin-orbital state into the qubits. The starting point is the HF initial state, which is believed to largely overlap with the actual ground state. In order to find the actual ground state, the initial state needs to be 'parameterized' into an ansatz to explore a subspace of all possible states. We apply the unitary coupled cluster (UCC) theory to the parameterized ansatz state, which is used to describe many-body systems and cannot be efficiently executed on a classical computer 53 Fig. 4 | Initial gate calibrations. a, Decomposition of single-qubit and two-qubit gates. After each microwave burst for single-qubit rotations, a corresponding phase correction is applied to each qubit. The CZ gate is implemented by a barrier voltage pulse applied to gate B (orange) and negative compensation pulses applied to gates LP (blue) and RP (red), with the same shape as the barrier pulse. Single-qubit phase corrections are then applied on each qubit to compensate the frequency detuning induced by electron movement in the magnetic field gradient. b, c, Calibration of phase corrections on Q 1 induced by a single-qubit gate applied on Q 2 (ϕ 21 , b) and on Q 1 (ϕ 11 , c). A relative phase shift, 2ϕ 21 (2ϕ 11 ), is determined by interleaving the target gate (a π/2 rotation) and its inverse (a −π/2 rotation) on Q 2 (Q 1 ) in a Ramsey interference sequence. d, e, Calibration of phase corrections on each qubit after the CZ gate, using Q 1 (d) and Q 2 (e) as the control qubits, respectively. When the amplitude of the barrier pulse is perfectly calibrated, the two curves in each experiment should be out of phase by 180°. However, when the barrier pulse amplitude is calibrated such that one of the two experiments shows a 180° phase difference (d), the phase difference in the other calibration experiment always deviates by a few degrees. One possible explanation is that the optional π-rotation applied to the control qubit induces a small, off-resonance rotation on the other qubit, causing an additional phase on the target qubit to appear in the measurement due to the commutation relation of the Pauli operators.