# Solving Inverse Problems for Spectral Energy Distributions with Deep
Generative Networks

Agapi Rissaki
National Technical University of Athens
<EMAIL_ADDRESS>
&Orestis Pavlou
European University Cyprus
<EMAIL_ADDRESS>
&Dimitris Fotakis
National Technical University of Athens
<EMAIL_ADDRESS>
&Vicky Papadopoulou
European University Cyprus
<EMAIL_ADDRESS>
&Andreas Efstathiou
European University Cyprus
<EMAIL_ADDRESS>

###### Abstract

We propose an end-to-end approach for solving inverse problems for a class of
complex astronomical signals, namely Spectral Energy Distributions (SEDs). Our
goal is to reconstruct such signals from scarce and/or unreliable
measurements. We achieve that by leveraging a learned structural prior in the
form of a Deep Generative Network. Similar methods have been tested almost
exclusively for images which display useful properties (e.g., locality,
periodicity) that are implicitly exploited. However, SEDs lack such properties
which make the problem more challenging. We manage to successfully extend the
methods to SEDs using a Generative Latent Optimization model trained with
significantly fewer and corrupted data.

##  1 Introduction

In astrophysics, distributions constructed by energy measurements in different
wavelengths, namely Spectral Energy Distributions (SEDs), are important tools
for studying the physical properties and evolution of astronomical objects.
SEDs can be used for example to determine the luminosity of astronomical
objects, the rate at which galaxies form new stars or the rate at which
supermassive black holes accrete mass to generate energy in quasars [1, 2, 3].
However, the measurement process is prone to statistical (random) as well as
systematic errors, such as background and foreground noise interference, i.e.,
atmospheric absorption and distortion, opaque/obscuring dust, etc. Due to
these factors, as well as technical limitations, such as camera sensor
sensitivity, cooling, resolution, etc, SEDs are collected in scarce, often
incomplete datasets. SEDs are compared to physical models in order to find the
best-fit model(s), which provides an insight into the underlying physical
processes and properties of the target. This highlights the importance of
expanding the range and improving the accuracy of the available data points.
In the literature, computational methods have been widely used to enhance SEDs
and handle the experimental error [4].

In recent years, deep learning has proven to be an important tool for
enhancement of real data and in general for solving inverse problems, where
the goal is to reconstruct or correct a signal given an incomplete and/or
noisy version. Specifically for astronomical data, deep learning techniques
have been used mainly for astronomical imaging, such as deblending images of
galaxies [5] or image enhancement [6]. For SEDs, deep learning has been used
in forward problems such as feature extraction [7], but not inverse problems.
In this paper we use well-known deep learning techniques adjusted
appropriately in order to solve various inverse problems for SEDs.

The method we apply is data-driven and utilizes Deep Generative Models as
learned structural priors. More specifically, models like Variational
AutoEncoders (VAEs) [8] and Generative Adversarial Networks (GANs) [9],
trained on large datasets (most frequently of images) are able to extract
information about the underlying data distribution and generate realistic
samples. These models, once trained, can be used as structural priors for
solving inverse problems [10]. Thus, this methods requires us to train a high-
quality generative network which can model realistic SEDs, with properties
such as high-frequency, irregularity etc. In this paper, we use the Generative
Latent Optimization framework (GLO) [11] to train a deep generative network
suitable for our needs. The framework allows us to train a high-quality
generative network with more flexibility than a VAE and at the same time
offers training efficiency unlike GANs, which are notoriously hard to train.

In order to train a generative network any state-of-the-art method requires a
high-quality large dataset. However, for the case of SEDs these prerequisites
are unrealistic since the measurement procedure contains innate error,
incompleteness and is particularly expensive. To overcome the issue of
erroneous and/or incomplete samples we propose an end-to-end approach: ($1$) a
preprocessing step where we utilize classical computational methods for
enhancement, e.g., iterative PCA [4], ($2$) the deep learning method described
above. Our approach is useful for a variety of inverse problems and it can
mitigate the long-term cost of solving such problems for SEDs. Furthermore, it
is expected to improve overall performance on these problems even with
significant corruption and/or incompleteness by leveraging the powerful
generalization property as well as the robustness of a deep generative
network.

##  2 Method

Suppose, we collect measurements of the form:

$y=Ax^{*}+\eta\,,$ (1)

where $A$ is a measurement matrix and $\eta$ a noise vector. Our goal is to
reconstruct the signal $x^{*}$, given $A$ and $\eta$, thus solve the linear
inverse problem. This formulation usually refers to compressed sensing (where
we assume few measurements taken) but can be also used to model several real-
world problems concerning SEDs.We tackle the problem for the case of SEDs
using a deep generative network as a structural prior [10], a method that has
been successfully applied to natural images.

###  2.1 Building the Generative Network

To build our generative network we use the Generative Latent Optimization
(GLO) framework [11], which allows us to train a relatively large generator
(sufficiently over-parametrized) in order to achieve good generalization [12].
The framework is based on the manipulation of the generator’s latent space as
well as its parameters using a simple reconstruction loss. We use the GLO
framework as an alternative to GANs which are trained via an adversarial
optimization scheme. Unlike GLO, which consists of a simple loss minimization
back-propagated to the latent space, GANs should ideally converge to an
(approximate) equilibrium which is not guaranteed and/or requires excessive
resources [13]. Thus, when training GANs in practice it is common to examine
the generated samples and stop the training when they are satisfactory. In the
case of images this technique can be easily applied, but for SEDs this is not
feasible. In fact, we use the ability to solve inverse problems as a proxy to
evaluate our trained generator.

Let us examine the training procedure more closely. We train the generator
$G\;:\;\mathcal{Z}\rightarrow\mathcal{X}$, where $\mathcal{Z}$ denotes the
latent space and $\mathcal{X}$ the underlying class of SEDs which is described
by the training set $\\{x_{i}\\}_{i=1}^{N}$. Prior to training, we randomly
initialize the latent codes $z_{i}\in\mathcal{Z}$ from a multi-dimensional
Normal distribution and pair them with each of the samples $x_{i}$. During
training, the generator’s parameters and the latent codes
$\\{z_{i}\\}_{i=1}^{N}$ are jointly optimized, as described by (2). The
optimization is driven by a simple reconstruction loss $\mathcal{L}(\cdot)$,
which in our case is Mean Squared Error (MSE).

$\min\limits_{G}\frac{1}{N}\sum_{i=1}^{N}\min\limits_{z_{i}\in\mathcal{Z}}\left[\mathcal{L}(G(z_{i}),x_{i})\right]$
(2)

More specifically, the gradient of the loss function with respect to the
parameters of the generator and the latent code is back-propagated all the way
through the network and to the latent space. This training procedure makes the
latent space more structurally meaningful and suitable for reconstruction. To
promote this feature, we project the latent codes onto the unit sphere during
training [11].

###  2.2 Reconstruction

Given the generative network $G(\cdot)$, the estimated solution of an inverse
problem (1) could be $\hat{x}=G(\hat{z})$ where:

$\hat{z}=\operatorname*{arg\,min}\limits_{z\in\mathcal{Z}}\frac{1}{m}||AG(z)-y||^{2}_{2}$
(3)

In other words, we (approximately) optimize the latent code $\hat{z}$ such
that the corresponding signal $\hat{x}$ matches the measurements $y$. We
optimize $\hat{z}$ by back-propagating the gradient of the reconstruction loss
through $G(\cdot)$ [10]. Note that we have to project $z$ onto the unit
sphere, similarly to training. In a different approach [10], instead of
explicitly projecting $z$ onto the unit sphere, we can apply a regularization
to implicitly restrict $z$ as follows:

$\hat{z}=\operatorname*{arg\,min}\limits_{z\in\mathcal{Z}}\frac{1}{m}||AG(z)-y||^{2}_{2}+R(z)\,,$
(4)

where $R(z)=\lambda||z||^{2}_{2}$ is the regularization term and $\lambda$ a
balance hyperparameter.

##  3 Experiments

###  3.1 Data

We apply our approach to Sloan Digital Sky Survey (SDSS) spectra
111https://www.sdss.org/dr12/spectro/. Specifically, we use the preprocessed
SDSS Corrected Spectra dataset offered by the astroML library [14]. The
dataset contains SEDs for $4000$ galaxies moved to restframe, preprocessed
with iterative PCA and resampled to $1000$ wavelengths
($3000-8000\mbox{\AA}$). Although the preprocessing is imperfect, leading to
outlier values, our deep learning approach still displays great performance
due to its robustness. Notice that the original SDSS dataset consists of
innately incomplete and/or corrupted SEDs, due to the nature of the
measurement process. Thus, the original SEDs cannot be used directly for
evaluation purposes because we would lack the ground truth. Instead, we
consider part of the corrected SEDs produced by the preprocessing step as test
data ($10\%$ of the preprocessed dataset), which we use for comparisons in
Section 3.3.

###  3.2 Training

We train a Feed-forward neural network with $7$ hidden layers and leakyReLU
activations (except for the output layer). We use $90\%$ of the preprocessed
dataset as our training data and train our network for $10000$ epochs with
batches of $64$ spectra. We use Adam optimization [15] with learning rate
$0.1$ for the network’s parameters and $0.01$ for the latent codes as well as
1d-batch normalization to accelerate the training procedure [16]. We choose a
simple Mean Squared Error (MSE) as our loss function and we also apply weight
decay to avoid overfitting.

Our spectra consist of measurements for $1000$ wavelengths. We choose $50$
dimensions for the latent space, which are sufficient for the representation
and allow for efficient training and reconstruction. For the reconstruction,
we limit the optimization procedure to $1000$ epochs and choose a
configuration similar to training. The project is developed using PyTorch
[17].

###  3.3 Results

(a) Inpainting problem: measurements are missing in a continuous window.

(b) Super-resolution problem: randomly selected measurements are missing.

Figure 1: The original SED signals and their reconstruction for $40\%$ missing
information in inpainting (top) and super-resolution (bottom) settings.

(a)

(b)

Figure 2: MSE of reconstruction for $100$ randomly selected signals on: (a)
inpainting, for different levels of missing information (%). (b) denoising,
for different levels of added noise ($l_{2}$-norm).

