Binary result files
*******************


ams.rkf
=======

The main ams.rkf file is written by the AMS driver. It contains high-
level information about the trajectory that the AMS driver took over
the potential energy surface. Since the AMSification of ADF, some
information that used to be on TAPE21 is now stored in ams.rkf.

This file contains information on geometry optimization, transition
state search, linear transit, PES scan, NEB, or IRC, if that was
requested in the calculation. For a geometry optimization or
transition state search, for example, it contains the history of how
the system's geometry changed during the optimization as well as the
final optimized geometry. The format in which this information is
written is independent of which engine was used for a calculation.

If a property, like vibrational modes, is tied to a special point on
the potential energy surface, it is stored in the engine main output
file adf.rkf.

* See also the AMS manual

  * Section and variables on ams.rkf


adf.rkf (TAPE21)
================

adf.rkf is the general result file of an ADF calculation. In ADF<=2019
it was known as TAPE21. It is a KF file: Direct-Access, binary, and
keyword-driven. It contains information about the calculation. You can
use it as a fragment file in a subsequent calculation on a bigger
molecule, where the current one may be a part, or in an analysis
program. Since the AMSification of ADF, some information that used to
be on TAPE21 is now stored in ams.rkf.

A description of the various utilities that can be used to process
adf.rkf can be found in other parts of this ADF manual.

* Sections and variables on adf.rkf


adf.rkf: Added notes
--------------------


Section Multipole matrix elements
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

This section contains information about a response calculation.

"dipole elements"
   The matrix elements of the 3 dipole operator components between
   occupied and virtual orbitals: outer loop over the operators (in
   order: y, z, x), loop over virtual MOs, inner loop over occupied
   MOs

"quadrupole elements"
   Similar to dipole. Order of operators: \sqrt{3} *xy \sqrt{3} *yz
   z2-(x2+y2)/2 \sqrt{3} *xz \sqrt{3} *(x2-y2)/2

"octupole elements"
   Similar to dipole and quadrupole. Order of operators: \sqrt{10}
   *y*(3*x2-y2)/4 \sqrt{15} *xyz \sqrt{6} *y*(4*z2-x2-y2)/4
   z*(z2-3(x2-y2)/2) \sqrt{6} *x*(4*z2-x2-y2)/4 \sqrt{15} *z*(x2-y2)/2
   \sqrt{10} *x*(x2-3y2)/4

"hexadecapole elements"
   Similar to dipole and quadrupole. Order of operators: \sqrt{35}
   *xy*(x2-y2)/2 \sqrt{70} *z*(3x2y-y3)/4 \sqrt{5} *xy*(6z2-x2-y2)/2
   \sqrt{10} *(4yz3-3yz*(x2+y2))/4
   (8z4-24*z2*(x2+y2)+3(x4+2x2y2+y4))/8 \sqrt{10}
   *(4xz3-3xz*(x2+y2))/4 \sqrt{5} *(x2-y2)*(6z2-x2-y2)/4 \sqrt{70}
   *z*(x3-3xy2)/4 \sqrt{35} (x4-6x2y2+y4)/8


Representation of functions and frozen cores
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

ADF uses the Cartesian representation for the spherical harmonics part
in functions:

   f(x,y,z)=x^a y^b z^c r^d e^{-\alpha r}

The angular momentum quantum number *l* is then given by *l*=a+b+c,
and the main quantum number *n* = *l* +d+1.

There are (*l* + 1)(*l* + 2)/2 different combinations of (a, b, c) for
a given *l* - value, rather than (2 *l* +1). The excess is caused by
the presence of spurious non-*l* functions in the set; a Cartesian
d-set, for instance, consists of six functions, five of which are true
d-functions while one linear combination is in fact an s-type function
(x2+y2+z2). Only the five true d-combinations are actually used as
degrees of freedom in the basis set, but lists of primitive basis
functions (bas), for instance, run over all Cartesian functions
including the improper ones.

A function *set* in ADF is characterized by the quantum numbers *l*
and *n*, and by the exponential decay factor a. A set thus represents
(*l* +1)(*l* +2)/2 Cartesian functions and (2 *l*+1) degrees of
freedom.

The atomic frozen core orbitals are described as expansions in Slater-
type functions; these are not the functions of the normal basis set
but another set of functions, defined on the data files you use in
Create mode.

Orthogonality of the valence space to the frozen core states is
enforced as follows: for each frozen core shell (characterized by the
quantum numbers *l* and *n*: all orbitals with *m* = - *l* ... + *l*
are identical apart from rotation in space) the set of valence basis
functions is augmented with a so-called core orthogonalization
function set. You may conceptually interpret the core
orthogonalization functions as single zeta expansions of the true
frozen core states. Each of the normal valence basis functions is now
transformed into a linear combination of that valence function with
all core orthogonalization functions, where the coefficients are
uniquely defined by the requirement that the resulting function is
orthogonal to all true core functions.

