Tutorial - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Quantum Chemistry Package Tutorial Worksheet

Copyright (c) RDMCHEM LLC 2024

Overview

The QuantumChemistry package is an environment for computing and visualizing the quantum energies and properties of many-electron atoms and molecules.

In this tutorial we will teach the user to use the following basic features of the package:

 • Definition of a molecule's geometry from an interface, an XYZ file, or a web database containing more than 96 million molecules  (see section below)
 • Computation of a molecule's energies and properties from advanced wavefunction, density functional, and reduced density matrix methods (see section below)
 • Visualization of molecular geometries, densities, and vibrations through 3D interactive plots and animations (see section below)
 • Launch of an interactive Maplet (see section below) for a graphical user interface to the package commands for defining, computing, and visualizing molecular data
 • Integration of lessons and curricula in chemistry and physics (see section below) which can be used for formal courses as well as self study
 • Launch of the Maple help pages for the QuantumChemistry package for detailed information on each command (see section below)
 • See the What'sNew2024 help page for examples of what's new in the QuantumChemistry Package 2024.

We begin by loading the commands of the Quantum Chemistry package using the Maple with command

 > $\mathrm{with}\left(\mathrm{QuantumChemistry}\right);$
 $\left[{\mathrm{AOLabels}}{,}{\mathrm{ActiveSpaceCI}}{,}{\mathrm{ActiveSpaceSCF}}{,}{\mathrm{AtomicData}}{,}{\mathrm{BondAngles}}{,}{\mathrm{BondDistances}}{,}{\mathrm{Charges}}{,}{\mathrm{ChargesPlot}}{,}{\mathrm{ContractedSchrodinger}}{,}{\mathrm{CorrelationEnergy}}{,}{\mathrm{CoupledCluster}}{,}{\mathrm{DensityFunctional}}{,}{\mathrm{DensityPlot3D}}{,}{\mathrm{Dipole}}{,}{\mathrm{DipolePlot}}{,}{\mathrm{Energy}}{,}{\mathrm{ExcitationEnergies}}{,}{\mathrm{ExcitationSpectra}}{,}{\mathrm{ExcitationSpectraPlot}}{,}{\mathrm{ExcitedStateEnergies}}{,}{\mathrm{ExcitedStateSpins}}{,}{\mathrm{ExcitonDensityPlot}}{,}{\mathrm{ExcitonPopulations}}{,}{\mathrm{ExcitonPopulationsPlot}}{,}{\mathrm{FullCI}}{,}{\mathrm{GeometryOptimization}}{,}{\mathrm{HartreeFock}}{,}{\mathrm{Interactive}}{,}{\mathrm{Isotopes}}{,}{\mathrm{LiteratureSearch}}{,}{\mathrm{MOCoefficients}}{,}{\mathrm{MODiagram}}{,}{\mathrm{MOEnergies}}{,}{\mathrm{MOIntegrals}}{,}{\mathrm{MOOccupations}}{,}{\mathrm{MOOccupationsPlot}}{,}{\mathrm{MOSymmetries}}{,}{\mathrm{MP2}}{,}{\mathrm{MolecularData}}{,}{\mathrm{MolecularDictionary}}{,}{\mathrm{MolecularGeometry}}{,}{\mathrm{NuclearEnergy}}{,}{\mathrm{NuclearGradient}}{,}{\mathrm{OscillatorStrengths}}{,}{\mathrm{Parametric2RDM}}{,}{\mathrm{PlotMolecule}}{,}{\mathrm{Populations}}{,}{\mathrm{Purify2RDM}}{,}{\mathrm{QuantumComputing}}{,}{\mathrm{RDM1}}{,}{\mathrm{RDM2}}{,}{\mathrm{RTM1}}{,}{\mathrm{ReadXYZ}}{,}{\mathrm{Restore}}{,}{\mathrm{Save}}{,}{\mathrm{SaveXYZ}}{,}{\mathrm{SearchBasisSets}}{,}{\mathrm{SearchFunctionals}}{,}{\mathrm{SkeletalStructure}}{,}{\mathrm{SolventDatabase}}{,}{\mathrm{Thermodynamics}}{,}{\mathrm{TransitionDipolePlot}}{,}{\mathrm{TransitionDipoles}}{,}{\mathrm{TransitionOrbitalPlot}}{,}{\mathrm{TransitionOrbitals}}{,}{\mathrm{Variational2RDM}}{,}{\mathrm{VibrationalModeAnimation}}{,}{\mathrm{VibrationalModes}}{,}{\mathrm{Video}}\right]$ (2.1)

We recommend setting the global variable Digits to 15 (double precision) rather than 10 (default):

 > $\mathrm{Digits}≔15;$
 ${\mathrm{Digits}}{≔}{15}$ (2.2)
 >

Definition of a Molecule

A molecule's geometry can be defined in the worksheet interface in three ways:

 1 entering the geometry as a Maple list of lists
 2 reading the geometry from an XYZ file
 3 retrieving the geometry from a web database

Maple List of Lists

Let us first enter the geometry of the molecule hydrogen fluoride HF by using a Maple list of lists.  Each list has four elements:

 1 a string of the atomic symbol of the atom, i.e. "H" or "F"
 2 the x Cartesian coordinate of the atom
 3 the y Cartesian coordinate of the atom
 4 the z Cartesian coordinate of the atom

The default unit of distance in the package is Angstroms (1 Angstrom m), which we employ in this worksheet.

 > $\mathrm{hf}≔\left[\left["H",0,0,-0.48\right],\left["F",0,0,0.48\right]\right];$
 ${\mathrm{hf}}{≔}\left[\left[{"H"}{,}{0}{,}{0}{,}{-0.48000000}\right]{,}\left[{"F"}{,}{0}{,}{0}{,}{0.48000000}\right]\right]$ (3.1.1)
 >

Web Database

Second, we can retrieve the geometry of a molecule from a web database containing more than 96 million molecules.  The database is especially useful for molecules with more than a few atoms.  To perform the search, we use the command MolecularGeometry (the computer must be connected to the web).

 > $\mathrm{hf}≔\mathrm{MolecularGeometry}\left("hydrogen fluoride"\right);$
 ${\mathrm{hf}}{≔}\left[\left[{"F"}{,}{0}{,}{0}{,}{0}\right]{,}\left[{"H"}{,}{0.43580000}{,}{-0.14770000}{,}{-0.81880000}\right]\right]$ (3.2.1)
 >

XYZ File

Second, we can read the geometry of a molecule from an XYZ file, that is a file containing the Cartesian coordinates of each atom.  For example, the XYZ file of hydrogen fluoride has the following format:

2

# Comment Line: Note that we give the total number of atoms in the first line, a comment in the second line, and then the Cartesian coordinates of the atoms in the remaining lines
H 0 0 0

F  0 0 0.95

To save an XYZ file, we use the command SaveXYZ to make an XYZ file from the Maple list of lists.  To read the resulting XYZ file, we use the command ReadXYZ.

Invoking ReadXYZ without a parameter ReadXYZ() opens a file dialogue for selecting an XYZ file.  Invoking ReadXYZ with a string parameter opens the file associated with the string name.  If the file is not present in Maple's current working directory, the string must contain the full path to the file or Maple's current working directory must modified by using the currentdir command.  For example, the XYZ file for porphin "porphin.xyz" can be read from the data folder of the package.  First we construct a full path to the file

 >

