Table of Contents
Fetching ...

Quantum Subroutine Composition

Stacey Jeffery

TL;DR

The paper addresses the challenge of composing quantum algorithms with subroutines that have nonuniform, input-dependent runtimes. It introduces a general framework based on multidimensional quantum walks and variable-time quantum walks to embed subroutine costs into quantum-phase-estimation-driven compositions, achieving a time-efficient bound in the presence of superposed inputs. The main contributions include a variable-time quantum walk edge composition theorem, a full algorithmic composition theorem for arbitrary quantum algorithms, and a comprehensive treatment of both positive and negative witnesses that certify bounded error. The results significantly extend known variable-time search and query-composition techniques to time complexity for general quantum algorithms, enabling more modular and efficient quantum algorithm design with variable subroutine costs.

Abstract

An important tool in algorithm design is the ability to build algorithms from other algorithms that run as subroutines. In the case of quantum algorithms, a subroutine may be called on a superposition of different inputs, which complicates things. For example, a classical algorithm that calls a subroutine $Q$ times, where the average probability of querying the subroutine on input $i$ is $p_i$, and the cost of the subroutine on input $i$ is $T_i$, incurs expected cost $Q\sum_i p_i E[T_i]$ from all subroutine queries. While this statement is obvious for classical algorithms, for quantum algorithms, it is much less so, since naively, if we run a quantum subroutine on a superposition of inputs, we need to wait for all branches of the superposition to terminate before we can apply the next operation. We nonetheless show an analogous quantum statement (*): If $q_i$ is the average query weight on $i$ over all queries, the cost from all quantum subroutine queries is $Q\sum_i q_i E[T_i]$. Here the query weight on $i$ for a particular query is the probability of measuring $i$ in the input register if we were to measure right before the query. We prove this result using the technique of multidimensional quantum walks, recently introduced in arXiv:2208.13492. We present a more general version of their quantum walk edge composition result, which yields variable-time quantum walks, generalizing variable-time quantum search, by, for example, replacing the update cost with $\sqrt{\sum_{u,v}π_u P_{u,v} E[T_{u,v}^2]}$, where $T_{u,v}$ is the cost to move from vertex $u$ to vertex $v$. The same technique that allows us to compose quantum subroutines in quantum walks can also be used to compose in any quantum algorithm, which is how we prove (*).

Quantum Subroutine Composition

TL;DR

The paper addresses the challenge of composing quantum algorithms with subroutines that have nonuniform, input-dependent runtimes. It introduces a general framework based on multidimensional quantum walks and variable-time quantum walks to embed subroutine costs into quantum-phase-estimation-driven compositions, achieving a time-efficient bound in the presence of superposed inputs. The main contributions include a variable-time quantum walk edge composition theorem, a full algorithmic composition theorem for arbitrary quantum algorithms, and a comprehensive treatment of both positive and negative witnesses that certify bounded error. The results significantly extend known variable-time search and query-composition techniques to time complexity for general quantum algorithms, enabling more modular and efficient quantum algorithm design with variable subroutine costs.

Abstract

An important tool in algorithm design is the ability to build algorithms from other algorithms that run as subroutines. In the case of quantum algorithms, a subroutine may be called on a superposition of different inputs, which complicates things. For example, a classical algorithm that calls a subroutine times, where the average probability of querying the subroutine on input is , and the cost of the subroutine on input is , incurs expected cost from all subroutine queries. While this statement is obvious for classical algorithms, for quantum algorithms, it is much less so, since naively, if we run a quantum subroutine on a superposition of inputs, we need to wait for all branches of the superposition to terminate before we can apply the next operation. We nonetheless show an analogous quantum statement (*): If is the average query weight on over all queries, the cost from all quantum subroutine queries is . Here the query weight on for a particular query is the probability of measuring in the input register if we were to measure right before the query. We prove this result using the technique of multidimensional quantum walks, recently introduced in arXiv:2208.13492. We present a more general version of their quantum walk edge composition result, which yields variable-time quantum walks, generalizing variable-time quantum search, by, for example, replacing the update cost with , where is the cost to move from vertex to vertex . The same technique that allows us to compose quantum subroutines in quantum walks can also be used to compose in any quantum algorithm, which is how we prove (*).
Paper Structure (31 sections, 19 theorems, 243 equations, 4 figures, 1 table)

