Event generators

From Charm-Tau Detector
Revision as of 15:00, 5 August 2019 by V.S.Vorobev (Talk | contribs)

Jump to: navigation, search

EvtGen

Default script

Script Generation/GenExamples/scripts/runevtgen.py generates Aurora script to run EvtGen. This script is added to the path and can be invoked from any place:

 runevtgen.py  

This string generates the default script ctaugen.py and produces the default output file output.root. This file contains 1000 events of inclusive psi(3770) decays in the SCT edm format.

One can run

ctaurun ctaugen.py

to invoke generator again.

Configuration

The file ctaugen.py contains two lines:

from GenWrappers.EvtGenTools import generateEvtGen
generateEvtGen(dec="",root="psi(3770)",ecms=0.0,nevt=1000,ip=[0.01, 0.01, 0.5],ofile="{CWD}/output.root"),

where ${CWD} is the path from where runevtgen.py was called.

The generateEvtGen has the following input parameters:

  • dec - EvtGen users decay file. It can be one of the included in Aurora files or absolute path to your own decay file. Inclusive MC generation does not require user decay file
  • root - root particle for EvtGen. vpho (virtual photon) should be used for non-resonant processes
  • ecms - Total center-of-mass energy. This parameter should be set for virtual photon. This parameter is ignored for if root particle is a resonance (it's mass is the center-of-mass energy)
  • nevt - number if events to be gnerated
  • ip - uniform 3D smearing (in mm) for the primary vertex
  • ofile - output file name

One can change this parameters to change behaviour of EvtGen and produce arbitrary MC sample.

An alternative approach is to invoke runevtgen.py script with command line arguments. Here is the code snippet of the parameters defined:

usage = 'evtgen.py [options]'
parser = OptionParser(usage=usage)
parser.add_option('-w', '--wdir',   dest='workdir',      default='.')
parser.add_option('-s', '--scr',    dest='scrfile',      default='ctaugen.py')
parser.add_option('-d', '--dec',    dest='decfile',      default=)
parser.add_option('-r', '--root',   dest='rootParticle', default='psi(3770)')
parser.add_option('-o', '--out',    dest='outfile',      default='output.root')
parser.add_option('-n', '--numevt', dest='nevt',         default=1000)
parser.add_option('-e', '--energy', dest='energy',       default=0.)

I hope the meaning of parameters is self-evident. --V.S.Vorobev (talk) 15:00, 5 August 2019 (+07)

Personal tools