We apply numerical optimization and linear algebra algorithms for classical computers to the problem of automatically synthesizing algorithms for quantum computers. Using our framework, we apply several common techniques from these classical domains and numerically examine their suitability for and performance on this problem. Our methods are evaluated on single-qubit systems as well as on larger systems. While the first part of our proposed method outputs a single unitary matrix representing the composite effects of a quantum circuit or algorithm, we use existing tools—and assess the performance of these—to factor such a matrix into a product of elementary quantum gates. This enables our pipeline to be truly end-to-end: starting from desired input/output examples, our code ultimately results in a quantum circuit diagram. The code implementation is publicly available at https://github.com/DABH/qule .
We apply numerical optimization and linear algebra algorithms for classical computers to the problem of automatically synthesizing algorithms for quantum computers. Using our framework, we apply several common techniques from these classical domains and numerically examine their suitability for and performance on this problem. Our methods are evaluated on single-qubit systems as well as on larger systems. While the first part of our proposed method outputs a single unitary matrix representing the composite effects of a quantum circuit or algorithm, we use existing tools—and assess the performance of these—to factor such a matrix into a product of elementary quantum gates. This enables our pipeline to be truly end-to-end: starting from desired input/output examples, our code ultimately results in a quantum circuit diagram. The code implementation is publicly available at https://github.com/DABH/qule .
Quantum computing promises remarkable computational power with minimal energy consumption. However, the complexity of developing quantum circuits and codes hinders fully exploiting this potential. The study proposes an approach based on the automatic quantum circuit and code generation based on deep learning. It enables the resynthesis of existing circuits and the creation of new ones from undefined inputs. The system transforms inputs into reversible truth tables, generates a quantum unitary matrix, corrects errors, optimizes it, and converts it into a quantum code or circuit. This approach has been implemented on circuits and codes that involve up to five variables. Rigorous evaluations include both the Deep Neural Network and the overall approach. Although the DNN output does not guarantee absolute correctness, our approach compensates with supplementary processes, ensuring the precise generation of quantum codes and circuits. Comprehensive testing confirmed the approach's effectiveness in overcoming challenges in quantum circuit and code development. • Benefiting from the low energy and high computing power potential offered by quantum computing. • Developing quantum circuits and algorithms is a challenging task. • The number of competent people in the field who can develop quantum circuits and algorithms is low. • Classical algorithms do not work on quantum computers. • Insufficient number of quantum circuits and algorithms running on quantum computers.
Abstract Gate-level quantum circuits are often derived manually from higher level algorithms. While this suffices for small implementations and demonstrations, ultimately automatic circuit design will be required to realise complex algorithms using hardware-specific operations and connectivity. Therefore, ab initio creation of circuits within a machine, either a classical computer or a hybrid quantum–classical device, is of key importance. We explore a range of established and novel techniques for the synthesis of new circuit structures, the optimisation of parameterised circuits, and the efficient removal of low-value gates via the quantum geometric tensor. Using these techniques we tackle the tasks of automatic encoding of unitary processes and translation (recompilation) of a circuit from one form to another. Using emulated quantum computers with various noise-free gate sets we provide simple examples involving up to 10 qubits, corresponding to 20 qubits in the augmented space we use. Further applications of specific relevance to chemistry modelling are considered in a sister paper, ‘Exploiting subspace constraints and ab initio variational methods for quantum chemistry’. The emulation environments used were QuEST, QuESTlink and pyQuEST. All resources will be made openly accessible and are currently available upon request.
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.
A major hurdle to the deployment of quantum linear systems algorithms and recent quantum simulation algorithms lies in the difficulty to find inexpensive reversible circuits for arithmetic using existing hand coded methods. Motivated by recent advances in reversible logic synthesis, we synthesize arithmetic circuits using classical design automation flows and tools. The combination of classical and reversible logic synthesis enables the automatic design of large components in reversible logic starting from well-known hardware description languages such as Verilog. As a prototype example for our approach we automatically generate high quality networks for the reciprocal 1/x, which is necessary for quantum linear systems algorithms.
A major hurdle to the deployment of quantum linear systems algorithms and recent quantum simulation algorithms lies in the difficulty to find inexpensive reversible circuits for arithmetic using existing hand coded methods. Motivated by recent advances in reversible logic synthesis, we synthesize arithmetic circuits using classical design automation flows and tools. The combination of classical and reversible logic synthesis enables the automatic design of large components in reversible logic starting from well-known hardware description languages such as Verilog. As a prototype example for our approach we automatically generate high quality networks for the reciprocal 1/x, which is necessary for quantum linear systems algorithms.
A quantum computer is expected to solve some problems far faster than today's computers and may be a promising device with low power consumption.This computer is based on the physical theory of quantum mechanics.In the theory of quantum mechanics, quantum states and evolutions of quantum states are represented by vectors in a Hilbert space and unitary operators, respectively.A unitary matrix can then be regarded as an algorithm in the conventional computer.Since it is generally difficult to develop an arbitrary unitary matrix in a quantum system, quantum computation is carried out by combining elementary operations such as one-or two-qubit operations, where a qubit is the smallest unit of information in quantum computation.A unitary matrix is said to be performed effectively if there exists a quantum circuit composed of a polynomial number of elementary gates.Therefore, translating a unitary matrix into an efficient sequence of elementary gates is a fundamental problem in designing quantum circuits.In this dissertation, the problem involved in synthesizing minimal quantum circuits for carrying out any (large) quantum operation is described.The author considers two quantum systems, namely, the two-level quantum system and the d-level quantum system, where d is any integer greater than two.Here, the two-level quantum system can be regarded as a quantum mechanical analogue of conventional computation, and the d-level quantum system can be regarded as a quantum mechanical analogue of conventional multilevel logic.