]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG4/AliAnaGammaDirect.h
appropriately modified builders for package and PAR library
[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 <TH2F.h>
32 #include <TString.h>
33
34 // --- ANALYSIS system ---
35 #include "AliAnaBaseClass.h"
36 class AliAODParticleCorrelations ;
37
38 class TList ;
39
40 class AliAnaGammaDirect : public AliAnaBaseClass {
41
42 public: 
43
44   AliAnaGammaDirect() ; // default ctor
45   AliAnaGammaDirect(const AliAnaGammaDirect & g) ; // cpy ctor
46   AliAnaGammaDirect & operator = (const AliAnaGammaDirect & g) ;//cpy assignment
47   virtual ~AliAnaGammaDirect() ; //virtual dtor
48
49   enum mcTypes {kPrompt, kFragmentation, kPi0Decay, kEtaDecay, kOtherDecay, kPi0, kEta, kElectron, kConversion, kUnknown};
50
51   Bool_t CheckInvMass(const Int_t icalo,const TLorentzVector mom, Double_t *v, TClonesArray * pl);
52   Int_t CheckOrigin(const Int_t label);
53   
54   TList *  GetCreateOutputObjects();
55
56   void MakeAnalysisFillAOD()  ;
57   
58   void MakeAnalysisFillHistograms() ; 
59
60   void MakeSeveralICAnalysis(AliAODParticleCorrelation * ph, Double_t v[3]); 
61   
62   void Print(const Option_t * opt)const;
63   
64   TString GetDetector()   const {return fDetector ; }
65   void SetDetector(TString det)    {fDetector = det ; }
66
67   Int_t    GetNCones()                  const {return fNCones ; }
68   Int_t    GetNPtThresFrac()                const {return fNPtThresFrac ; }
69   Float_t GetConeSizes(Int_t i)      const {return fConeSizes[i] ; }
70   Float_t GetPtThresholds(Int_t i)  const {return fPtThresholds[i] ; }
71   Float_t GetPtFractions(Int_t i)  const {return fPtFractions[i] ; }
72
73   void InitParameters();
74  
75   void SetNCones(Int_t ncs)              {fNCones = ncs ; }
76   void SetNPtThresFrac(Int_t npt)        {fNPtThresFrac = npt; }
77   void SetConeSizes(Int_t i, Float_t r)         {fConeSizes[i] = r ; }
78   void SetPtThresholds(Int_t i, Float_t pt)   {fPtThresholds[i] = pt; }
79   void SetPtFractions(Int_t i, Float_t pt)   {fPtFractions[i] = pt; } 
80
81   Bool_t IsIsolationOn() {return fMakeIC ; }
82   void SwitchOnIsolation() { fMakeIC = kTRUE;}
83   void SwitchOffIsolation() { fMakeIC = kFALSE;}
84
85   Bool_t IsReIsolationOn() {return fReMakeIC ; }
86   void SwitchOnReIsolation() { fReMakeIC = kTRUE;}
87   void SwitchOffReIsolation() { fReMakeIC = kFALSE;}
88
89   Bool_t IsSeveralIsolationOn() {return fMakeSeveralIC ; }
90   void SwitchOnSeveralIsolation() { fMakeSeveralIC = kTRUE;}
91   void SwitchOffSeveralIsolation() { fMakeSeveralIC = kFALSE;}
92
93   Bool_t IsInvariantMassOn() {return fMakeInvMass ; }
94   void SwitchOnInvariantMass() { fMakeInvMass = kTRUE;}
95   void SwitchOffInvariantMass() { fMakeInvMass = kFALSE;}
96
97   Bool_t SelectCluster(AliAODCaloCluster * calo, Double_t vertex[3], TLorentzVector & mom);
98
99   private:
100  
101   TString fDetector ; // Detector where the gamma is searched;
102   Bool_t fMakeIC ; //Do isolation analysis
103   Bool_t fReMakeIC ; //Do isolation analysis
104   Bool_t fMakeSeveralIC ; //Do analysis for different IC
105   Bool_t fMakeInvMass; //Select candidate if no pair from decay
106
107   //Histograms  
108   TH1F * fhPtGamma    ;  //!Number of identified (isolated) gamma 
109   TH2F * fhPhiGamma  ; //! Phi of identified  (isolated) gamma
110   TH2F * fhEtaGamma  ; //! eta of identified  (isolated) gamma
111   TH2F * fhConeSumPt ; //! Sum Pt in the cone
112
113   //Prompt photon analysis data members for multiple cones and pt thresholds 
114   Int_t         fNCones   ; //!Number of cone sizes to test
115   Int_t         fNPtThresFrac ; //!Number of ptThres and ptFrac to test
116   Float_t     fConeSizes[5] ; //! Array with cones to test
117   Float_t     fPtThresholds[5] ; //! Array with pt thresholds to test
118   Float_t     fPtFractions[5] ; //! Array with pt thresholds to test
119
120   TH1F* fhPtThresIsolated[5][5]; //! Isolated gamma with pt threshold 
121   TH1F* fhPtFracIsolated[5][5]; //! Isolated gamma with pt threshold 
122   TH2F* fhPtSumIsolated[5] ;  //!  Isolated gamma with threshold on cone pt sume
123
124   //MC
125   TH1F * fhPtPrompt; //!Number of identified (isolated) prompt gamma 
126   TH2F * fhPhiPrompt;  //! Phi of identified  (isolated) prompt gamma
127   TH2F * fhEtaPrompt;  //! eta of identified  (isolated) prompt gamma
128   TH1F * fhPtThresIsolatedPrompt[5][5];  //! Isolated prompt gamma with pt threshold 
129   TH1F * fhPtFracIsolatedPrompt[5][5];    //! Isolated prompt gamma with pt frac
130   TH2F * fhPtSumIsolatedPrompt[5]; //!  Isolated prompt gamma with threshold on cone pt sume
131   TH1F * fhPtFragmentation; //!Number of identified (isolated) fragmentation gamma 
132   TH2F * fhPhiFragmentation;  //! Phi of identified  (isolated) fragmentation gamma
133   TH2F * fhEtaFragmentation;  //! eta of identified  (isolated) fragmentation gamma
134   TH1F * fhPtThresIsolatedFragmentation[5][5];  //! Isolated fragmentation gamma with pt threshold 
135   TH1F * fhPtFracIsolatedFragmentation[5][5];    //! Isolated fragmentation gamma with pt frac
136   TH2F * fhPtSumIsolatedFragmentation[5]; //!  Isolated fragmentation gamma with threshold on cone pt sume
137   TH1F * fhPtPi0Decay; //!Number of identified (isolated) Pi0Decay gamma 
138   TH2F * fhPhiPi0Decay;  //! Phi of identified  (isolated) Pi0Decay gamma
139   TH2F * fhEtaPi0Decay;  //! eta of identified  (isolated) Pi0Decay gamma
140   TH1F * fhPtThresIsolatedPi0Decay[5][5];  //! Isolated Pi0Decay gamma with pt threshold 
141   TH1F * fhPtFracIsolatedPi0Decay[5][5];    //! Isolated Pi0Decay gamma with pt frac
142   TH2F * fhPtSumIsolatedPi0Decay[5]; //!  Isolated Pi0Decay gamma with threshold on cone pt sume
143   TH1F * fhPtOtherDecay; //!Number of identified (isolated) OtherDecay gamma 
144   TH2F * fhPhiOtherDecay;  //! Phi of identified  (isolated) OtherDecay gamma
145   TH2F * fhEtaOtherDecay;  //! eta of identified  (isolated) OtherDecay gamma
146   TH1F * fhPtThresIsolatedOtherDecay[5][5];  //! Isolated OtherDecay gamma with pt threshold 
147   TH1F * fhPtFracIsolatedOtherDecay[5][5];    //! Isolated OtherDecay gamma with pt frac
148   TH2F * fhPtSumIsolatedOtherDecay[5]; //!  Isolated OtherDecay gamma with threshold on cone pt sume    
149   TH1F * fhPtConversion; //!Number of identified (isolated) Conversion gamma 
150   TH2F * fhPhiConversion;  //! Phi of identified  (isolated) Conversion gamma
151   TH2F * fhEtaConversion;  //! eta of identified  (isolated) Conversion gamma
152   TH1F * fhPtThresIsolatedConversion[5][5];  //! Isolated Conversion gamma with pt threshold 
153   TH1F * fhPtFracIsolatedConversion[5][5];    //! Isolated Conversion gamma with pt frac
154   TH2F * fhPtSumIsolatedConversion[5]; //!  Isolated Conversion gamma with threshold on cone pt sume
155   TH1F * fhPtUnknown; //!Number of identified (isolated) Unknown gamma 
156   TH2F * fhPhiUnknown;  //! Phi of identified  (isolated) Unknown gamma
157   TH2F * fhEtaUnknown;  //! eta of identified  (isolated) Unknown gamma
158   TH1F * fhPtThresIsolatedUnknown[5][5];  //! Isolated Unknown gamma with pt threshold 
159   TH1F * fhPtFracIsolatedUnknown[5][5];    //! Isolated Unknown gamma with pt frac
160   TH2F * fhPtSumIsolatedUnknown[5]; //!  Isolated Unknown gamma with threshold on cone pt sume
161                                                 
162   ClassDef(AliAnaGammaDirect,1)
163 } ;
164  
165
166 #endif //AliAnaGammaDirect_H
167
168
169