Then we call ReadXYZ to read the XYZ file into the QuantumChemistry package's molecular geometry format

 >
 ${\mathrm{porphin}}{≔}\left[\left[{"N"}{,}{-1.62058500}{,}{-1.35841100}{,}{-0.00004500}\right]{,}\left[{"N"}{,}{1.62042400}{,}{-1.35852600}{,}{-0.00009500}\right]{,}\left[{"N"}{,}{-1.57898000}{,}{1.33345500}{,}{0.00027900}\right]{,}\left[{"N"}{,}{1.57912800}{,}{1.33329300}{,}{-0.00026600}\right]{,}\left[{"C"}{,}{-1.27247000}{,}{-2.69668000}{,}{0.00024100}\right]{,}\left[{"C"}{,}{1.27217700}{,}{-2.69676300}{,}{0.00031100}\right]{,}\left[{"C"}{,}{-3.00281900}{,}{-1.21613100}{,}{-0.00051500}\right]{,}\left[{"C"}{,}{3.00267300}{,}{-1.21642300}{,}{-0.00028500}\right]{,}\left[{"C"}{,}{-0.00016600}{,}{-3.27300100}{,}{0.00055400}\right]{,}\left[{"C"}{,}{-2.51334300}{,}{-3.43612200}{,}{0.00013200}\right]{,}\left[{"C"}{,}{2.51294900}{,}{-3.43634000}{,}{0.00024600}\right]{,}\left[{"C"}{,}{-3.55872200}{,}{-2.54069000}{,}{-0.00034400}\right]{,}\left[{"C"}{,}{3.55842900}{,}{-2.54101500}{,}{0.00016400}\right]{,}\left[{"C"}{,}{-3.63768700}{,}{0.02511200}{,}{-0.00061100}\right]{,}\left[{"C"}{,}{3.63773300}{,}{0.02474200}{,}{-0.00044500}\right]{,}\left[{"C"}{,}{-2.95501700}{,}{1.24875700}{,}{-0.00024700}\right]{,}\left[{"C"}{,}{2.95521500}{,}{1.24846000}{,}{-0.00035900}\right]{,}\left[{"C"}{,}{-1.27258700}{,}{2.67294600}{,}{0.00036400}\right]{,}\left[{"C"}{,}{1.27286200}{,}{2.67274100}{,}{0.00017600}\right]{,}\left[{"C"}{,}{0.00017500}{,}{3.25342200}{,}{0.00036700}\right]{,}\left[{"C"}{,}{-3.55030400}{,}{2.58382300}{,}{-0.00002800}\right]{,}\left[{"C"}{,}{3.55059000}{,}{2.58346400}{,}{-0.00045100}\right]{,}\left[{"C"}{,}{-2.50983200}{,}{3.46576200}{,}{0.00046900}\right]{,}\left[{"C"}{,}{2.51016700}{,}{3.46547700}{,}{0.00019800}\right]{,}\left[{"H"}{,}{-0.00017100}{,}{-4.35835700}{,}{0.00090700}\right]{,}\left[{"H"}{,}{-1.06231600}{,}{-0.49153600}{,}{0.00028100}\right]{,}\left[{"H"}{,}{1.06235700}{,}{-0.49148500}{,}{0.00004000}\right]{,}\left[{"H"}{,}{-2.57314000}{,}{-4.51439200}{,}{0.00038500}\right]{,}\left[{"H"}{,}{2.57252600}{,}{-4.51461900}{,}{0.00038400}\right]{,}\left[{"H"}{,}{-4.61490100}{,}{-2.76464200}{,}{-0.00062200}\right]{,}\left[{"H"}{,}{4.61460100}{,}{-2.76500800}{,}{0.00017400}\right]{,}\left[{"H"}{,}{-4.72223800}{,}{0.03505700}{,}{-0.00090700}\right]{,}\left[{"H"}{,}{4.72228200}{,}{0.03449200}{,}{-0.00050400}\right]{,}\left[{"H"}{,}{0.00026800}{,}{4.34141600}{,}{0.00063100}\right]{,}\left[{"H"}{,}{-4.60947300}{,}{2.79979000}{,}{-0.00015400}\right]{,}\left[{"H"}{,}{4.60975700}{,}{2.79940900}{,}{-0.00066000}\right]{,}\left[{"H"}{,}{-2.55314700}{,}{4.54611800}{,}{0.00079700}\right]{,}\left[{"H"}{,}{2.55354400}{,}{4.54583900}{,}{0.00050700}\right]\right]$ (3.3.1)
 > 

Computations

Computations of molecules can be performed in one of two ways:

 1 Maple commands based on the energy or property to be computed
 2 Maple commands based on the quantum chemistry method to be employed

Energies/Properties

The QuantumChemistry package contains commands to compute directly the following energies and properties:

 • energy
 • correlation energy
 • nuclear energy
 • molecular orbital coefficients
 • molecular orbital occupations
 • molecular orbital energies
 • orbital symmetries
 • atomic-orbital populations and charges
 • dipole moments
 • excited-state energies
 • excited-state spins
 • excitation spectra
 • transition dipole moments
 • oscillator strengths
 • natural transition orbitals
 • thermodynamic properties
 • 1-electron reduced density matrix (1-RDM)
 • 2-electron reduced density matrix (2-RDM)
 • 1-electron reduced transition matrices (1-RTMs)

Unless otherwise noted, all energies are in atomic units (a.u.).

The energy of hydrogen fluoride HF, for example, can be directly computed from the Hartree-Fock method from the command Energy

 > $\mathrm{Energy}\left(\mathrm{hf},\mathrm{method}=\mathrm{HartreeFock}\right);$
 ${-98.57249547}$ (4.1.1)

Each energy/property command can take all of the options, specified by optional keywords, available for the given method.  For instance, we can specify a larger basis set with the basis keyword

 > $\mathrm{Energy}\left(\mathrm{hf},\mathrm{method}=\mathrm{HartreeFock},\mathrm{basis}="cc-pvdz"\right);$
 ${-100.01804664}$ (4.1.2)

We can select a different method for computing the energy

 > $\mathrm{Energy}\left(\mathrm{hf},\mathrm{method}=\mathrm{DensityFunctional},\mathrm{basis}="cc-pvdz"\right);$
 ${-100.39764610}$ (4.1.3)

The nuclear energy from the repulsion of the nuclei in the molecule can be computed with the command NuclearEnergy

 > $\mathrm{NuclearEnergy}\left(\mathrm{hf}\right);$
 ${5.07069443}$ (4.1.4)

The energies of the molecular orbitals can be computed with the command MOEnergies

 > $\mathrm{MOEnergies}\left(\mathrm{hf},\mathrm{method}=\mathrm{HartreeFock}\right);$
 $\left[\begin{array}{c}{-25.90202575}\\ {-1.46443647}\\ {-0.57855098}\\ {-0.46350983}\\ {-0.46350983}\\ {0.60611202}\end{array}\right]$ (4.1.5)

The occupations of the molecular orbitals can be computed with the command MOOccupations

 > $\mathrm{MOOccupations}\left(\mathrm{hf},\mathrm{method}=\mathrm{HartreeFock}\right);$
 $\left[\begin{array}{c}{2.00000000}\\ {2.00000000}\\ {2.00000000}\\ {2.00000000}\\ {2.00000000}\\ {0.}\end{array}\right]$ (4.1.6)

The occupations being 2 (filled) or 0 (unfilled) reflect that the Hartree-Fock method does not correlate the orbitals describing the electrons.  Using the command MOOccupations with a correlated method like the variational 2-RDM method generates fractional occupations, that is occupations between 0 and 2

 >
 $\left[\begin{array}{c}{2.00000000}\\ {2.00000000}\\ {1.99925285}\\ {1.99925284}\\ {1.97401166}\\ {0.02748258}\end{array}\right]$ (4.1.7)

The 1-electron reduced density matrix (1-RDM) can be calculated from the variational 2-RDM method with the command RDM1

 > $\mathrm{dm1}≔\mathrm{RDM1}\left(\mathrm{hf},\mathrm{method}=\mathrm{Variational2RDM},\mathrm{active}=\left[6,4\right]\right);$
 ${\mathrm{dm1}}{≔}\left[\begin{array}{cccc}{1.97372420}& {0.}& {0.}& {-0.02365336}\\ {0.}& {1.99925284}& {0.}& {0.}\\ {0.}& {0.}& {1.99925285}& {0.}\\ {-0.02365336}& {0.}& {0.}& {0.02777004}\end{array}\right]$ (4.1.8)

The eigenvalues of the 1-RDM are the occupations of its eigenvectors, known as natural orbitals.  It is the occupations of the natural orbitals that are returned by the command MOOccupations.  To confirm that this is true for the variational 2-RDM method, we can calculate the eigenvalues of the 1-RDM with the Eigenvalues command in the LinearAlgebra package.  First, we ensure that dm1 is a symmetric matrix which will have real eigenvalues,

 > $\mathrm{dm1}≔\mathrm{Matrix}\left(\mathrm{dm1},\mathrm{shape}=\mathrm{symmetric}\right);$
 ${\mathrm{dm1}}{≔}\left[\begin{array}{cccc}{1.97372420}& {0.}& {0.}& {-0.02365336}\\ {0.}& {1.99925284}& {0.}& {0.}\\ {0.}& {0.}& {1.99925285}& {0.}\\ {-0.02365336}& {0.}& {0.}& {0.02777004}\end{array}\right]$ (4.1.9)

and then we compute the eigenvalues

 > $\mathrm{eigs}≔\mathrm{LinearAlgebra}:-\mathrm{Eigenvalues}\left(\mathrm{dm1}\right);$
 ${\mathrm{eigs}}{≔}\left[\begin{array}{c}{0.02748258}\\ {1.97401166}\\ {1.99925284}\\ {1.99925285}\end{array}\right]$ (4.1.10)

