Документ взят из кэша поисковой машины. Адрес оригинального документа : http://theory.sinp.msu.ru/~semenov/doc/node3.html
Дата изменения: Fri Mar 7 18:07:49 2008
Дата индексирования: Mon Oct 1 21:07:15 2012
Кодировка:
Structure of LanHEP input file next up previous contents
Next: Objects in the expressions Up: The LanHEP Handbook Previous: Getting started with LanHEP   Contents

Subsections

Structure of LanHEP input file

The LanHEP input file is the sequence of statements, each starts with a special identifier (such as parameter, lterm etc) and ends with the full-stop '.' symbol. Statement can occupy several lines in the input file.

This section is aimed to clarify the syntax of LanHEP input files, i.e. the structure of the statements.

Constants and identifiers

First of all, each word in any statement is either an identifier or a constant.

Indentfiers are the names of particles, parameters etc. Examples of identifiers from the previous section are particle names

e1 E1 A q Q G
The first word in each statement is also an identifier, defining the function which this statement performs. The identifiers are usually combinations of letters and digits starting with a letter. If an identifier does not respect this rule, it should be quoted. For example, the names of $W^\pm$ bosons must be written as 'W+' and 'W-', since they contain '+' and '-' symbols.

Constants can be classified as

Comments

User can include comments into the LanHEP input file in two ways. First, symbol '%' denotes the comment till the end of current line. Second way allows one to comment any number of lines by putting a part of input file between '/*' (begin of comment) and '*/' (end of comment) symbols.

Including files

LanHEP allows the user to divide the input file into several files. To include the file file, the user should use the statement

read file.
The standard extension '.mdl' of the file name may be omitted in this statement.

Another way to include a file is provided by the use statement as

use file.
The use statement reads the file only once, next appearances of this statement with the same argument do nothing. This function prevents multiple reading of the same file. This form can be used mainly to include some standard modules, such as declaration of Standard Model particles to be used for writing some extensions of this model.

Conditional processing of the model

Let us consider the LanHEP input files for the Standard Model with both the t'Hooft-Feynman and unitary gauges. It is clear that these input files differ by several lines only -- the declaration of gauge bosons and Higgs doublet. It is more convenient to have only one model definition file. In this case the conditional statements are necessary. LanHEP allows the user to define several keys, and use these keys to branch among several variants of the model. The keys have to be declared by the keys statement:

keys name1=value1, name2=value2, ... .
Then one can use the conditional statements:
do_if key==value1.
actions1
do_else_if key==value2.
actions2
do_else_if key==value3.
...
do_else.
default actions
end_if.

The statements do_else_if and do_else are not obligatory. The value of the key is a number or symbolic string. An example of using these statement in the Standard model may read:

keys Gauge=unitary.

do_if Gauge==Feynman.
vector Z/Z:('Z-boson',mass MZ = 91.187, width wZ = 2.502, gauge).
do_else_if Gauge==unitary.
vector Z/Z:('Z-boson',mass MZ = 91.187, width wZ = 2.502).
do_else.
write('Error: key Gauge must be either Feynman or unitary').
quit.
end_if.

Thus, to change the choice of gauge fixing in the generated Feynman rules it is enough to modify one word in the input file. There is another way, to set the key value from the command line at the launch of LanHEP:

lhep -key Gauge=Feynman filename.

If the value of key is set from the command line at the program launch, the value for this key in the keys statement is ignored.


next up previous contents
Next: Objects in the expressions Up: The LanHEP Handbook Previous: Getting started with LanHEP   Contents
Andrei Semenov 2008-02-16