Unbounded loops in quantum programs: categories and weak while loops

Pablo Andrés-Martínez
DOI: https://doi.org/10.48550/arXiv.2212.05371
2022-12-11
Abstract:Control flow of quantum programs is often divided into two different classes: classical and quantum. Quantum programs with classical control flow have their conditional branching determined by the classical outcome of measurements, and these collapse quantum data. Conversely, quantum control flow is coherent, i.e. it does not perturb quantum data; quantum walk-based algorithms are practical examples where coherent quantum feedback plays a major role. This dissertation has two main contributions: (i) a categorical study of coherent quantum iteration and (ii) the introduction of weak while loops. (i) The objective is to endow categories of quantum processes with a traced monoidal structure capable of modelling iterative quantum loops. To this end, the trace of a morphism is calculated via the execution formula, which adds up the contribution of all possible paths of the control flow. Haghverdi's unique decomposition categories are generalised to admit additive inverses and equipped with convergence criteria using basic topology. In this setting, it is possible to prove the validity of the execution formula as a categorical trace on certain categories of quantum processes. (ii) A weak while loop is a classical control flow primitive that offers a trade-off between the collapse caused on each iteration and the amount of information gained. The trade-off may be adjusted by tuning a parameter and, in certain situations, it is possible to set its value so that we may control the algorithm without sacrificing its quantum speed-up. As an example, it is shown that Grover's search problem can be implemented using a weak while loop, maintaining the same time complexity as the standard Grover's algorithm (as previously shown by Mizel).
Quantum Physics
What problem does this paper attempt to address?