]>
Commit | Line | Data |
---|---|---|
c3f9ed2f | 1 | void Config() |
2 | { | |
3 | // 7-DEC-2000 09:00 | |
4 | // Switch on Transition Radiation simulation. 6/12/00 18:00 | |
5 | // iZDC=1 7/12/00 09:00 | |
6 | // ThetaRange is (0., 180.). It was (0.28,179.72) 7/12/00 09:00 | |
7 | // Theta range given through pseudorapidity limits 22/6/2001 | |
8 | ||
9 | // Set Random Number seed | |
10 | ||
11 | TDatime dat ; | |
12 | gRandom->SetSeed(dat.GetTime()); | |
13 | ||
14 | new AliGeant3("C++ Interface to Geant3"); | |
15 | ||
16 | TFile *rootfile = new TFile("testPHOS.root", "recreate"); | |
17 | rootfile->SetCompressionLevel(2); | |
18 | ||
19 | ||
20 | TGeant3 *geant3 = (TGeant3 *) gMC; | |
21 | ||
22 | // | |
23 | // Set External decayer | |
24 | AliDecayer *decayer = new AliDecayerPythia(); | |
25 | ||
26 | decayer->SetForceDecay(kAll); | |
27 | decayer->Init(); | |
28 | gMC->SetExternalDecayer(decayer); | |
29 | // | |
30 | // | |
31 | //======================================================================= | |
32 | // ******* GEANT STEERING parameters FOR ALICE SIMULATION ******* | |
33 | geant3->SetTRIG(1); //Number of events to be processed | |
34 | geant3->SetSWIT(4, 10); | |
35 | geant3->SetDEBU(0, 0, 1); | |
36 | //geant3->SetSWIT(2,2); | |
37 | geant3->SetDCAY(1); | |
38 | geant3->SetPAIR(1); | |
39 | geant3->SetCOMP(1); | |
40 | geant3->SetPHOT(1); | |
41 | geant3->SetPFIS(0); | |
42 | geant3->SetDRAY(0); | |
43 | geant3->SetANNI(1); | |
44 | geant3->SetBREM(1); | |
45 | geant3->SetMUNU(1); | |
46 | geant3->SetCKOV(1); | |
47 | geant3->SetHADR(1); //Select pure GEANH (HADR 1) or GEANH/NUCRIN (HADR 3) | |
48 | geant3->SetLOSS(2); | |
49 | geant3->SetMULS(1); | |
50 | geant3->SetRAYL(1); | |
51 | geant3->SetAUTO(1); //Select automatic STMIN etc... calc. (AUTO 1) or manual (AUTO 0) | |
52 | geant3->SetABAN(0); //Restore 3.16 behaviour for abandoned tracks | |
53 | geant3->SetOPTI(2); //Select optimisation level for GEANT geometry searches (0,1,2) | |
54 | geant3->SetERAN(5.e-7); | |
55 | ||
56 | Float_t cut = 1.e-3; // 1MeV cut by default | |
57 | Float_t tofmax = 1.e10; | |
58 | ||
59 | // GAM ELEC NHAD CHAD MUON EBREM MUHAB EDEL MUDEL MUPA TOFMAX | |
60 | geant3->SetCUTS(cut, cut, cut, cut, cut, cut, cut, cut, cut, cut, | |
61 | tofmax); | |
62 | // | |
63 | //======================================================================= | |
64 | // ************* STEERING parameters FOR ALICE SIMULATION ************** | |
65 | // --- Specify event type to be tracked through the ALICE setup | |
66 | // --- All positions are in cm, angles in degrees, and P and E in GeV | |
67 | ||
68 | int nParticles = 1; | |
69 | AliGenBox *gener = new AliGenBox(nParticles); | |
70 | ||
71 | gener->SetPart(22) ; | |
72 | gener->SetPtRange(9.99, 10.00); | |
69c46d16 | 73 | gener->SetPhiRange(220, 320); |
c3f9ed2f | 74 | // Set pseudorapidity range from -8 to 8. |
69c46d16 | 75 | Float_t thmin = EtaToTheta(0.12); // 220 theta min. <---> eta max |
76 | Float_t thmax = EtaToTheta(-0.12); // 320 theta max. <---> eta min | |
c3f9ed2f | 77 | |
78 | gener->SetThetaRange(thmin, thmax); | |
79 | gener->SetOrigin(0, 0, 0); //vertex position | |
80 | gener->SetSigma(0, 0, 0); //Sigma in (X,Y,Z) (cm) on IP position | |
81 | gener->Init(); | |
82 | // | |
83 | // Activate this line if you want the vertex smearing to happen | |
84 | // track by track | |
85 | // | |
86 | //gener->SetVertexSmear(perTrack); | |
87 | ||
88 | gAlice->SetField(0,2); //Specify maximum magnetic field in Tesla (neg. ==> default field) | |
89 | ||
90 | //=================== Alice BODY parameters ============================= | |
91 | AliBODY *BODY = new AliBODY("BODY", "Alice envelop"); | |
92 | ||
93 | ||
94 | AliPHOS *PHOS = new AliPHOSv1("PHOS", "IHEP"); | |
95 | AliPHOSGetter * gime = AliPHOSGetter::GetInstance() ; | |
96 | AliPHOSQAMeanChecker * hm = static_cast<AliPHOSQAMeanChecker *>gime->QATasks("HitsMul"); | |
97 | AliPHOSQAMeanChecker * te = static_cast<AliPHOSQAMeanChecker *>gime->QATasks("TotEner"); | |
98 | AliPHOSQAMeanChecker * hmB = static_cast<AliPHOSQAMeanChecker *>gime->QATasks("HitsMulB"); | |
99 | AliPHOSQAMeanChecker * teB = static_cast<AliPHOSQAMeanChecker *>gime->QATasks("TotEnerB"); | |
100 | hm->Set(62.18, 23.81) ; | |
101 | hm->Print() ; | |
102 | te->Set(8.092, 3.06) ; | |
103 | hmB->Set(63.498, 24.348) ; | |
104 | teB->Set(8.363, 3.44) ; | |
105 | ||
106 | } | |
107 | ||
108 | Float_t EtaToTheta(Float_t arg){ | |
109 | return (180./TMath::Pi())*2.*atan(exp(-arg)); | |
110 | } |