ACFDT/RPA calculations: Difference between revisions

From VASP Wiki
No edit summary
No edit summary
Line 9: Line 9:
E_{c} = <math>\frac{1}{2 \pi} \int_{0}^{\infty}  \mathrm{Tr} \, \ln(1-\chi( i \omega) v) + \chi( i \omega) v \, d \omega</math>.
E_{c} = <math>\frac{1}{2 \pi} \int_{0}^{\infty}  \mathrm{Tr} \, \ln(1-\chi( i \omega) v) + \chi( i \omega) v \, d \omega</math>.


In practice,  RPA energy calculations need to proceed in four steps (VASP can not yet
In practice,  RPA energy calculations need to proceed in four steps (VASP can not yet perform all required steps in a single VASP run).
perform all required steps in a single VASP run).


{\bf First step} (a standard DFT run): All {\em occupied} orbitals (and as
First step (a standard DFT run): All occupied orbitals (and as usual in VASP, a few unoccupied orbitals) of the DFT-Hamiltonian are calculated:
usual in VASP, a few unoccupied orbitals) of the DFT-Hamiltonian are calculated:
\begin{verbatim}
  EDIFF = 1E-8
  EDIFF = 1E-8
  ISMEAR = 0 ; SIGMA = 0.05
  ISMEAR = 0 ; SIGMA = 0.05
\end{verbatim}
This can be done with your favorite setup, but we recommend to attain very high precision (small {{TAG|EDIFF}} flag) and to use a small smearing width  ({{TAG|SIGMA}} flag), and to avoid higher order Methfessel-Paxton smearing (see also {{TAG|ISMEAR}}). We suggest to use PBE orbitals as input for the ACFDT-RPA run, but other choices are possible as well, e.g. LDA or hybrid functionals such as HSE. For hybrid functionals, we suggest however to carefully consider the caveats mentioned in reference <ref name="paier"/>, specifically the RPA dielectric matrix yields significantly too weak screening for hybrid functionals, which is expected to deteriorate the RPA results.
This can be done with your favorite setup, but we recommend to attain very
high precision ({\tt EDIFF} flag) and to use a small smearing width  ({\tt SIGMA} flag),
and to avoid higher order Methfessel-Paxton smearing (see Sec. \ref{incar-smear}).
We suggest to use PBE orbitals as input for the ACFDT-RPA run,
but other choices are possible as well, e.g. LDA or hybrid functionals
such as HSE. For hybrid functionals, we suggest however
to carefully consider the caveats mentioned in Ref. \cite{paier08},
specifically the RPA dielectric matrix yields significantly too weak screening
for hybrid functionals, which is expected to deteriorate the RPA results.


{\bf Second step}: the Hartree Fock energy E$_{\rm EXX}$ is  calculated
 
using the predetermined DFT orbitals:
Second step: the Hartree Fock energy <math>E_{\mathrm{EXX}} is  calculated using the predetermined DFT orbitals:
\begin{verbatim}
  ALGO  = EIGENVAL ; NELM = 1
  ALGO  = EIGENVAL ; NELM = 1
  LWAVE=.FALSE.                  ! avoid accidental update of WAVECAR
  LWAVE=.FALSE.                  ! avoid accidental update of WAVECAR
  LHFCALC = .TRUE. ; AEXX = 1.0  ! you my set ALDAC = 0.0 but the default is 1-AEXX
  LHFCALC = .TRUE. ; AEXX = 1.0  ! you my set ALDAC = 0.0 but the default is 1-AEXX
  ISMEAR = 0 ; SIGMA = 0.05
  ISMEAR = 0 ; SIGMA = 0.05
\end{verbatim}
For insulators and semiconductors with a sizable gap, faster convergence of the Hartree-Fock energy can be obtained by setting {{TAG|HFRCUT}}=-1, altough this slows down k-point convergence for metals.
For insulators and semiconductors with a sizable gap, faster convergence of the Hartree-Fock energy can be obtained
by setting {\tt HFRCUT}=-1, altough {\tt HFRCUT}=-1 slows k-point convergence for metals.


{\bf Third step}: Search for ``{\tt maximum number of plane-waves:}`` in the OUTCAR file of the first step,
and run VASP again  with the following INCAR file to determine all virtual states by an exact
diagonalization of the Hamiltonian (DFT or hybrid, make certain to use the same
Hamiltonian as in step 1):


