Table of Contents
Fetching ...

Quantum Circuits Are Just a Phase

Chris Heunen, Louis Lemonnier, Christopher McNally, Alex Rice

TL;DR

This work introduces a phase-centric combinator language for quantum programs that abstracts away from gate-level circuits while retaining universality; a global phase operator and a quantum 'if let' enable decomposition into eigenspaces and controlled unitaries. The authors demonstrate that this minimal language can derive a universal gate set and naturally express key algorithms, including Grover, QFT, Hamiltonian simulation, QSP, and QET, through concise pattern-based constructs. A prototype compiler translates high-level terms into circuits, and a categorical denotational semantics provides soundness guarantees, offering a principled path toward more scalable and readable quantum programming. Collectively, the approach promises to align quantum software more closely with linear-algebraic reasoning and formal semantics, facilitating higher-level reasoning, optimization, and verification. The work thus marks a significant step in abstracting quantum programming away from low-level circuits toward structured, semantically grounded representations.

Abstract

Quantum programs today are written at a low level of abstraction - quantum circuits akin to assembly languages - and the unitary parts of even advanced quantum programming languages essentially function as circuit description languages. This state of affairs impedes scalability, clarity, and support for higher-level reasoning. More abstract and expressive quantum programming constructs are needed. To this end, we introduce a simple syntax for generating unitaries from "just a phase"; we combine a (global) phase operation that captures phase shifts with a quantum analogue of the "if let" construct that captures subspace selection via pattern matching. This minimal language lifts the focus from gates to eigendecomposition, conjugation, and controlled unitaries; common building blocks in quantum algorithm design. We demonstrate several aspects of the expressive power of our language in several ways. Firstly, we establish that our representation is universal by deriving a universal quantum gate set. Secondly, we show that important quantum algorithms can be expressed naturally and concisely, including Grover's search algorithm, Hamiltonian simulation, Quantum Fourier Transform, Quantum Signal Processing, and the Quantum Eigenvalue Transformation. Furthermore, we give clean denotational semantics grounded in categorical quantum mechanics. Finally, we implement a prototype compiler that efficiently translates terms of our language to quantum circuits, and prove that it is sound with respect to these semantics. Collectively, these contributions show that this construct offers a principled and practical step toward more abstract and structured quantum programming.

Quantum Circuits Are Just a Phase

TL;DR

This work introduces a phase-centric combinator language for quantum programs that abstracts away from gate-level circuits while retaining universality; a global phase operator and a quantum 'if let' enable decomposition into eigenspaces and controlled unitaries. The authors demonstrate that this minimal language can derive a universal gate set and naturally express key algorithms, including Grover, QFT, Hamiltonian simulation, QSP, and QET, through concise pattern-based constructs. A prototype compiler translates high-level terms into circuits, and a categorical denotational semantics provides soundness guarantees, offering a principled path toward more scalable and readable quantum programming. Collectively, the approach promises to align quantum software more closely with linear-algebraic reasoning and formal semantics, facilitating higher-level reasoning, optimization, and verification. The work thus marks a significant step in abstracting quantum programming away from low-level circuits toward structured, semantically grounded representations.

Abstract

Quantum programs today are written at a low level of abstraction - quantum circuits akin to assembly languages - and the unitary parts of even advanced quantum programming languages essentially function as circuit description languages. This state of affairs impedes scalability, clarity, and support for higher-level reasoning. More abstract and expressive quantum programming constructs are needed. To this end, we introduce a simple syntax for generating unitaries from "just a phase"; we combine a (global) phase operation that captures phase shifts with a quantum analogue of the "if let" construct that captures subspace selection via pattern matching. This minimal language lifts the focus from gates to eigendecomposition, conjugation, and controlled unitaries; common building blocks in quantum algorithm design. We demonstrate several aspects of the expressive power of our language in several ways. Firstly, we establish that our representation is universal by deriving a universal quantum gate set. Secondly, we show that important quantum algorithms can be expressed naturally and concisely, including Grover's search algorithm, Hamiltonian simulation, Quantum Fourier Transform, Quantum Signal Processing, and the Quantum Eigenvalue Transformation. Furthermore, we give clean denotational semantics grounded in categorical quantum mechanics. Finally, we implement a prototype compiler that efficiently translates terms of our language to quantum circuits, and prove that it is sound with respect to these semantics. Collectively, these contributions show that this construct offers a principled and practical step toward more abstract and structured quantum programming.

Paper Structure

This paper contains 9 sections, 33 equations, 3 figures.

Figures (3)

  • Figure 1: The Toffoli gate expanded into a quantum circuit of native gates. The expansion obscures that the operation commutes with $\mathsfZ\xspace$ measurement.
  • Figure 2: A circuit for an instance of Grover's algorithm searching for two marked bit strings 011 and 101 \citefiggattetal:grover. The intent of the programmer (and the meaning of the program) is obfuscated by the circuit representation.
  • Figure 3: Definitions of common quantum gates in the combinator syntax. A fully universal gate set can be generated with just a phase.

Theorems & Definitions (7)

  • Example 1: $\mathsf{X}\xspace$ gate
  • Definition 2: Inversion
  • Definition 3: Exponentials
  • Example 4
  • Example 5
  • Remark 6
  • Example 7