This paper contains 31 sections, 19 theorems, 243 equations, 4 figures, 1 table.

Key Result

Theorem 1.1

Let $\bar{{\sf q}}_i$ be the average (over all queries made by the outer algorithm) squared amplitude on querying index $i\in [n]$ (see eq:alg-comp-bar-q_i). Let $\epsilon_i$ be the error of the inner subroutine on input $i$, and $T_i$ the stopping time of the inner subroutine on input $i$, which is and suppose the subroutine's errors satisfy the following condition: Then there is a quantum algor

Figures (4)

  • Figure 1: Instead of using a $T_{u,v}$ step quantum algorithm for the transition from $u$ to $v$ to build a "bridge" from $u$ to $v$ that functions like a path of length $T_{u,v}$ (left), we use a variable-time quantum algorithm to put a ladder-like gadget between $u$ and $v$ (right). The rungs of the ladder correspond to the steps of the quantum algorithm, and intuitively, we should think of the weight of each rung as corresponding to the probability that the algorithm terminates at that step.
  • Figure 2: The overlap graph of the sets of states defined in \ref{['def:algorithm-states']} for some fixed $i$. Each node represents a set of states that are pairwise orthogonal. Two nodes share an edge if and only if their sets contain overlapping states. For different values of $i$, all states are orthogonal. One can imagine an algorithm starting in the state ${\lvert}\rightarrow\rangle{\lvert}i\rangle{\lvert}0,0\rangle{\lvert}0\rangle$, which only overlaps $\Psi_{0}^{i,\rightarrow}$. The state of the algorithm moves through the graph until some part of it is of the form ${\lvert}\leftarrow\rangle A_a{\lvert}i\rangle{\lvert}a,z\rangle{\lvert}t\rangle$, hopefully for $a=g(i)$, then on that part, it uncomputes to move back down the other side of the ladder to a state that only overlaps $\Psi_0^{i,\leftarrow}$. The length of the algorithm's path depends on which "rung" $t$ of the ladder it uses to move from the $\rightarrow$ to the $\leftarrow$ part, which will depend on the stopping probabilities at various steps.
  • Figure 3: If $G$ is a triangle with vertices $u$, $v$ and $w$, and $\overrightarrow{E}(G)=\{(u,v),(w,v),(u,w)\}$, this figure shows the overlap graph for the spaces that make up $\Psi^{\cal A}\cup\Psi^{\cal B}$. If $G$ is any graph, we can get a similar overlap graph by replacing each edge of $G$ with a "ladder" gadget, like those shown here. While the height of each ladder is ${\sf T}={\sf T}_{\max}$, if there is some probability of stopping at an earlier time, we can get flow through earlier rungs, thus saving time. The weights of the rungs should correspond to the probability that the algorithm halts at that time.
  • Figure 4: A graph showing the overlap between the states in $\Psi^{\cal A}\cup \Psi^{\cal B}$. Each node of the graph represents a set of pairwise orthogonal states. An edge between two nodes indicates that the sets are not orthogonal. The states in $\Psi^{\cal A}$ (or $\Psi^{\cal B}$) are an independent set of this graph. Here we show just a part of the graph, for some $\ell\in{\cal Q}$.

Theorems & Definitions (54)

  • Theorem 1.1: Informal
  • Definition 2.1: Network
  • Definition 2.2: Quantum Walk access to $G$
  • Definition 2.3: Flow, Circulation
  • Definition 2.4: Effective Resistance
  • Theorem 2.5: chandra1996ElectricalResAndCommute
  • Theorem 2.6: Folklore, or see apers2019UnifiedFrameworkQWSearch
  • Theorem 2.7: belovs2013ElectricWalks
  • Definition 2.8: Parameters of a Phase Estimation Algorithm
  • Definition 2.9: Negative Witness
  • ...and 44 more