1 #ifndef AliConversionSelection_cxx
2 #define AliConversionSelection_cxx
4 #include "AliAODConversionMother.h"
5 #include "AliConversionPhotonBase.h"
6 #include "AliAODConversionPhoton.h"
7 #include "AliConversionAODBGHandlerRP.h"
8 #include "AliConversionCuts.h"
9 #include "AliConversionMesonCuts.h"
11 #include "AliVEvent.h"
12 #include "AliMCEvent.h"
13 #include "TClonesArray.h"
14 #include "AliESDtrackCuts.h"
16 class AliConversionSelection : public TObject{
20 AliConversionSelection(AliConversionCuts *convCut=NULL, AliConversionMesonCuts *mesonCut=NULL);
21 AliConversionSelection(TString convCut, TString mesonCut);
22 AliConversionSelection(const AliConversionSelection&);
23 AliConversionSelection& operator=(const AliConversionSelection&); // not implemented
25 virtual ~AliConversionSelection();
28 Bool_t ProcessEvent(TClonesArray *photons,AliVEvent *inputEvent,AliMCEvent *mcEvent);
30 // public getter functions
32 Int_t GetNumberOfPi0s(){return fPi0Candidates->GetEntriesFast();}
33 Int_t GetNumberOfBGs(){return fBGPi0s->GetEntriesFast();}
34 Int_t GetNumberOfPhotons(){return fGoodGammas->GetEntriesFast();}
36 Double_t GetMultiplicity(AliVEvent *inputEvent);
38 AliAODConversionMother* GetPi0(Int_t index);
39 AliAODConversionMother* GetBG(Int_t index);
40 AliAODConversionPhoton* GetPhoton(Int_t index);
42 TClonesArray *GetPi0Candidates(){return fPi0Candidates;}
43 TClonesArray *GetBGPi0s(){return fBGPi0s;}
45 // public Set Functions
46 void SetInvMassRange(Double_t low,Double_t up){fInvMassRange[0]=low;fInvMassRange[1]=up;};
47 void SetInvMassRange(Double_t range[2]){SetInvMassRange(range[0],range[1]);};
49 Double_t* GetInvMassRange(){return fInvMassRange;}
51 TObjArray *GetGoodGammas(){return fGoodGammas;}
53 Int_t GetNumberOfChargedTracks(AliVEvent *inputEvent);
54 Double_t GetSPDMult(AliVEvent *inputEvent);
55 Double_t GetVZEROMult(AliVEvent *inputEvent);
57 Int_t GetEventNumber(AliVEvent *inputEvent);
59 TString GetCutString();
63 void InitializeBGHandler();
64 void CalculatePi0Candidates();
65 void CalculateBackground();
67 void RotateParticle(AliAODConversionPhoton *gamma,Int_t nDegreesPMBackground);
69 Bool_t MesonInMassWindow(AliAODConversionMother *pi0cand);
71 AliVEvent *fInputEvent;
73 AliConversionCuts *fConversionCut;
74 AliConversionMesonCuts *fMesonCut;
75 AliESDtrackCuts *fESDTrackCuts;
76 TObjArray *fGoodGammas; // Pointer to selected photons
77 TClonesArray *fPi0Candidates;
78 TClonesArray *fBGPi0s;
79 TRandom3 *fRandomizer; // Randomizer for Rotation
80 AliConversionAODBGHandlerRP *fBGHandler;
81 Double_t fInvMassRange[2];
82 Int_t fCurrentEventNumber; // Current Event Number
83 Bool_t fIsOwner; // Cuts will be deleted when the destructor is called
85 ClassDef(AliConversionSelection, 2); // example of analysis