\begin{verbatim}
Third step: Search for ''maximum number of plane-waves:'' in the {{TAG|OUTCAR} file of the first step, and run VASP again with the following {{TAG|INCAR}} file to determine all virtual states by an exact diagonalization of the Hamiltonian (DFT or hybrid, make certain to use the same  Hamiltonian as in step 1):
  NBANDS = maximum number of plane-waves (possibly times 2, for gamma-only!)
  NBANDS = maximum number of plane-waves (possibly times 2, for gamma-only!)
  ALGO = Exact    ! exact diagonalization
  ALGO = Exact    ! exact diagonalization
Line 50: Line 31:
  LOPTICS = .TRUE.
  LOPTICS = .TRUE.
  ISMEAR = 0 ; SIGMA = 0.05
  ISMEAR = 0 ; SIGMA = 0.05
\end{verbatim}
N.B.: For calculations using the gamma-point only version of vasp, {{TAG|NBANDS}} must be set to twice the ''maximum number of plane-waves:'' (found in the {{TAG|OUTCAR}} file) in step 1. For metals, we recommend to avoid setting {{TAG|LOPTICS}}=''.TRUE.'', since this slows down k-point convergence<ref name="harl"/>.
N.B.: For calculations using the gamma-point only version of vasp,
{\tt NBANDS} must be set to $2\times$ ``{\tt maximum number of plane-waves:}``
(found in the OUTCAR file) in step 1. For metals, we recommend
to avoid setting {\tt LOPTICS = .TRUE.}, since this
slows k-point convergence.\cite{harl10}




{\bf Fourth step}: Calculate the ACFDT-RPA correlation energy:
Fourth step: Calculate the ACFDT-RPA correlation energy:
\begin{verbatim}
  NBANDS =  maximum number of plane-waves
  NBANDS =  maximum number of plane-waves
  ALGO = ACFDT
  ALGO = ACFDT
  NOMEGA = 8-24  
  NOMEGA = 8-24  
\end{verbatim}
To reach technical convergence, a number of flags are available to control the evaluation of the ACFDT-RPA correlation energy in the fourth step. The expression for the ACFDT-RPA correlation energy reads:


To reach technical convergence, a number of flags are available to control
<math>\mathrm{E}_{\mathrm{c}}=\int_{0}^{\infty} \frac{\mathrm{d}\omega}{2\pi} \sum_{{\mathbf{q}}\in{BZ}}\sum_{{\mathbf{G}}} \left\{(\mathrm{ln}[1-\chi^{KS}({\mathbf{q}},\mathrm{i}\omega)\nu({\mathbf{q}})])_{{\mathbf{G,G}}}  +\nu_{{\mathbf{G,G}}}({\mathbf{q}})\chi^{KS}({\mathbf{q}},{\mathrm{i}}\omega) \right\} </math>.
the evaluation of the ACFDT-RPA correlation energy in the fourth step.
 
The expression for the ACFDT-RPA correlation energy reads:
The sum over reciprocal lattice vectors has to be truncated at some <math>\mathbf{G}_{\mathrm{max}}</math>, determined by <math>\frac{\hbar^2|{\mathbf{G}}+{\mathbf{q}}|^2}{2\mathrm{m}_e}</math> < {{TAG|ENCUTGW}}, which can be set in the {{TAG|INCAR}} file. The default value is <math>\frac{2}{3}\times</math> {{TAG|ENCUT}}, which experience has taught us not to change. For systematic convergence tests, instead increase {{TAG|ENCUT}} and repeat steps 1 to 4, but be aware that the "maximum number of plane-waves" changes when {{TAG|ENCUT}} is increased. Note that it is virtually impossible, to converge absolute correlation energies. Rather concentrate on relative energies (e.g. energy differences between two solids, or between a solid and the constituent atoms).
\begin{equation}
\mathrm{E}_{\rm c}=\int _0 ^\infty \frac{\mathrm{d}\omega}{2\pi}
\sum_{{\mathbf{q}}\in BZ}\sum_{{\mathbf{G}}}
\left\{(\mathrm{ln}[1-\chi^{KS}({\mathbf{q}},\mathrm{i}\omega)\nu({\mathbf{q}})])_{{\mathbf
{G,G}}}  +\nu_{{\mathbf{G,G}}}({\mathbf{q}})\chi^{KS}({\mathbf{q}},{\mathrm{i}}\omega) \right\}
\end{equation}
The sum over reciprocal lattice vectors has to be truncated at some ${\mathbf{G}}_{\rm max}$,
determined by $\frac{\hbar^2|{\mathbf{G}}+{\mathbf{q}}|^2}{2\mathrm{m}_e}< $ {\tt ENCUTGW},
which can be set in the INCAR file. The default value is $\frac23\times${\tt ENCUT},
which experience has taught us not to change. For systematic convergence tests, instead increase
{\tt ENCUT} and repeat steps 1-4, but be aware that the "maximum number of plane-waves"
changes when {\tt ENCUT} is increased. Note that it is virtually impossible, to converge absolute correlation energies
rather concentrate on relative energies (e.g. energy differences between two solids, or between
a solid and the constituent atoms).


Since correlation energies  converge very slowly with respect to ${\mathbf{G}}_{\rm max}$,
Since correlation energies  converge very slowly with respect to ${\mathbf{G}}_{\rm max}$,
Line 136: Line 97:
by {\tt ALGO = ACFDTR}. The new version is presently not part of
by {\tt ALGO = ACFDTR}. The new version is presently not part of
the VASP distribution.
the VASP distribution.
== References ==
<references>
<ref name="paier">[http://journals.aps.org/prb/abstract/10.1103/PhysRevB.78.121201 J. Paier, M. Marsman, G. Kresse, Phys. Rev. B 78, 121201(R)-1-4 (2008).]</ref>
<ref name="harl">[http://journals.aps.org/prb/abstract/10.1103/PhysRevB.81.115126 J. Harl, L. Schimka, and G. Kresse, Phys. Rev. B 81, 115126 (2010). ]</ref>
</references>

Revision as of 16:56, 17 January 2017

The ACFDT-RPA groundstate energy () is the sum of the ACFDT-RPA correlation energy and the Hartree-Fock energy evaluated non self-consistently using DFT orbitals :

.

Note that, here includes also the Hartree energy, the kinetic energy, as well as the Ewald energy of the ions, whereas often in literature refers only to the exact exchange energy evaluated using DFT orbitals.

If ALGO=ACFDT is set in the INCAR file, VASP calculates the correlation energy in the random phase approximation. To this end, VASP calculates first the independent particle response function, using the virtual (unoccupied) states found in the WAVECAR file, and then determines the correlation energy using the plasmon fluctuation equation:

E_{c} = .

In practice, RPA energy calculations need to proceed in four steps (VASP can not yet perform all required steps in a single VASP run).

First step (a standard DFT run): All occupied orbitals (and as usual in VASP, a few unoccupied orbitals) of the DFT-Hamiltonian are calculated:

EDIFF = 1E-8
ISMEAR = 0 ; SIGMA = 0.05

This can be done with your favorite setup, but we recommend to attain very high precision (small EDIFF flag) and to use a small smearing width (SIGMA flag), and to avoid higher order Methfessel-Paxton smearing (see also ISMEAR). We suggest to use PBE orbitals as input for the ACFDT-RPA run, but other choices are possible as well, e.g. LDA or hybrid functionals such as HSE. For hybrid functionals, we suggest however to carefully consider the caveats mentioned in reference [1], specifically the RPA dielectric matrix yields significantly too weak screening for hybrid functionals, which is expected to deteriorate the RPA results.


Second step: the Hartree Fock energy Failed to parse (syntax error): {\displaystyle E_{\mathrm{EXX}} is calculated using the predetermined DFT orbitals: ALGO = EIGENVAL ; NELM = 1 LWAVE=.FALSE. ! avoid accidental update of WAVECAR LHFCALC = .TRUE. ; AEXX = 1.0 ! you my set ALDAC = 0.0 but the default is 1-AEXX ISMEAR = 0 ; SIGMA = 0.05 For insulators and semiconductors with a sizable gap, faster convergence of the Hartree-Fock energy can be obtained by setting {{TAG|HFRCUT}}=-1, altough this slows down k-point convergence for metals. Third step: Search for ''maximum number of plane-waves:'' in the {{TAG|OUTCAR} file of the first step, and run VASP again with the following {{TAG|INCAR}} file to determine all virtual states by an exact diagonalization of the Hamiltonian (DFT or hybrid, make certain to use the same Hamiltonian as in step 1): NBANDS = maximum number of plane-waves (possibly times 2, for gamma-only!) ALGO = Exact ! exact diagonalization NELM = 1 ! one step suffices since WAVECAR is pre-converged LOPTICS = .TRUE. ISMEAR = 0 ; SIGMA = 0.05 N.B.: For calculations using the gamma-point only version of vasp, {{TAG|NBANDS}} must be set to twice the ''maximum number of plane-waves:'' (found in the {{TAG|OUTCAR}} file) in step 1. For metals, we recommend to avoid setting {{TAG|LOPTICS}}=''.TRUE.'', since this slows down k-point convergence<ref name="harl"/>. Fourth step: Calculate the ACFDT-RPA correlation energy: NBANDS = maximum number of plane-waves ALGO = ACFDT NOMEGA = 8-24 To reach technical convergence, a number of flags are available to control the evaluation of the ACFDT-RPA correlation energy in the fourth step. The expression for the ACFDT-RPA correlation energy reads: <math>\mathrm{E}_{\mathrm{c}}=\int_{0}^{\infty} \frac{\mathrm{d}\omega}{2\pi} \sum_{{\mathbf{q}}\in{BZ}}\sum_{{\mathbf{G}}} \left\{(\mathrm{ln}[1-\chi^{KS}({\mathbf{q}},\mathrm{i}\omega)\nu({\mathbf{q}})])_{{\mathbf{G,G}}} +\nu_{{\mathbf{G,G}}}({\mathbf{q}})\chi^{KS}({\mathbf{q}},{\mathrm{i}}\omega) \right\} } .

The sum over reciprocal lattice vectors has to be truncated at some , determined by < ENCUTGW, which can be set in the INCAR file. The default value is ENCUT, which experience has taught us not to change. For systematic convergence tests, instead increase ENCUT and repeat steps 1 to 4, but be aware that the "maximum number of plane-waves" changes when ENCUT is increased. Note that it is virtually impossible, to converge absolute correlation energies. Rather concentrate on relative energies (e.g. energy differences between two solids, or between a solid and the constituent atoms).

Since correlation energies converge very slowly with respect to ${\mathbf{G}}_{\rm max}$,

VASP automatically extrapolates to the infinite basis set limit

using a linear regression to the equation~\cite{harl08,harl10,klimes14}: \begin{equation} E_{\rm c}({\mathbf{G}})=E_{\rm c}(\infty)+\frac{A}{{\mathbf{G}}^3}. \end{equation} Furthermore, the Coulomb kernel is smoothly truncated between {\tt ENCUTGWSOFT} and {\tt ENCUTGW} using a simple cosine like window function (Hann window function). The default for {\tt ENCUTGWSOFT} is 0.8~$\times$~{\tt ENCUTGW} (again we do not recommend to change this default).

The integral over $\omega$ is evaluated by means of a highly accurate mini-max integration.\cite{kaltak14} The number of $\omega$ points is determined by the flag {\tt NOMEGA}, whereas the energy range of transitions is determined by the band gap and the energy difference between the lowest occupied and highest unoccupied one-electron orbital. VASP determines these values automatically (from vasp.5.4.1 on), and the user should only carefully converge with respect to the number of frequency points {\tt NOMEGA}. A good choice is usually {\tt NOMEGA=12}, however, for large gap systems one might obtain $\mu$eV convergence per atom already using 8 points, whereas for metals up to {\tt NOMEGA=24} frequency points are sometimes necessary, in particular, for large unit cells.

Strictly adhear to the steps outlines above. Specifically, be aware that steps two and three require the {\tt WAVECAR} file generated in step one, whereas step four requires the {\tt WAVECAR} and {\tt WAVEDER} file generated in step three (generated by setting {\tt LOPTICS = .TRUE.}).\\

{\bf Some issues particular to ACFDT-RPA calculations on metals}:

\noindent For metals, the RPA groundstate energy converges fastest with respect to k-points, if the exchange (Eq.~(12) in Ref.~\cite{harl10}) and correlation energy are calculated on the same k-point grid, {\tt HFRCUT=1} is not set, and the long-wavelength contributions from the polarizability are not considered (see Ref.~\cite{harl10}).

To evaluate Eq.~(12) in Ref.~\cite{harl10}, a correction energy for E$_{\rm EXX}$ related to partial occupancies has to be added to the RPA groundstate energy: \begin{equation} \mathrm{E}_{\rm RPA}=\mathrm{E}_{\rm c}+\mathrm{E}_{\rm EXX}+ \mathrm{E}_{HFc}. \end{equation} In vasp.5.4.1, this value is calculated for any HF type calculation (step 2) and can be found in the OUTCAR file after the total energy (in the line starting with {\tt exchange ACFDT corr. = }).

To neglect the long-wavelength contributions, simply set {\tt LOPTICS =.FALSE.} in the {\tt ALGO = Exact} step (third step), {\em and} remove WAVEDER files in the directory.

Virtually the same flags and procedures apply to the new low scaling RPA algorithm. However, in the last step {\tt ALGO = ACFDT} needs to be replaced by {\tt ALGO = ACFDTR}. The new version is presently not part of the VASP distribution.

References

Cite error: <ref> tag with name "harl" defined in <references> is not used in prior text.