# How do I run MP2 and/or CCSD-level hyperpolarizability calculations with GAMESS?

I have used GAMESS before for TDHF (RPA) / TDDFT level first hyperpolarizability ($\beta$) calculations. However, I cannot figure out how to calculate $\beta$ with MP2 and CCSD for comparative purposes. Do I have to use the FFIELD keyword for the finite field approach? If that is the case, what is the general workflow necessary to calculate the time-varying hyperpolarizability?

• Welcome to ChemSE. Please feel free to take a tour of this site to get a brief idea of who we are, and what topics are suitable here. Good luck, and hope to see you satisfied soon. Jul 24, 2017 at 13:54

As you guessed, to calculate $\beta$ within GAMESS for MP2 and CCSD, you would need to perform first- and second-order finite difference, respectively, as there is no coupled cluster gradient needed, so no true CCSD dipole moment.

However, there is a more fundamental problem: it is impossible to calculate time-dependent response using a finite field approach. Take the general form of 1-dimensional 2nd-order central difference, $$f''(x) \approx \lim_{h \to 0} \frac{f(x+h)-2f(x)+f(x-h)}{h^2},$$

which can directly translate to a diagonal element of the polarizability tensor formed from energies at finite electric fields:

$$\alpha_{zz}(x) \approx \lim_{h \to 0} \frac{E(x+h)-2E(x)+E(x-h)}{h^2}$$

where $h$ is a finite electric dipole field of some strength applied along the $z$-direction. What is $x$? Is it as simple as converting the desired frequency $\omega$ to units of electric field strength? No; that still corresponds to a static field rather than a time-varying field. How are the different perturbation directions handled? $x$ must be set to 0.

From a molecular properties review by Jurgen Gauss, page 5:

(...) disadvantages of the numerical differentiation scheme are

a) that there is no straightforward extension to the computation of frequency-dependent properties (...)

Page 37:

While analytic derivative theory is sufficient for the theoretical treatment of time-independent (static) properties, the underlying theory needs to be extended for the calculation of time-dependent (dynamical) properties. In particular, the fact that there is -- unlike for the static case -- in the time-dependent case no well-defined energy explains why the simple derivative theory discussed so far is not applicable.

Page 39 (with some manipulation by me):

It can be shown that the linear, quadratic, etc. response functions $\left<\left<A;B\right>\right>_{w_{b}}$, $\left<\left<A;B,C\right>\right>_{w_{b},w_{c}}$, etc. and thus the frequency-dependent properties of interest can be determined as derivatives of the so-called time-averaged quasi energy

$$Q(t) = \left<\tilde{\psi}\left|\left(H - i\frac{\partial}{\partial t}\right)\right|\tilde{\psi}\right>$$

with the phase-isolated wavefunction

$$\tilde{\psi}(t) = e^{iF(t)} \psi(t)$$

where $F$ is a time-varying external field, and $\psi(t)$ is the usual wavefunction where MO coefficients and thus the density are explicitly time-dependent.

The only numerical (rather than analytic) method for calculating dynamic properties I am aware of is direct time-propagation of the wavefunction. If you want to calculate frequency-dependent CCSD hyperpolarizabilities, your best (free) bet is DALTON. Note that their coupled cluster module is closed-shell only.

• Thank you for your response; it was very informative and I am grateful for the resource you have provided. I believe analytic gradients for CCSD and MP2 for the first hyperpolarizability have previously been published, is it just the case that they have not been implemented into GAMESS? Or am I mistaken about their derivation? Jul 26, 2017 at 13:35
• The point is that they are not implemented in GAMESS. Analytic gradients for MP2 and CCSD are in most packages. Very few programs (DALTON, Gaussian) can calculate correlated hyperpolarizabilities. Jul 26, 2017 at 13:57
• @ComputationalNovice If my answer was useful, please consider accepting it. Jul 28, 2017 at 19:47
• NWChem has had CCSD quadratic response hyperpolarizabilities with non-zero frequencies since 2008. You can do RHF, UHF or ROHF, but I strongly recommend ROHF for open shells, for reasons discussed in the paper linked last. nwchemgit.github.io/TCE.html#input pubs.aip.org/aip/jcp/article-abstract/130/19/194108/296267/… pubs.aip.org/aip/jcp/article-abstract/128/22/224102/924805/… Jan 10 at 11:59
• github.com/nwchemgit/nwchem/tree/… is an example input file, since it seems the user manual is not complete (my fault) Jan 10 at 13:55