]>
Commit | Line | Data |
---|---|---|
2bb2434e | 1 | //-*- Mode: C++ -*- |
2 | #ifndef ALIGAMMACONVERSIONAODBGHANDLER_H | |
3 | #define ALIGAMMACONVERSIONAODBGHANDLER_H | |
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | //////////////////////////////////////////////// | |
8 | //--------------------------------------------- | |
9 | // Class for handling of background calculation | |
10 | //--------------------------------------------- | |
11 | //////////////////////////////////////////////// | |
12 | ||
13 | #include <vector> | |
14 | ||
15 | ||
16 | // --- ROOT system --- | |
17 | #include <TObject.h> | |
18 | #include "AliKFParticle.h" | |
19 | #include "AliAODConversionPhoton.h" | |
20 | #include "AliAODConversionMother.h" | |
21 | #include "TClonesArray.h" | |
22 | #include "AliESDVertex.h" | |
23 | ||
24 | #if __GNUC__ >= 3 | |
25 | using namespace std; | |
26 | #endif | |
27 | ||
28 | typedef vector<AliAODConversionPhoton*> AliGammaConversionAODVector; | |
29 | ||
30 | class AliGammaConversionAODBGHandler : public TObject { | |
31 | ||
11c1e680 | 32 | public: |
33 | struct GammaConversionVertex | |
34 | { | |
35 | Double_t fX; | |
36 | Double_t fY; | |
37 | Double_t fZ; | |
38 | }; | |
39 | typedef struct GammaConversionVertex GammaConversionVertex; //! | |
40 | ||
41 | typedef vector<AliGammaConversionAODVector> AliGammaConversionBGEventVector; | |
42 | typedef vector<AliGammaConversionBGEventVector> AliGammaConversionMultipicityVector; | |
43 | typedef vector<AliGammaConversionMultipicityVector> AliGammaConversionBGVector; | |
44 | ||
45 | AliGammaConversionAODBGHandler(); //constructor | |
46 | AliGammaConversionAODBGHandler(UInt_t binsZ,UInt_t binsMultiplicity,UInt_t nEvents); // constructor | |
47 | AliGammaConversionAODBGHandler(UInt_t collisionSystem,UInt_t centMin,UInt_t centMax,UInt_t nEvents, Bool_t useTrackMult); | |
48 | AliGammaConversionAODBGHandler(const AliGammaConversionAODBGHandler & g); //copy constructor | |
49 | AliGammaConversionAODBGHandler & operator = (const AliGammaConversionAODBGHandler & g); //assignment operator | |
50 | virtual ~AliGammaConversionAODBGHandler(); //virtual destructor | |
51 | ||
52 | void Initialize(Double_t * const zBinLimitsArray, Double_t * const multiplicityBinLimitsArray); | |
53 | ||
54 | Int_t GetZBinIndex(Double_t z) const; | |
55 | ||
56 | Int_t GetMultiplicityBinIndex(Int_t mult) const; | |
57 | ||
58 | void AddEvent(TList* const eventGammas, Double_t xvalue,Double_t yvalue,Double_t zvalue, Int_t multiplicity); | |
59 | void AddElectronEvent(TClonesArray* const eventENeg, Double_t zvalue, Int_t multiplicity); | |
60 | ||
61 | Int_t GetNBGEvents()const {return fNEvents;} | |
62 | ||
63 | AliGammaConversionAODVector* GetBGGoodV0s(Int_t zbin, Int_t mbin, Int_t event); | |
64 | AliGammaConversionAODVector* GetBGGoodENeg(Int_t event, Double_t zvalue, Int_t multiplicity); | |
65 | void PrintBGArray(); | |
66 | ||
67 | GammaConversionVertex * GetBGEventVertex(Int_t zbin, Int_t mbin, Int_t event){return &fBGEventVertex[zbin][mbin][event];} | |
68 | ||
69 | Double_t GetBGProb(Int_t z, Int_t m){return fBGProbability[z][m];} | |
70 | ||
71 | private: | |
72 | ||
73 | Int_t fNEvents; // number of events | |
74 | Int_t ** fBGEventCounter; //! bg counter | |
75 | Int_t ** fBGEventENegCounter;//! bg electron counter | |
76 | Double_t ** fBGProbability; //! prob per bin | |
77 | GammaConversionVertex *** fBGEventVertex;//! array of event vertex | |
78 | Int_t fNBinsZ; //n z bins | |
79 | Int_t fNBinsMultiplicity; //n bins multiplicity | |
80 | Double_t *fBinLimitsArrayZ;//! bin limits z array | |
81 | Double_t *fBinLimitsArrayMultiplicity;//! bin limit multiplicity array | |
82 | AliGammaConversionBGVector fBGEvents; //background events | |
83 | AliGammaConversionBGVector fBGEventsENeg; //background electron events | |
84 | ClassDef(AliGammaConversionAODBGHandler,2) | |
2bb2434e | 85 | }; |
86 | #endif |