]>
Commit | Line | Data |
---|---|---|
7e4038b5 | 1 | #ifndef ALIROOT_PWG2_FORWARD_ANALYSIS2_ALIFMDCORRECTIONS_H |
2 | #define ALIROOT_PWG2_FORWARD_ANALYSIS2_ALIFMDCORRECTIONS_H | |
3 | #include <TNamed.h> | |
4 | #include <TList.h> | |
5 | #include "AliForwardUtil.h" | |
6 | class AliESDFMD; | |
7 | class TH2D; | |
8 | ||
9 | /** | |
10 | * This class calculates the inclusive charged particle density | |
11 | * in each for the 5 FMD rings. | |
12 | * | |
13 | * @par Input: | |
14 | * - AliESDFMD object possibly corrected for sharing | |
15 | * | |
16 | * @par Output: | |
17 | * - 5 RingHistos objects - each with a number of vertex dependent | |
18 | * 2D histograms of the inclusive charge particle density | |
19 | * | |
20 | * @par Corrections used: | |
21 | * - AliFMDAnaCalibBackgroundCorrection | |
22 | * - AliFMDAnaCalibEventSelectionEfficiency | |
23 | * - AliFMDAnaCalibSharingEfficiency | |
24 | * | |
25 | * @ingroup pwg2_forward_analysis | |
26 | */ | |
27 | class AliFMDCorrections : public TNamed | |
28 | { | |
29 | public: | |
30 | /** | |
31 | * Constructor | |
32 | */ | |
33 | AliFMDCorrections(); | |
34 | /** | |
35 | * Constructor | |
36 | * | |
37 | * @param name Name of object | |
38 | */ | |
39 | AliFMDCorrections(const char* name); | |
40 | /** | |
41 | * Copy constructor | |
42 | * | |
43 | * @param o Object to copy from | |
44 | */ | |
45 | AliFMDCorrections(const AliFMDCorrections& o); | |
46 | /** | |
47 | * Destructor | |
48 | */ | |
49 | virtual ~AliFMDCorrections(); | |
50 | /** | |
51 | * Assignement operator | |
52 | * | |
53 | * @param o Object to assign from | |
54 | * | |
55 | * @return Reference to this object | |
56 | */ | |
57 | AliFMDCorrections& operator=(const AliFMDCorrections&); | |
58 | /** | |
59 | * Do the calculations | |
60 | * | |
61 | * @param hists Cache of histograms | |
62 | * @param vtxBin Vertex bin | |
63 | * | |
64 | * @return true on successs | |
65 | */ | |
66 | virtual Bool_t Correct(AliForwardUtil::Histos& hists, Int_t vtxBin); | |
67 | /** | |
68 | * Scale the histograms to the total number of events | |
69 | * | |
c389303e | 70 | * @param dir Where the output is stored |
7e4038b5 | 71 | * @param nEvents Number of events |
72 | */ | |
9d99b0dd | 73 | void ScaleHistograms(TList* dir, Int_t nEvents); |
7e4038b5 | 74 | /** |
75 | * Output diagnostic histograms to directory | |
76 | * | |
77 | * @param dir List to write in | |
78 | */ | |
9d99b0dd | 79 | void DefineOutput(TList* dir); |
8dc20805 | 80 | /** |
81 | * Set the debug level. The higher the value the more output | |
82 | * | |
83 | * @param dbg Debug level | |
84 | */ | |
85 | void SetDebug(Int_t dbg=1) { fDebug = dbg; } | |
7e4038b5 | 86 | protected: |
87 | /** | |
88 | * Internal data structure to keep track of the histograms | |
89 | */ | |
9d99b0dd | 90 | struct RingHistos : public AliForwardUtil::RingHistos |
7e4038b5 | 91 | { |
92 | /** | |
93 | * Default CTOR | |
94 | */ | |
95 | RingHistos(); | |
96 | /** | |
97 | * Constructor | |
98 | * | |
99 | * @param d detector | |
100 | * @param r ring | |
101 | */ | |
102 | RingHistos(UShort_t d, Char_t r); | |
103 | /** | |
104 | * Copy constructor | |
105 | * | |
106 | * @param o Object to copy from | |
107 | */ | |
108 | RingHistos(const RingHistos& o); | |
109 | /** | |
110 | * Assignment operator | |
111 | * | |
112 | * @param o Object to assign from | |
113 | * | |
114 | * @return Reference to this | |
115 | */ | |
116 | RingHistos& operator=(const RingHistos& o); | |
117 | /** | |
118 | * Destructor | |
119 | */ | |
120 | ~RingHistos(); | |
c389303e | 121 | /** |
122 | * Make output | |
123 | * | |
124 | * @param dir Where to put it | |
125 | */ | |
7e4038b5 | 126 | void Output(TList* dir); |
9d99b0dd | 127 | /** |
128 | * Scale the histograms to the total number of events | |
129 | * | |
c389303e | 130 | * @param dir where the output is stored |
9d99b0dd | 131 | * @param nEvents Number of events |
132 | */ | |
133 | void ScaleHistograms(TList* dir, Int_t nEvents); | |
7e4038b5 | 134 | TH2D* fDensity; // Distribution primary Nch |
9d99b0dd | 135 | ClassDef(RingHistos,1); |
7e4038b5 | 136 | }; |
137 | /** | |
138 | * Get the ring histogram container | |
139 | * | |
140 | * @param d Detector | |
141 | * @param r Ring | |
142 | * | |
143 | * @return Ring histogram container | |
144 | */ | |
145 | RingHistos* GetRingHistos(UShort_t d, Char_t r) const; | |
146 | ||
147 | TList fRingHistos; // List of histogram containers | |
148 | Double_t fMultCut; // Low cut on scaled energy loss | |
8dc20805 | 149 | Int_t fDebug; // Debug level |
7e4038b5 | 150 | |
151 | ClassDef(AliFMDCorrections,1); // Calculate Nch density | |
152 | }; | |
153 | ||
154 | #endif | |
155 | // Local Variables: | |
156 | // mode: C++ | |
157 | // End: | |
158 |