]> git.uio.no Git - u/mrichter/AliRoot.git/blob - CORRFW/AliCFEventGenCuts.h
add a few more options when selecting the set of detectors used in PID, fix in QA...
[u/mrichter/AliRoot.git] / CORRFW / AliCFEventGenCuts.h
1
2 #ifndef ALICFEVENTGENCUTS_H
3 #define ALICFEVENTGENCUTS_H
4 /**************************************************************************
5  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
6  *                                                                        *
7  * Author: The ALICE Off-line Project.                                    *
8  * Contributors are mentioned in the code where appropriate.              *
9  *                                                                        *
10  * Permission to use, copy, modify and distribute this software and its   *
11  * documentation strictly for non-commercial purposes is hereby granted   *
12  * without fee, provided that the above copyright notice appears in all   *
13  * copies and that both the copyright notice and this permission notice   *
14  * appear in the supporting documentation. The authors make no claims     *
15  * about the suitability of this software for any purpose. It is          *
16  * provided "as is" without express or implied warranty.                  *
17  **************************************************************************/
18 // Cut on the Event at generator level: for the moment just
19 // the requirements on the MB process type, on the number of charged tracks 
20 // and on the vertex 3-D position are implemented
21 // The argument of IsSelected member function (passed object) is cast into 
22 // an AliMCEvent. In the future may be modified to use AliVEvent interface
23 // and to include more cut variables.
24 // The class derives from AliCFCutBase
25 // Author:S.Arcelli Silvia.Arcelli@cern.ch
26
27
28 #include "AliCFCutBase.h"
29 class TBits;
30 class AliEventGenHeader;
31 class AliMCEvent;
32 //____________________________________________________________________________
33 class AliCFEventGenCuts: public AliCFCutBase 
34 {
35  public :
36   AliCFEventGenCuts() ;
37   AliCFEventGenCuts(Char_t* name, Char_t* title) ;
38   AliCFEventGenCuts(const AliCFEventGenCuts& c) ;
39   AliCFEventGenCuts& operator=(const AliCFEventGenCuts& c) ;
40   ~AliCFEventGenCuts();
41   void GetBitMap(TObject *obj, TBits *bitmap);
42   Bool_t IsSelected(TObject* obj);
43   void Init(){;};
44
45   //number of embedded cuts
46   enum{kNCuts=5};
47
48   //Label the MB MC processes
49   enum PrType { 
50    kND, kSD, kDD 
51   }; 
52
53
54   static Int_t ProcType(AliGenEventHeader *genHeader); 
55   static Bool_t IsMBProcType(AliMCEvent *ev, PrType iproc);
56
57
58   void   SetMBSelProcType(PrType iproc = kND) {fMBProcType=iproc;} // cut values setter
59   Int_t  GetMBSelProcType()const {return fMBProcType;} // cut values getter
60
61
62
63   void SetNTracksCut(Int_t xMin=-1, Int_t xMax=1000000) {fNTracksMin=xMin; fNTracksMax=xMax;} // cut values setter
64
65   void SetRequireVtxCuts(Bool_t vtx=kFALSE) {fRequireVtxCuts=vtx;} // cut values setter
66   void SetVertexXCut(Double_t xMin=-1.e99, Double_t xMax=1.e99) { fVtxXMin=xMin; fVtxXMax=xMax;} // cut values setter
67   void SetVertexYCut(Double_t yMin=-1.e99, Double_t yMax=1.e99) { fVtxYMin=yMin; fVtxYMax=yMax;} // cut values setter
68   void SetVertexZCut(Double_t zMin=-1.e99, Double_t zMax=1.e99) { fVtxZMin=zMin; fVtxZMax=zMax;} // cut values setter
69
70   Int_t    GetNTracksMin() const {return fNTracksMin;} // cut values getter
71   Int_t    GetNTracksMax() const {return fNTracksMax;} // cut values getter
72   Bool_t   GetRequireVtxCuts() const {return fRequireVtxCuts;} // cut value getter
73   Double_t GetVertexXMax() const {return fVtxXMax;} // cut values getter
74   Double_t GetVertexYMax() const {return fVtxYMax;} // cut values getter
75   Double_t GetVertexZMax() const {return fVtxZMax;} // cut values getter
76   Double_t GetVertexXMin() const {return fVtxXMin;} // cut values getter
77   Double_t GetVertexYMin() const {return fVtxYMin;} // cut values getter
78   Double_t GetVertexZMin() const {return fVtxZMin;} // cut values getter
79   
80
81  private:
82
83   TBits * SelectionBitMap(TObject* obj);
84   
85   Int_t fMBProcType ; //the type of selected MB process 
86   Int_t fNTracksMin; //minimum number of particles in the event
87   Int_t fNTracksMax; //maximum number of particles in the event
88   Bool_t fRequireVtxCuts ; //The type of trigger to be checked
89   Double_t fVtxXMax ; //X vertex position, maximum value
90   Double_t fVtxYMax ; //Y vertex position, maximum value 
91   Double_t fVtxZMax ; //Z vertex position, maximum value
92   Double_t fVtxXMin ; //X vertex position, minimum value
93   Double_t fVtxYMin ; //Y vertex position, minimum value
94   Double_t fVtxZMin ; //Z vertex position, minimum value
95
96   TBits *fBitMap ; //cut mask
97
98   ClassDef(AliCFEventGenCuts,1);
99 };
100
101 #endif