Feff 5


Ab initio X-ray Absorption Fine Structure Code


Table of Contents

  1. Synopsis
  2. Introduction - How FEFF5 works
  3. Input File Options
  4. Output Files
  5. Installation Instructions
  6. Restrictions, License, and Copyright Information
  7. Sample Input Files
  8. Code Variables and Descriptions

Copyright 1992, FEFF Project, Department of Physics, FM-15 University of Washington, Seattle, WA 98195

Revised 3 April, 1992



Chapter 1. Synopsis

Code: FEFF5 calculates single- and multiple-scattering curved wave XAFS spectra, phase shifts and effective scattering amplitudes for clusters of atoms (Z < 95).

Code consists of 4 modules: i) a scattering potential and phase shift code: code uses a relativistic Dirac-Fock-Slater Desclaux atom code with the von Barth-Hedin ground state lda exchange-correlation potential; scattering states are calculated using overlapped atom potentials (Mattheiss prescription) plus a Hedin-Lundqvist/Quinn complex exchange correlation potential for excited states, referenced to the averaged interstitial potential; muffin-tin radii are determined automatically from calculated Norman radii; XAFS spectra are referenced to the threshold fermi level, as estimated by electron gas theory; atomic configurations and core-hole lifetimes are built in, and mean free paths are determined from the imaginary part of the average interstitial potential; ii) a path code: code reads atomic coordinates from input file feff.inp and generates a list of single and multiple-scattering paths, paths.dat; iii) a scattering matrix code: code calculates effective scattering matrices used in multiple scattering calculations using the algorithm of Rehr and Albers, and generates feffnnn.dat files, one for each scattering path; iv) an XAFS code: code ff2chi constructs the XAFS spectrum chi(k) from feff.dat files. Single and multiple scattering Debye-Waller factors are calculated using a correlated Debye model.

Machine Requirements: Code is written in ANSI FORTRAN 77, with the non-standard extension of double precision complex (complex*16) variables. See section V.

Input and Output Files: FEFF reads the single input file feff.inp, writes output files phase.bin (a binary file with the scattering phase shifts), paths.dat (a single- and multiple-scattering path list); feffnnn.dat (the effective scattering amplitudes for each path), the XAFS file chi.dat and optionally other output files. Details in sections II and III.

Copyright Notice: FEFF5 is copyright protected software and users must obtain a license from the University of Washington Office of Technology Transfer for its use; see section V.

Main Authors of FEFF5: please contact us concerning any problems with the codes.


S. I. Zabinsky
University of Washington, zabinsky@phys.washington.edu - (206) 543 0435
J. J. Rehr
University of Washington, jjr@leonardo.phys.washington.edu - (206) 543 8593
R. C. Albers
Los Alamos National Laboratory, rca@lanl.gov - (505) 665 0417
Citations: Please cite at least one of the following articles if FEFF is used in published work:
  1. J.J. Rehr and R.C. Albers, Phys. Rev. B41, 8139 (1990) (multiple scattering formalism); UW preprint (in preparation, 1992).
  2. J.J. Rehr, J. Mustre de Leon, S.I. Zabinsky, and R.C. Albers, J. Am. Chem. Soc. 113, 5135 (1991); J. Mustre de Leon, J.J. Rehr, S.I. Zabinsky, and R.C. Albers, Phys. Rev. B44, 4146 (1991)

Acknowledgements - We thank B. Houser and G. Pfeiffer for testing experimental versions of the multiple scattering code. Much of the original FEFF code was developed in collaboration with J. Mustre de Leon and is still in Feff5. We also thank J. Alben, M. Newville, P. O'Day, G. Pfeiffer, D. Sayers, E. Stern, Y. Yacoby for comments and suggestions.


Chapter 2. Introduction - How FEFF5 works

A: Calculation Strategy

Being a multiple-scattering code, FEFF5 differs in several respects from its single scattering predecessors, Feff3 and Feff4. We have, however, endeavored to make the code user-friendly, and reliable despite its increased complexity.

The efficient use of FEFF5 requires an understanding of both the code structure and the required input. Both the structure and input differ somewhat from that for FEFF4, but it is relatively easy to convert from one input format to the other. The input structure is illustrated for a particularly simple case below. A full list of options is given in section III.

