]>
Commit | Line | Data |
---|---|---|
7984e5f7 | 1 | // |
2 | // This class calculates the inclusive charged particle density | |
3 | // in each for the 5 FMD rings based on the MC truth. | |
4 | // | |
68d11054 | 5 | #ifndef ALIFMDMCDENSITYCALCULATOR_H |
6 | #define ALIFMDMCDENSITYCALCULATOR_H | |
0bd4b00f | 7 | #include "AliFMDDensityCalculator.h" |
8 | #include <TList.h> | |
9 | #include "AliForwardUtil.h" | |
10 | class AliMCEvent; | |
68d11054 | 11 | class TH2; |
0bd4b00f | 12 | class TH2D; |
68d11054 | 13 | class TProfile2D; |
0bd4b00f | 14 | |
15 | /** | |
16 | * This class calculates the inclusive charged particle density | |
17 | * in each for the 5 FMD rings based on the MC truth. | |
18 | * | |
19 | * @par Input: | |
20 | * - AliMCEvent MC truth event infromation | |
21 | * | |
22 | * @par Output: | |
23 | * - None | |
24 | * | |
25 | * @par Corrections used: | |
26 | * - None | |
27 | * | |
68d11054 | 28 | * @ingroup pwg2_forward_algo |
29 | * @ingroup pwg2_forward_mc | |
0bd4b00f | 30 | */ |
31 | class AliFMDMCDensityCalculator : public AliFMDDensityCalculator | |
32 | { | |
33 | public: | |
34 | /** | |
35 | * Constructor | |
36 | */ | |
68d11054 | 37 | AliFMDMCDensityCalculator() |
38 | : AliFMDDensityCalculator(), | |
39 | fFMD1i(0), | |
40 | fFMD2i(0), | |
41 | fFMD2o(0), | |
42 | fFMD3i(0), | |
43 | fFMD3o(0), | |
44 | fFMD1iC(0), | |
45 | fFMD2iC(0), | |
46 | fFMD2oC(0), | |
47 | fFMD3iC(0), | |
48 | fFMD3oC(0), | |
49 | fComps(0) | |
50 | {} | |
0bd4b00f | 51 | /** |
52 | * Constructor | |
53 | * | |
54 | * @param name Name of object | |
55 | */ | |
56 | AliFMDMCDensityCalculator(const char* name) | |
68d11054 | 57 | : AliFMDDensityCalculator(name), |
58 | fFMD1i(0), | |
59 | fFMD2i(0), | |
60 | fFMD2o(0), | |
61 | fFMD3i(0), | |
62 | fFMD3o(0), | |
63 | fFMD1iC(0), | |
64 | fFMD2iC(0), | |
65 | fFMD2oC(0), | |
66 | fFMD3iC(0), | |
67 | fFMD3oC(0), | |
68 | fComps(0) | |
0bd4b00f | 69 | {} |
70 | /** | |
71 | * Copy constructor | |
72 | * | |
73 | * @param o Object to copy from | |
74 | */ | |
75 | AliFMDMCDensityCalculator(const AliFMDMCDensityCalculator& o) | |
68d11054 | 76 | : AliFMDDensityCalculator(o) , |
77 | fFMD1i(o.fFMD1i), | |
78 | fFMD2i(o.fFMD2i), | |
79 | fFMD2o(o.fFMD2o), | |
80 | fFMD3i(o.fFMD3i), | |
81 | fFMD3o(o.fFMD3o), | |
82 | fFMD1iC(o.fFMD1iC), | |
83 | fFMD2iC(o.fFMD2iC), | |
84 | fFMD2oC(o.fFMD2oC), | |
85 | fFMD3iC(o.fFMD3iC), | |
86 | fFMD3oC(o.fFMD3oC), | |
87 | fComps(0) | |
0bd4b00f | 88 | {} |
89 | /** | |
90 | * Destructor | |
91 | */ | |
68d11054 | 92 | virtual ~AliFMDMCDensityCalculator(); |
0bd4b00f | 93 | /** |
94 | * Assignement operator | |
95 | * | |
96 | * @param o Object to assign from | |
97 | * | |
98 | * @return Reference to this object | |
99 | */ | |
7c1a1f1d | 100 | AliFMDMCDensityCalculator& operator=(const AliFMDMCDensityCalculator& o); |
0bd4b00f | 101 | /** |
68d11054 | 102 | * Initialize this object |
0bd4b00f | 103 | * |
68d11054 | 104 | * @param etaAxis Eta axis to use |
0bd4b00f | 105 | */ |
68d11054 | 106 | void Init(const TAxis& etaAxis); |
0bd4b00f | 107 | /** |
108 | * Calculate the charged particle density from the MC track references. | |
109 | * | |
110 | * @param event MC event | |
111 | * @param hists Histograms to fill | |
112 | * @param vz Interaction z coordinate @f$ v_z@f$ | |
113 | * @param vtxBin bin corresponding to @f$ v_z@f$ | |
114 | * | |
115 | * @return true on success | |
116 | */ | |
68d11054 | 117 | virtual Bool_t CalculateMC(const AliESDFMD& fmd, |
118 | AliForwardUtil::Histos& hists); | |
119 | ||
120 | /** | |
121 | * Compare the result of analysing the ESD for | |
122 | * the inclusive charged particle density to analysing | |
123 | * MC truth | |
124 | * | |
125 | * @param esd | |
126 | * @param mc | |
127 | * | |
128 | * @return | |
129 | */ | |
130 | virtual Bool_t CompareResults(AliForwardUtil::Histos& esd, | |
131 | AliForwardUtil::Histos& mc); | |
132 | /** | |
133 | * Output diagnostic histograms to directory | |
134 | * | |
135 | * @param dir List to write in | |
136 | */ | |
137 | void DefineOutput(TList* dir); | |
0bd4b00f | 138 | protected: |
68d11054 | 139 | /** |
140 | * MAke comparison profiles | |
141 | * | |
142 | * @param d Detector | |
143 | * @param r Ring | |
144 | * @param axis Eta axis | |
145 | * | |
146 | * @return Newly allocated profile object | |
147 | */ | |
148 | TProfile2D* Make(UShort_t d, Char_t r, const TAxis& axis) const; | |
149 | /** | |
150 | * MAke comparison profiles | |
151 | * | |
152 | * @param d Detector | |
153 | * @param r Ring | |
154 | * | |
155 | * @return Newly allocated profile object | |
156 | */ | |
157 | TH2D* Make(UShort_t d, Char_t r) const; | |
158 | /** | |
159 | * Fill comparison profiles | |
160 | * | |
161 | * @param d Detector | |
162 | * @param r Ring | |
163 | * @param esd ESD histogram | |
164 | * @param mc MC histogram | |
165 | */ | |
166 | void Fill(UShort_t d, Char_t r, TH2* esd, TH2* mc); | |
167 | ||
168 | TProfile2D* fFMD1i; // Comparison | |
169 | TProfile2D* fFMD2i; // Comparison | |
170 | TProfile2D* fFMD2o; // Comparison | |
171 | TProfile2D* fFMD3i; // Comparison | |
172 | TProfile2D* fFMD3o; // Comparison | |
173 | TH2D* fFMD1iC; // Correlation in FMD1i | |
174 | TH2D* fFMD2iC; // Correlation in FMD2i | |
175 | TH2D* fFMD2oC; // Correlation in FMD2o | |
176 | TH2D* fFMD3iC; // Correlation in FMD3i | |
177 | TH2D* fFMD3oC; // Correlation in FMD3o | |
178 | TList* fComps; // List of comparisons | |
0bd4b00f | 179 | |
180 | ClassDef(AliFMDMCDensityCalculator,1); // Calculate Nch density | |
181 | }; | |
182 | ||
183 | #endif | |
184 | // Local Variables: | |
185 | // mode: C++ | |
186 | // End: | |
187 |