Homepage of LC98 Workshop


SIMDET V3.1 Users Guide


Objectives

The program SIMDET simulates the response of an LC detector for e+ e- physics in a fast and flexible manner. The main objectives of the program are threefold:

The basic components of the detector are assumed to be:

The program applies Gaussian smearing to charged particle momenta. The calorimetric response is treated in a way using a parametrisation of results from the ab initio Monte Carlo program BRAHMS. Pattern recognition is emulated by means of cross reference tables between generated particles and detector response. An energy flow algorithm defines the output of the program. Impact informations for charged particles are also provided.

SIMDET offers for event input either to use a built in interface to PYTHIA for internal event generation or to read events generated by other programs and written by subroutine LCWRITE. Also, reading of events generated by CompHEP can be enabled.

After simulation and for the purpose of physics analysis, particles are classified as

Tracking efficiencies, charge mismeasurement and threshold energies for detector response are also taken into account either by default or with user adjustable values. Low energy muons are interpreted as pions.

The output of the program can be directed to a file using the standard output structure or a restricted form. Also, output of 'reconstructed' events can be completely suppressed or, if requested, the best estimates for the energy flow objects are stored such that the physics analysis package VECSUB can be directly used.

The program runs under the control of free format data cards with the possibility of overriding the default options.

A lot of changes and improvements were made with respect to version 2 of SIMDET September 1998; hence the old version should be considered as obsolete. This document describes SIMDET V3.1.


Access to code

The code of SIMDET V3.1 is found here. A PATCHY/CMZ CAR file as well as straight Fortran source is supplied.


Usage notes

SIMDET has a built in an interface to PYTHIA for internal event generation via subroutine SIPYTH. Alternatively, events generated by other programs can be used for detector simulation; subroutine SIEVTI provides an input interface to events written by subroutine LCWRITE whereas subroutine SICOMP is reserved for events generated by the program package CompHEP. If the structure of the generated events does not coincide with common /LUJETS/ of PYTHIA, subroutine SIPREP should fill the arrays K(I,...), P(I,...) and V(I,...). In all cases, NEVENT specifies the number of events to be processed.

The detector parameters used are defined in subroutine SIDETR. The naming convention is self explanatory. It should be noted, however, that the CDR does not specify the resolution parameters for all of the detector components assumed to exist. Hence, the corresponding numbers given in SIDETR should be considered as a first trial. The results of possible further detector improvements and appropriate detailed simulations by means of the ab initio Monte Carlo program BRAHMS should update these numbers.

Four options exist for the vertex detector (subroutine SIVTXD):

  1. the APS version, based on 2 cm resp. 1 cm beam pipe radius
  2. the CCD version, based on 2 cm resp. 1 cm beam pipe radius
The tracking performance in the forward direction (in subroutine SIFWTR) can be improved by invoking an additional tracking device with a high point resolution. Detection and tracking of forward muons (in subroutine SIFWMU) is based on an example by R.Bruni and R.Nania presented in DESY 97-123E. The luminosity detector (inside the mask) responds only to high energy electrons (subroutine SILUMI). At the moment, an instrumented mask (in subroutine SIMASK) is formally included in SIMDET. Particles not entering the calorimeters, e.g. low-pt tracks, are rescued in subroutine SIRSCU and added to the list of energy flow objects in subroutine SISTOR.

Subroutine SIFFRE reads the set of data cards with the FFREAD package. Default settings in subroutine SIINIT and/or in subroutine SIDETR might be overwritten.

Booking of histograms is provided in subroutine SIBOOK. A few standard histograms are provided to monitor detector response.

After selection of all particles which might give a response in the detector (subroutine SIPART), charged particle tracking and impact parameter estimations are steered by subroutine SICHPA.

The calorimetric response is based on detector studies using the simulation package BRAHMS. The energy distributions of electrons and charged pions in adjacent cells were fitted and the parameters obtained are used for appropriate energy deposits simulations in the electromagnetic and hadronic calorimeters (subroutine SILEGO and subroutine SIDEPO). Afterwards, a cluster search algorithm (with some idealized assumptions) provides clusters (subroutine SICLUS_I) in the ECAL as well as the HCAL. Finally, an energy flow algorithm (subroutine SIFLOW_I) joins tracker and calorimeter informations such that as many single particles as possible are resolved. Particle identification on the basis of shower shapes and matching between tracker and calorimeter information in space and momentum is emulated. Finally, best estimates of the energy flow objects are established.