The eigenvalues reveal the number of electrons in each natural orbital.  The deviation of the eigenvalues from 0 and 2 reveals the presence of electron correlation.  With a knowledge of the 1-RDM other important one-electron properties can be computed.

The Energy command is especially useful for generating potential energy curves (and surfaces) with just a few lines of code.  For example, the following five lines generate the potential energy of hydrogen fluoride from the Hartree-Fock method with the internuclear distance ranging from 0.8 Angstroms to 2.0 Angstroms in 0.05 increments

 > $\mathrm{rdata}≔\left[\mathrm{seq}\left(r,r=0.8..2.0,0.05\right)\right]:$
 > $\mathrm{molecules}≔\left[\mathrm{seq}\left(\left[\left["H",0,0,0\right],\left["F",0,0,i\right]\right],i=0.8..2.0,0.05\right)\right]:$
 > $\mathrm{edata_hf}≔\mathrm{map}\left(\mathrm{Energy},\mathrm{molecules},\mathrm{method}=\mathrm{HartreeFock}\right):$
 > $\mathrm{pes_hf}≔\mathrm{spline}\left(\mathrm{rdata},\mathrm{edata_hf},R,1\right):$
 > $\mathrm{plot_hf}≔\mathrm{plot}\left(\mathrm{pes_hf},R=0.8..2.0,\mathrm{axes}=\mathrm{BOXED},\mathrm{font}=\left[\mathrm{ROMAN},16\right],\mathrm{labelfont}=\left[\mathrm{ROMAN},16\right],\mathrm{labels}=\left['R','E'\right],\mathrm{color}=\mathrm{blue}\right);$

A similar point plot can be generated from the full solution of the Schrodinger equation in the given basis set, known as full configuration interaction

 > $\mathrm{edata_ci}≔\mathrm{map}\left(\mathrm{Energy},\mathrm{molecules},\mathrm{method}=\mathrm{ActiveSpaceCI},\mathrm{active}=\left\{3,4,5,6\right\}\right):$
 > $\mathrm{pes_hf}≔\left[\mathrm{seq}\left(\left[{\mathrm{rdata}}_{i},{\mathrm{edata_ci}}_{i}\right],i=1..\mathrm{nops}\left(\mathrm{rdata}\right)\right)\right]:$
 > $\mathrm{plot_ci}≔\mathrm{plots}:-\mathrm{pointplot}\left(\mathrm{pes_hf},\mathrm{axes}=\mathrm{BOXED},\mathrm{font}=\left[\mathrm{ROMAN},16\right],\mathrm{labelfont}=\left[\mathrm{ROMAN},16\right],\mathrm{symbolsize}=16,\mathrm{labels}=\left['R','E'\right],\mathrm{color}=\mathrm{black}\right);$

Finally, a plot can be generated from the variational 2-RDM method in which the correlated 2-RDM is directly computed without computing the many-electron wavefunction

 > $\mathrm{edata_2rdm}≔\mathrm{map}\left(\mathrm{Energy},\mathrm{molecules},\mathrm{method}=\mathrm{Variational2RDM},\mathrm{symmetry}=\mathrm{true},\mathrm{conditions}="DQ",\mathrm{active}=\left\{3,4,5,6\right\}\right):$
 > $\mathrm{pes_2rdm}≔\mathrm{spline}\left(\mathrm{rdata},\mathrm{edata_2rdm},R,1\right):$
 > $\mathrm{plot_2rdm}≔\mathrm{plot}\left(\mathrm{pes_2rdm},R=0.8..2.0,\mathrm{axes}=\mathrm{BOXED},\mathrm{font}=\left[\mathrm{ROMAN},16\right],\mathrm{labelfont}=\left[\mathrm{ROMAN},16\right],\mathrm{labels}=\left['R','E'\right],\mathrm{color}=\mathrm{red}\right);$

The three plots can be readily displayed together to reveal that the energies from the variational 2-RDM calculations exactly match those from the full configuration interaction.  .

 > $\mathrm{plots}:-\mathrm{display}\left(\left\{\mathrm{plot_ci},\mathrm{plot_hf},\mathrm{plot_2rdm}\right\}\right);$

In contrast to the 2-RDM and full configuration methods, the Hartree-Fock method yields a potential energy curve whose minimum energy occurs at an internuclear distance R that is too short and whose curvature at the minimum energy is too large.

Optimization of a molecule's geometry to reach a first-order critical point such as a minimum or a transition state can be performed with the command GeometryOptimization.  Furthermore, the vibrational frequencies of a molecule in the normal-mode approximation can be computed with the command VibrationalModes.  For example, we can optimize the internuclear distance of the hydrogen fluoride molecule by the Hartree-Fock method

 > $\mathrm{hf_hf},\mathrm{data_hf}≔\mathrm{GeometryOptimization}\left(\mathrm{hf},\mathrm{HartreeFock}\right):$
 $\left[\left[{"F"}{,}{-0.00376378}{,}{0.00127561}{,}{0.00707155}\right]{,}\left[{"H"}{,}{0.43956378}{,}{-0.14897561}{,}{-0.82587155}\right]\right]$ (4.1.11)

Because the fluorine is located at the origin, the bond distance can be computed as follows

 >
 ${\mathrm{bonddistance_hf}}{≔}{0.95546270}$ (4.1.12)

Once the optimized geometry is known, the vibrational frequency of the bond can be determined to be 4459 ${\mathrm{cm}}^{-1}$ from

 > $\mathrm{emode},\mathrm{vmode}≔\mathrm{VibrationalModes}\left(\mathrm{hf_hf},\mathrm{HartreeFock}\right);$
 ${\mathrm{emode}}{,}{\mathrm{vmode}}{≔}\left[\begin{array}{c}{4458.50363636}\end{array}\right]{,}\left[\begin{array}{c}{0.10414645}\\ {-0.03529699}\\ {-0.19567489}\\ {-0.45215325}\\ {0.15324239}\\ {0.84952527}\end{array}\right]$ (4.1.13)

Similarly, we can find optimize the internuclear distance by the variational 2-RDM method, using the D and Q N-representability conditions and freezing the core orbitals,

 > $\mathrm{hf_2rdm},\mathrm{data_2rdm}≔\mathrm{GeometryOptimization}\left(\mathrm{hf},\mathrm{Variational2RDM},\mathrm{conditions}="DQ",\mathrm{active}=\left\{3,4,5,6\right\}\right):$ $\mathrm{hf_2rdm};$
 $\left[\left[{"F"}{,}{-0.01249964}{,}{0.00423634}{,}{0.02348487}\right]{,}\left[{"H"}{,}{0.44829964}{,}{-0.15193634}{,}{-0.84228487}\right]\right]$ (4.1.14)

In this case the equilibrium bond distance, the distance at which the minimum energy occurs, is

 > $\mathrm{bonddistance_2rdm}≔\mathrm{BondDistances}\left(\mathrm{hf_2rdm},1,2\right);$
 ${\mathrm{bonddistance_2rdm}}{≔}{0.99311789}$ (4.1.15)

The vibrational frequency of the bond can be determined in ${\mathrm{cm}}^{-1}$ from

 > $\mathrm{emode},\mathrm{vmode}≔\mathrm{VibrationalModes}\left(\mathrm{hf_2rdm},\mathrm{Variational2RDM},\mathrm{conditions}="DQ",\mathrm{active}=\left\{3,4,5,6\right\}\right);$
 ${\mathrm{emode}}{,}{\mathrm{vmode}}{≔}\left[\begin{array}{c}{3780.92884067}\end{array}\right]{,}\left[\begin{array}{c}{0.10408256}\\ {-0.03519865}\\ {-0.19572664}\\ {-0.45187632}\\ {0.15281544}\\ {0.84974949}\end{array}\right]$ (4.1.16)

As in the plots above, we observe that the treatment of electron correlation by the variational 2-RDM method causes the equilibrium bond length to increase to 0.993 from 0.955 Angstroms and the vibrational frequency in wavenumbers to decrease significantly from 4459 ${\mathrm{cm}}^{-1}.$

Methods

