Adaptive Circuits for Quantum Chemistry
Overview
Adaptive Circuits for Quantum Chemistry
This PennyLane demo implements adaptive circuit construction for quantum chemistry, a family of methods (such as ADAPT-VQE) that build a problem-tailored ansatz on the fly instead of using a fixed, generic circuit, often yielding much shallower, more accurate chemistry calculations. Fixed ansaetze like full unitary coupled cluster can be unnecessarily deep, including many operators that contribute little; adaptive methods instead grow the ansatz one operator at a time, at each step selecting from a pool of candidate excitation gates the one whose gradient indicates it will lower the energy the most, adding it, re-optimizing, and repeating until convergence. The tutorial shows how to implement this in PennyLane: defining the molecular Hamiltonian and a pool of single- and double-excitation operators, computing the energy gradient with respect to each candidate to rank them, iteratively appending the most useful gates, and re-optimizing the parameters after each addition. It applies the method to a small molecule and shows that the adaptively-grown circuit reaches accurate energies with far fewer gates than a fixed ansatz. By building the circuit to fit the problem, the demo illustrates a powerful, resource-efficient approach to variational quantum chemistry in PennyLane.
Run it
pip install -r requirements.txt
python demo.py
Source and license
Imported from demonstrations_v2/tutorial_adaptive_circuits/demo.py in PennyLaneAI/demos at c52c0abeb5122218aa96b38eea848864cce7323f, under the Apache License 2.0. Original authors: Xanadu and the PennyLane community. The upstream LICENSE is included alongside this example.
This entry was created automatically from publicly available records. QCR links to public sources and only stores repository content where the license permits redistribution.
Publication
doi:10.1038/s41467-019-10988-2Harper R. Grimsley, Sophia E. Economou, Edwin Barnes, Nicholas J. Mayhall
Versions
Cite all versions? Use the base QCR ID to always reference the latest version of this entry.
Join the Discussion
Comments (0)
No comments yet. Be the first to share your thoughts!