Skip to main content

View on GitHub

Open this notebook in GitHub to run it yourself
A potential energy curve gives the ground energy of an assembly of atoms as a function of the distances between them. The global minima of the curve indicates the binding energy and internuclear distance for the stable molecule. Therefore, such a curve can be powerful tool in computational chemistry for predicting the molecular structure and spectrum. This tutorial demonstrates how to use the Classiq chemistry package to create a molecule’s potential energy curve. It compares the result with the Hartree-Fock approximation method and the FCI (Full Configuration Interaction) energy.

Definitions and Initialization

Define the range of internuclear distances for the model to simulate, and choose the number of sampling points in this range, which determines the graph’s resolution.
Output:

Energy Estimations

Define a for-loop, which takes these steps:
  1. Creating a molecule at changing distances between the atoms.
  2. Constructing a chemistry model for the corresponding Hamiltonian, using the Hartree-Fock initial state and UCC ansatz.
  3. Synthesizing the model to get a quantum program.
  4. Executing the quantum program to extract a solution for the ground energy.
  5. Obtaining the exact solution and Hartree-Fock solution.
Output:
Output:
Output:
Output:
Output:
Output:
Output:
Output:
Output:
Output:
Output:
Output:

Graph Creation

output This graph presents the ground state for the H2H_{2} molecule as a function of the distance between the two hydrogen atoms. Note that both the HF solution and Classiq VQE present decent results around the global minima. For further distances, Classiq VQE stays close to the exact solution while the HF solution gradually deviates. The source of this lack of correspondence is with the lack of flexible correlations within the HF model, which is enabled within the VQE scope. You can explore more curves, creating graphs for different molecules (even n-dimensional or larger atom assemblies) in a similar fashion.