]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGLF/FORWARD/analysis2/AliAODCentralMult.h
Merge branch 'feature-movesplit'
[u/mrichter/AliRoot.git] / PWGLF / FORWARD / analysis2 / AliAODCentralMult.h
1 //
2 // See implementation or Doxygen comments for more information
3 //
4 #ifndef ALIAODCENTRALMULT_H
5 #define ALIAODCENTRALMULT_H
6 /**
7  * @file   AliAODCentralMult.h
8  * @author Hans Hjersing Dalsgaard
9  * @date   Wed Mar 23 13:57:24 2011
10  * 
11  * @brief  
12  * 
13  * @ingroup pwglf_forward_aod
14  * 
15  */
16 #include <TObject.h>
17 #include <TH2D.h>
18 class TBrowser;
19 /**
20  * Class that contains the central multiplicity data per event 
21  *
22  * This class contains a histogram of 
23  * @f[
24  *   \frac{d^2N_{ch}}{d\eta d\phi}\quad,
25  * @f]
26  * as well as a trigger mask for each analysed event.  
27  * 
28  * The eta acceptance of the event is stored in the underflow bins of
29  * the histogram.  So to build the final histogram, one needs to
30  * correct for this acceptance (properly weighted by the events), and
31  * the vertex efficiency.  This simply boils down to defining a 2D
32  * histogram and summing the event histograms in that histogram.  One
33  * should of course also do proper book-keeping of the accepted event.
34  *
35  * @ingroup pwglf_forward
36  * @ingroup pwglf_forward_aod
37  */
38 class AliAODCentralMult : public TObject
39 {
40 public:
41   /** 
42    * User bits of these objects (bits 14-23 can be used)
43    */
44   enum {
45     /** Secondary correction maps where applied */
46     kSecondary           = (1 << 14), 
47     /** Acceptance correction was applied */
48     kAcceptance          = (1 << 16), 
49     /** Used eta dependent empirical correction - to be implemented */
50     kEmpirical           = (1 << 19)
51   };
52   /** 
53    * Default constructor 
54    * 
55    * Used by ROOT I/O sub-system - do not use
56    */
57   AliAODCentralMult();
58   /** 
59    * Constructor 
60    * 
61    * @param isMC Whether this was from MC or not 
62    */
63   AliAODCentralMult(Bool_t isMC);
64   /** 
65    * Destructor 
66    */
67   virtual ~AliAODCentralMult() {} // Destructor 
68   /** 
69    * Initialize 
70    * 
71    * @param etaAxis  Pseudo-rapidity axis
72    */
73   void Init(const TAxis& etaAxis);
74   /** 
75    * Get the @f$ d^2N_{ch}/d\eta d\phi@f$ histogram, 
76    *
77    * @return @f$ d^2N_{ch}/d\eta d\phi@f$ histogram, 
78    */  
79   const TH2D& GetHistogram() const { return fHist; } // Get histogram 
80   /** 
81    * Get the @f$ d^2N_{ch}/d\eta d\phi@f$ histogram, 
82    *
83    * @return @f$ d^2N_{ch}/d\eta d\phi@f$ histogram, 
84    */  
85   TH2D& GetHistogram() { return fHist; } // Get histogram 
86   /**
87    * Clear Object between events
88    *
89    * @param opt option (not used)
90    *
91    */
92   void Clear(Option_t* opt);
93   /** 
94    * browse this object 
95    * 
96    * @param b Browser 
97    */
98   void Browse(TBrowser* b);
99   /** 
100    * This is a folder 
101    * 
102    * @return Always true
103    */
104   Bool_t IsFolder() const { return kTRUE; } // Always true 
105
106   Bool_t IsSecondaryCorrected() const { return TestBit(kSecondary); }
107   Bool_t IsAcceptanceCorrected() const { return TestBit(kAcceptance); }
108   Bool_t IsEmpiricalCorrected() const { return TestBit(kEmpirical); }
109   /** 
110    * Print content 
111    * 
112    * @param option Passed verbatim to TH2::Print 
113    */
114   void Print(Option_t* option="") const;
115
116   /** 
117    * Get the name of the object 
118    * 
119    * @return Name of object 
120    */
121   const Char_t* GetName() const { return (fIsMC ? "CentralClustersMC" : "CentralClusters"); }
122
123 protected: 
124   /** Whether this is MC */
125   Bool_t  fIsMC;     // Whether this is from MC 
126   /** Histogram of @f$d^2N_{ch}/(d\eta d\phi)@f$ for this event */
127   TH2D    fHist;     // Histogram of d^2N_{ch}/(deta dphi) for this event
128   
129   ClassDef(AliAODCentralMult,2); // AOD forward multiplicity 
130 };
131
132 #endif
133 // Local Variables:
134 //  mode: C++
135 // End:
136