Lightweight Detection of a Small Number of Large Errors in a Quantum Circuit

Suppose we want to implement a unitary <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math>, for instance a circuit for some quantum algorithm. Suppose our actual implementation is a unitary <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math>, which we can only apply as a black-box. In general it is an exponentially-hard task to decide whether <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> equals the intended <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math>, or is significantly different in a worst-case norm. In this paper we consider two special cases where relatively efficient and lightweight procedures exist for this task.First, we give an efficient procedure under the assumption that <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math> and <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> (both of which we can now apply as a black-box) are either equal, or differ significantly in only one <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>k</mml:mi></mml:math>-qubit gate, where <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>k</mml:mi><mml:mo>=</mml:mo><mml:mi>O</mml:mi><mml:mo stretchy="false">(</mml:mo><mml:mn>1</mml:mn><mml:mo stretchy="false">)</mml:mo></mml:math> (the <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>k</mml:mi></mml:math> qubits need not be contiguous). Second, we give an even more lightweight procedure under the assumption that <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math> and <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> are <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mtext class="MJX-tex-mathit" mathvariant="italic">Clifford</mml:mtext></mml:mrow></mml:math> circuits which are either equal, or different in arbitrary ways (the specification of <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math> is now classically given while <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> can still only be applied as a black-box). Both procedures only need to run <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> a constant number of times to detect a constant error in a worst-case norm. We note that the Clifford result also follows from earlier work of Flammia and Liu, and da Silva, Landon-Cardinal, and Poulin.In the Clifford case, our error-detection procedure also allows us efficiently to learn (and hence correct) <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> if we have a small list of possible errors that could have happened to <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math>; for example if we know that only <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>O</mml:mi><mml:mo stretchy="false">(</mml:mo><mml:mn>1</mml:mn><mml:mo stretchy="false">)</mml:mo></mml:math> of the gates of <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math> are wrong, this list will be polynomially small and we can test each possible erroneous version of <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>U</mml:mi></mml:math> for equality with <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow class="MJX-TeXAtom-ORD"><mml:mover><mml:mi>U</mml:mi><mml:mo stretchy="false">~</mml:mo></mml:mover></mml:mrow></mml:math>.