Users must give FEFF enough input data to do its first two jobs of calculating both the the potentials and paths needed in the XAFS calculation. We have utilized the concept of a "unique potential" in FEFF5 to reduce compute time and memory requirements: all atoms with nearly equivalent local chemical environments should be given the same "unique potential" index by the user. This is NOT automated in FEFF5 and users must exercise reasonable care deciding whether two sites are chemically equivalent. For example, all atoms in the first shell of SF6 can be assumed to be chemically equivalent. Secondly, users must generally know or have some hypothetical estimate of the geometrical structure of the cluster of interest, for multiple scatterig to make sense. However, FEFF5 will still generate single scattering XAFS like FEFF3 or FEFF4 in the absence of such information.

Code strategy summary: FEFF reads one input file, feff.inp which specifies the model system and then runs one or more of the program modules POTPH, PATHS, GENFMT, and FF2CHI. The output is written to various ascii .dat files and binary .bin files. For a description of these output files and their contents, see notes for print level parameter on CONTROL card below and section IV (Output Files). The output simulates experimental data over the range 0-20 Ang**(-1), but the code may be speeded up by restricting the k range.


B: Running FEFF - Example Input Structure

The input to FEFF5 is given in the file feff.inp; it is listed on cards with a KEYWORD in CAPITAL LETTERS followed by data. As in FEFF4, the data is entered in free format. Comments may be added at the end of any line and spaces between lines are ignored. The following example illustrates the input structure. The location of KEYWORDS in feff.inp is arbitrary; and missing cards are replaced (when possible) by default values. An example input for the SF6 molecule is as follows:
TITLE SF6 molecule K-shell 

ATOMS                       
* x     y    z   pot-index
  0     0    0      0          (S absorber) 

 1.56   0    0      1          (6 F backscatters)
  0    1.56  0      1
  0     0   1.56    1

-1.56   0    0      1
  0   -1.56  0      1
  0    0  -1.56     1

POTENTIALS   pot-index  Z    (THESE CARDS MUST BE PRESENT)
       0    16
       1     9

Comments: The title of up to 75 characters is entered on a card with the KEYWORD TITLE. The geometrical information is normally entered using an ATOMS card, followed by data cards each containing the cartesian coordinates of a given atom in a cluster together with a "unique potential index." This index specifies the scattering potential to be used at that atomic site, i.e., potential 0 for the hole and potential 1 for all 6 backscatterers. The atomic number Z corresponding to a given "unique potential" must be entered in a list following the POTENTIALS card. Remaining lines beginning with an * are comments which are ignored.

With the above input FEFF5 will automatically find the multiple-scattering paths of within the cluster as well as the scattering potentials at each site.

Compatibility with FEFF4 - The input for FEFF5 has been simplified, in that a shell ordered input is no longer required - in FEFF5 that ordering is carried out automatically by the path code. To convert FEFF4 files to FEFF5 format, simply put a * in front of each FEFF4 SHELL card, and add the ATOMS and POTENTIALS cards.


C. Code Modules

The four independent code modules in FEFF5 are as follows:
An atomic potential and phase shift code, POTPH:
This code calculates atomic potentials and densities and overlaps them to determine scattering potentials, scattering phase shifts, muffin-tin radii, and other parameters for each atom. For computational efficiency we use the same scattering potential for every atom in a similar chemical environment. Each such distinguishable potential is called a "unique potential." CAUTION: This assignment is not automated in FEFF5 and requires some care on the part of a user. We anticipate that most physical systems will only have a small number of such unique potentials. For Cu for example, it is a good approximation to use just 3: 1) the potential for the central atom with the core hole, 2) that for the first coordination shell, and 3) that for the second shell; all subsequent shells may be assumed to have unique potential 3. All of these quantities are saved to disk in a binary file, PHASE.BIN.
A path code, PATH:
This module determines which paths to consider, based on atomic position data and/or single scattering paths which are described by SS cards (the SS cards are analogous to the SHELL cards of FEFF4). The pathfinder is the code that reads the atom positions and determines the paths. If atomic coordinates are not known, one may use SS cards to enter distance and coordination numbers; in that case feff only does single scattering. All paths are treated equally by the scattering amplitude subroutine GENFMT (see below) in FEFF5 -- a single scattering path is treated as a 2-legged multiple scattering path. The path list is needed by GENFMT to calculate the EXAFS; it is saved to disk in the file PATHS.DAT.
A scattering amplitude module, GENFMT:
The module GENFMT (the generalized f-matrix formalism): calculates the XAFS parameters for each path based on the fast, accurate scattering matrix formalism of Rehr and Albers, [Phys. Rev. B 41, 8139 (1990)]. The parameters are represented in terms of the quantities in the standard XAFS equation. GENFMT calculates these parameters for each path in the path list (PATHS.DAT) using the phase shifts, etc., from PHASE.BIN. The results are written to files FEFFnnn.DAT. A separate file, FILES.DAT, contains a list of all the feffnnn.dat files that were made.
The XAFS module, FF2CHI:
The XAFS spectrum chi(k) is calculated from the exafs parameters for each path. This module is called FF2CHI (i.e., feff to chi). FF2CHI reads the feffxxx.dat files listed in files.dat and makes chi.dat.