We evaluate our approach, both qualitatively and quantitatively, for different
inverse problems, by artificially injecting realistic corruption and/or
incompleteness to our test data. For the qualitative evaluation (Figure 1), we
examine the performance of our algorithm on inverse problems with missing
information. More specifically, the missing information corresponds to either
a continuous window of missing values (inpainting) or randomly chosen values
throughout the entire signal (super-resolution). For each problem we randomly
select four SED signals from our test set, then apply the appropriate masking
and produce a reconstruction. The missing information in both cases is chosen
to be $40\%$ of the total number of measurements that compose each SED. We can
see that for both problems, the reconstruction closely follows the trajectory
of the original signal and in most cases predicts the high-frequency changes
and large spikes.

In Figure 2, we examine quantitatively the performance of our algorithm on the
problems of (a) inpainting and (b) denoising (that is removing added noise
drawn by a normal distribution). For each configuration, we show the
reconstruction MSE of $100$ randomly selected SEDs (excluding measurements
that fall outside $1.5$ times the interquartile range). In Figure 2(a), we
examine the performance for different levels of missing information and
compare between SEDs drawn from test and training data. In both cases the MSE
of the vast majority of signals is particularly low for up to $40\%$ of
missing information. For reasonable percentages of missing information the
performance on test data is on par with the training data. For a sufficient
proportion of the examined signals, this trend persists even for larger
percentages (see median values). Given that our generative network was
optimized to represent the training data, this shows a considerable
generalization capability, which is crucial for the effectiveness of our
approach. In Figure 2(b), we examine the performance for different levels of
added noise and compare between our reconstruction methods, the explicit
projection (eq. 3) and the regularization (eq. 4). We can see that for all
levels of added noise the MSE is particularly low, which indicates notable
performance on denoising. Furthermore, when regularization is utilized we
observe better error concentration, which can be attributed to the flexibility
it offers to the reconstruction process.

##  4 Conclusion and Future Work

We presented an end-to-end deep learning solution for various inverse problems
concerning Spectral Energy Distributions (SEDs). Our approach relies on a deep
generative network, tailored to the particular properties of SEDs, as a
structural prior leveraging its generalization capability. Our preliminary
results show promising performance on realistic inverse problems. We are
working to extend this project to diverse and more demanding SED families
e.g., for different parts of the spectrum. Another future direction involves
transfer learning techniques, as well as ensemble learning in order to extend
our approach to data that are even more incomplete. Finally, we could augment
our method using bi-directional training in order to simultaneously extract
information regarding the astrophysical objects we study. This idea draws from
recent research on invertible neural networks for inverse problems [18].

## Broader Impact

This project will have broad impact in the effort to interpret the SEDs which
will be made available with a number of current and future ground-based and
space missions such as LSST, Euclid, JWST and SPICA. Although the examples
used in this work concentrate on the optical part of the spectrum, the same
method can also be used on SEDs which cover the whole spectrum of galaxies
from the ultraviolet to the radio. Such studies of the complete SEDs of
galaxies are now recognized as essential for a complete understanding of the
processes that control galaxy formation and evolution (e.g. [3, 19]).

## References

  * [1] Andreas Efstathiou and Michael Rowan-Robinson.  Dusty discs ih active galactic nuclei.  Monthly Notices of the Royal Astronomical Society, 273(3):649–661, 1995.
  * [2] Andreas Efstathiou, Michael Rowan-Robinson, and Ralf Siebenmorgen.  Massive star formation in galaxies: radiative transfer models of the uv to millimetre emission of starburst galaxies.  Monthly Notices of the Royal Astronomical Society, 313(4):734–744, 2000.
  * [3] Michael Rowan-Robinson and et al.  Spectral energy distributions and luminosities of galaxies and active galactic nuclei in the spitzer wide-area infrared extragalactic (swire) legacy survey.  The Astronomical Journal, 129:1183–1197, March 2005.
  * [4] Jakob Walcher, Brent Groves, Tamás Budavári, and Daniel Dale.  Fitting the integrated spectral energy distributions of galaxies.  Astrophysics and Space Science, 331(1):1–51, Aug 2010.
  * [5] Alexandre Boucaud, Marc Huertas-Company, Caroline Heneka, Emille E O Ishida, Nima Sedaghat, Rafael S de Souza, Ben Moews, Hervé Dole, Marco Castellano, Emiliano Merlin, and et al.  Photometry of high-redshift blended galaxies using deep learning.  Monthly Notices of the Royal Astronomical Society, 491(2):2481–2495, Dec 2019.
  * [6] Francois Lanusse, Peter Melchior, and Fred Moolekamp.  Hybrid physical-deep learning model for astronomical inverse problems, 2019.
  * [7] Frontera-Pons, J., Sureau, F., Bobin, J., and Le Floc´h, E.  Unsupervised feature-learning for galaxy seds with denoising autoencoders.  A&A, 603:A60, 2017.
  * [8] Diederik P. Kingma and Max Welling.  An introduction to variational autoencoders.  CoRR, abs/1906.02691, 2019.
  * [9] Ian J. Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio.  Generative adversarial networks, 2014.
  * [10] Ashish Bora, Ajil Jalal, Eric Price, and Alexandros G. Dimakis.  Compressed sensing using generative models.  In Proceedings of the 34th International Conference on Machine Learning - Volume 70, ICML’17, pages 537–546. JMLR.org, 2017.
  * [11] Piotr Bojanowski, Armand Joulin, David Lopez-Paz, and Arthur Szlam.  Optimizing the latent space of generative networks.  2017\.
  * [12] Behnam Neyshabur, Srinadh Bhojanapalli, David Mcallester, and Nati Srebro.  Exploring generalization in deep learning.  In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett, editors, Advances in Neural Information Processing Systems 30, pages 5947–5956. Curran Associates, Inc., 2017.
  * [13] Frans A. Oliehoek, Rahul Savani, Jose Gallego-Posada, Elise van der Pol, and Roderich Groß.  Beyond local nash equilibria for adversarial networks.  CoRR, abs/1806.07268, 2018.
  * [14] J.T. Vanderplas, A.J. Connolly, Ž. Ivezić, and A. Gray.  Introduction to astroml: Machine learning for astrophysics.  In Conference on Intelligent Data Understanding (CIDU), pages 47–54, Oct 2012.
  * [15] Diederik Kingma and Jimmy Ba.  Adam: A method for stochastic optimization.  International Conference on Learning Representations, 12 2014.
  * [16] Sergey Ioffe and Christian Szegedy.  Batch normalization: Accelerating deep network training by reducing internal covariate shift.  In Proceedings of the 32nd International Conference on International Conference on Machine Learning - Volume 37, ICML’15, page 448–456. JMLR.org, 2015.
  * [17] Adam Paszke, Sam Gross, Soumith Chintala, Gregory Chanan, Edward Yang, Zachary DeVito, Zeming Lin, Alban Desmaison, Luca Antiga, and Adam Lerer.  Automatic differentiation in pytorch.  2017\.
  * [18] Lynton Ardizzone, Jakob Kruse, Sebastian J. Wirkert, Daniel Rahner, Eric W. Pellegrini, Ralf S. Klessen, Lena Maier-Hein, Carsten Rother, and Ullrich Köthe.  Analyzing inverse problems with invertible neural networks.  CoRR, abs/1808.04730, 2018.
  * [19] Raphael Shirley, Yannick Roehlly, Peter D. Hurley, Veronique Buat, María del Carmen Campos Varillas, Steven Duivenvoorden, Kenneth J. Duncan, Andreas Efstathiou, Duncan Farrah, Eduardo González Solares, Katarzyna Malek, Lucia Marchetti, Ian McCheyne, Andreas Papadopoulos, Estelle Pons, Roberto Scipioni, Mattia Vaccari, and Seb Oliver.  HELP: a catalogue of 170 million objects, selected at 0.36-4.5 $\mu$m, from 1270 deg2 of prime extragalactic fields.  Monthly Notices of the Royal Astronomical Society, 490(1):634–656, November 2019.


# Measurement based estimator scheme for continuous quantum error correction

Sangkha Borah<EMAIL_ADDRESS>Okinawa Institute of Science and
Technology Graduate University, Onna-son, Okinawa 904-0495, Japan  Bijita
Sarma  Okinawa Institute of Science and Technology Graduate University, Onna-
son, Okinawa 904-0495, Japan  Michael Kewming  Department of Physics, Trinity
College Dublin, Dublin 2, Ireland  Fernando Quijandría  Okinawa Institute of
Science and Technology Graduate University, Onna-son, Okinawa 904-0495, Japan
Gerard J. Milburn  Centre for Engineered Quantum Systems, School of
Mathematics and Physics, University of Queensland, QLD 4072 Australia  Jason
Twamley  Okinawa Institute of Science and Technology Graduate University,
Onna-son, Okinawa 904-0495, Japan

(August 27, 2024)

###### Abstract

Canonical discrete quantum error correction (DQEC) schemes use projective von
Neumann measurements on stabilizers to discretize the error syndromes into a
finite set, and fast unitary gates are applied to recover the corrupted
information. QEC based on continuous measurement (CQEC), in principle, can be
executed faster than DQEC and can also be resource efficient. However, CQEC
requires meticulous filtering of noisy continuous measurement data to reliably
extract error syndromes on the basis of which errors could be detected. In
this work, we show that by constructing a measurement-based estimator (MBE) of
the logical qubit to be protected, which is driven by the noisy continuous
measurement currents of the stabilizers, it is possible to accurately track
the errors occurring on the physical qubits in real-time. We use this MBE to
develop a novel continuous quantum error correction (MBE-CQEC) scheme that can
protect the logical qubit to a high degree, surpassing the performances of
DQEC, and also allows QEC to be conducted either immediately or in delayed
time with instantaneous feedbacks.

quantum error correction; QEC; CQEC; continuous measurement; weak measurement;
quantum computing; fault-tolerant

