From 5ced7b152e10931f62c573a52c48d4763c5f466a Mon Sep 17 00:00:00 2001 From: Andreas Tsouchlos Date: Tue, 28 Apr 2026 01:59:52 +0200 Subject: [PATCH] Write first couple of pages of chapter 3 --- src/thesis/bibliography.bib | 12 + src/thesis/chapters/3_fault_tolerant_qec.tex | 340 ++++++++++++------ src/thesis/chapters/4_decoding_under_dems.tex | 1 + 3 files changed, 247 insertions(+), 106 deletions(-) diff --git a/src/thesis/bibliography.bib b/src/thesis/bibliography.bib index fc92ca9..ab2f475 100644 --- a/src/thesis/bibliography.bib +++ b/src/thesis/bibliography.bib @@ -1058,3 +1058,15 @@ month = dec, year = {2023}, } + +@article{gidney_fault-tolerant_2021, + title = {A {Fault}-{Tolerant} {Honeycomb} {Memory}}, + volume = {5}, + issn = {2521-327X}, + doi = {10.22331/q-2021-12-20-605}, + journal = {Quantum}, + author = {Gidney, Craig and Newman, Michael and Fowler, Austin and Broughton, Michael}, + month = dec, + year = {2021}, + pages = {605}, +} diff --git a/src/thesis/chapters/3_fault_tolerant_qec.tex b/src/thesis/chapters/3_fault_tolerant_qec.tex index 886a5bd..4e356e9 100644 --- a/src/thesis/chapters/3_fault_tolerant_qec.tex +++ b/src/thesis/chapters/3_fault_tolerant_qec.tex @@ -16,7 +16,7 @@ address both types of errors. % Definition of fault tolerance -% TODO: Proper consideration with number of errors +% TODO: Different variable name for N? We model the possible occurrence of errors during any processing stage as different \emph{error locations} $E_i,~i\in \{1,\ldots,N\}$ in the circuit. @@ -32,44 +32,64 @@ indicating which errors occurred, with .% \end{align*} \autoref{fig:fault_tolerance_overview} illustrates the flow of errors. -A \ac{qec} procedure is deemed fault tolerant if -\cite[Def.~5]{gottesman_introduction_2009} -\begin{align*} - % tex-fmt: off - \text{A)} - % tex-fmt: on - \hspace{5mm} & \lVert \bm{e}_\text{output} \rVert - \le \lVert \bm{e}_\text{internal} \rVert - \hspace{5mm} \forall\, - \bm{e}_\text{input}, \bm{e}_\text{internal} \in \{0,1\}^N : - \lVert \bm{e}_\text{internal} \rVert \le t \\ - % tex-fmt: off - \text{B)} - % tex-fmt: on - \hspace{5mm} & \lVert \bm{e}_\text{output} \rVert = 0 - \hspace{19.3mm} \forall\, - \bm{e}_\text{input}, \bm{e}_\text{internal} \in \{0,1\}^N : +Specifically for \ac{css} codes, a \ac{qec} procedure is deemed +\emph{fault-tolerant}, if \cite[Def.~4.2]{derks_designing_2025} +\begin{gather*} + \lVert \bm{e}_{\text{output},X} \rVert \le t \hspace{5mm} + \forall\, \bm{e}_\text{input}, \bm{e}_\text{internal} \in \{0,1\}^N: + \lVert \bm{e}_\text{input} \rVert + \lVert \bm{e}_\text{internal} + \rVert \le t \\[1mm] + \text{and} \\[1mm] + \lVert \bm{e}_{\text{output},Z} \rVert \le t \hspace{5mm} + \forall\, \bm{e}_\text{input}, \bm{e}_\text{internal} \in \{0,1\}^N: \lVert \bm{e}_\text{input} \rVert + \lVert \bm{e}_\text{internal} \rVert \le t - , -\end{align*} + ,% +\end{gather*} where $t = \lfloor (d_\text{min} -1)/2 \rfloor$ is the number of -errors the original code is able to correct. -Condition A limits the spread of input errors during the error -correction process. -Condition B means that as long as there are few enough internal and -input errors, the scheme should be able to correct all of them. +errors the code is able to correct. +The vectors $\bm{e}_{\text{output},X}$ and $\bm{e}_{\text{output},Z}$ +denote only $X$ and $Z$ errors respectively. + +In order to deal with errors during the syndrome extraction that flip +single syndrome bits, multiple rounds of syndrome measurements must +be performed. +Typically, the number of syndrome extraction rounds is chosen as $d_\text{min}$. + +% % This is the definition of a fault-tolerant QEC gadget +% A \ac{qec} procedure is deemed fault tolerant if +% \cite[Def.~5]{gottesman_introduction_2009} +% \begin{align*} +% % tex-fmt: off +% \text{A)} +% % tex-fmt: on +% \hspace{5mm} & \lVert \bm{e}_\text{output} \rVert +% \le \lVert \bm{e}_\text{internal} \rVert +% \hspace{5mm} \forall\, +% \bm{e}_\text{input}, \bm{e}_\text{internal} \in \{0,1\}^N : +% \lVert \bm{e}_\text{internal} \rVert \le t \\ +% % tex-fmt: off +% \text{B)} +% % tex-fmt: on +% \hspace{5mm} & \lVert \bm{e}_\text{output} \rVert = 0 +% \hspace{19.3mm} \forall\, +% \bm{e}_\text{input}, \bm{e}_\text{internal} \in \{0,1\}^N : +% \lVert \bm{e}_\text{input} \rVert + \lVert \bm{e}_\text{internal} +% \rVert \le t +% , +% \end{align*} +% where $t = \lfloor (d_\text{min} -1)/2 \rfloor$ is the number of +% errors the original code is able to correct. +% Condition A limits the spread of input errors during the error +% correction process. +% Condition B means that as long as there are few enough internal and +% input errors, the scheme should be able to correct all of them. % Practical considerations % TODO: Are the fault-tolerant QEC procedures where we don't perform % multiple measurement rounds? -\content{We generally need to perform multiple rounds of syndrome extraction} -\content{The number of rounds of syndrome extraction is usually -chosen equal to the $d_\text{min}$ of the code} -\content{One-shot decoding property} - \begin{figure}[t] \centering @@ -106,9 +126,8 @@ chosen equal to the $d_\text{min}$ of the code} % Intro -% TODO: Different variable name for N? We collect the probabilities of error at each location in the -\emph{noise model}, a vector $\bm{p} \in \mathbb{R}^N$, where $N \in +\emph{noise model}, a vector $\bm{p} \in [0,1]^N$, where $N \in \mathbb{N}$ is the number of possible error locations. There are different types of noise models, each allowing for different error locations in the circuit. @@ -118,20 +137,16 @@ different error locations in the circuit. We will illustrate the most widely used types of error models on the example of the three-qubit repetition code for $X$ errors. This code has stabilizers $Z_1Z_2$ and $Z_2Z_3$. -Figure \autoref{fig:pure_syndrome_extraction} shows the respective +\autoref{fig:pure_syndrome_extraction} shows the respective check matrix and syndrome extraction circuit. +We refer to the qubits carrying the logical state +$\ket{\psi}_\text{L}$ as \emph{data qubits}. Note that this is a concrete implementation using CNOT gates, as opposed to the system-level view introduced in \autoref{subsec:Stabilizer Codes}. We visualize the different types of noise models in \autoref{fig:noise_model_types}. -% Data and ancilla qubits - -\content{Introduce data qubits} - -\content{\textbf{TODO:} Write something about the code/circuit distance} - % Bit-flip noise The simplest type of noise model is \emph{bit-flip} noise. @@ -139,22 +154,19 @@ This corresponds to the classical \ac{bsc}, i.e., only $X$ errors on the data qubits are possible \cite[Appendix~A]{gidney_new_2023}. Note that we cannot use bit-flip noise to develop fault-tolerant systems, as it doesnt't account for errors during the syndrome extraction. -This is shown in \autoref{subfig:bit_flip}. \\ -\content{Some more words on bit-flip noise} -\content{\textbf{TODO}: What is this useful for? Just as a first step?} +This type of noise model is shown in \autoref{subfig:bit_flip}. % Depolarizing channel -Extending bit-flip noise to consider $X,Z$ or $Y$ instead of just $X$ errors, -we obtain the \emph{depolarizing channel} +Extending bit-flip noise to consider $X,Z$ or $Y$ instead of just $X$ +errors, we obtain the \emph{depolarizing channel} \cite[Sec.~7.6]{gottesman_stabilizer_1997}, depicted in -\autoref{subfig:depolarizing}. \\ -\content{Some more words on the depolarizing channel} -\content{\textbf{TODO}: What does this model? Memory experiment with -ideal syndrome extraction?} -\content{\textbf{TODO}: Why is it called depolarizing?} - -\content{\textbf{TODO:} Write something about ``code capacity'' noise models} +\autoref{subfig:depolarizing}. +It is well-suited for modeling memory experiments, where data qubits +are stored idly for some period of time and errors accumulate due to +decoherence. +Bit-flip noise and the depolarizing channel are sometimes referred to +as \emph{code capacity noise models}. % Phenomenological noise @@ -167,29 +179,44 @@ locations right before each measurement \cite[Appendix~A]{gidney_new_2023}. Note that it is enough to only consider $X$ errors at this point, since that is the only type of error directly affecting the measurement outcomes. -This model is depicted in \autoref{subfig:phenomenological}.\\ -\content{\textbf{TODO}: Why is this useful? Derks et al. mentioned -something about it being useful to derive fault-tolerant circuits} +While not fully capturing all possible error mechanisms, +phenomenological noise is already expressive enough to be used for +the design of fault-tolerant circuitry \cite[Sec.~4.2]{derks_designing_2025}. +This model is depicted in \autoref{subfig:phenomenological}. % Circuit-level noise The most general type of noise model is \emph{circuit-level noise}. Here we not only consider noise inbetween syndrome extraction rounds and at the measurements, but at each gate. -Specifically, we allow arbitrary for $n$-qubit Pauli errors after -each $n$-qubit gate. +Specifically, we allow arbitrary $n$-qubit Pauli errors after each +$n$-qubit gate \cite[Def.~2.5]{derks_designing_2025}. An $n$-qubit Pauli error is simply a series of correlated Pauli -errors on each individual related qubit. -Circuit-level noise is shown in \autoref{subfig:circuit_level}. \\ -\content{\textbf{TODO}: Why do we need this? Derks et al. mentioned - something about needing it for actual simulations, even when using -phenomenological noise for derivations.} +errors on each related individual qubit. +While phenomenological noise is useful for some design aspects of +fault tolerant circuitry, for simulations, circuit-level noise should +always be used \cite[Sec.~4.2]{derks_designing_2025}. +This type of noise model is shown in \autoref{subfig:circuit_level}. -% Different noise models for circuit-level noise +% Practical simulation aspects -\content{Comparison from Gidney's paper} -\content{In this work we only consider standard circuit-based -depolarizing noise} +While these types of noise models give us some constraints on the +types and locations of errors, the question of how exactly to choose +their probabilities remains. +When performing simulations, we typically sweep a range of values of +the \emph{physical error rate} $p$, and there are different ways of +obtaining the noise model $\bm{p}$ from this physical error rate. +For the depolarizing channel in particular, we usually choose the +same error rate $p/3$ for $X$, $Z$, and $Y$ errors. +For circuit-level noise, various options exist, such as the \emph{SI1000} +(superconducting inspired) or the \emph{EM3} (entangling +measurements) models \cite[Sec.~2.1]{gidney_fault-tolerant_2021}. +These differ in the way they compute individual error probabilities +from the physical error rate. +In this work we only consider \emph{standard circuit-based depolarizing +noise}, as this is the standard approach in the literature. +We thus set the error probabilities of all error locations in the +circuit-level noise model to the same value, the physical error rate $p$. \begin{figure}[t] \centering @@ -333,7 +360,7 @@ depolarizing noise} \begin{quantikz}[row sep=4mm, column sep=2mm] \setwiretype{n} & \xerr & \gate[style={right, draw=none, xshift=-15mm}]{\text{X error}} \\ \setwiretype{n} & \xyzerr & \gate[style={right, draw=none, xshift=-15mm}]{\text{X,Z, or Y error}} \\ - \setwiretype{n} & \gate{\phantom{1}}\wire[d][1]{q} & \gate[style={right, draw=none, xshift=-15mm},2]{\text{Correlated error}} \\ + \setwiretype{n} & \gate{\phantom{1}}\wire[d][1]{q} & \gate[style={right, draw=none, xshift=-15mm},2]{\text{Two-qubit error}} \\ \setwiretype{n} & \gate{\phantom{1}} & \end{quantikz} % tex-fmt: on @@ -347,52 +374,81 @@ depolarizing noise} \section{Detector Error Models} \label{sec:Detector Error Models} -\content{\textbf{TODO}: Look up how Derks et al. introduce DEMs} - -% Different ways of implementing fault tolerance - -\content{Ways of implementing fault tolerance different from DEMs} +\emph{Detector error models} constitue a standardized framework for +passing information about the circuit used for \ac{qec} to a decoder. +They are also useful in the design of fault-tolerant \ldots such as +fault-tolerant quantum computing schemes \cite[Sec.~1]{derks_designing_2025}. +% While alternate ways of considering fault tolerance exist, detector +% error models +% benefit from the fact that +\content{Benefits of this approach \cite[Sec.~4.2]{derks_designing_2025}} % Core idea -\content{Construct ``circuit code'' from original code} - -% Benefits - -\content{Benefits of this approach \cite[Sec.~4.2]{derks_designing_2025}} +The goal we strive to achieve is to consider the possible error +locations in the syndrome extraction circuitry during decoding. +The core idea behind detector error models is to do this by defining +a new \emph{circuit code} that describes the circuit. +Each \ac{vn} of this new code corresponds to an error location in the +circuit and each corresponds to a \ac{cn} to a syndrome measurement. +This circuit code, combined with the prior probabilities of error +given by the noise model, incorporates all information necessary for decoding. %%%%%%%%%%%%%%%% \subsection{Measurement Syndrome Matrix} \label{subsec:Measurement Syndrome Matrix} -% Core idea +% Mathematical definition -\content{Core idea: Matrix describes parity checks \\ - $\rightarrow$ A column shows which parity checks the - corresponding VN contributes to \\ - $\rightarrow$ View columns as syndromes corresponding to error - locations in the circuit -} +We describe the circuit code using the \emph{measurement syndrome +matrix} matrix $\bm{\Omega} \in \mathbb{F}_2^{m\times N}$, with +\begin{align*} + \Omega_{j,i} = + \begin{cases} + 1, & \text{Error $i$ flips measurement $j$}\\ + 0, & \text{otherwise} + \end{cases} + .% +\end{align*} +This matrix thus defines the code based on which error mechanism +flips which measurement, rather than the Pauli type and location of +each error \cite[Sec.~1.4.3]{higgott_practical_2024}. +To obtain $\bm{\Omega}$, we must propagate Pauli errors through the +circuit, tracking which measurements they affect +\cite[Sec.~2.4]{derks_designing_2025}. -% Multiple rounds of syndrome extraction +% Example -% TODO: First introduce syndrome measurement matrix, mathematically -% (consult Derks et al.'s paper). Then use the three-qubit repetition -% code as an example only -\autoref{fig:rep_code_multiple_rounds_bit_flip} shows a circuit -performing three rounds of syndrome extraction for the three-qubit -repetition code introduced earlier. -We are only considering bit-flip noise at this point. -For each syndrome extraction round, we get an additional set of +% TODO: Fix syndrome dimension notation +We turn to our example of the three-qubit repetition code to +illustrate the construction of the syndrome measurement matrix. +We begin by replicating the syndrome extraction circuitry, three +times in this case, as can be seen in +\autoref{fig:rep_code_multiple_rounds_bit_flip}. +We consider only bit flip noise at this stage. +For each syndrome extraction round we get an additional set of syndrome measurements. We combine these measurements by stacking them in a new vector $\bm{s} \in \mathbb{F}_2^{n_\text{rounds}\cdot(n-k)}$. -To model this behavior mathematically, we append additional rows to -the check matrix. -We call this matrix the \emph{measurement syndrome matrix} -$\bm{\Omega}$. +To accomodate the additional syndrome bits, we extend the +matrix $\bm{\Omega}$ representing the circuit by replicating the rows as well. +Recall that $\bm{\Omega}$ describes which \ac{vn} is connected to +which parity check and the syndrome indicates which parity checks +are violated. +This means that if an error exists at only a single \ac{vn}, we can +read off the syndrome in the corresponding column. -\begin{figure}[H] +% Expand to phenomenological + +We now whish to expand the error model to phenomenological noise, though +only considering $X$ errors in this case. +We introduce new error locations at the respective positions, +arriving at the circuit depicted in +\autoref{fig:rep_code_multiple_rounds_phenomenological}. +For each additional error location, we extend $\bm{\Omega}$ by +appending the corresponding syndrome vector as a column. + +\begin{figure}[t] \centering \begin{minipage}{0.3\textwidth} @@ -503,7 +559,7 @@ $\bm{\Omega}$. \label{fig:rep_code_multiple_rounds_bit_flip} \end{figure} -\begin{figure}[H] +\begin{figure}[t] \begin{gather*} \hspace*{-33.3mm}% \begin{array}{c} @@ -594,6 +650,7 @@ $\bm{\Omega}$. Repeated syndrome extraction circuit for the three-qubit repetition code under phenomenological noise. } + \label{fig:rep_code_multiple_rounds_phenomenological} \end{figure} %%%%%%%%%%%%%%%% @@ -608,14 +665,86 @@ may wish to combine them in some way. We call such combinations \emph{detectors}. Formally, a detector is a parity constraint on a set of measurement outcomes \cite[Def.~2.1]{derks_designing_2025}. +Chaning the perspective in this way does not change the theoretical +error correcting capabilities of the circuit, but it may change the +decoding performance when using a practical decoder. +\red{[Possibly a few more words on this (maybe a mathematical +proof/intuition?)]} -\content{Detector matrix} +% The detector matrix -\content{Detector error matrix} +% TODO: Fix the notation mess +We describe the relationship between measurements and detectors using +the \emph{detector matrix} $\bm{D} \in \mathbb{F}_2^{d\times m}$ +\cite[Def.~2.2]{derks_designing_2025}. +Similar to the way a \ac{pcm} connects bits with parity checks, the +detector matrix links measurements and detectors. +Each column corresponds to a measurement, while the rows correspond +to the detectors. +We should note at this point that the combination of measurements +into detectors has no bearing on the actual construction of the +syndrome extraction circuitry. +It is something that happens ``virtually'' after the fact and only +affects the decoder. -\content{One way of defining the detectors is ...} +% The detector error matrix -\begin{figure}[H] +We now know how the errors at different locations in the circuit +affect the measurements ($\bm{\Omega}$), and we know how the +measurements relate to the detectors ($\bm{D}$). +For decoding, we are interested in the effect of the errors on the +detectors directly. +We thus construct the \emph{detector error matrix} $\bm{H} \in +\mathbb{F}_2^{d\times N}$ \cite[Def.~2.9]{derks_designing_2025} as +\begin{align*} + \bm{H} := \bm{D}\bm{\Omega} + .% +\end{align*} +Note that, in particular when $d=m$, this is equivalent to performing row +additions on the matrix $\bm{\Omega}$. + +% How to choose the detectors + +% TODO: Give results from current and previous stage mathematical names +We still have a degree of freedom in how we choose the detectors. +\ldots +There is, however, one way of defining the detectors that will prove useful +at a later stage. +To the measurement results from each syndrome extraction round, we +can add the results from the previous round, as illustrated in +\autoref{fig:detectors_from_measurements_general}. +\red{[Mathematical notation for measurement combination]} + +We again turn our attention to the three-qubit repetition code. +In \autoref{fig:rep_code_multiple_rounds_phenomenological} we can see +that $E_6$ has occurred and has subsequently tripped the last four measurements. +We now take those measurements and combine them according to +\red{[Reference mathematical notation above]}. +We can see this process graphically in +\autoref{fig:detectors_from_measurements_rep_code} +To understand why this way of defining the detectors is useful, we +note that the error $E_6$ in +\autoref{fig:rep_code_multiple_rounds_phenomenological} has not only +tripped the measurements in the syndrome extraction round immediately +afterwards, but all subsequent ones as well. +To only see errors in the rounds immediately following them, we +consider our newly defined detectors instead of the measurements, +that effectively compute the difference between the measurements. + +Each error can only trip syndrome bits that follow it. +We can see this in the triangular structure of $\bm{\Omega}$ in +\autoref{fig:rep_code_multiple_rounds_phenomenological}. +Combining the measurements into detectors according to +\red{[Reference mathematical notation above]}, we are performing row +additions in such a way as to clear the bottom left of the matrix. +This yields a block-diagonal structure for the detector error matrix +$\bm{H}$, as in the example in +\autoref{fig:detectors_from_measurements_rep_code}. +Note that we exploit the fact that each syndrome measurement round is +identical to obtain this structure. + +% TODO: Change notation (\bm{D}) +\begin{figure}[t] \centering \tikzset{ @@ -637,11 +766,10 @@ outcomes \cite[Def.~2.1]{derks_designing_2025}. % tex-fmt: on \caption{Construction of detectors from measurements in the general case.} + \label{fig:detectors_from_measurements_general} \end{figure} -\content{The three-qubit repetition code as an exmaple} - -\begin{figure}[H] +\begin{figure}[t] \centering \hspace*{-5mm} @@ -694,7 +822,7 @@ outcomes \cite[Def.~2.1]{derks_designing_2025}. \caption{Construction of detectors from the measurements of a three-qubit repetition code.} - \label{fig:Construction of the detectors from the measurements} + \label{fig:detectors_from_measurements_rep_code} \end{figure} %%%%%%%%%%%%%%%% diff --git a/src/thesis/chapters/4_decoding_under_dems.tex b/src/thesis/chapters/4_decoding_under_dems.tex index b9e880d..13a6dbb 100644 --- a/src/thesis/chapters/4_decoding_under_dems.tex +++ b/src/thesis/chapters/4_decoding_under_dems.tex @@ -13,6 +13,7 @@ \content{Callback to previous chapter} \content{(Maybe even historical) overview of the literature} +\content{Better yet: A proper (at least as proper as possible) review} % High-level overview of Sliding-Window decoding