Chapter 3. Input File Options

A. File format

The input file to FEFF5, feff.inp, is free format line oriented. Blank lines and lines beginning with an asterisk (comment lines) are ignored wherever the occur. End of line comments are also ignored. Each type of input read by the program must contain a card with a "keyword" in CAPITAL LETTERS, and in some cases, followed by data cards. The sequence of keyword cards is arbitrary. If any card is omitted, default values are used; an exception is the POTENTIALS card, which is required. Numeric values are listed in free format, separated by blanks. Characters appearing after the expected data on a given line are ignored by feff and can be used as end-of-line comments. All distances are in Angstroms and energies in eV.

The complete list of input cards is given below. Detailed explanations follow.

The standard data types are (Sec. 4. B.)
TITLE, ATOMS, HOLE, POTENTIALS, CONTROL, PRINT, DEBYE and END
Useful options include (Sec. 4. C)
KLIMIT, SS, RMAX, RMULTIPLIER, NLEG, REQUIRE, CRIT
Some data types are recommended only for advanced users or diagnostic purposes (Sec. 4. D)
ION, EXCHANGE, FOLP, OVERLAP
These data types are listed below. Each DATATYPE is followed by a brief explanation and an example.

B. General DATATYPES

  1. TITLE card(s)
    The title can be any number of lines preceded by the keyword TITLE. Default: no title.

    TITLE Andradite (Novak and Gibbs, Am.Mineral 56,791 1971)
    TITLE K-shell 300K


  2. POTENTIALS card and data
    The data following the POTENTIALS card assigns a unique potential index to each distinguishable atom. The potential index ipot is the index of the potential to be used for the phase shift calculation. NOTE: Because the phase shift calculation is the most time-consuming part of FEFF, it may be useful to assume that the potential for a given shell of atoms is the same as that of a previously calculated shell. For example, in Cu it is a good approximation to determine potentials only for the central atom, first and second shells (ish=0, 1, and 2), and to use the second shell potential (ipot=2) for all higher shells. Such approximations should be checked in each case.

    POTENTIALS SF6 molecule
    * potential-index Z
    0 16 Sulfur K hole
    1 9


  3. HOLE hole-code, So**2
    The HOLE card includes the hole-code ihole and the amplitude reduction factor So**2. An entry of 0.0 for So**2 gives the default value s02=0.9 Defaults if HOLE card is omitted: hole=1 (K shell), s02=1. Presently available hole-codes (complain if you need M-shells, etc.) are:
    0 = no hole
    1 = K-shell
    2 = L1-shell
    3 = L2-shell
    4 = L3-shell

    HOLE 1 1.0 hole-code, So**2

  4. ATOMS card and data
    Cartesian coordinates of each atom in a cluster are entered following the atoms card, one per line, together with a unique potential index ipot.

    ATOMS
    * x y z ipot
    0. 0. 0. 0 S K-shell hole

    3.61 0.00 0.00 1 F 1st shell atoms
    0.00 3.61 0.00 1
    0.00 0.00 3.61 1
    -3.61 0.00 0.00 1
    0.00 -3.61 0.00 1
    0.00 0.00 -3.61 1


  5. CONTROL mphase, mpath, mfeff, mchi
    The CONTROL card enables users to run one or more of the modules separately. The card has 4 binary "switches", mphase, mpath, mfeff, mchi, with m=1=on m=0=off, one for each module. (Default is CONTROL 1 1 1 1) See Sec. D. below for more information.

    CONTROL 0 0 1 1

  6. PRINT iprint iclean
    The PRINT card determines what is printed The parameter iprint determines the output of the atom and phase code
    iprint = 0, potph only; =1 misc.dat; =2 pot and phase, =3 atom)
    The iclean parameter determines which feffxxx.dat files are printed:
    iclean =0 keep only feff.dat that meet xcrit, =1 keep only feff.dat that meet xcrit/2, =2 keep all feff.dat's). Used by genfmt.

    PRINT 2 2

  7. SS index ipot deg rss sig2
    The SS card is used when the structure of a given shell is unknown. No multiple scattering is produced but a single scattering path of degeneracy deg is produced. Overlap cards may be used to construct the potential for such a path. The parameters are a shell index (ipot), atomic number (iz), number of degeneracy (deg) distance to the central atom (rss) Debye-Waller factor (sig2). This could be used to add single scattering beyond the limits of a cluster.

    SS 29 2 48 5.98 .0036 (parameters for 19th shell of Cu)

  8. END
    The END card marks the end of reading a the feff.inp file; all data following the END card is ignored. This is optional, but useful for making short runs with only part of an input file.

