Searcharxiv⌕ Search

arXiv subjects

Olivia Di Matteo

Publications and source records attributed to Olivia Di Matteo.

At least 19 recordsLinked to original sources

Retromorphic Testing of Quantum Compiler Passes

Quantum compilers play a critical role in transforming high-level quantum programs into optimized, hardware-compatible circuits. However, verifying the correctness of compiler passes remains challenging, as determining the expected output of large, deeply entangled quantum circuits is computationally intractable. This challenge is further amplified when compiler passes modify already complex circuit structures, making manual validation of transformed circuits impractical. In this work, we perform a systematic analysis of unit tests for quantum compiler passes in four quantum programming frameworks (PennyLane, Qiskit, Cirq, and pytket). Our findings indicate validation is dominated by program-content and program-metric assertions, and test circuits are generally small and shallow. Motivated by these observations, we introduce a testing methodology for automated validation of quantum compiler passes based on retromorphic testing and principles from the Hadamard test. This methodology analyzes a compiler pass, test circuit, and expected pass behavior to verify semantic preservation and intended structural modifications. We implement our methods in a framework, RetroQ, and apply it to compiler passes in PennyLane and Qiskit. Experimental evaluation reproduced several existing bugs as well as uncovered previously undetected defects, such as flawed symbolic parameter handling, incorrect commutation logic, failure to recognize self-adjointness of gates, and runtime crashes. These findings highlight the need for compiler-pass-specific testing methodologies to improve the reliability of the evolving quantum software stack.

quant-ph↗

Why Are We Unrolling? The Importance of Structured Quantum Programs for Compilation

As quantum software stacks scale up to support future fault-tolerant quantum hardware and algorithms, quantum compilation is becoming an increasingly important component of the stack. How do we ensure that our software stacks support dynamic algorithms, including patterns such as mid-circuit measurement feedforward and repeat-until-success, with hundreds of logical qubits and billions of quantum operations? To do so, we must re-think how we represent quantum programs beyond straight-line circuits, to representations that include classical structure and dynamism, and make this the default representation to consider when performing quantum compilation. In this work, we present important patterns and algorithms from fault-tolerant quantum applications which admit a structured representation that we argue is crucial to preserve, and set a challenge to the community to compile such representations without unrolling them into straight-line quantum circuits. We also explore the status quo of structured program support in quantum software, and ask ourselves the rhetorical question: how much more efficient can we make quantum compilation tooling when we take into account the additional information from classical structure?

quant-ph↗

CircInspect: Integrating Visual Circuit Analysis, Abstraction, and Real-Time Development in Quantum Debugging

Software bugs typically result from errors in specifications or code translation. While classical software engineering has evolved with various tools and methodologies to tackle such bugs, the emergence of quantum computing presents unique challenges. Quantum software development introduces complexities due to the probabilistic nature of quantum computing, distinct algorithmic primitives, and potential hardware noise. In this paper, we introduce CircInspect, an interactive tool tailored for debugging quantum programs in Python and PennyLane. By leveraging breakpoints and real-time software development features, \toolname~empowers users to analyze isolated quantum circuit components, monitor program output, visualize structural changes, and abstract information to enhance comprehension.

cs.SE↗

An experience-based classification of quantum bugs in quantum software

As quantum computers continue to improve in quality and scale, there is a growing need for accessible software frameworks for programming them. However, the unique behavior of quantum systems means specialized approaches, beyond traditional software development, are required. This is particularly true for debugging due to quantum bugs, i.e., bugs that occur precisely because an algorithm is a quantum algorithm. Pinpointing a quantum bug's root cause often requires significant developer time, as there is little established guidance for quantum debugging techniques. Developing such guidance is the main challenge we sought to address. In this work, we describe a set of 14 quantum bugs, sourced primarily from our experience as quantum software developers, and supplemented by analysis of open-source GitHub repositories. We detail their context, symptoms, and the techniques applied to identify and fix them. While classifying these bugs based on existing schemes, we observed that most emerged due to unique interactions between multiple aspects of an algorithm or workflow. In other words, they occurred because more than one thing went wrong, which provided important insight into why quantum debugging is more challenging. Furthermore, based on this clustering, we found that - unexpectedly - there is no clear relationship between debugging strategies and bug classes. Further research is needed to develop effective and systematic quantum debugging strategies.

quant-ph↗

Non-Abelian dynamics on a cube: improving quantum compilation through qudit-based simulations

