]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STEER/AliEventTagCuts.cxx
Fixing a memory leak.
[u/mrichter/AliRoot.git] / STEER / AliEventTagCuts.cxx
CommitLineData
c7e89ea3 1/**************************************************************************
2 * Author: Panos Christakoglou. *
3 * Contributors are mentioned in the code where appropriate. *
4 * *
5 * Permission to use, copy, modify and distribute this software and its *
6 * documentation strictly for non-commercial purposes is hereby granted *
7 * without fee, provided that the above copyright notice appears in all *
8 * copies and that both the copyright notice and this permission notice *
9 * appear in the supporting documentation. The authors make no claims *
10 * about the suitability of this software for any purpose. It is *
11 * provided "as is" without express or implied warranty. *
12 **************************************************************************/
13
14/* $Id$ */
15
16//-----------------------------------------------------------------
17// AliEventTagCuts class
18// This is the class to deal with the event tag level cuts
19// Origin: Panos Christakoglou, UOA-CERN, Panos.Christakoglou@cern.ch
20//-----------------------------------------------------------------
21
22class AliLog;
23class AliESD;
24
25#include "AliEventTag.h"
26#include "AliEventTagCuts.h"
27
28ClassImp(AliEventTagCuts)
29
30
7e73fbbd 31//___________________________________________________________________________
fe12e09c 32AliEventTagCuts::AliEventTagCuts() :
33 TObject(),
34
35
36
37
38 fVxMin(-1000.0), fVxMax(1000.0),
39 fVxFlag(kFALSE),
40 fVyMin(-1000.0), fVyMax(1000.0),
41 fVyFlag(kFALSE),
42 fVzMin(-1000.0), fVzMax(1000.0),
43 fVzFlag(kFALSE),
44 fParticipantsMin(-1), fParticipantMax(10000),
45 fParticipantsFlag(kFALSE),
46 fImpactParamMin(-1.0), fImpactParamMax(1000.0),
47 fImpactParamFlag(kFALSE),
48 fPrimaryVertexFlag(1),
49 fPVFlag(kFALSE),
50
51 fPrimaryVertexZErrorMin(-10000.), fPrimaryVertexZErrorMax(10000.),
52 fPVzErrorFlag(kFALSE),
53 fTriggerMask(0),
54 fTriggerMaskFlag(kFALSE),
55 fTriggerCluster(0),
56 fTriggerClusterFlag(kFALSE),
57
58 fZDCNeutron1EnergyMin(-1.0), fZDCNeutron1EnergyMax(100000.0),
59 fZDCNeutron1EnergyFlag(kFALSE),
60 fZDCProton1EnergyMin(-1.0), fZDCProton1EnergyMax(100000.0),
61 fZDCProton1EnergyFlag(kFALSE),
62 fZDCNeutron2EnergyMin(-1.0), fZDCNeutron2EnergyMax(100000.0),
63 fZDCNeutron2EnergyFlag(kFALSE),
64 fZDCProton2EnergyMin(-1.0), fZDCProton2EnergyMax(100000.0),
65 fZDCProton2EnergyFlag(kFALSE),
66 fZDCEMEnergyMin(-1.0), fZDCEMEnergyMax(100000.0),
67 fZDCEMEnergyFlag(kFALSE),
68 fT0VertexZMin(-10000.0), fT0VertexZMax(10000.0),
69 fT0VertexZFlag(kFALSE),
70 fMultMin(0), fMultMax(100000),
71 fMultFlag(kFALSE),
72 fMultPosMin(-1), fMultPosMax(100000),
73 fMultPosFlag(kFALSE),
74 fMultNegMin(-1), fMultNegMax(100000),
75 fMultNegFlag(kFALSE),
76 fMultNeutrMin(-1), fMultNeutrMax(100000),
77 fMultNeutrFlag(kFALSE),
78 fV0sMin(-1), fV0sMax(1000000),
79 fV0sFlag(kFALSE),
80 fCascadesMin(-1), fCascadesMax(100000),
81 fCascadesFlag(kFALSE),
82 fkinksMin(-1), fkinksMax(1000000),
83 fkinksFlag(kFALSE),
84
85 fPMDTracksMin(-1), fPMDTracksMax(100000),
86 fPMDTracksFlag(kFALSE),
87 fFMDTracksMin(-1), fFMDTracksMax(100000),
88 fFMDTracksFlag(kFALSE),
89 fPHOSClustersMin(-1), fPHOSClustersMax(100000),
90 fPHOSClustersFlag(kFALSE),
91 fEMCALClustersMin(-1), fEMCALClustersMax(100000),
92 fEMCALClustersFlag(kFALSE),
93 fJetCandidatesMin(-1), fJetCandidatesMax(100000),
94 fJetCandidatesFlag(kFALSE),
95
96 fMaxJetEnergy(-1.0),
97 fMaxJetEnergyFlag(kFALSE),
98 fNHardPhotonsCandidatesMin(-1), fNHardPhotonsCandidatesMax(100000),
99 fNHardPhotonsCandidatesFlag(kFALSE),
100 fMaxNeutralEnergy(-1.0),
101 fMaxNeutralFlag(kFALSE),
102 fChargedAbove1GeVMin(-1), fChargedAbove1GeVMax(100000),
103 fChargedAbove1GeVFlag(kFALSE),
104 fChargedAbove3GeVMin(-1), fChargedAbove3GeVMax(100000),
105 fChargedAbove3GeVFlag(kFALSE),
106 fChargedAbove10GeVMin(-1), fChargedAbove10GeVMax(100000),
107 fChargedAbove10GeVFlag(kFALSE),
108 fMuonsAbove1GeVMin(-1), fMuonsAbove1GeVMax(100000),
109 fMuonsAbove1GeVFlag(kFALSE),
110 fMuonsAbove3GeVMin(-1), fMuonsAbove3GeVMax(100000),
111 fMuonsAbove3GeVFlag(kFALSE),
112 fMuonsAbove10GeVMin(-1), fMuonsAbove10GeVMax(100000),
113 fMuonsAbove10GeVFlag(kFALSE),
114 fElectronsAbove1GeVMin(-1), fElectronsAbove1GeVMax(100000),
115 fElectronsAbove1GeVFlag(kFALSE),
116 fElectronsAbove3GeVMin(-1), fElectronsAbove3GeVMax(100000),
117 fElectronsAbove3GeVFlag(kFALSE),
118 fElectronsAbove10GeVMin(-1), fElectronsAbove10GeVMax(100000),
119 fElectronsAbove10GeVFlag(kFALSE),
120 fElectronsMin(-1), fElectronsMax(100000),
121 fElectronsFlag(kFALSE),
122 fMuonsMin(-1), fMuonsMax(100000),
123 fMuonsFlag(kFALSE),
124 fPionsMin(-1), fPionsMax(100000),
125 fPionsFlag(kFALSE),
126 fKaonsMin(-1), fKaonsMax(100000),
127 fKaonsFlag(kFALSE),
128 fProtonsMin(-1), fProtonsMax(100000),
129 fProtonsFlag(kFALSE),
130 fLambdasMin(-1), fLambdasMax(100000),
131 fLambdasFlag(kFALSE),
132 fPhotonsMin(-1), fPhotonsMax(100000),
133 fPhotonFlag(kFALSE),
134 fPi0sMin(-1), fPi0sMax(100000),
135 fPi0sFlag(kFALSE),
136 fNeutronsMin(-1), fNeutronsMax(100000),
137 fNeutronsFlag(kFALSE),
138 fKaon0sMin(-1), fKaon0sMax(100000),
139 fKaon0sFlag(kFALSE),
140 fTotalPMin(-1.0), fTotalPMax(1000000.0),
141 fTotalPFlag(kFALSE),
142 fMeanPtMin(-1.0), fMeanPtMax(100000.0),
143 fMeanPtFlag(kFALSE),
144 fMaxPt(-1.0),
145 fMaxPtFlag(kFALSE),
146 fTotalNeutralPMin(-1.0), fTotalNeutralPMax(1000000.0),
147 fTotalNeutralPFlag(kFALSE),
148 fMeanNeutralPtMin(-1.0), fMeanNeutralPtMax(1000000.0),
149 fMeanNeutralPtFlag(kFALSE),
150 fMaxNeutralPt(-1.0),
151 fMaxNeutralPtFlag(kFALSE),
152 fEventPlaneAngleMin(-10000000.0), fEventPlaneAngleMax(10000000.0),
153 fEventPlaneAngleFlag(kFALSE),
154 fHBTRadiiMin(-1.0), fHBTRadiiMax(100000.0),
155 fHBTRadiiFlag(kFALSE)
156{
c7e89ea3 157 //Default constructor which calls the Reset method.
158 Reset();
159}
160
7e73fbbd 161//___________________________________________________________________________
162AliEventTagCuts::~AliEventTagCuts() {
c7e89ea3 163 //Defaut destructor.
164}
165
7e73fbbd 166//___________________________________________________________________________
167void AliEventTagCuts::Reset() {
c7e89ea3 168 //Sets dummy values to every private member.
169 fVxFlag = kFALSE;
170 fVyFlag = kFALSE;
171 fVzFlag = kFALSE;
172 fParticipantsFlag = kFALSE;
173 fImpactParamFlag = kFALSE;
174 fPVFlag = kFALSE;
7e73fbbd 175
176 fPVzErrorFlag = kFALSE;
177 fTriggerMaskFlag = kFALSE;
178 fTriggerClusterFlag = kFALSE;
179
32a5cab4 180 fZDCNeutron1EnergyFlag = kFALSE;
181 fZDCProton1EnergyFlag = kFALSE;
182 fZDCNeutron2EnergyFlag = kFALSE;
183 fZDCProton2EnergyFlag = kFALSE;
c7e89ea3 184 fZDCEMEnergyFlag = kFALSE;
185 fT0VertexZFlag = kFALSE;
186 fMultFlag = kFALSE;
187 fMultPosFlag = kFALSE;
188 fMultNegFlag = kFALSE;
189 fMultNeutrFlag = kFALSE;
190 fV0sFlag = kFALSE;
191 fCascadesFlag = kFALSE;
192 fkinksFlag = kFALSE;
7e73fbbd 193
194 fPMDTracksFlag = kFALSE;
195 fFMDTracksFlag = kFALSE;
196 fPHOSClustersFlag = kFALSE;
197 fEMCALClustersFlag = kFALSE;
198 fJetCandidatesFlag = kFALSE;
199
c7e89ea3 200 fMaxJetEnergyFlag = kFALSE;
201 fNHardPhotonsCandidatesFlag = kFALSE;
202 fMaxNeutralFlag = kFALSE;
203 fChargedAbove1GeVFlag = kFALSE;
204 fChargedAbove3GeVFlag = kFALSE;
205 fChargedAbove10GeVFlag = kFALSE;
206 fMuonsAbove1GeVFlag = kFALSE;
207 fMuonsAbove3GeVFlag = kFALSE;
208 fMuonsAbove10GeVFlag = kFALSE;
209 fElectronsAbove1GeVFlag = kFALSE;
210 fElectronsAbove3GeVFlag = kFALSE;
211 fElectronsAbove10GeVFlag = kFALSE;
212 fElectronsFlag = kFALSE;
213 fMuonsFlag = kFALSE;
214 fPionsFlag = kFALSE;
215 fKaonsFlag = kFALSE;
216 fProtonsFlag = kFALSE;
217 fLambdasFlag = kFALSE;
218 fPhotonFlag = kFALSE;
219 fPi0sFlag = kFALSE;
220 fNeutronsFlag = kFALSE;
221 fKaon0sFlag = kFALSE;
222 fTotalPFlag = kFALSE;
223 fMeanPtFlag = kFALSE;
224 fMaxPtFlag = kFALSE;
225 fTotalNeutralPFlag = kFALSE;
226 fMeanNeutralPtFlag = kFALSE;
227 fMaxNeutralPtFlag = kFALSE;
228 fEventPlaneAngleFlag = kFALSE;
229 fHBTRadiiFlag = kFALSE;
230
7e73fbbd 231 fVxMin = -1000.0; fVxMax = 1000.0;
232 fVyMin = -1000.0; fVyMax = 1000.0;
233 fVzMin = -1000.0; fVzMax = 1000.0;
234 fParticipantsMin = -1; fParticipantMax = 10000;
235 fImpactParamMin = -1.0; fImpactParamMax = 1000.0;
c7e89ea3 236 fPrimaryVertexFlag = 1;
7e73fbbd 237
238 fPrimaryVertexZErrorMin = -10000.; fPrimaryVertexZErrorMax = 10000.;
239 fTriggerMask = 0;
240 fTriggerCluster = 0;
c7e89ea3 241
7e73fbbd 242 fZDCNeutron1EnergyMin = -1.0; fZDCNeutron1EnergyMax = 100000.0;
243 fZDCProton1EnergyMin = -1.0; fZDCProton1EnergyMax = 100000.0;
244 fZDCNeutron2EnergyMin = -1.0; fZDCNeutron2EnergyMax = 100000.0;
245 fZDCProton2EnergyMin = -1.0; fZDCProton2EnergyMax = 100000.0;
246 fZDCEMEnergyMin = -1.0; fZDCEMEnergyMax = 100000.0;
247 fT0VertexZMin = -10000.0; fT0VertexZMax = 10000.0;
248 fMultMin = 0; fMultMax = 100000;
249 fMultPosMin = -1; fMultPosMax = 100000;
250 fMultNegMin = -1; fMultNegMax = 100000;
251 fMultNeutrMin = -1; fMultNeutrMax = 100000;
252 fV0sMin = -1; fV0sMax = 1000000;
253 fCascadesMin = -1; fCascadesMax = 100000;
254 fkinksMin = -1; fkinksMax = 1000000;
255
256 fPMDTracksMin = -1, fPMDTracksMax = 100000;
257 fFMDTracksMin = -1, fFMDTracksMax = 100000;
258 fPHOSClustersMin = -1, fPHOSClustersMax = 100000;
259 fEMCALClustersMin = -1, fEMCALClustersMax = 100000;
260 fJetCandidatesMin = -1, fJetCandidatesMax = 100000;
c7e89ea3 261
262 fMaxJetEnergy = -1.0;
7e73fbbd 263 fNHardPhotonsCandidatesMin = -1; fNHardPhotonsCandidatesMax = 100000;
c7e89ea3 264 fMaxNeutralEnergy = -1.0;
7e73fbbd 265 fChargedAbove1GeVMin = -1; fChargedAbove1GeVMax = 100000;
266 fChargedAbove3GeVMin = -1; fChargedAbove3GeVMax = 100000;
267 fChargedAbove10GeVMin = -1; fChargedAbove10GeVMax = 100000;
268 fMuonsAbove1GeVMin = -1; fMuonsAbove1GeVMax = 100000;
269 fMuonsAbove3GeVMin = -1; fMuonsAbove3GeVMax = 100000;
270 fMuonsAbove10GeVMin = -1; fMuonsAbove10GeVMax = 100000;
271 fElectronsAbove1GeVMin = -1; fElectronsAbove1GeVMax = 100000;
272 fElectronsAbove3GeVMin = -1; fElectronsAbove3GeVMax = 100000;
273 fElectronsAbove10GeVMin = -1; fElectronsAbove10GeVMax = 100000;
274 fElectronsMin = -1; fElectronsMax = 100000;
275 fMuonsMin = -1; fMuonsMax = 100000;
276 fPionsMin = -1; fPionsMax = 100000;
277 fKaonsMin = -1; fKaonsMax = 100000;
278 fProtonsMin = -1; fProtonsMax = 100000;
279 fLambdasMin = -1; fLambdasMax = 100000;
280 fPhotonsMin = -1; fPhotonsMax = 100000;
281 fPi0sMin = -1; fPi0sMax = 100000;
282 fNeutronsMin = -1; fNeutronsMax = 100000;
283 fKaon0sMin = -1; fKaon0sMax = 100000;
284 fTotalPMin = -1.0; fTotalPMax = 1000000.0;
285 fMeanPtMin = -1.0; fMeanPtMax = 100000.0;
286 fMaxPt = -1.0; fTotalNeutralPMin = -1.0;
287 fTotalNeutralPMax = 1000000.0;
288 fMeanNeutralPtMin = -1.0; fMeanNeutralPtMax = 1000000.0;
c7e89ea3 289 fMaxNeutralPt = -1.0;
7e73fbbd 290 fEventPlaneAngleMin = -10000000.0; fEventPlaneAngleMax = 10000000.0;
291 fHBTRadiiMin = -1.0; fHBTRadiiMax = 100000.0;
c7e89ea3 292}
293
7e73fbbd 294//___________________________________________________________________________
295void AliEventTagCuts::SetPrimaryVertexXRange(Float_t r1, Float_t r2) {
c7e89ea3 296 //Sets the primary vertex x range
297 //and the corresponding flag to kTRUE if the cut is used.
298 fVxMin = r1;
299 fVxMax = r2;
300 fVxFlag = kTRUE;
301}
302
7e73fbbd 303//___________________________________________________________________________
304void AliEventTagCuts::SetPrimaryVertexYRange(Float_t r1, Float_t r2) {
c7e89ea3 305 //Sets the primary vertex y range
306 //and the corresponding flag to kTRUE if the cut is used.
307 fVyMin = r1;
308 fVyMax = r2;
309 fVyFlag = kTRUE;
310}
311
7e73fbbd 312//___________________________________________________________________________
313void AliEventTagCuts::SetPrimaryVertexZRange(Float_t r1, Float_t r2) {
c7e89ea3 314 //Sets the primary vertex z range
315 //and the corresponding flag to kTRUE if the cut is used.
316 fVzMin = r1;
317 fVzMax = r2;
318 fVzFlag = kTRUE;
319}
320
7e73fbbd 321//___________________________________________________________________________
322void AliEventTagCuts::SetMultiplicityRange(Int_t n1, Int_t n2) {
c7e89ea3 323 //Sets the primary multiplicity range
324 //and the corresponding flag to kTRUE if the cut is used.
325 fMultMin = n1;
326 fMultMax = n2;
327 fMultFlag = kTRUE;
328}
329
7e73fbbd 330//___________________________________________________________________________
331void AliEventTagCuts::SetParticipantsRange(Int_t i1, Int_t i2) {
c7e89ea3 332 //Sets the number of participants range
333 //and the corresponding flag to kTRUE if the cut is used.
334 fParticipantsMin = i1;
335 fParticipantMax = i2;
336 fParticipantsFlag = kTRUE;
337}
338
7e73fbbd 339//___________________________________________________________________________
340void AliEventTagCuts::SetImpactParamRange(Float_t r1, Float_t r2) {
c7e89ea3 341 //Sets the impact parameter range
342 //and the corresponding flag to kTRUE if the cut is used.
343 fImpactParamMin = r1;
344 fImpactParamMax = r2;
345 fImpactParamFlag = kTRUE;
346}
347
348
7e73fbbd 349//___________________________________________________________________________
350void AliEventTagCuts::SetPrimaryVertexFlag(Int_t i) {
c7e89ea3 351 //Sets the primary vertex flag cut
352 //and the corresponding flag to kTRUE if the cut is used.
353 fPrimaryVertexFlag = i;
354 fPVFlag = kTRUE;
355}
356
7e73fbbd 357//___________________________________________________________________________
358void AliEventTagCuts::SetZDCNeutr1Range(Float_t r1, Float_t r2) {
c7e89ea3 359 //Sets the ZDC's neutron energy range
360 //and the corresponding flag to kTRUE if the cut is used.
32a5cab4 361 fZDCNeutron1EnergyMin = r1;
362 fZDCNeutron1EnergyMax = r2;
363 fZDCNeutron1EnergyFlag = kTRUE;
c7e89ea3 364}
7e73fbbd 365
366//___________________________________________________________________________
367void AliEventTagCuts::SetZDCProt1Range(Float_t r1, Float_t r2) {
c7e89ea3 368 //Sets the ZDC's proton energy range
369 //and the corresponding flag to kTRUE if the cut is used.
32a5cab4 370 fZDCProton1EnergyMin = r1;
371 fZDCProton1EnergyMax = r2;
372 fZDCProton1EnergyFlag = kTRUE;
373}
7e73fbbd 374//___________________________________________________________________________
375void AliEventTagCuts::SetZDCNeutr2Range(Float_t r1, Float_t r2) {
32a5cab4 376 //Sets the ZDC's neutron energy range
377 //and the corresponding flag to kTRUE if the cut is used.
378 fZDCNeutron2EnergyMin = r1;
379 fZDCNeutron2EnergyMax = r2;
380 fZDCNeutron2EnergyFlag = kTRUE;
381}
7e73fbbd 382//___________________________________________________________________________
383void AliEventTagCuts::SetZDCProt2Range(Float_t r1, Float_t r2) {
32a5cab4 384 //Sets the ZDC's proton energy range
385 //and the corresponding flag to kTRUE if the cut is used.
386 fZDCProton2EnergyMin = r1;
387 fZDCProton2EnergyMax = r2;
388 fZDCProton2EnergyFlag = kTRUE;
c7e89ea3 389}
7e73fbbd 390//___________________________________________________________________________
391void AliEventTagCuts::SetZDCEMRange(Float_t r1, Float_t r2) {
c7e89ea3 392 //Sets the ZDC's e/m energy range
393 //and the corresponding flag to kTRUE if the cut is used.
394 fZDCEMEnergyMin = r1;
395 fZDCEMEnergyMax = r2;
396 fZDCEMEnergyFlag = kTRUE;
397}
398
7e73fbbd 399//___________________________________________________________________________
400void AliEventTagCuts::SetT0VertexZRange(Float_t r1, Float_t r2) {
c7e89ea3 401 //Sets the T0's Vz range
402 //and the corresponding flag to kTRUE if the cut is used.
403 fT0VertexZMin = r1;
404 fT0VertexZMax = r2;
405 fT0VertexZFlag = kTRUE;
406}
407
7e73fbbd 408//___________________________________________________________________________
409void AliEventTagCuts::SetPosMultiplicityRange(Int_t n1, Int_t n2) {
c7e89ea3 410 //Sets the positive multiplicity range
411 //and the corresponding flag to kTRUE if the cut is used.
412 fMultPosMin = n1;
413 fMultPosMax = n2;
414 fMultPosFlag = kTRUE;
415}
416
417
7e73fbbd 418//___________________________________________________________________________
419void AliEventTagCuts::SetNegMultiplicityRange(Int_t n1, Int_t n2) {
c7e89ea3 420 //Sets the negative multiplicity range
421 //and the corresponding flag to kTRUE if the cut is used.
422 fMultNegMin = n1;
423 fMultNegMax = n2;
424 fMultNegFlag = kTRUE;
425}
426
427
7e73fbbd 428//___________________________________________________________________________
429void AliEventTagCuts::SetNeutrMultiplicityRange(Int_t n1, Int_t n2) {
c7e89ea3 430 //Sets the neutral particle multiplicity range
431 //and the corresponding flag to kTRUE if the cut is used.
432 fMultNeutrMin = n1;
433 fMultNeutrMax = n2;
434 fMultNeutrFlag = kTRUE;
435}
436
7e73fbbd 437//___________________________________________________________________________
438void AliEventTagCuts::SetV0sRange(Int_t n1, Int_t n2) {
c7e89ea3 439 //Sets the v0s multiplicity range
440 //and the corresponding flag to kTRUE if the cut is used.
441 fV0sMin = n1;
442 fV0sMax = n2;
443 fV0sFlag = kTRUE;
444}
445
7e73fbbd 446//___________________________________________________________________________
447void AliEventTagCuts::SetCascadesRange(Int_t n1, Int_t n2) {
c7e89ea3 448 //Sets the cascades multiplicity range
449 //and the corresponding flag to kTRUE if the cut is used.
450 fCascadesMin = n1;
451 fCascadesMax = n2;
452 fCascadesFlag = kTRUE;
453}
454
7e73fbbd 455//___________________________________________________________________________
456void AliEventTagCuts::SetKinksRange(Int_t n1, Int_t n2) {
c7e89ea3 457 //Sets the kinks multipliicity range
458 //and the corresponding flag to kTRUE if the cut is used.
459 fkinksMin = n1;
460 fkinksMax = n2;
461 fkinksFlag = kTRUE;
462}
463
7e73fbbd 464//___________________________________________________________________________
465void AliEventTagCuts::SetMaxJetEnergy(Float_t r1) {
c7e89ea3 466 //Sets the lower limit of the maximum jet energy
467 //and the corresponding flag to kTRUE if the cut is used.
468 fMaxJetEnergy = r1;
469 fMaxJetEnergyFlag = kTRUE;
470}
7e73fbbd 471//___________________________________________________________________________
472void AliEventTagCuts::SetMaxNeutralEnergy(Float_t r1) {
c7e89ea3 473 //Sets the lower limit of the maximum neutral jet energy
474 //and the corresponding flag to kTRUE if the cut is used.
475 fMaxNeutralEnergy = r1;
476 fMaxNeutralFlag = kTRUE;
477}
7e73fbbd 478//___________________________________________________________________________
479void AliEventTagCuts::SetHardPhotonsRange(Int_t i1, Int_t i2) {
c7e89ea3 480 //Sets the hard photons multiplicity range
481 //and the corresponding flag to kTRUE if the cut is used.
482 fNHardPhotonsCandidatesMin = i1;
483 fNHardPhotonsCandidatesMax = i2;
484 fNHardPhotonsCandidatesFlag = kTRUE;
485}
486
7e73fbbd 487//___________________________________________________________________________
488void AliEventTagCuts::SetNChargedAbove1GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 489 //Sets the number of charged above 1GeV range
490 //and the corresponding flag to kTRUE if the cut is used.
491 fChargedAbove1GeVMin = i1;
492 fChargedAbove1GeVMax = i2;
493 fChargedAbove1GeVFlag = kTRUE;
494}
495
7e73fbbd 496//___________________________________________________________________________
497 void AliEventTagCuts::SetNChargedAbove3GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 498 //Sets the number of charged above 3GeV range
499 //and the corresponding flag to kTRUE if the cut is used.
500 fChargedAbove3GeVMin = i1;
501 fChargedAbove3GeVMax = i2;
502 fChargedAbove3GeVFlag = kTRUE;
503}
504
505
7e73fbbd 506//___________________________________________________________________________
507void AliEventTagCuts::SetNChargedAbove10GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 508 //Sets the number of charged above 10GeV range
509 //and the corresponding flag to kTRUE if the cut is used.
510 fChargedAbove10GeVMin = i1;
511 fChargedAbove10GeVMax = i2;
512 fChargedAbove10GeVFlag = kTRUE;
513}
514
515
7e73fbbd 516//___________________________________________________________________________
517void AliEventTagCuts::SetNMuonsAbove1GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 518 //Sets the number of muons above 1GeV range
519 //and the corresponding flag to kTRUE if the cut is used.
520 fMuonsAbove1GeVMin = i1;
521 fMuonsAbove1GeVMax = i2;
522 fMuonsAbove1GeVFlag = kTRUE;
523}
524
525
7e73fbbd 526//___________________________________________________________________________
527void AliEventTagCuts::SetNMuonsAbove3GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 528 //Sets the number of muons above 3GeV range
529 //and the corresponding flag to kTRUE if the cut is used.
530 fMuonsAbove3GeVMin = i1;
531 fMuonsAbove3GeVMax = i2;
532 fMuonsAbove3GeVFlag = kTRUE;
533}
534
7e73fbbd 535//___________________________________________________________________________
536void AliEventTagCuts::SetNMuonsAbove10GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 537 //Sets the number of muons above 10GeV range
538 //and the corresponding flag to kTRUE if the cut is used.
539 fMuonsAbove10GeVMin = i1;
540 fMuonsAbove10GeVMax = i2;
541 fMuonsAbove10GeVFlag = kTRUE;
542}
543
544
7e73fbbd 545//___________________________________________________________________________
546void AliEventTagCuts::SetNElectronsAbove1GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 547 //Sets the number of electrons above 1GeV range
548 //and the corresponding flag to kTRUE if the cut is used.
549 fElectronsAbove1GeVMin = i1;
550 fElectronsAbove1GeVMax = i2;
551 fElectronsAbove1GeVFlag = kTRUE;
552}
553
7e73fbbd 554//___________________________________________________________________________
555void AliEventTagCuts::SetNElectronsAbove3GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 556 //Sets the number of electrons above 3GeV range
557 //and the corresponding flag to kTRUE if the cut is used.
558 fElectronsAbove3GeVMin = i1;
559 fElectronsAbove3GeVMax = i2;
560 fElectronsAbove3GeVFlag = kTRUE;
561}
562
7e73fbbd 563//___________________________________________________________________________
564void AliEventTagCuts::SetNElectronsAbove10GeVRange(Int_t i1, Int_t i2) {
c7e89ea3 565 //Sets the number of electrons above 10GeV range
566 //and the corresponding flag to kTRUE if the cut is used.
567 fElectronsAbove10GeVMin = i1;
568 fElectronsAbove10GeVMax = i2;
569 fElectronsAbove10GeVFlag = kTRUE;
570}
7e73fbbd 571//___________________________________________________________________________
572void AliEventTagCuts::SetNElectronRange(Int_t n1, Int_t n2) {
c7e89ea3 573 //Sets the electron multiplicity range
574 //and the corresponding flag to kTRUE if the cut is used.
575 fElectronsMin = n1;
576 fElectronsMax = n2;
577 fElectronsFlag = kTRUE;
578}
7e73fbbd 579//___________________________________________________________________________
580void AliEventTagCuts::SetNMuonRange(Int_t n1, Int_t n2) {
c7e89ea3 581 //Sets the muon multiplicity range
582 //and the corresponding flag to kTRUE if the cut is used.
583 fMuonsMin = n1;
584 fMuonsMax = n2;
585 fMuonsFlag = kTRUE;
586}
587
7e73fbbd 588//___________________________________________________________________________
589void AliEventTagCuts::SetNPionRange(Int_t n1, Int_t n2) {
c7e89ea3 590 //Sets the pion multiplicity range
591 //and the corresponding flag to kTRUE if the cut is used.
592 fPionsMin = n1;
593 fPionsMax = n2;
594 fPionsFlag = kTRUE;
595}
596
7e73fbbd 597//___________________________________________________________________________
598void AliEventTagCuts::SetNKaonRange(Int_t n1, Int_t n2) {
c7e89ea3 599 //Sets the kaon multiplicity range
600 //and the corresponding flag to kTRUE if the cut is used.
601 fKaonsMin = n1;
602 fKaonsMax = n2;
603 fKaonsFlag = kTRUE;
604}
605
7e73fbbd 606//___________________________________________________________________________
607void AliEventTagCuts::SetNProtonRange(Int_t n1, Int_t n2) {
c7e89ea3 608 //Sets the proton multiplicity range
609 //and the corresponding flag to kTRUE if the cut is used.
610 fProtonsMin = n1;
611 fProtonsMax = n2;
612 fProtonsFlag = kTRUE;
613}
614
7e73fbbd 615//___________________________________________________________________________
616void AliEventTagCuts::SetNLambdaRange(Int_t n1, Int_t n2) {
c7e89ea3 617 //Sets the lambda multiplicity range
618 //and the corresponding flag to kTRUE if the cut is used.
619 fLambdasMin = n1;
620 fLambdasMax = n2;
621 fLambdasFlag = kTRUE;
622}
7e73fbbd 623//___________________________________________________________________________
624void AliEventTagCuts::SetNPhotonRange(Int_t n1, Int_t n2) {
c7e89ea3 625 //Sets the photon multiplicity range
626 //and the corresponding flag to kTRUE if the cut is used.
627 fPhotonsMin = n1;
628 fPhotonsMax = n2;
629 fPhotonFlag = kTRUE;
630}
7e73fbbd 631//___________________________________________________________________________
632void AliEventTagCuts::SetNPi0Range(Int_t n1, Int_t n2) {
c7e89ea3 633 //Sets the pi0 multiplicity range
634 //and the corresponding flag to kTRUE if the cut is used.
635 fPi0sMin = n1;
636 fPi0sMax = n2;
637 fPi0sFlag = kTRUE;
638}
639
7e73fbbd 640//___________________________________________________________________________
641void AliEventTagCuts::SetNNeutronRange(Int_t n1, Int_t n2) {
c7e89ea3 642 //Sets the neutron multiplicity range
643 //and the corresponding flag to kTRUE if the cut is used.
644 fNeutronsMin = n1;
645 fNeutronsMax = n2;
646 fNeutronsFlag = kTRUE;
647}
648
7e73fbbd 649//___________________________________________________________________________
650void AliEventTagCuts::SetNKaon0Range(Int_t n1, Int_t n2) {
c7e89ea3 651 //Sets the K0s multiplicity range
652 //and the corresponding flag to kTRUE if the cut is used.
653 fKaon0sMin = n1;
654 fKaon0sMax = n2;
655 fKaon0sFlag = kTRUE;
656}
657
7e73fbbd 658//___________________________________________________________________________
659void AliEventTagCuts::SetTotalPRange(Float_t r1, Float_t r2) {
c7e89ea3 660 //Sets the total momentum range
661 //and the corresponding flag to kTRUE if the cut is used.
662 fTotalPMin = r1;
663 fTotalPMax = r2;
664 fTotalPFlag = kTRUE;
665}
666
7e73fbbd 667//___________________________________________________________________________
668void AliEventTagCuts::SetMeanPtRange(Float_t r1, Float_t r2) {
c7e89ea3 669 //Sets the mean Pt range
670 //and the corresponding flag to kTRUE if the cut is used.
671 fMeanPtMin = r1;
672 fMeanPtMax = r2;
673 fMeanPtFlag = kTRUE;
674}
675
7e73fbbd 676//___________________________________________________________________________
677void AliEventTagCuts::SetMaxPt(Float_t r1) {
c7e89ea3 678 //Sets the lower limit of the max Pt value
679 //and the corresponding flag to kTRUE if the cut is used.
680 fMaxPt = r1;
681 fMaxPtFlag = kTRUE;
682}
683
7e73fbbd 684//___________________________________________________________________________
685void AliEventTagCuts::SetTotalNeutralPRange(Float_t r1, Float_t r2) {
c7e89ea3 686 //Sets the total momentum of neutral particles range
687 //and the corresponding flag to kTRUE if the cut is used.
688 fTotalNeutralPMin =r1 ;
689 fTotalNeutralPMax = r2;
690 fTotalNeutralPFlag = kTRUE;
691}
7e73fbbd 692//___________________________________________________________________________
693void AliEventTagCuts::SetMeanNeutralPtPRange(Float_t r1, Float_t r2) {
c7e89ea3 694 //Sets the mean Pt of neutral particles range
695 //and the corresponding flag to kTRUE if the cut is used.
696 fMeanNeutralPtMin = r1;
697 fMeanNeutralPtMax = r2;
698 fMeanNeutralPtFlag = kTRUE;
699}
7e73fbbd 700//___________________________________________________________________________
701void AliEventTagCuts::SetMaxNeutralPt(Float_t r1) {
c7e89ea3 702 //Sets the lower limit of the maximum Pt of neutral particles
703 //and the corresponding flag to kTRUE if the cut is used.
704 fMaxNeutralPt = r1;
705 fMaxNeutralPtFlag = kTRUE;
706}
707
7e73fbbd 708//___________________________________________________________________________
709void AliEventTagCuts::SetEvPlaneAngleRange(Float_t r1, Float_t r2) {
c7e89ea3 710 //Sets the event plane range
711 //and the corresponding flag to kTRUE if the cut is used.
712 fEventPlaneAngleMin = r1;
713 fEventPlaneAngleMax = r2;
714 fEventPlaneAngleFlag = kTRUE;
715}
716
7e73fbbd 717//___________________________________________________________________________
718void AliEventTagCuts::SetHBTRadiiRange(Float_t r1, Float_t r2) {
c7e89ea3 719 //Sets the HBT radii range
720 //and the corresponding flag to kTRUE if the cut is used.
721 fHBTRadiiMin = r1;
722 fHBTRadiiMax = r2;
723 fHBTRadiiFlag = kTRUE;
724}
725
7e73fbbd 726//___________________________________________________________________________
727Bool_t AliEventTagCuts::IsAccepted(AliEventTag *EvTag) const {
c7e89ea3 728 //Returns true if the event is accepted otherwise false.
c7e89ea3 729 if(fVzFlag)
730 if((EvTag->GetVertexZ() < fVzMin) || (EvTag->GetVertexZ() > fVzMax))
731 return kFALSE;
732
733 if(fVyFlag)
734 if((EvTag->GetVertexY() < fVyMin) || (EvTag->GetVertexY() > fVyMax))
735 return kFALSE;
736
737 if(fVxFlag)
738 if((EvTag->GetVertexX() < fVxMin) || (EvTag->GetVertexX() > fVxMax))
739 return kFALSE;
740
741 if(fParticipantsFlag)
742 if((EvTag->GetNumOfParticipants() < fParticipantsMin) || (EvTag->GetNumOfParticipants() > fParticipantMax))
743 return kFALSE;
744
745 if(fImpactParamFlag)
746 if((EvTag->GetImpactParameter() < fImpactParamMin) || (EvTag->GetImpactParameter() > fImpactParamMax))
747 return kFALSE;
748
749 if(fPVFlag)
750 if((EvTag->GetVertexFlag() != fPrimaryVertexFlag))
751 return kFALSE;
752
7e73fbbd 753 if(fPVzErrorFlag)
754 if((EvTag->GetVertexZError() < fPrimaryVertexZErrorMin) || (EvTag->GetVertexZError() > fPrimaryVertexZErrorMax))
755 return kFALSE;
756 if(fTriggerMaskFlag)
757 if((EvTag->GetTriggerMask() != fTriggerMask))
758 return kFALSE;
759 if(fTriggerClusterFlag)
760 if((EvTag->GetTriggerMask() != fTriggerMask))
761 return kFALSE;
762
32a5cab4 763 if(fZDCNeutron1EnergyFlag)
764 if((EvTag->GetZDCNeutron1Energy() < fZDCNeutron1EnergyMin) || (EvTag->GetZDCNeutron1Energy() > fZDCNeutron1EnergyMax))
765 return kFALSE;
766
767 if(fZDCProton1EnergyFlag)
768 if((EvTag->GetZDCProton1Energy() < fZDCProton1EnergyMin) || (EvTag->GetZDCProton1Energy() > fZDCProton1EnergyMax))
769 return kFALSE;
770
771 if(fZDCNeutron2EnergyFlag)
772 if((EvTag->GetZDCNeutron2Energy() < fZDCNeutron2EnergyMin) || (EvTag->GetZDCNeutron2Energy() > fZDCNeutron2EnergyMax))
c7e89ea3 773 return kFALSE;
774
32a5cab4 775 if(fZDCProton2EnergyFlag)
776 if((EvTag->GetZDCProton2Energy() < fZDCProton2EnergyMin) || (EvTag->GetZDCProton2Energy() > fZDCProton2EnergyMax))
c7e89ea3 777 return kFALSE;
778
779 if(fZDCEMEnergyFlag)
780 if((EvTag->GetZDCEMEnergy() < fZDCEMEnergyMin) || (EvTag->GetZDCEMEnergy() > fZDCEMEnergyMax))
781 return kFALSE;
782
783 if(fT0VertexZFlag)
784 if((EvTag->GetT0VertexZ() < fT0VertexZMin) || (EvTag->GetT0VertexZ() > fT0VertexZMax))
785 return kFALSE;
786
7e73fbbd 787 if(fMultFlag)
788 if((EvTag->GetNumOfTracks() < fMultMin) || (EvTag->GetNumOfTracks() > fMultMax))
789 return kFALSE;
c7e89ea3 790 if(fMultPosFlag)
791 if((EvTag->GetNumOfPosTracks() < fMultPosMin) || (EvTag->GetNumOfPosTracks() > fMultPosMax))
792 return kFALSE;
793
794 if(fMultNegFlag)
795 if((EvTag->GetNumOfNegTracks() < fMultNegMin) || (EvTag->GetNumOfNegTracks() > fMultNegMax))
796 return kFALSE;
797
798 if(fMultNeutrFlag)
799 if((EvTag->GetNumOfNeutrTracks() < fMultNeutrMin) || (EvTag->GetNumOfNeutrTracks() > fMultNeutrMax))
800 return kFALSE;
801
802 if(fV0sFlag)
803 if((EvTag->GetNumOfV0s() < fV0sMin) || (EvTag->GetNumOfV0s() > fV0sMax))
804 return kFALSE;
805
806 if(fCascadesFlag)
807 if((EvTag->GetNumOfCascades() < fCascadesMin) || (EvTag->GetNumOfCascades() > fCascadesMax))
808 return kFALSE;
809
810 if(fkinksFlag)
811 if((EvTag->GetNumOfKinks() < fkinksMin) || (EvTag->GetNumOfKinks() > fkinksMax))
812 return kFALSE;
7e73fbbd 813
814
815 if(fPMDTracksFlag)
816 if((EvTag->GetNumOfPMDTracks() < fPMDTracksMin) || (EvTag->GetNumOfPMDTracks() > fPMDTracksMax))
817 return kFALSE;
818 if(fFMDTracksFlag)
819 if((EvTag->GetNumOfFMDTracks() < fFMDTracksMin) || (EvTag->GetNumOfFMDTracks() > fFMDTracksMax))
820 return kFALSE;
821 if(fPHOSClustersFlag)
822 if((EvTag->GetNumOfPHOSClusters() < fPHOSClustersMin) || (EvTag->GetNumOfPHOSClusters() > fPHOSClustersMax))
823 return kFALSE;
824 if(fEMCALClustersFlag)
825 if((EvTag->GetNumOfEMCALClusters() < fEMCALClustersMin) || (EvTag->GetNumOfEMCALClusters() > fEMCALClustersMax))
826 return kFALSE;
827 if(fJetCandidatesFlag)
828 if((EvTag->GetNumOfJetCandidates() < fJetCandidatesMin) || (EvTag->GetNumOfJetCandidates() > fJetCandidatesMax))
829 return kFALSE;
830
831
c7e89ea3 832 if(fMaxJetEnergyFlag)
833 if((EvTag->GetMaxJetEnergy() < fMaxJetEnergy))
834 return kFALSE;
835
836 if(fNHardPhotonsCandidatesFlag)
837 if((EvTag->GetNumOfHardPhotonsCandidates() < fNHardPhotonsCandidatesMin) || (EvTag->GetNumOfHardPhotonsCandidates() > fNHardPhotonsCandidatesMax))
838 return kFALSE;
839
840 if(fMaxNeutralFlag)
841 if((EvTag->GetMaxNeutralEnergy() < fMaxNeutralEnergy))
842 return kFALSE;
843
844 if(fChargedAbove1GeVFlag)
845 if((EvTag->GetNumOfChargedAbove1GeV() < fChargedAbove1GeVMin) || (EvTag->GetNumOfChargedAbove1GeV() > fChargedAbove1GeVMax))
846 return kFALSE;
847
848 if(fChargedAbove3GeVFlag)
849 if((EvTag->GetNumOfChargedAbove3GeV() < fChargedAbove3GeVMin) || (EvTag->GetNumOfChargedAbove3GeV() > fChargedAbove3GeVMax))
850 return kFALSE;
851
852 if(fChargedAbove10GeVFlag)
853 if((EvTag->GetNumOfChargedAbove10GeV() < fChargedAbove10GeVMin) || (EvTag->GetNumOfChargedAbove10GeV() > fChargedAbove10GeVMax))
854 return kFALSE;
855
856 if(fMuonsAbove1GeVFlag)
857 if((EvTag->GetNumOfMuonsAbove1GeV() < fMuonsAbove1GeVMin) || (EvTag->GetNumOfMuonsAbove1GeV() > fMuonsAbove1GeVMax))
858 return kFALSE;
859
860 if(fMuonsAbove3GeVFlag)
861 if((EvTag->GetNumOfMuonsAbove3GeV() < fMuonsAbove3GeVMin) || (EvTag->GetNumOfMuonsAbove3GeV() > fMuonsAbove3GeVMax))
862 return kFALSE;
863
864 if(fMuonsAbove10GeVFlag)
865 if((EvTag->GetNumOfMuonsAbove10GeV() < fMuonsAbove10GeVMin) || (EvTag->GetNumOfMuonsAbove10GeV() > fMuonsAbove10GeVMax))
866 return kFALSE;
867
868 if(fElectronsAbove1GeVFlag)
869 if((EvTag->GetNumOfElectronsAbove1GeV() < fElectronsAbove1GeVMin) || (EvTag->GetNumOfElectronsAbove1GeV() > fElectronsAbove1GeVMax))
870 return kFALSE;
871
872 if(fElectronsAbove3GeVFlag)
873 if((EvTag->GetNumOfElectronsAbove3GeV() < fElectronsAbove3GeVMin) || (EvTag->GetNumOfElectronsAbove3GeV() > fElectronsAbove3GeVMax))
874 return kFALSE;
875
876 if(fElectronsAbove10GeVFlag)
877 if((EvTag->GetNumOfElectronsAbove10GeV() < fElectronsAbove10GeVMin) || (EvTag->GetNumOfElectronsAbove10GeV() > fElectronsAbove10GeVMax))
878 return kFALSE;
879
880 if(fElectronsFlag)
881 if((EvTag->GetNumOfElectrons() < fElectronsMin) || (EvTag->GetNumOfElectrons() > fElectronsMax))
882 return kFALSE;
883
884 if(fMuonsFlag)
885 if((EvTag->GetNumOfMuons() < fMuonsMin) || (EvTag->GetNumOfMuons() > fMuonsMax))
886 return kFALSE;
887
888 if(fPionsFlag)
889 if((EvTag->GetNumOfPions() < fPionsMin) || (EvTag->GetNumOfPions() > fPionsMax))
890 return kFALSE;
891
892 if(fKaonsFlag)
893 if((EvTag->GetNumOfKaons() < fKaonsMin) || (EvTag->GetNumOfKaons() > fKaonsMax))
894 return kFALSE;
895
896 if(fProtonsFlag)
897 if((EvTag->GetNumOfProtons() < fProtonsMin) || (EvTag->GetNumOfProtons() > fProtonsMax))
898 return kFALSE;
899
900 if(fLambdasFlag)
901 if((EvTag->GetNumOfLambdas() < fLambdasMin) || (EvTag->GetNumOfLambdas() > fLambdasMax))
902 return kFALSE;
903
904 if(fPhotonFlag)
905 if((EvTag->GetNumOfPhotons() < fPhotonsMin) || (EvTag->GetNumOfPhotons() > fPhotonsMax))
906 return kFALSE;
907
908 if(fPi0sFlag)
909 if((EvTag->GetNumOfPi0s() < fPi0sMin) || (EvTag->GetNumOfPi0s() > fPi0sMax))
910 return kFALSE;
911
912 if(fNeutronsFlag)
913 if((EvTag->GetNumOfNeutrons() < fNeutronsMin) || (EvTag->GetNumOfNeutrons() > fNeutronsMax))
914 return kFALSE;
915
916 if(fKaon0sFlag)
917 if((EvTag->GetNumOfKaon0s() < fKaon0sMin) || (EvTag->GetNumOfKaon0s() > fKaon0sMax))
918 return kFALSE;
919
920 if(fTotalPFlag)
921 if((EvTag->GetTotalMomentum() < fTotalPMin) || (EvTag->GetTotalMomentum() > fTotalPMax))
922 return kFALSE;
923
924 if(fMeanPtFlag)
925 if((EvTag->GetMeanPt() < fMeanPtMin) || (EvTag->GetMeanPt() > fMeanPtMax))
926 return kFALSE;
927
928 if(fMaxPtFlag)
929 if((EvTag->GetMaxPt() < fMaxPt))
930 return kFALSE;
931
932 if(fTotalNeutralPFlag)
933 if((EvTag->GetNeutralTotalMomentum() < fTotalNeutralPMin) || (EvTag->GetNeutralTotalMomentum() > fTotalNeutralPMax))
934 return kFALSE;
935
936 if(fMeanNeutralPtFlag)
937 if((EvTag->GetNeutralMeanPt() < fMeanNeutralPtMin) || (EvTag->GetNeutralMeanPt() >fMeanNeutralPtMax ))
938 return kFALSE;
939
940 if(fMaxNeutralPtFlag)
941 if((EvTag->GetNeutralMaxPt() < fMaxNeutralPt))
942 return kFALSE;
943
944 if(fEventPlaneAngleFlag)
945 if((EvTag->GetEventPlaneAngle() < fEventPlaneAngleMin) || (EvTag->GetEventPlaneAngle() > fEventPlaneAngleMax))
946 return kFALSE;
947
948 if(fHBTRadiiFlag)
949 if((EvTag->GetHBTRadii() < fHBTRadiiMin) || (EvTag->GetHBTRadii() > fHBTRadiiMax))
950 return kFALSE;
951
952 return kTRUE;
953}