C. Special Options in FEFF5

  1. KLIMIT xkmin, xkmax
    The KLIMIT card limits the data range, for example to save compute time. Most of the compute time in the phase shift calculations is taken between k=10 and k=20.

    KLIMIT 2. 12.

  2. DEBYE temp debye-temp sigma**2
    The Debye card is used to calculate debye-waller factors for each single and multiple scattering path using the correlated Debye Model or insert an overall debye-waller factor into the problem. The model is best suited for homogeneous systems, where it is quite accurate. CAUTION: in heterogeneous systems the model only gives approximate values which can easily be off by factors of two or more. Temperatures are in K, sigma**2 in Ang**2. Two examples follow:

    DEBYE 190 315 0 Debye Waller factors for Cu

    DEBYE 0 0 .0036 Overall sigma**2 for Cu


  3. MCMASTER
    The MCMASTER card adds a correction to sigma**2, typically about 0.0005 to account for the edge step normalization error. (Option not yet installed in FEFF5).

D. Single and Multiple Scattering Control Cards

  1. RMAX rmax
    The RMAX card determines the maximum effective distance, rmax, of a given path. Note that rmax is one-half of the total path length in multiple-scattering paths.

    RMAX 5.10 (only include multiple scattering up to the 4th shell in Cu))

  2. NLEG nleg max
    The NLEG card limits the number of scattering paths to nleg. If nleg is set to 2, only single scattering paths are found. The default is nleg = 4.

    NLEG 2 (find only single scattering paths)

  3. REQUIRE rreq, ipot
    This card reduces the total number of multiple scattering paths by requiring that each such path have a particular atom type. For example, the card can be used to eliminate multiple scattering paths with all low Z atoms. It forces the pathfinder to require that all ms paths of length rreq contain at least one atom with potential index ipot.

    REQUIRE 5.0 29

  4. RMULTIPLIER rmult
    The use of the RMULTIPLIER card multiples all atomic coordinates by a constant factor, rmult. This is useful, for example, if unit cell coordinates are used. (Default value rmult=1.)

    RMULTIPLIER 1.01 (increase distances by 1%)

  5. CRIT icrit xcrit
    The CRIT card sets a cutoff parameter to limit the number of multiple scattering paths. An estimate of the XAFS amplitude for a path must be above the value of xcrit to be retained. Default: xcrit = 0.1 (i.e., 10% of the contribution of the first shell scatterers.) icrit = 0, use xcrit for chi factor criterion, = 1, use .1*first path chi factor as xcrit

    CRIT 0 0.01

