bcff03f59e49ee26228006a0a4a114e76d747569
[u/mrichter/AliRoot.git] / PWG4 / GammaConv / AliAnalysisTaskGammaConversion.h
1 #ifndef ALIANALYSISTASKGAMMACONVERSION_H\r
2 #define ALIANALYSISTASKGAMMACONVERSION_H\r
3  \r
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *\r
5  * See cxx source for full Copyright notice                               */\r
6 \r
7 ////////////////////////////////////////////////\r
8 //--------------------------------------------- \r
9 // Class used to do analysis on conversion pairs\r
10 //---------------------------------------------\r
11 ////////////////////////////////////////////////\r
12  \r
13 #include "AliAnalysisTaskSE.h"\r
14 #include <vector>\r
15 #include "AliV0Reader.h"\r
16 #include "TNtuple.h"\r
17 \r
18 class AliGammaConversionHistograms;\r
19 class AliESDv0;\r
20 class AliKFParticle;\r
21 class AliESDInputHandler;\r
22 class AliESDEvent;\r
23 class AliAODEvent;\r
24 class TList;\r
25 class AliStack;\r
26 \r
27 class AliAnalysisTaskGammaConversion : public AliAnalysisTaskSE\r
28 {\r
29  public:\r
30     AliAnalysisTaskGammaConversion();\r
31     AliAnalysisTaskGammaConversion(const char* name);\r
32     virtual ~AliAnalysisTaskGammaConversion() ;// virtual destructor\r
33  \r
34     // Implementation of interface methods\r
35     virtual void UserCreateOutputObjects();\r
36     virtual void Init();\r
37     virtual void LocalInit() {Init();}\r
38     virtual void Exec(Option_t *option);\r
39     virtual void Terminate(Option_t *option);\r
40     virtual void ConnectInputData(Option_t *);\r
41         \r
42     void ProcessMCData();\r
43     void ProcessV0s();\r
44     void ProcessGammasForNeutralMesonAnalysis();\r
45     void SetHistograms(AliGammaConversionHistograms *histograms){fHistograms=histograms;}\r
46     void SetDoMCTruth(Bool_t flag){fDoMCTruth=flag;}\r
47     void SetElectronMass(Double_t electronMass){fElectronMass = electronMass;}\r
48     void SetGammaMass(Double_t gammaMass){fGammaMass = gammaMass;}\r
49     void SetGammaWidth(Double_t gammaWidth){fGammaWidth = gammaWidth;}\r
50     void SetPi0Mass(Double_t pi0Mass){fPi0Mass = pi0Mass;}\r
51     void SetPi0Width(Double_t pi0Width){fPi0Width = pi0Width;}\r
52     void SetEtaMass(Double_t etaMass){fEtaMass = etaMass;}\r
53     void SetEtaWidth(Double_t etaWidth){fEtaWidth = etaWidth;}\r
54     void SetV0Reader(AliV0Reader* reader){fV0Reader=reader;}\r
55     void SetCalculateBackground(Bool_t bg){fCalculateBackground=bg;}\r
56     void CalculateBackground();\r
57     void SetWriteNtuple(Bool_t writeNtuple){fWriteNtuple = writeNtuple;}\r
58     void FillNtuple();\r
59     Double_t GetMCOpeningAngle(TParticle* daughter0, TParticle* daughter1) const;\r
60 \r
61  private:\r
62     AliAnalysisTaskGammaConversion(const AliAnalysisTaskGammaConversion&); // Not implemented\r
63     AliAnalysisTaskGammaConversion& operator=(const AliAnalysisTaskGammaConversion&); // Not implemented\r
64 \r
65     AliV0Reader* fV0Reader;\r
66 \r
67     AliStack * fStack;\r
68 \r
69     TList * fOutputContainer ; // Histogram container\r
70 \r
71     AliGammaConversionHistograms *fHistograms;\r
72 \r
73     Bool_t fDoMCTruth;\r
74     \r
75     vector<TParticle*> fMCAllGammas;\r
76     vector<TParticle*> fMCPi0s;\r
77     vector<TParticle*> fMCEtas;\r
78     vector<TParticle*> fMCGammaChic;\r
79 \r
80     vector<AliKFParticle> fKFReconstructedGammas;\r
81 \r
82     //mass defines\r
83     Double_t fElectronMass;\r
84     Double_t fGammaMass;\r
85     Double_t fPi0Mass;\r
86     Double_t fEtaMass;\r
87 \r
88     // width defines\r
89     Double_t fGammaWidth;\r
90     Double_t fPi0Width;\r
91     Double_t fEtaWidth;\r
92     Bool_t fCalculateBackground;\r
93     Bool_t fWriteNtuple;\r
94     TNtuple *fGammaNtuple;\r
95     TNtuple *fNeutralMesonNtuple;\r
96 \r
97     Int_t fTotalNumberOfAddedNtupleEntries;\r
98 \r
99     ClassDef(AliAnalysisTaskGammaConversion, 1); // Analysis task for gamma conversions\r
100 };\r
101  \r
102 #endif //ALIANALYSISTASKGAMMA_H\r