Recent developments in mapping lattice gauge theories relevant to the Standard Model onto digital quantum computers identify scalable paths with well-defined quantum compilation challenges toward the continuum. As an entry point to these challenges, we address the simulation of SU(2) lattice gauge theory. Using qudit registers to encode the digitized gauge field, we provide quantum resource estimates, in terms of elementary qudit gates, for arbitrarily high local gauge field truncations. We then demonstrate an end-to-end simulation of real-time, qutrit-digitized SU(2) dynamics on a cube. Through optimizing the simulation, we improved circuit decompositions for uniformly-controlled qudit rotations, an algorithmic primitive for general applications of quantum computing. The decompositions also apply to mixed-dimensional qudit systems, which we found advantageous for compiling lattice gauge theory simulations. Furthermore, we parallelize the evolution of opposite faces in anticipation of similar opportunities arising in three-dimensional lattice volumes. This work details an ambitious executable for future qudit hardware and attests to the value of codesign strategies between lattice gauge theory simulation and quantum compilation.

quant-ph↗

Productive Quantum Programming Needs Better Abstract Machines

An effective, accessible abstraction hierarchy has made using and programming computers possible for people across all disciplines. Establishing such a hierarchy for quantum programming is an outstanding challenge, especially due to a proliferation of different conventions and the rapid pace of innovation. One critical portion of the hierarchy is the abstract machine, the layer that separates a programmer's mental model of the hardware from its physical realization. Drawing on historical parallels in classical computing, we explain why having the "right" quantum abstract machine (QAM) is essential for making progress in the field and propose a novel framework for evaluating QAMs based on a set of desirable criteria. These criteria capture aspects of a QAM such as universality, compactness, expressiveness, and composability, which aid in the representation of quantum programs. By defining this framework we take steps toward defining an optimal QAM. We further apply our framework to survey the landscape of existing proposals, draw comparisons, and assess them based on our criteria. While these proposals share many common strengths, we find that each falls short of our ideal. Our framework and our findings set a direction for subsequent efforts to define a future QAM that is both straightforward to map to a variety of quantum computers, and provides a stable abstraction for quantum software development.

quant-ph↗

Constant-time hybrid compilation of Shor's algorithm with quantum just-in-time compilation

Continuous improvements in quantum computing hardware are exposing the need for simultaneous advances in software. Large-scale implementation of quantum algorithms requires rapid and automated compilation routines such as circuit synthesis and optimization. As systems move towards fault-tolerance, programming frameworks and compilers must also be capable of compiling and optimizing programs comprising both classical and quantum code. This work takes a step in that direction by providing an implementation of Shor's factoring algorithm, compiled to elementary quantum gates using PennyLane and Catalyst, a library for quantum just-in-time (QJIT) compilation of hybrid workflows. We demonstrate that with QJIT compilation, the algorithm is compiled once per bit width of $N$, the integer being factored, even when $N$-specific optimizations are applied to circuit generation based on values determined at runtime. The implementation is benchmarked up to 32-bit $N$, and both the size of the compiled program and the pure compilation time are found to be constant (under 3 seconds on a laptop computer), meaning code generation becomes tractable even for realistic problem sizes.

quant-ph↗

Graph-based identification of qubit network (GidNET) for qubit reuse

Quantum computing introduces the challenge of optimizing quantum resources crucial for executing algorithms within the limited qubit availability of current quantum architectures. Existing qubit reuse algorithms face a trade-off between optimality and scalability, with some achieving optimal reuse but limited scalability due to computational complexities, while others exhibit reduced runtime at the expense of optimality. This paper introduces GidNET (Graph-based Identification of qubit NETwork), an algorithm for optimizing qubit reuse in quantum circuits. By analyzing the circuit's Directed Acyclic Graph (DAG) representation and its corresponding candidate matrix, GidNET identifies higher-quality pathways for qubit reuse more efficiently. Through a comparative study with established algorithms, notably QNET [1], GidNET not only achieves a consistent reduction in compiled circuit widths by a geometric mean of 4.4%, reaching up to 21% in larger circuits, but also demonstrates enhanced computational speed and scaling, with average execution time reduction of 97.4% (i.e., 38.5X geometric mean speedup) and up to 99.3% (142.9X speedup) across various circuit sizes. Furthermore, GidNET consistently outperforms Qiskit in circuit width reduction, achieving an average improvement of 59.3%, with maximum reductions of up to 72% in the largest tested circuits. These results demonstrate GidNET's ability to improve circuit width and runtime, offering a solution for quantum computers with limited numbers of qubits.

quant-ph↗

An Abstraction Hierarchy Toward Productive Quantum Programming