Generally speaking, quantum error correction (QEC) is a solution to preserve a
quantum state from environmental decoherence, and is essential for achieving
fault-tolerant quantum computation, cryptography and quantum communications
Nielsen and Chuang (2010); Shor (1995); Steane (1996); Djordjevic (2012);
Gertler  _et al._ (2021). The essence of QEC is to redundantly encode the
quantum information of a qubit in several entangled qubits which collectively
form a so called logical qubit that exhibits a longer lifetime than individual
component physical qubits. The logical qubit lies in a two-dimensional
subspace of the Hilbert space of the physical qubits, and the interaction
between the qubits and their environment cause an orthogonal rotation of the
collective state of the physical qubits out of this subspace. By
simultaneously measuring a set of operators, this rotation can be detected and
corrected without changing the encoded logical qubit state. Such operators are
selected parity operators in the Pauli group, called the stabilizer
generators, the eigenvalues of which are known as the error syndromes Shor
(1995); Steane (1996); Gottesman (1997). In canonical QEC methods, which we
will refer to as discrete quantum error correction (DQEC), these operators are
measured projectively and reveal the discrete error syndromes and this
classical information is subsequently used to correct qubit errors via fast
unitary gates Devitt  _et al._ (2013); Reed  _et al._ (2012). To achieve fault
tolerant quantum computation, it is important that the probability of an
erroneous rotation of the logical qubit, is below a critical threshold value
Knill  _et al._ (1998); Girvin (2021). Over the few years, DQEC has been
demonstrated experimentally in various platforms such as in ion traps
Schindler  _et al._ (2011); Linke  _et al._ (2017); Negnevitsky  _et al._
(2018), diamond NV centers Cramer  _et al._ (2016), and superconducting
circuits Kelly  _et al._ (2015); Ristè  _et al._ (2015); Ofek  _et al._
(2016); Arute et al. (2019); Andersen  _et al._ (2020); Stricker  _et al._
(2020); Chen et al. (2021); de Neeve  _et al._ (2022).

A less explored alternative to DQEC is to utilize continuous quantum error
correction (CQEC) methods, with the first few studies dating back to the early
2000s, co-authored by one of the authors of this article Ahn  _et al._ (2002,
2003); Sarovar  _et al._ (2004); Sarovar and Milburn (2005); Wiseman and
Milburn (2014). In CQEC, instead of discrete projective measurements of the
stabilizer generators, these generators are continuously and weakly measured
and a quantum feedback control Hamiltonian is used for continuous error
correction. One early seminal result demonstrated how single bit flip errors
can be corrected using CQEC provided one knows the conditional moments of the
error syndromes, which alas, is not practically feasible Ahn  _et al._ (2002).
This is because when we perform a weak measurement on the stabilizers, we no
longer have the direct access to the exact syndrome signals, since they are
now masked by the measurement noise that is necessarily added to the measured
signal. Likewise, in previous research along these directions, the continuous
measurement records of the syndrome measurements were smoothed with various
filter kernels so that the exact signal of the error syndromes could be
extracted from the noisy measurement records. Expectedly, this performed
suboptimally given that it is not possible to isolate the signal from noise
for any realistic situation Sarovar  _et al._ (2004); Mabuchi (2009); Cardona
_et al._ (2019); Mohseninia  _et al._ (2020); Atalaya  _et al._ (2021);
Livingston  _et al._ (2022). Following a similar strategy for filtering noisy
data, CQEC has been demonstrated experimentally for the first time in a
superconducting circuit platform last year Livingston  _et al._ (2022).

Unlike DQEC, which relies on projective measurements, CQEC eliminates the need
to use ancilla qubits to measure the stabilizer operators by weakly measuring
the physical qubits, and allows faster measurements and error detection,
thereby greatly reducing the likelihood of undetected errors Wiseman and
Milburn (2014). Furthermore, CQEC can be advantageous when the control
resources are limited and the performance of the feedback can be improved by
optimizing the operational parameters Sarovar  _et al._ (2004). However, as
mentioned above, previous methods to perform CQEC suffered from their
inability to correctly identify when errors occur as the continuous
measurement signals necessarily contain noise Sarovar  _et al._ (2004);
Atalaya  _et al._ (2021); Livingston  _et al._ (2022). In this work we show
how to overcome this and push the capabilities of the CQEC far beyond the
abilities of the standard DQEC. To achieve this we equip the CQEC with a real-
time Measurement Based Estimator (MBE), which can detect and correct errors
rapidly without filtering or smoothing of the measured data. We call this
scheme of continuous error correction as MBE-CQEC. This gives a practical
solution for realizing the theoretical proposal of Ahn et al. Ahn  _et al._
(2002), without using filters for signal processing of the measurement records
Sarovar  _et al._ (2004); Livingston  _et al._ (2022). Finally, we show that
the corrective action need not be instantaneous, but can be delayed and
corrected whenever required, a feature we call delayed error correction (DEC).

Figure 1: The proposed protocol for CQEC using the measurement based $\cal
E$stimator (MBE) scheme. The $\cal R$eal system (left) consists of a logical
qubit comprising three physical qubits with an encoded unknown quantum state
$|\psi^{\cal R}\rangle_{L}=\alpha|000\rangle+\beta|111\rangle$, which we want
to protect from bit-flip errors. The $\cal E$stimator (right) is a simulation
[computer] of the stochastic dynamics of the $\cal R$eal system modelled
similarly but with a different initial quantum state $|\psi^{\cal
E}\rangle_{L}=\alpha^{\prime}|000\rangle+\beta^{\prime}|111\rangle$, where
$\alpha^{\prime}\neq\alpha$ and $\beta^{\prime}\neq\beta$ and where
$[\alpha,\beta](\alpha^{\prime},\beta^{\prime})$ are [unknown]known. For
generality, we will initialize the $\cal E$stimator state at: $|\psi^{\cal
E}\rangle_{L}=1|000\rangle$. One executes separate continuous measurements of
the three syndrome generators on the $\cal R$eal system and the resulting time
varying classical signals $(dQ_{ZZI}(t),dQ_{IZZ}(t),dQ_{ZIZ}(t))$ drive the
stochastic dynamics of the $\cal E$stimator quantum dynamics. Although the
$\cal E$stimator cannot learn about the unknown encoded quantum state, any
errors appearing in the $\cal R$eal system are faithfully reproduced in the
$\cal E$stimator. By monitoring the appearance of bit-flips in the $\cal
E$stimator one applies a feedback Hamiltonian $F(t)$ which applies the
appropriate correction in a continuous manner with control strengths
$\lambda_{j}$ on the individual physical qubits in the $\cal R$eal system.
Figure 2: [(a) - (c)] The time evolution of the conditional means of the three
error syndromes for the $\cal R$eal system (in blue, linewidth slightly
increased for visibility) and the $\cal E$stimator (orange) under the MBE
scheme (without error correction) that explains the essence of the protocol of
the proposed CQEC scheme. Essentially, the MBE scheme allows us to use a
computer simulation driven by the continuous measurement currents of the $\cal
R$eal system to perform real-time quantum error tracking that permits real
time QEC (d) Instead of using the conditional means of the syndromes we find
that the MBE has access to the full real-time effects of errors on each
simulated physical qubit and this information can permit us to perform error
correction. Information about the evolution of the Pauli-$Z_{q}$ operator for
the physical qubit $q$, $\langle Z_{q}(t)\rangle$, scaled by its initial
absolute value $|\langle Z_{q}(0)\rangle|$ for one of the physical qubits of
the $\cal E$stimator (orange) is compared, as an example, to the corresponding
evolution of the same of the $\cal R$eal system (blue). (e) The absolute
values of the instantaneous differences $\Delta\langle Z_{q}(t)\rangle=\langle
Z_{q}(t)\rangle-\langle Z_{q}(0)\rangle$ scaled by their initial values
$\langle Z_{q}(0)\rangle$ follow one another for the respective qubits of the
$\cal R$eal and the $\cal E$stimator. (f) The fidelity of the particular
physical qubit, ${\cal F}_{q}$ (red) as well as of the logical qubit, ${\cal
F}$ (green) with respective to the initial state to be preserved is shown for
the bit-flip errors demonstrated in [(a) - (e)]. Thus, the change in fidelity
of the physical qubits can be directly monitored by computing the values of
$|\langle Z_{q}(t)\rangle-\langle Z_{q}(0)\rangle|$ for each of the qubits of
the $\cal E$stimator, which sets the bit-flip error detection protocol of the
proposed MBE-CQEC scheme. (g) The performance of the MBE-CQEC scheme is
showcased in terms of the logical qubit fidelity for a single trajectory to
show how the errors are corrected once they are detected, based on the above
error detection protocol; also showing the fidelities of each physical qubits,
in (i), and the feedbacks on the individual qubits to correct the corrupted
information at appropriate times, in (j). For these analyses, we set the
initial logical qubit state as $|\psi^{\cal R}\rangle_{L}=|111\rangle$ to
maximize the contrast of fidelity drop under bit-flip error. For these plots,
we have used $\kappa/\gamma=800$ and $\lambda/\gamma=600$.

The generalized MBE is constructed as follows. Let us consider that the
internal dynamics of this $\cal R$eal system is described by the Hamiltonian
$H$, and its conditional density matrix to be, $\rho^{\cal R}_{c}(t)$, under
continuous measurement of the operator $A^{\mathcal{R}}=A$. This can be
described by the quantum stochastic master equation (SME) Wiseman and Milburn
(2014); Diósi  _et al._ (2006); Borah  _et al._ (2021),

$\displaystyle d\rho^{\cal R}_{c}(t)=$
$\displaystyle-i[H,\rho^{\mathcal{R}}_{c}(t)]dt+\gamma\mathcal{D}[c]\rho^{\cal
R}_{c}(t)dt+\kappa\mathcal{D}[A]\rho^{\cal R}_{c}(t)dt$ $\displaystyle+$
$\displaystyle\sqrt{\kappa\eta}\mathcal{H}[A]\rho^{\cal R}_{c}(t)\,dW^{\cal
R}(t).$ (1)

Here, $A=\mathcal{A}/\mathcal{A}_{0}$ a dimensionless operator corresponding
to the physical observable $\mathcal{A}$ scaled suitably by $\mathcal{A}_{0}$
to make it dimensionless, and is known as the measurement operator, which is
measured with a measurement rate of $\kappa$. The first term on the RHS is the
coherent evolution of the system. The second term on the RHS gives the
environmental decoherence at a rate $\gamma$ with the collapse operator $c$,
and the third term gives the measurement backaction due to the measurement of
$A$, where $\mathcal{D}[A]\rho=A\rho
A^{\dagger}-\frac{1}{2}(A^{\dagger}A\rho+\rho A^{\dagger}A)$ represents the
decoherence superoperator. The last term is the stochastic diffusion term with
$dW(t)$ being the Wiener noise increments. $\mathcal{H}$ is a superoperator
given by, $\mathcal{H}[A]\rho=A\rho+\rho
A^{\dagger}-\rho\mathrm{tr}[A\rho+\rho A^{\dagger}]$, and $\eta\in(0,1]$ is
the measurement efficiency. The measurement records, $dQ^{\mathcal{R}}(t)$ are
given by the summation of the conditional mean of the measurement operator and
the corresponding random noise component of the measurement,

