The full quantum computing stack
Nitrogen fixation is a process by which nitrogen is taken from the atmosphere, in which it is abundant, and converted into forms that can be utilized by living organisms. The Haber-Bosch process was developed in the first half of the twentieth century and is the main industrial procedure used for artificial nitrogen fixation. The artificial production of fertilizers by the Haber-Bosch process has facilitated a period of unprecedented growth in human population but at significant cost – fertilizer production worldwide uses up to 2% of global energy and up to 5% of the world’s natural gas. The Haber-Bosch process is about 61% efficient and requires temperatures of 450°C alongside 200 atmospheres of pressure. Nature, however, can fix nitrogen at close to 100% efficiency, at room temperature and atmospheric pressure. It therefore must be possible to find some combination of catalysts and conditions providing vastly better efficiencies and saving huge quantities of energy. Quantum computers will provide a critical tool in the identification of new processes for artificial nitrogen fixation.
The Variational Quantum Eigensolver (VQE) is a quantum algorithm that could be used to compute the energy landscape of FeMoco. It is a variational algorithm in which a classical computer optimizes parameters of a quantum computation. In the setup of the problem we take the known structure of a molecule and construct a Hamiltonian for the system. The Hamiltonian of a system provides a description of how that system evolves in time and we want to find its ground state. Chemical Hamiltonians tend to have the useful property of being expressible in a small number of ‘terms’. Each term requires a number of measurements on the quantum computer for each optimization step and it is critical for the algorithm that the number of terms in the Hamiltonian does not grow too fast with the size of the molecule.
We code the problem in a high level quantum programming language. The research community has not yet settled on a singular framework for quantum programming. Various high level languages exist and are under development, such as ETH’s ProjectQ, IBM’s Qiskit and Rigetti’s Forest.
from projectq import MainEngine
from projectq.ops import All, Measure, QubitOperator, TimeEvolution eng = MainEngine() wavefunction = eng.allocate_qureg(2) # Specify a Hamiltonian in terms of Pauli operators: hamiltonian = QubitOperator(“X0 X1“) + 0.5 * QubitOperator(“Y0 Y1“) # Apply exp(-i * Hamiltonian * time) (without Trotter error) TimeEvolution(time=1, hamiltonian=hamiltonian) | wavefunction # Measure the expection value using the simulator shortcut: eng.flush() value = eng.backend.get_expectation_value(hamiltonian, wavefunction) # Last operation in any program should be measuring all qubits All(Measure) | qureg eng.flush()
OPENQASM 2.0; //
qreg q; //Create register with 4 qubits
Rx(pi/2) q; //Apply x rotation to first qubit
h q; h q; h q; //Apply Hadamard gate to other three qubits
cx q,q; cx q,q; cx q,q; //Apply three c-not gates
Rz(theta) q; //Apply phase rotation
cx q,q; cx q,q; cx q,q; //Apply three cnot gates
Rx(-pi/2) q; //Apply x rotation to first qubit
h q; h q; h q; //Apply Hadamard gate to other three qubits
To translate to the hardware we need some qubits. Currently, the leading qubits are superconducting and trapped ion based. We aim to answer the question of how the low level gate instructions are converted to the physical systems on which the computations occur.
Superconducting qubits exploit some of the most exotic physical phenomenon known. These occur in superconductors – macro-scale objects demonstrating quantum effects at fairly high temperature. Because superconductors demonstrate quantum effects at distance scales normally solidly in the classical regime, they are prime candidates for use as qubits. Current qubit designs can be up to a millimetre in size, facilitating the use of engineering techniques borrowed from the semiconductor industry. Key ingredients needed to create superconducting qubits are Josephson junctions, SQUID loops and couplers.
Operations on superconducting qubits are performed with microwaves, shone on the charge qubit resonant with the energy gap. This causes Rabi flopping to occur between the two energy levels. The time for which the microwave is applied must be controlled to high precision to produce the desired change in the system. Applying a resonant pulse for different time periods and phases allows any single-qubit operation to be performed. To carry out two-qubit operations, some coupling element must be placed between the qubits. This coupling can take many forms, for example, a third tunable qubit could be placed in-between facilitating swap-like operations. In this case the FPGA controls the coupling of the mediation qubits to apply two-qubit operations, and the single-qubit rotation controls, with microwave generators.
Trapped ion qubits
Trapped ion qubits have the longest coherence times of any variety. A few decades ago it was discovered that individual charged atoms can be cooled to near absolute zero and can be suspended with magnets and lasers. The energy levels of an electron in one of these extremely cold trapped ions can then be used to encode the |0⟩ and |1⟩ states of a qubit in such a way that environmental noise does not immediately corrupt the information. The charged atoms (isotopes of calcium can be used) are arranged in a string.
Paul traps allow ions to be suspended in magnetic fields if they are sufficiently cold. AC magnetic fields must be used to keep the ions stable as it is impossible to suspend a charged particle with stationary fields.
Measuring trapped ion qubits’ quantum states with high fidelity is generally difficult. For trapped ions, a technique called electron shelving is used, in which light is shone on a qubit such that if the qubit is in the |1⟩ state a transition to a higher state will occur. The transition is selected so that the atom will fluoresce when it is driven and the resulting photons are measured.
There is currently development at every level of the quantum computing stack. Companies such as Google, Rigetti and IBM are working to create bigger, lower error devices, while companies like Riverlane aim to reduce the system requirements of known algorithms. A few years ago, cloud-based devices of tens of qubits nearing threshold error rates did not exist. If the recent rates of development continue in both algorithmic and hardware development, the useful applications of quantum computers might arrive sooner than we expect.