1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
16 // Cut container class for the ALICE HFE group
17 // Serves also as interface to the correction Framework
18 // Provides a set of standard cuts
27 #ifndef ALIHFEEXTRACUTS_H
28 #include "AliHFEextraCuts.h"
38 class AliHFEcuts : public TObject{
43 kStepMCInAcceptance = 2,
44 kStepRecKineITSTPC = 3,
50 kEventStepGenerated = 0,
51 kEventStepReconstructed = 1
56 }; // Additional constants
59 AliHFEcuts(const AliHFEcuts &c);
60 AliHFEcuts &operator=(const AliHFEcuts &c);
63 void Initialize(AliCFManager *cfm);
66 Bool_t CheckParticleCuts(CutStep_t step, TObject *o);
68 TList *GetQAhistograms() const { return fHistQA; }
71 void SetAOD() { SetBit(kAOD, kTRUE); }
72 void SetESD() { SetBit(kAOD, kFALSE); }
73 void UnsetDebugMode() { SetBit(kDebugMode, kFALSE); }
74 Bool_t IsInDebugMode() const { return TestBit(kDebugMode); };
75 Bool_t IsAOD() const { return TestBit(kAOD); }
76 Bool_t IsESD() const { return !TestBit(kAOD); }
79 Bool_t IsRequireITSpixel() const { return TESTBIT(fRequirements, kITSPixel); };
80 Bool_t IsRequireMaxImpactParam() const { return TESTBIT(fRequirements, kMaxImpactParam); };
81 Bool_t IsRequirePrimary() const { return TESTBIT(fRequirements, kPrimary); };
82 Bool_t IsRequireProdVertex() const { return TESTBIT(fRequirements, kProductionVertex); };
83 Bool_t IsRequireSigmaToVertex() const { return TESTBIT(fRequirements, kSigmaToVertex); };
84 Bool_t IsRequireDCAToVertex() const {return TESTBIT(fRequirements, kDCAToVertex); };
87 inline void SetCutITSpixel(UChar_t cut);
88 void SetCheckITSLayerStatus(Bool_t checkITSLayerStatus) { fCheckITSLayerStatus = checkITSLayerStatus; }
89 void SetMinNClustersTPC(UChar_t minClustersTPC) { fMinClustersTPC = minClustersTPC; }
90 void SetMinNTrackletsTRD(UChar_t minNtrackletsTRD) { fMinTrackletsTRD = minNtrackletsTRD; }
91 void SetMaxChi2perClusterTPC(Double_t chi2) { fMaxChi2clusterTPC = chi2; };
92 inline void SetMaxImpactParam(Double_t radial, Double_t z);
93 void SetMinRatioTPCclusters(Double_t minRatioTPC) { fMinClusterRatioTPC = minRatioTPC; };
94 void SetPtRange(Double_t ptmin, Double_t ptmax){fPtRange[0] = ptmin; fPtRange[1] = ptmax;};
95 inline void SetProductionVertex(Double_t xmin, Double_t xmax, Double_t ymin, Double_t ymax);
96 inline void SetSigmaToVertex(Double_t sig);
98 inline void CreateStandardCuts();
101 void SetRequireDCAToVertex() { SETBIT(fRequirements, kDCAToVertex); };
102 void SetRequireIsPrimary() { SETBIT(fRequirements, kPrimary); };
103 void SetRequireITSPixel() { SETBIT(fRequirements, kITSPixel); }
104 void SetRequireProdVertex() { SETBIT(fRequirements, kProductionVertex); };
105 void SetRequireSigmaToVertex() { SETBIT(fRequirements, kSigmaToVertex); };
107 void SetDebugLevel(Int_t level) { fDebugLevel = level; };
108 Int_t GetDebugLevel() const { return fDebugLevel; };
112 kDebugMode = BIT(14),
117 kProductionVertex = 1,
123 void SetParticleGenCutList();
124 void SetAcceptanceCutList();
125 void SetRecKineITSTPCCutList();
126 void SetRecPrimaryCutList();
127 void SetHFElectronITSCuts();
128 void SetHFElectronTRDCuts();
129 void SetEventCutList(Int_t istep);
131 ULong64_t fRequirements; // Bitmap for requirements
132 Double_t fDCAtoVtx[2]; // DCA to Vertex
133 Double_t fProdVtx[4]; // Production Vertex
134 Double_t fPtRange[2]; // pt range
135 UChar_t fMinClustersTPC; // Min.Number of TPC clusters
136 UChar_t fMinTrackletsTRD; // Min. Number of TRD tracklets
137 UChar_t fCutITSPixel; // Cut on ITS pixel
138 Bool_t fCheckITSLayerStatus; // Check ITS layer status
139 Double_t fMaxChi2clusterTPC; // Max Chi2 per TPC cluster
140 Double_t fMinClusterRatioTPC; // Min. Ratio findable / found TPC clusters
141 Double_t fSigmaToVtx; // Sigma To Vertex
143 TList *fHistQA; //! QA Histograms
144 TObjArray *fCutList; //! List of cut objects(Correction Framework Manager)
146 Int_t fDebugLevel; // Debug Level
148 ClassDef(AliHFEcuts, 1) // Container for HFE cuts
151 //__________________________________________________________________
152 void AliHFEcuts::SetProductionVertex(Double_t xmin, Double_t xmax, Double_t ymin, Double_t ymax){
153 // Set the production vertex constraint
154 SetRequireProdVertex();
161 //__________________________________________________________________
162 void AliHFEcuts::SetSigmaToVertex(Double_t sig){
163 SetRequireSigmaToVertex();
167 //__________________________________________________________________
168 void AliHFEcuts::SetMaxImpactParam(Double_t radial, Double_t z){
169 SetRequireDCAToVertex();
170 fDCAtoVtx[0] = radial;
174 //__________________________________________________________________
175 void AliHFEcuts::SetCutITSpixel(UChar_t cut){
176 SetRequireITSPixel();
180 //__________________________________________________________________
181 void AliHFEcuts::CreateStandardCuts(){
183 // Standard Cuts defined by the HFE Group
185 SetRequireProdVertex();
190 SetRequireDCAToVertex();
193 fMinClustersTPC = 50;
194 fMinTrackletsTRD = 0;
195 SetRequireITSPixel();
196 fCutITSPixel = AliHFEextraCuts::kFirst;
197 fMaxChi2clusterTPC = 3.5;
198 fMinClusterRatioTPC = 0.6;