$\displaystyle dQ^{\mathcal{R}}(t)=\langle
A^{\mathcal{R}}(t)\rangle_{c}dt+\frac{1}{\sqrt{4\kappa\eta}}{dW^{\mathcal{R}}(t)}.$
(2)

The dynamics of the $\cal E$stimator is modelled following the modified SME,

$\displaystyle d\rho^{\cal E}_{c}(t)=$ $\displaystyle-i[H,\rho^{\cal
E}_{c}(t)]dt+\gamma\mathcal{D}[c]\rho^{\cal
E}_{c}(t)dt+\kappa\mathcal{D}[A]\rho^{\cal E}_{c}(t)dt$ $\displaystyle+$
$\displaystyle{2\kappa\eta}\left[dQ^{\cal R}(t)-\langle A^{\cal
E}(t)\rangle_{c}dt\right]\mathcal{H}[A]\rho^{\cal E}_{c}(t).$ (3)

In essence, the noise of the $\cal E$stimator is modelled based on the noisy
measurement records of the $\cal R$eal system. In the context of the present
work for correcting bit-flip errors of the three-qubit code, we would have,
$c=\\{XII,IXI,XIX\\}$ and $A=\\{ZZI,IZZ,ZIZ\\}$.

The proposed MBE-CQEC scheme is shown schematically in Fig. 1. The $\cal R$eal
system (left) with the initial state $\rho^{\cal R}$ consists of a logical
qubit comprising three physical qubits we take to be a system in the
laboratory, where one continuously measures the stabilizer operators $ZZI,IZZ$
and $ZIZ$, where the third stabilizer operator is redundant and can be omitted
in principle. We consider an $\cal E$stimator of the system with the initial
state $\rho^{\cal E}$, as a numerical simulator on a fast computer (on the
right in Fig. 1), whose purpose is to detect the errors on the qubits
occurring in the $\cal R$eal system based on the real time measurement
records. The $\cal E$stimator also acts as a controller to apply an
appropriate feedback Hamiltonian to the $\cal R$eal system:
$F(t)=\lambda_{1}(t)XII+\lambda_{2}(t)IXI+\lambda_{3}(t)IIX$, where $X$
denotes a Pauli-$X$ operator, and $\lambda_{q}(t)$’s are the feedback
strengths.

At the heart of the MBE-CQEC lies the fact that for the measurement of the
stabilizer operators, the $\cal E$stimator can perfectly follow the
conditional means of the stabilizers ($\langle ZZI\rangle_{c}(t),\langle
IZZ\rangle_{c}(t)$ and $\langle ZIZ\rangle_{c}(t)$) when it is fed the
continuous, albeit noisy syndrome measurement records
($dQ_{ZZI}(t),dQ_{IZZ}(t),dQ_{ZIZ}(t)$). In Fig. 2[(a) - (c)], we show these
for the $\cal R$eal (blue, with slightly thicker lines for visibility) and the
$\cal E$stimator (orange) for a single quantum trajectory, where the $\cal
E$stimator dynamics is driven by the syndrome measurement currents of the
$\cal R$eal system. The perfect match of these values entails the power of the
approach we are going to formulate for QEC, which offers a novel strategy to
extract the conditional means of the error syndromes using continuous
measurement instead of projective von Neumann measurement and without any
signal filtering. This would allow CQEC to operate at the optimum level of
performance using the error syndromes directly while outperforming the DQEC
protocols Ahn  _et al._ (2002); Sarovar  _et al._ (2004); Wiseman and Milburn
(2014); Nielsen and Chuang (2010), thus making it a perfect marriage between
DQEC and CQEC techniques.

Figure 3: (a) The net fidelity of the logical qubit averaged over an ensemble
of at least 100 trajectories under the proposed MBE-CQEC scheme for different
choices of measurement strength, $\kappa$ in the units of the qubit bit flip
error rate $\gamma$ are shown with the feedback strengths $\lambda=\kappa$,
for reasons demonstrated in (b). The time evolutions up to 10 lifetimes of the
qubit ($10/\gamma$) are corrected. Also shown are the fidelities for the DQEC
(cyan) and one (violet) physical qubit errors for comparison. On the left of
(a) the zoomed-in portion within $t=1/\gamma$ is shown. While DQEC fails
completely beyond a few lifetimes of the qubit (one qubit error), MBE-CQEC
protocol outperforms it significantly. (b) The performance of CQEC scheme for
different choices of the feedback strength, $\lambda$ for a fixed
$\kappa/\gamma=800$. It shows that $\lambda\sim\kappa$ is a decent choice for
overall high fidelity in long time limit. (c) The performance of the scheme
for non-ideal choices of measurement efficiencies, $\eta$, showing that the
drop in fidelity relative to the case of ideal measurement efficiency,
$\eta=1$ is not significantly large for reasonable values of $\eta$. Figure 4:
(a) and (b) demonstrate the delayed error correction (DEC) allowed by the MBE-
CQEC scheme, where the error correction can be deferred until a later time. In
these simulations, we do not apply any error correction till $t=0.9/\gamma$,
after which the errors are detected based on the proposed error detection
scheme and faithfully corrected. (a) An example trajectory shows how the error
is corrected at $t=0.9/\gamma$. (b) The same as (a) but averaged over many
trajectories, which shows how the overall fidelity drops until the errors are
corrected. [(c) - (f)] Explanation of the fidelity drop with the CQEC protocol
based on the MBE scheme: (c) the fidelity variation in time without CQEC
($\lambda=0$) is shown for a particular quantum trajectory for
$\kappa/\gamma=800$; (d) the same when used for CQEC using $\lambda=\kappa$,
that reveals that the error at $t\sim 0.2/\gamma$ could not be corrected
fully; (e) the same as (d) but for $\lambda=5\kappa/4$, for which the error
correction is even worse at that particular instance; (f) the errors getting
perfectly corrected for $\lambda=3\kappa/4$.

While the perfect computation of the real time conditional error syndromes
with the proposed MBE scheme provides optimal error correction with continuous
measurements, we will show in the following that we can use yet another error
detection protocol that depends on the time evolution of the Pauli-$Z$
operator of the $\cal E$stimator physical qubits $q$, conditioned on the
measurement records of the $\cal R$eal system. This protocol will have the
benefit of performing CQEC with a significant time delay solely based on
measurement data obtained from the real qubit measurements, and will have
additional benefits, which we will discuss in subsequent sections. In Fig.
2(d), we compare, the time evolution of the $\langle Z_{q}(t)\rangle$ (only
one of the physical qubits is shown as an example) of the instantaneous
density matrix of the $\cal R$eal, $\rho^{\cal R}(t)$ and $\cal E$stimator,
$\rho^{\cal E}(t)$ where the $\cal E$stimator is evolved according to the MBE
scheme discussed above. As expected, the expectation value $\langle
Z_{q}(t)\rangle$ for the $\cal R$eal system (in blue) and the $\cal E$stimator
(in orange) exhibit different values, as the initial states are different.
However, when normalized by their absolute values before measurement, $\langle
Z_{q}(0)\rangle$, they undergo similar changes. As shown in Fig. 2(e), the
instantaneous differences $\Delta\langle Z_{q}(t)\rangle=\langle
Z_{q}(t)\rangle-\langle Z_{q}(0)\rangle$ scaled by their initial values
$\langle Z_{q}(0)\rangle$ follow one another for the respective qubits of the
$\cal R$eal and the $\cal E$stimator. In Fig. 2(f), the fidelity of that
particular physical qubit $q$, ${\cal
F}_{q}(t)=\langle\psi(0),\mathrm{tr}_{q}(\rho(t))\psi(0)\rangle$ (red), where
$\mathrm{tr}_{q}(\rho(t))$ is the partial trace of the logical qubit density
matrix on the $q$th Hilbert space, along with the codespace fidelity of the
logical qubit, ${\cal F}(t)=\langle\psi^{L}(0),\rho(t)\psi^{L}(0)\rangle$
(green) are shown, from which, by comparing with Fig. 2(e), it is observed
that the drop in fidelity of the individual qubits are directly related in a
one to one fashion to $|\Delta\langle Z_{q}(t)\rangle/|\langle
Z_{q}(0)\rangle|$ of the $\cal R$eal/$\cal E$stimator systems. This fact can
be utilized to detect flipping of the qubits deterministically, as an error in
a qubit would mean simply $|\Delta\langle Z_{q}(t)\rangle|>\varepsilon|\langle
Z_{q}(0)\rangle|$ on the $\cal E$stimator, where $\varepsilon=1.05$ is a small
tolerance to error detection. Naturally, $\varepsilon=2$ would signify a
complete flip, while $\varepsilon=0$ would signify a complete preservation of
the state. For the $\cal E$stimator, we can fix the initial logical state of
the qubit at the reset conditions, $|\psi\rangle_{L}^{\cal E}=|000\rangle$ for
simplicity and generality. For more details of the error detection protocol,
see Methods.

Using the above approach of error detection, we next go on to the
implementation of the MBE-CQEC protocol. In Fig. 2(g), we demonstrate our CQEC
scheme by applying it to a quantum trajectory evolved over one lifetime of a
physical qubit ($t=1/\gamma$). It can be seen how well the scheme works in
correcting the bit-flip errors, quickly restoring the logical qubit after an
error is detected, as detected by the error syndromes in Fig. 2(a)-(c). In
Fig. 2(h), the individual fidelities of the physical qubits are shown, and the
times of the applied feedbacks on respective qubits are shown in (i). There is
hardly any drop in fidelity for this particular trajectory under MBE-CQEC
within this time span.

