next up previous
Next: alter_elements Up: User's Manual for elegant Previous: Fiducialization in elegant

Namelist Command Dictionary

The main input file for an elegant run consists of a series of namelists, which function as commands. Most of the namelists direct elegant to set up to run in a certain way. A few are ``action'' commands that begin the actual simulation. FORTRAN programmers should note that, unlike FORTRAN namelists, these namelists need not come in a predefined order; elegant is able to detect which namelist is next in the file and react appropriately.

Each namelist has a number of variables associated with it, which are used to control details of the run. These variables come in three data types: (1) long, for the C long integer type. (2) double, for the C double-precision floating point type. (3) STRING, for a character string enclosed in double quotation marks. All variables have default values, which are listed on the following pages. STRING variables often have a default value listed as NULL, which means no data; this is quite different from the value ``'', which is a zero-length character string. long variables are often used as logical flags, with a zero value indicating false and a non-zero value indicating true.

On the following pages the reader will find individual descriptions of each of the namelist commands and their variables. Each description contains a sequence of the form

&<namelist-name>
    <variable-type> <variable-name> = <default-value>;
    .
    .
    .
&end
This summarizes the parameters of the namelist. Note, however, that the namelists are invoked in the form
&<namelist-name>
    [<variable-name> = <value> ,]
    [<array-name>[<index>] = <value> [,<value> ...] ,]
        .
        .
        .
&end
The square-brackets enclose an optional component. Not all namelists require variables to be given-the defaults may be sufficient. However, if a variable name is given, it must have a value. Values for STRING variables must be enclosed in double quotation marks. Values for double variables may be in floating-point, exponential, or integer format (exponential format uses the `e' character to introduce the exponent).

Array variables take a list of values, with the first value being placed in the slot indicated by the subscript. As in C, the first slot of the array has subscript 0, not 1. The namelist processor does not check to ensure that one does not put elements into nonexistent slots beyond the end of the array; doing so may cause the processor to hang up or crash.

Wildcards are allowed in a number of places in elegant and the SDDS Toolkit. The wildcard format is very similar to that used in UNIX:

The special characters *, ?, [, and ] are entered literally by preceeding the character by a backslash (e.g., \*).

In many places where a filename is required in an elegant namelist, the user may supply a so-called ``incomplete'' filename. An incomplete filename has the sequence ``%s'' imbedded in it, for which is substituted the ``rootname.'' The rootname is by default the filename (less the extension) of the lattice file. The most common use of this feature is to cause elegant to create names for all output files that share a common filename but differ in their extensions. Post-processing can be greatly simplified by adopting this naming convention, particularly if one consistently uses the same extension for the same type of output. Recommended filename extensions are given in the lists below.

When elegant reads a namelist command, one of its first actions is to print the namelist back to the standard output. This printout includes all the variables in the namelist and their values. Occasionally, the user may see a variable listed in the printout that is not in this manual. These are often obsolete and are retained only for backward compatibility, or else associated with a feature that is not fully supported. Use of such ``undocumented features'' is discouraged.

elegant supports substitution of fields in namelists using the commandline macro option. This permits making runs with altered parameters without editing the input file. Macros inside the input file have one of two forms: <tag> or $tag. To perform substitution, use the syntax

elegant inputfile -macro=tag1=value1[,tag2=value2...]
When using this feature, it is important to substitute the value of rootname (in run_setup) so that one can get a new set of output files (assuming use of the suggested ``%s'' field in all the output file names). One may give the macro option any number of times, or combine all substitutions in one option.



Subsections
next up previous
Next: alter_elements Up: User's Manual for elegant Previous: Fiducialization in elegant
Robert Soliday 2004-04-21