This page is intended for people directly involved in the support
of the GSTAR/STAF software and the Monte Carlo production runs.
Since Staf is being replaced by the Starsim application, the users
are discouraged from using this page, which is kept here as a reference
only, useful in debugging some old code.
Propagating the event generator data through reconstruction
In addition to the "normal" output of an event generator, which is
the list of particles and their momenta, there is often additional
information available at the event generation stage, which may be
useful for further analysis. An example of such data is the "subprocess
id" in the Pythia event generator.
In order to propagate this to the reconstruction stage, code changes
should be made that would affect both STAF/GSTAR application proper
as well as root4star .
In particular, the following needs to be accomplished:
- First, the file
heperead.age in the Pythia simulation
package should be modified in order to actually create an additional data bank
which will hold the data. While this bank can be planted in a few different
location withing the ZEBRA hierarchy, the following location was chosen as
optimal:
Fill /EVNT/PASS/MPAR ! comment
SBPR = MSTI(1) ! Pythia subprocess ID
endfill
Before it can be filled, we also need to declare this struct:
Structure MPAR { int SBPR }
Besides, the actual Pythia data such as MSTI(1) should be made accessible
via the use of a COMMON block:
COMMON/PYPARS/MSTP(200),PARP(200),MSTI(200),PARI(200)
All of these changes are in the same source file heperead.age .
- Second, the container that will receive these data during reconstruction
should have additional storage. The "g2t_event" structure should be augmented with
requisite fileds, i.e. it would now look something like:
struct g2t_event { /* G2t_event */
long eg_label; /* Event label from event generator */
long event_type; /* specifies trigger, pileup, cosmic, laser */
long ge_rndm[2]; /* geant random seeds at start of event */
long merge_info[10]; /* as yet unspecified */
long n_event; /* Event number */
long n_part_neut_east; /* number of participant neutrons */
long n_part_neut_west; /* number of participant neutrons */
long n_part_prot_east; /* number of participant protons */
long n_part_prot_west; /* number of participant protons */
long n_run; /* Run number */
long n_track_eg_fs; /* Number of final state event gen. tracks */
long n_track_prim; /* Number of primary tracks (w/o parent) */
long polarization[10]; /* polarization info, as yet unspecified */
long prim_vertex_p; /* Id of first primary vertex in event */
float b_impact; /* Impact parameter */
float phi_impact; /* Azimuth of reaction plane */
float time_offset; /* time offset in seconds wrt trigger event */
long subprocess_id; /* Pythia subprocess Id */
};
This change should be made in the requisite idl file, in the directory
pams/sim/idl .
-
The file
pams/sim/g2t/g2t_get_event.F has the functionality
to fill the structure described in the previous item. It should be augmented
like this:
call MHEADRD(SUB_ID)
g2t_event(1).subprocess_id = SUB_ID
Here, of course, we are populating the structure that we added to
in the previous item. The subroutine name MHEADRD is
arbitrary.
Passing the data is done via the subroutine argument, however
it may be be necessary to employ a COMMON block for
that purpose in case there are multiple parameters to be extracted
from the bank.
- A piece of code, containing the aforementioned subroutione,
should be placed in a file residing in the
directory
pams/sim/g2t . The purpose of this code is
to provide access to the data that may be present in the added
bank. Basic error checking is in order here:
SUBROUTINE MHEADRD(SUB_ID)
integer SUB_ID, ISTAT
data ISTAT/0/
STRUCTURE MPAR {int SBPR}
USE /EVNT/PASS/MPAR stat=ISTAT
IF(ISTAT.GE.0) THEN
SUB_ID=MPAR_SBPR
ELSE
SUB_ID=MPAR_SBPR
ENDIF
RETURN
END
This Page Is Under Construction!
GEANT 4 components
CLHEP releases:
- /afs/cern.ch/sw/lhcxx/specific/redhat61/gcc-2.95.2/CLHEP/1.8.0.0
- /afs/cern.ch/sw/lhcxx/specific/redhat72/gcc-2.95.2/CLHEP/1.8.0.0
- /afs/cern.ch/sw/lhcxx/specific/redhat72/gcc-3.2/CLHEP/1.8.0.0
- /afs/cern.ch/sw/lhcxx/specific/redhat73/gcc-2.95.2/CLHEP/1.8.0.0
- /afs/cern.ch/sw/lhcxx/specific/redhat73/gcc-3.2/CLHEP/1.8.0.0
- /afs/cern.ch/sw/lhcxx/specific/sun4x_57/CC-5.2/CLHEP/1.8.0.0 (Solaris-7)
- /afs/cern.ch/sw/lhcxx/specific/sun4x_58/CC-5.3/CLHEP/1.8.0.0 (Solaris-8)
- /afs/cern.ch/sw/lhcxx/specific/sun4x_58/CC-5.4/CLHEP/1.8.0.0 (Solaris-8)
Building the GSTAR/STAF application
The GSTAR/STAF software at the time of this writing is undergoing
infrastructure changes, so the following should be considered
"work in progress". Certain features such as CMZ based source
file management are of historical origin and will eventually go away.
Requisite files
- starsim.cmz -- the main source code archive (self-extracting)
- staf.makefile -- the makefile used to build
libstaf.a
- libgcalor.a -- the library providing the GCALOR functionality in GEANT simulations.
At the time of writing, the library we use is not build locally at STAR but copied from this
location:
/afs/usatlas.bnl.gov/software/dist/latest/gcalor/gcalor-00-00-39/i686-rh73-gcc32-dbg/libgcalor.a
- The following
CERNLIB components:
- geant321.cmz
- geang321.cmz
- zebpack.cmz
- zebra.cmz
- comis.cmz
These can be found in /afs/rhic/asis/share/cern/95a/src/cmz and should
either be copied to, or linked from, the build directory.
The staf.makefile targets
-
headerlinks -- if necessary, creates the include directory,
makes sure it's emptied in case it already existed and establishes symbolic
links for the header files found in staf/*/inc, to facilitate
compilaton
-
cernlinks -- if necessary, establishes symbolic
links for the CMZ files mentioned above, which contain the CERNLIB components.
Procedure
Roughly, there are two steps that need to be taken in order to build the application.
|