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