Coherent noise and quantum memory

We shall consider a particular version of the surface code proposed in Refs.31,32 A distance-d surface code has one logical qubit and n = d2 physical qubits located at sites of a square lattice of size d × d with open boundary conditions, see Fig. 1.

Fig. 1 Surface codes with distance d = 3 and d = 5. Qubits and stabilizers are located at sites and faces respectively. A stabilizer B f located on a face f applies X (black faces) or Z (white faces) to each qubit on the boundary of f. Logical Pauli operators X L (red) and Z L (blue) have support on the left and the top boundary Full size image

We consider the situation where a logical state ψ L initially encoded by the surface code undergoes a coherent error U = U 1 ⊗…⊗U n which applies some (unknown) unitary operator U j to each qubit j. To diagnose and correct the error without disturbing the encoded state we assume the standard protocol based on the syndrome measurement is applied. It works by measuring the eigenvalue (syndrome) s f = ±1 of each stabilizer B f on the corrupted state U|ψ L 〉 and then applying a Pauli-type correction operator C s depending on the measured syndrome s = {s f } f . The correction C s is computed by a classical decoding algorithm (for example, one may choose C s as a minimum-weight Pauli error consistent with s). We note that the syndrome s is a random variable with some probability distribution p(s) since the error U maps the initial logical state to a coherent superposition of states with different syndromes. We only consider noiseless syndrome measurements, and also assume that the correction operations C s can be executed noiselessly. These assumptions (which can be relaxed by adapting our methods) are motivated by our focus on the effect of coherent errors. They also imply that we can assume that the correction C s always returns the system to the logical subspace resulting in some final logical state |ϕ s 〉. Thus the process of (noisy) storage with error U and subsequent error correction maps an initial encoded state |ψ L 〉 to a certain final logical state |ϕ s 〉 with probability p(s), while also providing the classical syndrome s.

The main question addressed here is how close the final state |ϕ s 〉 and the initial state |ψ L 〉 are as a function of the noise. Here we will assume that the error applied to qubit j is of the form U j = exp(iη j Z) for some (unknown) angle η j . The restriction to Z-rotations is dictated by the limitations of our simulation algorithm for storage. It provides a paradigmatic example of coherent noise. We also discuss a related problem—that of state preparation—and provide analogous results for general SU(2) coherent errors (see Supplementary Note 2).

Effective coherent logical noise

We show analytically that the syndrome probability distribution p(s) is independent of the initial logical state ψ L whereas the final logical state has the form

$$|\phi _s\rangle = {\mathrm{exp}}(i\theta _sZ_L)|\psi _L\rangle$$ (3)

for some logical rotation angle θ s ∈[0, π) depending on the syndrome s (see Supplementary Note 1). In other words, the error correction process converts physical-level coherent noise U to effective coherent noise exp(iθ s Z L ) on the logical qubit, with a strength θ s depending on the (randomly distributed) syndrome s.

The parametrization (3) concisely captures the effect of coherent noise, providing us with a window into the nature of this conversion. We use the quantity

$$P^L = 2\mathop {\sum}\limits_s p(s)\left| {{\mathrm{sin}}\theta _s} \right|$$ (4)

as a measure of the (average) logical error rate: this is the average (over syndromes) diamond-norm distance33 \(\left\| {\Lambda _s - {\mathrm{id}}} \right\|_\diamondsuit = 2\left| {{\mathrm{sin}}\theta _s} \right|\) between the conditional logical channel

$$\Lambda _s(\rho ) = e^{i\theta _sZ}\rho e^{ - i\theta _sZ}$$ (5)

and the identity channel id. While the quantity PL provides a meaningful measure for how well the initial state is preserved, the full information of the structure of residual logical errors is given by the distribution p(s) over logical rotation angles θ s .

Polynomial-time classical simulation

We construct a polynomial-time classical algorithm which takes as input |ψ L 〉 and the rotation angles η 1 ,…,η n , samples a syndrome s from the distribution p(s), and outputs s as well as the associated final state |ϕ s 〉 (i.e., the logical rotation angle θ s ). The runtime of this algorithm scales as O(n2), where we measure complexity in terms of the number of additions, multiplications, and divisions of complex numbers that are required. Strictly speaking, the simulation time scales as O(n2) + t(n), where t(n) is the runtime of the decoding algorithm that computes the correction C s . In our simulations the decoding time was negligible compared with the time required to sample the syndrome and compute the final logical state. By sampling sufficiently many syndromes, one can thus learn how frequently and in which ways error correction may fail in the presence of coherent noise. In particular, we may estimate the quantity PL. By providing both the syndrome s and the the logical rotation angle θ s conditioned on s, our algorithm also gives us a unique opportunity to investigate the full structure of the logical-level noise.

