Home page of the FOOT simulation software
The simulation framework
The FOOT simulation is performed using the
FLUKA software package.
Running the simulation: how to
There are several steps needed to get, compile, run, access the simulation output.
Getting the code
The instructions to download the code are available in the
FOOT software page.
Compiling and running
As a prerequisite for running a simulation you need a valid installation of the FLUKA software.
You have to setup the $FLUPRO, $FLUTIL and $FLUFOR variables before compiling the code (help with the FLUKA installation phase is provided in the
FLUKA web page, FLUKA mailing lists and, if everything else failed, from the FOOT FLUKA "experts": V. Patera, G. Battistoni, A. Sarti). Once everything is installed and setup, you can proceed with the following instructions.
To compile the code you have to:
- Go in the Simulation folder.
- Source the link_FOOT_mag.sh (if you want to simulate with magnetic field ON) or link_FOOT.sh (if you want to simulate with magnetic field OFF) script.
- After the code is compiled, check that you have a fluka_FOOT_ mag.exe (magnetic field ON) or fluka_FOOT.exe (magnetic field OFF) executable created in your Simulation folder.
- If you want the magnetic field switched on you have to put the variable MagField =true (=off if you want it switched off) in foot_geo.h to create the correct input file
- Compile the program to write the input and the geometry files with the command:
make -f Makefile_geo
- Execute the program with the command:
./foot_geo
To run the code you have to.
- Go in the Simulation folder.
- Execute the command:
$FLUPRO/flutil/rfluka -e fluka_FOOT_mag.exe -N0 -M1 foot
or
$FLUPRO/flutil/rfluka -e fluka_FOOT.sh -N0 -M1 foot
- The output will appear in:
foot001_TXT.dat
Decoding the output
The output format is a dat file. To have access to a tupled file you need to convert it using a converter.
Libraries are kept under
TXT2ROOT folder.
- Compile the converter in TXT2ROOT by issuing the command:
make
- Then you can run the converter with the following command:
./Txt2Root -in ../foot001_TXT.dat -out foot001_TXT.root
This will generate the output.root file containing all the MC info needed for furher processing.
Event reconstruction
The reconstruction of the decoded MC events is accomplished using the reconstruction software
documented in the related web page.
Presently available simulation output files
On the tier3 there are Root output files of simulation available as reference for the study of detector performances. They are
documented in the related web page
--
Alessio Sarti - 2016-07-06
Comments