Introduction

All of the programs have special branches that may be (and sometimes must be) set from command-line switches.

Here is an example:

$ lmf cafeas -vns=4 -vnm=5 --rpos=pos

Following unix style, switches always begin with dash (−). Many codes have command-line switches unique to their purpose, but a number of switches are shared in common.

Some switches have a single dash ; some have two. Those with two tend to control program flow (e.g. --show), while those with a single dash tend to have an “assignment” function, such as a variables declaration (e.g. -vns=4). Sometimes there is not a clear distinction between the two, e.g. the printout verbosity --pr accepts either one or two dashes (see below).

In the example above, -vns=4 -vnm=5 assigns variables ns and nm to 4 and 5, respectively, while --rpos=pos tells lmf to read site positions from file pos.cafeas.

Switches Common to Most or All Programs

--help | --h

Lists command-line switches for that program and exits.

--input

Lists tags (categories and tokens) a program will read. Same as turning on IO_HELP=T

--showp

Prints out input file after parsing by preprocessor, and exits. It shows the action of the preprocessor, without parsing any tags.

--show | --show=2

Prints the input file parsed by preprocessor, and the value of the tags parsed or default values taken.--show=2 causes the program to exits after printing.

Note: the preceding switches are intended to assist in managing and reading input files. They are discussed in more detail here.

--pr#1[,#2] | -pr#1[,#2]

Sets output verbosities, overriding any specification in the ctrl file.

Optional #2 sets verbosity for the potential generation part (applicable to some codes)

Prints out a summary of timings in various sections of the code. Timings are kept to a nesting level of #1. If #2 is nonzero, timings are printed on the fly.

--iactive

Turns on ‘interactive’ mode, overriding any specification through IO_IACTIV in the ctrl file. See here for a description.

--iactive=no | --no-iactive

Turns off ‘interactive’ mode.

-cname=”string“

Declares a character variable name and gives it a value “string“. The quotation marks are not needed if string has no spaces.

-vname=expr

Declares a numeric variable name and assigns its value to the result of expression expr. Only the first declaration of a variable is used. Later declarations have no effect.Note: there are also generalized assignment operators *=, /=, +=, -=, and ^= that modify already-declared variables, following C syntax.

Switches Common To Programs Using Site Information

Most Questaal codes read structural information (lattice and position vectors). For any program reading site information the following switches apply:

--rpos=fnam

Tells the program to read site positions from file fnam.ext after the input file has been read. fnam.ext is in standard Questaal format for 2D arrays.

