Automated Quantum Chemistry Code Generation with the $p^\daggerq$ Package
Abstract
We present the most recent version of the \pq package, which is a Python library for generating equations and computer code for many-body quantum chemistry methods. Originally developed for prototyping single-reference electronic structure methods such as standard coupled-cluster (CC) and equation-of-motion (EOM) CC theory, the functionality in \pq has expanded to include boson operators, coupled fermion-boson operators, unitary cluster operators, non-particle-conserving EOM operators, spin tracing, multiple single-particle subspaces, and more. Additional developments allow for the generation of C++ and Python code that maximizes memory efficiency via careful analysis of contraction order and the reuse of intermediate tensor containers and minimizes floating-point operations by both contraction order and fusing like terms.