|
43 | 43 |
|
44 | 44 | #include <Rtypes.h> |
45 | 45 |
|
| 46 | +#include <array> |
46 | 47 | #include <cmath> |
47 | 48 | #include <cstddef> |
48 | 49 | #include <cstdint> |
@@ -187,37 +188,37 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to |
187 | 188 | // *) Define and initialize all data members to be called in the main process* functions: |
188 | 189 | // **) Task configuration: |
189 | 190 | struct TaskConfiguration { |
190 | | - bool fProcess[eProcess_N] = {false}; // Set what to process. See enum EProcess for full description. Set via implicit variables within a PROCESS_SWITCH clause. |
191 | | - bool fDryRun = false; // book all histos and run without filling and calculating anything |
192 | | - } tc; // you have to prepend "tc." for all objects name in this group later in the code |
| 191 | + std::array<bool, eProcess_N> fProcess{false}; // Set what to process. See enum EProcess for full description. Set via implicit variables within a PROCESS_SWITCH clause. |
| 192 | + bool fDryRun = false; // book all histos and run without filling and calculating anything |
| 193 | + } tc; // you have to prepend "tc." for all objects name in this group later in the code |
193 | 194 |
|
194 | 195 | // **) Particle histograms: |
195 | 196 | struct ParticleHistograms { |
196 | | - TList* fParticleHistogramsList = NULL; //!<! list to hold all control particle histograms |
197 | | - TH1F* fParticleHistograms[eParticleHistograms_N][2][2] = {{{NULL}}}; |
| 197 | + TList* fParticleHistogramsList = nullptr; //!<! list to hold all control particle histograms |
| 198 | + std::array<std::array<std::array<TH1F*, 2>, 2>, eParticleHistograms_N> fParticleHistograms{}; |
198 | 199 | } pc; // you have to prepend "pc." for all objects name in this group later in the code |
199 | 200 |
|
200 | 201 | // *) Event histograms: |
201 | 202 | struct EventHistograms { |
202 | | - TList* fEventHistogramsList = NULL; //!<! list to hold all event-level histograms |
203 | | - TH1F* fEventHistograms[eEventHistograms_N][2][2] = {{{NULL}}}; //! [ type - see enum EEventHistograms ][reco,sim][before, after event cuts] |
204 | | - } ec; // prepend "ec." for event counters |
| 203 | + TList* fEventHistogramsList = nullptr; //!<! list to hold all event-level histograms |
| 204 | + std::array<std::array<std::array<TH1F*, 2>, 2>, eEventHistograms_N> fEventHistograms{}; //! [ type - see enum EEventHistograms ][reco,sim][before, after event cuts] |
| 205 | + } ec; // prepend "ec." for event counters |
205 | 206 |
|
206 | 207 | // *) External histograms: |
207 | 208 | struct ExternalHistograms { |
208 | | - TList* fExternalHistogramsList = NULL; |
209 | | - TH1D* fhistWeights = NULL; |
| 209 | + TList* fExternalHistogramsList = nullptr; |
| 210 | + TH1D* fhistWeights = nullptr; |
210 | 211 | } ex; |
211 | 212 |
|
212 | 213 | struct Observables { |
213 | | - TList* fObservablesList = NULL; |
214 | | - TProfile* fProfTwo[2][2] = {{NULL}}; //! [reco,sim][before, after event cuts] |
| 214 | + TList* fObservablesList = nullptr; |
| 215 | + std::array<std::array<TProfile*, 2>, 2> fProfTwo{}; //! [reco,sim][before, after event cuts] |
215 | 216 | } obs; |
216 | 217 |
|
217 | 218 | // *) Quality assurance histograms: |
218 | 219 | struct QualityAssurance { |
219 | | - TList* fQualityAssuranceList = NULL; //!<! list to hold all qualityAssurance histograms |
220 | | - TH2F* fHistCentralityRecSim = NULL; |
| 220 | + TList* fQualityAssuranceList = nullptr; //!<! list to hold all qualityAssurance histograms |
| 221 | + TH2F* fHistCentralityRecSim = nullptr; |
221 | 222 | } qa; // prepend "qa." for qa histograms |
222 | 223 |
|
223 | 224 | // *) functions |
@@ -552,6 +553,12 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to |
552 | 553 | break; // thisCent is already FT0C |
553 | 554 | } |
554 | 555 |
|
| 556 | + LOGF(info, |
| 557 | + "centFT0C=%.6f centFT0M=%.6f centFV0A=%.6f", |
| 558 | + collision.centFT0C(), |
| 559 | + collision.centFT0M(), |
| 560 | + collision.centFV0A()); |
| 561 | + |
555 | 562 | auto thisRefMult = collision.multTPC(); // use auto to determine the type |
556 | 563 | switch (multiplicityTables) { |
557 | 564 | case eMultTPC: |
@@ -605,7 +612,7 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to |
605 | 612 | if (rm == eMC) { |
606 | 613 | auto thisMCCollision = collision.mcCollision(); // corresponding MC truth simulated particle |
607 | 614 | int multiplicitySim = static_cast<int>(tracks.size()); |
608 | | - auto impactParameter = thisMCCollision.impactParameter() * 1e15; |
| 615 | + auto impactParameter = thisMCCollision.impactParameter(); |
609 | 616 | LOGF(info, |
610 | 617 | "Reco collision = %d, MC collision = %d, b = %f", |
611 | 618 | collision.globalIndex(), |
|
0 commit comments