In order to evaluate the performance of the scheme correctly in a statistical
sense, we apply it to an ensemble of quantum trajectories and average over it,
the results of which are shown in Fig. 3 in terms of average codespace
fidelity, $\bar{\cal F}=1/N\sum_{j=1}^{N}\mathcal{F}_{i}$ of the logical
qubit, where $N$ represents the number of trajectories for the ensemble
average, and $\mathcal{F}_{i}$ is the codespace fidelity of the $i$th
trajectory, as defined earlier. While the feedback strengths $\lambda$’s can
be tuned in principle within a trajectory, we have used a constant value,
$\lambda_{0}\sim\kappa$ for simplicity, which means that $\lambda$ can only
take the values of $0$ or $\lambda_{0}$. In Fig. 3(a), we show how higher
values of the continuous measurement rate $\kappa$ yields an overall higher
fidelity in the long time limit for the encoded state. The time limit
considered is 10 times the single qubit lifetime ($10/\gamma$). We have found
that by choosing a feedback strength of $\lambda\sim\kappa$ is a good choice
that leads to an overall higher fidelity when averaged over hundreds of
trajectories. The performance of DQEC is also shown for comparison, which
shows that the MBE-CQEC scheme outperforms DQEC for $\kappa>10\gamma$. Another
useful measure that is typically checked and useful for fault-tolerance is the
so-called one qubit error fidelity, shown as a solid line in violet, which
saturates at ${1/2}$ in the long time limit. DQEC fails completely beyond
about $t\sim\pi/\gamma$, whereas with the MBE-CQEC scheme, the infidelity is
maintained within $1-4\%$ for higher values of $\kappa$ over 10 lifetimes of a
physical qubit. The zoomed in view of the plot, focussing on the performance
within 1 lifetime of a physical qubit, is shown on the left of Fig. 3(a). The
final fidelities for $\kappa=1000\gamma$ and $800\gamma$ are respectively
$99.857\%$ and $99.578\%$ at $t=1/\gamma$. Thus, it is not necessarily useful
to keep pushing the value of $\kappa$ any further, as the above fidelities are
not significantly different in magnitude. Recent developments of quantum
technologies, particularly those based on superconducting hardwares, allow
experimentalists to go beyond the conventional regimes of weak coupling Minev
_et al._ (2019); Blais  _et al._ (2021); Livingston  _et al._ (2022). In this
spirit, we will consider $\kappa/\gamma=800$ for further analyses in the rest
of the paper. In Fig. 3(b), we evaluate the proposed CQEC scheme for different
choices of $\lambda/\gamma$ while keeping $\kappa/\gamma=800$. It reveals that
$\lambda\sim\kappa$ is a relatively decent choice to preserve overall
fidelities in the long time limit. Next, we evaluate the performance of the
protocol for inefficient measurements ($\eta<1$), shown in Fig. 3(c) relative
to the ideal case, $\eta=1$. It is observed that the scheme is fairly robust
for $\eta>0.5$, and the drop of fidelity is not huge.

Now, we will discuss a distinct feature of the proposed MBE-CQEC scheme
facilitated by the new error-detection/correction scheme discussed above. We
find that we can delay the correction until some later time when it is more
convenient. We call this feature delayed error correction (DEC). This is
facilitated by the proposed error detection scheme based on computation of the
Pauli-$Z$ operator on the physical qubit $q$ of the $\cal E$stimator model
under the MBE scheme. This allows to keep a track the changes of $|\langle
Z_{q}(t)\rangle-\langle Z_{q}(0)\rangle|/|\langle Z_{q}(0)\rangle|$ on the
$\cal R$eal system qubits indirectly by monitoring the same on the $\cal
E$stimator qubits (see discussions at the beginning, and Methods). For
instance, within a trajectory of total time of $1/\gamma$, we can abstain from
doing any error correction until a later time, say $t=0.9/\gamma$. Based on
the measurement records of the $\cal R$eal system, the $\cal E$stimator can
follow the errors that happened on the qubits, and the errors can be
rightfully detected and corrected using the proposed MBE-CQEC protocol, shown
for an example trajectory in Fig. 4(a). The same for an ensemble of
trajectories is shown in Fig. 4(b). This shows how the fidelity drops
significantly to a very low value without error correction, but how the error
is corrected instantly at $t=0.9/\gamma$ just monitoring the $\cal E$stimator
$\langle Z(t)\rangle$ on individual qubits.

Finally, we will address the long time fidelity drop issue despite error
correction using our MBE-CQEC code, and possibilities of using fine-tuned
feedback controls. We have found that the choice of the feedback strength
$\lambda$ plays a key role in maintaining codespace fidelity for longer
durations. To demonstrate it, we first simulate a trajectory that undergoes
bit-flip errors as shown in Fig. 4(c) and save the noise signal, in order to
test the effect of different feedback strengths on exactly the same dynamics.
For this simulation, we use $\kappa/\gamma=800$ as before. Now, we use our
CQEC scheme with $\lambda=\kappa$, for which we see that the fidelity could
not be preserved beyond $t\sim 0.2/\gamma$, shown in Fig. 4(d). Applying the
same for $\lambda=5\kappa/4$ leads to further drop in fidelity (Fig. 4(e)) at
that point. This can be corrected perfectly, however, with $\lambda=3\kappa/4$
(Fig. 4(f)). Hence, the reason for the drop in fidelity with time can be
attributed to the instantaneous choices of the feedback strengths. Although,
in the discussion for Fig. 3(c), we had found that $\lambda\sim\kappa$ serves
as a decent choice of feedback strength, in principle fine tuning it will
improve the achievable fidelity in the long time limit. Optimizing the values
of $\lambda_{j}(t)$ however, may not be a trivial task.

In this work, we have formulated an innovative approach of realizing bit-flip
QEC that can be regarded as one of the most optimal error correcting methods
in the literature, which is named as measurement based estimation controlled
continuous quantum error correction (MBE-CQEC). While traditionally used
methods of QEC are based on projective measurements, the current proposal
utilizes continuous measurements at its core, and thus falls under CQEC. While
CQEC, in principle, can be carried out in much quicker time intervals, the
biggest problem is the absence of the true error syndromes as these signals
get masked by the measurement noises. In our proposed method of CQEC, based on
a measurement based estimation scheme, the best of both QEC and traditional
CQEC techniques could be achieved. In addition, a novel bit-flip error
detection scheme was formulated that can be operated in delayed time. In
practical scenarios, each gate carries intrinsic error, which albeit being
small, accumulates in time and poses a challenge to achieve fault-tolerant
quantum computation. The delayed CQEC method can be advantageous in this
particular context, where the intervals of successive error correction steps
can be kept significantly high. Also note that for the analysis of the work,
we assume that the encoding was done perfectly. However, MBE-CQEC is expected
to be resilient to small encoding errors thanks to the perfect emulation of
the individual qubit errors and the way the errors are detected based on
Pauli-$Z$ expectation value deviation.

Finally, while the method works optimally with the distinctive features of
delayed QEC, the bottleneck would come from numerical expenses when one would
try to extend to more qubits, as the Hilbert space dimension would grow as
$2^{N}$, where $N$ is the number of qubits. In addition, for best performance
the detector should exhibit high response bandwidth. While phase-shift errors
can be corrected as bit-flip errors by moving to the computational basis of
qubits, the inclusion of both errors in a single code, e.g., the 9-qubit Shor
code, will be limited drastically by the computational effort required to
solve the $\cal E$stimator dynamics in real time. In this context, the use of
a compact representation of the states, e.g. the matrix product states, could
be useful.

In conclusion, we have proposed a novel approach of doing bit-flip error
correction that performs optimally. It not only removes the limitations of
canonical projective QEC techniques, but also can be used to correct errors in
delayed time based on all the previous measurement records, which can be a
much welcoming factor for its experimental realization.

## Appendix

Quantum continuous measurement and feedback control. Contrary to von Neumann
measurements, where a measurement operator (observable) is projectively
measured collapsing the state to an eigenstate, continuous measurements are
weak measurements where the observable is monitored in real time without
perturbing the state of the system significantly, so that the collapse is
gradual. These types of measurements are useful to observe the process of
collapse of a state, and to engineer feedback to control its dynamics. In
fact, it can be shown that a projective measurement is equivalent to an
infinite number of continuous weak measurements carried out over an
infinitesimally small time interval. Such a continuous measurement protocol
leads to the conditional evolution of the density matrix based on noisy
measurement outcomes given by,

$\displaystyle d\rho_{c}(t)$
$\displaystyle=-i[H,\rho_{c}(t)]dt+\kappa\mathcal{D}[A]\rho_{c}(t)dt$
$\displaystyle+\sqrt{\kappa}\mathcal{H}[A]\rho_{c}(t)dW(t),$ (4)

where $\rho_{c}$ denotes the conditional density matrix of the system
described by the Hamiltonian $H$. $A=\mathcal{A}/\mathcal{A}_{0}$ is a
dimensionless operator corresponding to the physical observable $\mathcal{A}$
scaled suitably by $\mathcal{A}_{0}$, and is known as the measurement
operator, which is measured with a measurement rate of $\kappa$ (denotes the
rate at which the information is extracted). The first term of the above
equation on the right-hand side represents the coherent evolution of the
system. The second term on the right-hand side gives the measurement
backaction due to the measurement of $A$, where $\mathcal{D}[A]\rho=A\rho
A^{\dagger}-\frac{1}{2}(A^{\dagger}A\rho+\rho A^{\dagger}A)$ represents the
decoherence superoperator. The last term is the stochastic diffusion term with
$dW(t)$ being the Wiener increments, which are Gaussian distributed random
variables with zero mean and represent memoryless white noise, $\langle
dW(t)dW(\tau)\rangle=\delta(t-\tau)$. $\mathcal{H}$ is a superoperator given
by, $\mathcal{H}[A]\rho=A\rho+\rho A^{\dagger}-\rho\mathrm{tr}[A\rho+\rho
A^{\dagger}]$. Eq. 4 is known as the stochastic master equation (SME). The
measurement records $dQ(t)$ are given by,

$\displaystyle dQ(t)=\langle A_{c}(t)\rangle
dt+\frac{1}{\sqrt{4\kappa}}{dW(t)},$ (5)

where $\langle A_{c}(t)\rangle$ denotes the conditional mean of the
measurement operator $A$ (dimensionless) at time $t$, which is nothing but the
signal, and the last term represents the measurement noise associated with it.

Each evolution of the density matrix, $\rho_{c}(t)$ in time, following the SME
in Eq. 4, represents a quantum trajectory, which can be manipulated and
controlled by using appropriate feedback to the Hamiltonian in real time. If
the feedback Hamiltonian, $F(t)$ is based on the conditional state,
$\rho_{c}(t)$ or the conditional mean $\langle A_{c}(t)\rangle$ of the
measurement operator, then the SME with the feedback Hamiltonian is given by,

$\displaystyle d\rho_{c}(t)=$
$\displaystyle-i[H,\rho_{c}(t)]dt+\kappa\mathcal{D}[A]\rho_{c}(t)dt$
$\displaystyle+$
$\displaystyle\sqrt{\kappa}\mathcal{H}[A]\rho_{c}(t)dW(t)-i[F(t),\rho_{c}(t)]dt.$
(6)