The QuantumChemistry package can solve the Schrodinger equation of atoms and molecules by several different methods.  The methods can be employed in the Energy and other commands of the previous section, and they can also be called directly. Supported methods include:

 • Hartree-Fock (HF) methods
 • Density Functional Theory (DFT) methods
 • RDM Functional Theory (RDMFT) method
 • Variational Two-electron Reduced Density Matrix (2-RDM) method
 • Parametric Two-electron Reduced Density Matrix (2-RDM) method
 • Anti-Hermitian Contracted Schrödinger Equation (CSE) method
 • Full Configuration Interaction (FCI) method
 • Second-order Many-body Perturbation Theory (MP2) method
 • Coupled Cluster Singles-Doubles (CCSD) method
 • Complete-Active-Space Configuration Interaction (CAS-CI) method
 • Complete-Active-Space Self-Consistent-Field (CAS-SCF) method
 • Time-dependent Hartree-Fock (TDHF) method (via the HartreeFock command)
 • Configuration-Interaction Singles (CIS) method (via the HartreeFock command)
 • Time-dependent Density Functional Theory (TDDFT) method (via the DensityFunctional command)
 • Tamm-Dancoff Approximation (TDA)  method (via the DensityFunctional command)

The Hartree-Fock method, for example, can be invoked by the HartreeFock command

 >

As described in the help page for the HartreeFock command, which can be opened by clicking on the hyperlink, each method has the molecule's geometry as a Maple list of lists as its first argument.  Additional keyword arguments can be provided to control the charge, spin, symmetry, and basis set as well as technical details of the solution method.  Complete information about these options is provided on the help page.  Running a method's command returns a Maple table containing entries that correspond to generated data such as the total electronic energy, the coefficients of the molecular orbitals in terms of the atomic orbitals, the electron occupations of the molecular orbitals, the energies of the orbitals, the symmetries of the orbitals, the 1- and 2-electron reduced density matrices, the name of the point-group symmetry, and a parameter indicating convergence (set to one) or non-convergence (set to zero).  The total energy from the data table can be accessed as follows:

 > ${\mathrm{data}}_{\mathrm{e_tot}}$
 ${-100.02155522}$ (4.2.1)

Similarly, the energies of the molecular orbitals can be retrieved as follows

 > ${\mathrm{data}}_{\mathrm{mo_energy}}$

Rerunning the command takes a negligible amount of CPU time because the result is stored in a cache table.

The variational 2-RDM method, as another example, can be invoked by the Variational2RDM command

 >

The basis set of the molecule can be changed using the basis keyword.  The basis keyword supports a wide range of basis sets including mixed basis sets in which each atom type has its own basis set as well as effective core potential (ECP) basis sets for heavy atoms (see Basis for details).

 > $\mathrm{data1}≔\mathrm{HartreeFock}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz"\right):$

The charge of the molecule can be changed using the charge and spin keywords

 > $\mathrm{data2}≔\mathrm{HartreeFock}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz",\mathrm{charge}=1,\mathrm{spin}=1\right):$

From the two energies we can estimate the ionization energy, the energy to remove an electron as 0.531 a.u.

 > $\mathrm{ie}≔{\mathrm{data2}}_{\mathrm{e_tot}}-{\mathrm{data1}}_{\mathrm{e_tot}}$
 ${\mathrm{ie}}{≔}{0.53141295}$ (4.2.2)

which (at least at this level of approximation) is slightly greater than the energy to ionize the hydrogen atom.

Density functional theory (DFT) can be invoked by the DensityFunctional command

 > $\mathrm{data1}≔\mathrm{DensityFunctional}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz"\right):$

As with the Hartree-Fock method the charge of the molecule can be changed using the charge and spin keywords

 > $\mathrm{data2}≔\mathrm{DensityFunctional}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz",\mathrm{charge}=1,\mathrm{spin}=1\right):$

From DFT with the default B3LYP functional the energy to remove an electron is 0.596 a.u.

 > $\mathrm{ie}≔{\mathrm{data2}}_{\mathrm{e_tot}}-{\mathrm{data1}}_{\mathrm{e_tot}}$
 ${\mathrm{ie}}{≔}{0.59619956}$ (4.2.3)

Second-order many-body perturbation theory (MP2) can be run with the MP2 command

 > $\mathrm{data1}≔\mathrm{MP2}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz"\right):$

As with the Hartree-Fock and the DFT method the molecule can be treated with the +1 charge

 > $\mathrm{data2}≔\mathrm{MP2}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz",\mathrm{charge}=1,\mathrm{spin}=1\right):$

From MP2 the energy to remove an electron is 0.552 atomic units of energy

 > $\mathrm{ie}≔{\mathrm{data2}}_{\mathrm{e_tot}}-{\mathrm{data1}}_{\mathrm{e_tot}}$
 ${\mathrm{ie}}{≔}{0.55160015}$ (4.2.4)

MP2 in the aug-cc-pVDZ basis set predicts a lower ionization energy for hydrogen fluoride than DFT with the B3LYP functional.

The parametric 2-RDM method can be run with the Parametric2RDM command

 > $\mathrm{data1}≔\mathrm{Parametric2RDM}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz"\right):$

As with the Hartree-Fock and the DFT method the molecule can be treated with the +1 charge

 > $\mathrm{data2}≔\mathrm{Parametric2RDM}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz",\mathrm{charge}=1,\mathrm{spin}=1\right):$

From parametric 2-RDM the energy to remove an electron is 0.586 atomic units of energy

 > $\mathrm{ie}≔{\mathrm{data2}}_{\mathrm{e_tot}}-{\mathrm{data1}}_{\mathrm{e_tot}}$
 ${\mathrm{ie}}{≔}{0.58562861}$ (4.2.5)

Parametric 2-RDM in the aug-cc-pVDZ basis set predicts a slightly lower ionization energy for hydrogen fluoride than DFT with the B3LYP functional.

The anti-Hermitian contracted Schrödinger equation (ACSE) method can be run with the ContractedSchrodinger command

 >

As with Hartree-Fock, DFT, and the Parametric2RDM method the molecule can be treated with the +1 charge

 >

From the ACSE the energy to remove an electron is 0.539 atomic units of energy

 > $\mathrm{ie}≔{\mathrm{data2}}_{\mathrm{e_tot}}-{\mathrm{data1}}_{\mathrm{e_tot}}$
 ${\mathrm{ie}}{≔}{0.53884898}$ (4.2.6)

The ACSE ionization energy is higher than that from the Hartree-Fock method but lower than that from the parametric 2-RDM method.

The coupled cluster method with single and double excitations can be run with the CoupledCluster command

 > $\mathrm{data1}≔\mathrm{CoupledCluster}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz"\right):$

As with the Hartree-Fock and the DFT method the molecule can be treated with the +1 charge

 > $\mathrm{data2}≔\mathrm{CoupledCluster}\left(\mathrm{hf},\mathrm{basis}="aug-cc-pvdz",\mathrm{charge}=1,\mathrm{spin}=1\right):$

From coupled cluster the energy to remove an electron is 0.585 atomic units of energy

 > $\mathrm{ie}≔{\mathrm{data2}}_{\mathrm{e_tot}}-{\mathrm{data1}}_{\mathrm{e_tot}}$
 ${\mathrm{ie}}{≔}{0.58533448}$ (4.2.7)

The coupled cluster singles-doubles result is close to that from the parametric 2-RDM method.

The excited spectra of hydrogen fluoride can be computed from time-dependent density functional theory (TDDFT) with the ExcitationSpectra command

 >

 State Energy Wavelength Spin Oscillator $1$ $8.83272265⟦\mathrm{eV}⟧$ $140.36917303⟦\mathrm{nm}⟧$ Triplet $0.03753967$ $2$ $8.83272575⟦\mathrm{eV}⟧$ $140.36912368⟦\mathrm{nm}⟧$ Triplet $0.03753965$ $3$ $9.25846857⟦\mathrm{eV}⟧$ $133.91436875⟦\mathrm{nm}⟧$ Singlet $0.03516694$ $4$ $9.25847182⟦\mathrm{eV}⟧$ $133.91432172⟦\mathrm{nm}⟧$ Singlet $0.03516693$ $5$ $11.99880830⟦\mathrm{eV}⟧$ $103.33042610⟦\mathrm{nm}⟧$ Triplet $0.40290203$ $6$ $12.38162341⟦\mathrm{eV}⟧$ $100.13565532⟦\mathrm{nm}⟧$ Triplet $0.01137906$ $7$ $12.38162658⟦\mathrm{eV}⟧$ $100.13562965⟦\mathrm{nm}⟧$ Triplet $0.01137904$ $8$ $12.64008197⟦\mathrm{eV}⟧$ $98.08812769⟦\mathrm{nm}⟧$ Singlet $0.00602209$ $9$ $12.64008532⟦\mathrm{eV}⟧$ $98.08810170⟦\mathrm{nm}⟧$ Singlet $0.00602209$ $10$ $13.18586379⟦\mathrm{eV}⟧$ $94.02811934⟦\mathrm{nm}⟧$ Singlet $0.13597576$ $11$ $13.21703694⟦\mathrm{eV}⟧$ $93.80634854⟦\mathrm{nm}⟧$ Triplet $0.00272417$ $12$ $14.32133712⟦\mathrm{eV}⟧$ $86.57305972⟦\mathrm{nm}⟧$ Singlet $0.00177742$