--fixpos[:tol=#] | --fixpos[:#]

Adjust positions slightly, rendering them as consistent as possible with the symmetry group. That is, if possible to slightly displace site positions to make the bsis conform to a group operation, make the displacement. Optional tolerance specifies the maximum amount of adjustment allowed. Example: lmchk --fixpos:tol=.001

--fixlat

Adjust lattice vectors and point group operations, attempting to render them internally consistent with each other.

--sfill[options]

Runs the sphere resizer. The same function is performed if SPEC_SCLWSR is set. Using this command-line argument you control the tags SCLWSR, WSRMAX, OMAX1, and ATOM_CSTRMX, overriding those in the ctrl file. The first character in options acts as a delimiter separating them. Here we assume it is ’~’. Options:

Switches for blm

Express style input file level n. If n>0, an express category is created. For n>0, an EXPRESS category is created and a site file is created. Lattice and site information are not included in the ctrl file but are read through the site file. As n increases, the ctrl file becomes simpler but contains less information. If --express is missing, a default value of n=3 is used. If n is missing, a default value of n=6 is used. Level mode

0: Standalone: All input through standard categories, and site file is not automatically made. No supporting comments are given.

1: Expert: Similar to mode 9, but EXPRESS category is added. Input is terse with no supporting comments Tags duplicated by EXPRESS are retained to facilitate editing by the user (EXPRESS takes precedence).

2: Verbose: Similar to mode 1, with comments added

3: Large: Similar to mode 2, but duplicate tags are removed

4: Standard: Most tags covered by defaults are removed.

5: Simple: No preprocessor instructions, variables or expressions are used

The following set switches allow you to set parameters for which no defaults are supplied. You can enter them through command line arguments to blm as shown below, or edit the ctrl file later.

--gmax=# specify mesh density cutoff GMAX. You can use lmfa to determine this number for you, once the basis set has been supplied. See this tutorial for an example.

--nk=#1[,#2,#3] k-mesh for Brillouin zone integration. A typical number for semiconductors in small cells is 6. For metals it depends on how precisely you need to determine the Fermi level. See this tutorial for an example.

--nkgw=#1[,#2,#3] Similar as --nk but applies to GWk-mesh. Same as --gw~nk=…

--nit=# specify max number of iterations to attempt on the approach to self-consistency. Program ends after # iterations, or when self-consistency is reached, whichever occurs first. For an example, see this tutorial.

--ehmx=# adds a tag HAM_AUTOBAS_EHMX=# (or the equivalent in EXPRESS mode). This is used by lmfa and limits the upper bound to LMTO smoothed Hankel energy, when autogenerating a basis set.

--rsmmx=# adds a tag HAM_AUTOBAS_RSMMX=# (or the equivalent in EXPRESS mode). This is used by lmfa and limits the upper bound to LMTO smoothed Hankel smoothing radius, when autogenerating a basis set. # is a multiple of the MT radius (default value=2/3).

--frzwf Adds FRZWF={frzwf} to the HAM category. This switch will be set if preprocessor variablefrzwf is set to nonzero. When HAM_FRZWF is set, the basis set is kept fixed the potential used to make partial waves is frozen, and the boundary conditions kept fixed. (In the ASA, only the latter applies). For an application, see this tutorial.

--nl=# Sets default maximum l cutoff to #−1 in augmentation spheres (used in the absence of explicit species-dependent specification). The full-potential codes use this default for ATOM_SPEC_LMXA; The ASA codes use it for ATOM_SPEC_LMX.This tutorial has an example.

--findes[~options] search for empty sphere sites to improve lattice packing. It works by adding adding empty spheres (largest possible first) until maximum sphere overlap is reached, or until space is filled such that sum-of-sphere volumes = unit cell volume. Options:

~omax=# : Temporarily constrain overlap between sites to # when finding empty spheres. After they are located, omax is restored to its default value (or what is set by --omax=) and spheres are resized.

~sclwsr~# : Use in conjunction with ~omax=#. Sets SPEC_SCLWSR when spheres are resized after omax is restored on finding ES.

~nspmx=# : Limit the number of E species to #. The MT radius of all new classes exceeding # is set to the smallest E radius found.

~1spec : Force new empty sites to be the same species. Same as nspmx=1.

~spec : (when used with lmchk). Do not split species into classes before searching for empty spheres.This tutorial has a simple example; see also this tutorial and this one for more detailed examples.

--addes[~options] add tags to prepare for later addition of empty spheres. Options:

~end : Tells blm to put the E species last in the SPEC categoryThis tutorial has an example.

--omax=#1 | --omax=#1,#2,#3 Set maximum sphere overlaps to #1. #2 and #3 concern A-E and E-E overlaps, respectively where A are true atoms and E are empty spheres.This tutorial has an example.

The following concern how structural data is written to disk or read from disk:

Tab displacement style: (--shell~tab=2~disp=file) special purpose mode that reads in a second set of site positions from file.ext. It lists only connecting vectors that are changed relative the original vectors. Moreover the table prints out both the original vector and the displacement vector, e.g.

Options are delimited by ~ (or the first character following --shell):~r=#: Specifies range of neighbor-list. Default value is 5.~e: prints inner product between Euler angles (relevant to noncollinear magnetism in the ASA)~fn=filename: writes neighbor table to file filename.ext~sites~site-list: restricts sites considered to site-list. See here for the syntax of site-list~pair~site-list: restricts neighbors to site-list.~nn: restrict table to nearest-neighbor shell (tab mode only)

Example: --shell:tab=2:disp=pos:sites:1:r=3:fn=tab2:nn writes to tab2.ext a table in this format. The table is restricted to displacements around site 1, distance less than 3 a.u.

--angles[options]

Prints angles between triples of sites.

Options are delimited by ~ (or the first character following --shell):~r=#: Specifies range of neighbor-list. Default value is 2.5.~sites~site-list: loops over center atoms in site-list. See here for the syntax of site-list.~bonds~site-list: prints out table only for triples whose neighbors are in site-list.

Example: --angles~sites~1,2~bonds~style=2~z==34 finds triples of atoms connected to sites 1 and 2. Both sites connected to the central site must have atomic number 34 (Selenium) /tutorial/lmf/molstat/#11-bond-lengths-and-angles

Euler angles must be supplied either in the input file, or in the Euler angles file eula.ext (in the standard Questaal format). Options are delimited by ~ (or the first character following --shell):~r=rmax[,rmin]: Include in table only pairs closer than rmax. If rmin is also given, exclude pairs closer than rmin.~sites~site-list: include only sites in site-list. See here for the syntax of site-list.~sign: If present, rotate angle by 180° for each member of the pair whose magnetic moment is negative.

tells lmchk to use an algorithm to determine augmentation sphere radii. Results are printed to stdout; you must modify the input file by hand.

--mino~z | --mino~site-list

tells lmchk to shuffle atom positions in site-list to minimize some simple function of the overlap. (For now, the function has been set arbitrarily to the sixth power of the overlap).--mino~z : construct list from all sites with atomic number Z=0--mino~site-list : list of sites; see here for site-list syntax.

--terse

print minimum information about overlaps. Writes the site positions to file.ext

#1=0: do not read the restart file on the initial iteration, but overlap free-atom densities. Requires atm.ext.

#1=1: read restart data from binary rst.ext

#1=2: read restart data from ascii rsta.ext

#1=3: same as 0, but also tells lmf to overlap free-atom densities after a molecular statics or molecular dynamics step.

Add 10 to additionally adjust the mesh density to approximately accommodate shifts in site positions relative to those used in the generation of the restart file. See --rs switch #3 below for which site positions the program uses.

Default switches: --rs=1,1,0,0,0. Enter anywhere between one and five integers; defaults are used for those not given.

--band[~options]

tells lmf (or any program accepts --band to generate energy bands instead of making a self-consistent calculation. The energy bands (or energy levels) can be generated at specified k-points in one of three formats, or modes.

Symmetry line mode is designed for plotting energy bands along symmetry lines. In this case k-points are specifed by a sequences of lines with start and end points. The output is written in special format that plbnds is designed to read. This is the default mode; alternatively you can select the list or mesh modes:

The list mode is a general purpose mode to be used when energy levels are sought at some arbitrary set of k-points, specified by the user. Data is written in a standard Questaal format with k-points followed by eigenvalues.

The mesh mode generates states on a uniform mesh of k-points in a plane. Its purpose is to generate contour plots of constant energy surfaces, e.g. the Fermi surface. Data file output is written in a standard Questaal format designed for contour plots.

Unless you otherwise specify, input file specifing the k points is qp.ext, and the output written to bnds.ext for all three modes.

Options below are delimited by ~ (or the first character following --band):

~qp: list mode. An arbitrary list of k points can be specified. See here for the input file format.

~con: mesh mode for contour plot. k-points are specified on a uniform 2D grid; data is written for a specified list of bands. See here for input file format in this mode.

~bin: write bands as a binary file, file name bbnds.ext. Works only with ~qp and ~con modes.

~fn=fnam: read k points from file fnam.ext. Default name is qp.ext.

~ef=#: Use # for Fermi level.

~spin1: generate bands for 1st spin only (spin polarized case)

~spin2: generate bands for 2nd spin only (spin polarized case)

~mq: q-points are given as multiples of reciprocal lattice vectors. Applies to symmetry line and qp-list modes only.

~col2=orbital-list generate a second weight to orbitals specified in a list. With this option you can create bands with a second independent color.

~col3=orbital-list generate a third weight to orbitals specified in a list. With this option you can create bands with three independent colors.

~colst | ~colst=orbital-list generates four color weights corresponding to charge and x,y,z spin components of the magnetization Addition of orbital-list has the same meaning as for usual color weights: each weight is computed from the Mulliken projection of orbitals included in the list. This switch is conveniently used together with plbnds and the --fplot~spintexture flag.

The col option tells the band generator to save, in addition to the energy bands, a corresponding weight for each energy. Each band is resolved into individual orbital character by a Mulliken decomposition The sum of Mulliken weights from orbital-list is the weight assigned to a state. Thus if orbital-list contains all orbitals the weights will be unity. There is an example in the plbnds documentation, which shows how to use that utility to make plots with color weights.

colst is designed to resolve magnetization directions for the noncollinear cases. The four color weights correspond to projections onto the 2×2 unit matrix, and the three Paul spin matrices σx, σy, σz. In the absence of orbital-list the first weight should be unity (unit norm of eigenvector), and the remaining three the x, y, and z components of the magnetization of that state. See the spin texture example in the plbnds documentation.

Note:tbe does not yet possess color weights capability.

The individual orbitals make up the hamiltonian basis. States specified in orbital-list corresponding to the ordering of the orbitals in the hamiltonian. You can get a table of this ordering by invoking lm|lmf --pr55 --quit=ham .... Choose orbital-list from the orbitals you want to select out of the Table.

This list can sometimes be rather long and complex. To accomodate this, some simple enchancements are added to the standard integer list syntax.

tells lmf to read site positions from fnam.ext after the input file has been read. fnam.ext is in standard Questaal format

--wpos=fnam

tells lmf to write site positions to fnam.ext after self-consistency or a relaxation step.

--pdos[~options] | --mull[:options]

tells lmf to generate weights for density-of-states or Mulliken analysis resolved into partial waves. Options are described here.

--optbas[~sort][~etol=#][~spec=spid[,rs][,e][,l=###]…]

Operates the program in a special mode to optimize the total energy wrt the basis set. lmf makes several band passes (not generating the output density or adding to the save file), varying selected parameters belonging to tokens RSMH= and EH= to minimize the total energy wrt these parameters. Options are delimited by ~ (or the first character following --optbas):

etol=#: only adjust parameter if energy gain exceeds #.

No species given: lmf optimizes wrt RSMH in each species.

spec=spid,rs: Optimize wrt RSMH for a particular species.

spec=spid,e: Optimize wrt EH for a particular species.

spec=spid,rs,e: Optimize wrt both RSMH and EH for a particular species.

spec=spid…,l=###: Specify which l to optimize (default is all l in the basis)

sort: sort RSMH from smallest to largest. The total energy is more sensitive to small RSMH;, then the most important parameters are optimized first.

--rdbasp[:fn]

tells the program to read basis parameters from file fn. If not present, fn defaults to basp.ext. This supersedes settings in HAM_AUTOBAS.

--wden[~options]

tells lmf to write the charge density to disk, on a uniform of mesh of points. At present, there is no capability to interpolate the smoothed density to an arbitrary plane, so you are restricted to choosing a plane that has points on the mesh. Options syntax:[~fn=filenam][~core=#][~spin][~3d][~ro=#1,#2,#3][~o=#1,#2,#3][~q=#1,#2,#3][~lst=band-list][~l1=#1,#2,#3,[#4]][~l2=#1,#2,#3,[#4]]

Information for the plane is specified by three groups of numbers: the origin (o=), i.e. a point through which the plane must pass; a first direction vector l1 with its number of points; and a second direction vector l2 with its number of points. Default values will be taken for any of the three sets you do not specify. The density generated is the smooth density, augmented by the local densities in a polynomial approximation (see option core)

To comply with this restriction, all three groups of numbers may be given sets of integers. Supposing your lattice vectors are p1, p2, and p3, and the smooth mesh has (n1,n2,n3) divisions. Then the vector (l1=#1,#2,#3) corresponds tov1 = #1/n1 p1 + #2/n2 p2 + #3/n3 p3 Specify the origin (a point through which the plane must pass) by~o=i1,i2,i3 Default value is o=0,0,0. Alternatively you can specify a the origin in Cartesian coordinates by:~ro=x1,x2,x3 (x1,x2,x3) a vector in Cartesian coordinates, units of alat, and it is converted into the nearest integers i1,i2,i3. Thus the actual origin may not exactly coincide with (x1,x2,x3).

Options are delimited by ~ (or the first character following --wden):

~l1=#1,#2,#3[,#4] first direction vector as noted above, that is:#1,#2,#3 select the increments in mesh points along each of the three lattice vectors that define the direction vector. The last number (#4) specifies how many points to take in this direction and therefore corresponds to a length. Default values : l1=1,0,0,n1+1 where n1 is the number of points on the third axis.

~l2=#1,#2,#3[,#4] second direction vector as noted above, and number of points (#4) Default values : l2=0,1,0,n2+1 where n2 is the number of points on the second axis.

core=# specifies how local densities are to be included in the mesh. Any local density added is expanded as polynomial * gaussian, and added to the smoothed mesh density.

#=0 includes core densities + nuclear contributions

#=1 includes core densities, no nuclear contributions

#=2 exclude core densities

#=-1 no local densities to be included (only interstitial)

#=-2 local density, with no smoothed part

#=-3 interstitial and local smoothed densities Default: core=2

fn=filnam specifies the file name for file I/O. The default name is smrho.ext

3d causes a 3D mesh density to be saved in XCRYSDEN format

q=q1,q2,q3 and lst=list-of-band-indices These switches should be taken together. They generate the density from a single k-point only (at q) and for a particular set of bands. Use integer list syntax for list-of-band-indices.

Example: suppose n1=n2=48 and n3=120. Then--wden~fn=myrho~o=0,0,60~l1=1,1,0,49~l2=0,0,1,121 writes to myrho.ext a mesh (49,121) points. The origin (first point) lies at (p3/2) since 60=120/2. The first vector (l1=1,1,0,49) points along (p1+p2) and has that length (48+1); the second vector points along p3 and has that length.

Example: suppose the lattice is fcc with n1=n2=n3=40. Then--wden~q=0,0,0.001~core=-1~ro=0,0,.25~lst=7~l1=-1,1,1,41~l2=1,-1,1,41 generates the smoothed part of the density from the 7th band at Γ, in a plane normal to the z axis (q=0,0,0.001 is slightly displaced off Γ along z), passing through (0,0,0.25).

--cv:lst | --cvK:lst

Calculate electronic specific heat for a list of temperatures. You must use Brillouin sampling with Fermi function: BZ_N=−1. Data is written to file cv.ext.

--wforce=fn]

causes lmf to write forces to file fn.

--ef

Override file Fermi level; use with --band

--efrnge

Print out indices to bands that bracket the Fermi level

--no-fixef0

Do not adjust estimate of Fermi level after first band pass

--oldvc

chooses old-style energy zero, which sets the cell average of the potential to zero. By default average electrostatic potential at the augmentation boundary is chosen to be the zero. That puts the Fermi level at roughly zero.

Makes SO-weighted average of electric field at each site. Used for estimating size of Rashba effect.

--vext~step[~options…]~v=# | --vext~igv[~options…]~v=#

An external potential is added to the LDA hamiltonian. The size of the external potential is given by the argument following (~v=). (Options are delimited by the first character following --vext, which is assumed to be ~ in this description.)

is specified by a rule which can assume one of two forms (in reciprocal space, through --vext~igv~…, or in real space, through --vext~step~…). In either case is symmetrized by whatever symmetry operations are used.

The~epsand ~eps=# _options For either style, you may add an optional switch ~eps or ~eps=#. This will cause lmf to print an analysis of the response function. This analysis is printed at each iteration in the self-consistency cycle.

For the input density it prints a table including the static inverse dielectric function defined as , in a table like the following:

In this case (called phiext in the table) has two Fourier components, which correspond to two points (kv) on the density mesh (reciprocal space). Note: index 1 corresponds to k=0 along the direction of that lattice vector.

For the output density a table is printed including the response function, defined as , in a table like the following:

The analysis applies if either ~eps or ~eps=eps0 is specified. The latter option has an additional feature, namely at the starting iteration it estimates the screening charge for a dielectric constant you specify by eps0. It assumes that, for each Fourier component, . It will print out a table similar to the following:

To calculate the perturbation there has to be a memory of the initial unperturbed potential (density). lmf keeps track of the intial potential. If you begin execution from a self-consistent density for the unperturbed case, at self-consistency the difference in starting and final potential are indeed the perturbation. However, if you start from a different density, e.g. the self-consistent density after the perturbation was added, or a density modified with ~eps=#, the perturbation lmf prints out is fictitious.

The ~pot0 switch makes it possible to retain an original potential so perturbations can be properly calculated. Including this switch causes lmf to write whatever Hartree potential it has generated from the given density to file smpot0.ext, and exit.

Any subsequent invocation of lmf with --vext~eps will cause the reference potential and density to be read from this file, and the perturbation is calculated as the change in the current potential (density) relative to the reference potential (density) stored in smpot0.ext.

Specifying with a single Fourier component

The syntax is : --vext~igv=#1,#2,#3[~eps[=#]][~pot0]~v=#

~igv=#1,#2,#3 defines a particular k point, by . , , and are the number of divisions along each of the three reciprocal lattice directions. This information is printed at the start of execution: in this example, it prints out

Evidently has nonzero points (1,1,2) and (1,1,88), which correspond to the first and last points along . It was specifed by --vext~igv=0,0,1; to make the potential real two Fourier components are required, corresponding to mesh points (1,1,2) and (1,1,88). Note: in the specification indexing starts at 0, while the indexing of the mesh density starts at 1.

Example : –vext~igv=0,0,1~eps=3~v=.02

Specifying in real space

At present the available option is to specify a step potential for a family of adjacent planes. The minimum syntax is : –vext~step=#~l1=#1,#2,#3~l2=#1,#2,#3~v=#\

~step=# tells lmf how many planes the potential spans. You can use ~stepx=# in place of ~step=#: this shifts the average perturbation to zero.

~l1 and ~l2 define points in a plane in the same manner as described for the --wden switch. The first plane can also be specified with [~ro=#1,#2,#3] or [~o=#1,#2,#3] as described there.

~v=# gives the size of the step.

You can use the ~eps, ~eps=#, and ~pot0 options in this mode.

Example : –vext~stepx=44~o=0,0,22~l1=1,0,0~l2=0,1,0~eps=3~v=.02

With a mesh density of 16×16×88 divisions and the following lattice vectors:

Reads/writes the l=0 part of sphere densities and potential to atmx.ext. This file has the same form as the atomic file atm.ext generated by lmfa. However the spherical density and spherical potential V0 are taken from lmf’s current contents, e.g. the self-consistent density. By reading data from atmx.ext you can start with a a better trial density when overlapping “atoms” Also, V0 is used to make partial waves φl. If also V0 is frozen (e.g. using HAM_FRZWF=t), the partial waves are constructed from this information, when V0 is read from this file.

--wrhoat

Write partial atomic densities to atom files.

--wrhomt | --wpotmt

Not documented yet.

--zhblock~block[~~block…]

Zeros out or scales selected rows and columns of off-diagonal parts of the hamiltonian and overlap matrices. Diagonal parts are retained, though there is an option to set them through this switch. Both the hamiltonian and overlap matrix are modified.

For a single block a list of rows and columns must be specified; there is some some flexibility in how this is accomplished as described below. You can modify multiple blocks by successive block specifications. Different blocks are separated by a double delimiter. The delimiter is the first character after --zhblock (assumed to be ~ in this documentation).

For one block, specify the list of (row,column) pairs using one of the following forms. ilist is described below; h is the hamiltonian and s is the overlap matrix.

~rows=ilist For each i and j in ilist, each h(i,j) is zeroed (or scaled by a factor f) for i≠j. Thus ilist applies to both rows and columns.

~cols=ilist Has the same effect as 1.

~rows=ilist1~cols=ilist2 Similar to 1, but the block is comprised of rows in ilist1, columns comprised of elements in ilist2.

~ilist1 Similar to 3, but ilist2 is taken to comprise the entire hamiltonian. All elements in ~ilist are completely isolated from the rest of the hamiltonian; that is, h is diagonal for those elements.

The diagonal elements i=j are left untouched by default. To set them, include ~e=#1[,#2] in the block specification. #1 specifies the eigenvalue of spin 1, #2 the eigenvalue of spin 2, if it is supplied (if not, #1 is used for both spins). If e is given s(i,i) will be left untouched while h(i,i) is set to e×s(i,i), so that (if the element has no coupling to any other element, as in specification type 4) the hamiltonian will yield an eigenvalue e. for each i.

The scale factor f is zero, by default. To specify it, include ~s=f in the block specification.

ilist is an integer list of orbitals in the hamiltonian; integer lists are described here. To see how the basis is ordered, run lmf with

lmf --pr55 --quit=ham ...

and inspect the table following this header:

Orbital positions in hamiltonian, resolved by l:

Further notes

For each (i,j) modified, (j,i) is modified in the same manner so that h and s remain hermitian.

e can be one or two numbers, so that the majority and minority spins can be scaled differently. If the second number is not specified e(1) is used for both spins.

f can be one or two numbers, corresponding to hamiltonian and overlap. If neither number is specified, f=0 for both h and s. If the second number is not specified, elements in the overlap are set to zero.

Caution: since both h and its hermitian conjugate are scaled, elements of h that belong to both ilist1 and ilist2 get scaled twice (this may change in future). This matters only if f is not zero.

If no list is specified in a block, --zhblock does nothing for that block and exits without parsing for more blocks.

Note that basis sets often have more than one orbital per l. To isolate a particular l or lm, include all basis functions with a particular (site, l) or (site, lm) in ilist.

Example 1 (specification type 4):

~e=-1.5,1.4~10:16

h(10:16,:) and h(:,10:16), and s(10:16,:) and s(:,10:16) are zeroed out except for the diagonal elements. The diagonal elements of s are left untouched. The diagonal elements of h(i,i) for i=10:16 are set to -1.5×s(i,i) for the majority spin and +1.4×s(i,i) for the minority spin. As a result 7 eigenvalues will be -1.5 Ry for spin 1, and +1.4 Ry for spin 2.

Example 2 (multiple blocks):

~rows=5,6,8~s=.5~~rows=7,9~s=0

Scales the off-diagonal elements between t2g orbitals (5,6,8) by 0.52, and sets the off-diagonal elements between eg orbitals to zero.

Read or write matrix elements of the square of the velocity operator |v|2 to file optdata.ext.

Data is read or written for each band pair, k point, and spin (optical matrix elements).

|v|2 is symmetrized according to the given symmetry operations.

In the read case, the band pass is skipped and the band code proceeds directly to making the dielectric function (or a similar property).

In the write case, the band pass is skipped and the band code exits after writing; the dielectric function is not made.

--opt:woptmc | --opt:woptmc,rdqp

Writes the matrix elements both of the velocity operator v and |v|2, to file optdatac.ext.

|v|2, is symmetrized, but v is not.

Addition of modifier ,rdqp causes lmf to read the k-points from qpts.ext.Note: to cause lmf to read the k-points in the same order that the GW codes require them, run lmfgwd with --job=6 or --job=7. and run lmf with --opt:woptmc,rdqp. This is necessary when setting up the velocity operator for Bethe-Salpeter equation.

See optics documentation.

--cls[.ib,l,n[.ib,l,n][.lst=list,l,n][.fn=file]]

Core level spectroscopy. After lmf completes, follow up the calculation with lmdos to generate a DOS-like file. The theory used for this switch is described in J. Phys.: Condens. Matter 12 (2000). To carry out CLS calculations in a potential containing a core hole, see tags SPEC_ATOM_C-HOLE and SPEC_ATOM_C-HQ when making the self-consistent density.

You must supply a list of core levels (site, l, and principal quantum number n) for which to calculate CLS. Do it in one of three ways, through modifiers. Modifiers are separated by '.' (any separator will do, e.g. '#', other than ':' or ',').

Demonstration: This makes CrN self-consistent with a core hole on a N 1s state, and performs CLS calculation in that potential. It corresponds to a ‘sudden approximation’ (system relaxes instantanously from electron ejected out of a core hole). In your build directory do

./fp/test/test.fp crn

The CLS is written to a file in the DOS format. The script will ask you if you want to draw a figure of the CLS.

Optics editor — built into lmf; see here for an instance of its usagex

--wsig~edit

QSGW self-energy editor

The following switches affect howlmfreads, writes, or modifies the QSGW self-energy Σ0.Note: Σ0 is stored in practice as , so that this potential can be added to the LDA potential.

--mixsig=#1[,#2]

lmf reads QSGW self-energy Σ0 from two files, sigm.ext and sigm1.ext. For Σ0 it takes the linear combination #1×sigm.ext + #2×sigm1.ext. If #2 is missing, it does not read sigm1.ext but scales Σ0 by #1.

--rsig[~options]

Tells lmf about the form of the input self-energy file.

Options are delimited by ~ (or the first character following --rsig).

~ascii: read from file sigma in ASCII format (see table below)

~rs: read in real space (see table below)

~null: generate a null consistent with the hamiltonian dimensions. Useful in combination with the sigma editor.

~fbz: flags that is stored for all k points in the full Brillouin zone. Equivalent to setting 10000s digit=1 in token RDSIG= . (Not meaningful if the ~rs switch is used)

~spinav: average spin channels in spin-polarized sigma

~rlxkp: when reading , do not impose requirement that each k correspond to the file k. Not generally advised, but useful in certain contexts, e.g shearing a lattice.

~shftq=#,#,# indicates that sigma was generated on a kmesh offset by #,#,# #,#,# are optional; then a default of three small numbers is used.

If either ~ascii or ~rs is used, the input file name may change:

k-space

real-space

binary

sigm

sigmrs

ascii

sigma

sigmars

--wsig[~options]

Writes a possibly modified QSGW self-energy to sigm2.ext and exits.

Options are delimited by ~ (or the first character following --wsig):

~ascii: read sigm in ascii format (see table below)

~newkp: generate sigma on a new k mesh. It reads the mesh from GW_NKABC.

~edit: invoke the sigma editor. This editor has many options, which you can see by running the editor.

~fbz: causes lmf to ignore symmetry operations and generate a sigma file for k-points in the entire BZ. It is useful when generating a sigma file that allows fewer symmetry operations, e.g. when making the m-resolved density-of-states, or a trial sigm for a case (such as a shear) where symmetry operations are lowered.

driver mode: make interface to the GW code: files gwb.extgw1.extgw2.extgwa.extvxc.extevec.extnormchk.extrhoMT.*.

--vxcsig

Write QSGW Σ0 in place of LDA exchange-correlation potential into vxc file. Use this switch when you are performing 1-shot GW calculations as a perturbation around the QSGW potential: the perturbation is Σ−Σ0.

--shorbz=no

Suppress shortening of k-points.

The following switches apply to GWinput creation mode (--job=−1):

--gwin0

Read parts of GWinput template from GWin0. Portions of GWin0 may substitute for corresponding parts in GWinput.

The GWinput syntax is roughly similar to the standard Questaal format but the syntax is more restricted. GWinput has categories but they are delimited by <name> and have a predetermined order. Also the first (Header) category has no delimiter.

GWin0 has the same structure as GWinput, but only parts of it are read and substituted for GWinput. The following subsitutions (arranged by category) are permitted:

Header (comments and tags at the top of the file, preceding the <PRODUCT BASIS> category. The header is read from GWin0 and used in place of GWinput. Next, the following line is written to GWinput:

! Supply possible tags not found in GWin0

As the GWin0 file is read, the following tags are logged:

GWversion

KeepEigen

KeepPPOVL

BZmesh

WgtQ0P

NormChk

n1n2n3

QpGcut_psi

QpGcut_cou

unit_2pioa

alpha_OffG

emax_sigm

dw

omg_c

iSigMode

niw

delta

deltaw

esmr

rsm

GaussSmear

Any tags in this list not logged are written to GWinput. in the same form that they would have been otherwise written.

Product basis section, which begins with delimiter <PRODUCT_BASIS>. These lines follow the delimiter:

tolerance = minimum eigenvalue in PB overlap to reduce linear dependency
[one or more floating point numbers]
lcutmx(atom) = l-cutoff for the product basis
[sequence of integers, one for each atom]

If tolerance is present in GWin0, that line and the line following are substituted for the two lines that would normally be written.

If lcutmx(atom) and the following line are present in GWin0, they are substituted for the two lines that would normally be written.

QPNT section, which begins with delimiter <QPNT>.

If the following line is present in GWin0, it and the one following it are substituted for the two lines that would otherwise be written.

*** Sigma ...

If the following line is present in GWin0, it and the pair following it are substituted for the three lines that would otherwise be written.

*** no. ...

If the following line is present in GWin0

*** q-points ...

it and all subsequent lines to to the end-of-section (delimited by </QPNT>) are written to GWinput.

Example

Make a GWinput template in the usual way and copy it to GWin0, e.g.

lmfgwd --job=-1
cp GWinput GWin0

Run lmfgwd again with the switch --gwin0 and compare GWinput to GWin0:

lmfgwd --job=-1 --gwin0
diff GWinput GWin0

They should differ only in that an additional line is written to GWinput.

! Supply possible tags not found in GWin0

Remove or modify various parts of GWin0 and see how GWinput changes.

--sigw

Add lines to GWinput needed to make the dynamical self-energy, Σ(ω).Note: With these modifications the 1-shot self-energy maker, hsfp0, must be run with --job=4. They do not affect QSGW self-energy maker, hs0fp0_sc.

--ib=list

Specify list of QP levels for which to make sigma (for 1-shot case only)

Switches for lm

causes lm to read atomic data from a restart file rsta.ext. By default the ASA writes potential information, e.g. logarithmic derivative parametersP and energy moments of chargeQ for each class to a separate file. If #1 is nonzero, data is read from rsta.ext, superseding information in class files. If #2 is nonzero, data written rsta.ext.

--band[~options]

tells lm to generate energy bands instead of making a self-consistent calculation. See here for options.

--pdos[~options]

tells lm to generate weights for density-of-states or Mulliken analysis resolved into partial waves. Options are described here

--zerq[~options]

Invokes lm’s charge neutrality enforcer. One of the options must be a prescription for a list of classes. Ways of specifying a class list

Switches for lmgf

To obtain the charge density or other integrated properties, lmgf requires an energy integration in addition to the k integration. The Fermi level must be found by iteration; alternatively (which is what this code does), it shifts the system by a constant potential to reach the prescribed Fermi level.

Switches for lmdos

lmdos is a postprocessing step that generates partial densities-of-states. It reads the weights file moms.ext generated by another program and makes partial contributions to the total DOS. Partial dos can be computed either with tetrahedron integration or with gaussian samplingmoms.ext must be made in advance by a generating program, typically lmf, lm or tbe.

How channels for partial DOS are specified depends on the context. Typically you generate moms.ext specifying channels with --pdos. lmdos expects the DOS to be ordered as specified by the switch. lm will generates moms.ext even without --pdos, and orders the channels by class. If you invoke lmdos without --pdos, it assumes the ASA ordering.

Otherwise it assumes the weights are generated and stored by class. This works with lm and tbe, but otherwise, generate moms.ext with --pdos or something similar.

lmdos doesn’t need to know what the origin of the channels is; it simply reads the number of channels from the weights file. However, to assist you in making an identification of the channels with atom-centered functions, it will print out what it thinks the connection is.Caution:lmdos may print out if you use the generating program inconsistently with it.

lmdos has a variety of options; for example it can generate the ballistic conductivity as matrix elements of the velocity operator.

Either of the following switches causes the generating program (lmf, lm, or tbe) to create moms.ext

Specifies the channels for which partial DOS are generated or analyzed.Note: this switch applies to the both the generating program and lmdos. Use the same arguments for generating and postprocessing.--pdos partial DOS--mull Mulliken DOS Options are delimited by ~ (or the first character following --pdos):

~group=lst1;lst2;…: DOS for a list of groups. A group can consist of one or more sites, which are combined to make a single channel.

~nl=#: a global l cutoff: l are written to maximum value of #−1.

~lcut=l1,l2,…: l-cutoff for each group or site in the group or site list.

Example from the pldos manual : --pdos~mode=2~group=1:3;4:9~lcut=2,1 makes DOS for sites 1:3 combined for the first channel, sites 4:9 for the second. DOS is resolved by l and m (mode=2), with l=0,1,2 for the first group and l=0,1 for the second. See also this tutorial.

--dos~options

Various options that affect the action of lmdos (some elements apply to lmf for the total DOS). Options are delimited by ~ (or the first character following --dos):

bands=list: compute contribution to DOS from a prescribed list of bands.

classes=list: generate DOS for a specified list of classesCaution: this option is only compatible with default moments files generated by the ASA, which stores dos weights by class. It is incompatible with the --pdos switch which stores weights by site.

Example: compute the ballistic conductance in the z direction over an energy range (-0.8,0.5)Ry:--dos:mode=1:npts=501:window=-.8,.5:vec=0,0,1

Rearrange order of sites in the supercell. (ring) shifts sites i1…i2-1 to one position higher, and site i2 cycles to position i1. (swap) swaps pairs i1 and i2 (sort) Sorts the basis by ordering algebraic expressions associated with them. Expressions can use Cartesian components x1, x2, x3, e.g. --sort:’x3 x2’. Optional expr2 sorts subsets of sites with equivalent values of expr1, similarly for expr3.

--sites:site-list

Make supercell of subset of sites in original basis. See here for site-list syntax.

--rsta | –rsta,amom

(ASA only) Makes ASA restart file for the supercell from existing file rsta.ext. Optional amom applies to noncollinear magnetism: it flips the majority and minority spins for sites where the magnetic moment is negative, while rotating the Euler angle by 180°

--shorten

shorten basis vectors.

--pl:expr

(for lmpg code) Assign principal-layer index according to expr. Sites with equivalent values of expr are assigned the same PL index.

--wrsj[~fn=name][~scl=#]

Writing the pairwise exchange parameters of the supercell generated, e.g., from lmgf. Input file rsj.ext must be present.

--disp~fnam~site-list

Displace a set of atoms in the neighborhood of a given one, e.g. --disp:tab2:style=3:Fex Use in conjunction with lmchk command line argument (--shell~tab=2~disp=file). See here for site-list syntax.

--sqs[~seed=#][~r2max=#][~r3max=#][~r3mode=#]

Make a Special QuasiRandom Structure. It works by minimizing a norm function. The norm is obtained by assigning a weight to each pair and three body correlator, and summing the individual weights.

Options are delimited by ~ (or the first character following --shell):~seed=#: initial seed for random number generator. For a fixed seed the algorithm proceeds the same way each time.~r2max=#: Maximum distance between pairs for pair participate in the norm~r3max=#: Maximum sum of legs between for triples to participate in the norm.

Switches for lmfgws

lmfgws is the analyzer of the dynamical GW self-energy. You need to create the self-energy first and set up the input file (se) using spectral. See this tutorial.

–sfuned Run the spectral function editor. Its usage is documented in this tutorial. There is also a help mode when you run the editor interactively.

Switches for lmfdmft

lmdmft serves both as an interface linking lmf with DMFT solvers, and as a means to extract results given a DMFT-generated self-energy.lmdmft requires an extra input file, indmfl.ext, that specifies the correlated orbitals and other conditions for DMFT calculations.

The DMFT code will generate a self-energy for the correlated channels. In the interface to Haule’s CTQMC code, this file is called sig.inp. If sig.inp is missing, lmdmft will make template for a Matsubara frequencies specified in the ctrl file, and populate the DMFT self-energy with 0.

--gprt[~rdsigr=fn][~rdsigr=fn][~mode=#][~band[@flags]][~nom=#]: Write local Green’s function gloc to disk. Options are delimited by the first character following --gprt ( ~ in this case).

~rdsigr=fn reads frequencies and self-energy from file fn. Frequencies are taken to be real.

~rdsig=fn reads frequencies and self-energy from file fn. Frequencies are taken to be Matsubara frequencies (imaginary). If you do not read frequencies, the code will use the standard (Matsubara) frequencies that build the hybridization function.

~mode=# choose from the following:

#=1 k-integrated gloc (this is the default)

#=2 k-resolved gkloc (output in gkloc.ext)

#=3 both 1 and 2

#=4 k-resolved hkloc (output in hkloc.ext)

#=8 k-resolved G in the basis of 1-particle eigenfunctions (output in gk.ext)

#=18 write diagonal in the basis of 1-particle eigenfunctions (output in se.ext)

#=19 write diagonal in the basis of 1-particle eigenfunctions (output in se.ext)

#=20 Like 19, but an effective diagonal sigma defined from diagonal part of matrix gij. Causes g computed from diagonal sigma to match diagonal gij.

~nom=# calculate G only for the first # points.

~band[@flags] generates the self-energy for an independent set of k points, specified through the options modifying band. Flags are identical to those following the --band switch, and delimited by the first character following band ( @ in this case). It must be distinct from the delimiter to --gprt.

--dos: Make dos (not documented; also implementation is correct only when sigma is static).

Switches for spectral

spectral is a postprocessor of the raw GW dynamical self-energy files SEComg.UP and SEComg.DN. Its main purpose is to translate self-energies generated by the GW self-energy maker hsfp0, into an input file se.ext that the dynamical self-energy analyzer, lmfgws, can read.

spectral also has a limited ability to make spectral functions, and most of its command-line switches are intended for that purpose.

Note on interpolation: the spectral function is only reliable on a fine energy mesh. Unless many-body effects are very pronounced (rare in a GW context), varies smoothly with ω and can be interpolated to a fine mesh. nw and domg are designed to interpolate Σ. If you want to interpolate, choose one or the other.

If you are using spectral only to make se for lmfgws, it is better not to interpolate and use --nw=1.

Switches:

--ws | --ws:x Does no analysis but write a self-energy file (se) for all k, suitable for reading by lmfgws.--ws:x performs the same function but also writes the exchange potential to se.ext.Note: when using this switch, --nw=1 is advised, since lmfgws can do its own interpolation.

Switches for symlinepoints

symlinepoints is a script that structures a file containing k point information into Questaal’s symmetry lines format. The symmetry lines file is used to generate energy band structures. You can supply k points in one of several possible forms.

This script is self-documenting. For help, run symlinepoints with no arguments or with --h, viz

$ symlinepoints --h

Switches are:

-nk=# Specify number of k-points on a line as (length of line)×#. This is useful because points on each line will be have approximately the same spacing.

-qlat=qfile | -qlatl=qfile Specify that each k-point is a multiple of the reciprocal lattice vectors (RLV).qfile is a file containing is a 3×3 matrix (9 elements) with elements ordered as follows:

Qx1 Qy1 Qz1 Qx2 Qy2 Qz2 Qx3 Qy3 Qz3

Questaal codes print out the RLV in this order. You can create qfile by doing, e.g.

-qlat and -qlatl both interpret input k points as multiples of the reciprocal lattice vectors. The former writes them out as Cartesian coordinates, while the latter as multiples of RLV. Note: if the symmetry lines file contains k points in multiples of the RLV, be sure to generate the bands with --band~mq .

Switches for tbe

--st: start new MD run (otherwise strt is read); begin new md, mv and xyz files

--md=#: in MD write info to the md file every # timesteps

--mc=#: in MD or static relaxation write to the xbs mv file every # steps

--xyz=#: in MD or static relaxation write to a standard xyz file every # steps

--leanrho: in MPI, try to save memory at the expense of some communication

The following switches apply to MPI process mapping options. In most cases the default mapping is the optimal choice.

--kblocks: Number of rectangular processor blocks over which to distribute the k-points

--nprows: Number of rows of the ScaLAPACK/BLACS process arrays/blocks.

Switches for lmxbs

lmxbs generates input for the graphics program xbs, a program written by M. Methfessel, which draws cartoons of crystals. See this page.

Command-line switches:

-bs=expr: factor that scales the default ball (sphere) size. This factor scales SPEC_RMAX by expr**. By default, the scaling is 0.5.

-ss=expr: controls the criterion for what length defines a connected bond. This switch scales the default factor scaling a ‘bond length’ which must be closer than RMAXi+RMAXj.

-shift=x1,x2,x3: shifts all the coordinates by this amount, in units of ALAT.

-scale=val: sets the xbs variable scale.

-spec: shifts Organize sites by species (e.g. colors). By default sites are organized by classes.

-sp:rule1[:rule2][…]: modifies the species rmax and colors.rule has the syntaxexpr,rmax,red,green,blueexpr is a logical expression involving the class index ic and atomic number z. If expr evalates to true, the rule applies to this class. rmax, red, green, blue are the ball size, and RGB colors for the ball. Default values are taken for those numbers omitted. For the colors, the defaults are random numbers between 0 and 1.

-dup=n1,n2,n3[,expr]: duplicates the unit cell n1+1,n2+1,n3+1 times in the three lattice directions. Optional expr is a constraint. If expr is present, sites whose for which expr is zero are excluded. Variables that may be used in expr are:

Site-list syntax

Site-lists are used in command-line arguments in several contexts, e.g. in lmscell, lmgf’s exchange maker, and lmchk’s --shell and --angles switches. For definiteness assume ~ is the delimiter and the segment being parsed is sites~site-list.sites~site-list can take one of the following forms:

sites~list

list is an integer list of site indices, e.g. 1,5:9. The syntax for integer lists is described here.

sites~style=1~list

list is an integer list of species or class indices (depending on the switch).

All sites which belong a species in the species (or class) list get included in the site list.

~style=2~expr

expr is an integer expression. The expression can involve the species index is (or class index ic) and atomic number z. The species list (or class list) is composed of members for which expr is nonzero. All sites which belong a species in the species (or class) list form the site list.

~style=3~spec1,spec2,…

spec1,spec2,… are a string of one or more species names. The species list (or class list) is composed of species with a name in the list.

All sites which belong a species in the species (or class) list form the site list.

Note: some ASA-specific switches refer to class-list. The structure is identical to the construction above, except that the class list is not expanded into a site list.