]>
Commit | Line | Data |
---|---|---|
563113d0 | 1 | #ifndef ALICFEVENTCLASSCUTS_H |
2 | #define ALICFEVENTCLASSCUTS_H | |
3 | /************************************************************************** | |
4 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * * | |
6 | * Author: The ALICE Off-line Project. * | |
7 | * Contributors are mentioned in the code where appropriate. * | |
8 | * * | |
9 | * Permission to use, copy, modify and distribute this software and its * | |
10 | * documentation strictly for non-commercial purposes is hereby granted * | |
11 | * without fee, provided that the above copyright notice appears in all * | |
12 | * copies and that both the copyright notice and this permission notice * | |
13 | * appear in the supporting documentation. The authors make no claims * | |
14 | * about the suitability of this software for any purpose. It is * | |
15 | * provided "as is" without express or implied warranty. * | |
16 | **************************************************************************/ | |
17 | // Cut on the type of Event Class: for the moment | |
18 | // the Trigger (pp running configurations) | |
19 | // and requirements on the energy observed in the ZDC are implemented | |
20 | // The argument of IsSelected member function (passed object) is cast into | |
21 | // an AliVEvent, although conditions are meaningful only for AliESD(AOD)Event | |
22 | // type objects. | |
23 | // The class derives from AliCFCutBase | |
24 | // Author:S.Arcelli Silvia.Arcelli@cern.ch | |
25 | ||
26 | #include "AliCFCutBase.h" | |
27 | #include "TBits.h" | |
28 | class TH1F; | |
29 | class AliVEvent; | |
30 | //____________________________________________________________________________ | |
31 | class AliCFEventClassCuts: public AliCFCutBase | |
32 | { | |
33 | public : | |
34 | AliCFEventClassCuts() ; | |
35 | AliCFEventClassCuts(Char_t* name, Char_t* title) ; | |
36 | AliCFEventClassCuts(const AliCFEventClassCuts& c) ; | |
37 | AliCFEventClassCuts& operator=(const AliCFEventClassCuts& c) ; | |
38 | ~AliCFEventClassCuts(); | |
9eeae5d5 | 39 | Bool_t IsSelected(TObject* obj); |
40 | Bool_t IsSelected(TList* /*list*/) {return kTRUE;} | |
563113d0 | 41 | |
42 | //Association to The Trigger bits in the mask. | |
43 | //They correspond to the PP running descriptor as in | |
44 | //STEER/createTriggerDescriptor_pp.C plus five MB Trigger combinations | |
45 | enum TriggerType { | |
46 | kVZEROLeft=0,kVZERORight,kVZEROBeamGas, | |
47 | kSTARTAL0,kSTARTCL0, | |
48 | kITSSPDGFOL0,kITSSPDHMultL0, | |
49 | kMUSingleLPtL0,kMUUnlikeLPtL0,kMUUnlikeHPtL0,kMULikeLPtL0,kMULikeHPtL0, | |
50 | kMB,kTOFMB, | |
51 | kMUSingleMB,kMUUnLikeLPtMB,kMULikeLPtMB, | |
52 | kMB1,kMB2,kMB3,kMB4,kMB5 | |
53 | }; | |
54 | ||
b68f417e | 55 | //static checker for trigger bits |
563113d0 | 56 | static Bool_t IsTriggered(AliVEvent *ev, TriggerType trigger=kMB1); |
57 | ||
58 | void SetTriggerType(TriggerType trigger=kMB1) { fTriggerType.SetBitNumber(trigger,kTRUE);} // Set requested trigger bits | |
59 | TBits GetTriggerType() const { return fTriggerType;} // get Triggers bits which were requested | |
60 | void SetTriggersInAND( Bool_t flag){fTriggerAND=flag;} // request Trigger bits in .AND. | |
61 | ||
62 | void SetZDCN1EnergyCut(Double_t min,Double_t max){fZDCN1EnergyMin=min; fZDCN1EnergyMax=max;} // ZDC energy cuts | |
63 | void SetZDCN2EnergyCut(Double_t min,Double_t max){fZDCN2EnergyMin=min; fZDCN2EnergyMax=max;} // ZDC energy cuts | |
64 | void SetZDCP1EnergyCut(Double_t min,Double_t max){fZDCP1EnergyMin=min; fZDCP1EnergyMax=max;} // ZDC energy cuts | |
65 | void SetZDCP2EnergyCut(Double_t min,Double_t max){fZDCP2EnergyMin=min; fZDCP2EnergyMax=max;} // ZDC energy cuts | |
66 | void SetZDCEM1EnergyCut(Double_t min,Double_t max){fZDCEM1EnergyMin=min; fZDCEM1EnergyMax=max;} // ZDC energy cuts | |
67 | void SetZDCEM2EnergyCut(Double_t min,Double_t max){fZDCEM2EnergyMin=min; fZDCEM2EnergyMax=max;} // ZDC energy cuts | |
68 | ||
69 | Double_t GetZDCN1EnergyCutMin() const {return fZDCN1EnergyMin;};//ZDC N1 energy min | |
70 | Double_t GetZDCN2EnergyCutMin() const {return fZDCN2EnergyMin;};//ZDC N2 Emin | |
71 | Double_t GetZDCP1EnergyCutMin() const {return fZDCP1EnergyMin;};//ZDC P1 Emin | |
72 | Double_t GetZDCP2EnergyCutMin() const {return fZDCP2EnergyMin;};//ZDC P2 Emin | |
73 | Double_t GetZDCEM1EnergyCutMin() const {return fZDCEM1EnergyMin;};//ZDC EM1 Emin | |
74 | Double_t GetZDCEM2EnergyCutMin() const {return fZDCEM2EnergyMin;};//ZDC EM2 Emin | |
75 | ||
76 | Double_t GetZDCN1EnergyCutMax() const {return fZDCN1EnergyMax;};//ZDC N1 Emax | |
77 | Double_t GetZDCN2EnergyCutMax() const {return fZDCN2EnergyMax;};//ZDC N2 Emax | |
78 | Double_t GetZDCP1EnergyCutMax() const {return fZDCP1EnergyMax;};//ZDC P1 Emax | |
79 | Double_t GetZDCP2EnergyCutMax() const {return fZDCP2EnergyMax;};//ZDC P2 Emax | |
80 | Double_t GetZDCEM1EnergyCutMax() const {return fZDCEM1EnergyMax;};//ZDC EM1 Emax | |
81 | Double_t GetZDCEM2EnergyCutMax() const {return fZDCEM2EnergyMax;};//ZDC EM2 Emax | |
82 | ||
83 | ||
563113d0 | 84 | // QA histogram setter |
85 | // please use indices from the enumeration below | |
86 | void SetHistogramBins(Int_t index, Int_t nbins, Double_t *bins); | |
87 | void SetHistogramBins(Int_t index, Int_t nbins, Double_t xmin, Double_t xmax); | |
b68f417e | 88 | enum{kTrigger=0, |
89 | kZDCEnergyN1, | |
90 | kZDCEnergyP1, | |
91 | kZDCEnergyN2, | |
92 | kZDCEnergyP2, | |
93 | kZDCEnergyEM1, | |
94 | kZDCEnergyEM2, | |
95 | kNTriggers=17, | |
96 | kNTriggersMB=5, | |
97 | kNCuts=7, | |
98 | kNStepQA=2 | |
99 | }; | |
107a3100 | 100 | protected: |
101 | void SelectionBitMap(TObject* obj); | |
563113d0 | 102 | static void TriggerBitMap(AliVEvent* ev,TBits *bitmapT); |
103 | void DefineHistograms(); // books histograms and TList | |
107a3100 | 104 | void AddQAHistograms(TList *qaList) ; |
563113d0 | 105 | void Initialise(); // sets everything to 0 |
106 | void FillHistograms(TObject* obj, Bool_t b); | |
107 | ||
108 | TBits fTriggerType ; //The type of trigger to be checked | |
109 | Bool_t fTriggerAND; //Flag to ak for .AND of all the requested trigger bits (.or.is default) | |
110 | Double_t fZDCN1EnergyMin; //Min Energy in ZDCN1 | |
111 | Double_t fZDCP1EnergyMin; //Min Energy in ZDCP1 | |
112 | Double_t fZDCN2EnergyMin; //Min Energy in ZDCN2 | |
113 | Double_t fZDCP2EnergyMin; //Min Energy in ZDCP2 | |
114 | Double_t fZDCEM1EnergyMin; //Min Energy in ZDCEM1 | |
115 | Double_t fZDCEM2EnergyMin; //Min Energy in ZDCEM2 | |
116 | Double_t fZDCN1EnergyMax; //Max Energy in ZDCN1 | |
117 | Double_t fZDCP1EnergyMax; //Max Energy in ZDCP1 | |
118 | Double_t fZDCN2EnergyMax; //Max Energy in ZDCN2 | |
119 | Double_t fZDCP2EnergyMax; //Max Energy in ZDCP2 | |
120 | Double_t fZDCEM1EnergyMax; //Max Energy in ZDCEM1 | |
121 | Double_t fZDCEM2EnergyMax; //Max Energy in ZDCEM2 | |
122 | ||
123 | TBits *fBitMap ; //cut mask | |
124 | TH1F* fhQA[kNCuts][kNStepQA]; // QA Histograms | |
563113d0 | 125 | |
107a3100 | 126 | ClassDef(AliCFEventClassCuts,2); |
563113d0 | 127 | }; |
128 | #endif |