The simulation finishes by providing all measured objects in the proposed common output structure in subroutine SISTOR. If requested, the program allows to write (unformatted/formatted) all objects in either the standard structure or in a restricted structure (best estimates only) to an external file in subroutine SIWDST so that analysis can follow externally. If no external file should be written, the array VECP(I,K) is optionally filled in subroutine SIBEST which allows to use directly the physics analysis package VECSUB (a product from SLAC/DELPHI).

The user subroutine SIUSER (IFLAG) has been added and given as an independent card file. It is called during inititialization (IFLAG=1), for each event before writing to output file (IFLAG=2) and during termination of the job (IFLAG=3).

The program exist as Fortran as well as a PATCHY/CMZ CAR file. If the CAR file is used, the 'use' selection SIMDET selects the simulation material, while NOSIMU selects the code without any detector response. This enables physics studies at the parton level or generator level.

Please note that in the FORTRAN code error handling routines are inserted. These are of relevance for HP platforms only. If the CAR file is used, the 'use' selection HPUX includes this material.

Please link the CERN libraries and the lund/jetset74 libraries.


Input/Output units:

Logical unit number Default file name Contents
6 simdetv3.res debugging information like the history of a few events and histograms
7 user-defined input events generated by an external program
8 simdetv3.dat free format data card file
11 user-defined simulated and reconstructed objects for further analysis
12 simdetv3.hist PAW histogram file

Note that the names of input and reconstructed event files should be enclosed in single quotes, start with a point and end with a blank when specified on the respective data cards. The length of all file names is restriced to 80 characters.


Event output structure (standard):

This describes the SIMDET V3.1 standard output structure. The output file starts with a single file header of 10 words. Each event starts with the number of generated particles NGENPA, which is followed by a record of 13 words for each particle. According to the user's choice, the whole event history or only the stable particles which might give a response in the detector are covered.

The number of the energy flow objects, NENFLO, then follows. For each object, blocks of records follow, describing status information, best estimates, generator information, charged particles, calorimetric clusters and muons from the muon system, in this order.


File header record:

Offset Variable name Data type Meaning
1 INSTATE INTEGER ISR flag, PYTHIA default:
0 = no radiation, 1 = ISR & Beamstrahlung, 2 = ISR only, 3 = Beamstrahlung
2 SQRTS REAL nominal collider cms energy [GeV]
3 SIGMA REAL Cross section [fb]
4 IDCLASS INTEGER Reaction identifier, user defined
5 dummy INTEGER not used
6 dummy REAL not used
7 FIELD REAL Magnetic field [T]
8 dummy INTEGER not used
9 dummy INTEGER not used
10 dummy INTEGER not used

This record is written once per file.


Generated particle record:

Offset Variable name Data type Meaning
1 STATUS INTEGER 0 = no detector response, 1 = detector response
2 ID INTEGER particle code according to LUND convention
3 line INTEGER line number of mother in the LUND record
4 Px REAL x-component of momentum [GeV]
5 Py REAL y-component of momentum [GeV]
6 Pz REAL z-component of momentum [GeV]
7 E REAL Energy [GeV]
8 m REAL mass of particle [GeV]
9 Q REAL charge of particle
10 x REAL x-component of vertex [mm]
11 y REAL y-component of vertex [mm]
12 z REAL z-component of vertex [mm]
13 Time REAL time of production [mm/c]

This record is repeated NGENPA times.


Energy flow record 1: status of energy flow object

Offset Variable name Data type Meaning
1 STATUS INTEGER < 0: invalid object; 1=charged object; 2=neutral object; 3=composite object
2 Type INTEGER particle code according to LUND convention, 999 = cluster of unresolvable particles
3 NGEN INTEGER number of generator particles contributing to the energy flow object
4 NTRK INTEGER number of charged particles contributing to the energy flow object
5 NCAL INTEGER number of clusters contributing to the energy flow object
6 NMUS INTEGER number of muons contributing to the energy flow object

This record and the following blocks are repeated NENFLO times.


Energy flow record 2: best estimate for object's energy and direction

Offset Variable name Data type Meaning
1 Px REAL x-component of momentum [GeV]
2 Py REAL y-component of momentum [GeV]
3 Pz REAL z-component of momentum [GeV]
4 E REAL Energy [GeV]
5 m REAL mass of particle [GeV]
6 Q REAL charge of particle

