STATIC: List of Files |
This is a discussion of the actual program files for the static code. The discussion of the format of the input and output files are given elsewhere.
The files in the source code distribution of static are:
makefile
,
which is discussed in the Installation section.P1
, P2
and
P3
, which are also discussed in the Installation section.static.f
is the main program. It organizes the
calculation, opens input (SKIN
) and output
(SKOUT, SKENG
) files, and passes information to
the other processors, as needed. Note that only
static.f
and bande.f
make explicit calls
to MPI. All other functions and subroutines either run
independently on each processor, or only on the master
processor, which is assumed to have MPI rank 0.
static.f
calls the following subroutines:
mpifake.h
, a fake MPI header file, which tells
the code that there is only one processor available, and
mpifake.f
, a fake MPI library source. This
subterfuge is designed to increase the portability of the
code with little penalty in execution speed for serial
computers. In one case, in the subroutine
bande.f
, using fake MPI calls would cause a
large amount of needless copying. In this case we have
written the code to skip the MPI calls when only one
processor is being used. Note that this trick also saves
time if, for some reason, you want to run an MPI compiled
program on only one processor.input.f
reads the Slater-Koster parameter
file. The current version of the file reads files in the
format listed in the Tight-Binding
Parameters Database. This routine may be modified to
select other versions of the input parameters.
input.f
runs only on the master processor.input1.f
reads the structural information for
each lattice in the input (SKIN
) file. This
includes the primitive vectors of the lattice, the
number of atoms, the number of electrons, and the
internal parameters of the crystal. This is discussed
in detail in the examples in the Usage section.input1.f
calls
setlat.f
, which allows the user to
select from a preselected set of lattice types or to select
an arbitrary lattice. After the lattice is selected,
setlat
also allows you to construct an
arbitrary or pre-selected
strain, e.g., to calculate energy versus strain
and hence the elastic constants of the crystal.kptin.f
reads the information which determines
the k-point mesh in the problem. This may be a list of
k-points, a set of instructions to build the k-point
mesh, or a file in which the k-point information may be
obtained. Construction of a k-point mesh is discussed
in the examples in the Usage
section. This routine and all of its subprocesses run
only on the master processor. It may be feasible to run
the k-point generation program over many processors,
but it is probably not time efficient. kptin.f
calls the following subroutines:
rdspgp.f
, which reads the space group
file. Space group files for many lattices can be
found in the Crystal
Lattice Structures database. The proper space
group file is required only if the program is to
generate the k-points. If pre-generated k-points are
used, one can use this null
space-group file. rdspgp.f
calls
matmlt.f
, which performs some matrix
multiplications.mapk.f
, which converts from lattice to
Cartesian coordinates, and visa versakpgen.f
, which actually actually
generates the k-point mesh, if needed. This routine
calls the routines gdot.f
, which performs
inner products with a metric, hsort.f
, which
sorts the k-points, and also mapk.f
.search2.f
determines which atoms are close enough to be connected
by the Slater-Koster hopping and overlap integrals. This
determines the number of Slater-Koster pairs used in the
calculation. The distance, direction, and atom types
involved in each pair will be passed via the
/pairs/
common block. Note that it may be
profitable to convert search2.f
to a scalable
program. At the moment it runs on each processor, in
order to minimize the amount of message passing required
between the nodes.bande.f
performs the actual Slater-Koster
computation of the energy and, optionally, the pressure
or electronic structure. bande.f
runs in
parallel, assigning k-points to each processor and
collecting the results. This parallelization scheme
works best for a problem which has a large number of
k-points an a relatively few number of processors. See
the discussion in diag.f
for a possible alternative scheme for making the code
scalable. bande.f
calls:
setpar.f
, which uses the
information from search2.f
and the
tight-binding parameter file to construct the
Slater-Koster on-site, Hamiltonian, and overlap
matrix elements. Prior to version 1.11 this routine
was part of setup.f
If you have an
alternative method for determining Slater-Koster
parameters you can place it into the code by
modifying setpar.f
.setparv.f
is used to set
up the presure derivatives of the Slater-Koster
parameters found in setpar.f
. Prior to
version 1.11 this routine was part of
setvol.f
.setham.f
, which uses
the information from setpar.f
to
determine the Hamiltonian and overlap matrices at a
given k-point. This code was formerly part of
setup.f
. setham.f
calls
rotate.f
, which transforms the
Slater-Koster matrix elements into the appropriate
Hamiltonian and overlap matrix elements by
rotating from the standard molecular basis set
onto the actually Cartesian direction, and applies
Bloch's theorem to incorporate the k-point
mesh.diag.f
, which calls
the
LAPACK routine zhpev
to solve the
generalized Hermitian eigenvalue problem, or
zhpgv
to solve the generalized
Hermitian eigenvalue problem with eigenvectors. For
large diagonalization problems, especially with a
large number of available processors and only a few
k-points, it is likely that better scalability will
result by replacing these subroutines with the
corresponding ones from the
ScaLAPACK distribution.
diag.f
and perturb.f
(below) are collected in the file
lapack.f
. If your computer
installation has an optimized version of LAPACK
and/or BLAS, it is undoubtably better to link in
this version rather than use the generic versions
which are listed here. Another alternative, the
open-source ATLAS
(Automatically Tuned Linear Algebra Software)
package. The SGI Origin makefile
discussed in the Installation
section shows how this can be accomplished on one
system.setparv.f
, which, if the pressure is to
be calculated, uses the results of diag.f
and setparv.f
to set up the perturbation
matrices required to determine the Hellmann-Feynman
pressure for this calculation. The execution of
setparv.f
is very similar to
setham.f
. Like setham.f
,
setparv.f
also calls rotate.f
to
populate the Hamiltonian and overlap matrix.perturb.f
, which, if the pressure is to
be calculated, determines the perturbation energies
for the Hellmann-Feynman pressure, using the
LAPACK routine zhpev
to split degenerate
eigenvalues. The routine is similar in operation to
diag.f
.tweaks.f
routine analyzes
the contents of the TWEAKS
file, if it exists, and signals the main program as to
which diagnostic information is the be printed.static Home Page Introduction Installation List of Files Usage Input Files Output Files Trouble Shooting Appendix
Current URL: http://esd.cos.gmu.edu/tb/static/list_of_files.html