# Pseudopotential plane-wave density functional theory (NWPW)
[TOC]
## Overview
The NWChem plane-wave (NWPW) module uses pseudopotentials and plane-wave
basis sets to perform Density Functional Theory calculations (simple
introduction [pw-lecture.pdf](pw-lecture.pdf)).
This module complements the capabilities of the more traditional
Gaussian function based approaches by having an accuracy at least as
good for many applications, yet is still fast enough to treat systems
containing hundreds of atoms. Another significant advantage is its
ability to simulate dynamics on a ground state potential surface
directly at run-time using the Car-Parrinello algorithm. This method's
efficiency and accuracy make it a desirable first principles method of
simulation in the study of complex molecular, liquid, and solid state
systems. Applications for this first principles method include the
calculation of free energies, search for global minima, explicit
simulation of solvated molecules, and simulations of complex vibrational
modes that cannot be described within the harmonic approximation.
The NWPW module is a collection of three modules.
- PSPW - (PSeudopotential Plane-Wave) A gamma point code for
calculating molecules, liquids, crystals, and surfaces.
- Band - A band structure code for calculating crystals and surfaces
with small band gaps (e.g. semi-conductors and metals).
- PAW - a (gamma point) projector augmented plane-wave code for
calculating molecules, crystals, and surfaces
( *This module will be deprecated in the
future releases since PAW potentials have been added to PSPW*
)
The PSPW, Band, and PAW modules can be used to compute the energy and
optimize the geometry. Both the PSPW and Band modules can also be used
to find saddle points, and compute numerical second derivatives. In
addition the PSPW module can also be used to perform Car-Parrinello
molecular dynamics. Section [PSPW Tasks](#pspw-tasks-gamma-point-calculations)
describes the tasks contained within the PSPW module, section [Band
Tasks](#band-tasks-multiple-k-point-calculations) describes the tasks contained within the
Band module, section [PAW Tasks](#paw-tasks-legacy-implementation) describes the
tasks contained within the PAW module, and section [Pseudopotential and
PAW basis
Libraries](#pseudopotential-and-paw-basis-libraries)
describes the pseudopotential library included with NWChem. The
datafiles used by the PSPW module are described in section [NWPW RTDB
Entries and DataFiles](#nwpw-rtdb-entries-and-miscellaneous-datafiles).
Car-Parrinello output data files are described in section
[Car-Parrinello Output
Datafiles](#PSPW_Car-Parrinello_Output_Datafiles), and the
minimization and Car-Parrinello algorithms are described in section
[Car-Parrinello Scheme for Ab Initio Molecular
Dynamics](#car-parrinello-scheme-for-ab-initio-molecular-dynamics).
Examples of how to setup and run a PSPW geometry optimization, a
Car-Parrinello simulation, a band structure minimization, and a PAW
geometry optimization are presented at the end. Finally in section [NWPW
Capabilities and
Limitations](#nwpw-capabilities-and-limitations) the
capabilities and limitations of the NWPW module are discussed.
*As of NWChem 6.6 to use PAW potentials the
user is recommended to use the implementation contained in the PSPW
module (see Sections ). PAW potentials are also being integrated into
the BAND module. Unfortunately, the porting to BAND was not completed
for the NWChem 6.6 release.*
If you are a first time user of this module it is recommended that you
skip the next five sections and proceed directly to the tutorials.
## PSPW Tasks: Gamma Point Calculations
All input to the PSPW Tasks is contained within the compound PSPW block,
```
PSPW
...
END
```
To perform an actual calculation a TASK PSPW directive is used (Section
[Task](TASK)).
`TASK PSPW`
In addition to the directives listed in
[Task](TASK), i.e.
```
TASK PSPW energy
TASK PSPW gradient
TASK PSPW optimize
TASK PSPW saddle
TASK PSPW freqencies
TASK PSPW vib
```
there are additional directives that are specific to the
PSPW module, which are:
```
TASK PSPW [Car-Parrinello ||
Born-Oppenheimer ||
Metropolis ||
pspw_et ||
noit_energy ||
stress ||
pspw_dplot ||
wannier ||
expand_cell ||
exafs ||
ionize ||
lcao ||
rdf ||
aimd_properties ||
translate ||
psp_generator ||
steepest_descent ||
psp_formatter ||
wavefunction_initializer ||
v_wavefunction_initializer ||
wavefunction_expander ]
```
Once a user has specified a geometry, the PSPW module can be invoked
with no input directives (defaults invoked throughout). However, the
user will probably always specify the simulation cell used in the
computation, since the default simulation cell is not well suited for
most systems. There are sub-directives which allow for customized
application; those currently provided as options for the PSPW module
are:
```
NWPW
SIMULATION_CELL ... (see section [Simulation Cell](#simulation-cell)) END
CELL_NAME
VECTORS [[input () ||
[output()]]
XC (Vosko || LDA || PBE96 || revPBE || PBEsol ||
LDA-SIC || LDA-SIC/2 || LDA-0.4SIC || LDA-SIC/4 || LDA-0.2SIC ||
PBE96-SIC || PBE96-SIC/2 || PBE96-0.4SIC || PBE96-SIC/4 || PBE96-0.2SIC ||
revPBE-SIC || revPBE-SIC/2 || revPBE-0.4SIC || revPBE-SIC/4 || revPBE-0.2SIC ||
PBE96-Grimme2 || PBE96-Grimme3 || PBE96-Grimme4 || BLYP-Grimme2 || BLYP-Grimme3 || BLYP-Grimme4 ||
revPBE-Grimme2 || revPBE-Grimme3 || revPBE-Grimme4 || PBEsol-Grimme2 || PBEsol-Grimme3 || PBEsol-Grimme4 ||
PBE0-Grimme2 || PBE0-Grimme3 || PBE0-Grimme4 || B3LYP-Grimme2 || B3LYP-Grimme3 || B3LYP-Grimme4 ||
revPBE0-Grimme2 || revPBE0-Grimme3 || revPBE0-Grimme4 ||
PBE0 || revPBE0 || HSE || HF || default Vosko)
XC new ...(see section [Using Exchange-Correlation Potentials Available in the DFT Module](#Using_Exchange-Correlation_Potentials_Available_in_the_DFT_Module))
DFT||ODFT||RESTRICTED||UNRESTRICTED
MULT
CG
LMBFGS
SCF [Anderson|| simple || Broyden]
[CG || RMM-DIIS]
[density || potential]
[ALPHA real alpha default 0.25]
[Kerker real ekerk nodefault]
[ITERATIONS integer inner_iterations default 5]
[OUTER_ITERATIONS integer outer_iterations default 0]
LOOP
TOLERANCES
FAKE_MASS
TIME_STEP
EWALD_NCUT
EWALD_RCUT
CUTOFF
ENERGY_CUTOFF
WAVEFUNCTION_CUTOFF
ALLOW_TRANSLATION
TRANSLATION (ON || OFF)
ROTATION (ON || OFF)
MULLIKEN [OFF]
EFIELD
BO_STEPS
MC_STEPS
BO_TIME_STEP
BO_ALGORITHM [verlet|| velocity-verlet || leap-frog]
BO_FAKE_MASS
SOCKET (UNIX || IPI_CLIENT)
MAPPING
NP_DIMENSIONS
CAR-PARRINELLO ... (see section [Car-Parrinello](#car-parrinello-scheme-for-ab-initio-molecular-dynamics)) END
STEEPEST_DESCENT ... (see section [Steepest Descent](#STEEPEST_DESCENT)) END
DPLOT ... (see section [DPLOT](#DPLOT)) END
WANNIER ... (see section [Wannier](#Wannier)) END
PSP_GENERATOR ... (see section [PSP Generator](#PSP_GENERATOR))) END
WAVEFUNCTION_INITIALIZER ... (see section [Wavefunction Initializer](NWPW_RETIRED#WAVEFUNCTION_INITIALIZER) - retired) END
V_WAVEFUNCTION_INITIATIZER ... (see section [Wavefunction Velocity Initializer (NWPW_RETIRED#V_WAVEFUNCTION_INITIALIZER) - retired) END
WAVEFUNCTION_EXPANDER ... (see section [Wavefunction Expander](NWPW_RETIRED#WAVEFUNCTION_EXPANDER) - retired) END
INPUT_WAVEFUNCTION_FILENAME
OUTPUT_WAVEFUNCTION_FILENAME
END
```
The following list describes the keywords contained in the PSPW input
block.
- `cell_name` - name of the simulation_cell named `cell_name`. See
section [Simulation Cell](#simulation-cell).
- `input_wavefunctions` - name of the file containing one-electron
orbitals
- `output_wavefunctions` - name of the file that will contain the
one-electron orbitals at the end of the run.
- `fake_mass` - value for the electronic fake mass $\mu$
This parameter is not presently used in a conjugate gradient
simulation.
- `time_step` - value for the time step $\Delta t$. This parameter
is not presently used in a conjugate gradient simulation.
- `inner_iteration` - number of iterations between the printing out of
energies and tolerances
- `outer_iteration` - number of outer iterations
- `tole` - value for the energy tolerance.
- `tolc` - value for the one-electron orbital tolerance.
- `cutoff` - value for the cutoff energy used to define the
wavefunction. In addition using the CUTOFF keyword automatically
sets the cutoff energy for the density to be twice the wavefunction
cutoff.
- `ecut` - value for the cutoff energy used to define the density.
Default is set to be the maximum value that will fit within the
simulation_cell `cell_name`.
- `wcut` - value for the cutoff energy used to define the one-electron
orbitals. Default is set to be the maximum value that will fit
within the simulation_cell `cell_name`.
- `ncut` - value for the number of unit cells to sum over (in each
direction) for the real space part of the Ewald summation. Note
Ewald summation is only used if the simulation_cell is periodic.
- `rcut` - value for the cutoff radius used in the Ewald summation.
Note Ewald summation is only used if the simulation_cell is
periodic.
Default set to be $\frac{MIN(\left| \vec{a_i} \right|)}{\pi}, i=1,2,3$.
- (Vosko || PBE96 || revPBE || ...) - Choose between Vosko et al's LDA
parameterization or the orginal and revised Perdew, Burke, and
Ernzerhof GGA functional. In addition, several hybrid options.
- MULT - optional keyword which if specified allows the user to define
the spin multiplicity of the system
- MULLIKEN - optional keyword which if specified causes a Mulliken
analysis to be performed at the end of the simulation.
- EFIELD - optional keyword which if specified causes an atomic
electric field analysis to be performed at the end of the
simulation.
- ALLOW_TRANSLATION - By default the the center of mass forces are
projected out of the computed forces. This optional keyword if
specified allows the center of mass forces to not be zero.
- TRANSLATION - By default the the center of mass forces are projected
out of the computed forces. TRANSLATION ON allows the center of mass
forces to not be zero.
- ROTATION - By default the overall rotation is not projected out of
the computed forces. ROTATION OFF projects out the overal rotation
of the molecule.
- CG - optional keyword which sets the minimizer to 1
- LMBFGS - optional keyword which sets the minimizer to 2
- SCF - optional keyword which sets the minimizer to be a band by band
minimizer. Several options are available for setting the density or
potential mixing, and the type of Kohn-Sham minimizer.
- `mapping` - for a value of 1 slab FFT is used, for a value of 2 a
2d-hilbert FFT is used.
A variety of prototype minimizers can be used to minimize the energy. To
use these other optimizers the following SET directive needs to be
specified:
```
set nwpw:mimimizer 1 # Default - Grassman conjugate gradient minimizer is used to minimize the energy.
set nwpw:mimimizer 2 # Grassman LMBFGS minimimzer is used to minimize the energy.
set nwpw:minimizer 4 # Stiefel conjugate gradient minimizer is used to minimize the energy.
set nwpw:minimizer 5 # Band-by-band (potential) minimizer is used to minimize the energy.
set nwpw:minimizer 6 # Projected Grassman LMBFGS minimizer is used to minimize the energy.
set nwpw:minimizer 7 # Stiefel LMBFGS minimizer is used to minimize the energy.
set nwpw:minimizer 8 # Band-by-band (density) minimizer is used to minimize the energy.
```
Limited testing suggests that the Grassman LMBFGS minimizer is about
twice as fast as the conjugate gradient minimizer. However, there are
several known cases where this optimizer fails, so it is currently not a
default option, and should be used with caution.
In addition the following SET directives can be
specified:
```
set nwpw:lcao_skip .false. # Initial wavefunctions generated using an LCAO guess.
set nwpw:lcao_skip .true. # Default - Initial wavefunctions generated using a random plane-wave guess.
set nwpw:lcao_print .false. # Default - Output not produced during the generation of the LCAO guess.
set nwpw:lcao_print .true. # Output produced during the generation of the LCAO guess.
set nwpw:lcao_iterations 2 #specifies the number of LCAO iterations.
```
### PAW Potentials
The PSPW code can now handle PAW potentials. To use them the
pseudopotentials input block is used to redirect the code to use the paw
potentials located in the default paw potential library
(`$NWCHEM_TOP/src/nwpw/libraryp/paw_default`). For example, to redirect
the code to use PAW potentials for carbon and hydrogen, the following
input would be used.
```
nwpw
pseudopotentials
C library paw_default
H library paw_default
end
end
```
Most of the capabilities of PSPW will work with PAW potentials including
geometry optimization, Car-Parrinello ab initio molecular dynamics,
Born-Oppenheimer ab initio molecular dynamics, Metropolis Monte-Carlo,
and AIMD/MM. Unfortunately, some of the functionality is missing at this
point in time such as Mulliken analysis, and analytic stresses. However
these small number of missing capabilities should become available over
the next couple of months in the development tree of NWChem.
Even though analytic stresses are not currently available with PAW
potentials unit cell optimization can still be carried out using
numerical stresses. The following SET directives can be used to tell the
code to calculate stresses
numerically.
```
set includestress .true. #this option tells driver to optimize the unit cell
set includelattice .true. #this option tells driver to optimize cell using a,b,c,alpha,beta,gamma
set nwpw:frozen_lattice:thresh 999.0 #large number guarentees the lattice gridding does not adjust during optimization
set nwpw:cif_filename pspw_corundum
set nwpw:stress_numerical .true.
set nwpw:lstress_numerical .true.
```
#### PAW Implementation Notes
The main idea in the PAW method(Blochl 1994) is to project out the
high-frequency components of the wavefunction in the atomic sphere
region. Effectively this splits the original wavefunction into two
parts:
$$\psi_n(\mathbf{r}) = \tilde{\psi}_n(\mathbf{r}) + \sum_I \psi_n^I(\mathbf{r})$$
The first part $\tilde{\psi}_n(\mathbf{r})$ is smooth and can be
represented using a plane wave basis set of practical size. The second
term is localized with the atomic spheres and is represented on radial
grids centered on the atoms
as
$$\psi_n^I(\mathbf{r}) = \sum_{\alpha} (\varphi_{\alpha}^I(\mathbf{r})-\tilde{\varphi}_{\alpha}^I(\mathbf{r}))c_{n\alpha}^I$$
where the coefficients $c_{n\alpha}^I$ are given by
$$ c_{n\alpha}^I = <\tilde{p}_{\alpha}^I | \tilde{\psi}_n>$$
This decomposition can be expressed using an invertible linear
transformation, $T$, is defined which relates the stiff one-electron
wavefunctions $\psi_n$ to a set of smooth one-electron wavefunctions
$\tilde{\psi}_n$
$$\tilde{\psi}_n = T \psi_n$$
$$\psi_n = T^{-1} \tilde{\psi}_n$$
which can be represented by fairly small plane-wave basis. The
transformation $T$ is defined using a local PAW basis, which consists
of atomic orbitals, $\varphi{\alpha}^I(\mathbf{r})$,
smooth atomic
orbitals, $\tilde{\varphi}$αI(**r**) which coincide with
the atomic orbitals outside a defined atomic sphere, and projector
functions, $p_{\alpha}^I(\mathbf{r})$. Where I is the atomic index and
α is the orbital index. The projector functions are constructed such
that they are localized within the defined atomic sphere and in addition
are orthonormal to the atomic orbitals. Blöchl defined the invertible linear transformations by
$$T = 1 + \sum_I \sum_\alpha (|\tilde{\varphi}_\alpha^I> - |\varphi_\alpha^I > ) < p_\alpha^I|$$
$$\tilde{T} = 1 + \sum_I \sum_{\alpha} (|\varphi_{\alpha}^I> - |\tilde{\varphi}_{\alpha}^I >)<\tilde{\varphi}_{\alpha}^I|$$
$$|\tilde{p}_{\alpha}^I> = \sum_{\beta} [<\tilde{p}^I | \varphi^I >]_{\alpha\beta}^{-1} | p_{\beta}^I>$$
The main effect of the PAW transformation is that the fast variations of
the valence wave function in the atomic sphere region are projected out
using local basis set, thereby producing a smoothly varying wavefunction
that may be expanded in a plane wave basis set of a manageable size.
The expression for the total energy in PAW method can be separated into
the following 15 terms.
$$E_{PAW} = \tilde{E}_{kinetic-pw} + \tilde{E}_{vlocal-pw} + \tilde{E}_{Coulomb-pw} + \tilde{E}_{xc-pw} + E_{ion-ion}$$
$$ + E_{cmp-cmp} + E_{cmp-pw} + E_{valence-core} + E_{kinetic-core} + E_{ion-core}$$
The first five terms are essentially the same as for a standard
pseudopotential plane-wave program, minus the non-local pseudopotential,
where
$$\tilde{E}_{kinetic-pw} = \sum_i \sum_{\mathbf{G}} \frac{|\mathbf{G}|^2}{2} \tilde{\psi}_i^{*}(\mathbf{G}) \tilde{\psi}_i(\mathbf{G})$$
$$\tilde{E}_{vlocal-pw} = \sum_{\mathbf{G}} \tilde{\rho}(\mathbf{G}) V_{local}(\mathbf{G})$$
$$\tilde{E}_{Coulomb-pw} = \frac{\Omega}{2} \sum_{\mathbf{G}} \frac{4\pi}{|\mathbf{G}|} \tilde{\rho}^{*}(\mathbf{G}) \tilde{\rho}(\mathbf{G})$$
$$\tilde{E}_{xc-pw} = \frac{\Omega}{N_1 N_2 N_3} \sum_{\mathbf{r}} \tilde{\rho}(\mathbf{r}) \epsilon_{xc}(\tilde{\rho}(\mathbf{r}))$$
$$E_{ion-ion} = \frac{1}{2\Omega} \sum_{\mathbf{G}} \frac{4\pi}{|\mathbf{G}|^2} \exp(\frac{|\mathbf{G}|^2}{4\epsilon}) \sum_{I,J} Z_I \exp (-i \mathbf{G} \cdot \mathbf{R}_I) Z_J \exp ( -i \mathbf{G} \cdot \mathbf{R}_J) + $$
$$\frac{1}{2}\sum_{\mathbf{a}} \sum_{I,J \in |\mathbf{R}_I-\mathbf{R}_J+\mathbf{a}|} Z_I Z_J \frac{erf(\epsilon |\mathbf{R}_I-\mathbf{R}_J+\mathbf{a}|)}{|\mathbf{R}_I-\mathbf{R}_J+\mathbf{a}|} - \frac{\epsilon}{\pi}\sum_I Z_I^2 + $$
$$ - \frac{\pi}{2\epsilon^2\Omega} \left( \sum_{I} Z_{I} \right)^2 $$
The local potential in the $\tilde{E}_{vlocal-pw}$ term is the Fourier
transform of
$$V_{local}(\mathbf{r}) = -\sum_I Z_I \frac{\frac{|\mathbf{r}-\mathbf{R}_I|}{\sigma_I}}{|\mathbf{r}-\mathbf{R}_I|} + v_{ps}^I(|\mathbf{|\mathbf{r}-\mathbf{R}_I|})$$
It turns out that for many atoms $\sigma_I$ needs to be fairly small.
This results in $V_{local} (\mathbf{r})$ being stiff. However, since
in the integral above this function is multiplied by a smooth density
$\tilde{\rho}(\mathbf{G})$ the expansion of Vlocal(G)
only needs to be the same as the smooth density. The auxiliary
pseudoptential $v_{ps}^I (|\mathbf{r}-\mathbf{R}_I |)$ is defined to
be localized within the atomic sphere and is introduced to remove ghost
states due to local basis set incompleteness.
The next four terms are atomic based and they essentially take into
account the difference between the true valence wavefunctions and the
pseudowavefunctions.
$$ E_{kinetic-atom}= \sum_I \sum_i \sum_{\alpha\beta} <\tilde{\psi}_i|\tilde{p}_{\alpha}^I < (t_{atom}^I)_{\alpha\beta} <\tilde{p}_{\beta}^I|\tilde{\psi}_i $$
$$ E_{local-atom}=\sum_I \sum_i \sum_{\alpha\beta} <\tilde{\psi}_i|\tilde{p}_{\alpha}^I> (u_{atom}^I)_{\alpha\beta} <\tilde{p}_{\beta}^I|\tilde{\psi}_i>$$
$$ E_{xc-atom}=\sum_I \sum_{\theta\phi} w_{\theta\phi} \int_0^{r_{cut}^I} r^2 (\rho^I(r,\theta,\phi) \epsilon_{xc}(\rho^I(r,\theta,\phi)) -\tilde{\rho}^I(r,\theta,\phi) \epsilon_{xc}(\tilde{\rho}^I(r,\theta,\phi))) dr $$
$$ E_{hartree-atom}= \sum_I W_{atom}^I =\frac{1}{2} \sum_I \sum_i \sum_{\alpha\beta} <\tilde{\psi}_i|\tilde{p}_{\alpha}> <\tilde{p}_{\beta}^I|\tilde{\psi}_i> $$
$$ \sum_j \sum_{\mu\nu} <\tilde{\psi}_j|\tilde{p}_{\mu}^I> <\tilde{p}_{\nu}^I|\tilde{\psi}_j> \sum_{lm} \tau_{l_\alpha m_\alpha, l_\beta m_\beta}^{lm} \tau_{l_\mu m_\mu, l_\nu m_\nu}^{lm} (V_{Heff}^I)_{\alpha\beta\mu\nu}^{l} $$
The next three terms are the terms containing the compensation charge
densities.
$$E_{cmp-vloc}= \sum_{\mathbf{G}} [\rho_{cmp} (\mathbf{G}) \tilde{V}_{local}(\mathbf{G})+\tilde{\rho}_{cmp}(\mathbf{G})(V_{local}(\mathbf{G})-\tilde{V}_{local}(\mathbf{G}))] + \\
\int (\rho_{cmp}(\mathbf{r})-\tilde{\rho}_{cmp}(\mathbf{r}))(V_{local}(r)-\tilde{V}_{local}(\mathbf{r}))d\mathbf{r}$$
$$E_{cmp-cmp}= \Omega \sum_{\mathbf{G} \neq 0} \frac{4\pi}{|\mathbf{G}|^2} [ \rho_{cmp}(\mathbf{G}) \tilde{\rho}_{cmp}(\mathbf{G})- \frac{1}{2} \tilde{\rho}_{cmp}(\mathbf{G})\tilde{\rho}_{cmp}(\mathbf{G})] + \\
\frac{1}{2} \iint \frac{(\rho_{cmp}(\mathbf{r})-\tilde{\rho}_{cmp}(\mathbf{r}))(\rho_{cmp}(\mathbf{r}')-\tilde{\rho}_{cmp}(\mathbf{r}'))} {|\mathbf{r}-\mathbf{r}'|} d\mathbf{r} d\mathbf{r}'$$
$$E_{cmp-pw}= \Omega \sum_{\mathbf{G} \neq 0} \frac{4\pi}{|\mathbf{G}|^2} \rho_{cmp}(\mathbf{G}) \tilde{\rho}(\mathbf{G})$$
In the first two formulas the first terms are computed using plane-waves
and the second terms are computed using Gaussian two center integrals.
The smooth local potential in the $E_{cmp-vloc}$ term is the Fourier
transform
of
$$\tilde{V}_{local}(\mathbf{r})=- \sum_I Z_I \frac{ erf( \frac{ |\mathbf{r}-\mathbf{R}_I | }{\tilde{\sigma}_I })} {|r-R_I |}$$
The stiff and smooth compensation charge densities in the above formula
are
$$\rho_{cmp}(r)=\sum_I\sum_{lm} Q_{lm}^I g_{lm}^(\sigma_I ) (r-R_I )$$
$$\tilde{\rho}_{cmp}(r)=\sum_I \sum_{lm} Q_{lm}^I g_{lm}^(\tilde{\sigma}_I ) (r-R_I )$$
where
$$Q_{lm}^I = \sum_i \sum_{\alpha\beta} <\tilde{\psi}_i|\tilde{p}_\alpha^I > <\tilde{p}_\beta^I|\tilde{\psi}_i > \tau_{l_\alpha m_\alpha, l_\beta m_\beta}^{lm} (q_{comp}^I )_{\alpha\beta}^l$$
The decay parameter $\sigma_I$ is defined the same as above, and
$\tilde{\sigma}$I is defined to be smooth enough in order that ρ̃cmp(r) and $\tilde{V}$local(r) can readily be expanded in
terms of plane-waves.
The final three terms are the energies that contain the core
densities
$$E_{valence-core}=\sum_{i}\sum_{I}\sum_{\alpha \beta}<\tilde{\psi}_{i} | \tilde{p}_{\alpha}^{I} > (V_{valence-core})_{\alpha \beta}^{I} <\tilde{p}_\beta^{I} | \tilde{\psi}_{i} >$$
$$E_{kinetic-core}=\sum_c \int_0^\infty \left[ (\varphi_{n_c l_c}^I (r))^{'} (\varphi_{n_c l_c}^{I} (r))^{'} + l_c (l_c+1) \frac{\varphi_{n_c l_c}^{I} (r) \varphi_{n_c l_c}^{I} (r)}{r^{2}} \right] dr$$
$$E_{ion-core}= \sum_I \frac{1}{2} \iint \frac{\rho_c^{I} (r) \rho_c^{I} (r')}{|r-r'|} drdr^{'} - \int \frac{\rho_c^{I} (r)}{|r|} (Z_I+Z_I^{core} ) dr$$
The matrix elements contained in the above formula are
$$(t_{atom}^{I} )_{\alpha \beta}= {\delta_{m_\alpha m_\beta} \delta_{l_\alpha l_\beta }}2 \int_0^{r_{cut}^I} \left[
(\varphi_{n_\alpha l_\alpha}^{I} (r))' (\varphi_{n_\beta l_\beta}^{I} (r))' - (\tilde{\varphi}_{n_\alpha l_\alpha}^{I} (r))' (\tilde{\varphi}_{n_\beta l_\beta}^{I} (r))' + l_\alpha (l_\alpha+1) \frac{ \varphi_{n_\alpha l_\alpha}^{I}(r) \varphi_{n_\beta l_\beta}^{I}(r) - \tilde{\varphi}_{n_\alpha l_\alpha}^{I}(r) \tilde{\varphi}_{n_\beta l_\beta}^I }{r^2 } \right] dr$$
$$(u_{atom}^I )_{\alpha \beta} =\frac{Z_I}{4\pi} (V_{comp}^I )_{\alpha \beta}^{l=0} + \frac{2Z_I}{(\sqrt{2\pi} \sigma_I } (q_comp^I )_{\alpha \beta}^(l=0) +\delta_{m_\alpha m_\beta } \delta_{l_\alpha l_\beta } \int_0^{r_{cut}^I} [ \varphi_{n_\alpha l_\alpha}^I (r) \varphi_(n_\beta l_\beta)^I (r) \frac{-Z_I}{r} + \tilde{\varphi}_{n_\alpha l_\alpha}^I (r) \tilde{\varphi}_{n_\beta l_\beta}^I (r) (-v_{ps}^I (r)) ] dr$$
$$(V_{Heff}^I )_{\alpha \beta \mu \nu}^l = (V_H^I )_{\alpha\beta\mu\nu}^l - 2(V_{comp}^I )_{\alpha\beta}^l (q_{comp}^I )_{\mu\nu}^l -(v_g^I )^l (q_{comp}^I )_{\alpha\beta}^l (q_{comp}^I )_{\mu\nu}^l$$
$$(V_H^I )_{\alpha\beta\mu\nu}^l = \frac{4\pi}{2l+1} \int_0^{r_{cut}^I} \int_0^{r_{cut}^I} \left( \frac{r_{<}^l}{r_{>}^{l+1} } \right)( \varphi_{n_\alpha l_\alpha } (r) \varphi_{n_\beta l_\beta } (r) \varphi_{n_\mu l_\mu } (r) \varphi_{n_\nu l_\nu } (r) - \tilde{\varphi}_{n_\alpha l_\alpha } (r) \tilde{\varphi}_(n_\beta l_\beta ) (r) \tilde{\varphi}_{n_\mu l_\mu } (r) \tilde{\varphi}_{n_\nu l_\nu } (r) ) drdr'$$
$$(V_{comp}^I )_{\alpha\beta}^l = \frac{4\pi}{2l+1} \int_0^{r_{cut}^I} \int_0^{r_{cut}^I} \tilde{\varphi}_{n_\alpha l_\alpha } (r) \tilde{\varphi}_{n_\beta l_\beta } (r) \left( \frac{r_{<}^l}{r_{>}^{l+1} } \right) g_l^I (r') r'^2 drdr'$$
$$(q_{comp}^I )_{\alpha\beta}^l = \int_0^\infty r^l \left( \varphi_{n_\alpha l_\alpha } (r) \varphi_{n_\beta l_\beta } (r)- \tilde{\varphi}_{n_\alpha l_\alpha } (r) \tilde{\varphi}_{n_\beta l_\beta } (r) \right) dr$$
$$(v_g^I )^l =\frac{4\sqrt{2\pi}}{ (2l+1)(2l+1)!! \sigma_I^{2l+1} }$$
$$\tau_{l_\alpha m_\alpha,l_\beta m_\beta}^{lm}= \int_0^{2\pi} \int_0^{\pi} T_{lm} (\theta,\phi) T_{l_\alpha m_\alpha } (\theta,\phi) T_{l_\beta m_\beta } (\theta,\phi) \sin(\theta) d\theta d\phi$$
### Exchange-Correlation Potentials
#### DFT + U Corrections
TO DO
```
nwpw
uterm d 0.13634 0.0036749 1
end
```
#### Langreth style vdw and vdw van der Wall functionals
These potenials that are used to augment standard exchange-correlation potentials area calculated from a double integral over a nonlocal interaction kernel, $\phi(\mathbf{r},\mathbf{r}^{'})$
$$E_{vdw} = \int \rho(\mathbf{r}) \phi(\mathbf{r},\mathbf{r}^{'}) \rho(\mathbf{r}^{'}) d\mathbf{r} d\mathbf{r}^{'} $$
that is evaluated using the fast Fourier transformation method of Roman-Perez and Soler.
G. Roman-Perez and J. M. Soler, Phys. Rev. Lett. 103, 096102 (2009).
Langreth vdw and vdw2 van der Wall functionals are currently available for the BEEF, PBE96,
revPBE, PBEsol, BLYP, PBE0, revPBE0, HSE, and B3LYP exchange-correlation
functionals. To use them the following keywords BEEF-vdw, BEEF-vdw2, PBE96-vdw,
PBE96-vdw2, BLYP-vdw, BLYP-vdw2,
revPBE-vdw, revPBE-vdw, PBEsol-vdw PBEsol-vdw2, PBE0-vdw, PBE0-vdw2,
revPBE0-vdw, revPBE0-vdw2, HSE-vdw, HSE-vdw2, B3LYP-vdw, and B3LYP-vdw2
can be used in the XC input directive, e.g.
```
nwpw
xc beef-vdw
end
```
```
nwpw
xc beef-vdw2
end
```
the vdw and vdw2 functionals are defined in
(vdw) Dion M, Rydberg H, Schröder E, Langreth DC, Lundqvist BI. Van der Waals density functional for general geometries. Physical review letters. 2004 Jun 16;92(24):246401.
(vdw2) K. Lee, E. D. Murray, L. Kong, B. I. Lundqvist, and D. C. Langreth, Phys. Rev. B 82, 081101 (2010).
#### Grimme Dispersion Corrections
Grimme dispersion corrections are currently available for the PBE96,
revPBE, PBEsol, BLYP, PBE0, revPBE0, HSE, and B3LYP exchange-correlation
functionals. To use them the following keywords PBE96-Grimme2,
PBE96-Grimme3, PBE96-Grimme4, BLYP-Grimme2, BLYP-Grimme3, BLYP-Grimme4,
revPBE-Grimme2, revPBE-Grimme3, revPBE-Grimme4, PBEsol-Grimme2,
PBEsol-Grimme3, PBEsol-Grimme4, PBE0-Grimme2, PBE0-Grimme3,
PBE0-Grimme4, revPBE0-Grimme2, revPBE0-Grimme3, revPBE0-Grimme4,
HSE-Grimme2, HSE-Grimme3, HSE-Grimme4, B3LYP-Grimme2, B3LYP-Grimme3, and
B3LYP-Grimme4 can be used in the XC input directive, e.g.
```
nwpw
xc pbe96-grimme2
end
```
In these functionals Grimme2, Grimme3 and Grimme4 are defined in the
following papers by S. Grimme.
Grimme2 - Commonly known as DFT-D2, S. Grimme, J. Comput. Chem., 27
(2006), 1787-1799.
Grimme3 - Commonly known as DFT-D3, S. Grimme, J. Antony, S. Ehrlich and
H. Krieg A consistent and accurate ab initio parameterization of density
functional dispersion correction (DFT-D) for the 94 elements H-Pu, J.
Chem. Phys, 132 (2010), 154104
Grimme4 - Commonly known as DFT-D3 with BJ damping. This correction
augments the Grimme3 correction by including BJ-damping, S. Grimme, J.
Antony, S. Ehrlich and H. Krieg A consistent and accurate ab initio
parameterization of density functional dispersion correction (DFT-D) for
the 94 elements H-Pu, J. Chem. Phys, 132 (2010), 154104. S. Grimme, S.
Ehrlich and L. Goerigk, J. Comput. Chem, 32 (2011), 1456-1465. This
correction augments the Grimme3 correction by including BJ-damping.
If these functionals are used in a publication please include in your
citations the references to Grimme's work.
#### Using Exchange-Correlation Potentials Available in the DFT Module
(*Warning - To use this capability in NWChem
6.6 the user must explicitly include the nwxc module in the
NWCHEM_MODULES list when compiling. Unfortunately, there was too much
uncertainty in how the nwxc computed higher-order derivatives used by
some of the functionality in nwdft module to include it in a release for
all the functionality in NWChem. We are planning to have a debug release
in winter 2016 to take fix this problem. This capability is still
included by default in NWChem 6.5*)
The user has the option of using many of the exchange-correlation
potentials available in DFT Module (see Section [XC and DECOMP --
Exchange-Correlation
Potentials](Density-Functional-Theory-for-Molecules#xc-and-decomp-exchange-correlation-potentials)).
```
XC [[acm] [b3lyp] [beckehandh] [pbe0] [bhlyp]\
[becke97] [becke97-1] [becke97-2] [becke97-3] [becke98] [hcth] [hcth120] [hcth147] \
[hcth407] [becke97gga1] [hcth407p] \
[optx] [hcthp14] [mpw91] [mpw1k] [xft97] [cft97] [ft97] [op] [bop] [pbeop]\
[HFexch ] \
[becke88 [nonlocal] ] \
[xperdew91 [nonlocal] ] \
[xpbe96 [nonlocal] ] \
[gill96 [nonlocal] ] \
[lyp ] \
[perdew81 ] \
[perdew86 [nonlocal] ] \
[perdew91 [nonlocal] ] \
[cpbe96 [nonlocal] ] \
[pw91lda ] \
[slater ] \
[vwn_1 ] \
[vwn_2 ] \
[vwn_3 ] \
[vwn_4 ] \
[vwn_5 ] \
[vwn_1_rpa ]]
```
These functional can be invoked by prepending the "new" directive before
the exchange correlation potetntials in the input directive, XC new
slater vwn_5.
That is, this statement in the input file
```
nwpw
XC new slater vwn_5
end
task pspw energy
```
Using this input the user has ability to include only the local or
nonlocal contributions of a given functional. The user can also specify
a multiplicative prefactor (the variable `prefactor` in the input) for
the local/nonlocal component or total (for more details see Section [XC
and DECOMP -- Exchange-Correlation
Potentials](Density-Functional-Theory-for-Molecules#xc-and-decomp-exchange-correlation-potentials)).
An example of this might be,
` XC new becke88 nonlocal 0.72`
The user should be aware that the Becke88 local component is simply the
Slater exchange and should be input as such.
Any combination of the supported exchange functional options can be
used. For example the popular Gaussian B3 exchange could be specified
as:
` XC new slater 0.8 becke88 nonlocal 0.72 HFexch 0.2`
Any combination of the supported correlation functional options can be
used. For example B3LYP could be specified
as:
`XC new vwn_1_rpa 0.19 lyp 0.81 HFexch 0.20 slater 0.80 becke88 nonlocal 0.72`
and X3LYP as:
```
xc new vwn_1_rpa 0.129 lyp 0.871 hfexch 0.218 slater 0.782 \
becke88 nonlocal 0.542 xperdew91 nonlocal 0.167
```
#### Exact Exchange
#### Self-Interaction Corrections
The SET directive is used to specify the molecular orbitals contribute
to the self-interaction-correction (SIC) term.
```
set pspw:SIC_orbitals
```
This defines only the molecular orbitals in the list as SIC active. All
other molecular orbitals will not contribute to the SIC term. For
example the following directive specifies that the molecular orbitals
numbered 1,5,6,7,8, and 15 are SIC active.
`set pspw:SIC_orbitals 1 5:8 15`
or equivalently
`set pspw:SIC_orbitals 1 5 6 7 8 15`
The following directive turns on self-consistent SIC.
```
set pspw:SIC_relax .false. # Default - Perturbative SIC calculation
set pspw:SIC_relax .true. # Self-consistent SIC calculation
```
Two types of solvers can be used and they are specified using the
following SET directive
```
set pspw:SIC_solver_type 1 # Default - cutoff coulomb kernel
set pspw:SIC_solver_type 2 # Free-space boundary condition kernel
```
The parameters for the cutoff coulomb kernel are defined by the
following SET directives:
```
set pspw:SIC_screening_radius
set pspw:SIC_screening_power
```
### Wannier
The pspw wannier task is generate maximally localized (Wannier)
molecular orbitals. The algorithm proposed by Silvestrelli et al is use
to generate the Wannier orbitals.
Input to the Wannier task is contained within the Wannier sub-block.
```
NWPW
...
Wannier
...
END
...
END
```
To run a Wannier calculation the following directive is used:
`TASK PSPW Wannier`
Listed below is the format of a Wannier
sub-block.
```
NWPW
...
Wannier
OLD_WAVEFUNCTION_FILENAME
NEW_WAVEFUNCTION_FILENAME
END
...
END
```
The following list describes the input for the Wannier sub-block.
- `input_wavefunctions` - name of pspw wavefunction file.
- `output_wavefunctions` - name of pspw wavefunction file that will
contain the Wannier orbitals.
### Mulliken Analysis
### Density of States
The "dos" option is used to turn on a density of states analysis. This
option can be specified without additional parameters, i.e.
```
nwpw
dos
end
```
in which case default values are used, or it can be specified with
additional parameters, e.g.
```
nwpw
dos 0.002 700 -0.80000 0.8000
end
```
The parameters are
```
nwpw
dos [ ]
end
```
where
- `alpha` value for the broadening the eigenvalues, default
0.05/27.2116 au
- `npoints` number of plotting points in dos files, default 500
- `emin` minimum energy in dos plots, default min(eigenvalues)-0.1
au
- `emax` maximimum energy in dos plots, default max(eigenvalues)+0.1
au
The units for dos parameters are in atomic units. Note that if virtual
states are specified in the pspw calculation then the virtual density of
states will also be generated in addition to the filled density of
states.
The following files are generated and written to the permanent_dir for
restricted calculations
- file_prefix.smear_dos_both - total density of states
- file_prefix.smear_fdos_both - density of states of filled states
- file_prefix.smear_vdos_both - density of states of virtual states
For unrestricted calculations
- file_prefix.smear_dos_alpha - total density of states for up
electrons
- file_prefix.smear_dos_beta - total density of states for down
electrons
- file_prefix.smear_fdos_alpha - density of states for filled up
electrons
- file_prefix.smear_fdos_beta - density of states for filled down
electrons
- file_prefix.smear_vdos_alpha - density of states for virtual up
electrons
- file_prefix.smear_vdos_beta - density of states for virtual down
electrons
The nwpw:dos:actlist variable is used to specify the atoms used to
determine weights for dos generation. If the variable is not set then
all the atoms are used, e.g.
`set nwpw:dos:actlist 1 2 3 4`
### Projected Density of States
For projected density of states the "Mulliken" keyword needs to be set,
e.g.
```
nwpw
Mulliken
dos
end
```
The following additional files are generated and written to the
permanent_dir for restricted calculations
- file_prefix.mulliken_dos_both_s - total s projected density of
restricted states
- file_prefix.mulliken_fdos_both_s - s projected density of states
of filled restricted states
- file_prefix.mulliken_vdos_both_s - s projected density of states
of virtual restricted states
- file_prefix.mulliken_dos_both_p - total p projected density of
states
- file_prefix.mulliken_fdos_both_p - p projected density of states
of filled states
- file_prefix.mulliken_vdos_both_p - p projected density of states
of virtual states
...
- file_prefix.mulliken_dos_both_all - total of projected density
of filled and virtual restricted states
- file_prefix.mulliken_fdos_both_all - total of projected density
of filled restricted states
- file_prefix.mulliken_vdos_both_all - total of projected density
of states of virtual restricted states
Similarly for unrestricted calculations
- file_prefix.mulliken_dos_alpha_s - total s projected density of
up states
- file_prefix.mulliken_fdos_alpha_s - s projected density of
states of filled up states
- file_prefix.mulliken_vdos_alpha_s - s projected density of
states of virtual up states
- file_prefix.mulliken_dos_alpha_p - total p projected density of
up states
- file_prefix.mulliken_fdos_alpha_p - p projected density of
states of filled up states
- file_prefix.mulliken_vdos_alpha_p - p projected density of
states of virtual up states
...
- file_prefix.mulliken_dos_alpha_all - total of projected density
of filled up states
- file_prefix.mulliken_fdos_alpha_all - total of projected density
of filled up states
- file_prefix.mulliken_vdos_alpha_all - total of projected density
of states of virtual up states
...
- file_prefix.mulliken_dos_beta_s - total s projected density of
down states
- file_prefix.mulliken_fdos_beta_s - s projected density of states
of filled down states
- file_prefix.mulliken_vdos_beta_s - s projected density of states
of virtual down states
- file_prefix.mulliken_dos_beta_p - total p projected density of
down states
- file_prefix.mulliken_fdos_beta_p - p projected density of states
of filled down states
- file_prefix.mulliken_vdos_beta_p - p projected density of states
of virtual down states
...
- file_prefix.mulliken_dos_beta_all - total of projected density
of filled down states
- file_prefix.mulliken_fdos_beta_all - total of projected density
of filled down states
- file_prefix.mulliken_vdos_beta_all - total of projected density
of states of virtual down states
### Point Charge Analysis
The MULLIKEN option can be used to generate derived atomic point charges
from a plane-wave density. This analysis is based on a strategy
suggested in the work of P.E. Blochl, J. Chem. Phys. vol. 103, page 7422
(1995). In this strategy the low-frequency components a plane-wave
density are fit to a linear combination of atom centered Gaussian
functions.
The following SET directives are used to define the
fitting.
```
set nwpw_APC:Gc # specifies the maximum frequency component of the density to be used in the fitting in units of au.
set nwpw_APC:nga # specifies the the number of Gaussian functions per atom.
set nwpw_APC:gamma # specifies the decay lengths of each atom centered Gaussian.
```
We suggest using the following parameters.
```
set nwpw_APC:Gc 2.5
set nwpw_APC:nga 3
set nwpw_APC:gamma 0.6 0.9 1.35
```
### PSPW_DPLOT: Generate Gaussian Cube Files
The pspw dplot task is used to generate plots of various types of
electron densities (or orbitals) of a molecule. The electron density is
calculated on the specified set of grid points from a PSPW calculation.
The output file generated is in the Gaussian Cube format. Input to the
DPLOT task is contained within the DPLOT sub-block.
```
NWPW
...
DPLOT
...
END
...
END
```
To run a DPLOT calculation the following directive is used:
`TASK PSPW PSPW_DPLOT`
Listed below is the format of a DPLOT
sub-block.
```
NWPW
...
DPLOT
VECTORS
DENSITY [total||diff||alpha||beta||laplacian||potential default total]
ELF [restricted|alpha|beta]
ORBITAL
[LIMITXYZ [units ]
]
NCELL
POSITION_TOLERANCE
END
...
END
```
The following list describes the input for the DPLOT sub-block.
```
VECTORS
```
This sub-directive specifies the name of the molecular orbital file. If
the second file is optionally given the density is computed as the
difference between the corresponding electron densities. The vector
files have to
match.
```
DENSITY [total||difference||alpha||beta||laplacian||potential default total]
```
This sub-directive specifies, what kind of density is to be plotted. The
known names for total, difference, alpha, beta, laplacian, and
potential.
```
ELF [restricted|alpha|beta]
```
This sub-directive specifies that an electron localization function
(ELF) is to be
plotted.
```
ORBITAL
```
This sub-directive specifies the molecular orbital number that is to be
plotted.
```
LIMITXYZ [units ]
```
By default the grid spacing and the limits of the cell to be plotted are
defined by the input wavefunctions. Alternatively the user can use the
LIMITXYZ sub-directive to specify other limits. The grid is generated
using No_Of_Spacings + 1 points along each direction. The known names
for Units are angstroms, au and bohr.
## Band Tasks: Multiple k-point Calculations
All input to the Band Tasks is contained within the compound NWPW block,
```
NWPW
...
END
```
To perform an actual calculation a Task Band directive is used (Section
[Task](TASK)).
`Task Band`
Once a user has specified a geometry, the Band module can be invoked
with no input directives (defaults invoked throughout). There are
sub-directives which allow for customized application; those currently
provided as options for the Band module
are:
```
NWPW
CELL_NAME
ZONE_NAME
INPUT_WAVEFUNCTION_FILENAME
OUTPUT_WAVEFUNCTION_FILENAME
FAKE_MASS
TIME_STEP
LOOP
TOLERANCES
CUTOFF
ENERGY_CUTOFF
WAVEFUNCTION_CUTOFF
EWALD_NCUT ]
EWALD_RCUT
XC (Vosko || LDA || PBE96 || revPBE || PBEsol || `
|| HSE || default Vosko) `
#Note that HSE is the only hybrid functional implemented in BAND
DFT||ODFT||RESTRICTED||UNRESTRICTED
MULT
CG
LMBFGS
SCF [Anderson|| simple || Broyden]
[CG || RMM-DIIS] [density || potential]
[ALPHA real alpha default 0.25]
[ITERATIONS integer inner_iterations default 5]
[OUTER_ITERATIONS integer outer_iterations default 0]
SIMULATION_CELL [units ]
... (see input description)
END
BRILLOUIN_ZONE
... (see input description)
END
MONKHORST-PACK
BAND_DPLOT
... (see input description)
END
MAPPING
SMEAR
[TEMPERATURE ]
[FERMI || GAUSSIAN || MARZARI-VANDERBILT default FERMI]
[ORBITALS ]
END
```
The following list describes these keywords.
- `cell_name` - name of the simulation_cell named `cell_name`. See
[Simulation Cell](#simulation-cell).
- `input_wavefunctions` - name of the file containing one-electron
orbitals
- `output_wavefunctions` - name that will point to file containing the
one-electron orbitals at the end of the run.
- `fake_mass` - value for the electronic fake mass $\mu$. This
parameter is not presently used in a conjugate gradient simulation
- `time_step` - value for the time step $\Delta t$. This parameter
is not presently used in a conjugate gradient simulation.
- `inner_iteration` - number of iterations between the printing out of
energies and tolerances
- `outer_iteration` - number of outer iterations
- `tole` - value for the energy tolerance.
- `tolc` - value for the one-electron orbital tolerance.
- `cutoff` - value for the cutoff energy used to define the
wavefunction. In addition using the CUTOFF keyword automatically
sets the cutoff energy for the density to be twice the wavefunction
cutoff.
- `ecut` - value for the cutoff energy used to define the density.
Default is set to be the maximum value that will fit within the
simulation_cell `cell_name`.
- `wcut` - value for the cutoff energy used to define the one-electron
orbitals. Default is set to be the maximum value that will fix
within the simulation_cell `cell_name`.
- `ncut` - value for the number of unit cells to sum over (in each
direction) for the real space part of the Ewald summation. Note
Ewald summation is only used if the simulation_cell is periodic.
- `rcut` - value for the cutoff radius used in the Ewald summation.
Note Ewald summation is only used if the simulation_cell is
periodic.
Default set to be $\frac{MIN(\left| \vec{a_i} \right|)}{\pi}, i=1,2,3$.
- (Vosko || PBE96 || revPBE) - Choose between Vosko et al's LDA
parameterization or the orginal and revised Perdew, Burke, and
Ernzerhof GGA functional.
- SIMULATION_CELL (see section -sec:pspw_cell-)
- BRILLOUIN_ZONE (see section -sec:band_brillouin_zone-)
- MONKHORST-PACK - Alternatively, the MONKHORST-PACK keyword can be
used to enter a MONKHORST-PACK sampling of the Brillouin zone.
- `smear` - value for smearing broadending
- `temperature` - same as smear but in units of K.
- CG - optional keyword which sets the minimizer to 1
- LMBFGS - optional keyword which sets the minimizer to 2
- SCF - optional keyword which sets the minimizer to be a band by band
minimizer. Several options are available for setting the density or
potential mixing, and the type of Kohn-Sham minimizer.
### Brillouin Zone
To supply the special points of the Brillouin zone, the user defines a
brillouin_zone sub-block within the NWPW block. Listed below is the
format of a brillouin_zone
sub-block.
```
NWPW
...
BRILLOUIN_ZONE
ZONE_NAME
(KVECTOR
...)
END
...
END
```
The user enters the special points and weights of the Brillouin zone.
The following list describes the input in detail.
- `name` - user-supplied name for the simulation block.
- `k1 k2 k3` - user-supplied values for a special point in the
Brillouin zone.
- `weight` - user-supplied weight. Default is to set the weight so
that the sum of all the weights for the entered special points adds
up to unity.
#### Band Structure Paths
SC: gamma, m, r, x
FCC: gamma, k, l, u, w, x
BCC: gamma, h, n, p
Rhombohedral: not currently implemented
Hexagonal: gamma, a, h, k, l, m
Simple Tetragonal: gamma, a, m, r, x, z
Simple Orthorhombic: gamma, r, s, t, u, x, y, z
Body-Centered Tetragonal: gamma, m, n, p, x
#### Special Points of Different Space Groups (Conventional Cells)
(1) P1
(2) P-1
(3)
### Screened Exchange
### Density of States and Projected Density of States
The "dos" option is used to calculate density of states using broadening
of the eigenvalues . This option can be specified without additional
parameters, i.e.
```
nwpw
dos
end
```
in which case default values are used, or it can be specified with
additional parameters, e.g.
```
nwpw
dos 0.002 700 -0.80000 0.8000
end
```
The parameters are
```
nwpw
dos [ ]
end
```
where
- `alpha` - value for the broadening the eigenvalues, default
0.05/27.2116 au
- `npoints` - number of plotting points in dos files, default 500
- `emin` - minimum energy in dos plots, default min(eigenvalues)-0.1
au
- `emax` - maximimum energy in dos plots, default max(eigenvalues)+0.1
au
The units for dos parameters are in atomic units. Note that if virtual
states are specified in the pspw calculation then the virtual density of
states will also be generated in addition to the filled density of
states.
The following files are generated and written to the permanent_dir for
restricted calculations
- file_prefix.smear_dos_both - total density of states
- file_prefix.smear_fdos_both - density of states of filled states
- file_prefix.smear_vdos_both - density of states of virtual states
For unrestricted calculations
- file_prefix.smear_dos_alpha - total density of states for up
electrons
- file_prefix.smear_dos_beta - total density of states for down
electrons
- file_prefix.smear_fdos_alpha - density of states for filled up
electrons
- file_prefix.smear_fdos_beta - density of states for filled down
electrons
- file_prefix.smear_vdos_alpha - density of states for virtual up
electrons
- file_prefix.smear_vdos_beta - density of states for virtual down
electrons
The nwpw:dos:actlist variable is used to specify the atoms used to
determine weights for dos generation. If the variable is not set then
all the atoms are used, e.g.
`set nwpw:dos:actlist 1 2 3 4`
For projected density of states the "Mulliken" keyword needs to be set,
e.g.
```
nwpw
Mulliken
dos
end
```
The following additional files are generated and written to the
permanent_dir for restricted calculations
- file_prefix.mulliken_dos_both_s - total s projected density of
restricted states
- file_prefix.mulliken_fdos_both_s - s projected density of states
of filled restricted states
- file_prefix.mulliken_vdos_both_s - s projected density of states
of virtual restricted states
- file_prefix.mulliken_dos_both_p - total p projected density of
states
- file_prefix.mulliken_fdos_both_p - p projected density of states
of filled states
- file_prefix.mulliken_vdos_both_p - p projected density of states
of virtual states
...
- file_prefix.mulliken_dos_both_all - total of projected density
of filled and virtual restricted states
- file_prefix.mulliken_fdos_both_all - total of projected density
of filled restricted states
- file_prefix.mulliken_vdos_both_all - total of projected density
of states of virtual restricted states
Similarly for unrestricted calculations
- file_prefix.mulliken_dos_alpha_s - total s projected density of
up states
- file_prefix.mulliken_fdos_alpha_s - s projected density of
states of filled up states
- file_prefix.mulliken_vdos_alpha_s - s projected density of
states of virtual up states
- file_prefix.mulliken_dos_alpha_p - total p projected density of
up states
- file_prefix.mulliken_fdos_alpha_p - p projected density of
states of filled up states
- file_prefix.mulliken_vdos_alpha_p - p projected density of
states of virtual up states
...
- file_prefix.mulliken_dos_alpha_all - total of projected density
of filled up states
- file_prefix.mulliken_fdos_alpha_all - total of projected density
of filled up states
- file_prefix.mulliken_vdos_alpha_all - total of projected density
of states of virtual up states
...
- file_prefix.mulliken_dos_beta_s - total s projected density of
down states
- file_prefix.mulliken_fdos_beta_s - s projected density of states
of filled down states
- file_prefix.mulliken_vdos_beta_s - s projected density of states
of virtual down states
- file_prefix.mulliken_dos_beta_p - total p projected density of
down states
- file_prefix.mulliken_fdos_beta_p - p projected density of states
of filled down states
- file_prefix.mulliken_vdos_beta_p - p projected density of states
of virtual down states
...
- file_prefix.mulliken_dos_beta_all - total of projected density
of filled down states
- file_prefix.mulliken_fdos_beta_all - total of projected density
of filled down states
- file_prefix.mulliken_vdos_beta_all - total of projected density
of states of virtual down states
### Two-Component Wavefunctions (Spin-Orbit ZORA)
### BAND_DPLOT: Generate Gaussian Cube Files
The BAND BAND_DPLOT task is used to generate plots of various types of
electron densities (or orbitals) of a crystal. The electron density is
calculated on the specified set of grid points from a Band calculation.
The output file generated is in the Gaussian Cube format. Input to the
BAND_DPLOT task is contained within the BAND_DPLOT sub-block.
```
NWPW
...
BAND_DPLOT
...
END
...
END
```
To run a BAND_DPLOT calculation the following directive is used:
`TASK BAND BAND_DPLOT`
Listed below is the format of a BAND_DPLOT
sub-block.
```
NWPW
...
BAND_DPLOT
VECTORS
DENSITY [total||difference||alpha||beta||laplacian||potential default total]
ELF [restricted|alpha|beta]
ORBITAL (density || real || complex default density)
[LIMITXYZ [units ]
]
END
...
END
```
The following list describes the input for the BAND_DPLOT sub-block.
`VECTORS `
This sub-directive specifies the name of the molecular orbital file. If
the second file is optionally given the density is computed as the
difference between the corresponding electron densities. The vector
files have to
match.
```
DENSITY [total||difference||alpha||beta||laplacian||potential default total]
```
This sub-directive specifies, what kind of density is to be plotted. The
known names for total, difference, alpha, beta, laplacian, and
potential.
```
ELF [restricted|alpha|beta]
```
This sub-directive specifies that an electron localization function
(ELF) is to be
plotted.
```
ORBITAL (density || real || complex default density)
```
This sub-directive specifies the molecular orbital number that is to be
plotted.
```
LIMITXYZ [units ]
```
By default the grid spacing and the limits of the cell to be plotted are
defined by the input wavefunctions. Alternatively the user can use the
LIMITXYZ sub-directive to specify other limits. The grid is generated
using No_Of_Spacings + 1 points along each direction. The known names
for Units are angstroms, au and bohr.
## Car-Parrinello
The Car-Parrinello task is used to perform ab initio molecular dynamics
using the scheme developed by Car and Parrinello. In this unified ab
initio molecular dynamics scheme the motion of the ion cores is coupled
to a fictitious motion for the Kohn-Sham orbitals of density functional
theory. Constant energy or constant temperature simulations can be
performed. A detailed description of this method is described in section
[Car-Parrinello Scheme for Ab Initio Molecular
Dynamics](#car-parrinello-scheme-for-ab-initio-molecular-dynamics).
Input to the Car-Parrinello simulation is contained within the
Car-Parrinello sub-block.
```
NWPW
...
Car-Parrinello
...
END
...
END
```
To run a Car-Parrinello calculation the following directives are used:
```
TASK PSPW Car-Parrinello
TASK BAND Car-Parrinello
TASK PAW Car-Parrinello
```
The Car-Parrinello sub-block contains a great deal of input, including
pointers to data, as well as parameter input. Listed below is the format
of a Car-Parrinello
sub-block.
```
NWPW
...
Car-Parrinello
CELL_NAME
INPUT_WAVEFUNCTION_FILENAME
OUTPUT_WAVEFUNCTION_FILENAME
INPUT_V_WAVEFUNCTION_FILENAME
OUTPUT_V_WAVEFUNCTION_FILENAME
FAKE_MASS
TIME_STEP
LOOP
SCALING
ENERGY_CUTOFF
WAVEFUNCTION_CUTOFF
EWALD_NCUT
EWALD_RCUT
XC (Vosko || LDA || PBE96 || revPBE || HF ||
LDA-SIC || LDA-SIC/2 || LDA-0.4SIC || LDA-SIC/4 || LDA-0.2SIC ||
PBE96-SIC || PBE96-SIC/2 || PBE96-0.4SIC || PBE96-SIC/4 || PBE96-0.2SIC ||
revPBE-SIC || revPBE-SIC/2 || revPBE-0.4SIC || revPBE-SIC/4 || revPBE-0.2SIC ||
PBE0 || revPBE0 || default Vosko)
[Nose-Hoover ]
[TEMPERATURE ]
[SA_decay ]
XYZ_FILENAME
ION_MOTION_FILENAME
HMOTION_FILENAME
OMOTION_FILENAME
EIGMOTION_FILENAME
END
...
END
```
The following list describes the input for the Car-Parrinello sub-block.
- `cell_name` - name of the the simulation_cell named `cell_name`.
See section [Simulation Cell](#simulation-cell).
- `input_wavefunctions` - name of the file containing one-electron
orbitals
- `output_wavefunctions` - name of the file that will contain the
one-electron orbitals at the end of the run.
- `input_v_wavefunctions` - name of the file containing one-electron
orbital velocities.
- `output_v_wavefunctions` - name of the file that will contain the
one-electron orbital velocities at the end of the run.
- `fake_mass` - value for the electronic fake mass ($\mu$ ).
- `time_step` - value for the Verlet integration time step
($Delta t$).
- `inner_iteration` - number of iterations between the printing out of
energies.
- `outer_iteration` - number of outer iterations
- `scale_c` - value for the initial velocity scaling of the
one-electron orbital velocities.
- `scale_r` - value for the initial velocity scaling of the ion
velocities.
- `ecut` - value for the cutoff energy used to define the density.
Default is set to be the maximum value that will fit within the
simulation_cell `cell_name`.
- `wcut` - value for the cutoff energy used to define the one-electron
orbitals. Default is set to be the maximum value that will fit
within the simulation_cell `cell_name`.
- `ncut` - value for the number of unit cells to sum over (in each
direction) for the real space part of the Ewald summation. Note
Ewald summation is only used if the simulation_cell is periodic.
- `rcut` - value for the cutoff radius used in the Ewald summation.
Note Ewald summation is only used if the simulation_cell is
periodic.
Default set to be $\frac{MIN(\left| \vec{a_i} \right|)}{\pi}, i=1,2,3$.
- (Vosko || PBE96 || revPBE || ...) - Choose between Vosko et al's LDA
parameterization or the orginal and revised Perdew, Burke, and
Ernzerhof GGA functional. In addition, several hybrid options.
- Nose-Hoover or Temperature - optional subblock which if specified
causes the simulation to perform Nose-Hoover dynamics. If this
subblock is not specified the simulation performs constant energy
dynamics. See section -sec:pspw_nose- for a description of the
parameters. Note that the Temperature subblock is just a reordering
of the Nose-Hoover subblock.
- `Period_electron` $\equiv P_{electron}$ - estimated period for
fictitious electron thermostat.
- `Temperature_electron` $\equiv T_{electron}$ - temperature for
fictitious electron motion
- `Period_ion` $\equiv P_{ion}$ - estimated period for ionic
thermostat
- `Temperature_ion` $\equiv T_{ion}$ - temperature for ion
motion
- `Chainlength_electron` - number of electron thermostat chains
- `Chainlength_ion` - number of ion thermostat chains
- SA_decay - optional subblock which if specified causes the
simulation to run a simulated annealing simulation. For simulated
annealing to work the Nose-Hoover subblock needs to be specified.
The initial temperature are taken from the Nose-Hoover subblock. See
section -sec:pspw_nose- for a description of the parameters.
- `sa_scale_c` $\equiv \tau_{electron}$ - decay rate in atomic
units for electronic temperature.
- `sa_scale_r` $\equiv \tau_{ionic}$ - decay rate in atomic
units for the ionic temperature.
- `xyz_filename` - name of the XYZ motion file generated
- `emotion_filename` - name of the emotion motion file. See section
[EMOTION motion file](#emotion-motion-file) for a
description of the datafile.
- `hmotion_filenameh` - name of the hmotion motion file. See section
[HMOTION motion file](#hmotion-motion-file) for a
description of the datafile.
- `eigmotion_filename` - name of the eigmotion motion file. See
section [EIGMOTION motion file](#eigmotion-motion-file)
for a description of the datafile.
- `ion_motion_filename` - name of the ion_motion motion file. See
section [ION_MOTION motion file](#ion_motion-motion-file)- for a description of the
datafile.
- MULLIKEN - optional keyword which if specified causes an omotion
motion file to be created.
- `omotion_filename` - name of the omotion motion file. See section
[OMOTION motion file](#omotion-motion-file) for a description of
the datafile.
When a DPLOT sub-block is specified the following SET directive can be
used to output dplot data during a PSPW Car-Parrinello simulation:
```
set pspw_dplot:iteration_list
```
The Gaussian cube files specified in the DPLOT sub-block are appended
with the specified iteration number.
For example, the following directive specifies that at the
3,10,11,12,13,14,15, and 50 iterations Gaussian cube files are to be
produced.
`set pspw_dplot:iteration_list 3,10:15,50`
### Adding Geometry Constraints to a Car-Parrinello Simulation
The Car-Parrinello module allows users to freeze the cartesian
coordinates in a simulation (Note - the Car-Parrinello code recognizes
Cartesian constraints, but it does not recognize internal coordinate
constraints). The +SET+ directive (Section [Applying constraints in
geometry
optimizations](ZCOORD-Forcing-internal-coordinates#applying-constraints-in-geometry-optimizations))
is used to freeze atoms, by specifying a directive of the form:
```
set geometry:actlist
```
This defines only the centers in the list as active. All other centers
will have zero force assigned to them, and will remain frozen at their
starting coordinates during a Car-Parrinello simulation.
For example, the following directive specifies that atoms numbered 1, 5,
6, 7, 8, and 15 are active and all other atoms are frozen:
`set geometry:actlist 1 5:8 15`
or equivalently,
`set geometry:actlist 1 5 6 7 8 15`
If this option is not specified by entering a +SET+ directive, the
default behavior in the code is to treat all atoms as active. To revert
to this default behavior after the option to define frozen atoms has
been invoked, the +UNSET+ directive must be used (since the database is
persistent, see Section [NWChem Architecture](NWChem-Architecture)).
The form of the +UNSET+ directive is as follows:
`unset geometry:actlist`
In addition, the Car-Parrinello module allows users to freeze bond
lengths via a Shake algorithm. The following +SET+ directive shows how
to do this.
`set nwpw:shake_constraint "2 6 L 6.9334"`
This input fixes the bond length between atoms 2 and 6 to be 6.9334
bohrs. Note that this input only recognizes bohrs.
When using constraints it is usually necessary to turn off center of
mass shifting. This can be done by the following +SET+ directive.
`set nwpw:com_shift .false.`
### Car-Parrinello Output Datafiles
#### XYZ motion file
Data file that stores ion positions and velocities as a function of time
in XYZ
format.
```
[line 1: ] n_ion
[line 2: ] do ii=1,n_ion
[line 2+ii: ] atom_name(ii), x(ii),y(ii),z(ii),vx(ii),vy(ii),vz(ii)
end do
[line n_ion+3 ] n_nion
do ii=1,n_ion
[line n_ion+3+ii: ] atom_name(ii), x(ii),y(ii),z(ii), vx(ii),vy(ii),vz(ii)
end do
[line 2*n_ion+4: ] ....
```
#### ION_MOTION motion file
Datafile that stores ion positions and velocities as a function of
time
```
[line 1: ] it_out, n_ion, omega, a1.x,a1.y,a1.z, a2.x,a2,y,a2.z, a3.x,a3.y,a3.z
[line 2: ] time
do ii=1,n_ion
[line 2+ii: ] ii, atom_symbol(ii),atom_name(ii), x(ii),y(ii),z(ii), vx(ii),vy(ii),vz(ii)
end do
[line n_ion+3 ] time
do do ii=1,n_ion
[line n_ion+3+ii: ] ii, atom_symbol(ii),atom_name(ii), x(ii),y(ii),z(ii), vx(ii),vy(ii),vz(ii)
end do
[line 2*n_ion+4: ] ....
```
#### EMOTION motion file
Datafile that store energies as a function of
time.
```
[line 1: ] time, E1,E2,E3,E4,E5,E6,E7,E8,(E9,E10, if Nose-Hoover),eave,evar,have,hvar,ion_Temp
[line 2: ] ...
```
where
```
E1 = total energy
E2 = potential energy
E3 = ficticious kinetic energy
E4 = ionic kinetic energy
E5 = orbital energy
E6 = hartree energy
E7 = exchange-correlation energy
E8 = ionic energy
eave = average potential energy
evar = variance of potential energy
have = average total energy
hvar = variance of total energy
ion_Temp = temperature
```
#### HMOTION motion file
Datafile that stores the rotation matrix as a function of time.
```
[line 1: ] time
[line 2: ] ms,ne(ms),ne(ms)
do i=1,ne(ms)
[line 2+i: ] (hml(i,j), j=1,ne(ms)
end do
[line 3+ne(ms): ] time
[line 4+ne(ms): ] ....
```
#### EIGMOTION motion file
Datafile that stores the eigenvalues for the one-electron orbitals as a
function of time.
```
[line 1: ] time, (eig(i), i=1,number_orbitals)
[line 2: ] ...
```
#### OMOTION motion file
Datafile that stores a reduced representation of the one-electron
orbitals. To be used with a molecular orbital viewer that will be ported
to NWChem in the near future.
## Born-Oppenheimer Molecular Dynamics
```
NWPW
...
BO_STEPS
BO_TIME_STEP
BO_ALGORITHM [verlet|| velocity-verlet || leap-frog]
BO_FAKE_MASS
END
```
## i-PI Socket Communication
```
NWPW
SOCKET (UNIX || IPI_CLIENT)
END
```
The `NWPW` module provides native communication via the i-PI socket protocol.
The behavior is identical to the
[i-PI socket communication](Geometry-Optimization#i-pi-socket-communication)
provided by the `DRIVER` module.
The `NWPW` implementation of the `SOCKET` directive is better optimized for
plane-wave calculations.
For proper behavior, the `TASK` directive should be set to `GRADIENT`,
e.g. `TASK PSPW GRADIENT` or `TASK BAND GRADIENT`.
## Metropolis Monte-Carlo
```
NWPW
...
MC_STEPS
END
```
## Free Energy Simulations
### MetaDynamics

. Courtesy of Raymond Atta-Fynn](ray.gif "Metadynamics simulation of the first hydrolysis of U(IV) from 1. Courtesy of Raymond Atta-Fynn")
Metadynamics[2](http://en.wikipedia.org/wiki/Metadynamics)[3](http://iopscience.iop.org/0034-4885/71/12/126601)[4](http://people.sissa.it/~laio/Research/Res_metadynamics.php)
is a powerful, non-equilibrium molecular dynamics method which
accelerates the sampling of the multidimensional free energy surfaces of
chemical reactions. This is achieved by adding an external
time-dependent bias potential that is a function of user defined
collective variables, $\mathbf{s}$. The bias potential discourages the
system from sampling previously visited values of $\mathbf{s}$ (i.e.,
encourages the system to explore new values of $\mathbf{s}$. During the
simulation the bias potential accumulates in low energy wells which then
allows the system to cross energy barriers much more quickly than would
occur in standard dynamics. The collective variable $\mathbf{s}$ is a
generic function of the system coordinates, $\mathbf{R}$ (e.g. bond
distance, bond angle, coordination numbers, etc.) that is capable of
describing the chemical reaction of interest.
$\mathbf{s}\left(\mathbf{R}\right)$ can be regarded as a reaction
coordinate if it can distinguish between the reactant, transition, and
products states, and also capture the kinetics of the reaction.
The biasing is achieved by “flooding” the energy landscape with
repulsive Gaussian “hills” centered on the current location of
$\mathbf{s}\left(\mathbf{R}\right)$ at a constant time interval
$\Delta t$. If the height of the Gaussians is constant in time then we
have standard metadynamics; if the heights vary (slowly decreased) over
time then we have well-tempered metadynamics. In between the addition of
Gaussians, the system is propagated by normal (but out of equilibrium)
dynamics. Suppose that the dimension of the collective space is $d$,
i.e.
$\mathbf{s}\left(\mathbf{R}\right)=\bigl[s_1\left(\mathbf{R}\right),s_2\left(\mathbf{R}\right),\ldots,s_d\left(\mathbf{R}\right)\bigr]$
and that prior to any time $t$ during the simulation, $N +1$
Gaussians centered on
$\mathbf{S}^{t_g}$
are deposited along the
trajectory of $\mathbf{s}\left(\mathbf{R}\right)$ at times
$t_g = 0, \Delta t, 2\Delta t, \ldots ,N\Delta t$. Then, the value of
the bias potential, $V$, at an arbitrary point,
$\mathbf{s}\left(\mathbf{R}\right)=\bigl[s_1\left(\mathbf{R}\right),s_2\left(\mathbf{R}\right),\ldots,s_d\left(\mathbf{R}\right)\bigr]$,
along the trajectory of $\mathbf{s}\left(\mathbf{R}\right)$ at time $t$
is given
by
$$V_{meta}\left(\pmb{s},t\right) = \sum_{t_g=0}^{t_g<} W(t) \exp\left(-\sum_{i=1}^{d}\frac{({s_i}-{s_i}^{t_g})^2}{2\sigma_i^2}\right)$$
where
$W(t)=W_0 \exp\left(-\frac{V_{meta}\left(\mathbf{s},t-\Delta t\right)}{k_B T_{tempered}}\right)$
is the time-dependent Gaussian height. $\sigma_i \,(i=1,2,\ldots,d)$
and $W_0$ are width and initial height respectively of Gaussians, and
$T_{tempered}$
is the tempered metadynamics temperature.
$T_{tempered}=0$
corresponds to standard molecular dynamics because
$W(t)=0$
and therfore there is no bias. $T_{tempered}=\infty$
corresponds to standard metadynamics since in this case
$W(t)=W_0$=constant. A positive, finite value of $T_{tempered}$ (eg.
$T_{tempered}$ >=1500 K) corresponds to *well-tempered* metadynamics in which $0 < W(t)<= W_0$.
For sufficiently large $t$, the history potential
$V_{meta}\left(\mathbf{s},t\right)$ will nearly flatten the free energy
surface, $F(\mathbf{s})$, along $\mathbf{S}$ and an unbiased estimator
of F(s) is given by
$$F(\mathbf{s}) = -\left(1+\frac{T}{T_{tempered}}\right)\lim_{t \to \infty} V_{meta}(\mathbf{s},t)$$
#### Input
Input to a metadynamics simulation is contained within the METADYNAMICS
sub-block. Listed below is the the format of a METADYNAMICS
sub-block,
```
NWPW
METADYNAMICS
[
BOND
[W ]
[SIGMA ]
[RANGE ]
[NRANGE ]
...]
[
ANGLE
[W ]
[SIGMA ]
[RANGE ]
...]
[
COORD_NUMBER [INDEX1 ][INDEX2 ]
[SPRIK]
[N ]
[M ]
[R0 ]
[W ]
[SIGMA ]
[RANGE ]
[NRANGE ]
...]
[
N-PLANE
[W ]
[SIGMA ]
[RANGE ]
[NRANGE ]
[NVECTOR ]
...]
[UPDATE ]
[PRINT_SHIFT ]
[TEMPERED ]
[BOUNDARY ]
END
END
```
Multiple collective variables can be defined at the same time, e.g.
```
NWPW
METADYNAMICS
BOND 1 8 W 0.0005 SIGMA 0.1
BOND 1 15 W 0.0005 SIGMA 0.1
END
END
```
will produce a two-dimensional potential energy surface.
### TAMD - Temperature Accelerated Molecular Dynamics
#### Input
### Collective Variables
#### Bond Distance Collective Variable
This describes the bond distance between any pair of atoms $i$ and
$j$:
$$s\left(r_{ij}\right) = \left \vert \mathbf{r}_{i}-\mathbf{r}_j\right\vert = r_{ij}$$
#### Angle Collective Variable
This describes the bond angle formed at $i$ by the triplet $$
$$s\left(r_{ij},r_{ik}\right) = \frac{\pmb{r}_{ij}\cdot\pmb{r}_{ik}}{r_{ij}r_{ik}}$$
#### Coordination Collective Variable
The coordination number collective variable is defined as
$$s\left(r_{ij},r_{0}\right) =\sum_{i,j}\xi_{ij}$$
where the summation over $i$ and $j$ runs over two types of atoms,
$\xi_{ij}$ is the *weighting function*, and $r_{0}$ is the cut-off
distance.
In the standard procedure for computing the coordination
number, $\xi_{ij}$ =1 if $r_{ij} < r_0$, otherwise
$\xi_{ij}$ =0,
implying that $\xi_{ij}$ is not continuous when
$r_{ij}=r_{0}$. To
ensure a smooth and continuous definition of the coordination number, we
adopt two variants of the weighting function. The first variant
is
$$\xi_{ij} = \frac{1-\left(r_{ij}/r_{0}\right)^n}{1-\left(r_{ij}/r_{0}\right)^m}$$
where $n$ and $m$ are integers (m > n) chosen such that
$\xi_{ij}\approx 1$ when $r_{ij} < r_0$ and
$\xi_{ij}\rightarrow 0$ when $r_{ij}$ is much larger than $r_{0}$.
For example, the parameters of the O-H coordination in water is well
described by $r_{0}$ =1.6 Å,
$n=6$
and $m=18$.
In practice, $n$
and $m$ must tuned for a given $r_{0}$ to ensure that $\xi_{ij}$
is smooth and satisfies the above mentioned properties, particularly the
large $r_{ij}$
The second form of the weighting function, which is due to Sprik, is
$$\xi_{ij}=\frac{1}{1 + \exp\left[n\left(r_{ij}-r_{0}\right)\right]}$$
In this definition $\xi_{ij}$ is analogous to the Fermi function and
its width is controlled by the parameter $\frac{1}{n}$. Large and
small values of $n$ respectively correspond to sharp and soft
transitions at $r_{ij} = r_{0}$.
Furthermore $\xi_{ij}$ should
approach 1 and 0 when $r_{ij} < 0$
and $r_{ij} < r_0 $
respectively. In practice $n$ =6-10 Å $^{-1}$.
For example, a good set
of parameters of the O-H coordination in water is $r_{0}$ =1.4 Å and
$n$ =10 Å $^{-1}$.
#### N-Plane Collective Variable
The N-Plane collective variable is useful for probing the adsorption of
adatom/admolecules to a surface. It is defined as the *average distance*
of the adatom/admolecule from a given layer in the slab along the
surface normal:
$$s = Z_{ads}-\frac{1}{N_{plane}}\sum_{i=1}^{N_{plane}}Z_i$$
where $Z_{ads}$ denotes the position of the adatom/admolecule/impurity
along the surface normal (here, we assume the surface normal to be the
z-axis) and the summation over
$i$
runs over
$N_{plane}$
atoms at
$Z_i$ which form the layer. The layer could be on the face or in the
interior of the
slab.
#### User defined Collective Variable
## Extended X-Ray Absorption Fine Structure (EXAFS) - Integration with FEFF6L
## Frozen Phonon Calculations
## Steepest Descent
The functionality of this task is now performed automatically by the
PSPW and BAND. For backward compatibility, we provide a description of
the input to this task.
The steepest_descent task is used to optimize the one-electron orbitals
with respect to the total energy. In addition it can also be used to
optimize geometries. This method is meant to be used for coarse
optimization of the one-electron orbitals.
Input to the steepest_descent simulation is contained within the
steepest_descent sub-block.
```
NWPW
...
STEEPEST_DESCENT
...
END
...
END
```
To run a steepest_descent calculation the following directive is used:
```
TASK PSPW steepest_descent
TASK BAND steepest_descent
```
The steepest_descent sub-block contains a great deal of input,
including pointers to data, as well as parameter input. Listed below is
the format of a STEEPEST_DESCENT
sub-block.
```
NWPW
...
STEEPEST_DESCENT
CELL_NAME
[GEOMETRY_OPTIMIZE]
INPUT_WAVEFUNCTION_FILENAME
OUTPUT_WAVEFUNCTION_FILENAME
FAKE_MASS
TIME_STEP
LOOP
TOLERANCES
ENERGY_CUTOFF
WAVEFUNCTION_CUTOFF
EWALD_NCUT
EWALD_RCUT
XC (Vosko || LDA || PBE96 || revPBE || HF ||
LDA-SIC || LDA-SIC/2 || LDA-0.4SIC || LDA-SIC/4 || LDA-0.2SIC ||
PBE96-SIC || PBE96-SIC/2 || PBE96-0.4SIC || PBE96-SIC/4 || PBE96-0.2SIC ||
revPBE-SIC || revPBE-SIC/2 || revPBE-0.4SIC || revPBE-SIC/4 || revPBE-0.2SIC ||
PBE0 || revPBE0 || default Vosko)
[MULLIKEN]
END
...
END
```
The following list describes the input for the STEEPEST_DESCENT
sub-block.
- `cell_name` - name of the simulation_cell named `cell_name`. See
[Simulation Cell](#simulation-cell).
- GEOMETRY_OPTIMIZE - optional keyword which if specified turns on
geometry optimization.
- `input_wavefunctions` - name of the file containing one-electron
orbitals
- `output_wavefunctions` - name of the file tha will contain the
one-electron orbitals at the end of the run.
- `fake_mass` - value for the electronic fake mass $\mu$
- `time_step` - value for the time step $Delta t$.
- `inner_iteration` - number of iterations between the printing out of
energies and tolerances
- `outer_iteration` - number of outer iterations
- `tole` - value for the energy tolerance.
- `tolc` - value for the one-electron orbital tolerance.
- `tolr` - value for the ion position tolerance.
- `ecut` - value for the cutoff energy used to define the density.
Default is set to be the maximum value that will fit within the
simulation_cell `cell_name`.
- `wcut` - value for the cutoff energy used to define the one-electron
orbitals. Default is set to be the maximum value that will fit
within the simulation_cell `cell_name`.
- `ncut` - value for the number of unit cells to sum over (in each
direction) for the real space part of the Ewald summation. Note
Ewald summation is only used if the simulation_cell is periodic.
- `rcut` - value for the cutoff radius used in the Ewald summation.
Note Ewald summation is only used if the simulation_cell is
periodic.
Default set to be $\frac{MIN(\left| \vec{a_i} \right|)}{\pi}, i=1,2,3$.
- (Vosko || PBE96 || revPBE || ...) - Choose between Vosko et al's LDA
parameterization or the orginal and revised Perdew, Burke, and
Ernzerhof GGA functional. In addition, several hybrid options
(hybrid options are not available in BAND).
- MULLIKEN - optional keyword which if specified causes a Mulliken
analysis to be performed at the end of the simulation.
## Simulation Cell
The simulation cell parameters are entered by defining a
simulation_cell sub-block within the PSPW block. Listed below is the
format of a simulation_cell sub-block.
```
NWPW
...
SIMULATION_CELL [units ]
CELL_NAME
BOUNDARY_CONDITIONS (periodic || aperiodic default periodic)
LATTICE_VECTORS
NGRID
END
...
END
```
Basically, the user needs to enter the dimensions, gridding and boundary
conditions of the simulation cell. The following list describes the
input in detail.
- `name` - user-supplied name for the simulation block.
- periodic - keyword specifying that the simulation cell has periodic
boundary conditions.
- aperiodic - keyword specifying that the simulation cell has
free-space boundary conditions.
- `a1.x a1.y a1.z` - user-supplied values for the first lattice
vector
- `a2.x a2.y a2.z` - user-supplied values for the second lattice
vector
- `a3.x a3.y a3.z` - user-supplied values for the third lattice
vector
- `na1 na2 na3` - user-supplied values for discretization along
lattice vector directions.
Alternatively, instead of explicitly entering lattice vectors, users can
enter the unit cell using the standard cell parameters, a, b, c,
$alpha$,
$\beta$,
and $\gamma$, by using the LATTICE block. The
format for input is as follows:
```
NWPW
...
SIMULATION_CELL [units ]
...
LATTICE
[lat_a ]
[lat_b ]
[lat_c ]
[alpha ]
[beta ]
[gamma ]
END
...
END
...
END
```
The user can also enter the lattice vectors of standard unit cells using
the keywords SC, FCC, BCC, for simple cubic, face-centered cubic, and
body-centered cubic respectively. Listed below is an example of the
format of this type of input.
```
NWPW
...
SIMULATION_CELL [units ]
SC 20.0
....
END
...
END
```
Finally, the lattice vectors from the unit cell can also be defined
using the fractional coordinate input in the GEOMETRY input (see section
[Geometry Lattice
Parameters](SYSTEM----Lattice-parameters-for-periodic-systems)).
Listed below is an example of the format of this type of input for an 8
atom silicon carbide unit cell.
```
geometry units au
system crystal
lat_a 8.277
lat_b 8.277
lat_c 8.277
alpha 90.0
beta 90.0
gamma 90.0
end
Si -0.50000 -0.50000 -0.50000
Si 0.00000 0.00000 -0.50000
Si 0.00000 -0.50000 0.00000
Si -0.50000 0.00000 0.00000
C -0.25000 -0.25000 -0.25000
C 0.25000 0.25000 -0.25000
C 0.25000 -0.25000 0.25000
C -0.25000 0.25000 0.25000
end
```
Warning - Currently only the "system crystal" option is recognized by
NWPW. The "system slab" and "system polymer" options will be supported
in the future.
## Unit Cell Optimization
The PSPW module using the DRIVER geometry optimizer can optimize a
crystal unit cell. Currently this type of optimization works only if the
geometry is specified in fractional coordinates. The following SET
directive is used to tell the DRIVER geometry optimizer to optimize the
crystal unit cell in addition to the geometry.
`set includestress .true.`
## SMEAR - Fractional Occupation of the Molecular Orbitals
The smear keyword to turn on fractional occupation of the molecular
orbitals in PSPW and BAND
calculations
```
SMEAR [TEMPERATURE ]
[FERMI || GAUSSIAN || MARZARI-VANDERBILT default FERMI]
[ORBITALS ]
```
Fermi-Dirac (FERMI), Gaussian, and Marzari-Vanderbilt broadening functions are
available. The ORBITALS keyword is used to change the number of virtual
orbitals to be used in the calculation. Note to use this option the user
must currently use the SCF minimizer. The following SCF options are
recommended for running fractional occupation
`SCF Anderson outer_iterations 0 Kerker 2.0`
## Spin Penalty Functions
Spin-penalty functions makes it easier to define antiferromagnetic
structures. These functions are implemented by adding a scaling factor
to the non-local psp for up/down spins on atoms and angular momentum
that you specify.
Basically, the pseudopotential
energy
$$E_{psp}= \sum_{\sigma=\uparrow,\downarrow} \sum_{i=1}^{n_{elc}^\sigma} \sum_{I=1}^{n_{ions}} \left( <\psi_i^\sigma|V_{local}^{I}|\psi_i^\sigma> + \sum_{l=0}^{l_{max}^I} \sum_{m=-l}^{l} \sum_{n=1}^{n_{max}^I} \sum_{n'=1}^{n_{max}^I} <\psi_i^\sigma|P_{nlm}^I> h_{l,n,n'}^I \right)$$
was modified
to
$$E_{psp}= \sum_{\sigma=\uparrow,\downarrow} \sum_{i=1}^{n_{elc}^\sigma} \sum_{I=1}^{n_{ions}} \left( <\psi_i^\sigma|V_{local}^{I}|\psi_i^\sigma> + \sum_{l=0}^{l_{max}^I} \sum_{m=-l}^{l} \sum_{n=1}^{n_{max}^I} \sum_{n'=1}^{n_{max}^I} \left(1-\delta_{l,l^\sigma} \delta_{I,ionlist^\sigma}(\xi^\sigma-1)\right) <\psi_i^\sigma|P_{nlm}^I> h_{l,n,n'}^I \right)$$
An example input is as follows:
```
title "hematite 10 atoms"
start hema10
memory 1900 mb
permanent_dir ./perm
scratch_dir ./perm
geometry center noautosym noautoz print
system crystal
lat_a 5.42
lat_b 5.42
lat_c 5.42
alpha 55.36
beta 55.36
gamma 55.36
end
Fe 0.355000 0.355000 0.355000
Fe 0.145000 0.145000 0.145000
Fe -0.355000 -0.355000 -0.355000
Fe 0.855000 0.855000 0.855000
O 0.550000 -0.050000 0.250000
O 0.250000 0.550000 -0.050000
O -0.050000 0.250000 0.550000
O -0.550000 0.050000 -0.250000
O -0.250000 -0.550000 0.050000
O 0.050000 -0.250000 -0.550000\
end
nwpw
virtual 8
odft
ewald_rcut 3.0
ewald_ncut 8
xc pbe96
lmbfgs
mult 1
dplot
density diff diff1.cube
end
#spin penalty functions
pspspin up d -1.0 1:2
pspspin down d -1.0 3:4
end
task pspw energy
task pspw pspw_dplot
nwpw
pspspin off
dplot
density diff diff2.cube
end
end
task pspw energy
task pspw pspw_dplot
```
## AIMD/MM (QM/MM)
A QM/MM capability is available that is integrated with PSPW module and
can be used with Car-Parrinello simulations. Currently, the input is not
very robust but it is straightforward. The first step to run a QM/MM
simulations is to define the MM atoms in the geometry block. The MM
atoms must be at the end of the geometry and a carat, " ^ ", must be
appended to the end of the atom name, e.g.
```
geometry units angstrom nocenter noautosym noautoz print xyz
C -0.000283 0.000106 0.000047
Cl -0.868403 1.549888 0.254229
Cl 0.834043 -0.474413 1.517103
Cl -1.175480 -1.275747 -0.460606
Cl 1.209940 0.200235 -1.310743
O^ 0.3226E+01 -0.4419E+01 -0.5952E+01
H^ 0.3193E+01 -0.4836E+01 -0.5043E+01
H^ 0.4167E+01 -0.4428E+01 -0.6289E+01
O^ 0.5318E+01 -0.3334E+01 -0.1220E+01
H^ 0.4978E+01 -0.3040E+01 -0.2113E+01
H^ 0.5654E+01 -0.2540E+01 -0.7127E+00
end
```
Another way to specify the MM atoms is to use the mm_tags option which
appends the atoms with a " ^ ".
```
geometry units angstrom nocenter noautosym noautoz print xyz
C -0.000283 0.000106 0.000047
Cl -0.868403 1.549888 0.254229
Cl 0.834043 -0.474413 1.517103
Cl -1.175480 -1.275747 -0.460606
Cl 1.209940 0.200235 -1.310743
O 0.3226E+01 -0.4419E+01 -0.5952E+01
H 0.3193E+01 -0.4836E+01 -0.5043E+01
H 0.4167E+01 -0.4428E+01 -0.6289E+01
O 0.5318E+01 -0.3334E+01 -0.1220E+01
H 0.4978E+01 -0.3040E+01 -0.2113E+01
H 0.5654E+01 -0.2540E+01 -0.7127E+00
end
NWPW
QMMM
mm_tags 6:11
END
END
```
The option "mm_tags off" can be used to remove the " ^ " from the
atoms, i.e.
```
NWPW
QMMM
mm_tags 6:11 off
END
END
```
Next the pseudopotentials have be defined for the every type of MM atom
contained in the geometry blocks. The following local pseudopotential
suggested by Laio, VandeVondele and Rothlisberger can be automatically
generated.
$$\begin{matrix}V(\vec{r}) = -Z_{ion}\frac{{r_c}^{n_{\sigma}} - r^{n_{\sigma}}}{-sign(Z_{ion})*{r_c}^{n_{\sigma}+1}-r^{n_{\sigma}+1}}\end{matrix}$$
The following input To define this pseudopo the O^ MM atom using the
following input
```
NWPW
QMMM
mm_psp O^ -0.8476 4 0.70
END
END
```
defines the local pseudopotential for the O^ MM atom , where
$Z_{ion}=-0.8476$,
$n_{\sigma}=4$, and $r_c=0.7$. The following
input can be used to define the local pseudopotentials for all the MM
atoms in the geometry block defined above
```
NWPW
QMMM
mm_psp O^ -0.8476 4 0.70
mm_psp H^ 0.4238 4 0.40
END
END
```
Next the Lenard-Jones potentials for the QM and MM atoms need to be
defined. This is done as as follows
```
NWPW
QMMM
lj_ion_parameters C 3.41000000d0 0.10d0
lj_ion_parameters Cl 3.45000000d0 0.16d0
lj_ion_parameters O^ 3.16555789d0 0.15539425d0
END
END
```
Note that the Lenard-Jones potential is not defined for the MM H atoms
in this example. The final step is to define the MM fragments in the
simulation. MM fragments are a set of atoms in which bonds and angle
harmonic potentials are defined, or alternatively shake constraints are
defined. The following input defines the fragments for the two water
molecules in the above
geometry,
```
NWPW
QMMM
fragment spc
size 3 #size of fragment
index_start 6:9:3 #atom index list that defines the start of
# the fragments (start:final:stride)
bond_spring 1 2 0.467307856 1.889726878 #bond i j Kspring r0
bond_spring 1 3 0.467307856 1.889726878 #bond i j Kspring r0
angle_spring 2 1 3 0.07293966 1.910611932 #angle i j k Kspring theta0
end
END
END
```
The fragments can be defined using shake constraints
as
```
NWPW
QMMM
fragment spc
size 3 #size of fragment
index_start 6:9:3 #atom index list that defines the start of
# the fragments (start:final:stride)
shake units angstroms 1 2 3 cyclic 1.0 1.632993125 1.0
end
END
END
```
Alternatively, each water could be defined independently as
follows.
```
NWPW
QMMM
fragment spc1
size 3 #size of fragment
index_start 6 #atom index list that defines the start of
#the fragments
bond_spring 1 2 0.467307856 1.889726878 #bond i j Kspring r0
bond_spring 1 3 0.467307856 1.889726878 #bond i j Kspring r0
angle_spring 2 1 3 0.07293966 1.910611932 #angle i j k Kspring theta0
end
fragment spc2
size 3 #size of fragment
index_start 9 #atom index list that defines the start of
#the fragments
shake units angstroms 1 2 3 cyclic 1.0 1.632993125 1.0
end
END
END
```
## PSP_GENERATOR
A one-dimensional pseudopotential code has been integrated into NWChem.
This code allows the user to modify and develop pseudopotentials.
Currently, only the Hamann and Troullier-Martins norm-conserving
pseudopotentials can be generated. In future releases, the
pseudopotential library (section [Pseudopotential and PAW basis
Libraries](#Pseudopotential_and_PAW_basis_Libraries)) will be
more complete, so that the user will not have explicitly generate
pseudopotentials using this module.
Input to the PSP_GENERATOR task is contained within the PSP_GENERATOR
sub-block.
```
NWPW
...
PSP_GENERATOR
...
END
...
END
```
To run a PSP_GENERATOR calculation the following directive is used:
`TASK PSPW PSP_GENERATOR`
Listed below is the format of a PSP_GENERATOR
sub-block.
```
NWPW
...
PSP_GENERATOR
PSEUDOPOTENTIAL_FILENAME:
ELEMENT:
CHARGE:
MASS_NUMBER:
ATOMIC_FILLING: ( (1||2||...) (s||p||d||f||...) ...)
[CUTOFF: ( (s||p||d||f||g) ...) ]
PSEUDOPOTENTIAL_TYPE: (TROULLIER-MARTINS || HAMANN default HAMANN)
SOLVER_TYPE: (PAULI || SCHRODINGER default PAULI)
EXCHANGE_TYPE: (dirac || PBE96 default DIRAC)
CORRELATION_TYPE: (VOSKO || PBE96 default VOSKO)
[SEMICORE_RADIUS: ]
END
...
END
```
The following list describes the input for the PSP_GENERATOR sub-block.
- `psp_name` - name that points to a.
- `element` - Atomic symbol.
- `charge` - charge of the atom
- `mass` - mass number for the atom
- `ncore` - number of core states
- `nvalence` - number of valence states.
- ATOMIC_FILLING:.....(see below)
- `filling` - occupation of atomic state
- CUTOFF:....(see below)
- `rcore` - value for the semicore radius (see below)
### ATOMIC_FILLING Block
This required block is used to define the reference atom which is used
to define the pseudopotential. After the ATOMIC_FILLING:
line, the core states are listed (one per line), and then the
valence states are listed (one per line). Each state contains two
integer and a value. The first integer specifies the radial quantum
number, $n$, the second integer specifies the angular momentum quantum
number, $l$, and the third value specifies the occupation of the
state.
For example to define a pseudopotential for the Neon atom in the
$1s^2 2s^2 2p^6$ state could have the block
```
ATOMIC_FILLING: 1 2
1 s 2.0 #core state - 1s^2
2 s 2.0 #valence state - 2s^2
2 p 6.0 #valence state - 2p^6
```
for a pseudopotential with a $2s$ and $2p$ valence electrons or the
block
```
ATOMIC_FILLING: 3 0
1 s 2.0 #core state
2 s 2.0 #core state
2 p 6.0 #core state
```
could be used for a pseudopotential with no valence electrons.
### CUTOFF
This optional block specifies the cutoff distances used to match the
all-electron atom to the pseudopotential atom. For Hamann
pseudopotentials $r_{cut}(l)$ defines the distance where the
all-electron potential is matched to the pseudopotential, and for
Troullier-Martins pseudopotentials $r_{cut}(l)$ defines the distance
where the all-electron orbital is matched to the pseudowavefunctions.
Thus the definition of the radii depends on the type of pseudopotential.
The cutoff radii used in Hamann pseudopotentials will be smaller than
the cutoff radii used in Troullier-Martins pseudopotentials.
For example to define a softened Hamann pseudopotential for Carbon would
be
```
ATOMIC_FILLING: 1 2
1 s 2.0
2 s 2.0
2 p 2.0
CUTOFF: 2
s 0.8
p 0.85
d 0.85
```
while a similarly softened Troullier-Marting pseudopotential for Carbon
would be
```
ATOMIC_FILLING: 1 2
1 s 2.0
2 s 2.0
2 p 2.0
CUTOFF: 2
s 1.200
p 1.275
d 1.275
```
### SEMICORE_RADIUS
Specifying the SEMICORE_RADIUS option turns on the semicore correction
approximation proposed by Louie et al (S.G. Louie, S. Froyen, and M.L.
Cohen, Phys. Rev. B, **26**(, 1738, (1982)). This approximation is known
to dramatically improve results for systems containing alkali and
transition metal atoms.
The implementation in the PSPW module defines the semi-core density,
$\rho_{semicore}$, by
using the sixth-order polynomial
$$\rho_{semicore}(r) = \begin{cases} \rho_{core} \mbox{if } r \ge r_{semicore} \\ c_0 + c_3 r^3 + c_4 r^4 + c_5 r^5 + c_6 r^6 \mbox{if } r < r_{semicore} \end{cases}$$
This expansion was suggested by Fuchs and Scheffler (M. Fuchs, and M.
Scheffler, Comp. Phys. Comm.,**119**,67 (1999)), and is better behaved
for taking derivatives (i.e. calculating ionic forces) than the
expansion suggested by Louie et al.
## PAW Tasks: Legacy Implementation
(*This capability is now available in PSPW. It
is recommended that this module only be used for testing purposes.*
)
All input to the PAW Tasks is contained within the compound NWPW block,
```
NWPW
...
END
```
To perform an actual calculation a TASK PAW directive is used
([Task](TASK)).
`TASK PAW`
In addition to the directives listed in [Task](TASK), i.e.
```
TASK paw energy
TASK paw gradient
TASK paw optimize
TASK paw saddle
TASK paw freqencies
TASK paw vib
```
there are additional directives that are specific to the PSPW module,
which are:
`TASK PAW [Car-Parrinello || steepest_descent ]`
Once a user has specified a geometry, the PAW module can be invoked with
no input directives (defaults invoked throughout). There are
sub-directives which allow for customized application; those currently
provided as options for the PAW module
are:
```
NWPW
CELL_NAME
[GEOMETRY_OPTIMIZE]
INPUT_WAVEFUNCTION_FILENAME
OUTPUT_WAVEFUNCTION_FILENAME
FAKE_MASS
TIME_STEP
LOOP
TOLERANCES
CUTOFF