]>
Commit | Line | Data |
---|---|---|
c95698be | 1 | #if !defined(__CINT__) || defined(__MAKECINT__) |
2 | #include <Riostream.h> | |
3 | #include <TRandom.h> | |
4 | #include <TDatime.h> | |
5 | #include <TSystem.h> | |
6 | #include <TVirtualMC.h> | |
7 | #include <TGeant3TGeo.h> | |
8 | #include "AliRunLoader.h" | |
9 | #include "AliRun.h" | |
10 | #include "AliConfig.h" | |
11 | #include "AliDecayerPythia.h" | |
12 | #include "AliGenPythia.h" | |
13 | #include "AliGenDPMjet.h" | |
14 | #include "AliMagFCheb.h" | |
15 | #include "AliBODY.h" | |
16 | #include "AliMAG.h" | |
17 | #include "AliABSOv3.h" | |
18 | #include "AliDIPOv3.h" | |
19 | #include "AliHALLv3.h" | |
20 | #include "AliFRAMEv2.h" | |
21 | #include "AliSHILv3.h" | |
22 | #include "AliPIPEv3.h" | |
23 | #include "AliPIPEv4.h" | |
24 | #include "AliITSv11.h" | |
25 | #include "AliTPCv2.h" | |
26 | #include "AliTOFv6T0.h" | |
27 | #include "AliHMPIDv3.h" | |
28 | #include "AliZDCv3.h" | |
29 | #include "AliTRDv1.h" | |
30 | #include "AliTRDgeometry.h" | |
31 | #include "AliFMDv1.h" | |
32 | #include "AliMUONv1.h" | |
33 | #include "AliPHOSv1.h" | |
34 | #include "AliPHOSSimParam.h" | |
35 | #include "AliPMDv1.h" | |
36 | #include "AliT0v1.h" | |
37 | #include "AliEMCALv2.h" | |
38 | #include "AliACORDEv1.h" | |
39 | #include "AliVZEROv7.h" | |
40 | #include "AliMFT.h" | |
41 | #endif | |
42 | ||
43 | enum PDCProc_t {kGenBox, | |
44 | kGenMuonLMR, | |
b5ab1ac4 | 45 | kGenParamJpsi, |
6e8e4c4a | 46 | kGenPionKaon, |
c95698be | 47 | kGenCorrHF, |
48 | kPythia6, | |
49 | kPythiaPerugia0, | |
a2b7dc2a | 50 | kPythiaPerugia0Jpsi2mu, |
51 | kPythiaPerugia0BtoJpsi2mu, | |
c95698be | 52 | kHijing, |
53 | kHijing2500, | |
4fe8ee42 | 54 | kHijing2500Cocktail, |
55 | kCocktailSignals}; | |
c95698be | 56 | |
57 | const Char_t* pprRunName[] = {"kGenBox", | |
58 | "kGenMuonLMR", | |
b5ab1ac4 | 59 | "kGenParamJpsi", |
6e8e4c4a | 60 | "kGenPionKaon", |
c95698be | 61 | "kGenCorrHF", |
62 | "kPythia6", | |
63 | "kPythiaPerugia0", | |
a2b7dc2a | 64 | "kPythiaPerugia0Jpsi2mu", |
65 | "kPythiaPerugia0BtoJpsi2mu", | |
c95698be | 66 | "kHijing", |
67 | "kHijing2500", | |
4fe8ee42 | 68 | "kHijing2500Cocktail", |
69 | "kCocktailSignals"}; | |
c95698be | 70 | |
71 | enum Mag_t { kNoField, k5kG, kFieldMax }; | |
72 | ||
73 | const Char_t* pprField[] = { "kNoField", "k5kG", "kFieldMax" }; | |
74 | ||
75 | void LoadLibs(); | |
76 | ||
77 | // ----------------------- Generator, field, beam energy,... ------------------------------------------------------------ | |
4fe8ee42 | 78 | static PDCProc_t proc = kGenParamJpsi; |
79 | static PDCProc_t signal = kGenParamJpsi; // only in case kHijing2500Cocktail is the proc | |
c95698be | 80 | static Mag_t mag = k5kG; |
a2b7dc2a | 81 | static Float_t energy = 5500.; // energy in CMS |
c95698be | 82 | static Float_t bMin = 0.; |
83 | static Float_t bMax = = 5.; // 0-5 fm corresponds to around 0-10% (see https://twiki.cern.ch/twiki/bin/viewauth/ALICE/CentStudies#Tables_with_centrality_bins_for) | |
84 | static Double_t JpsiPol = 0; // Jpsi polarisation | |
85 | static Bool_t JpsiHarderPt = kFALSE; // Jpsi harder pt spectrum (8.8 TeV) | |
86 | // ---------------------------------------------------------------------------------------------------------------------- | |
87 | ||
88 | static TString comment; | |
89 | ||
90 | //==================================================================================================================================================== | |
91 | ||
92 | void Config() { | |
93 | ||
94 | // AliLog::SetClassDebugLevel("AliMFT", 1); | |
95 | ||
96 | LoadLibs(); | |
97 | ||
98 | new TGeant3TGeo("C++ Interface to Geant3"); | |
99 | ||
100 | // Create the output file | |
101 | ||
102 | AliRunLoader* rl=0x0; | |
103 | ||
cabfe25b | 104 | printf("Config.C: Creating Run Loader ..."); |
c95698be | 105 | rl = AliRunLoader::Open("galice.root", AliConfig::GetDefaultEventFolderName(), "recreate"); |
106 | if (rl == 0x0) { | |
107 | gAlice->Fatal("Config.C","Can not instatiate the Run Loader"); | |
108 | return; | |
109 | } | |
110 | rl->SetCompressionLevel(2); | |
111 | rl->SetNumberOfEventsPerFile(1000); | |
112 | gAlice->SetRunLoader(rl); | |
113 | ||
114 | // ************* STEERING parameters FOR ALICE SIMULATION ************** | |
115 | // --- Specify event type to be tracked through the ALICE setup | |
116 | // --- All positions are in cm, angles in degrees, and P and E in GeV | |
117 | ||
118 | gMC->SetProcess("DCAY",1); | |
119 | gMC->SetProcess("PAIR",1); | |
120 | gMC->SetProcess("COMP",1); | |
121 | gMC->SetProcess("PHOT",1); | |
122 | gMC->SetProcess("PFIS",0); | |
123 | gMC->SetProcess("DRAY",0); | |
124 | gMC->SetProcess("ANNI",1); | |
125 | gMC->SetProcess("BREM",1); | |
126 | gMC->SetProcess("MUNU",1); | |
127 | gMC->SetProcess("CKOV",1); | |
128 | gMC->SetProcess("HADR",1); | |
129 | gMC->SetProcess("LOSS",2); | |
130 | gMC->SetProcess("MULS",1); | |
131 | gMC->SetProcess("RAYL",1); | |
132 | ||
133 | Float_t cut = 1.e-3; // 1MeV cut by default | |
134 | Float_t tofmax = 1.e10; | |
135 | ||
136 | gMC->SetCut("CUTGAM", cut); | |
137 | gMC->SetCut("CUTELE", cut); | |
138 | gMC->SetCut("CUTNEU", cut); | |
139 | gMC->SetCut("CUTHAD", cut); | |
140 | gMC->SetCut("CUTMUO", cut); | |
141 | gMC->SetCut("BCUTE", cut); | |
142 | gMC->SetCut("BCUTM", cut); | |
143 | gMC->SetCut("DCUTE", cut); | |
144 | gMC->SetCut("DCUTM", cut); | |
145 | gMC->SetCut("PPCUTM", cut); | |
146 | gMC->SetCut("TOFMAX", tofmax); | |
147 | ||
148 | TVirtualMCDecayer *decayer = new AliDecayerPythia(); | |
149 | decayer->SetForceDecay(kAll); | |
150 | decayer->Init(); | |
151 | gMC->SetExternalDecayer(decayer); | |
152 | ||
153 | // Generator | |
154 | AliGenerator* gener = 0x0; | |
a2b7dc2a | 155 | if (proc == kPythia6) gener = MbPythia(); |
156 | else if (proc == kPythiaPerugia0) gener = MbPythiaTunePerugia0(); | |
157 | else if (proc == kHijing) gener = Hijing(); | |
158 | else if (proc == kHijing2500) gener = Hijing2500(); | |
159 | else if (proc == kHijing2500Cocktail) gener = Hijing2500Cocktail(); | |
160 | else if (proc == kGenBox) gener = GenBox(); | |
161 | else if (proc == kGenMuonLMR) gener = GenMuonLMR(); | |
162 | else if (proc == kGenParamJpsi) gener = GenParamJpsi(); | |
163 | else if (proc == kGenCorrHF) gener = GenCorrHF(); | |
164 | else if (proc == kGenPionKaon) gener = GenParamPionKaon(); | |
165 | else if (proc == kPythiaPerugia0BtoJpsi2mu) gener = MbPythiaTunePerugia0BtoJpsi2mu(); | |
4fe8ee42 | 166 | else if (proc == kCocktailSignals) gener = CocktailSignals(); |
c95698be | 167 | |
168 | // Size of the interaction diamond | |
169 | Float_t sigmaz = 5.4 / TMath::Sqrt(2.); // [cm] | |
170 | Float_t betast = 3.5; // beta* [m] | |
171 | Float_t eps = 3.75e-6; // emittance [m] | |
172 | Float_t gamma = energy / 2.0 / 0.938272; // relativistic gamma [1] | |
173 | Float_t sigmaxy = TMath::Sqrt(eps * betast / gamma) / TMath::Sqrt(2.) * 100.; // [cm] | |
174 | ||
175 | printf("\n \n Diamond size x-y: %10.3e z: %10.3e\n \n", sigmaxy, sigmaz); | |
176 | ||
4fe8ee42 | 177 | gener->SetOrigin(0,0,0); |
178 | gener->SetSigma(sigmaxy, sigmaxy, sigmaz); // Sigma in (X,Y,Z) (cm) on IP position | |
179 | gener->SetVertexSmear(kPerEvent); | |
c95698be | 180 | gener->Init(); |
181 | ||
182 | printf("\n \n Comment: %s \n \n", comment.Data()); | |
183 | ||
184 | // TGeoGlobalMagField::Instance()->SetField(new AliMagF("Maps","Maps", -1., -1., AliMagF::k5kG, AliMagF::kBeamTypeAA, 2750.)); | |
185 | TGeoGlobalMagField::Instance()->SetField(new AliMagF("Maps","Maps", -1., -1., AliMagF::k5kG, AliMagF::kBeamTypepp, 7000.)); | |
186 | ||
187 | rl->CdGAFile(); | |
188 | ||
189 | // Detector Setup | |
190 | ||
191 | Int_t iABSO = 1; | |
192 | Int_t iDIPO = 1; | |
193 | Int_t iHALL = 1; | |
194 | Int_t iMUON = 1; | |
195 | Int_t iPIPE = 1; | |
196 | Int_t iSHIL = 1; | |
197 | Int_t iT0 = 0; | |
198 | Int_t iVZERO = 1; | |
199 | Int_t iMFT = 1; | |
200 | Int_t iACORDE= 0; | |
201 | Int_t iEMCAL = 0; | |
202 | Int_t iFMD = 0; | |
203 | Int_t iFRAME = 0; | |
204 | Int_t iITS = 0; | |
2666aca2 | 205 | Int_t iMAG = 1; |
c95698be | 206 | Int_t iPHOS = 0; |
207 | Int_t iPMD = 0; | |
208 | Int_t iHMPID = 0; | |
209 | Int_t iTOF = 0; | |
210 | Int_t iTPC = 0; | |
211 | Int_t iTRD = 0; | |
212 | Int_t iZDC = 0; | |
213 | ||
214 | ||
215 | AliBODY *BODY = new AliBODY("BODY", "Alice envelop"); | |
216 | ||
217 | if (iMAG) AliMAG *MAG = new AliMAG("MAG", "Magnet"); | |
218 | if (iABSO) AliABSO *ABSO = new AliABSOv3("ABSO", "Muon Absorber"); | |
219 | if (iDIPO) AliDIPO *DIPO = new AliDIPOv3("DIPO", "Dipole version 3"); | |
220 | if (iHALL) AliHALL *HALL = new AliHALLv3("HALL", "Alice Hall"); | |
221 | if (iSHIL) AliSHIL *SHIL = new AliSHILv3("SHIL", "Shielding Version 3"); | |
4fe8ee42 | 222 | if (iITS) gROOT->ProcessLine(".x $ALICE_ROOT/ITS/UPGRADE/testITSU/CreateITSU.C"); |
c95698be | 223 | if (iTPC) AliTPC *TPC = new AliTPCv2("TPC", "Default"); |
224 | if (iTOF) AliTOF *TOF = new AliTOFv6T0("TOF", "normal TOF"); | |
225 | if (iHMPID) AliHMPID *HMPID = new AliHMPIDv3("HMPID", "normal HMPID"); | |
226 | if (iFMD) AliFMD *FMD = new AliFMDv1("FMD", "normal FMD"); | |
227 | if (iPHOS) AliPHOS *PHOS = new AliPHOSv1("PHOS", "noCPV_Modules123"); | |
228 | if (iPMD) AliPMD *PMD = new AliPMDv1("PMD", "normal PMD"); | |
229 | if (iT0) AliT0 *T0 = new AliT0v1("T0", "T0 Detector"); | |
230 | if (iEMCAL) AliEMCAL *EMCAL = new AliEMCALv2("EMCAL", "EMCAL_FIRSTYEARV1"); | |
231 | if (iACORDE) AliACORDE *ACORDE = new AliACORDEv1("ACORDE", "normal ACORDE"); | |
232 | if (iVZERO) AliVZERO *VZERO = new AliVZEROv7("VZERO", "normal VZERO"); | |
233 | if (iFRAME) { | |
234 | AliFRAMEv2 *FRAME = new AliFRAMEv2("FRAME", "Space Frame"); | |
235 | FRAME->SetHoles(1); | |
236 | } | |
237 | if (iPIPE) { | |
238 | // AliPIPE *PIPE = new AliPIPEv3("PIPE", "Beam Pipe"); | |
11ae1092 | 239 | AliPIPE *PIPE = new AliPIPEv4("PIPE", "Beam Pipe"); |
c95698be | 240 | } |
241 | if (iZDC) { | |
242 | AliZDC *ZDC = new AliZDCv3("ZDC", "normal ZDC"); | |
243 | ZDC->SetSpectatorsTrack(); | |
244 | ZDC->SetLumiLength(0.); | |
245 | } | |
246 | if (iTRD) { | |
247 | AliTRD *TRD = new AliTRDv1("TRD", "TRD slow simulator"); | |
248 | } | |
249 | if (iMUON) { | |
250 | AliMUON *MUON = new AliMUONv1("MUON", "default"); | |
251 | MUON->SetTriggerEffCells(1); // not needed if raw masks | |
252 | Char_t* digitstore="AliMUONDigitStoreV2S"; | |
253 | MUON->SetDigitStoreClassName(digitstore); | |
254 | } | |
255 | if (iMFT) { | |
256 | AliMFT *MFT = new AliMFT("MFT", "normal MFT"); | |
c95698be | 257 | } |
258 | ||
259 | TIter next(gAlice->Modules()); | |
260 | AliModule *detector; | |
261 | printf("gAlice->Modules:\n"); | |
262 | while((detector = (AliModule*)next())) printf("%s\n",detector->GetName()); | |
263 | ||
264 | } | |
265 | ||
266 | //==================================================================================================================================================== | |
267 | ||
268 | AliGenerator* GenBox() { | |
269 | ||
4fe8ee42 | 270 | AliGenBox *gener = new AliGenBox(10); |
271 | gener->SetMomentumRange(4, 50); | |
c95698be | 272 | gener->SetPhiRange(0., 360.); |
4fe8ee42 | 273 | gener->SetThetaRange(170.0,178.0); |
274 | Bool_t isMuPlus = gRandom->Integer(2); | |
275 | if (isMuPlus) gener->SetPart(kMuonPlus); // Muons | |
276 | else gener->SetPart(kMuonMinus); // Muons | |
c95698be | 277 | |
278 | return gener; | |
279 | ||
280 | } | |
281 | ||
282 | //==================================================================================================================================================== | |
283 | ||
284 | AliGenerator* GenMuonLMR() { | |
285 | ||
286 | AliGenMUONLMR *gener = new AliGenMUONLMR(); | |
287 | gener->SetMomentumRange(0,999); | |
288 | gener->SetPtRange(0,100.); | |
a2b7dc2a | 289 | gener->SetYRange(-4.5, -2.0); |
290 | gener->SetChildThetaRange(171.0,178.0); | |
291 | gener->SetChildMomentumRange(4.0, 999.); | |
c95698be | 292 | enum {kEta2Body, kEtaDalitz, kRho2Body, kOmega2Body, kOmegaDalitz, kPhi2Body, kEtaPrimeDalitz, kPionLMR, kKaonLMR}; |
a2b7dc2a | 293 | gener->GenerateSingleProcess(kOmega2Body, 10); |
b5ab1ac4 | 294 | gener->SetCutOnChild(1); |
295 | ||
296 | return gener; | |
297 | ||
298 | } | |
299 | ||
300 | //==================================================================================================================================================== | |
301 | ||
302 | AliGenerator* GenParamJpsi() { | |
303 | ||
304 | AliGenParam *gener = new AliGenParam(5, AliGenMUONlib::kJpsi); | |
305 | gener->SetMomentumRange(0,999); | |
306 | gener->SetPtRange(0,100.); | |
307 | gener->SetYRange(-4.0, -2.5); | |
308 | gener->SetPhiRange(0., 360.); | |
ada051d2 | 309 | gener->SetChildThetaRange(171.0,177.0); |
4fe8ee42 | 310 | gener->SetChildMomentumRange(4.0, 999.); |
b5ab1ac4 | 311 | gener->SetForceDecay(kDiMuon); |
312 | gener->SetTrackingFlag(1); | |
c95698be | 313 | gener->SetCutOnChild(1); |
314 | ||
315 | return gener; | |
316 | ||
317 | } | |
318 | ||
319 | //==================================================================================================================================================== | |
320 | ||
6e8e4c4a | 321 | AliGenerator* GenParamPionKaon() { |
322 | ||
323 | AliGenParamPionsKaons *gener = new AliGenParamPionsKaons(100,"$ALICE_ROOT/MFT/PionKaonKinematics.root"); | |
324 | gener->SetPtRange(0, 5.); | |
325 | gener->SetPhiRange(0., 360.); | |
326 | gener->SetYRange(-10., 0.); | |
6e8e4c4a | 327 | // gener->SetCutOnChild(1); |
328 | ||
329 | return gener; | |
330 | ||
331 | } | |
332 | ||
333 | //==================================================================================================================================================== | |
334 | ||
c95698be | 335 | AliGenerator* GenCorrHF() { |
336 | ||
a2b7dc2a | 337 | AliGenCorrHF *gener = new AliGenCorrHF(1, 4, 6); // for charm, 1 pair per event |
338 | // AliGenCorrHF *gener = new AliGenCorrHF(1, 5, 6); // for beauty, 1 pair per event | |
c95698be | 339 | |
340 | gener->SetMomentumRange(0,9999); | |
341 | gener->SetCutOnChild(1); // 1/0 means cuts on children enable/disable | |
a2b7dc2a | 342 | gener->SetChildThetaRange(171.0,178.0); |
343 | gener->SetChildMomentumRange(4.0, 999.); | |
c95698be | 344 | gener->SetForceDecay(kSemiMuonic); |
345 | gener->SetTrackingFlag(1); | |
346 | gener->Init(); | |
347 | ||
348 | return gener; | |
349 | ||
350 | } | |
351 | ||
352 | //==================================================================================================================================================== | |
353 | ||
354 | AliGenerator* MbPythia() { | |
355 | ||
356 | comment = comment.Append(" pp: Pythia low-pt"); | |
357 | ||
358 | // Pythia | |
359 | AliGenPythia* pythia = new AliGenPythia(-1); | |
360 | pythia->SetMomentumRange(0, 999999.); | |
361 | // pythia->SetThetaRange(0., 180.); | |
362 | // pythia->SetChildYRange(-12.,0.); | |
363 | // pythia->SetPtRange(0,1000.); | |
364 | // pythia->SetCutOnChild(1); | |
365 | pythia->SetProcess(kPyMb); | |
366 | pythia->SetEnergyCMS(energy); | |
367 | pythia->SetForceDecay(kSemiMuonic); | |
368 | ||
369 | return pythia; | |
370 | } | |
371 | ||
372 | //==================================================================================================================================================== | |
373 | ||
374 | AliGenerator* MbPythiaTunePerugia0() { | |
375 | ||
376 | comment = comment.Append(" pp: Pythia low-pt (Perugia0)"); | |
377 | ||
378 | // Pythia | |
379 | AliGenPythia* pythia = new AliGenPythia(-1); | |
380 | pythia->SetMomentumRange(0, 999999.); | |
381 | pythia->SetThetaRange(0., 180.); | |
382 | pythia->SetYRange(-12.,12.); | |
383 | pythia->SetPtRange(0,1000.); | |
384 | pythia->SetProcess(kPyMb); | |
385 | pythia->SetEnergyCMS(energy); | |
386 | // Tune | |
387 | // 320 Perugia 0 | |
388 | pythia->SetTune(320); | |
389 | pythia->UseNewMultipleInteractionsScenario(); | |
390 | ||
391 | return pythia; | |
392 | } | |
393 | ||
394 | //==================================================================================================================================================== | |
395 | ||
a2b7dc2a | 396 | AliGenerator* MbPythiaTunePerugia0Jpsi2mu() { |
c95698be | 397 | |
a2b7dc2a | 398 | comment = comment.Append("Jpsi forced to dimuons"); |
c95698be | 399 | AliGenParam *jpsi=0x0; |
a2b7dc2a | 400 | if (JpsiHarderPt) jpsi = new AliGenParam(1, AliGenMUONlib::kJpsi, "CDF pp 8.8", "Jpsi"); // 8.8 TeV |
c95698be | 401 | else jpsi = new AliGenParam(1, AliGenMUONlib::kJpsi, "CDF pp 7", "Jpsi"); // 7 TeV |
402 | jpsi->SetPtRange(0.,999.); | |
403 | jpsi->SetYRange(-1.0, 1.0); | |
404 | jpsi->SetPhiRange(0.,360.); | |
a2b7dc2a | 405 | jpsi->SetForceDecay(kDiMuon); |
c95698be | 406 | return jpsi; |
407 | ||
408 | } | |
409 | ||
410 | //==================================================================================================================================================== | |
411 | ||
a2b7dc2a | 412 | AliGenerator* MbPythiaTunePerugia0BtoJpsi2mu() { |
c95698be | 413 | |
a2b7dc2a | 414 | comment = comment.Append(" pp: Pythia (Perugia0) BtoJpsi (1 bbbar per event, 1 b-hadron, 1 J/psi"); |
c95698be | 415 | |
416 | // Pythia | |
417 | AliGenPythia* pythia = new AliGenPythia(-1); | |
418 | pythia->SetMomentumRange(0, 999999.); | |
a2b7dc2a | 419 | pythia->SetYRange(-4.5, -2.0); |
c95698be | 420 | pythia->SetPtRange(0,1000.); |
421 | pythia->SetProcess(kPyBeautyppMNRwmi); | |
422 | pythia->SetEnergyCMS(energy); | |
423 | // Tune | |
424 | // 320 Perugia 0 | |
425 | pythia->SetTune(320); | |
426 | pythia->UseNewMultipleInteractionsScenario(); | |
427 | // | |
428 | // decays | |
429 | pythia->SetCutOnChild(1); | |
430 | pythia->SetPdgCodeParticleforAcceptanceCut(443); | |
a2b7dc2a | 431 | pythia->SetChildYRange(-4.5, -2.0); |
c95698be | 432 | pythia->SetChildPtRange(0,10000.); |
433 | // | |
434 | // decays | |
a2b7dc2a | 435 | pythia->SetForceDecay(kBJpsiDiMuon); |
c95698be | 436 | |
437 | return pythia; | |
a2b7dc2a | 438 | |
c95698be | 439 | } |
440 | ||
441 | //==================================================================================================================================================== | |
442 | ||
443 | AliGenerator* HijingParam() { | |
444 | ||
445 | AliGenHIJINGpara *gener = new AliGenHIJINGpara(2000); | |
446 | gener->SetMomentumRange(0,999); | |
447 | gener->SetPhiRange(0,360); | |
448 | gener->SetThetaRange(171, 179); | |
c95698be | 449 | gGener = gener; |
450 | ||
451 | return gener; | |
452 | ||
453 | } | |
454 | ||
455 | //==================================================================================================================================================== | |
456 | ||
457 | AliGenerator* Hijing() { | |
458 | ||
459 | AliGenHijing *gener = new AliGenHijing(-1); | |
460 | // centre of mass energy | |
461 | gener->SetEnergyCMS(energy); | |
462 | gener->SetImpactParameterRange(bMin, bMax); | |
463 | // reference frame | |
464 | gener->SetReferenceFrame("CMS"); | |
465 | // projectile | |
466 | gener->SetProjectile("A", 208, 82); | |
467 | gener->SetTarget ("A", 208, 82); | |
468 | // tell hijing to keep the full parent child chain | |
469 | gener->KeepFullEvent(); | |
470 | // enable jet quenching | |
471 | gener->SetJetQuenching(1); | |
472 | // enable shadowing | |
473 | gener->SetShadowing(1); | |
474 | // Don't track spectators | |
475 | gener->SetSpectators(0); | |
476 | // kinematic selection | |
477 | gener->SetSelectAll(0); | |
478 | return gener; | |
479 | } | |
480 | ||
481 | //==================================================================================================================================================== | |
482 | ||
483 | AliGenerator* Hijing2500() { | |
484 | ||
485 | AliGenHijing *gener = (AliGenHijing*) Hijing(); | |
486 | gener->SetJetQuenching(0); | |
487 | gener->SetPtHardMin (4.5); | |
488 | return gener; | |
489 | ||
490 | } | |
491 | ||
492 | //==================================================================================================================================================== | |
493 | ||
494 | AliGenerator* Hijing2500Cocktail() { | |
495 | ||
496 | comment = comment.Append(" PbPb: Hjing2500 at 5.5 + muon signals"); | |
497 | ||
498 | AliGenCocktail *cocktail = new AliGenCocktail(); | |
499 | cocktail->SetProjectile("A", 208, 82); | |
500 | cocktail->SetTarget ("A", 208, 82); | |
501 | cocktail->SetEnergyCMS(energy); | |
502 | ||
503 | // 1 Hijing event: provides underlying event and collision geometry | |
504 | AliGenHijing *hijing = Hijing2500(); | |
505 | cocktail->AddGenerator(hijing,"hijing",1); | |
506 | ||
507 | // generator for the custom signal | |
508 | AliGenerator* signalGen = 0x0; | |
509 | switch (signal) { | |
510 | case 0: | |
511 | signalGen = GenBox(); | |
512 | break; | |
513 | case 1: | |
514 | signalGen = GenMuonLMR(); | |
515 | break; | |
516 | case 2: | |
517 | signalGen = GenCorrHF(); | |
518 | break; | |
519 | default: | |
520 | signalGen = GenBox(); | |
521 | break; | |
522 | } | |
523 | cocktail->AddGenerator(signalGen, "signal", 1); | |
524 | ||
525 | cocktail->SetTrackingFlag(1); | |
526 | ||
527 | return cocktail; | |
528 | ||
529 | } | |
530 | ||
531 | //==================================================================================================================================================== | |
532 | ||
4fe8ee42 | 533 | AliGenerator* CocktailSignals() { |
534 | ||
535 | comment = comment.Append("Cocktail of various signals"); | |
536 | ||
537 | AliGenCocktail *cocktail = new AliGenCocktail(); | |
538 | ||
539 | // 1) Dummy generation of positive pions, to keep memory of the production vertex | |
540 | AliGenBox *dummyPionPos = new AliGenBox(20); | |
541 | dummyPionPos->SetYRange(-0.5, 0.5); | |
542 | dummyPionPos->SetPtRange(1., 10.); | |
543 | dummyPionPos->SetPart(211); | |
544 | cocktail->AddGenerator(dummyPionPos,"dummyPionPos",1); | |
545 | ||
546 | // 2) Dummy generation of negative pions, to keep memory of the production vertex | |
547 | AliGenBox *dummyPionNeg = new AliGenBox(20); | |
548 | dummyPionNeg->SetYRange(-0.5, 0.5); | |
549 | dummyPionNeg->SetPtRange(1., 10.); | |
550 | dummyPionNeg->SetPart(-211); | |
551 | cocktail->AddGenerator(dummyPionNeg,"dummyPionNeg",1); | |
552 | ||
553 | // 3) Generator for the custom signal | |
554 | AliGenerator* signalGen = 0x0; | |
555 | if (signal == kPythia6) signalGen = MbPythia(); | |
556 | else if (signal == kPythiaPerugia0) signalGen = MbPythiaTunePerugia0(); | |
557 | else if (signal == kHijing) signalGen = Hijing(); | |
558 | else if (signal == kHijing2500) signalGen = Hijing2500(); | |
559 | else if (signal == kGenBox) signalGen = GenBox(); | |
560 | else if (signal == kGenMuonLMR) signalGen = GenMuonLMR(); | |
561 | else if (signal == kGenParamJpsi) signalGen = GenParamJpsi(); | |
562 | else if (signal == kGenCorrHF) signalGen = GenCorrHF(); | |
563 | else if (signal == kGenPionKaon) signalGen = GenParamPionKaon(); | |
564 | else if (signal == kPythiaPerugia0BtoJpsi2mu) signalGen = MbPythiaTunePerugia0BtoJpsi2mu(); | |
565 | cocktail->AddGenerator(signalGen, "signal", 1); | |
566 | ||
567 | cocktail->SetTrackingFlag(1); | |
568 | ||
569 | return cocktail; | |
570 | ||
571 | } | |
572 | ||
573 | //==================================================================================================================================================== | |
574 | ||
7cf09ddf AU |
575 | AliGenerator* QEDGeneratorPbPb() { |
576 | ||
577 | AliGenEpEmv1 *generQED = new AliGenEpEmv1(); | |
578 | generQED->SetEnergyCMS(energy); | |
579 | generQED->SetProjectile("A", 208, 82); | |
580 | generQED->SetTarget ("A", 208, 82); | |
581 | generQED->SetYRange(-8.5, 0.); | |
582 | generQED->SetPtRange(0.4e-3, 1.0); // Set pt limits (GeV) for e+- | |
4fe8ee42 | 583 | generQED->SetDebug(0); // Set debug level (0 = silent) |
7cf09ddf AU |
584 | |
585 | } | |
586 | ||
587 | //==================================================================================================================================================== | |
588 | ||
c95698be | 589 | void LoadLibs() { |
590 | ||
591 | #if defined(__CINT__) | |
592 | ||
593 | gSystem->Load("liblhapdf"); // Parton density functions | |
594 | gSystem->Load("libEGPythia6"); // TGenerator interface | |
595 | if (proc == kPythia6) { | |
596 | gSystem->Load("libpythia6"); // Pythia 6.2 | |
597 | gSystem->Load("libAliPythia6"); // ALICE specific implementations | |
598 | } | |
599 | else { | |
600 | gSystem->Load("libpythia6.4.21"); // Pythia 6.4 | |
601 | gSystem->Load("libAliPythia6"); // ALICE specific implementations | |
602 | } | |
603 | ||
604 | if (proc == kHijing || proc == kHijing2500 || proc == kHijing2500Cocktail) { | |
605 | gSystem->Load("libhijing"); | |
606 | gSystem->Load("libTHijing"); | |
607 | } | |
608 | ||
609 | gSystem->Load("libgeant321"); | |
4fe8ee42 | 610 | |
4070f709 | 611 | gSystem->Load("libITSUpgradeBase"); |
612 | gSystem->Load("libITSUpgradeSim"); | |
4fe8ee42 | 613 | |
c95698be | 614 | #endif |
615 | ||
616 | } | |
617 | ||
618 | //==================================================================================================================================================== | |
619 |