]>
Commit | Line | Data |
---|---|---|
f8b94231 | 1 | #ifndef ALIMUONEVENTCUTS_H |
2 | #define ALIMUONEVENTCUTS_H | |
3 | ||
4 | #include "AliAnalysisCuts.h" | |
f8b94231 | 5 | |
6 | class AliVEvent; | |
7 | class AliVVertex; | |
8 | class TList; | |
9 | class TAxis; | |
f8b94231 | 10 | class TArrayI; |
57142b8e | 11 | class TString; |
12 | class TObjString; | |
13 | class TObjArray; | |
f8b94231 | 14 | |
15 | class AliMuonEventCuts : public AliAnalysisCuts | |
16 | { | |
17 | public: | |
18 | ||
19 | enum { | |
20 | kPhysicsSelected = BIT(0), | |
21 | kSelectedCentrality = BIT(1), | |
22 | kSelectedTrig = BIT(2), | |
23 | kGoodVertex = BIT(3) | |
24 | }; | |
25 | ||
26 | AliMuonEventCuts(); | |
27 | AliMuonEventCuts(const char* name, const char* title); | |
28 | AliMuonEventCuts(const AliMuonEventCuts& obj); | |
29 | AliMuonEventCuts& operator=(const AliMuonEventCuts& obj); | |
30 | ||
31 | virtual ~AliMuonEventCuts(); | |
32 | ||
33 | virtual UInt_t GetSelectionMask ( const TObject* obj ); | |
34 | virtual Bool_t IsSelected ( TObject* obj ); | |
35 | virtual Bool_t IsSelected ( TList* /*list */ ); | |
36 | ||
37 | void SetDefaultFilterMask(); | |
38 | void SetDefaultParameters(); | |
39 | ||
f8b94231 | 40 | // Handle trigger |
dba277b7 | 41 | void SetTrigClassPatterns ( const TString trigPattern ); |
f8b94231 | 42 | /// Get default trigger class patterns |
43 | TString GetDefaultTrigClassPatterns() { return fDefaultTrigClassPatterns; }; | |
a3f27e84 | 44 | void SetTrigClassLevels ( const TString pattern = "MSL:Lpt,MUSL:Lpt,MSH:Hpt,MUSH:Hpt,MUL:LptLpt,MUU:LptLpt,MLL:LptLpt" ); |
f8b94231 | 45 | TArrayI GetTrigClassPtCutLevel ( const TString trigClassName ) const; |
57142b8e | 46 | void SetTrigInputsMap ( const TString trigInputsMap ); |
f8b94231 | 47 | /// Get trigger classes found in run |
48 | TList* GetAllSelectedTrigClasses () const { return fAllSelectedTrigClasses; } | |
72ebcde7 | 49 | const TObjArray* GetSelectedTrigClassesInEvent ( const AliVEvent* event ); |
5376e016 CP |
50 | const TObjArray* GetSelectedTrigClassesInEvent(const TString& firedTriggerClasses, |
51 | UInt_t l0Inputs, UInt_t l1Inputs, UInt_t l2Inputs); | |
52 | ||
53 | UInt_t GetTriggerInputBitMaskFromInputName(const char* inputName) const; | |
f8b94231 | 54 | |
f8b94231 | 55 | // Handle centrality |
56 | void SetCentralityClasses(Int_t nCentralityBins = -1, Double_t* centralityBins = 0x0); | |
57 | /// Get centrality classes | |
58 | TAxis* GetCentralityClasses() const { return fCentralityClasses; } | |
59 | ||
60 | void SetCentralityEstimator ( const TString centralityEstimator = "V0M" ); | |
61 | TString GetCentralityEstimator () const; | |
62 | Double_t GetCentrality ( const AliVEvent* event ) const; | |
63 | ||
64 | ||
65 | /// Set Physics selection mask | |
66 | void SetPhysicsSelectionMask ( const UInt_t physicsSelectionMask ) { fPhysicsSelectionMask = physicsSelectionMask; } | |
67 | ||
68 | ||
69 | /// Set minimum number of vertex contributors | |
68e9b988 | 70 | void SetVertexMinNContributors ( const Int_t vertexMinNContributors ) { fVertexMinNContributors = vertexMinNContributors; } |
f8b94231 | 71 | /// Get minimum number of vertex contributors |
68e9b988 | 72 | Int_t GetVertexMinNContributors () const { return fVertexMinNContributors; } |
f8b94231 | 73 | /// Set Vz limits |
68e9b988 | 74 | void SetVertexVzLimits ( Double_t vzMin = -999., Double_t vzMax = 999. ) { fVertexVzMin = vzMin; fVertexVzMax = vzMax; } |
f8b94231 | 75 | /// Get Vtx vz min |
68e9b988 | 76 | Double_t GetVertexVzMin () const { return fVertexVzMin; } |
f8b94231 | 77 | /// Get Vtx vz max |
68e9b988 | 78 | Double_t GetVertexVzMax () const { return fVertexVzMax; } |
f8b94231 | 79 | |
80 | void Print ( Option_t* option = "" ) const; | |
81 | ||
f8b94231 | 82 | protected: |
83 | ||
57142b8e | 84 | void BuildTriggerClasses ( const TString firedTrigClasses, UInt_t l0Inputs, UInt_t l1Inputs, UInt_t l2Inputs ); |
85 | Bool_t CheckTriggerClassPattern ( const TString& toCheck ) const; | |
a3f27e84 | 86 | Bool_t CheckTriggerClassCombination ( const TObjArray* combo, const TString& firedTriggerClasses, UInt_t l0Inputs, UInt_t l1Inputs, UInt_t l2Inputs ) const; |
782b4332 | 87 | void AddToEventSelectedClass ( const TString& toCheck, const TObjString* foundTrig, const UInt_t comboType = 0 ); |
f8b94231 | 88 | Bool_t UpdateEvent( const AliVEvent* event ); |
89 | void SetDefaultTrigClassPatterns(); | |
57142b8e | 90 | void SetDefaultTrigInputsMap(); |
68e9b988 | 91 | |
f8b94231 | 92 | UInt_t fPhysicsSelectionMask; ///< Physics selection mask |
93 | ||
68e9b988 | 94 | Int_t fVertexMinNContributors; ///< Minimum number of SPD vertex contributors |
95 | Double_t fVertexVzMin; ///< SPD vertex Vz min | |
96 | Double_t fVertexVzMax; ///< SPD vertex Vz max | |
f8b94231 | 97 | |
98 | TString fDefaultTrigClassPatterns; ///< Default trigger class patterns | |
99 | TObjArray* fSelectedTrigPattern; ///< List of triggers to be kept | |
100 | TObjArray* fRejectedTrigPattern; ///< List of triggers to be rejected | |
101 | TObjArray* fSelectedTrigLevel; ///< Track-trigger pt cut for selected trigger class | |
57142b8e | 102 | TObjArray* fSelectedTrigCombination; ///< Selected trigger combinations |
103 | TList* fTrigInputsMap; ///< Trigger inputs map | |
f8b94231 | 104 | TList* fAllSelectedTrigClasses; ///< List of all selected trigger classes found |
105 | TAxis* fCentralityClasses; ///< Centrality classes | |
106 | ||
107 | private: | |
4e2a9c02 | 108 | ULong64_t fEventTriggerMask; //!< Fired trigger mask in the event |
782b4332 | 109 | TObjArray* fSelectedTrigClassesInEvent; //!< list of selected trigger classes in current event |
110 | enum {kComboSimple, kComboFormula, kComboAND, kComboOR}; //!< Trigger combination types | |
f8b94231 | 111 | |
4e2a9c02 | 112 | ClassDef(AliMuonEventCuts, 4); // Class for muon event filters |
f8b94231 | 113 | }; |
114 | ||
115 | #endif | |
116 |