The ExcitationSpectraPlot command generates an excitation spectra from the computed data

 > $\mathrm{ExcitationSpectraPlot}\left(\mathrm{hf},\mathrm{ex_table}\right);$

Other available methods include the coupled cluster method with single, double, and perturbative triple excitations [CCSD(T)].  For example, the ground-state CCSD(T) energy of hydrogen fluoride in the default basis set can be computed with the CoupledCluster command

 >
 ${\mathrm{data_cc}}{≔}{table}{}\left(\left[{\mathrm{populations}}{=}\left[\begin{array}{c}{1.99914076}\\ {1.95182047}\\ {1.83289245}\\ {1.98027767}\\ {1.41160949}\\ {0.82425915}\end{array}\right]{,}{\mathrm{converged}}{=}{1}{,}{\mathrm{charges}}{=}\left[\begin{array}{c}{-0.17574085}\\ {0.17574085}\end{array}\right]{,}{\mathrm{dipole}}{=}\left[\begin{array}{c}{0.52012820}\\ {-0.17628025}\\ {-0.97723949}\end{array}\right]{,}{\mathrm{aolabels}}{=}\left[\begin{array}{c}{"0 F 1s"}\\ {"0 F 2s"}\\ {"0 F 2px"}\\ {"0 F 2py"}\\ {"0 F 2pz"}\\ {"1 H 1s"}\end{array}\right]{,}{\mathrm{e_tot}}{=}{-98.60007479}{,}{\mathrm{rdm1}}{=}\left[\begin{array}{cccccc}{1.99999925}& {-0.00001685}& {4.95025598}{}{{10}}^{{-6}}& {0.}& {0.}& {0.00006529}\\ {-0.00001685}& {1.99698382}& {0.00838799}& {0.}& {0.}& {-0.00379698}\\ {4.95025598}{}{{10}}^{{-6}}& {0.00838799}& {1.97103031}& {0.}& {0.}& {-0.02111998}\\ {0.}& {0.}& {0.}& {1.99940397}& {0.}& {0.}\\ {0.}& {0.}& {0.}& {0.}& {1.99940397}& {0.}\\ {0.00006529}& {-0.00379698}& {-0.02111998}& {0.}& {0.}& {0.03317869}\end{array}\right]{,}{\mathrm{mo_occ}}{=}\left[\begin{array}{c}{1.99999971}\\ {1.99950563}\\ {1.99940397}\\ {1.99940397}\\ {1.96874518}\\ {0.03294154}\end{array}\right]{,}{\mathrm{e_corr}}{=}{-0.02757932}{,}{\mathrm{e_tot_ccsdt}}{=}{-98.60007479}{,}{\mathrm{mo_coeff}}{=}\left[\begin{array}{cccccc}{-1.00227899}& {0.23246897}& {0.}& {0.}& {0.00628867}& {0.08099457}\\ {0.00884878}& {-1.02622701}& {0.}& {0.}& {-0.13908643}& {-0.52734083}\\ {-0.00283785}& {0.05398513}& {-0.85059038}& {-0.24740034}& {0.31832859}& {-0.38384728}\\ {0.00096179}& {-0.01829647}& {-0.35393857}& {0.92195357}& {-0.10788695}& {0.13009234}\\ {0.00533187}& {-0.10142961}& {-0.38887465}& {-0.29798438}& {-0.59808960}& {0.72118898}\\ {0.00536943}& {0.00918453}& {0.}& {0.}& {0.56110954}& {1.06349216}\end{array}\right]{,}{\mathrm{e_tot_mp2}}{=}{-98.59082940}\right]\right)$ (4.2.8)

The core 1s orbital of fluorine can be frozen to an occupation of one with the frozen keyword

 >
 ${\mathrm{data_ccf}}{≔}{table}{}\left(\left[{\mathrm{populations}}{=}\left[\begin{array}{c}{1.99914076}\\ {1.95182047}\\ {1.83289245}\\ {1.98027767}\\ {1.41160949}\\ {0.82425915}\end{array}\right]{,}{\mathrm{converged}}{=}{1}{,}{\mathrm{charges}}{=}\left[\begin{array}{c}{-0.17574085}\\ {0.17574085}\end{array}\right]{,}{\mathrm{dipole}}{=}\left[\begin{array}{c}{0.52012820}\\ {-0.17628025}\\ {-0.97723949}\end{array}\right]{,}{\mathrm{aolabels}}{=}\left[\begin{array}{c}{"0 F 1s"}\\ {"0 F 2s"}\\ {"0 F 2px"}\\ {"0 F 2py"}\\ {"0 F 2pz"}\\ {"1 H 1s"}\end{array}\right]{,}{\mathrm{e_tot}}{=}{-98.60007479}{,}{\mathrm{rdm1}}{=}\left[\begin{array}{cccccc}{1.99999925}& {-0.00001685}& {4.95025598}{}{{10}}^{{-6}}& {0.}& {0.}& {0.00006529}\\ {-0.00001685}& {1.99698382}& {0.00838799}& {0.}& {0.}& {-0.00379698}\\ {4.95025598}{}{{10}}^{{-6}}& {0.00838799}& {1.97103031}& {0.}& {0.}& {-0.02111998}\\ {0.}& {0.}& {0.}& {1.99940397}& {0.}& {0.}\\ {0.}& {0.}& {0.}& {0.}& {1.99940397}& {0.}\\ {0.00006529}& {-0.00379698}& {-0.02111998}& {0.}& {0.}& {0.03317869}\end{array}\right]{,}{\mathrm{mo_occ}}{=}\left[\begin{array}{c}{1.99999971}\\ {1.99950563}\\ {1.99940397}\\ {1.99940397}\\ {1.96874518}\\ {0.03294154}\end{array}\right]{,}{\mathrm{e_corr}}{=}{-0.02757932}{,}{\mathrm{e_tot_ccsdt}}{=}{-98.60007479}{,}{\mathrm{mo_coeff}}{=}\left[\begin{array}{cccccc}{-1.00227899}& {0.23246897}& {0.}& {0.}& {0.00628867}& {0.08099457}\\ {0.00884878}& {-1.02622701}& {0.}& {0.}& {-0.13908643}& {-0.52734083}\\ {-0.00283785}& {0.05398513}& {-0.85059038}& {-0.24740034}& {0.31832859}& {-0.38384728}\\ {0.00096179}& {-0.01829647}& {-0.35393857}& {0.92195357}& {-0.10788695}& {0.13009234}\\ {0.00533187}& {-0.10142961}& {-0.38887465}& {-0.29798438}& {-0.59808960}& {0.72118898}\\ {0.00536943}& {0.00918453}& {0.}& {0.}& {0.56110954}& {1.06349216}\end{array}\right]{,}{\mathrm{e_tot_mp2}}{=}{-98.59082940}\right]\right)$ (4.2.9)