This record is written once per energy flow object.


Energy flow record 3: generator particle contributing to energy flow object

Offset Variable name Data type Meaning
1 link INTEGER line number of particle in the LUND record
2 Efrac REAL energy fraction

This record is repeated NGEN times.


Energy flow record 4: charged particle tracks that are part of the object

Offset Variable name Data type Meaning
1 P REAL absolute value of momentum [GeV]
2 Theta REAL polar angle [radian]
3 Phi REAL azimuth angle [radian]
4 Q REAL charge of particle
5 Imp(R,phi) REAL transverse impact parameter, in units of sigma
6 Imp(R,z) REAL Longitudinal impact parameter, in units of sigma
7 cov. matrix REAL element of the cov. matrix
8 cov. matrix REAL element of the cov. matrix
9 cov. matrix REAL element of the cov. matrix
10 cov. matrix REAL element of the cov. matrix
11 cov. matrix REAL element of the cov. matrix
12 cov. matrix REAL element of the cov. matrix
13 cov. matrix REAL element of the cov. matrix
14 cov. matrix REAL element of the cov. matrix
15 cov. matrix REAL element of the cov. matrix

This record is repeated NTRK times.


Energy flow record 5: calorimeter cluster (ECAL/HCAL) that are part of the object

Offset Variable name Data type Meaning
1 E REAL energy [GeV]
2 Theta REAL polar angle [radian]
3 Phi REAL azimuth angle [radian]
4 Time REAL timing information
5 C(em) REAL probability of being consistent with an electromagnetic particle
6 E REAL energy [GeV]
7 Theta REAL polar angle [radian]
8 Phi REAL azimuth angle [radian]
9 Time REAL timing information
10 C(mip) REAL probability of being consistent with a minimum ionizing particle

This record is repeated NCAL times.


Energy flow record 6: muons from the muon system that are part of the object

Offset Variable name Data type Meaning
1 E REAL energy [GeV]
2 Theta REAL polar angle [radian]
3 Phi REAL azimuth angle [radian]
4 Q REAL charge of particle
5 Time REAL timing information
6 C(punch) REAL probability of being consistent with an punch-through object

This record is repeated NMUS times.


Restricted output structure:

This describes the SIMDET V3.1 restricted output structure, mainly intended to save disc space for reconstructed events. The output file starts with a single file header of 10 words. Each event starts with the number of energy flow objects, NENFLO. This is followed by a series of records for each energy flow object, which describe only the best estimate of the object's energy and direction, in analogy to energy flow record 2 from the full data format, supplementerd by impact parameter information.


File header record:

Offset Variable name Data type Meaning
1 INSTATE INTEGER ISR flag, PYTHIA default:
0 = no radiation, 1 = ISR & Beamstrahlung, 2 = ISR only, 3 = Beamstrahlung
2 SQRTS REAL nominal collider cms energy [GeV]
3 SIGMA REAL Cross section [fb]
4 IDCLASS INTEGER Reaction identifier, user defined
5 dummy INTEGER not used
6 SQSACT REAL Event related cms energy
7 FIELD REAL Magnetic field [T]
8 dummy INTEGER not used
9 dummy INTEGER not used
10 dummy INTEGER not used

This record is written once per file.


Energy flow record:

Offset Variable name Data type Meaning
1 Px REAL best estimate for x-component of momentum [GeV]
2 Py REAL best estimate for y-component of momentum [GeV]
3 Pz REAL best estimate for z-component of momentum [GeV]
4 E REAL best estimate for energy [GeV]
5 m REAL mass of particle [GeV]
6 Q REAL charge of particle
7 Imp(R,phi) REAL transverse impact parameter, in units of sigma
8 Imp(R,z) REAL Longitudinal impact parameter, in units of sigma
9 NTRK INTEGER number of charged particles contributing to the energy flow object
10 type INTEGER particle code according to LUND convention, 999 = cluster of unresolvable particles

In cases of NTRK > 1, the largest impact parameters are recorded. This record is repeated NENFLO times.


Data cards:

This describes the SIMDET V3.1 free format data cards. The initialized default values are given in parentheses. Note that file names should be enclosed in single quotes, start with a point and end with a blank. The length of all file names is restriced to 80 characters. The sample data card file simdet_301.dat delivered with the program causes the simulation of events from the reaction e+e- -> H(80 GeV) Z -> bb qq at a center of mass energy of 500 GeV, generated using PYTHIA.