For non-ideal measurement efficiency $\eta$ and in presence of the
environmental decoherence, it becomes,

$\displaystyle d\rho_{c}(t)=$
$\displaystyle-i[H,\rho_{c}(t)]dt+\gamma\mathcal{D}[c]\rho_{c}(t)dt+\kappa\mathcal{D}[A]\rho_{c}(t)dt$
$\displaystyle+\sqrt{\kappa\eta}\mathcal{H}[A]\rho_{c}(t)dW(t)-i[F(t),\rho_{c}(t)]dt,$
(7)

where $\gamma$ is the environmental decoherence rate with collapse operator
$c$. The expression for the continuous measurement record in presence of
$\eta$ gets modified to,

$\displaystyle dQ(t)=\langle A_{c}(t)\rangle
dt+\frac{1}{\sqrt{4\eta\kappa}}{dW(t)}.$ (8)

Discrete quantum error correction. Generally speaking, QEC is a method to
protect an unknown state of an open quantum system. However, in the context of
quantum computing, we will consider qubits interacting with environmental
decoherences. In contrast to classical bit errors there are two sources of
errors, bit and phase flips. To correct bit-flip errors, stabilizer codes are
used, while phase errors can be corrected similarly to the bit-flip errors but
in a rotated basis (Hadamard basis) of the physical qubits Nielsen and Chuang
(2010). Stabilizer codes are repetition codes, where the unknown state of the
qubit is mapped onto a tensor space of a larger Hilbert space of multiple
qubits as entangled states. Such an entangled unit of qubits is called a
logical qubit. For example, in the three qubit repetition code, the unknown
state of the qubit is mapped onto three physical qubits, on which single bit-
flip errors can be corrected,

$\displaystyle|0\rangle\to|000\rangle\equiv|0\rangle_{L},$ (9)
$\displaystyle|1\rangle\to|111\rangle\equiv|1\rangle_{L}.$ (10)

Here the states $|0\rangle_{L}$ and $|1\rangle_{L}$ are the basis states for
the QEC code and the space spanned by them is called the codespace. The
elements of the codespace are known as the codewords. If the state of a
physical qubit is $|\psi\rangle=\alpha|0\rangle+\beta|1\rangle$, it is encoded
to two more physical qubits as
$|\psi\rangle_{L}=\alpha|000\rangle+\beta|111\rangle$, with
$\alpha^{2}+\beta^{2}=1$. The time evolution of the density matrix of the
logical qubit under bit-flip errors caused by the environment decoherences, at
a characteristic rate of $\gamma$ is described by,

$\displaystyle
d\rho(t)=\gamma(\mathcal{D}[XII]+\mathcal{D}[IXI]+\mathcal{D}[IIX])\,\rho\,dt.$
(11)

This is equivalent to assuming that the environment causes independent bit-
flips of each physical qubit at Poisson distributed times with rate $\gamma$.

The essence of QEC is that the state of the logical qubit, $|\psi\rangle_{L}$
is unknown to us, except however, the codespace, and we need to preserve it
without losing the initial fidelity and without any knowledge of the elements,
$\alpha$ and $\beta$ of the state. In this situation, it is possible to
measure a few special observables that determine the parities of the
neighbouring qubits without giving any information about the state of the
qubits themselves. In the three qubit code, there are three possible such
operators, given by, $M_{1}=ZZI$, $M_{2}=IZZ$ and $M_{3}=ZIZ$, where the third
operator can be considered redundant. As $M_{j}^{2}=\mathbb{I}$, these
operators have two possible eigenvalues $\pm 1$. The pair of eigenvalues
$(m_{1},m_{2})$ for the simultaneous measurements of $M_{1}$ and $M_{2}$ gives
the bit-flip error happening on a given qubit, provided no two qubits are
flipped at the same time. Such one qubit flips can be corrected by applying
unitary $X$ gates to the qubit on which the flip happened. Typically, to
achieve this, the syndrome operators are projectively measured and errors are
corrected based on the following conditions of the outcomes ($m_{1},m_{2}$):
(i) $(-1,+1)\to XII$, (ii) $(-1,-1)\to IXI$, (iii) $(+1,-1)\to IIX$ and (iv)
$(-1,+1)\to$ None. We will call QEC based on projective measurement as
discrete quantum error correction (DQEC) from now on.

In order for DQEC to work, it is important to make the assumption that there
are no multiple flips of the qubits happening simultaneously, and that no
single flip errors are missed. Given the fact that projective measurements
require significant time between each measurement, while the environment acts
to degrade the qubits continuously, DQEC can never be conducted perfectly, and
the error correction performance drops significantly over time. Theoretically
speaking, if we consider each error to be detected perfectly, the contribution
of simultaneous bit-flips can be relatively small for low environmental
decoherences, $\gamma$, as the theoretical fidelity of the error corrected
logical state with DQEC with respect to the initial state is given by Ahn  _et
al._ (2002),

$\displaystyle F_{\rm DQEC}(t)=\frac{1}{4}(2+3e^{-2\gamma t}-e^{-6\gamma t}).$
(12)

The drop in fidelity due to the bit-flip errors in a single qubit without
error correction, is given by,

$\displaystyle F_{1}(t)=\frac{1}{2}(1+e^{-2\gamma t}),$ (13)

and that of three qubits is given by $F_{3}(t)=F_{1}(t)^{3}$. This essentially
means that $F_{\rm DQEC}(t)\sim F_{1}(t)$ when $t\geq\pi$, which shows how
quickly the DQEC performance drops.

Continuous quantum error correction. CQEC differs from DQEC in multiple
aspects: in the way the measurements are performed on the syndrome operators,
how the errors are detected, and how the errors are corrected. Instead of
projective measurements, CQEC utilizes continuous weak measurements of the
syndrome operators, discussed above. The conditional evolution of the state of
the logical qubit undergoing bit-flip errors, continuous measurements and
feedback is modelled using the SME as,

$\displaystyle d\rho_{c}(t)=$
$\displaystyle\gamma(\mathcal{D}[XII]+\mathcal{D}[IXI]+\mathcal{D}[IIX])\rho_{c}dt$
$\displaystyle+$
$\displaystyle\kappa(\mathcal{D}[ZZI]+\mathcal{D}[IZZ]+\mathcal{D}[ZIZ])\rho_{c}dt$
$\displaystyle+$
$\displaystyle\sqrt{\kappa}(\mathcal{H}[ZZI]dW_{1}+\mathcal{H}[IZZ]dW_{2}+\mathcal{H}[ZIZ]dW_{3})\rho_{c}$
$\displaystyle-$ $\displaystyle i[F(t),\rho_{c}]dt,$ (14)

where the stochastic time varying measurement records of the stabilizer
generators are given by,

$\displaystyle dQ_{1}(t)=$ $\displaystyle\langle
ZZI\rangle_{c}dt+\frac{1}{\sqrt{4\kappa}}{dW_{1}(t)},$ (15) $\displaystyle
dQ_{2}(t)=$ $\displaystyle\langle
IZZ\rangle_{c}dt+\frac{1}{\sqrt{4\kappa}}{dW_{2}(t)},$ (16) $\displaystyle
dQ_{3}(t)=$ $\displaystyle\langle
ZIZ\rangle_{c}dt+\frac{1}{\sqrt{4\kappa}}{dW_{3}(t)}.$ (17)

Here $F(t)$ is the feedback Hamiltonian given by,

$\displaystyle F(t)=\lambda_{1}(t)XII+\lambda_{2}(t)IXI+\lambda_{3}(t)IIX,$
(18)

where $\lambda_{i}(t)$’s are, in principle, time dependent control parameters
which depends on the conditional means of the error syndromes. For example,
the following feedback scheme was proposed by Ahn et al. Ahn  _et al._ (2002)
for CQEC,

$\displaystyle\lambda_{1}(t)=$
$\displaystyle\lambda(1-\langle{ZZI}\rangle_{c})(1+\langle{IZZ}\rangle_{c})(1-\langle{ZIZ}\rangle_{c}),$
(19) $\displaystyle\lambda_{2}(t)=$
$\displaystyle\lambda(1-\langle{ZZI}\rangle_{c})(1-\langle{IZZ}\rangle_{c})(1+\langle{ZIZ}\rangle_{c}),$
(20) $\displaystyle\lambda_{3}(t)=$
$\displaystyle\lambda(1+\langle{ZZI}\rangle_{c})(1-\langle{IZZ}\rangle_{c})(1-\langle{ZIZ}\rangle_{c}),$
(21)

where $\lambda$ is a feedback strength of the order of the measurement rate,
$\kappa$. The feedback function $F(t)$ described above, makes use of the
conditional means of the syndrome operators, and thus, to perform CQEC
ideally, we require detailed information about the time dependence of the
conditional means of the syndrome generators. However, the conditional means
are not available from the measurement records (Eq. 15-17) directly as these
quantities are masked by measurement noise that is a fundamental component of
all quantum measurements. The signal to noise ratio of such measurements can
be typically quite poor. For practical purposes, researchers have previously
used temporal filters to recover these conditional means from the noisy
measurement records, with some filters possessing non-uniform temporal
weights, biasing up the most recent records to avoid any lags or delays
Sarovar  _et al._ (2004); Atalaya  _et al._ (2021); Livingston  _et al._
(2022); Mabuchi (2009). Of course real world devices already have limits on
their response bandwidths. The effects of additional software/hardware
filtering to smooth out the noisy measurement records will also degrade the
signal or conditional means. However, if somehow we happen to know the
conditional means in real time perfectly, the CQEC scheme would perform
optimally for bit-flip correction under the assumption that no two or more
qubits flip simultaneously in a three qubit stabilizer code. In the following,
we show how our proposed measurement based estimator (MBE) scheme allows us to
achieve this. We call this MBE method of CQEC as MBE-CQEC scheme.

The MBE-CQEC scheme. We now describe a scheme that can perform faithful real-
time estimation of any dynamical changes affecting the logical qubit. This MBE
scheme will play a crucial role in detecting the bit-flip errors perfectly and
therefore in applying the appropriate feedback $\lambda_{j}(t)$, in a manner,
as we will show, that achieves ultra-high levels of protection of the unknown
quantum state. Let us denote the laboratory-based quantum system that we wish
to protect, as the $\cal R$eal system, and our $\cal E$stimator system is a
numerical/computational model of the $\cal R$eal system, shown schematically
in Fig. 1 in the main text. We consider that the internal dynamics of this
$\cal R$eal system is described by the Hamiltonian $H^{\mathcal{R}}=H$, and
its conditional density matrix is given by, $\rho^{\cal R}_{c}$, under
continuous measurement via the measurement operator $A^{\mathcal{R}}=A$
(dimensionless). This can be described by the SME described above as,