Similarly, we can perform a variational 2-RDM calculation with the Variational2RDM command.  The 1s orbital of fluorine can be frozen by specifying the active (non-frozen) orbitals with the active keyword

 > $\mathrm{data_2rdmf}≔\mathrm{Variational2RDM}\left(\mathrm{hf},\mathrm{active}=\left\{2,3,4,5,6\right\}\right);$
 ${\mathrm{data_2rdmf}}{≔}{table}{}\left(\left[{\mathrm{populations}}{=}\left[\begin{array}{c}{1.99912587}\\ {1.95091199}\\ {1.83369501}\\ {1.98035217}\\ {1.41449316}\\ {0.82142167}\end{array}\right]{,}{\mathrm{converged}}{=}{1}{,}{\mathrm{charges}}{=}\left[\begin{array}{c}{-0.17857819}\\ {0.17857833}\end{array}\right]{,}{\mathrm{dipole}}{=}\left[\begin{array}{c}{0.52844734}\\ {-0.17909975}\\ {-0.99286985}\end{array}\right]{,}{\mathrm{aolabels}}{=}\left[\begin{array}{c}{"0 F 1s"}\\ {"0 F 2s"}\\ {"0 F 2px"}\\ {"0 F 2py"}\\ {"0 F 2pz"}\\ {"1 H 1s"}\end{array}\right]{,}{\mathrm{e_tot}}{=}{-98.60038641}{,}{\mathrm{group}}{=}{"C1"}{,}{\mathrm{rdm1}}{=}\left[\begin{array}{ccccc}{1.99703225}& {0.00841689}& {0.}& {0.}& {-0.00277427}\\ {0.00841689}& {1.97125998}& {0.}& {0.}& {-0.01736494}\\ {0.}& {0.}& {1.99938398}& {0.}& {0.}\\ {0.}& {0.}& {0.}& {1.99938398}& {0.}\\ {-0.00277427}& {-0.01736494}& {0.}& {0.}& {0.03293968}\end{array}\right]{,}{\mathrm{active_orbitals}}{=}\left[{2}{..}{6}\right]{,}{\mathrm{mo_occ}}{=}\left[\begin{array}{c}{2.00000000}\\ {1.99956715}\\ {1.99938398}\\ {1.99938398}\\ {1.96888435}\\ {0.03278041}\end{array}\right]{,}{\mathrm{e_corr}}{=}{-0.02789094}{,}{\mathrm{mo_coeff}}{=}\left[\begin{array}{cccccc}{0.99472636}& {-0.26283449}& {0.}& {0.}& {-0.00551743}& {0.08131247}\\ {0.02241395}& {1.02565051}& {0.}& {0.}& {0.13682957}& {-0.52864911}\\ {0.00129454}& {-0.05487058}& {-0.01841073}& {0.88564777}& {-0.31891137}& {-0.38324583}\\ {-0.00043874}& {0.01859655}& {-0.98561636}& {0.06189728}& {0.10808446}& {0.12988850}\\ {-0.00243224}& {0.10309320}& {0.16799235}& {0.46021382}& {0.59918454}& {0.72005893}\\ {-0.00552213}& {-0.00864666}& {0.}& {0.}& {-0.55928135}& {1.06445845}\end{array}\right]{,}{\mathrm{mo_coeff_canonical}}{=}\left[\begin{array}{cccccc}{0.99472636}& {-0.25006317}& {-0.08004214}& {0.}& {0.}& {0.08237594}\\ {0.02241395}& {0.94240683}& {0.42089082}& {0.}& {0.}& {-0.53373351}\\ {0.00129454}& {0.03851262}& {-0.32465214}& {0.01817457}& {0.88565265}& {-0.38040816}\\ {-0.00043874}& {-0.01305258}& {0.11003011}& {0.98559982}& {0.06216010}& {0.12892677}\\ {-0.00243224}& {-0.07235919}& {0.60997056}& {-0.16811507}& {0.46016900}& {0.71472739}\\ {-0.00552213}& {0.15381697}& {-0.52865089}& {0.}& {0.}& {1.06902327}\end{array}\right]\right]\right)$ (4.2.10)

A full configuration interaction calculation can be performed with the FullCI command

 > $\mathrm{data_ci}≔\mathrm{FullCI}\left(\mathrm{hf}\right);$
 ${\mathrm{data_ci}}{≔}{table}{}\left(\left[{\mathrm{populations}}{=}\left[\begin{array}{c}{1.99914076}\\ {1.95182045}\\ {1.83289247}\\ {1.98027767}\\ {1.41160956}\\ {0.82425909}\end{array}\right]{,}{\mathrm{charges}}{=}\left[\begin{array}{c}{-0.17574091}\\ {0.17574091}\end{array}\right]{,}{\mathrm{dipole}}{=}\left[\begin{array}{c}{0.52012838}\\ {-0.17628032}\\ {-0.97723983}\end{array}\right]{,}{\mathrm{aolabels}}{=}\left[\begin{array}{c}{"0 F 1s"}\\ {"0 F 2s"}\\ {"0 F 2px"}\\ {"0 F 2py"}\\ {"0 F 2pz"}\\ {"1 H 1s"}\end{array}\right]{,}{\mathrm{e_tot}}{=}{-98.60007479}{,}{\mathrm{rdm1}}{=}\left[\begin{array}{cccccc}{1.99999925}& {-0.00001685}& {4.95032807}{}{{10}}^{{-6}}& {0.}& {0.}& {0.00006529}\\ {-0.00001685}& {1.99698383}& {0.00838798}& {0.}& {0.}& {-0.00379696}\\ {4.95032807}{}{{10}}^{{-6}}& {0.00838798}& {1.97103032}& {0.}& {0.}& {-0.02111990}\\ {0.}& {0.}& {0.}& {1.99940396}& {0.}& {0.}\\ {0.}& {0.}& {0.}& {0.}& {1.99940396}& {0.}\\ {0.00006529}& {-0.00379696}& {-0.02111990}& {0.}& {0.}& {0.03317868}\end{array}\right]{,}{\mathrm{mo_occ}}{=}\left[\begin{array}{c}{1.99999971}\\ {1.99950563}\\ {1.99940396}\\ {1.99940396}\\ {1.96874520}\\ {0.03294154}\end{array}\right]{,}{\mathrm{ci_coeff}}{=}\left[\begin{array}{cccccc}{0.99159670}& {0.}& {0.}& {-0.01200503}& {0.00159127}& {0.00003099}\\ {0.}& {-0.01726321}& {0.}& {0.}& {0.}& {0.}\\ {0.}& {0.}& {-0.01726321}& {0.}& {0.}& {0.}\\ {-0.01200503}& {0.}& {0.}& {-0.11594211}& {-0.02996891}& {-0.00009994}\\ {0.00159127}& {0.}& {0.}& {-0.02996891}& {-0.02464160}& {0.00045812}\\ {0.00003099}& {0.}& {0.}& {-0.00009994}& {0.00045812}& {-0.00039491}\end{array}\right]{,}{\mathrm{e_corr}}{=}{-0.02757932}{,}{\mathrm{mo_coeff}}{=}\left[\begin{array}{cccccc}{-1.00227898}& {-0.23246903}& {0.}& {0.}& {0.00628869}& {0.08099458}\\ {0.00884871}& {1.02622699}& {0.}& {0.}& {-0.13908651}& {-0.52734086}\\ {-0.00283784}& {-0.05398511}& {-0.08755575}& {0.88150151}& {0.31832861}& {-0.38384727}\\ {0.00096179}& {0.01829647}& {-0.98743945}& {-0.01530444}& {-0.10788696}& {0.13009234}\\ {0.00533186}& {0.10142957}& {0.13151931}& {0.47193310}& {-0.59808964}& {0.72118895}\\ {0.00536943}& {-0.00918445}& {0.}& {0.}& {0.56110950}& {1.06349218}\end{array}\right]\right]\right)$ (4.2.11)

We can freeze orbitals in the configuration interaction by using the command ActiveSpaceCI with the active keyword

 > $\mathrm{data_cif}≔\mathrm{ActiveSpaceCI}\left(\mathrm{hf},\mathrm{active}=\left\{2,3,4,5,6\right\}\right);$
 ${\mathrm{data_cif}}{≔}{table}{}\left(\left[{\mathrm{populations}}{=}\left[\begin{array}{c}{1.99913163}\\ {1.95182665}\\ {1.83290091}\\ {1.98027662}\\ {1.41164516}\\ {0.82421904}\end{array}\right]{,}{\mathrm{charges}}{=}\left[\begin{array}{c}{-0.17578096}\\ {0.17578096}\end{array}\right]{,}{\mathrm{dipole}}{=}\left[\begin{array}{c}{0.52021054}\\ {-0.17630816}\\ {-0.97739420}\end{array}\right]{,}{\mathrm{aolabels}}{=}\left[\begin{array}{c}{"0 F 1s"}\\ {"0 F 2s"}\\ {"0 F 2px"}\\ {"0 F 2py"}\\ {"0 F 2pz"}\\ {"1 H 1s"}\end{array}\right]{,}{\mathrm{e_tot}}{=}{-98.60005428}{,}{\mathrm{rdm1}}{=}\left[\begin{array}{ccccc}{1.99950586}& {0.}& {0.}& {0.}& {0.}\\ {0.}& {1.99940167}& {0.}& {0.}& {0.}\\ {0.}& {0.}& {1.99940167}& {0.}& {0.}\\ {0.}& {0.}& {0.}& {1.96873815}& {0.}\\ {0.}& {0.}& {0.}& {0.}& {0.03295264}\end{array}\right]{,}{\mathrm{active_orbitals}}{=}\left[{2}{..}{6}\right]{,}{\mathrm{mo_occ}}{=}\left[\begin{array}{c}{2.00000000}\\ {1.99950586}\\ {1.99940167}\\ {1.99940167}\\ {1.96873815}\\ {0.03295264}\end{array}\right]{,}{\mathrm{ci_coeff}}{=}\left[\begin{array}{ccccc}{0.99172762}& {0.}& {0.}& {0.}& {0.}\\ {0.}& {-0.12502370}& {0.}& {0.}& {0.}\\ {0.}& {0.}& {-0.01729632}& {0.}& {0.}\\ {0.}& {0.}& {0.}& {-0.01729632}& {0.}\\ {0.}& {0.}& {0.}& {0.}& {-0.01571841}\end{array}\right]{,}{\mathrm{e_corr}}{=}{-0.02755881}{,}{\mathrm{spin_squared}}{=}{0}{,}{\mathrm{mo_coeff}}{=}\left[\begin{array}{cccccc}{0.99472636}& {0.25006317}& {-0.07872131}& {0.01448099}& {0.}& {0.08237594}\\ {0.02241395}& {-0.94240683}& {0.41394543}& {-0.07614636}& {0.}& {-0.53373351}\\ {0.00129454}& {-0.03851262}& {-0.31600675}& {0.07660979}& {-0.88565265}& {-0.38040816}\\ {-0.00043874}& {0.01305258}& {0.28652632}& {0.94942946}& {-0.06216010}& {0.12892677}\\ {-0.00243224}& {0.07235919}& {0.56949015}& {-0.27569501}& {-0.46016900}& {0.71472739}\\ {-0.00552213}& {-0.15381697}& {-0.51992728}& {0.09564200}& {0.}& {1.06902327}\end{array}\right]\right]\right)$ (4.2.12)