Experience from seven decades of classical computing suggests that a sustainable computer industry depends on a community of software engineers writing programs to address a wide variety of specific end-user needs, achieving both performance and utility in the process. Quantum computing is an emerging technology, and we do not yet have the insight to understand what quantum software tools and practices will best support researchers, software engineers, or applications specialists. Developers for today's quantum computers are grappling with the low-level details of the hardware, and progress towards scalable devices does not yet suggest what higher-level abstractions may look like. In this paper, we analyze and reframe the current state of the quantum software stack using the language of programming models. We propose an abstraction hierarchy to support quantum software engineering and discuss the consequences of overlaps across the programming, execution, and hardware models found in current technologies. We exercise this hierarchy for solving the eigenvalue estimation problem in two ways (a variational algorithm with error mitigation, and phase estimation with error correction) and pinpoint key differences in these approaches in terms of these layered models and their overlaps. While our work points to concrete conceptual challenges and gaps in quantum programming and proposes some specific steps forward, our primary thesis is that progress hinges on thinking about the abstraction hierarchy holistically, and not just about its components.

quant-ph↗

On the need for effective tools for debugging quantum programs

The ability to incorporate quantum phenomena in computing unlocks a host of new ways to make mistakes. This work surveys existing studies and approaches to debugging quantum programs. It then presents a set of examples that stem from first-hand experience, intended to motivate future research on the subject and the development of novel tools and techniques.

quant-ph↗

Prediction of the neutron drip line in oxygen isotopes using quantum computation

In the noisy intermediate-scale quantum era, variational algorithms have become a standard approach to solving quantum many-body problems. Here, we present variational quantum eigensolver (VQE) results of selected oxygen isotopes within the shell model description. The aim of the present work is to locate the neutron drip line of the oxygen chain using unitary coupled cluster (UCC) type ansatze with different microscopic interactions (DJ16, JISP16, and N3LO), in addition to a phenomenological USDB interaction. While initially infeasible to execute on contemporary quantum hardware, the size of the problem is reduced significantly using qubit tapering techniques in conjunction with custom circuit design and optimization. The optimal values of ansatz parameters from classical simulation are taken for the DJ16 interaction, and the tapered circuits are run on IonQ's Aria, a trapped-ion quantum computer. After applying gate error mitigation for three isotopes, we reproduced exact ground state energies within a few percent error. The post-processed results from hardware also clearly show $^{24}$O as the drip line nucleus of the oxygen chain. Future improvements in quantum hardware could make it possible to locate drip lines of heavier nuclei.

nucl-th↗

Exploring the Potential of Qutrits for Quantum Optimization of Graph Coloring

Recent hardware demonstrations and advances in circuit compilation have made quantum computing with higher-dimensional systems (qudits) on near-term devices an attractive possibility. Some problems have more natural or optimal encodings using qudits over qubits. We explore this potential by formulating graph 3-coloring, a well-known and difficult problem with practical applications, using qutrits, and solve it using the quantum approximate optimization algorithm (QAOA). Qutrit-based cost and mixer Hamiltonians are constructed along with appropriate quantum circuits using qutrit gates. We run noiseless simulations using PennyLane to compare the formulation against qubit-based QAOA, and analyze the solution quality and resources required. Preliminary results show that the qutrit encoding finds more accurate solutions with a comparable set of hyperparameters, uses half as many qudits, and has a notably smaller circuit depth per layer than an efficient qubit encoding. This work suggests that qutrits may be useful in solving some problems on near-term devices, however further work is required to assess their potential in a noisy environment.

quant-ph↗

Differentiable quantum computational chemistry with PennyLane

This work describes the theoretical foundation for all quantum chemistry functionality in PennyLane, a quantum computing software library specializing in quantum differentiable programming. We provide an overview of fundamental concepts in quantum chemistry, including the basic principles of the Hartree-Fock method. A flagship feature in PennyLane is the differentiable Hartree-Fock solver, allowing users to compute exact gradients of molecular Hamiltonians with respect to nuclear coordinates and basis set parameters. PennyLane provides specialized operations for quantum chemistry, including excitation gates as Givens rotations and templates for quantum chemistry circuits. Moreover, built-in simulators exploit sparse matrix techniques for representing molecular Hamiltonians that lead to fast simulation for quantum chemistry applications. In combination with PennyLane's existing methods for constructing, optimizing, and executing circuits, these methods allow users to implement a wide range of quantum algorithms for quantum chemistry. We discuss how PennyLane can be used to implement variational algorithms for calculating ground-state energies, excited-state energies, and energy derivatives, all of which can be differentiated with respect to both circuit and Hamiltonian parameters. We provide an example workflow describing how to jointly optimize circuit parameters, nuclear coordinates, and basis set parameters for quantum chemistry algorithms. We discuss a functionality for reducing the number of qubits by using symmetries and explain how PennyLane can be used to estimate quantum resources needed to implement several quantum algorithms. By combining insights from quantum computing, computational chemistry, and machine learning, PennyLane is the first library for differentiable quantum computational chemistry.

