2 #include <phgenfit/Track.h>
13 #include <phpythia8/PHPythia8.h>
36 #include <myjetanalysis/MyJetAnalysis_AllSi.h>
47 const
char *outputFile = "out_allSi",
48 const
char *genpar = "
pi-",
49 const
int det_ver = 2,
50 const
double pixel_size = 10.)
54 const int particle_gen = 5;
55 const int magnetic_field = 4;
57 bool do_projections =
false;
60 string projname1 =
"DIRC";
61 double projradius1 = 50.;
62 double length1 = 400.;
64 double thinness = 0.1;
66 string projname2 =
"FOR";
67 double projzpos2 = 130+thinness/2.;
68 double projradius2 = 50.;
70 string projname3 =
"BACK";
71 double projzpos3 = -(130+thinness/2.);
72 double projradius3 = 50.;
81 if(particle_gen<4) cout <<
"Particle that will be generated: " << std::string(genpar) << endl;
94 gen_pT->
set_name(std::string(genpar));
122 bool do_pythia8_jets =
false;
123 if (particle_gen==1){se->
registerSubsystem( gen); cout <<
"Using particle generator" << endl;}
124 else if(particle_gen==2){se->
registerSubsystem( gun); cout <<
"Using particle gun" << endl;}
125 else if(particle_gen==3){se->
registerSubsystem(segen); cout <<
"Using simple event generator" << endl;}
126 else if(particle_gen==4){
127 do_pythia8_jets =
true;
128 gSystem->Load(
"libPHPythia8.so");
138 else if (particle_gen==5){se->
registerSubsystem(gen_pT); cout <<
"Using particle generator flat in pT" << endl;}
145 if(magnetic_field==1){
149 else if(magnetic_field==2){
153 else if(magnetic_field==3){
154 B_label =
"_sPHENIX";
158 else if(magnetic_field==4){
163 cout <<
"User did not provide a valid magnetic field setting. Set 'magnetic_field'. Bailing out!" << endl;
225 double um_to_cm = 1E-04;
241 if(DISPLACED_VERTEX){
266 fast_sim_eval->
set_filename(TString(outputFile)+B_label+
"_FastTrackingEval.root");
284 Jet_Eval(
string(outputFile) +
"_g4jet_eval.root");
290 const std::string dst_name = std::string(outputFile)+
"_G4LBLVtx.root";
300 gSystem->Load(
"libmyjetanalysis");
301 std::string jetoutputFile = std::string(outputFile) + std::string(
"_electrons+jets.root");
302 MyJetAnalysis_AllSi *myJetAnalysis =
new MyJetAnalysis_AllSi(
"AntiKt_Track_r10",
"AntiKt_Truth_r10",jetoutputFile.data());
308 if (nEvents <= 0)
return;