]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG4/AliAnaGammaDirect.h
Minor changes required due to changed in AliHLTComponent.
[u/mrichter/AliRoot.git] / PWG4 / AliAnaGammaDirect.h
1 #ifndef ALIANAGAMMADIRECT_H
2 #define ALIANAGAMMADIRECT_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice     */
5 /* $Id$ */
6
7 /* History of cvs commits:
8  *
9  * $Log$
10  * Revision 1.5  2007/08/17 12:40:04  schutz
11  * New analysis classes by Gustavo Conesa
12  *
13  * Revision 1.4.4.3  2007/07/26 10:32:09  schutz
14  * new analysis classes in the the new analysis framework
15  *
16  *
17  */
18
19 //_________________________________________________________________________
20
21 // Class for the analysis of prompt gamma, isolation cut. 
22 //
23 //  Class created from old AliPHOSGammaJet
24 //  (see AliRoot versions previous Release 4-09)
25
26 //*-- Author: Gustavo Conesa (INFN-LNF)
27
28 // --- ROOT system ---
29 #include <TParticle.h> 
30 #include <TClonesArray.h> 
31 #include "TObject.h" 
32 #include <TH2F.h>
33 #include <TNtuple.h>
34
35 class TList ;
36
37 class AliAnaGammaDirect : public TObject {
38
39 public: 
40
41   AliAnaGammaDirect() ; // default ctor
42   AliAnaGammaDirect(const AliAnaGammaDirect & g) ; // cpy ctor
43   AliAnaGammaDirect & operator = (const AliAnaGammaDirect & g) ;//cpy assignment
44   virtual ~AliAnaGammaDirect() ; //virtual dtor
45   
46   enum Anatype {kNoIC, kPtIC, kSumPtIC, kSeveralIC};
47   
48   Double_t  GetMinGammaPt()    const {return fMinGammaPt ; }
49   Float_t     GetConeSize()          const {return fConeSize ; }
50   Float_t     GetPtThreshold()      const {return fPtThreshold ; }
51   Float_t     GetPtSumThres()     const {return fPtSumThreshold ; }
52   Int_t        GetICMethod()          const {return fICMethod ; }
53   Bool_t     IsMC() const {return fAnaMC ; };
54
55   TList *  GetCreateOutputObjects();
56   void GetPromptGamma(TClonesArray * plNe, TClonesArray * plCTS, TClonesArray * plPrimNe,  TParticle * pGamma, Bool_t &Is)  const;
57   
58   void MakeSeveralICAnalysis(TClonesArray * plCalo, TClonesArray * plCTS); 
59   void MakeIsolationCut(TClonesArray * plCTS, TClonesArray * plNe, 
60                         TParticle *pCandidate, Int_t index, Int_t &n,
61                         Bool_t &imcpt, Bool_t &icms, Float_t &ptsum) const ;  
62   
63   void Print(const Option_t * opt)const;
64   
65   void SetMinGammaPt(Double_t ptcut){fMinGammaPt =ptcut;}
66   void SetConeSize(Float_t r)              {fConeSize = r ; }
67   void SetPtThreshold(Float_t pt)        {fPtThreshold = pt; };
68   void SetPtSumThreshold(Float_t pt) {fPtSumThreshold = pt; };
69   void SetICMethod(Int_t i )          {fICMethod = i ; }
70   void SetMC()    {fAnaMC = kTRUE ; }
71   void SetIsolatePi0(Bool_t iso)    {fIsolatePi0 = iso ; }
72
73   Int_t    GetNCones()                  const {return fNCones ; }
74   Int_t    GetNPtThresholds()                const {return fNPtThres ; }
75   Float_t GetConeSizes(Int_t i)      const {return fConeSizes[i] ; }
76   Float_t GetPtThresholds(Int_t i)  const {return fPtThresholds[i] ; }
77   
78   void InitParameters();
79  
80   void SetNCones(Int_t ncs)              {fNCones = ncs ; }
81   void SetNPtThresholds(Int_t npt)        {fNPtThres = npt; }
82   void SetConeSizes(Int_t i, Float_t r)         {fConeSizes[i] = r ; }
83   void SetPtThresholds(Int_t i, Float_t pt)   {fPtThresholds[i] = pt; }
84
85   
86   private:
87      
88   Double_t    fMinGammaPt ;  // Min pt in Calorimeter
89   Float_t      fConeSize ; //Size of the isolation cone 
90   Float_t      fPtThreshold ; //Mimium pt of the particles in the cone to set isolation
91   Float_t      fPtSumThreshold ; //Mimium pt sum of the particles in the cone to set isolation  
92   Int_t        fICMethod ; //Isolation cut method to be used
93                                            // kNoIC: No isolation
94                                            // kPtIC: Pt threshold method
95                                            // kSumPtIC: Cone pt sum method
96                                            // kSeveralIC: Analysis for several cuts
97   Bool_t fAnaMC ; //Set in case of using MCData reader 
98   Bool_t fIsolatePi0 ; //Consider identified pi0 in the isolation study.
99   //Histograms  
100   TH1F * fhNGamma    ;  //Number of (isolated) gamma identified
101   TH2F * fhPhiGamma  ; // Phi of identified gamma
102   TH2F * fhEtaGamma  ; // eta of identified gamma
103   TH2F * fhConeSumPt ; // Sum Pt in the cone
104
105   TNtuple *    fntuplePrompt ; //List of found prompt photons, pt, eta and phi. Also primary information.
106
107   //Prompt photon analysis data members for multiple cones and pt thresholds kIsolationCut
108   Int_t         fNCones   ; //Number of cone sizes to test
109   Int_t         fNPtThres ; //Number of ptThres to test
110   Float_t     fConeSizes[10] ; // Array with cones to test
111   Float_t     fPtThresholds[10] ; // Array with pt thresholds to test
112   
113   TH1F* fhPtThresIsolated[20][20]; // Isolated gamma with pt threshold 
114   TH2F* fhPtSumIsolated[20] ;  //  Isolated gamma with threshold on cone pt sume
115   TNtuple *    fntSeveralIC[20] ; //ntuple 
116
117   ClassDef(AliAnaGammaDirect,1)
118 } ;
119  
120
121 #endif //ALIANAGAMMADIRECT_H
122
123
124