]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWG4/GammaConv/ConvCorrelations/AliAnaConvCorrBase.h
Updating conv correlation software
[u/mrichter/AliRoot.git] / PWG4 / GammaConv / ConvCorrelations / AliAnaConvCorrBase.h
CommitLineData
fc7e3b59 1/* This file is property of and copyright *\r
2 * ALICE Experiment at CERN, All rights reserved. *\r
3 * See cxx source for full Copyright notice */\r
4\r
5/// @file AliAnaConvCorrPhoton.h\r
6/// @author Svein Lindal\r
7/// @brief Base class for analysis of correlations between conversion particles and charged tracks\r
8\r
9#ifndef ALIANACONVCORRBASE_CXX\r
10#define ALIANACONVCORRBASE_CXX\r
11\r
12#include "Rtypes.h"\r
13#include "TMath.h"\r
14#include "TList.h"\r
15#include "TH1.h"\r
16\r
17class TH1F;\r
811b0806 18class TH3F;\r
fc7e3b59 19class TH2F;\r
20class AliAODConversionParticle;\r
21class TClonesArray;\r
22class TNtuple;\r
23class TString;\r
24\r
25\r
26class AliAnaConvCorrBase : public TObject {\r
27\r
28public:\r
29\r
30 \r
31\r
32 //Constructor / desctructor\r
33 AliAnaConvCorrBase(TString name); \r
34 virtual ~AliAnaConvCorrBase();\r
35 \r
36 //Set and get min pt for triggers\r
811b0806 37 // void SetTriggerPt(Float_t pt) { fTriggerPt = pt; }\r
38 // inline Float_t GetTriggerPt() const {return fTriggerPt; }\r
fc7e3b59 39\r
40\r
811b0806 41 // //Set and get min pt for correlation particles\r
42 // void SetCorrelatedPt(Float_t pt) { fCorrelatedPt = pt; }\r
43 // inline Float_t GetCorrelatedPt() const {return fCorrelatedPt; }\r
fc7e3b59 44\r
45 //CreateHistograms\r
811b0806 46 void CreateBaseHistograms();\r
47 //To be overrriden by children. Should always call CreateBaseHistograms()\r
48 virtual void CreateHistograms();\r
fc7e3b59 49 \r
50 //Get list of histograms\r
51 TList * GetHistograms() const { return fHistograms;}\r
52\r
53 //Add histogram to list\r
54 void AddHistogram(TH1 * histogram) { fHistograms->Add(dynamic_cast<TObject*>(histogram));}\r
55\r
56 //Set and get number of bins in phi direction\r
57 void SetNPhiBins(Int_t bins) { fNPhiBins = bins; }\r
58 Int_t GetNPhiBins() const { return fNPhiBins;}\r
59\r
60 ///Get the distance in phi between trigger particle and correlated particle\r
61 Float_t GetDPhi(Float_t dPhi) { \r
62 if ( dPhi < 3*TMath::PiOver2() && dPhi > - TMath::PiOver2() ) return dPhi;\r
63 else return ( (dPhi>0)? dPhi - TMath::TwoPi() : dPhi + TMath::TwoPi() ); \r
64 }\r
65\r
fc7e3b59 66\r
811b0806 67 TArrayD * GetTriggerBins() const { return fPtBins; }\r
fc7e3b59 68\r
69 //Print statistics for histograms\r
70 void PrintStatistics();\r
71\r
72\r
73protected:\r
74\r
75 //Fill histograms\r
76 void FillHistograms(Float_t tPt, Float_t cPt, Float_t dPhi, Float_t dEta, Bool_t isolated);\r
77 //Fill trigger counter histograms\r
78 void FillTriggerCounters(Float_t tPt, Bool_t isolated);\r
79\r
80 private:\r
81 \r
82 TString fName; //name of analysis\r
fc7e3b59 83 TList * fHistograms; //List of histograms\r
84\r
811b0806 85 Int_t fNPhiBins; //Nbins in phi direction\r
86 TArrayD * fdPhiBins; //!transient phi bin array\r
87 TArrayD * fPtBins; //!Array of trigger bins\r
fc7e3b59 88 \r
fc7e3b59 89\r
811b0806 90 TH3F * fHdPhi[2]; //dPhi pt histogram\r
91 TH1F * fHNTriggers[2]; //Histograms containing number of triggers in various bins\r
92\r
93\r
fc7e3b59 94 //Default constructor prohibited\r
95 AliAnaConvCorrBase(); //not implemented\r
96 AliAnaConvCorrBase(const AliAnaConvCorrBase&); // not implemented\r
97 AliAnaConvCorrBase& operator=(const AliAnaConvCorrBase&); // not implemented\r
811b0806 98 ClassDef(AliAnaConvCorrBase, 3); // example of analysis\r
fc7e3b59 99};\r
100\r
101#endif\r