Numerical results

Using our algorithm, we perform the first numerical study of large topological codes subject to coherent noise, performing simulations for surface codes with up to n = 2401 physical qubits, see Table 1 for a timing analysis.

Table 1 Runtime in seconds for a C++ implementation of our algorithm Full size table

This shows that efficient classical simulation of fault-tolerance processes under coherent noise is possible, and allows us to extract key characteristics of these codes in the limit of large system size.

In more detail, in our simulations we consider translation-invariant coherent noise of the form (eiθZ)⊗n, where θ∈[0, π) is the only noise parameter. The Pauli correction C s was computed using the standard minimum weight matching decoder9,34 with constant weights independent of θ.

Our numerical results for the logical error rate PL are presented in Fig. 2. Using the symmetries of the surface code one can easily check that PL is invariant under flipping the sign of θ; accordingly, it suffices to simulate θ ≥ 0. The data suggests that the quantity PL decays exponentially in the code distance d for θ<θ 0 , where

$$0.08\pi \le \theta _0 \le 0.1\pi$$ (6)

can be viewed as an error correction threshold. We observe the exponential decay of PL as a function of the code distance d in the sub-threshold regime.

Fig. 2 (Empirical) logical error rate PL for storage of quantum states. We consider distance-d surface codes subject to coherent errors exp(iθZ) on each qubit. We consider surface codes with distance 5 ≤ d ≤ 37. The smallest distance d = 3 was skipped because of strong finite-size effects (note that the considered surface codes are only defined for odd values of d). In all figures, the logical error rate PL was estimated by the Monte Carlo method with at least 50,000 syndrome samples per data point Full size image

Surprisingly, the threshold estimate Eq. (6) agrees very well with the so-called Pauli twirl approximation35,36 where coherent noise of the form \({\cal N}(\rho ) = e^{i\theta Z}\rho e^{ - i\theta Z}\) is replaced by its Pauli-twirled version, i.e., dephasing noise of the form \({\cal N}_{{\mathrm{twirl}}}(\rho ) = (1 - \varepsilon )\rho + \varepsilon Z\rho Z\) with \(\varepsilon = {\mathrm{sin}}^2\theta\). For the latter the threshold error rate is around ε 0 ≈ 0.11, see Ref.9 Solving the equation \(\varepsilon _0 = \mathop {{sin}}

olimits^2 (\theta _0)\) for θ 0 yields θ 0 ≈ 0.10π, in agreement with Eq. (6).

Applying the Pauli twirl at the physical level amounts to ignoring the coherent part of the noise. To assess the validity of this approximation, let us compare logical error rates \(P^L\) computed for coherent physical noise \({\cal N}\) and its Pauli-twirled version \({\cal N}_{{\mathrm{twirl}}}\). Let \(P^L({\cal N}_{{\mathrm{twirl}}})\) be the logical error rate corresponding to \({\cal N}_{{\mathrm{twirl}}}\). The plot of \(P^L({\cal N}_{{\mathrm{twirl}}})\) and the ratio \(P^L/P^L({\cal N}_{{\mathrm{twirl}}})\) are shown on Fig. 3. It can be seen that applying the Pauli twirl approximation to the physical noise gives an accurate estimate of the error threshold but significantly underestimates the logical error probability in the sub-threshold regime. We conclude that coherence of noise has a profound effect on the performance of large surface codes in the sub-threshold regime which is particularly important for quantum fault-tolerance. This phenomenon was previously observed in,23,28 but has not been studied for large topological codes prior to our work.

Fig. 3 Comparison between the logical error rates PL and PL(N twirl ) computed for coherent noise N(ρ) = eiθZρe−iθZ and its Pauli twirled version N twirl (ρ) = (1 − ε)ρ + εZρZ with \(\varepsilon = {\mathrm{sin}}^2(\theta )\). In both cases we used the minimum weight matching decoder. The plot demonstrates that applying the Pauli twirl approximation to the physical noise significantly underestimates the logical error rate in the sub-threshold regime Full size image