$\displaystyle d\rho^{\cal R}_{c}(t)=$
$\displaystyle-i[H,\rho^{\mathcal{R}}_{c}(t)]dt+\gamma\mathcal{D}[c]\rho^{\cal
R}_{c}(t)dt$ $\displaystyle+$ $\displaystyle\kappa\mathcal{D}[A]\rho^{\cal
R}_{c}(t)dt+\sqrt{\kappa}\mathcal{H}[A]\rho^{\cal R}_{c}(t)\,dW^{\cal R}(t),$
(22)

where the superscript $\cal R$ is used to represent the $\cal R$eal lab
system. The measurement record, $dQ^{\mathcal{R}}(t)$ is given by the
summation of the conditional mean of the measurement operator and the
corresponding random noise component of the measurement,

$\displaystyle dQ^{\mathcal{R}}(t)=\langle
A^{\mathcal{R}}(t)\rangle_{c}dt+\frac{1}{\sqrt{4\kappa}}{dW^{\mathcal{R}}(t)}.$
(23)

Now, we make an $\cal E$stimator ($\cal E$) of the $\cal R$eal on a computer
with the same physical model ($H^{\mathcal{E}}=H^{\mathcal{R}}=H$), and the
continuous measurement of the same observable
($A^{\mathcal{E}}=A^{\mathcal{R}}=A$), but start the $\cal E$stimator dynamics
with a known initial state, $\rho^{\mathcal{E}}(0)$, which might be different
from the initial state of the $\cal R$eal system. The dynamics of this $\cal
E$stimator can be modelled as,

$\displaystyle d\rho^{\cal E}_{c}(t)=$ $\displaystyle-i[H,\rho^{\cal
E}_{c}(t)]dt+\gamma\mathcal{D}[c]\rho^{\cal
E}_{c}(t)dt+\kappa\mathcal{D}[A]\rho^{\cal E}_{c}(t)dt$ $\displaystyle+$
$\displaystyle\sqrt{\kappa}\mathcal{H}[A]\rho^{\cal E}_{c}(t)\,dW^{\cal
E}(t).$ (24)

We now can slave the dynamics of this $\cal E$stimator model to the dynamics
of the $\cal R$eal system by setting the $\cal E$stimator noise
${dW^{\mathcal{E}}(t)}$ as,

$\displaystyle{dW^{\mathcal{E}}(t)}={\sqrt{4\kappa}}\left[dQ^{\mathcal{R}}(t)-\langle
A^{\mathcal{E}}(t)\rangle_{c}dt\right],$ (25)

where the conditional mean $\langle A^{\mathcal{E}}(t)\rangle_{c}$, is
obtained from the $\cal E$stimator, which is readily available without any
extraneous noise. Thus, the dynamics of the $\cal E$stimator follows the
measurement records of the $\cal R$eal system as,

$\displaystyle d\rho^{\cal E}_{c}(t)=$ $\displaystyle-i[H,\rho^{\cal
E}_{c}(t)]dt+\gamma\mathcal{D}[c]\rho^{\cal
E}_{c}(t)dt+\kappa\mathcal{D}[A]\rho^{\cal E}_{c}(t)dt$ $\displaystyle+$
$\displaystyle{2\kappa}\left[dQ^{R}(t)-\langle A^{\cal
E}(t)\rangle_{c}dt\right]\mathcal{H}[A]\rho^{\cal E}_{c}(t).$ (26)

Let us now consider that the $\cal R$eal system consists of a logical qubit
comprising three physical qubits with an encoded unknown quantum state
$|\psi^{\cal R}\rangle_{L}=|\psi^{\cal
R}\rangle_{L}^{\alpha,\beta}=\alpha|000\rangle+\beta|111\rangle$, which we
want to protect from bit-flip errors. The $\cal E$stimator is modelled
similarly but with a different initial quantum state $|\psi^{\cal
E}\rangle_{L}=|\psi^{\cal
E}\rangle_{L}^{\alpha^{\prime},\beta^{\prime}}=\alpha^{\prime}|000\rangle+\beta^{\prime}|111\rangle$,
where $\alpha^{\prime}\neq\alpha$ and $\beta^{\prime}\neq\beta$. While the
values of $\alpha^{\prime}$ and $\beta^{\prime}$ we can choose; $\alpha$ and
$\beta$ for the $\cal R$eal system can be any possible values not known to us.
The conditional mean in the $\cal R$eal system, is unknown as it is masked by
the measurement noise as already stated. However, for the syndrome operators,
being parity operators, the measurement signals (error syndromes) are
independent of the coefficients ($\alpha$ and $\beta$) of the logical state
$|\psi\rangle_{L}=\alpha|000\rangle+\beta|111\rangle$, but only depends on the
codespace ($|000\rangle$ and $|111\rangle$). The unperturbed syndrome values,
$\langle{\cal G}_{i}\rangle_{c}^{{\cal R}/{\cal E}}$ at $t=0$ satisfy,

$\displaystyle\langle{\cal G}_{i}\rangle_{c}^{\cal E}(0)=\langle{\cal
G}_{i}\rangle_{c}^{\cal R}(0)=1.$ (27)

Here ${\cal G}_{i}$ represents the $i$th stabilizer operator. Now using Eq.
26, the $\cal E$stimator can be propagated to the next timestep after a
measurement time interval of $dt$ using the measurement current from the $\cal
R$eal but the conditional means from the $\cal E$stimator. For the second
step, the noise signal can be correctly recovered as, $\langle{\cal
G}_{i}\rangle_{c}^{\cal E}(dt)=\langle{\cal G}_{i}\rangle_{c}^{\cal R}(dt)$,
which can be either $+1$ or $-1$ unlike Eq. 27, and similarly the process is
repeated in timesteps of $dt$ for the $\cal E$stimator for subsequent times.
Such an $\cal E$stimator that is fed with real-time measurement records can
correctly emulate the dynamics of all the errors happening on the $\cal R$eal
system for each quantum trajectory. One can extract the error syndromes of the
$\cal R$eal system by merely looking at the $\cal E$stimator conditional
syndrome values, which are readily available. This solves the main problem of
CQEC codes, where it is otherwise not possible to isolate the error syndromes
from the measurement noise. The scheme is abbreviated as MBE-CQEC standing for
measurement based estimator scheme for continuous quantum error correction,
and is shown schematically in Fig. 1 in the main text of the article.

The MBE-CQEC scheme described above gives us a smart way of computing the
error syndromes within a continuous measurement process, which allows us to
correct bit-flips errors in real time in much rapid time intervals than DQEC
codes Nielsen and Chuang (2010) or using Eqn. 19-21. In the following we show
how the estimator system has real time tomographic information about the
errors happening to individual qubits, and we can use this to devise a new
correction scheme. This new scheme is not based on the conditional means of
the stabilizer operators, but instead, on the deviation of $\langle
Z(t)\rangle$ of the qubits in the $\cal E$stimator relative to their original
values at $t=0$, which is described below.

In the main text of the article, we have shown how the absolute deviation of
the expectation value of the Pauli-$Z$ operator of the physical qubit $q$ of
the $\cal E$stimator, $|\Delta\langle Z_{q}(t)\rangle=\langle
Z_{q}(t)\rangle-\langle Z_{q}(0)\rangle|$ scaled by its initial unperturbed
value $|\langle Z_{q}(0)\rangle|$, i.e., $|\Delta\langle
Z_{q}(t)\rangle|/|\langle Z_{q}(0)\rangle|$, follows the same in the $\cal
R$eal system. This constitutes the backbone of the error detection/correction
proposal presented in the article. To understand it better, let’s consider a
physical qubit $q$ with state given by
$|\psi\rangle=\alpha|0\rangle+\beta|1\rangle$. The initial expectation value
$Z_{q}$ without measurement is $\langle Z_{q}(0)\rangle=\beta^{2}-\alpha^{2}$.
A flip of the qubit at time $t>0$ will mean $\langle
Z_{q}(t)\rangle=\alpha^{2}-\beta^{2}$, such that the absolute deviation from
its initial state is given by, $|\langle\Delta
Z_{q}(t)\rangle|=2|\beta^{2}-\alpha^{2}|$. The ratio $|\Delta\langle
Z_{q}(t)\rangle|/|\langle Z_{q}(0)\rangle|=2$, which means a complete flip.
Similarly, $|\Delta\langle Z_{q}(t)\rangle|/|\langle Z_{q}(0)\rangle|=0$ would
mean absolutely no flipping. For any other change $\varepsilon$ in between,
$|\Delta\langle Z_{q}(t)\rangle|/|\langle Z_{q}(0)\rangle|=\varepsilon$. The
$\cal E$stimator qubit can be modelled with $\alpha=1$ and $\beta=0$, i.e., at
the reset condition for convenience, which means $\langle Z_{q}(0)\rangle=1$
for the $\cal E$stimator qubit. Under the same noise measurement signals,
$dW_{s}^{\cal E}(t)=dW_{s}^{\cal E}$, where $s=(ZZI,IZZ,ZIZ)$ denote the
syndrome operators under measurement of the three physical qubits of the $\cal
R$eal system, a change in $|\Delta\langle
Z^{\mathcal{R}}_{q}(t)\rangle|/|\langle Z^{\mathcal{R}}_{q}(0)\rangle|$ on
qubit $q$ by an amount $\varepsilon$ will underpin similar changes in the
$\cal E$stimator qubits, $|\Delta\langle
Z^{\mathcal{E}}_{q}(t)\rangle(t)|/|\langle Z^{\mathcal{E}}_{q}(0)\rangle|$,
i.e.,

$\displaystyle\frac{|\Delta\langle Z^{\mathcal{E}}_{q}(t)\rangle|}{|\langle
Z^{\mathcal{E}}_{q}(0)\rangle|}=\frac{|\Delta\langle
Z^{\mathcal{R}}_{q}(t)\rangle|}{|\langle
Z^{\mathcal{R}}_{q}(0)\rangle|}=\varepsilon(t).$ (28)

