Update for the resolution parameterization.
[u/mrichter/AliRoot.git] / macros / ConfigPPR.C
CommitLineData
13051068 1// One can use the configuration macro in compiled mode by
2// root [0] gSystem->Load("libgeant321");
3// root [0] gSystem->SetIncludePath("-I$ROOTSYS/include -I$ALICE_ROOT/include\
4// -I$ALICE_ROOT -I$ALICE/geant3/TGeant3");
5// root [0] .x grun.C(1,"ConfigPPR.C++")
6
de78d77f 7#if !defined(__CINT__) || defined(__MAKECINT__)
8#include <Riostream.h>
9#include <TRandom.h>
10#include <TSystem.h>
11#include <TVirtualMC.h>
87d24ab1 12#include <TGeant3TGeo.h>
eab1dd9d 13#include <TPDGCode.h>
14#include <TF1.h>
de78d77f 15#include "STEER/AliRunLoader.h"
16#include "STEER/AliRun.h"
17#include "STEER/AliConfig.h"
18#include "STEER/AliGenerator.h"
87d24ab1 19#include "STEER/AliLog.h"
de78d77f 20#include "PYTHIA6/AliDecayerPythia.h"
21#include "EVGEN/AliGenHIJINGpara.h"
22#include "THijing/AliGenHijing.h"
23#include "EVGEN/AliGenCocktail.h"
24#include "EVGEN/AliGenSlowNucleons.h"
25#include "EVGEN/AliSlowNucleonModelExp.h"
78e738e5 26#include "EVGEN/AliGenParam.h"
e860c7ea 27#include "EVGEN/AliGenMUONlib.h"
eab1dd9d 28#include "EVGEN/AliGenSTRANGElib.h"
b984b0e1 29#include "EVGEN/AliGenMUONCocktail.h"
eab1dd9d 30#include "EVGEN/AliGenCocktail.h"
31#include "EVGEN/AliGenGeVSim.h"
32#include "EVGEN/AliGeVSimParticle.h"
de78d77f 33#include "PYTHIA6/AliGenPythia.h"
34#include "STEER/AliMagFMaps.h"
35#include "STRUCT/AliBODY.h"
36#include "STRUCT/AliMAG.h"
96fb3353 37#include "STRUCT/AliABSOv3.h"
38#include "STRUCT/AliDIPOv3.h"
39#include "STRUCT/AliHALLv3.h"
de78d77f 40#include "STRUCT/AliFRAMEv2.h"
96fb3353 41#include "STRUCT/AliSHILv3.h"
42#include "STRUCT/AliPIPEv3.h"
e1cd8da1 43#include "ITS/AliITSvPPRasymmFMD.h"
de78d77f 44#include "TPC/AliTPCv2.h"
0d7ef405 45#include "TOF/AliTOFv6T0.h"
55eb2b56 46#include "HMPID/AliHMPIDv2.h"
9d07603a 47#include "ZDC/AliZDCv3.h"
de78d77f 48#include "TRD/AliTRDv1.h"
49#include "FMD/AliFMDv1.h"
50#include "MUON/AliMUONv1.h"
51#include "PHOS/AliPHOSv1.h"
52#include "PMD/AliPMDv1.h"
ababa197 53#include "T0/AliT0v1.h"
4920e63e 54#include "EMCAL/AliEMCALv2.h"
b384f8a4 55#include "ACORDE/AliACORDEv0.h"
4a2f6442 56#include "VZERO/AliVZEROv7.h"
de78d77f 57#endif
58
36d4cb82 59enum PprRun_t
60{
61 test50,
62 kParam_8000, kParam_4000, kParam_2000,
63 kHijing_cent1, kHijing_cent2,
64 kHijing_per1, kHijing_per2, kHijing_per3, kHijing_per4, kHijing_per5,
433185a9 65 kHijing_jj25, kHijing_jj50, kHijing_jj75, kHijing_jj100, kHijing_jj200,
bc3e0a09 66 kHijing_gj25, kHijing_gj50, kHijing_gj75, kHijing_gj100, kHijing_gj200,
13051068 67 kHijing_pA, kPythia6,
68 kPythia6Jets20_24, kPythia6Jets24_29, kPythia6Jets29_35,
69 kPythia6Jets35_42, kPythia6Jets42_50, kPythia6Jets50_60,
70 kPythia6Jets60_72, kPythia6Jets72_86, kPythia6Jets86_104,
71 kPythia6Jets104_125, kPythia6Jets125_150, kPythia6Jets150_180,
5d185da5 72 kD0PbPb5500, kCharmSemiElPbPb5500, kBeautySemiElPbPb5500,
e860c7ea 73 kCocktailTRD, kPyJJ, kPyGJ,
b984b0e1 74 kMuonCocktailCent1, kMuonCocktailPer1, kMuonCocktailPer4,
75 kMuonCocktailCent1HighPt, kMuonCocktailPer1HighPt, kMuonCocktailPer4HighPt,
76 kMuonCocktailCent1Single, kMuonCocktailPer1Single, kMuonCocktailPer4Single,
eab1dd9d 77 kFlow_2_2000, kFlow_10_2000, kFlow_6_2000, kFlow_6_5000,
78 kHIJINGplus, kRunMax
3f7a17bb 79};
80
22ad5c43 81const char* pprRunName[] = {
3f7a17bb 82 "test50",
83 "kParam_8000", "kParam_4000", "kParam_2000",
84 "kHijing_cent1", "kHijing_cent2",
85 "kHijing_per1", "kHijing_per2", "kHijing_per3", "kHijing_per4",
86 "kHijing_per5",
87 "kHijing_jj25", "kHijing_jj50", "kHijing_jj75", "kHijing_jj100",
88 "kHijing_jj200",
89 "kHijing_gj25", "kHijing_gj50", "kHijing_gj75", "kHijing_gj100",
13051068 90 "kHijing_gj200", "kHijing_pA", "kPythia6",
91 "kPythia6Jets20_24", "kPythia6Jets24_29", "kPythia6Jets29_35",
92 "kPythia6Jets35_42", "kPythia6Jets42_50", "kPythia6Jets50_60",
93 "kPythia6Jets60_72", "kPythia6Jets72_86", "kPythia6Jets86_104",
94 "kPythia6Jets104_125", "kPythia6Jets125_150", "kPythia6Jets150_180",
5d185da5 95 "kD0PbPb5500", "kCharmSemiElPbPb5500", "kBeautySemiElPbPb5500",
e860c7ea 96 "kCocktailTRD", "kPyJJ", "kPyGJ",
b984b0e1 97 "kMuonCocktailCent1", "kMuonCocktailPer1", "kMuonCocktailPer4",
98 "kMuonCocktailCent1HighPt", "kMuonCocktailPer1HighPt", "kMuonCocktailPer4HighPt",
eab1dd9d 99 "kMuonCocktailCent1Single", "kMuonCocktailPer1Single", "kMuonCocktailPer4Single",
100 "kFlow_2_2000", "kFlow_10_2000", "kFlow_6_2000", "kFlow_6_5000", "kHIJINGplus"
36d4cb82 101};
102
36d4cb82 103enum PprRad_t
104{
105 kGluonRadiation, kNoGluonRadiation
106};
107
cf3f928d 108enum PprMag_t
109{
110 k2kG, k4kG, k5kG
111};
112
b34c4a51 113enum PprTrigConf_t
114{
115 kDefaultPPTrig, kDefaultPbPbTrig
116};
117
118const char * pprTrigConfName[] = {
119 "p-p","Pb-Pb"
120};
cf3f928d 121
6b612c2d 122enum PprGeo_t
123 {
124 kHoles, kNoHoles
125 };
126
36d4cb82 127// This part for configuration
de78d77f 128//static PprRun_t srun = test50;
6b612c2d 129static PprRun_t srun = kHIJINGplus;
130static PprRad_t srad = kGluonRadiation;
131static PprMag_t smag = k5kG;
132static PprGeo_t geo = kHoles;
3f7a17bb 133static Int_t sseed = 12345; //Set 0 to use the current time
b34c4a51 134//static PprTrigConf_t strig = kDefaultPPTrig; // default pp trigger configuration
135static PprTrigConf_t strig = kDefaultPbPbTrig; // default PbPb trigger configuration
cf3f928d 136
36d4cb82 137// Comment line
138static TString comment;
139
de78d77f 140// Functions
141Float_t EtaToTheta(Float_t arg);
142AliGenerator* GeneratorFactory(PprRun_t srun);
143AliGenHijing* HijingStandard();
eab1dd9d 144AliGenGeVSim* GeVSimStandard(Float_t, Float_t);
3f7a17bb 145void ProcessEnvironmentVars();
36d4cb82 146
147void Config()
148{
36d4cb82 149 // ThetaRange is (0., 180.). It was (0.28,179.72) 7/12/00 09:00
150 // Theta range given through pseudorapidity limits 22/6/2001
151
3f7a17bb 152 // Get settings from environment variables
153 ProcessEnvironmentVars();
154
36d4cb82 155 // Set Random Number seed
3f7a17bb 156 gRandom->SetSeed(sseed);
de78d77f 157 cout<<"Seed for random number generation= "<<gRandom->GetSeed()<<endl;
36d4cb82 158
de78d77f 159
160 // libraries required by geant321
161#if defined(__CINT__)
c8921088 162 gSystem->Load("libgeant321");
de78d77f 163#endif
c8921088 164
b0470150 165 new TGeant3TGeo("C++ Interface to Geant3");
36d4cb82 166
458041af 167 if(!AliCDBManager::Instance()->IsDefaultStorageSet()){
168 AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
169 AliCDBManager::Instance()->SetRun(0);
170 }
171
de78d77f 172 AliRunLoader* rl=0x0;
36d4cb82 173
27c7e486 174 AliLog::Message(AliLog::kInfo, "Creating Run Loader", "", "", "Config()"," ConfigPPR.C", __LINE__);
ad38c0e5 175
de78d77f 176 rl = AliRunLoader::Open("galice.root",
5295b11b 177 AliConfig::GetDefaultEventFolderName(),
de78d77f 178 "recreate");
179 if (rl == 0x0)
180 {
181 gAlice->Fatal("Config.C","Can not instatiate the Run Loader");
182 return;
183 }
184 rl->SetCompressionLevel(2);
185 rl->SetNumberOfEventsPerFile(3);
186 gAlice->SetRunLoader(rl);
458041af 187 // gAlice->SetGeometryFromFile("geometry.root");
188 // gAlice->SetGeometryFromCDB();
36d4cb82 189
b34c4a51 190 // Set the trigger configuration
191 gAlice->SetTriggerDescriptor(pprTrigConfName[strig]);
192 cout<<"Trigger configuration is set to "<<pprTrigConfName[strig]<<endl;
193
36d4cb82 194 //
195 // Set External decayer
196 AliDecayer *decayer = new AliDecayerPythia();
197
5d185da5 198
199 switch (srun) {
200 case kD0PbPb5500:
201 decayer->SetForceDecay(kHadronicD);
202 break;
203 case kCharmSemiElPbPb5500:
204 decayer->SetForceDecay(kSemiElectronic);
205 break;
206 case kBeautySemiElPbPb5500:
207 decayer->SetForceDecay(kSemiElectronic);
208 break;
209 default:
210 decayer->SetForceDecay(kAll);
211 break;
212 }
36d4cb82 213 decayer->Init();
214 gMC->SetExternalDecayer(decayer);
215 //
216 //
217 //=======================================================================
36d4cb82 218 //
219 //=======================================================================
220 // ************* STEERING parameters FOR ALICE SIMULATION **************
221 // --- Specify event type to be tracked through the ALICE setup
222 // --- All positions are in cm, angles in degrees, and P and E in GeV
223
6a3df6c9 224 gMC->SetProcess("DCAY",1);
225 gMC->SetProcess("PAIR",1);
226 gMC->SetProcess("COMP",1);
227 gMC->SetProcess("PHOT",1);
228 gMC->SetProcess("PFIS",0);
229 gMC->SetProcess("DRAY",0);
230 gMC->SetProcess("ANNI",1);
231 gMC->SetProcess("BREM",1);
232 gMC->SetProcess("MUNU",1);
233 gMC->SetProcess("CKOV",1);
234 gMC->SetProcess("HADR",1);
235 gMC->SetProcess("LOSS",2);
236 gMC->SetProcess("MULS",1);
237 gMC->SetProcess("RAYL",1);
238
239 Float_t cut = 1.e-3; // 1MeV cut by default
240 Float_t tofmax = 1.e10;
241
242 gMC->SetCut("CUTGAM", cut);
243 gMC->SetCut("CUTELE", cut);
244 gMC->SetCut("CUTNEU", cut);
245 gMC->SetCut("CUTHAD", cut);
246 gMC->SetCut("CUTMUO", cut);
247 gMC->SetCut("BCUTE", cut);
248 gMC->SetCut("BCUTM", cut);
249 gMC->SetCut("DCUTE", cut);
250 gMC->SetCut("DCUTM", cut);
251 gMC->SetCut("PPCUTM", cut);
252 gMC->SetCut("TOFMAX", tofmax);
253
b03cb1f2 254 // Debug and log level
255 AliLog::SetGlobalDebugLevel(0);
87d24ab1 256 AliLog::SetGlobalLogLevel(AliLog::kError);
36d4cb82 257
b03cb1f2 258 // Generator Configuration
de78d77f 259 AliGenerator* gener = GeneratorFactory(srun);
36d4cb82 260 gener->SetOrigin(0, 0, 0); // vertex position
261 gener->SetSigma(0, 0, 5.3); // Sigma in (X,Y,Z) (cm) on IP position
262 gener->SetCutVertexZ(1.); // Truncate at 1 sigma
263 gener->SetVertexSmear(kPerEvent);
264 gener->SetTrackingFlag(1);
265 gener->Init();
cf3f928d 266
de78d77f 267 if (smag == k2kG) {
cf3f928d 268 comment = comment.Append(" | L3 field 0.2 T");
de78d77f 269 } else if (smag == k4kG) {
cf3f928d 270 comment = comment.Append(" | L3 field 0.4 T");
de78d77f 271 } else if (smag == k5kG) {
cf3f928d 272 comment = comment.Append(" | L3 field 0.5 T");
273 }
274
275
de78d77f 276 if (srad == kGluonRadiation)
36d4cb82 277 {
278 comment = comment.Append(" | Gluon Radiation On");
279
280 } else {
281 comment = comment.Append(" | Gluon Radiation Off");
282 }
283
de78d77f 284 printf("\n \n Comment: %s \n \n", comment.Data());
36d4cb82 285
286
287// Field (L3 0.4 T)
de78d77f 288 AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 2, 1., 10., smag);
b8cec322 289 field->SetL3ConstField(0); //Using const. field in the barrel
de78d77f 290 rl->CdGAFile();
c9397ade 291 gAlice->SetField(field);
36d4cb82 292//
293 Int_t iABSO = 1;
36d4cb82 294 Int_t iDIPO = 1;
295 Int_t iFMD = 1;
296 Int_t iFRAME = 1;
297 Int_t iHALL = 1;
298 Int_t iITS = 1;
299 Int_t iMAG = 1;
300 Int_t iMUON = 1;
301 Int_t iPHOS = 1;
302 Int_t iPIPE = 1;
303 Int_t iPMD = 1;
de1857bb 304 Int_t iHMPID = 1;
36d4cb82 305 Int_t iSHIL = 1;
ababa197 306 Int_t iT0 = 1;
36d4cb82 307 Int_t iTOF = 1;
308 Int_t iTPC = 1;
309 Int_t iTRD = 1;
310 Int_t iZDC = 1;
7d0b3b31 311 Int_t iEMCAL = 1;
cf3f928d 312 Int_t iVZERO = 1;
b384f8a4 313 Int_t iACORDE = 0;
36d4cb82 314
315 //=================== Alice BODY parameters =============================
316 AliBODY *BODY = new AliBODY("BODY", "Alice envelop");
317
318
319 if (iMAG)
320 {
321 //=================== MAG parameters ============================
322 // --- Start with Magnet since detector layouts may be depending ---
323 // --- on the selected Magnet dimensions ---
324 AliMAG *MAG = new AliMAG("MAG", "Magnet");
325 }
326
327
328 if (iABSO)
329 {
330 //=================== ABSO parameters ============================
96fb3353 331 AliABSO *ABSO = new AliABSOv3("ABSO", "Muon Absorber");
36d4cb82 332 }
333
334 if (iDIPO)
335 {
336 //=================== DIPO parameters ============================
337
96fb3353 338 AliDIPO *DIPO = new AliDIPOv3("DIPO", "Dipole version 3");
36d4cb82 339 }
340
341 if (iHALL)
342 {
343 //=================== HALL parameters ============================
344
96fb3353 345 AliHALL *HALL = new AliHALLv3("HALL", "Alice Hall");
36d4cb82 346 }
347
348
349 if (iFRAME)
350 {
351 //=================== FRAME parameters ============================
352
353 AliFRAMEv2 *FRAME = new AliFRAMEv2("FRAME", "Space Frame");
6b612c2d 354 if (geo == kHoles) {
355 FRAME->SetHoles(1);
356 } else {
357 FRAME->SetHoles(0);
358 }
36d4cb82 359 }
360
361 if (iSHIL)
362 {
363 //=================== SHIL parameters ============================
364
96fb3353 365 AliSHIL *SHIL = new AliSHILv3("SHIL", "Shielding Version 3");
36d4cb82 366 }
367
368
369 if (iPIPE)
370 {
371 //=================== PIPE parameters ============================
372
96fb3353 373 AliPIPE *PIPE = new AliPIPEv3("PIPE", "Beam Pipe");
36d4cb82 374 }
375
e89fa83b 376 if (iITS)
377 {
378 //=================== ITS parameters ============================
36d4cb82 379
e1cd8da1 380 AliITSvPPRasymmFMD *ITS = new AliITSvPPRasymmFMD("ITS","New ITS PPR detailed version with asymmetric services");
e810b5b5 381 }
36d4cb82 382
383 if (iTPC)
384 {
26ca4b4a 385 //============================ TPC parameters =====================
36d4cb82 386 AliTPC *TPC = new AliTPCv2("TPC", "Default");
36d4cb82 387 }
388
e810b5b5 389
36d4cb82 390 if (iTOF) {
36d4cb82 391 //=================== TOF parameters ============================
0d7ef405 392 AliTOF *TOF = new AliTOFv6T0("TOF", "normal TOF");
36d4cb82 393 }
394
e810b5b5 395
de1857bb 396 if (iHMPID)
36d4cb82 397 {
de1857bb 398 //=================== HMPID parameters ===========================
55eb2b56 399 AliHMPID *HMPID = new AliHMPIDv2("HMPID", "normal HMPID");
36d4cb82 400
401 }
402
403
404 if (iZDC)
405 {
406 //=================== ZDC parameters ============================
407
9d07603a 408 AliZDC *ZDC = new AliZDCv3("ZDC", "normal ZDC");
36d4cb82 409 }
410
36d4cb82 411 if (iTRD)
412 {
413 //=================== TRD parameters ============================
414
415 AliTRD *TRD = new AliTRDv1("TRD", "TRD slow simulator");
36d4cb82 416 }
417
418 if (iFMD)
419 {
420 //=================== FMD parameters ============================
657f2294 421 AliFMD *FMD = new AliFMDv1("FMD", "normal FMD");
36d4cb82 422 }
423
424 if (iMUON)
425 {
426 //=================== MUON parameters ===========================
d85afa9b 427 // New MUONv1 version (geometry defined via builders)
36d4cb82 428 AliMUON *MUON = new AliMUONv1("MUON", "default");
429 }
430 //=================== PHOS parameters ===========================
431
432 if (iPHOS)
433 {
434 AliPHOS *PHOS = new AliPHOSv1("PHOS", "IHEP");
435 }
436
437
438 if (iPMD)
439 {
440 //=================== PMD parameters ============================
441 AliPMD *PMD = new AliPMDv1("PMD", "normal PMD");
36d4cb82 442 }
443
ababa197 444 if (iT0)
36d4cb82 445 {
ababa197 446 //=================== T0 parameters ============================
447 AliT0 *T0 = new AliT0v1("T0", "T0 Detector");
36d4cb82 448 }
449
21e394f9 450 if (iEMCAL)
36d4cb82 451 {
452 //=================== EMCAL parameters ============================
0588179e 453 AliEMCAL *EMCAL = new AliEMCALv2("EMCAL", "SHISH_77_TRD1_2X2_FINAL_110DEG");
36d4cb82 454 }
21e394f9 455
b384f8a4 456 if (iACORDE)
21e394f9 457 {
b384f8a4 458 //=================== ACORDE parameters ============================
459 AliACORDE *ACORDE = new AliACORDEv0("ACORDE", "normal ACORDE");
21e394f9 460 }
cf3f928d 461
462 if (iVZERO)
463 {
fe229631 464 //=================== VZERO parameters ============================
4a2f6442 465 AliVZERO *VZERO = new AliVZEROv7("VZERO", "normal VZERO");
cf3f928d 466 }
21e394f9 467
468
36d4cb82 469}
470
471Float_t EtaToTheta(Float_t arg){
472 return (180./TMath::Pi())*2.*atan(exp(-arg));
473}
474
475
476
de78d77f 477AliGenerator* GeneratorFactory(PprRun_t srun) {
36d4cb82 478 Int_t isw = 3;
de78d77f 479 if (srad == kNoGluonRadiation) isw = 0;
36d4cb82 480
481
de78d77f 482 AliGenerator * gGener = 0x0;
483 switch (srun) {
36d4cb82 484 case test50:
de78d77f 485 {
36d4cb82 486 comment = comment.Append(":HIJINGparam test 50 particles");
487 AliGenHIJINGpara *gener = new AliGenHIJINGpara(50);
488 gener->SetMomentumRange(0, 999999.);
0ac28de4 489 gener->SetPhiRange(0., 360.);
36d4cb82 490 // Set pseudorapidity range from -8 to 8.
491 Float_t thmin = EtaToTheta(8); // theta min. <---> eta max
492 Float_t thmax = EtaToTheta(-8); // theta max. <---> eta min
493 gener->SetThetaRange(thmin,thmax);
de78d77f 494 gGener=gener;
495 }
bd3a65b4 496 break;
36d4cb82 497 case kParam_8000:
de78d77f 498 {
36d4cb82 499 comment = comment.Append(":HIJINGparam N=8000");
500 AliGenHIJINGpara *gener = new AliGenHIJINGpara(86030);
501 gener->SetMomentumRange(0, 999999.);
0ac28de4 502 gener->SetPhiRange(0., 360.);
36d4cb82 503 // Set pseudorapidity range from -8 to 8.
504 Float_t thmin = EtaToTheta(8); // theta min. <---> eta max
505 Float_t thmax = EtaToTheta(-8); // theta max. <---> eta min
506 gener->SetThetaRange(thmin,thmax);
de78d77f 507 gGener=gener;
508 }
bd3a65b4 509 break;
36d4cb82 510 case kParam_4000:
de78d77f 511 {
36d4cb82 512 comment = comment.Append("HIJINGparam N=4000");
513 AliGenHIJINGpara *gener = new AliGenHIJINGpara(43015);
514 gener->SetMomentumRange(0, 999999.);
0ac28de4 515 gener->SetPhiRange(0., 360.);
36d4cb82 516 // Set pseudorapidity range from -8 to 8.
517 Float_t thmin = EtaToTheta(8); // theta min. <---> eta max
518 Float_t thmax = EtaToTheta(-8); // theta max. <---> eta min
519 gener->SetThetaRange(thmin,thmax);
de78d77f 520 gGener=gener;
521 }
36d4cb82 522 break;
523 case kParam_2000:
de78d77f 524 {
36d4cb82 525 comment = comment.Append("HIJINGparam N=2000");
526 AliGenHIJINGpara *gener = new AliGenHIJINGpara(21507);
527 gener->SetMomentumRange(0, 999999.);
0ac28de4 528 gener->SetPhiRange(0., 360.);
36d4cb82 529 // Set pseudorapidity range from -8 to 8.
530 Float_t thmin = EtaToTheta(8); // theta min. <---> eta max
531 Float_t thmax = EtaToTheta(-8); // theta max. <---> eta min
532 gener->SetThetaRange(thmin,thmax);
de78d77f 533 gGener=gener;
534 }
bd3a65b4 535 break;
36d4cb82 536//
537// Hijing Central
538//
539 case kHijing_cent1:
de78d77f 540 {
36d4cb82 541 comment = comment.Append("HIJING cent1");
542 AliGenHijing *gener = HijingStandard();
543// impact parameter range
544 gener->SetImpactParameterRange(0., 5.);
de78d77f 545 gGener=gener;
546 }
bd3a65b4 547 break;
36d4cb82 548 case kHijing_cent2:
de78d77f 549 {
36d4cb82 550 comment = comment.Append("HIJING cent2");
551 AliGenHijing *gener = HijingStandard();
552// impact parameter range
553 gener->SetImpactParameterRange(0., 2.);
de78d77f 554 gGener=gener;
de78d77f 555 }
bd3a65b4 556 break;
36d4cb82 557//
558// Hijing Peripheral
559//
560 case kHijing_per1:
de78d77f 561 {
36d4cb82 562 comment = comment.Append("HIJING per1");
563 AliGenHijing *gener = HijingStandard();
564// impact parameter range
565 gener->SetImpactParameterRange(5., 8.6);
de78d77f 566 gGener=gener;
567 }
bd3a65b4 568 break;
36d4cb82 569 case kHijing_per2:
de78d77f 570 {
36d4cb82 571 comment = comment.Append("HIJING per2");
572 AliGenHijing *gener = HijingStandard();
573// impact parameter range
574 gener->SetImpactParameterRange(8.6, 11.2);
de78d77f 575 gGener=gener;
576 }
bd3a65b4 577 break;
36d4cb82 578 case kHijing_per3:
de78d77f 579 {
36d4cb82 580 comment = comment.Append("HIJING per3");
581 AliGenHijing *gener = HijingStandard();
582// impact parameter range
583 gener->SetImpactParameterRange(11.2, 13.2);
de78d77f 584 gGener=gener;
585 }
bd3a65b4 586 break;
36d4cb82 587 case kHijing_per4:
de78d77f 588 {
36d4cb82 589 comment = comment.Append("HIJING per4");
590 AliGenHijing *gener = HijingStandard();
591// impact parameter range
592 gener->SetImpactParameterRange(13.2, 15.);
de78d77f 593 gGener=gener;
594 }
bd3a65b4 595 break;
36d4cb82 596 case kHijing_per5:
de78d77f 597 {
36d4cb82 598 comment = comment.Append("HIJING per5");
599 AliGenHijing *gener = HijingStandard();
600// impact parameter range
601 gener->SetImpactParameterRange(15., 100.);
de78d77f 602 gGener=gener;
603 }
bd3a65b4 604 break;
36d4cb82 605//
606// Jet-Jet
607//
608 case kHijing_jj25:
de78d77f 609 {
36d4cb82 610 comment = comment.Append("HIJING Jet 25 GeV");
611 AliGenHijing *gener = HijingStandard();
612// impact parameter range
613 gener->SetImpactParameterRange(0., 5.);
614 // trigger
615 gener->SetTrigger(1);
433185a9 616 gener->SetPtJet(25.);
36d4cb82 617 gener->SetRadiation(isw);
433185a9 618 gener->SetSimpleJets(!isw);
619 gener->SetJetEtaRange(-0.3,0.3);
620 gener->SetJetPhiRange(75., 165.);
de78d77f 621 gGener=gener;
622 }
bd3a65b4 623 break;
36d4cb82 624
625 case kHijing_jj50:
de78d77f 626 {
36d4cb82 627 comment = comment.Append("HIJING Jet 50 GeV");
628 AliGenHijing *gener = HijingStandard();
629// impact parameter range
630 gener->SetImpactParameterRange(0., 5.);
631 // trigger
632 gener->SetTrigger(1);
433185a9 633 gener->SetPtJet(50.);
36d4cb82 634 gener->SetRadiation(isw);
433185a9 635 gener->SetSimpleJets(!isw);
636 gener->SetJetEtaRange(-0.3,0.3);
637 gener->SetJetPhiRange(75., 165.);
de78d77f 638 gGener=gener;
639 }
36d4cb82 640 break;
641
642 case kHijing_jj75:
de78d77f 643 {
36d4cb82 644 comment = comment.Append("HIJING Jet 75 GeV");
645 AliGenHijing *gener = HijingStandard();
646// impact parameter range
647 gener->SetImpactParameterRange(0., 5.);
648 // trigger
649 gener->SetTrigger(1);
433185a9 650 gener->SetPtJet(75.);
36d4cb82 651 gener->SetRadiation(isw);
433185a9 652 gener->SetSimpleJets(!isw);
653 gener->SetJetEtaRange(-0.3,0.3);
654 gener->SetJetPhiRange(75., 165.);
de78d77f 655 gGener=gener;
656 }
bd3a65b4 657 break;
36d4cb82 658
659 case kHijing_jj100:
de78d77f 660 {
36d4cb82 661 comment = comment.Append("HIJING Jet 100 GeV");
662 AliGenHijing *gener = HijingStandard();
663// impact parameter range
664 gener->SetImpactParameterRange(0., 5.);
665 // trigger
666 gener->SetTrigger(1);
433185a9 667 gener->SetPtJet(100.);
36d4cb82 668 gener->SetRadiation(isw);
433185a9 669 gener->SetSimpleJets(!isw);
670 gener->SetJetEtaRange(-0.3,0.3);
671 gener->SetJetPhiRange(75., 165.);
de78d77f 672 gGener=gener;
673 }
bd3a65b4 674 break;
36d4cb82 675
433185a9 676 case kHijing_jj200:
de78d77f 677 {
433185a9 678 comment = comment.Append("HIJING Jet 200 GeV");
36d4cb82 679 AliGenHijing *gener = HijingStandard();
680// impact parameter range
681 gener->SetImpactParameterRange(0., 5.);
682 // trigger
683 gener->SetTrigger(1);
433185a9 684 gener->SetPtJet(200.);
36d4cb82 685 gener->SetRadiation(isw);
433185a9 686 gener->SetSimpleJets(!isw);
687 gener->SetJetEtaRange(-0.3,0.3);
688 gener->SetJetPhiRange(75., 165.);
de78d77f 689 gGener=gener;
690 }
bd3a65b4 691 break;
36d4cb82 692//
693// Gamma-Jet
694//
695 case kHijing_gj25:
de78d77f 696 {
36d4cb82 697 comment = comment.Append("HIJING Gamma 25 GeV");
698 AliGenHijing *gener = HijingStandard();
699// impact parameter range
700 gener->SetImpactParameterRange(0., 5.);
701 // trigger
702 gener->SetTrigger(2);
433185a9 703 gener->SetPtJet(25.);
36d4cb82 704 gener->SetRadiation(isw);
433185a9 705 gener->SetSimpleJets(!isw);
706 gener->SetJetEtaRange(-0.12, 0.12);
707 gener->SetJetPhiRange(220., 320.);
de78d77f 708 gGener=gener;
709 }
bd3a65b4 710 break;
36d4cb82 711
712 case kHijing_gj50:
de78d77f 713 {
36d4cb82 714 comment = comment.Append("HIJING Gamma 50 GeV");
715 AliGenHijing *gener = HijingStandard();
716// impact parameter range
717 gener->SetImpactParameterRange(0., 5.);
718 // trigger
719 gener->SetTrigger(2);
433185a9 720 gener->SetPtJet(50.);
36d4cb82 721 gener->SetRadiation(isw);
433185a9 722 gener->SetSimpleJets(!isw);
723 gener->SetJetEtaRange(-0.12, 0.12);
724 gener->SetJetPhiRange(220., 320.);
de78d77f 725 gGener=gener;
726 }
bd3a65b4 727 break;
36d4cb82 728
729 case kHijing_gj75:
de78d77f 730 {
36d4cb82 731 comment = comment.Append("HIJING Gamma 75 GeV");
732 AliGenHijing *gener = HijingStandard();
733// impact parameter range
734 gener->SetImpactParameterRange(0., 5.);
735 // trigger
736 gener->SetTrigger(2);
433185a9 737 gener->SetPtJet(75.);
36d4cb82 738 gener->SetRadiation(isw);
433185a9 739 gener->SetSimpleJets(!isw);
740 gener->SetJetEtaRange(-0.12, 0.12);
741 gener->SetJetPhiRange(220., 320.);
de78d77f 742 gGener=gener;
743 }
bd3a65b4 744 break;
36d4cb82 745
746 case kHijing_gj100:
de78d77f 747 {
36d4cb82 748 comment = comment.Append("HIJING Gamma 100 GeV");
749 AliGenHijing *gener = HijingStandard();
750// impact parameter range
751 gener->SetImpactParameterRange(0., 5.);
752 // trigger
753 gener->SetTrigger(2);
433185a9 754 gener->SetPtJet(100.);
36d4cb82 755 gener->SetRadiation(isw);
433185a9 756 gener->SetSimpleJets(!isw);
757 gener->SetJetEtaRange(-0.12, 0.12);
758 gener->SetJetPhiRange(220., 320.);
de78d77f 759 gGener=gener;
760 }
bd3a65b4 761 break;
36d4cb82 762
433185a9 763 case kHijing_gj200:
de78d77f 764 {
433185a9 765 comment = comment.Append("HIJING Gamma 200 GeV");
36d4cb82 766 AliGenHijing *gener = HijingStandard();
767// impact parameter range
768 gener->SetImpactParameterRange(0., 5.);
769 // trigger
770 gener->SetTrigger(2);
433185a9 771 gener->SetPtJet(200.);
36d4cb82 772 gener->SetRadiation(isw);
433185a9 773 gener->SetSimpleJets(!isw);
774 gener->SetJetEtaRange(-0.12, 0.12);
775 gener->SetJetPhiRange(220., 320.);
de78d77f 776 gGener=gener;
777 }
bd3a65b4 778 break;
bc3e0a09 779 case kHijing_pA:
de78d77f 780 {
bc3e0a09 781 comment = comment.Append("HIJING pA");
782
783 AliGenCocktail *gener = new AliGenCocktail();
78e738e5 784
bc3e0a09 785 AliGenHijing *hijing = new AliGenHijing(-1);
786// centre of mass energy
787 hijing->SetEnergyCMS(TMath::Sqrt(82./208.) * 14000.);
788// impact parameter range
789 hijing->SetImpactParameterRange(0., 15.);
790// reference frame
791 hijing->SetReferenceFrame("CMS");
792 hijing->SetBoostLHC(1);
793// projectile
794 hijing->SetProjectile("P", 1, 1);
795 hijing->SetTarget ("A", 208, 82);
796// tell hijing to keep the full parent child chain
797 hijing->KeepFullEvent();
798// enable jet quenching
799 hijing->SetJetQuenching(0);
800// enable shadowing
801 hijing->SetShadowing(1);
802// Don't track spectators
803 hijing->SetSpectators(0);
804// kinematic selection
805 hijing->SetSelectAll(0);
806//
807 AliGenSlowNucleons* gray = new AliGenSlowNucleons(1);
808 AliSlowNucleonModel* model = new AliSlowNucleonModelExp();
809 gray->SetSlowNucleonModel(model);
810 gray->SetDebug(1);
811 gener->AddGenerator(hijing,"Hijing pPb", 1);
812 gener->AddGenerator(gray, "Gray Particles",1);
de78d77f 813 gGener=gener;
814 }
bd3a65b4 815 break;
1458d037 816 case kPythia6:
de78d77f 817 {
818 comment = comment.Append(":Pythia p-p @ 14 TeV");
819 AliGenPythia *gener = new AliGenPythia(-1);
820 gener->SetMomentumRange(0,999999);
de78d77f 821 gener->SetThetaRange(0., 180.);
822 gener->SetYRange(-12,12);
823 gener->SetPtRange(0,1000);
de78d77f 824 gener->SetProcess(kPyMb);
825 gener->SetEnergyCMS(14000.);
826 gGener=gener;
827 }
bd3a65b4 828 break;
13051068 829 case kPythia6Jets20_24:
b8cec322 830 {
13051068 831 comment = comment.Append(":Pythia jets 20-24 GeV @ 5.5 TeV");
832 AliGenPythia * gener = new AliGenPythia(-1);
833 gener->SetEnergyCMS(5500.);// Centre of mass energy
834 gener->SetProcess(kPyJets);// Process type
835 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
836 gener->SetJetPhiRange(0., 360.);
837 gener->SetJetEtRange(10., 1000.);
838 gener->SetGluonRadiation(1,1);
839 // gener->SetPtKick(0.);
840 // Structure function
841 gener->SetStrucFunc(kCTEQ4L);
842 gener->SetPtHard(20., 24.);// Pt transfer of the hard scattering
843 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
844 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
845 gGener=gener;
846 }
847 break;
848 case kPythia6Jets24_29:
849 {
850 comment = comment.Append(":Pythia jets 24-29 GeV @ 5.5 TeV");
851 AliGenPythia * gener = new AliGenPythia(-1);
852 gener->SetEnergyCMS(5500.);// Centre of mass energy
853 gener->SetProcess(kPyJets);// Process type
854 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
855 gener->SetJetPhiRange(0., 360.);
856 gener->SetJetEtRange(10., 1000.);
857 gener->SetGluonRadiation(1,1);
858 // gener->SetPtKick(0.);
859 // Structure function
860 gener->SetStrucFunc(kCTEQ4L);
861 gener->SetPtHard(24., 29.);// Pt transfer of the hard scattering
862 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
863 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
864 gGener=gener;
865 }
866 break;
867 case kPythia6Jets29_35:
868 {
869 comment = comment.Append(":Pythia jets 29-35 GeV @ 5.5 TeV");
870 AliGenPythia * gener = new AliGenPythia(-1);
871 gener->SetEnergyCMS(5500.);// Centre of mass energy
872 gener->SetProcess(kPyJets);// Process type
873 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
874 gener->SetJetPhiRange(0., 360.);
875 gener->SetJetEtRange(10., 1000.);
876 gener->SetGluonRadiation(1,1);
877 // gener->SetPtKick(0.);
878 // Structure function
879 gener->SetStrucFunc(kCTEQ4L);
880 gener->SetPtHard(29., 35.);// Pt transfer of the hard scattering
881 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
882 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
883 gGener=gener;
884 }
885 break;
886 case kPythia6Jets35_42:
887 {
888 comment = comment.Append(":Pythia jets 35-42 GeV @ 5.5 TeV");
889 AliGenPythia * gener = new AliGenPythia(-1);
890 gener->SetEnergyCMS(5500.);// Centre of mass energy
891 gener->SetProcess(kPyJets);// Process type
892 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
893 gener->SetJetPhiRange(0., 360.);
894 gener->SetJetEtRange(10., 1000.);
895 gener->SetGluonRadiation(1,1);
896 // gener->SetPtKick(0.);
897 // Structure function
898 gener->SetStrucFunc(kCTEQ4L);
899 gener->SetPtHard(35., 42.);// Pt transfer of the hard scattering
900 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
901 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
902 gGener=gener;
903 }
904 break;
905 case kPythia6Jets42_50:
906 {
907 comment = comment.Append(":Pythia jets 42-50 GeV @ 5.5 TeV");
908 AliGenPythia * gener = new AliGenPythia(-1);
909 gener->SetEnergyCMS(5500.);// Centre of mass energy
910 gener->SetProcess(kPyJets);// Process type
911 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
912 gener->SetJetPhiRange(0., 360.);
913 gener->SetJetEtRange(10., 1000.);
914 gener->SetGluonRadiation(1,1);
915 // gener->SetPtKick(0.);
916 // Structure function
917 gener->SetStrucFunc(kCTEQ4L);
918 gener->SetPtHard(42., 50.);// Pt transfer of the hard scattering
919 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
920 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
921 gGener=gener;
922 }
923 break;
924 case kPythia6Jets50_60:
925 {
926 comment = comment.Append(":Pythia jets 50-60 GeV @ 5.5 TeV");
927 AliGenPythia * gener = new AliGenPythia(-1);
928 gener->SetEnergyCMS(5500.);// Centre of mass energy
929 gener->SetProcess(kPyJets);// Process type
930 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
931 gener->SetJetPhiRange(0., 360.);
932 gener->SetJetEtRange(10., 1000.);
933 gener->SetGluonRadiation(1,1);
934 // gener->SetPtKick(0.);
935 // Structure function
936 gener->SetStrucFunc(kCTEQ4L);
937 gener->SetPtHard(50., 60.);// Pt transfer of the hard scattering
938 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
939 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
940 gGener=gener;
941 }
942 break;
943 case kPythia6Jets60_72:
944 {
945 comment = comment.Append(":Pythia jets 60-72 GeV @ 5.5 TeV");
946 AliGenPythia * gener = new AliGenPythia(-1);
947 gener->SetEnergyCMS(5500.);// Centre of mass energy
948 gener->SetProcess(kPyJets);// Process type
949 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
950 gener->SetJetPhiRange(0., 360.);
951 gener->SetJetEtRange(10., 1000.);
952 gener->SetGluonRadiation(1,1);
953 // gener->SetPtKick(0.);
954 // Structure function
955 gener->SetStrucFunc(kCTEQ4L);
956 gener->SetPtHard(60., 72.);// Pt transfer of the hard scattering
957 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
958 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
959 gGener=gener;
960 }
961 break;
962 case kPythia6Jets72_86:
963 {
964 comment = comment.Append(":Pythia jets 72-86 GeV @ 5.5 TeV");
965 AliGenPythia * gener = new AliGenPythia(-1);
966 gener->SetEnergyCMS(5500.);// Centre of mass energy
967 gener->SetProcess(kPyJets);// Process type
968 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
969 gener->SetJetPhiRange(0., 360.);
970 gener->SetJetEtRange(10., 1000.);
971 gener->SetGluonRadiation(1,1);
972 // gener->SetPtKick(0.);
973 // Structure function
974 gener->SetStrucFunc(kCTEQ4L);
975 gener->SetPtHard(72., 86.);// Pt transfer of the hard scattering
976 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
977 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
978 gGener=gener;
979 }
980 break;
981 case kPythia6Jets86_104:
982 {
983 comment = comment.Append(":Pythia jets 86-104 GeV @ 5.5 TeV");
bd3a65b4 984 AliGenPythia * gener = new AliGenPythia(-1);
b8cec322 985 gener->SetEnergyCMS(5500.);// Centre of mass energy
986 gener->SetProcess(kPyJets);// Process type
987 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
988 gener->SetJetPhiRange(0., 360.);
989 gener->SetJetEtRange(10., 1000.);
990 gener->SetGluonRadiation(1,1);
991 // gener->SetPtKick(0.);
992 // Structure function
993 gener->SetStrucFunc(kCTEQ4L);
994 gener->SetPtHard(86., 104.);// Pt transfer of the hard scattering
995 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
996 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
997 gGener=gener;
998 }
bd3a65b4 999 break;
13051068 1000 case kPythia6Jets104_125:
1001 {
1002 comment = comment.Append(":Pythia jets 105-125 GeV @ 5.5 TeV");
1003 AliGenPythia * gener = new AliGenPythia(-1);
1004 gener->SetEnergyCMS(5500.);// Centre of mass energy
1005 gener->SetProcess(kPyJets);// Process type
1006 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
1007 gener->SetJetPhiRange(0., 360.);
1008 gener->SetJetEtRange(10., 1000.);
1009 gener->SetGluonRadiation(1,1);
1010 // gener->SetPtKick(0.);
1011 // Structure function
1012 gener->SetStrucFunc(kCTEQ4L);
1013 gener->SetPtHard(104., 125.);// Pt transfer of the hard scattering
1014 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
1015 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
1016 gGener=gener;
1017 }
1018 break;
1019 case kPythia6Jets125_150:
1020 {
1021 comment = comment.Append(":Pythia jets 125-150 GeV @ 5.5 TeV");
1022 AliGenPythia * gener = new AliGenPythia(-1);
1023 gener->SetEnergyCMS(5500.);// Centre of mass energy
1024 gener->SetProcess(kPyJets);// Process type
1025 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
1026 gener->SetJetPhiRange(0., 360.);
1027 gener->SetJetEtRange(10., 1000.);
1028 gener->SetGluonRadiation(1,1);
1029 // gener->SetPtKick(0.);
1030 // Structure function
1031 gener->SetStrucFunc(kCTEQ4L);
1032 gener->SetPtHard(125., 150.);// Pt transfer of the hard scattering
1033 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
1034 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
1035 gGener=gener;
1036 }
1037 break;
1038 case kPythia6Jets150_180:
1039 {
1040 comment = comment.Append(":Pythia jets 150-180 GeV @ 5.5 TeV");
1041 AliGenPythia * gener = new AliGenPythia(-1);
1042 gener->SetEnergyCMS(5500.);// Centre of mass energy
1043 gener->SetProcess(kPyJets);// Process type
1044 gener->SetJetEtaRange(-0.5, 0.5);// Final state kinematic cuts
1045 gener->SetJetPhiRange(0., 360.);
1046 gener->SetJetEtRange(10., 1000.);
1047 gener->SetGluonRadiation(1,1);
1048 // gener->SetPtKick(0.);
1049 // Structure function
1050 gener->SetStrucFunc(kCTEQ4L);
1051 gener->SetPtHard(150., 180.);// Pt transfer of the hard scattering
1052 gener->SetPycellParameters(2., 274, 432, 0., 4., 5., 1.0);
1053 gener->SetForceDecay(kAll);// Decay type (semielectronic, etc.)
1054 gGener=gener;
1055 }
1056 break;
bd3a65b4 1057 case kD0PbPb5500:
1058 {
1059 comment = comment.Append(" D0 in Pb-Pb at 5.5 TeV");
1060 AliGenPythia * gener = new AliGenPythia(10);
1061 gener->SetProcess(kPyD0PbPbMNR);
1062 gener->SetStrucFunc(kCTEQ4L);
1063 gener->SetPtHard(2.1,-1.0);
1064 gener->SetEnergyCMS(5500.);
1065 gener->SetNuclei(208,208);
5d185da5 1066 gener->SetForceDecay(kHadronicD);
1067 gener->SetYRange(-2,2);
1068 gener->SetFeedDownHigherFamily(kFALSE);
1069 gener->SetStackFillOpt(AliGenPythia::kParentSelection);
1070 gener->SetCountMode(AliGenPythia::kCountParents);
1071 gGener=gener;
1072 }
1073 break;
1074 case kCharmSemiElPbPb5500:
1075 {
1076 comment = comment.Append(" Charm in Pb-Pb at 5.5 TeV");
1077 AliGenPythia * gener = new AliGenPythia(10);
1078 gener->SetProcess(kPyCharmPbPbMNR);
1079 gener->SetStrucFunc(kCTEQ4L);
1080 gener->SetPtHard(2.1,-1.0);
1081 gener->SetEnergyCMS(5500.);
1082 gener->SetNuclei(208,208);
1083 gener->SetForceDecay(kSemiElectronic);
1084 gener->SetYRange(-2,2);
1085 gener->SetFeedDownHigherFamily(kFALSE);
1086 gener->SetCountMode(AliGenPythia::kCountParents);
1087 gGener=gener;
1088 }
1089 break;
1090 case kBeautySemiElPbPb5500:
1091 {
1092 comment = comment.Append(" Beauty in Pb-Pb at 5.5 TeV");
1093 AliGenPythia *gener = new AliGenPythia(10);
1094 gener->SetProcess(kPyBeautyPbPbMNR);
1095 gener->SetStrucFunc(kCTEQ4L);
1096 gener->SetPtHard(2.75,-1.0);
1097 gener->SetEnergyCMS(5500.);
1098 gener->SetNuclei(208,208);
1099 gener->SetForceDecay(kSemiElectronic);
1100 gener->SetYRange(-2,2);
1101 gener->SetFeedDownHigherFamily(kFALSE);
1102 gener->SetCountMode(AliGenPythia::kCountParents);
bd3a65b4 1103 gGener=gener;
1104 }
1105 break;
e860c7ea 1106 case kCocktailTRD:
78e738e5 1107 {
e860c7ea 1108 comment = comment.Append(" Cocktail for TRD at 5.5 TeV");
1109 AliGenCocktail *gener = new AliGenCocktail();
836ef9e4 1110
d3d5165e 1111 AliGenParam *phi = new AliGenParam(10,
1112 new AliGenMUONlib(),
1113 AliGenMUONlib::kPhi,
1114 "Vogt PbPb");
1115
1116 phi->SetPtRange(0, 100);
1117 phi->SetYRange(-1., +1.);
1118 phi->SetForceDecay(kDiElectron);
1119
1120 AliGenParam *omega = new AliGenParam(10,
1121 new AliGenMUONlib(),
1122 AliGenMUONlib::kOmega,
1123 "Vogt PbPb");
1124
1125 omega->SetPtRange(0, 100);
1126 omega->SetYRange(-1., +1.);
1127 omega->SetForceDecay(kDiElectron);
1128
e860c7ea 1129 AliGenParam *jpsi = new AliGenParam(10,
1130 new AliGenMUONlib(),
1131 AliGenMUONlib::kJpsiFamily,
1132 "Vogt PbPb");
1133
1134 jpsi->SetPtRange(0, 100);
1135 jpsi->SetYRange(-1., +1.);
1136 jpsi->SetForceDecay(kDiElectron);
1137
1138 AliGenParam *ups = new AliGenParam(10,
1139 new AliGenMUONlib(),
1140 AliGenMUONlib::kUpsilonFamily,
1141 "Vogt PbPb");
1142 ups->SetPtRange(0, 100);
1143 ups->SetYRange(-1., +1.);
1144 ups->SetForceDecay(kDiElectron);
1145
1146 AliGenParam *charm = new AliGenParam(10,
1147 new AliGenMUONlib(),
1148 AliGenMUONlib::kCharm,
1149 "central");
1150 charm->SetPtRange(0, 100);
1151 charm->SetYRange(-1.5, +1.5);
1152 charm->SetForceDecay(kSemiElectronic);
1153
1154
1155 AliGenParam *beauty = new AliGenParam(10,
1156 new AliGenMUONlib(),
1157 AliGenMUONlib::kBeauty,
1158 "central");
1159 beauty->SetPtRange(0, 100);
1160 beauty->SetYRange(-1.5, +1.5);
1161 beauty->SetForceDecay(kSemiElectronic);
1162
836ef9e4 1163 AliGenParam *beautyJ = new AliGenParam(10,
1164 new AliGenMUONlib(),
1165 AliGenMUONlib::kBeauty,
1166 "central");
1167 beautyJ->SetPtRange(0, 100);
1168 beautyJ->SetYRange(-1.5, +1.5);
1169 beautyJ->SetForceDecay(kBJpsiDiElectron);
1170
d3d5165e 1171 gener->AddGenerator(phi,"Phi",1);
1172 gener->AddGenerator(omega,"Omega",1);
e860c7ea 1173 gener->AddGenerator(jpsi,"J/psi",1);
1174 gener->AddGenerator(ups,"Upsilon",1);
1175 gener->AddGenerator(charm,"Charm",1);
1176 gener->AddGenerator(beauty,"Beauty",1);
836ef9e4 1177 gener->AddGenerator(beautyJ,"J/Psi from Beauty",1);
78e738e5 1178 gGener=gener;
1179 }
1180 break;
1181 case kPyJJ:
1182 {
1183 comment = comment.Append(" Jet-jet at 5.5 TeV");
1184 AliGenPythia *gener = new AliGenPythia(-1);
1185 gener->SetEnergyCMS(5500.);
1186 gener->SetProcess(kPyJets);
1187 Double_t ptHardMin=10.0, ptHardMax=-1.0;
1188 gener->SetPtHard(ptHardMin,ptHardMax);
1189 gener->SetYHard(-0.7,0.7);
1190 gener->SetJetEtaRange(-0.2,0.2);
1191 gener->SetEventListRange(0,1);
1192 gGener=gener;
1193 }
1194 break;
1195 case kPyGJ:
1196 {
1197 comment = comment.Append(" Gamma-jet at 5.5 TeV");
1198 AliGenPythia *gener = new AliGenPythia(-1);
1199 gener->SetEnergyCMS(5500.);
1200 gener->SetProcess(kPyDirectGamma);
1201 Double_t ptHardMin=10.0, ptHardMax=-1.0;
1202 gener->SetPtHard(ptHardMin,ptHardMax);
1203 gener->SetYHard(-1.0,1.0);
1204 gener->SetGammaEtaRange(-0.13,0.13);
1205 gener->SetGammaPhiRange(210.,330.);
1206 gener->SetEventListRange(0,1);
1207 gGener=gener;
1208 }
1209 break;
b984b0e1 1210 case kMuonCocktailCent1:
1211 {
1212 comment = comment.Append(" Muon Cocktail Cent1");
1213 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1214 gener->SetPtRange(0.4,100.); // Transverse momentum range
b984b0e1 1215 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1216 gener->SetYRange(-4.0,-2.4);
1217 gener->SetMuonPtCut(0.8);
1218 gener->SetMuonThetaCut(171.,178.);
1219 gener->SetMuonMultiplicity(2);
d4c80005 1220 gener->SetImpactParameterRange(0.,5.); //Centrality class Cent1 for PDC04
b984b0e1 1221 gGener=gener;
1222 }
1223 break;
1224 case kMuonCocktailPer1:
1225 {
1226 comment = comment.Append(" Muon Cocktail Per1");
1227 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1228 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1229 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1230 gener->SetYRange(-4.0,-2.4);
1231 gener->SetMuonPtCut(0.8);
1232 gener->SetMuonThetaCut(171.,178.);
1233 gener->SetMuonMultiplicity(2);
9c4fff20 1234 gener->SetImpactParameterRange(5.,8.6);//Centrality class Per1 for PDC04
b984b0e1 1235 gGener=gener;
1236 }
1237 break;
1238 case kMuonCocktailPer4:
1239 {
1240 comment = comment.Append(" Muon Cocktail Per4");
1241 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1242 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1243 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1244 gener->SetYRange(-4.0,-2.4);
1245 gener->SetMuonPtCut(0.8);
1246 gener->SetMuonThetaCut(171.,178.);
1247 gener->SetMuonMultiplicity(2);
9c4fff20 1248 gener->SetImpactParameterRange(13.2,15.0);//Centrality class Per4 for PDC04
b984b0e1 1249 gGener=gener;
1250 }
1251 break;
1252 case kMuonCocktailCent1HighPt:
1253 {
1254 comment = comment.Append(" Muon Cocktail HighPt Cent1");
1255 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1256 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1257 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1258 gener->SetYRange(-4.0,-2.4);
1259 gener->SetMuonPtCut(2.5);
1260 gener->SetMuonThetaCut(171.,178.);
1261 gener->SetMuonMultiplicity(2);
9c4fff20 1262 gener->SetImpactParameterRange(0.,5.); //Centrality class Cent1 for PDC04
b984b0e1 1263 gGener=gener;
1264 }
1265 break;
1266 case kMuonCocktailPer1HighPt :
1267 {
1268 comment = comment.Append(" Muon Cocktail HighPt Per1");
1269 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1270 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1271 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1272 gener->SetYRange(-4.0,-2.4);
1273 gener->SetMuonPtCut(2.5);
1274 gener->SetMuonThetaCut(171.,178.);
1275 gener->SetMuonMultiplicity(2);
9c4fff20 1276 gener->SetImpactParameterRange(5.,8.6);//Centrality class Per1 for PDC04
b984b0e1 1277 gGener=gener;
1278 }
1279 break;
1280 case kMuonCocktailPer4HighPt:
1281 {
1282 comment = comment.Append(" Muon Cocktail HighPt Per4");
1283 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1284 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1285 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1286 gener->SetYRange(-4.0,-2.4);
1287 gener->SetMuonPtCut(2.5);
1288 gener->SetMuonThetaCut(171.,178.);
1289 gener->SetMuonMultiplicity(2);
9c4fff20 1290 gener->SetImpactParameterRange(13.2,15.0);//Centrality class Per4 for PDC04
b984b0e1 1291 gGener=gener;
1292 }
1293 break;
1294 case kMuonCocktailCent1Single:
1295 {
1296 comment = comment.Append(" Muon Cocktail Single Cent1");
1297 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1298 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1299 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1300 gener->SetYRange(-4.0,-2.4);
1301 gener->SetMuonPtCut(0.8);
1302 gener->SetMuonThetaCut(171.,178.);
1303 gener->SetMuonMultiplicity(1);
9c4fff20 1304 gener->SetImpactParameterRange(0.,5.); //Centrality class Cent1 for PDC04
b984b0e1 1305 gGener=gener;
1306 }
1307 break;
1308 case kMuonCocktailPer1Single :
1309 {
1310 comment = comment.Append(" Muon Cocktail Single Per1");
1311 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1312 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1313 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1314 gener->SetYRange(-4.0,-2.4);
1315 gener->SetMuonPtCut(0.8);
1316 gener->SetMuonThetaCut(171.,178.);
1317 gener->SetMuonMultiplicity(1);
9c4fff20 1318 gener->SetImpactParameterRange(5.,8.6);//Centrality class Per1 for PDC04
b984b0e1 1319 gener->SetNumberOfParticipants(229.3);//Centrality class Per1 for PDC04
1320 gGener=gener;
1321 }
1322 break;
1323 case kMuonCocktailPer4Single:
1324 {
1325 comment = comment.Append(" Muon Cocktail Single Per4");
1326 AliGenMUONCocktail * gener = new AliGenMUONCocktail();
9c4fff20 1327 gener->SetPtRange(0.0,100.); // Transverse momentum range
b984b0e1 1328 gener->SetPhiRange(0.,360.); // Azimuthal angle range
1329 gener->SetYRange(-4.0,-2.4);
1330 gener->SetMuonPtCut(0.8);
1331 gener->SetMuonThetaCut(171.,178.);
1332 gener->SetMuonMultiplicity(1);
9c4fff20 1333 gener->SetImpactParameterRange(13.2,15.0);//Centrality class Per4 for PDC04
b984b0e1 1334 gGener=gener;
1335 }
1336 break;
eab1dd9d 1337 case kFlow_2_2000:
1338 {
1339 comment = comment.Append(" Flow with dN/deta = 2000, vn = 2%");
1340 gGener = GeVSimStandard(2000., 2.);
1341 }
1342 break;
1343
1344 case kFlow_10_2000:
1345 {
1346 comment = comment.Append(" Flow with dN/deta = 2000, vn = 10%");
1347 gGener = GeVSimStandard(2000., 10.);
1348 }
1349 break;
1350
1351 case kFlow_6_2000:
1352 {
1353 comment = comment.Append(" Flow with dN/deta = 2000, vn = 6%");
1354 gGener = GeVSimStandard(2000., 6.);
1355 }
1356 break;
1357
1358 case kFlow_6_5000:
1359 {
1360 comment = comment.Append(" Flow with dN/deta = 5000, vn = 6%");
1361 gGener = GeVSimStandard(5000., 6.);
1362 }
1363 break;
1364 case kHIJINGplus:
1365 {
1366 //
1367 // The cocktail
1368 AliGenCocktail *gener = new AliGenCocktail();
1369
1370 //
1371 // Charm production by Pythia
1372 AliGenPythia * genpyc = new AliGenPythia(230);
1373 genpyc->SetProcess(kPyCharmPbPbMNR);
1374 genpyc->SetStrucFunc(kCTEQ4L);
1375 genpyc->SetPtHard(2.1,-1.0);
1376 genpyc->SetEnergyCMS(5500.);
1377 genpyc->SetNuclei(208,208);
1378 genpyc->SetYRange(-999,999);
1379 genpyc->SetForceDecay(kAll);
1380 genpyc->SetFeedDownHigherFamily(kFALSE);
1381 genpyc->SetCountMode(AliGenPythia::kCountParents);
1382 //
1383 // Beauty production by Pythia
1384 AliGenPythia * genpyb = new AliGenPythia(9);
1385 genpyb->SetProcess(kPyBeautyPbPbMNR);
1386 genpyb->SetStrucFunc(kCTEQ4L);
1387 genpyb->SetPtHard(2.75,-1.0);
1388 genpyb->SetEnergyCMS(5500.);
1389 genpyb->SetNuclei(208,208);
1390 genpyb->SetYRange(-999,999);
1391 genpyb->SetForceDecay(kAll);
1392 genpyb->SetFeedDownHigherFamily(kFALSE);
1393 genpyb->SetCountMode(AliGenPythia::kCountParents);
1394 //
1395 // Hyperons
1396 //
1397 AliGenSTRANGElib *lib = new AliGenSTRANGElib();
1398 Int_t particle;
1399 // Xi
1400 particle = AliGenSTRANGElib::kXiMinus;
1401 AliGenParam *genXi = new AliGenParam(16,particle,lib->GetPt(particle),lib->GetY(particle),lib->GetIp(particle));
1402 genXi->SetPtRange(0., 12.);
1403 genXi->SetYRange(-1.1, 1.1);
1404 genXi->SetForceDecay(kNoDecay);
1405
1406 //
1407 // Omega
1408 particle = AliGenSTRANGElib::kOmegaMinus;
1409 AliGenParam *genOmega = new AliGenParam(10,particle,lib->GetPt(particle),lib->GetY(particle),lib->GetIp(particle));
1410 genOmega->SetPtRange(0, 12.);
1411 genOmega->SetYRange(-1.1, 1.1);
1412 genOmega->SetForceDecay(kNoDecay);
1413
1414 //
1415 // Central Hijing
1416 AliGenHijing *genHi = HijingStandard();
1417 genHi->SwitchOffHeavyQuarks(kTRUE);
1418 genHi->SetImpactParameterRange(0.,5.);
1419 //
1420 // Add everything to the cocktail and shake ...
1421 gener->AddGenerator(genHi, "Hijing cent1", 1);
1422 gener->AddGenerator(genpyc, "Extra charm", 1);
1423 gener->AddGenerator(genpyb, "Extra beauty", 1);
1424 gener->AddGenerator(genXi, "Xi" , 1);
1425 gener->AddGenerator(genOmega, "Omega", 1);
1426 gGener = gener;
1427 }
1428 break;
3f7a17bb 1429 default: break;
36d4cb82 1430 }
eab1dd9d 1431
de78d77f 1432 return gGener;
36d4cb82 1433}
1434
1435AliGenHijing* HijingStandard()
1436{
1437 AliGenHijing *gener = new AliGenHijing(-1);
1438// centre of mass energy
1439 gener->SetEnergyCMS(5500.);
1440// reference frame
1441 gener->SetReferenceFrame("CMS");
1442// projectile
1443 gener->SetProjectile("A", 208, 82);
1444 gener->SetTarget ("A", 208, 82);
1445// tell hijing to keep the full parent child chain
1446 gener->KeepFullEvent();
1447// enable jet quenching
dbed4b8c 1448 gener->SetJetQuenching(1);
36d4cb82 1449// enable shadowing
1450 gener->SetShadowing(1);
1451// neutral pion and heavy particle decays switched off
1452 gener->SetDecaysOff(1);
1453// Don't track spectators
1454 gener->SetSpectators(0);
1455// kinematic selection
1456 gener->SetSelectAll(0);
1457 return gener;
1458}
1459
eab1dd9d 1460AliGenGeVSim* GeVSimStandard(Float_t mult, Float_t vn)
1461{
1462 AliGenGeVSim* gener = new AliGenGeVSim(0);
1463//
1464// Mult is the number of charged particles in |eta| < 0.5
1465// Vn is in (%)
1466//
1467// Sigma of the Gaussian dN/deta
1468 Float_t sigma_eta = 2.75;
1469//
1470// Maximum eta
1471 Float_t etamax = 7.00;
1472//
1473//
1474// Scale from multiplicity in |eta| < 0.5 to |eta| < |etamax|
1475 Float_t mm = mult * (TMath::Erf(etamax/sigma_eta/sqrt(2.)) / TMath::Erf(0.5/sigma_eta/sqrt(2.)));
1476//
1477// Scale from charged to total multiplicity
1478//
1479 mm *= 1.587;
1480//
1481// Vn
1482 vn /= 100.;
1483//
1484// Define particles
1485//
1486//
1487// 78% Pions (26% pi+, 26% pi-, 26% p0) T = 250 MeV
1488 AliGeVSimParticle *pp = new AliGeVSimParticle(kPiPlus, 1, 0.26 * mm, 0.25, sigma_eta) ;
1489 AliGeVSimParticle *pm = new AliGeVSimParticle(kPiMinus, 1, 0.26 * mm, 0.25, sigma_eta) ;
1490 AliGeVSimParticle *p0 = new AliGeVSimParticle(kPi0, 1, 0.26 * mm, 0.25, sigma_eta) ;
1491//
1492// 12% Kaons (3% K0short, 3% K0long, 3% K+, 3% K-) T = 300 MeV
1493 AliGeVSimParticle *ks = new AliGeVSimParticle(kK0Short, 1, 0.03 * mm, 0.30, sigma_eta) ;
1494 AliGeVSimParticle *kl = new AliGeVSimParticle(kK0Long, 1, 0.03 * mm, 0.30, sigma_eta) ;
1495 AliGeVSimParticle *kp = new AliGeVSimParticle(kKPlus, 1, 0.03 * mm, 0.30, sigma_eta) ;
1496 AliGeVSimParticle *km = new AliGeVSimParticle(kKMinus, 1, 0.03 * mm, 0.30, sigma_eta) ;
1497//
1498// 10% Protons / Neutrons (5% Protons, 5% Neutrons) T = 250 MeV
1499 AliGeVSimParticle *pr = new AliGeVSimParticle(kProton, 1, 0.05 * mm, 0.25, sigma_eta) ;
1500 AliGeVSimParticle *ne = new AliGeVSimParticle(kNeutron, 1, 0.05 * mm, 0.25, sigma_eta) ;
1501//
b74d8a65 1502// Set Elliptic Flow properties
170ea6d3 1503
1504 Float_t pTsaturation = 2. ;
1505
170ea6d3 1506 pp->SetEllipticParam(vn,pTsaturation,0.) ;
1507 pm->SetEllipticParam(vn,pTsaturation,0.) ;
1508 p0->SetEllipticParam(vn,pTsaturation,0.) ;
1509 pr->SetEllipticParam(vn,pTsaturation,0.) ;
1510 ne->SetEllipticParam(vn,pTsaturation,0.) ;
1511 ks->SetEllipticParam(vn,pTsaturation,0.) ;
1512 kl->SetEllipticParam(vn,pTsaturation,0.) ;
1513 kp->SetEllipticParam(vn,pTsaturation,0.) ;
1514 km->SetEllipticParam(vn,pTsaturation,0.) ;
eab1dd9d 1515//
1516// Set Direct Flow properties
b74d8a65 1517 pp->SetDirectedParam(vn,1.0,0.) ;
1518 pm->SetDirectedParam(vn,1.0,0.) ;
1519 p0->SetDirectedParam(vn,1.0,0.) ;
1520 pr->SetDirectedParam(vn,1.0,0.) ;
1521 ne->SetDirectedParam(vn,1.0,0.) ;
1522 ks->SetDirectedParam(vn,1.0,0.) ;
1523 kl->SetDirectedParam(vn,1.0,0.) ;
1524 kp->SetDirectedParam(vn,1.0,0.) ;
1525 km->SetDirectedParam(vn,1.0,0.) ;
eab1dd9d 1526//
1527// Add particles to the list
1528 gener->AddParticleType(pp) ;
1529 gener->AddParticleType(pm) ;
1530 gener->AddParticleType(p0) ;
1531 gener->AddParticleType(pr) ;
1532 gener->AddParticleType(ne) ;
1533 gener->AddParticleType(ks) ;
1534 gener->AddParticleType(kl) ;
1535 gener->AddParticleType(kp) ;
1536 gener->AddParticleType(km) ;
1537//
1538// Random Ev.Plane ----------------------------------
1539 TF1 *rpa = new TF1("gevsimPsiRndm","1", 0, 360);
1540// --------------------------------------------------
1541 gener->SetPtRange(0., 9.) ; // Use a resonable range! (used for bin size in numerical integration)
1542 gener->SetPhiRange(0, 360);
1543 //
1544 // Set pseudorapidity range
1545 Float_t thmin = EtaToTheta(+etamax);
1546 Float_t thmax = EtaToTheta(-etamax);
1547 gener->SetThetaRange(thmin,thmax);
1548 return gener;
1549}
1550
1551
36d4cb82 1552
3f7a17bb 1553void ProcessEnvironmentVars()
1554{
1555 // Run type
1556 if (gSystem->Getenv("CONFIG_RUN_TYPE")) {
1557 for (Int_t iRun = 0; iRun < kRunMax; iRun++) {
1558 if (strcmp(gSystem->Getenv("CONFIG_RUN_TYPE"), pprRunName[iRun])==0) {
1559 srun = (PprRun_t)iRun;
1560 cout<<"Run type set to "<<pprRunName[iRun]<<endl;
1561 }
1562 }
1563 }
36d4cb82 1564
3f7a17bb 1565 // Random Number seed
1566 if (gSystem->Getenv("CONFIG_SEED")) {
1567 sseed = atoi(gSystem->Getenv("CONFIG_SEED"));
1568 }
1569}