So the list of all Cartesian basis functions is much larger than the
degrees of freedom of the basis: it contains the spurious *non-l*
combinations and it contains also the core orthogonalization
functions.


Evaluation of the charge density and molecular orbitals
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

adf.rkf contains all the information you need to evaluate the charge
density or a Molecular Orbital (MO) at any point in space. Most of the
information is located in section Basis:

A list of function characteristics (kx,ky,kz,kr,alf), including the
core orthogonalization functions. This list does *not* run over *all*
bas functions used in the molecule: if a particular function is used
on the atoms of a given atomtype, the function occurs only once in the
list, but in the molecule it occurs as many times as there are atoms
of that type.

With array nbptr you locate the subsections in the function list that
correspond to the different types of atoms: for atom type i the
functions nbptr(i)...nbptr(i+1)-1. The distinct atom types are listed
in an early section of the standard output file.

Array nqptr gives the number of atoms for type i: nqptr(i+1)-nqptr(i).
With this information you construct the complete list of all
functions. Repeat the subsection of type i as many times as there are
atoms of that type: the complete list can be considered to be
constructed as a double loop, the outer being over the atom types, the
inner over the atoms that belong to that type. The total 'overall'
list of functions you obtain in this way contains naos functions. Note
that in this way we have implicitly also defined a list of all atoms,
where all atoms that belong to a particular atom type are contiguous.
This list is the so-called 'internal' atom ordering, which may not be
identical to the order in which atoms were specified in input, under
atoms.

For a given symmetry representation (Sections S) the array npart gives
the indices of the basis functions in the overall list that are used
to describe orbitals in this representation. In case of an
unrestricted run the array npart applies for either spin: the same
basis functions are used; the expansion coefficients for the molecular
orbitals are different, of course.

In the symmetry-representation sections Eigen_bas gives the expansion
coefficients that describe the MOs. The expansion refers to the
functions indicated by npart, and the function characteristics are
given by the arrays kx,ky,kz,kr,alf, *and* bnorm, i.e. the expansion
is in *normalized* functions.

The value of an MO is now obtained as a summation of values of
primitive basis functions. For the evaluation of any such basis
function you have to take into account that its characteristics are
defined in the local coordinate system of its atom.

To obtain the charge density you sum all MOs, squared and multiplied
by the respective occupation numbers (array froc in the appropriate
irrep section).

Note that the auxiliary program densf, which is provided with the ADF
package, generates orbital and density values on a user-specified
grid.


TAPE10
======

TAPE10 is a binary KF file. By default TAPE10 is a scratch file.
TAPE10 contains data related to the numerical integration: points and
weights, values of functions (depends on direct-SCF options) and core
densities and potentials.

Use the keywords 'SAVE TAPE10' in the ADF calculation such that TAPE10
is saved. NMR requires a TAPE10 file, see also documentation on NMR
chemical shifts and NMR spin-spin couplings.


TAPE13
======

TAPE13 is a binary KF file. TAPE13 is the checkpoint file for restarts
after a crash. It is a concise version of adf.rkf, containing only the
data the program uses for restarting the calculation. See the restart
keyword. Note that since the AMSification of ADF in most cases this
TAPE13 has lost its usefulness. Instead one should use the file
ams.rkf, which is produced by the AMS driver, for restarting a
geometry optimization, for example.

Like adf.rkf, TAPE13 is a binary, keyword-driven KF file.

The kind of calculation that produces TAPE13 determines which sections
are written on it. The actual values of the variables should be
identical to the corresponding variables on adf.rkf. Also they should
have the same names and be located in the same sections. In some
cases, TAPE13 contains the complete corresponding section of adf.rkf.


TAPE15
======

TAPE15 is a binary KF file. By default TAPE15 is a scratch file.
TAPE15 contains data related to matrices like the density matrix, the
Fock matrix, and the overlap matrix.

Use the keywords 'SAVE TAPE15' in the ADF calculation such that TAPE15
is saved. Some external programs may need data that is stored on
TAPE15. See, for example, the documentation on adf2nbo to produce an
input for NBO and adf2damqt to produce an input for DAMQT.


TAPE41
======

TAPE41 is a binary KF file. It is produced by the *densf* program to
generate values of molecular orbitals, charge densities and potentials
on a user-specified grid, to be used typically for plotting or
graphical display, see the documentation on densf.


Other binary files
==================

In the results directory that ams creates one may find other binary KF
files. There may be binary adf.rkf-like output files for some points
on the potential energy surface that was visited during the
calculation. One may find t21.*.elementname files which are atomic adf
.rkf-like files, that were created during an ADF calculation. One may
find the binary t12.rel file that is not a KF file, which is an
auxiliary binary file for relativistic calculations. Depending on the
kind of ADF calculation more binary KF (scratch) files may be used.