More information about the structure of the effective noise can be gained from Fig. 4, which shows the empirical probability distribution of the logical rotation angle θ s obtained by sampling 106 syndromes s for the physical Z-rotation angle θ = 0.08π (which we expect to be slightly below the threshold). We compare the cases d = 9 and 25. In both cases the distribution has a sharp peak at θ s = 0 (equivalent to θ s = π). This peak indicates that error correction almost always succeeds in the considered regime. It can be seen that increasing the code distance has a dramatic effect on the distribution of θ s . The distance-9 code has a broad distribution of θ s meaning that the logical-level noise retains a strong coherence. On the other hand, the distance-25 code has a sharply peaked distribution of θ s with a peak at θ s = π/2 which corresponds to the logical Pauli error Z L . Such errors are likely to be caused by “ambiguous” syndromes s for which the minimum weight matching decoder makes a wrong choice of the Pauli correction C s . We conclude that as the code distance increases, the logical-level noise can be well approximated by random Pauli errors even though the physical-level noise is coherent.

Fig. 4 These histograms show the empirical probability distribution of logical rotation angles θ s for the code distance d = 9 (left) and d = 25 (right) obtained by sampling 106 syndromes s. The histograms use the same noise parameter θ = 0.08π. For ease of visualization, we truncated the main peak at θ s = 0 Full size image

To get a deeper insight into this phenomenon, we introduce and numerically study associated measures of “incoherence”. To define a metric quantifying the degree of coherence present in the logical-level noise, let us consider the twirled version of the logical channel Λ s ,

$$\Lambda _s^{{\mathrm{twirl}}}(\rho ) = (1 - \varepsilon _s)\rho + \varepsilon _sZ\rho Z,\quad \varepsilon _s \equiv {\mathrm{sin}}^2(\theta _s),$$

and the corresponding logical error rate

$$P_{{\mathrm{twirl}}}^L = \mathop {\sum}\limits_s p(s)\left\| {\Lambda _s^{{\mathrm{twirl}}} - {\mathrm{id}}} \right\|_\diamondsuit = 2\mathop {\sum}\limits_s p(s){\mathrm{sin}}^2(\theta _s).$$ (7)

Comparison of Eqs. (4,7) reveals that \(P^L \ge P_{{\mathrm{twirl}}}^L\) with equality iff the distribution of θ s has all its weight on {0,π/2}, that is, when the logical noise is incoherent. It is therefore natural to measure coherence of the logical noise by the ratio \(P^L/P_{{\mathrm{twirl}}}^L\). This “coherence ratio” is plotted as a function of θ on Fig. 5(a). The data indicates that the coherence ratio decreases for increasing system size approaching one for large code distances. This further supports the conclusion that the logical noise has a negligible coherence. Finally, in Fig. 5(b), we show the analogous quantity for the average logical noise channel21 defined as \({\mathrm{\Lambda }} = \mathop {\sum}

olimits_s p(s){\mathrm{\Lambda }}_s\). This average channel provides an appropriate model for the logical-level noise if the environment has no access to the measured syndrome. This may be relevant, for instance, in the quantum communication settings where noise acts only during transmission of information. Thus one can alternatively define the coherence ratio as

$$P^L/P_{{\mathrm{twirl}}}^L = \frac{{\left\| {{\mathrm{\Lambda }} - {\mathrm{id}}} \right\|_\diamondsuit }}{{\left\| {{\mathrm{\Lambda }}^{{\mathrm{twirl}}} - {\mathrm{id}}} \right\|_\diamondsuit }},$$ (8)

where Λtwirl is the Pauli-twirled version of Λ. A straightforward computation gives \(P^L/P_{{\mathrm{twirl}}}^L = \frac{{\sqrt {\varepsilon ^2 + \delta ^2} }}{\varepsilon }\) where \(\varepsilon = \mathop {\sum}

olimits_s p(s){\mathrm{sin}}^2(\theta _s)\) and \(\delta = \mathop {\sum}

olimits_s p(s){\mathrm{sin}}(2\theta _s)/2\). The coherence ratio of the average logical channel is plotted as a function θ on Fig. 5(b). It provides particularly strong evidence that in the limit of large code distances, coherent physical noise gets converted into incoherent logical noise.