Input
GEANT
MTSIM
Embeding
Reconstruction
Maching
ROOT MINI-DST
Home page
Last modification:
2003-07-22
e-mail:
cblume@cern.ch
korus@cern.ch
|
|
This is an example script to run GEANT. The sorce code of this file you may find here.
|
|
#!/bin/ksh
NEVENT=100
OUTFILE=sim_kstar_01.ds
GENFILEDAT=gen_kstar_01.d
#Change to working directory
CURDIR=/afs/cern.ch/user/r/rkorus/public/kstar/geant
cd $CURDIR
#Set the NA49 level
NA49_LEVEL=dev
. $NA49/etc/na49_env.sh
#Create temporary files for the piping
TMP1=/tmp/sim_1_${USER}_$$.ds
rm -f $TMP1
mkfifo $TMP1
TMP2=/tmp/sim_2_${USER}_$$.ds
rm -f $TMP2
mkfifo $TMP2
#Start gfilt to select tracks with hits in the detector
gfilt -i $TMP1 -o $OUTFILE -n $NEVENT > /dev/null 2>&1 &
GFILTPID=$!
#Start g2ds to convert the GEANT FZ-output into a DS-file
g2ds -i $TMP2 -o $TMP1 -n $NEVENT >/dev/null 2>&1 &
G2DSPID=$!
#Start GNA49
. $CURDIR/setup_00.phys_off.std+.256tb.ksh
gna49_PP </dev/null 2>&1
0
#Only decays into charged particles for omega and lambda
vec/cre ubuf(1) r 0
vec/cre branch(1) r 100
vec/cre mode1(1) i 911
spart 33 kstar 3 0.8961 0.0 1.0e-24 ubuf 0 branch mode1
u/fz/fzout o $TMP2
vertexinput $CURDIR/vertex/$VERTEXFILE
ukin o tx $CURDIR/generate/$GENFILEDAT
trigger $NEVENT
u/fz/fzout c
quit
EOF
GNA49PID=$!
#Wait for all processes to finish
wait $GNA49PID
GNA49RC=$?
wait $G2DSPID
G2DSRC=$?
wait $GFILTPID
GFILTRC=$?
rm -f $TMP1
rm -f $TMP2
|
|