Note that the energy from configuration interaction (CI) and the variational 2-RDM method are extremely close

 > ${\mathrm{data_2rdmf}}_{\mathrm{e_tot}}-{\mathrm{data_cif}}_{\mathrm{e_tot}}$
 ${-0.00033213}$ (4.2.13)

Finally, we can also perform active-space calculations, that is calculations with a set of orbitals designated as active (not frozen to an occupation of 1 or 0), where we optimize the active orbitals through orbital rotations.  These types of calculations can be performed with complete-active-space self-consistent-field (CASSCF) with the ActiveSpaceSCF command or with the variational 2-RDM method with the Variational2RDM command.  For example, orbitals 3 and 6 can be selected as active.  For example, with the variational 2-RDM method we have

 > $\mathrm{data_scf}≔\mathrm{Variational2RDM}\left(\mathrm{hf},\mathrm{basis}="6-31g",\mathrm{active}=\left\{3,6\right\},\mathrm{casscf}=\mathrm{true}\right);$

Visualization

Molecular geometries, densities, and vibrations can be visualized through 3D interactive plots and animations.  See the What'sNew2020 help page for new plots for excited-state spectra.

Molecular geometries

To illustrate the PlotMolecule command, we examine three molecules: (1) hydrogen fluoride, (2) 1,3-diboromobenzene, and (3) tylenol

hydrogen fluoride

As shown previously, the geometry can be retrieved from the web database

 > $\mathrm{hf}≔\mathrm{MolecularGeometry}\left("hydrogenfluoride"\right);$
 ${\mathrm{hf}}{≔}\left[\left[{"F"}{,}{0}{,}{0}{,}{0}\right]{,}\left[{"H"}{,}{0.43580000}{,}{-0.14770000}{,}{-0.81880000}\right]\right]$ (5.1.1.1)

The resulting geometry as a Maple can then be passed to PlotMolecule

 > $\mathrm{PlotMolecule}\left(\mathrm{hf}\right);$

The keyword option model allows us to choose a "ballandstick" (default) or "spacefilling" model

 > $\mathrm{PlotMolecule}\left(\mathrm{hf},\mathrm{model}="spacefilling"\right);$
 >

1,3-dibromobenzene

The geometry can be retrieved from the web database

 > $\mathrm{bromobenzene}≔\mathrm{MolecularGeometry}\left("1,3-dibromobenzene"\right);$
 ${\mathrm{bromobenzene}}{≔}\left[\left[{"Br"}{,}{-2.84530000}{,}{-1.23120000}{,}{0}\right]{,}\left[{"Br"}{,}{2.84540000}{,}{-1.23100000}{,}{0}\right]{,}\left[{"C"}{,}{0.00010000}{,}{-0.98450000}{,}{0.00010000}\right]{,}\left[{"C"}{,}{-1.20800000}{,}{-0.28710000}{,}{0}\right]{,}\left[{"C"}{,}{1.20800000}{,}{-0.28700000}{,}{-0.00010000}\right]{,}\left[{"C"}{,}{-1.20810000}{,}{1.10770000}{,}{-0.00010000}\right]{,}\left[{"C"}{,}{1.20790000}{,}{1.10780000}{,}{0.00010000}\right]{,}\left[{"C"}{,}{-0.00020000}{,}{1.80520000}{,}{0}\right]{,}\left[{"H"}{,}{0.00020000}{,}{-2.07230000}{,}{0.00010000}\right]{,}\left[{"H"}{,}{-2.14060000}{,}{1.66640000}{,}{-0.00010000}\right]{,}\left[{"H"}{,}{2.14030000}{,}{1.66660000}{,}{0.00010000}\right]{,}\left[{"H"}{,}{-0.00020000}{,}{2.89130000}{,}{0}\right]\right]$ (5.1.2.1)

We can also retrieve the skeletal structure with the command SkeletalStructure

 > $\mathrm{SkeletalStructure}\left("1,3-dibromobenzene"\right);$

The resulting geometry as a Maple can then be passed to PlotMolecule

 > $\mathrm{PlotMolecule}\left(\mathrm{bromobenzene}\right);$
 >

tylenol

The geometry can be retrieved from the web database

 > $\mathrm{tylenol}≔\mathrm{MolecularGeometry}\left("tylenol"\right);$
 ${\mathrm{tylenol}}{≔}\left[\left[{"O"}{,}{3.85090000}{,}{0.45160000}{,}{0.00120000}\right]{,}\left[{"O"}{,}{-2.59990000}{,}{1.40410000}{,}{-0.00180000}\right]{,}\left[{"N"}{,}{-1.57050000}{,}{-0.71710000}{,}{0.00010000}\right]{,}\left[{"C"}{,}{-0.20660000}{,}{-0.42310000}{,}{-0.00020000}\right]{,}\left[{"C"}{,}{0.22050000}{,}{0.90470000}{,}{0.00040000}\right]{,}\left[{"C"}{,}{0.72980000}{,}{-1.45700000}{,}{-0.00070000}\right]{,}\left[{"C"}{,}{1.58410000}{,}{1.19860000}{,}{0.00020000}\right]{,}\left[{"C"}{,}{2.09330000}{,}{-1.16290000}{,}{-0.00070000}\right]{,}\left[{"C"}{,}{2.52040000}{,}{0.16480000}{,}{-0.00030000}\right]{,}\left[{"C"}{,}{-2.64850000}{,}{0.17820000}{,}{0.00090000}\right]{,}\left[{"C"}{,}{-3.97350000}{,}{-0.54200000}{,}{0.00100000}\right]{,}\left[{"H"}{,}{-0.44360000}{,}{1.75770000}{,}{0.00120000}\right]{,}\left[{"H"}{,}{0.41130000}{,}{-2.49630000}{,}{-0.00100000}\right]{,}\left[{"H"}{,}{-1.80100000}{,}{-1.70860000}{,}{0.00010000}\right]{,}\left[{"H"}{,}{1.90530000}{,}{2.23700000}{,}{0.00090000}\right]{,}\left[{"H"}{,}{2.81800000}{,}{-1.97260000}{,}{-0.00080000}\right]{,}\left[{"H"}{,}{-4.06550000}{,}{-1.14630000}{,}{-0.90580000}\right]{,}\left[{"H"}{,}{-4.79040000}{,}{0.18440000}{,}{0.02880000}\right]{,}\left[{"H"}{,}{-4.04450000}{,}{-1.18860000}{,}{0.88020000}\right]{,}\left[{"H"}{,}{3.96500000}{,}{1.41760000}{,}{0.00170000}\right]\right]$ (5.1.3.1)

We can also retrieve the skeletal structure with the command SkeletalStructure

 > $\mathrm{SkeletalStructure}\left("tylenol"\right);$

