1 | This directory contains files contributed by Rene Brun and |
---|
2 | Axel Naumann, which illustrate how ROOT commands can be used |
---|
3 | inside PYTHIA code. You should read the "ROOT usage" page |
---|
4 | in the manual to understand the function of the files, and |
---|
5 | how to set up the environment in which they can be used. |
---|
6 | |
---|
7 | The practical steps to be taken, assuming you use the bash shell, |
---|
8 | are: |
---|
9 | |
---|
10 | 1) Add to your ".bashrc" file (in your home directory) |
---|
11 | the following lines: |
---|
12 | |
---|
13 | ######################################################## |
---|
14 | # Root path and libraries: |
---|
15 | source /Path_to_ROOT/root/bin/thisroot.sh |
---|
16 | |
---|
17 | # Pythia 8 path and libraries: |
---|
18 | export PYTHIA8=/Path_to_Pythia8/pythia81xx/ |
---|
19 | export LD_LIBRARY_PATH=$PYTHIA8/lib:$LD_LIBRARY_PATH |
---|
20 | ######################################################## |
---|
21 | |
---|
22 | where xx is the Pythia 8.1 subversion. |
---|
23 | As usual type "source .bashrc" after the changes. |
---|
24 | |
---|
25 | 2) Before compilation, configure Pythia 8 with shared libraries: |
---|
26 | |
---|
27 | ./configure --enable-shared |
---|
28 | |
---|
29 | 3) "make hist" builds an application for histogramming |
---|
30 | Pythia output (alternatively "make" builds and runs all examples). |
---|
31 | |
---|
32 | 4) "./hist" runs the example showing the Pythia output histogram |
---|
33 | in Root format. |
---|
34 | |
---|
35 | 5) You can correspondingly try the "tree" program, which illustrates |
---|
36 | how Pythia event records can be saved by Root. Needless to say, files |
---|
37 | can become quite large when many events are generated. |
---|
38 | |
---|
39 | 6) When upgrading to a new Pythia subversion you should re-generate |
---|
40 | pythiaDict.cxx to reflect the new classes: |
---|
41 | |
---|
42 | cd NewPythiaVersion/rootexamples |
---|
43 | make pythiaDict.cxx |
---|
44 | |
---|
45 | and use the generated pythiaDict.h and pythiaDict.cxx for building |
---|
46 | your program. |
---|
47 | |
---|
48 | 7) For FastJet use, add the following lines to the Makefile: |
---|
49 | |
---|
50 | CXXFLAGS += -I/Path_to_FastJet/include |
---|
51 | |
---|
52 | -L$(PYTHIA8)/lib -lpythia8 -llhapdfdummy -L/Path_to_FastJet/lib -lfastjet |
---|
53 | |
---|
54 | where "Path_to_FastJet" is the directory where FastJet was installed. |
---|
55 | Finally, add to your ".bashrc" file the following line: |
---|
56 | |
---|
57 | export LD_LIBRARY_PATH=//Path_to_FastJet/lib:LD_LIBRARY_PATH |
---|
58 | |
---|
59 | and type "source .bashrc" after the changes. |
---|