Thus, we can use the following condition on the $\cal E$stimator system to
detect a bit-flip error on qubit $q$ and correspondingly apply the feedback
Hamiltonian after a time $\delta t$,

$\lambda_{q}(t+\delta t)=\begin{cases}\lambda_{q},&\mathrm{if}|\langle
Z_{q}^{\cal E}(t)\rangle-\langle Z_{q}^{\cal E}(0)\rangle|>\varepsilon|\langle
Z_{q}^{\cal E}(0)\rangle|,\\\ 0,&\text{otherwise},\end{cases}$ (29)

where $\lambda_{q}\sim\kappa$ and $\epsilon$ is a tolerance slightly higher
than 1, which we choose to be $\varepsilon=1.05$.

##  I acknowledgments

The authors thank the super-computing facilities provided by the Okinawa
Institute of Science and Technology (OIST) Graduate University and financial
support. GJM acknowledge the support of the Australian Research Council Centre
of Excellence for Engineered Quantum Systems CE170100009.

## References

  * Nielsen and Chuang (2010) Michael A. Nielsen and Isaac L. Chuang,  _Quantum Computation and Quantum Information_ (Cambridge University Press, Cambridge, England, UK, 2010).
  * Shor (1995) Peter W. Shor, “Scheme for reducing decoherence in quantum computer memory,” Phys. Rev. A 52, R2493–R2496(R) (1995).
  * Steane (1996) A. M. Steane, “Error Correcting Codes in Quantum Theory,” Phys. Rev. Lett. 77, 793–797 (1996).
  * Djordjevic (2012) Ivan Djordjevic,  _Quantum Information Processing and Quantum Error Correction_ (Elsevier, Academic Press, 2012).
  * Gertler  _et al._ (2021) Jeffrey M. Gertler, Brian Baker, Juliang Li, Shruti Shirol, Jens Koch, and Chen Wang, “Protecting a bosonic qubit with autonomous quantum error correction,” Nature 590, 243–248 (2021).
  * Gottesman (1997) Daniel Gottesman, “Stabilizer Codes and Quantum Error Correction,” arXiv (1997), quant-ph/9705052 .
  * Devitt  _et al._ (2013) Simon J. Devitt, William J. Munro, and Kae Nemoto, “Quantum error correction for beginners,” Rep. Prog. Phys. 76, 076001 (2013).
  * Reed  _et al._ (2012) M. D. Reed, L. DiCarlo, S. E. Nigg, L. Sun, L. Frunzio, S. M. Girvin, and R. J. Schoelkopf, “Realization of three-qubit quantum error correction with superconducting circuits,” Nature 482, 382–385 (2012).
  * Knill  _et al._ (1998) Emanuel Knill, Raymond Laflamme, and Wojciech H. Zurek, “Resilient quantum computation: error models and thresholds,” Proc. R. Soc. Lond. A. 454, 365–384 (1998).
  * Girvin (2021) Steven M. Girvin, “Introduction to Quantum Error Correction and Fault Tolerance,” arXiv (2021), 2111.08894 .
  * Schindler  _et al._ (2011) Philipp Schindler, Julio T. Barreiro, Thomas Monz, Volckmar Nebendahl, Daniel Nigg, Michael Chwalla, Markus Hennrich, and Rainer Blatt, “Experimental Repetitive Quantum Error Correction,” Science 332, 1059–1061 (2011).
  * Linke  _et al._ (2017) Norbert M. Linke, Mauricio Gutierrez, Kevin A. Landsman, Caroline Figgatt, Shantanu Debnath, Kenneth R. Brown, and Christopher Monroe, “Fault-tolerant quantum error detection,” Sci. Adv. 3, e1701074 (2017).
  * Negnevitsky  _et al._ (2018) V. Negnevitsky, M. Marinelli, K. K. Mehta, H.-Y. Lo, C. Flühmann, and J. P. Home, “Repeated multi-qubit readout and feedback with a mixed-species trapped-ion register,” Nature 563, 527–531 (2018).
  * Cramer  _et al._ (2016) J. Cramer, N. Kalb, M. A. Rol, B. Hensen, M. S. Blok, M. Markham, D. J. Twitchen, R. Hanson, and T. H. Taminiau, “Repeated quantum error correction on a continuously encoded qubit by real-time feedback,” Nat. Commun. 7, 1–7 (2016).
  * Kelly  _et al._ (2015) J. Kelly, R. Barends, A. G. Fowler, A. Megrant, E. Jeffrey, T. C. White, D. Sank, J. Y. Mutus, B. Campbell, Yu Chen, Z. Chen, B. Chiaro, A. Dunsworth, I.-C. Hoi, C. Neill, P. J. J. O’Malley, C. Quintana, P. Roushan, A. Vainsencher, J. Wenner, A. N. Cleland, and John M. Martinis, “State preservation by repetitive error detection in a superconducting quantum circuit,” Nature 519, 66–69 (2015).
  * Ristè  _et al._ (2015) D. Ristè, S. Poletto, M.-Z. Huang, A. Bruno, V. Vesterinen, O.-P. Saira, and L. DiCarlo, “Detecting bit-flip errors in a logical qubit using stabilizer measurements,” Nat. Commun. 6, 1–6 (2015).
  * Ofek  _et al._ (2016) Nissim Ofek, Andrei Petrenko, Reinier Heeres, Philip Reinhold, Zaki Leghtas, Brian Vlastakis, Yehan Liu, Luigi Frunzio, S. M. Girvin, L. Jiang, Mazyar Mirrahimi, M. H. Devoret, and R. J. Schoelkopf, “Extending the lifetime of a quantum bit with error correction in superconducting circuits,” Nature 536, 441–445 (2016).
  * Arute et al. (2019) Frank Arute et al., “Quantum supremacy using a programmable superconducting processor,” Nature 574, 505–510 (2019).
  * Andersen  _et al._ (2020) Christian Kraglund Andersen, Ants Remm, Stefania Lazar, Sebastian Krinner, Nathan Lacroix, Graham J. Norris, Mihai Gabureac, Christopher Eichler, and Andreas Wallraff, “Repeated quantum error detection in a surface code,” Nat. Phys. 16, 875–880 (2020).
  * Stricker  _et al._ (2020) Roman Stricker, Davide Vodola, Alexander Erhard, Lukas Postler, Michael Meth, Martin Ringbauer, Philipp Schindler, Thomas Monz, Markus Müller, and Rainer Blatt, “Experimental deterministic correction of qubit loss,” Nature 585, 207–210 (2020).
  * Chen et al. (2021) Zijun Chen et al., “Exponential suppression of bit or phase errors with cyclic error correction,” Nature 595, 383–387 (2021).
  * de Neeve  _et al._ (2022) Brennan de Neeve, Thanh-Long Nguyen, Tanja Behrle, and Jonathan P. Home, “Error correction of a logical grid state qubit by dissipative pumping,” Nat. Phys. 18, 296–300 (2022).
  * Ahn  _et al._ (2002) Charlene Ahn, Andrew C. Doherty, and Andrew J. Landahl, “Continuous quantum error correction via quantum feedback control,” Phys. Rev. A 65, 042301 (2002).
  * Ahn  _et al._ (2003) Charlene Ahn, H. M. Wiseman, and G. J. Milburn, “Quantum error correction for continuously detected errors,” Phys. Rev. A 67, 052310 (2003).
  * Sarovar  _et al._ (2004) Mohan Sarovar, Charlene Ahn, Kurt Jacobs, and Gerard J. Milburn, “Practical scheme for error control using feedback,” Phys. Rev. A 69, 052324 (2004).
  * Sarovar and Milburn (2005) Mohan Sarovar and G. J. Milburn, “Continuous quantum error correction by cooling,” Phys. Rev. A 72, 012306 (2005).
  * Wiseman and Milburn (2014) Howard M. Wiseman and Gerard J. Milburn,  _Quantum Measurement and Control_ (Cambridge University Press, Cambridge, England, UK, 2014).
  * Mabuchi (2009) Hideo Mabuchi, “Continuous quantum error correction as classical hybrid control,” New J. Phys. 11, 105044 (2009).
  * Cardona  _et al._ (2019) Gerardo Cardona, Alain Sarlette, and Pierre Rouchon, “Continuous-time Quantum Error Correction with Noise-assisted Quantum Feedback,” IFAC-PapersOnLine 52, 198–203 (2019).
  * Mohseninia  _et al._ (2020) Razieh Mohseninia, Jing Yang, Irfan Siddiqi, Andrew N. Jordan, and Justin Dressel, “Always-On Quantum Error Tracking with Continuous Parity Measurements,” Quantum 4, 358 (2020), 1907.08882v2 .
  * Atalaya  _et al._ (2021) J. Atalaya, S. Zhang, M. Y. Niu, A. Babakhani, H. C. H. Chan, J. M. Epstein, and K. B. Whaley, “Continuous quantum error correction for evolution under time-dependent Hamiltonians,” Phys. Rev. A 103, 042406 (2021).
  * Livingston  _et al._ (2022) William P. Livingston, Machiel S. Blok, Emmanuel Flurin, Justin Dressel, Andrew N. Jordan, and Irfan Siddiqi, “Experimental demonstration of continuous quantum error correction,” Nat. Commun. 13, 1–7 (2022).
  * Diósi  _et al._ (2006) Lajos Diósi, Thomas Konrad, Artur Scherer, and Jürgen Audretsch, “Coupled Ito equations of continuous quantum state measurement and estimation,” J. Phys. A: Math. Gen. 39, L575–L581 (2006).
  * Borah  _et al._ (2021) Sangkha Borah, Bijita Sarma, Michael Kewming, Gerard J. Milburn, and Jason Twamley, “Measurement-Based Feedback Quantum Control with Deep Reinforcement Learning for a Double-Well Nonlinear Potential,” Phys. Rev. Lett. 127, 190403 (2021).
  * Minev  _et al._ (2019) Z. K. Minev, S. O. Mundhada, S. Shankar, P. Reinhold, R. Gutiérrez-Jáuregui, R. J. Schoelkopf, M. Mirrahimi, H. J. Carmichael, and M. H. Devoret, “To catch and reverse a quantum jump mid-flight - Nature,” Nature 570, 200–204 (2019).
  * Blais  _et al._ (2021) Alexandre Blais, Arne L. Grimsmo, S. M. Girvin, and Andreas Wallraff, “Circuit quantum electrodynamics,” Rev. Mod. Phys. 93, 025005 (2021).