Or its dictionary entry with the command MolecularDictionary

 > $\mathrm{MolecularDictionary}\left("tylenol"\right);$
 Acetaminophen: Paracetamol is a member of the class of phenols that is 4-aminophenol in which one of the hydrogens attached to the amino group has been replaced by an acetyl group. It has a role as a cyclooxygenase 2 inhibitor, a cyclooxygenase 1 inhibitor, a non-narcotic analgesic, an antipyretic, a non-steroidal anti-inflammatory drug, a cyclooxygenase 3 inhibitor, a xenobiotic, an environmental contaminant, a human blood serum metabolite and a hepatotoxic agent. It is a member of phenols and a member of acetamides. It derives from a 4-aminophenol. -ChEBI     Acetaminophen: Acetaminophen is a p-aminophenol derivative with analgesic and antipyretic activities. Although the exact mechanism through which acetaminophen exert its effects has yet to be fully determined, acetaminophen may inhibit the nitric oxide (NO) pathway mediated by a variety of neurotransmitter receptors including N-methyl-D-aspartate (NMDA) and substance P, resulting in elevation of the pain threshold. The antipyretic activity may result from inhibition of prostaglandin synthesis and release in the central nervous system (CNS) and prostaglandin-mediated effects on the heat-regulating center in the anterior hypothalamus. -NCI Thesaurus (NCIt)

The resulting geometry as a Maple list of lists can then be passed to PlotMolecule

 > $\mathrm{PlotMolecule}\left(\mathrm{tylenol}\right);$
 >

Molecular densities

To illustrate the DensityPlot3D command, we examine two molecules: (1) hydrogen fluoride and (2) tylenol

hydrogen fluoride

We can compute the orbitals of hydrogen fluoride from the HartreeFock command

 > $\mathrm{data}≔\mathrm{HartreeFock}\left(\mathrm{hf}\right);$
 ${\mathrm{data}}{≔}{table}{}\left(\left[{\mathrm{populations}}{=}\left[\begin{array}{c}{1.99909064}\\ {1.94654042}\\ {1.83945507}\\ {1.98155906}\\ {1.43326789}\\ {0.80008693}\end{array}\right]{,}{\mathrm{converged}}{=}{1}{,}{\mathrm{charges}}{=}\left[\begin{array}{c}{-0.19991307}\\ {0.19991307}\end{array}\right]{,}{\mathrm{dipole}}{=}\left[\begin{array}{c}{0.58797708}\\ {-0.19927539}\\ {-1.10471692}\end{array}\right]{,}{\mathrm{aolabels}}{=}\left[\begin{array}{c}{"0 F 1s"}\\ {"0 F 2s"}\\ {"0 F 2px"}\\ {"0 F 2py"}\\ {"0 F 2pz"}\\ {"1 H 1s"}\end{array}\right]{,}{\mathrm{e_tot}}{=}{-98.57249547}{,}{\mathrm{group}}{=}{"C1"}{,}{\mathrm{rdm1}}{=}\left[\begin{array}{cccccc}{2.11683774}& {-0.49410898}& {0.03528596}& {-0.01195901}& {-0.06629679}& {-0.00328525}\\ {-0.49410898}& {2.13156421}& {-0.20063906}& {0.06799998}& {0.37696940}& {-0.15533983}\\ {0.03528596}& {-0.20063906}& {1.78318968}& {0.07348069}& {0.40735267}& {0.35508878}\\ {-0.01195901}& {0.06799998}& {0.07348069}& {1.97509615}& {-0.13805872}& {-0.12034560}\\ {-0.06629679}& {0.37696940}& {0.40735267}& {-0.13805872}& {1.23464808}& {-0.66715625}\\ {-0.00328525}& {-0.15533983}& {0.35508878}& {-0.12034560}& {-0.66715625}& {0.60632385}\end{array}\right]{,}{\mathrm{mo_energy}}{=}\left[\begin{array}{c}{-25.90202575}\\ {-1.46443647}\\ {-0.57855098}\\ {-0.46350983}\\ {-0.46350983}\\ {0.60611202}\end{array}\right]{,}{\mathrm{mo_occ}}{=}\left[\begin{array}{c}{2.00000000}\\ {2.00000000}\\ {2.00000000}\\ {2.00000000}\\ {2.00000000}\\ {0.}\end{array}\right]{,}{\mathrm{mo_coeff}}{=}\left[\begin{array}{cccccc}{0.99472636}& {-0.25006317}& {-0.08004214}& {0.}& {0.}& {0.08237594}\\ {0.02241395}& {0.94240683}& {0.42089082}& {0.}& {0.}& {-0.53373351}\\ {0.00129454}& {0.03851262}& {-0.32465214}& {0.49991940}& {0.73129442}& {-0.38040816}\\ {-0.00043874}& {-0.01305258}& {0.11003011}& {0.85891086}& {-0.48738385}& {0.12892677}\\ {-0.00243224}& {-0.07235919}& {0.60997056}& {0.11114282}& {0.47714302}& {0.71472739}\\ {-0.00552213}& {0.15381697}& {-0.52865089}& {0.}& {0.}& {1.06902327}\end{array}\right]{,}{\mathrm{mo_symmetry}}{=}\left[\begin{array}{c}{"A"}\\ {"A"}\\ {"A"}\\ {"A"}\\ {"A"}\\ {"A"}\end{array}\right]\right]\right)$ (5.2.1.1)

The electron density of the molecule can be displayed with the DensityPlot3D command

 > $\mathrm{DensityPlot3D}\left(\mathrm{hf},\mathrm{data}\right);$

The density of a given orbital can be selected with the keyword orbitalindex

 > $\mathrm{DensityPlot3D}\left(\mathrm{hf},\mathrm{data},\mathrm{orbitalindex}=6\right);$
 >

tylenol

We can compute the orbitals of tylenol from the HartreeFock command

 > $\mathrm{data}≔\mathrm{HartreeFock}\left(\mathrm{tylenol}\right);$

The electron density of the molecule can be displayed with the DensityPlot3D command

 > $\mathrm{DensityPlot3D}\left(\mathrm{tylenol},\mathrm{data}\right);$

The density of a given orbital can be selected with the keyword orbitalindex

 > $\mathrm{DensityPlot3D}\left(\mathrm{tylenol},\mathrm{data},\mathrm{orbitalindex}=36\right);$
 >

Vibrational modes

To illustrate the VibrationalModeAnimation command, we examine the water molecule

 > $\mathrm{water}≔\mathrm{MolecularGeometry}\left("water"\right);$
 ${\mathrm{water}}{≔}\left[\left[{"O"}{,}{0}{,}{0}{,}{0}\right]{,}\left[{"H"}{,}{0.27740000}{,}{0.89290000}{,}{0.25440000}\right]{,}\left[{"H"}{,}{0.60680000}{,}{-0.23830000}{,}{-0.71690000}\right]\right]$ (5.3.1)

After obtaining an initial geometry from the web database, we perform a geometry optimization with the Hartree-Fock method

 >
 $\left[\left[{"O"}{,}{-0.01931358}{,}{-0.01429454}{,}{0.01010464}\right]{,}\left[{"H"}{,}{0.28821797}{,}{0.89605410}{,}{0.24592050}\right]{,}\left[{"H"}{,}{0.61529561}{,}{-0.22715956}{,}{-0.71852514}\right]\right]$ (5.3.2)

The vibrational modes are then computed

 >

We can finally animate the lowest vibrational mode of water (at this level of theory and in this basis set) with the VibrationalModeAnimation command

 > $\mathrm{VibrationalModeAnimation}\left(\mathrm{water},\mathrm{emodes},\mathrm{vmodes},1\right);$
 >

Interactive Maplet

An interactive Maplet can be launched with the Interactive command for a graphical user interface to the package

 > $\mathrm{Interactive}\left(\right);\phantom{\rule[-0.0ex]{0.0em}{0.0ex}}$

A video tutorial for the Interactive command is available from the Video command

 > $\mathrm{Video}\left("Interactive.mp4"\right);$
 >
 Courses Lessons and curricula in chemistry and physics are directly integrated into the QuantumChemistry package.  Curricula are available for chemistry courses in general chemistry, physical chemistry (quantum mechanics), physical chemistry (statistical thermodynamics), computational chemistry, and graduate-level quantum chemistry as well as physics courses in quantum mechanics and statistical thermodynamics.   The lessons and curricula, which are accessible through the help pages of the package, employ advanced features of the package to facilitate the learning and understanding of both introductory and advanced concepts in the study of atoms and molecules.  They can be used for formal courses as well as self study.

Help

Maple help pages for the QuantumChemistry package provide detailed information on each command .  To access the main QuantumChemistry help page, you can issue the command

 > $\mathrm{help}\left("QuantumChemistry/Overview"\right);$

Other commands are also accessible in this fashion.  For example, to obtain the HartreeFock help page, you can issue the command

 > $\mathrm{help}\left("HartreeFock"\right);$
 >