E. Cards for EXPERT USERS

  1. OVERLAP iph
    The OVERLAP card contains information needed to construct the overlapped atom potentials when atomic coordinates are not known or specified. It is recommended only for EXPERT USERS - see WARNING below. If the atomic positions are listed following the ATOMS cards, the OVERLAP cards are NOT needed. The OVERLAP card contains the potential index of the atom being overlapped and must be followed by cards specifying: the potential index, number of atoms of a given type to be overlapped and and their distance to the atom being overlapped. This option can be useful in crystals, especially for distant shells -- see sample input files for an example. WARNING: users should verify that the coordination chemistry built in using the OVERLAP cards is realistic; it is important to specify ALL the closest neighbors of a typical atom in the shell to be overlapped. A user should keep in mind that the most important factor in determining the scattering amplitudes is the atomic number of the scatterer, but the coordination chemistry is must be approximately correct to ensure good scattering potentials. Thus it is important to specify as accurately as possible the coordination environment of the scatterer.

    OVERLAP 4 determine overlap for 3rd shell of Cu
    0 1 2.55266 ipot, number in shell, distance
    1 4 2.55266
    2 7 2.55266
    2 6 3.61000
    2 24 4.42133


  2. EXCHANGE ixc, vi0, vr0 (EXPERT USERS only)
    The EXCHANGE card specifies the energy dependent exchange correlation potential to be used. It contains the index of the xc pot (ixc), the constant imaginary part of the self-energy (vi0), and a constant real energy shift (vr0). The Hedin-Lundquist self-energy (default) appears to be the best choice for all applications we have tested in detail. Optionally one may use the Dirac-Hara exchange correlation potential and an appropriate imaginary potential vi0. Defaults if EXCHANGE card is ommitted: ixc=0 (Hedin-Lundquist), vi0=0.0
    ixc values
    ixc=0 Hedin-Lunqvist + const [const= -(vr0 + i*vi0)]
    ixc=1 Dirac-Hara + const
    ixc=2 ground state + const
    ixc=3 Dirac-Hara + HL imag part
    vi values
    vi0 is (the negative of the) imaginary const shift
    v00 is (the negative of the) real const shift


    EXCHANGE 1 5.0 3.0 ixc, vi0, vr0 (in eV)

  3. ION ipot ionization (EXPERT USERS only)
    The ION card ionizes all atoms with atom type ipot. Negative values and non-integers are NOT permitted. The ION card is used to ionize all atoms of a particular potential index. For example, for diatomics like Br2, the fully relaxed configuration has ionization=1 on ipot=1. WARNING: The ionization card should be used with caution; because of charge transfer, the actual degree of ionization is not directly related to the chemical valency. The default (non-ionized) scattering potentials are often superior to those empirically ionized, and the results should be checked both ways. Defaults if ION cards are ommitted: atoms are not ionized.

    ION 1 1 ipot, ionization

  4. FOLP iph folp - (EXPERT USERS ONLY)
    The FOLP card sets a parameter which determines by what factor muffin-tin radii are overlapped. We recommend that the default be used, except possibly in cases with severe anisotropy, or for diagnostic purposes.

    FOLP 1 1.1 (10% overlap of muffin tin of atom #1)

F: Run Control Options

For many cases of interest, users may want to use the various control options in FEFF5 to facilitate multiple scattering calculations. FEFF5 controls the code function using a CONTROL card that lets enables users to run one or more of the modules separately. The card has 4 binary "switches" m=1=on m=0=off, one for each module.

CONTROL mphase, mpath, mfeff, mchi

The modules and associated input and output files are:
POTPH: potential and phase calculator
reads: feff.inp
writes: phase.bin (binary file) and various diagnostic files
PATH: path finder
reads: feff.inp
writes: paths.dat
GENFMT: exafs parameter calculation
reads: phase.bin and paths.dat
writes: feffnnn.dat (one for each path) and files.dat
FF2CHI: XAFS calculation
reads: files.dat and all files specified in files.dat (feff.dat format) writes: chi.dat

Users will probably only want to calculate the unique potentials and phase shifts once, since this is the most time-consuming part of the process. To do this simply save the phase.bin file from the first run (e.g. a run with CONTROL 1 0 0 0) on with a cluster of sufficient size to model the scattering potentials adequately. Then use the CONTROL card to turn off the potential and phase module (set mpotph=0) for the rest of your analysis. If you alter the model structure enough, you may need to recalculate potentials. To be safe, one should redo the entire problem at the end of the analysis with fresh potentials and phase shifts.

Which multiple scattering paths are important to include in a given system is often not obvious. Also the folklore, that shadowing paths are the most important, is unreliable. Our hope is that FEFF5 will enable users to answer this question case by case. A sensible approach is to proceed by trial, chosing different combinations of paths to compute the total XAFS spectrum. Most likely one will want to include all of the shortest single and multiple-scattering paths, and only some of the more distant paths. This can be compared with a calculation containing only single-scattering and shadowed paths. To simplify the task, we have introduced an "importance factor" which gives an estimated magnitude of a given path compared to a single scattering path of the same length.

The multiple scattering paths are determined by the path finder, PATH, and the file paths.dat is the path finder output. One can use several path-finder control cards (NLEGS, REQUIRE, RMAX) to simplify this task by limiting the number and length. of multiple scattering paths. To examine path data alone, it suffices to run only the PATH module; this is done with the CONTROL card setting CONTROL 0 1 0 0 .

When you have a set paths make sure that paths.dat has only the paths you want, and run the XAFS calculation module GENFMT. This module will make feffxxx.dat files with effective scattering amplitudes and phases, one for each path (xxx is the path index of each path in paths.dat) as well as a file feff.dat containing a list of feff.dat files. If you are making lots of runs, you may want to re-name some or all of the feffxxx.dat files.

If you want to calculate the contribution to the XAFS spectrum chi(k) from a given combination of paths, you can edit the file files.dat: make sure that it only contains a list of the files that you want; if you don't change files.dat, it will contain the list of the feffxxx.dat files created when the genfmt module was last run.


G. EDITING INPUT and OUTPUT FILES

Users may edit the following files as a quick and sometimes convienent way to prepare a given run. See file format section for details.
files.dat
This is the list of files that ff2chi uses to calculate chi. You can also change the parameters in the built-in correlated debye model here; for example, you can change the debye temperature without having to rerun the path finder or genfmt.
feffxxxx.dat
You may re-name any of these to whatever you like, as long as you remember to list the files in files.dat when you want to calculate the XAFS using FF2CHI. You may also add or modify an explicit debye waller factor or amplitude factor for a given path by editing this file.
paths.dat
You may modify a path, or even invent new ones. For example, you could make a path to determine the effect of a focusing atom on a distant scatterer. Whatever index you enter for the path will be used in the filename given to the feffxxx.dat file; i.e., for the choice, index = 845, the exafs parameters will appear in feff845.dat.
A handy way to add a single scattering path of length R is to make a 2-leg path with the central atom at (0, 0, 0) and the scatterer at (R, 0, 0).

Chapter 4. Output files

There are several types of files written by feff depending on print level specified for the run. This file describes the contents of each type of output file. (See PRINT options)

1) File descriptions