quant-ph↗

Quantum computing fidelity susceptibility using automatic differentiation

Automatic differentiation is an invaluable feature of machine learning and quantum machine learning software libraries. In this work it is shown how quantum automatic differentiation can be used to solve the condensed-matter problem of computing fidelity susceptibility, a quantity whose value may be indicative of a phase transition in a system. Results are presented using simulations including hardware noise for small instances of the transverse-field Ising model, and a number of optimizations that can be applied are highlighted. Error mitigation (zero-noise extrapolation) is applied within the autodifferentiation framework to a number of gradient values required for computation of fidelity susceptibility and a related quantity, the second derivative of the energy. Such computations are found to be highly sensitive to the additional statistical noise incurred by the error mitigation method

quant-ph↗

Rotation-inspired circuit cut optimization

Recent works have demonstrated that large quantum circuits can be cut and decomposed into smaller clusters of quantum circuits with fewer qubits that can be executed independently on a small quantum computer. Classical post-processing then combines the results from each cluster to reconstruct the output of the original quantum circuit. However, the runtime for such hybrid quantum-classical algorithms is exponential in the number of cuts on a circuit. We propose Rotation-Inspired Circuit Cut Optimization (RICCO), an alternative method which reduces the post-processing overhead of circuit cutting, at the cost of having to solve an optimization problem. RICCO introduces unitary rotations at cut locations to rotate the quantum state such that expectation values with respect to one set of observables are maximized and others are set to zero. We demonstrate practical application of RICCO to VQE by classically simulating a small instance of VQE and comparing it to one of the existing circuit-cutting methods.

quant-ph↗

PennyLane: Automatic differentiation of hybrid quantum-classical computations

PennyLane is a Python 3 software framework for differentiable programming of quantum computers. The library provides a unified architecture for near-term quantum computing devices, supporting both qubit and continuous-variable paradigms. PennyLane's core feature is the ability to compute gradients of variational quantum circuits in a way that is compatible with classical techniques such as backpropagation. PennyLane thus extends the automatic differentiation algorithms common in optimization and machine learning to include quantum and hybrid computations. A plugin system makes the framework compatible with any gate-based quantum simulator or hardware. We provide plugins for hardware providers including the Xanadu Cloud, Amazon Braket, and IBM Quantum, allowing PennyLane optimizations to be run on publicly accessible quantum devices. On the classical front, PennyLane interfaces with accelerated machine learning libraries such as TensorFlow, PyTorch, JAX, and Autograd. PennyLane can be used for the optimization of variational quantum eigensolvers, quantum approximate optimization, quantum machine learning models, and many other applications.

quant-ph↗

Universal quantum circuits for quantum chemistry

Universal gate sets for quantum computing have been known for decades, yet no universal gate set has been proposed for particle-conserving unitaries, which are the operations of interest in quantum chemistry. In this work, we show that controlled single-excitation gates in the form of Givens rotations are universal for particle-conserving unitaries. Single-excitation gates describe an arbitrary $U(2)$ rotation on the two-qubit subspace spanned by the states $|01\rangle, |10\rangle$, while leaving other states unchanged -- a transformation that is analogous to a single-qubit rotation on a dual-rail qubit. The proof is constructive, so our result also provides an explicit method for compiling arbitrary particle-conserving unitaries. Additionally, we describe a method for using controlled single-excitation gates to prepare an arbitrary state of a fixed number of particles. We derive analytical gradient formulas for Givens rotations as well as decompositions into single-qubit and CNOT gates. Our results offer a unifying framework for quantum computational chemistry where every algorithm is a unique recipe built from the same universal ingredients: Givens rotations.

quant-ph↗

Quantum computing with differentiable quantum transforms

We present a framework for differentiable quantum transforms. Such transforms are metaprograms capable of manipulating quantum programs in a way that preserves their differentiability. We highlight their potential with a set of relevant examples across quantum computing (gradient computation, circuit compilation, and error mitigation), and implement them using the transform framework of PennyLane, a software library for differentiable quantum programming. In this framework, the transforms themselves are differentiable and can be parametrized and optimized, which opens up the possibility of improved quantum resource requirements across a spectrum of tasks.

quant-ph↗