Abstract We present a computational method to automatically design the n -qubit realisations of quantum algorithms. Our approach leverages a domain-specific language (DSL) that enables the construction of quantum circuits via modular building blocks, making it well-suited for evolutionary search. In this DSL quantum circuits are abstracted beyond the usual gate-sequence description and scale automatically to any problem size. This enables us to learn the algorithm structure rather than a specific unitary implementation. We demonstrate our method by automatically designing three known quantum algorithms—the Quantum Fourier Transform, the Deutsch-Jozsa algorithm, and Grover’s search. Remarkably, we were able to learn the general implementation of each algorithm by considering examples of circuits containing at most 5-qubits. Our method proves robust, as it maintains performance across increasingly large search spaces. Convergence to the relevant algorithm is achieved with high probability and with moderate computational resources.
Abstract We present a computational method to automatically design the n -qubit realisations of quantum algorithms. Our approach leverages a domain-specific language (DSL) that enables the construction of quantum circuits via modular building blocks, making it well-suited for evolutionary search. In this DSL quantum circuits are abstracted beyond the usual gate-sequence description and scale automatically to any problem size. This enables us to learn the algorithm structure rather than a specific unitary implementation. We demonstrate our method by automatically designing three known quantum algorithms—the Quantum Fourier Transform, the Deutsch-Jozsa algorithm, and Grover’s search. Remarkably, we were able to learn the general implementation of each algorithm by considering examples of circuits containing at most 5-qubits. Our method proves robust, as it maintains performance across increasingly large search spaces. Convergence to the relevant algorithm is achieved with high probability and with moderate computational resources.
Several prominent quantum computing algorithms—including Grover’s search algorithm and Shor’s algorithm for finding the prime factorization of an integer—employ subcircuits termed ‘oracles’ that embed a specific instance of a mathematical function into a corresponding bijective function that is then realized as a quantum circuit representation. Designing oracles, and particularly, designing them to be optimized for a particular use case, can be a non-trivial task. For example, the challenge of implementing quantum circuits in the current era of NISQ-based quantum computers generally dictates that they should be designed with a minimal number of qubits, as larger qubit counts increase the likelihood that computations will fail due to one or more of the qubits decohering. However, some quantum circuits require that function domain values be preserved, which can preclude using the minimal number of qubits in the oracle circuit. Thus, quantum oracles must be designed with a particular application in mind. In this work, we present two methods for automatic quantum oracle synthesis. One of these methods uses a minimal number of qubits, while the other preserves the function domain values while also minimizing the overall required number of qubits. For each method, we describe known quantum circuit use cases, and illustrate implementation using an automated quantum compilation and optimization tool to synthesize oracles for a set of benchmark functions; we can then compare the methods with metrics including required qubit count and quantum circuit complexity.
Quantum hardware continues to advance, yet finding new quantum algorithms - quantum software - remains a challenge, with classically trained computer programmers having little intuition of how computational tasks may be performed in the quantum realm. As such, the idea of developing automated tools for algorithm development is even more appealing for quantum computing than for classical. Here we develop a robust, multi-objective evolutionary search strategy to design quantum circuits 'from scratch', by combining and parameterizing a task-generic library of quantum circuit elements. When applied to 'ab initio' design of quantum circuits for the input/output mapping requirements of the quantum Fourier transform and Grover's search algorithm, it finds textbook circuit designs, along with alternative structures that achieve the same functionality. Exploiting its multi-objective nature, the discovery algorithm can trade off performance measures such as accuracy, circuit width or depth, gate count, or implementability - a crucial requirement for first-generation quantum processors and applications.
Designing effective quantum circuits remains a central challenge in quantum computing, as circuit structure strongly influences expressivity, trainability, and hardware feasibility. Current approaches, whether using manually designed circuit templates, fixed heuristics, or automated rules, face limitations in scalability, flexibility, and adaptability, often producing circuits that are poorly matched to the specific problem or quantum hardware. In this work, we propose the Evolutionary eXploration of Augmenting Quantum Circuits (EXAQC), an evolutionary approach to the automated design and training of parameterized quantum circuits (PQCs) which leverages and extends on strategies from neuroevolution and genetic programming. The proposed method jointly searches over gate types, qubit connectivity, parameterization, and circuit depth while respecting hardware and noise constraints. The method supports both Qiskit and Pennylane libraries, allowing the user to configure every aspect. This work highlights evolutionary search as a critical tool for advancing quantum machine learning and variational quantum algorithms, providing a principled pathway toward scalable, problem-aware, and hardware-efficient quantum circuit design. Preliminary results demonstrate that circuits evolved on classification tasks are able to achieve over 90% accuracy on most of the benchmark datasets with a limited computational budget, and are able to emulate target circuit quantum states with high fidelity scores.
Abstract. In order to design a quantum circuit that performs a desired quantum computation, it is necessary to find a decomposition of the unitary matrix that represents that computation in terms of a sequence of quantum gate operations. To date, such designs have either been found by hand or by exhaustive enumeration of all possible circuit topologjks. In this paper we propose an automated approach to quantum circuit design using search heuristics based on principles abstracted from evolutionary genetics, i.e. using a genetic programming algorithm adapted specially for this problem. We demonstrate the method on the task of discovering quantum circuit designs for quantum teleportation. We show that to find a given known circuit design (one which was hand-crafted by a human), the method considers roughly an order of magnitude fewer designs than naive enumeration. In addition, the method finds novel circuit designs superior to those previously known. 1
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 computing combined with machine learning, is a promising emerging field for tackling problems that are extremely expensive or fundamentally infeasible for classical computers. Nonetheless, design of the optimal quantum circuit for machine learning is a major challenge, which can be attributed to the exponential search space of the quantum gate arrangement and unmatched structured design methods. To resolve this, our work introduces a novel automated framework for quantum architecture search (AQAS) that adopts both meta-learning and evolutionary algorithms to automatically learn, transfer, and optimize quantum circuit architectures to suit different machine learning tasks. Our strategy relies on meta-learning to introduce a learning scheme, i.e. it allows the AQAS system to generalize across distributions by learning from a shared structural and functional prior from the distribution of machine learning problems. This enables the approach to quickly home in effective quantum circuit implementations for new tasks with low data or retraining. At the same time, we use evolutionary algorithms– mimicking natural selection– to breed populations of quantum circuit architectures. These circuits are represented in genotypes, are varied under mutation and crossover, and are selected according to a fitness function that blends quantum resource utilization (e.g., depth, qubits) with task-specific performance (e.g., classification accuracy or loss). The architecture is realized in a mixed quantum-classical environment, with quantum circuits simulated on quantum simulators and/or Noisy-Intermediate-Scale-Quantum (NISQ) devices. We verify the effectiveness of our approach on a number of benchmarked datasets and tasks which range from quantum-aided image recognition, time series prediction to medical diagnostics. We demonstrate that AQAS can discover compact, high-performing quantum models, which generalize better and are computationally more efficient than the custom-built quantum models.