chi.dat
Standard xafs data chi(k) relative to threshold (k=0). Columns are: k, chi(k), |chi(k)| (xafs)
feffnnnn.dat
Effective scattering amplitude and phase shift data, with k referenced to threshold for shell nn. Clumns are: k, phi_c, |feff|, ph(feff), redfac, lambda, Re(p)
misc.dat
header file for quick reference
phasexx.dat
complex phase shifts for each shell
potxx.dat
detailed atomic potentials and densities 'till ya choke
atomnn.dat
diagnostic information on Desclaux free atom calculation for free atom nn
echo.dat
input parameters and internal indices
ovrlp.dat
overlapped interstitial data

2) Variables in output files and in calculation of XAFS

k
wave number (ang**-1); k=sqrt(e-e_f) where e is energy and e_fermi is the fermi level computed from electron gas theory at the avg interstitial charge density
chi(k)
so**2 * redfac sum_shells [ natsh * (|feff|/kR**2) * exp(-2R/lambda) * sin(2kR + ph(feff) + phi_c)) * exp(-2k**2*sigma**2) ]
phi_c
2*delta_l_c -l*pi (total central atom phase)
feff
effective, curved-wave backscattering amplitude feff(k) in xafs formula for each shell
ph(feff)
phase of feff(k) for each shell
redfac
exp(-2 imag (delta_c) ) , total central atom loss factor
R
distance to central atom for each shell
natsh
mean number atoms in each shell
sigma**2
mean square variation of R for each shell
lambda
mean free path (angstroms) =-1./imag (p)
kf
fermi momentum at avg interstitial charge density
p=p(r)
local momentum (p(r)**2=k**2+kf(r)**2+sigma-sigma_f)
sigma
self energy at energy e, sigma_f at energy e_f

Chapter 5. Installation Instructions

The program FEFF5 is provided as a single source file, which contains a main program and all necessary subroutines. Simply compile and link on your system using a Fortran 77 compiler and your usual linker. The executable file produced is all you will need.

We have endeavored to make FEFF portable to most machines without any modification. If your machine does not reproduce the test output files chi.dat and feffnnn.dat to high accuracy, some changes may be needed. Please report any problems or warning messages to the authors, as this will help us achieve full portablility. If changes are needed, keep in mind the following points:

Floating point calculations must be done to precision 64 bits. Thus the code uses double precision variables throughout, i.e., real*8 for real numbers and complex*16 for complex numbers. A single precision version for 64 bit word machines, e.g., CRAY and CDC, is available from the authors.