Certain obvious logical restrictions apply to the proper combination of options. For example, option 'HIST 1' only works in connection with option 'BEST 0'.


Key Variable Data type Meaning
NEVT NEVENT INTEGER total number of events to process (D=10)
PYTH IFPYTH INTEGER 1 = event generation by PYTHIA, 0 = no PYTHIA event generation (D=1)
EVTI IFEVTI INTEGER 1 = event reading from an external file, written by sr LCWRITE, 0 = no event reading (D=0)
GENF LUNGENF INTEGER input file name of generated events, user defined
WDST IFWDST INTEGER 1 = event writing to an external file, 0 = no event writing (D=1)
RECF LUNRECF INTEGER output file name of processed events, user defined
FORM IFFORM INTEGER 1 = formatted output structure, 0 = unformatted output structure (D=0)
BEST IFBEST INTEGER 1 = best estimates are enabled, 0 = no best estimates (D=0)
VECS IFVECS INTEGER 1 = filling of the array VECP(I,K) for VECSUB, 0 = no filling of this array (D=0)
HIST IFHIST INTEGER 1 = history of the generated event to output file, 0 = only stable generated particles to output file (D=0)
COMP IFCOMP INTEGER 1 = event reading from an external file, written by CompHEP, 0 = no event reading (D=0)
APS2 IFAPS2 INTEGER 1 = pixel detector (for 2 cm beam pipe) is enabled, 0 = no pixel detector (D=1)
APS1 IFAPS1 INTEGER 1 = pixel detector (for 1 cm beam pipe) is enabled, 0 = no pixel detector (D=0)
CCD2 IFCCD2 INTEGER 1 = CCD detector (for 2 cm beam pipe) is enabled, 0 = no CCD (2cm) detector (D=0)
CCD1 IFCCD1 INTEGER 1 = CCD detector (for 1 cm beam pipe) is enabled, 0 = no CCD (1cm) detector (D=0)
FWTR IFFWTR INTEGER 1 = additional forward tracker is enabled, 0 = no additional forward tracker (D=0)
FWMU IFFWMU INTEGER 1 = forward muon detector is enabled, 0 = no forward muon detector (D=0)
LUMI IFLUMI INTEGER 1 = luminosity detector is enabled, 0 = no luminosity detector (D=0)
MASK IFMASK INTEGER 1 = instrumented mask is enabled, 0 = no instrumented mask (D=0)
EFTR TRKEFF REAL measurement track efficiency (D=0.99)
PTTR PTMINP REAL minimum transverse momentum required (D=0.050 [GeV])
QMTR QTRKMIS REAL charge misinterpretation probability (D=0.005)
EMPH EMINPH REAL minimum energy required for photon detection (D=0.100 [GeV])
AEMR AEMRES REAL first energy resolution parameter for ECAL (D=0.102)
BEMR BEMRES REAL second (constant) energy resolution parameter for ECAL (D=0.006)
EMHA EMINHAS REAL minimum energy required for hadron detection in HCAL (D=0.200 [GeV])
AHAR AHARES REAL first energy resolution parameter for HCAL (D=0.405)
BHAR BHARES REAL second (constant) energy resolution parameter for HCAL (D=0.042)
EMLU EMINLU REAL minimum energy required for electron detection in LUMI detector (D=30.0 [GeV])
EFLU ELEFLU REAL measurement efficiency for electrons in LUMI detector (D=0.999)
CSLU SIZLUM REAL cell size of LUMI detector (D=1.0 [degrees])
ARLU ALURESS REAL first energy resolution parameter for LUMI detector (D=0.10)
BRLU BLURES REAL second (constant) energy resolution parameter for LUMI detector (D=0.01)
EMMU EMINFWM REAL minimum energy required for muon detection in forward muon detector (D=5.0 [GeV])
EFMU EFFFWMU REAL measurement efficiency for muons in forward muon detector (D=0.95)
QMMU QMISFWM REAL charge misinterpretation probability for muons in forward muon detector (D=0.003)
PFWT PMINFTR REAL minimum transverse momentum in forward tracker (D=0.200 [GeV])
EMSK EMINMSK REAL minimum energy required for particle measurement in the mask (D=10.0 [GeV])


Further information

If you have questions, comments or suggestions, please do not hesitate to contact H. Jürgen Schreiber (email: schreibe@ifh.de).