Code is written in ANSI FORTRAN 77, EXCEPT that complex*16 variables are required. Since data type COMPLEX*16 is not part of the ANSI standard, minor compiler-dependent modification may be necessary. We have used the VAX extensions to ANSI FORTRAN 77 since they seem to be the most portable. The non-standard statements and intrinsic functions used are: COMPLEX*16 variables and arrays; DIMAG(arg) returns a double precision imaginary part of arg; DCMPLX(arg) returns a complex*16 version of arg; DBLE(arg) returns a double precision real part of arg; SQRT, EXP, ABS and other generic math functions are assumed to accept complex*16 arguments and return double precision or complex*16 results.

Files are opened with the OPEN statement. As the ANSI definition gives some leeway in how the OPEN statement interacts with the operating system, we have chosen file names and conventions that work on UNIX, VAX/VMS, IBM PCs (and clones) with MS FORTRAN, CRAY, and CDC machines. It may be necessary to modify the open statements on other systems.



Chapter 6. Restrictions, License, and Copyright Information

1) Restrictions and License Information

Feff is copyrighted software and a license from the University of Washington Office of Technology Transfer must be obtained for its use. This is necessary to protect the interests of users and the University of Washington. Both academic/non-profit and corporate licenses are available - see the addendum to this document for details. New users should request the latest version of this code from the authors. The license may be obtained by writing to FEFF Project, c/o Marion Joyner, Dept. of Physics, FM-15, Univ. of Washington, Seattle, WA 98195. Tel: (206) 685-2400 E-mail: joyner@landau.phys.washington.edu

2) ADDENDUM: Government Copyrights (DO NOT DELETE)

This work was supported in part by DOE Grant DE-FG06-90ER45416. In accordance with the DOE FAR rules part 600.33 "Rights in Technical Data - Modified Short Form" the following clause applies to FEFF:

(c)(1)The grantee agrees to and does hereby grant to the U.S. Government and to others acting on its behalf:

(i) A royalty-free, nonexclusive, irrevocable, world-wide license for Governmental purposes to reproduce, distribute, display, and perform all copyrightable material first produced or composed in the performance of this grant by the grantee, its employees or any individual or concern specifically employed or assigned to originate and prepare such material and to prepare derivative works based thereon,

(ii) A license as aforesaid under any and all copyrighted or copyrightable work not first produced or composed by the grantee in the performance of this grant but which is incorporated in the material furnished under the grant, provided that such license shall be only to the extent the grantee now has, or prior to completion or close-out of the grant, may acquire the right to grant such license without becoming liable to pay compensation to others solely because of such grant.

(c)(2) The grantee agrees that it will not knowingly include any material copyrighted by others in any written or copyrightable material furnished or delivered under this grant without a license as provided for in paragraph (c)(1)(ii) of this section, or without the consent of the copyright owner, unless it obtains specific written approval of the Contracting Officer for the inclusion of such copyright material.



Chapter 7. Sample input files

a. SF6 Molecule

TITLE SF6 molecule K-shell 300K

ATOMS                       
* x     y    z   pot-index
  0     0    0      0          (S absorber) 

 1.56   0    0      1          (6 F backscatters)
  0    1.56  0      1
  0     0   1.56    1

-1.56   0    0      1
  0   -1.56  0      1
  0    0  -1.56     1

POTENTIALS   pot-index  Z    (THESE CARDS MUST BE PRESENT)
       0    16
       1     9

b) Cu fcc metal 3 shells

TITLE Cu crystal fcc 190 K 
* fcc, lattice parameter a=3.61 from Kittel

*       mphase mpath mfeff mchi
CONTROL      0     0     0    1
KLIMIT  2 12
PRINT 2  2
DEBYE 190 315 0     

HOLE  1  0.85      K shell absorption, s0**2 = 0.85

POTENTIALS
  0  29
  1  29

ATOMS
* Absorbing atom
 0.0  0.0  0.0  0

* shell 1
 0.00    1.805  -1.805  1
 0.00    1.805   1.805  1
 0.00   -1.805  -1.805  1
 0.00   -1.805   1.805  1
 1.805   0.00   -1.805  1
 1.805   0.00    1.805  1
-1.805   0.00   -1.805  1
-1.805   0.00    1.805  1
 1.805  -1.805   0.00  1
 1.805   1.805   0.00  1
-1.805  -1.805   0.00  1
-1.805   1.805   0.00  1

* shell 2
 3.61   0.00   0.00  1
 0.00   3.61   0.00  1
 0.00   0.00   3.61  1
-3.61   0.00   0.00  1
 0.00  -3.61   0.00  1
 0.00   0.00  -3.61  1

* shell 3
 3.61   1.805 -1.805  1
 3.61   1.805  1.805  1
 3.61  -1.805 -1.805  1
 3.61  -1.805  1.805  1
-3.61   1.805 -1.805  1
-3.61   1.805  1.805  1
-3.61  -1.805 -1.805  1
-3.61  -1.805  1.805  1
 1.805  3.61  -1.805  1
 1.805  3.61   1.805  1
 1.805 -3.61  -1.805  1
 1.805 -3.61   1.805  1
-1.805  3.61  -1.805  1
-1.805  3.61   1.805  1
-1.805 -3.61  -1.805  1
-1.805 -3.61   1.805  1
 1.805  1.805 -3.61  1
 1.805  1.805  3.61  1
 1.805 -1.805 -3.61  1
 1.805 -1.805  3.61  1
-1.805  1.805 -3.61  1
-1.805  1.805  3.61  1
-1.805 -1.805 -3.61  1
-1.805 -1.805  3.61  1

Chapter 8. Code Dimension Limits and Parameter Descriptions

The end of line comments were removed from the code because they are not standard Fortran. The array names are a bit cryptic, due to the six character limit in standard FORTRAN -- the comments included here explain what the names mean. If you need to run larger problems than the dimension statements in the code allow, simply change the dimensions in all the relevant parameter statements and recompile. Some dimensions associated with the atom and phase shift codes, e.g. the number of r-mesh points and the max number of angular momentum levels should NOT be changed.

dim.h

      parameter (nphx = 7)	!max number of shells to calc phases
      parameter (natx = 200)	!max number of specific atoms
      parameter (nfrx = nphx)	!max number of free atom types
      parameter (novrx = 8)	!max number of overlap shells
      parameter (nrptx = 250)	!(max) number of r-mesh points
      parameter (neptx = 50)	!(max) number of coarse e-mesh points
      parameter (lmaxx = 24)	!max number of ang mom levels
      parameter (nktot = 401)	!number of points in fine e-mesh
      parameter (nheadx = 30)	!max number of title lines

arrays.h

c     Notes:
c        nat	number of atoms in problem
c        nph	number of unique potentials
c        nfr	number of unique free atoms
c        ihole	hole code of absorbing atom
c        iph=0 for central atom
c        ifr=0 for central atom

c     Specific atom input data
      dimension iphat(natx)	!given specific atom, which unique pot?
      dimension rat(3,natx)	!cartesian coords of specific atom

c     Unique potential input data
      dimension iatph(0:nphx)	!given unique pot, which atom is model?
				!(0 if none specified for this unique pot)
      dimension ifrph(0:nphx)	!given unique pot, which free atom?
      dimension xnatph(0:nphx)	!given unique pot, how many atoms are there 
				!of this type? (used for interstitial calc)

      dimension folp(0:nphx)	!overlap factor for rmt calculation
      dimension novr(0:nphx)	!number of overlap shells for unique pot
      dimension iphovr(novrx,0:nphx)	!unique pot for this overlap shell
      dimension nnovr(novrx,0:nphx)	!number of atoms in overlap shell
      dimension rovr(novrx,0:nphx)	!r for overlap shell

c     Free atom data
      dimension ion(0:nfrx)	!ionicity, input
      dimension iz(0:nfrx)	!atomic number, input

c     ATOM output
c     Note that ATOM output is dimensioned 251, all other r grid
c     data is set to nrptx, currently 250
      dimension rho(251,0:nfrx)		!density*4*pi
      dimension vcoul(251,0:nfrx)	!coulomb potential

c     Overlap calculation results
      dimension edens(nrptx,0:nphx)	!overlapped density*4*pi,
      dimension vclap(nrptx,0:nphx) 	!overlapped coul pot
      dimension vtot (nrptx,0:nphx)	!overlapped total potential

c     Muffin tin calculation results
      dimension imt(0:nphx)	!r mesh index just inside rmt
      dimension inrm(0:nphx)	!r mesh index just inside rnorman
      dimension rmt(0:nphx)	!muffin tin radius
      dimension rnrm(0:nphx)	!norman radius

c     PHASE output
      complex*16 eref(neptx)		!interstitial energy ref
      complex*16 ph(neptx,lmaxx+4,0:nphx)	!phase shifts
      dimension em(neptx)		!energy mesh
      dimension lmax(0:nphx)		!number of ang mom levels
      dimension lmax(0:nphx)			!number of ang mom levels


BR