]>
Commit | Line | Data |
---|---|---|
ec82df5b | 1 | // |
2 | // Task to analyse the AOD for for dN/deta in the central regions | |
3 | // | |
4 | #ifndef ALICENTRALDNDETATASK_H | |
5 | #define ALICENTRALDNDETATASK_H | |
6 | #include <AliAnalysisTaskSE.h> | |
7 | // #include <AliAODCentralMult.h> | |
8 | class TList; | |
9 | class TH2D; | |
10 | class TH1D; | |
11 | ||
12 | /** | |
13 | * Task to determine the | |
14 | */ | |
15 | class AliCentraldNdetaTask : public AliAnalysisTaskSE | |
16 | { | |
17 | public: | |
18 | /** | |
19 | * Constructor | |
20 | * | |
21 | */ | |
22 | AliCentraldNdetaTask(); | |
23 | /** | |
24 | * Constructor | |
25 | * | |
26 | * @param name Name of task | |
27 | * @param maxVtx Set @f$v_z@f$ range | |
28 | */ | |
29 | AliCentraldNdetaTask(const char* name); | |
30 | ||
31 | void SetVertexRange(Double_t min, Double_t max) { fVtxMin=min; fVtxMax=max; } | |
32 | void SetRebinning(Int_t rebin) { fRebin = rebin; } | |
33 | void SetTriggerMask(UShort_t mask) { fTriggerMask = mask; } | |
34 | void SetTriggerMask(const char* mask); | |
35 | /** | |
36 | * Destructor | |
37 | * | |
38 | */ | |
39 | virtual ~AliCentraldNdetaTask(); | |
40 | /** | |
41 | * Initialise on master - does nothing | |
42 | * | |
43 | */ | |
44 | virtual void Init() {} | |
45 | /** | |
46 | * Create output objects. | |
47 | * | |
48 | * This is called once per slave process | |
49 | */ | |
50 | virtual void UserCreateOutputObjects(); | |
51 | /** | |
52 | * Process a single event | |
53 | * | |
54 | * @param option Not used | |
55 | */ | |
56 | virtual void UserExec(Option_t* option); | |
57 | /** | |
58 | * Called at end of event processing.. | |
59 | * | |
60 | * This is called once in the master | |
61 | * | |
62 | * @param option Not used | |
63 | */ | |
64 | virtual void Terminate(Option_t* option); | |
65 | protected: | |
66 | AliCentraldNdetaTask(const AliCentraldNdetaTask&); | |
67 | AliCentraldNdetaTask& operator=(const AliCentraldNdetaTask&) { return *this; } | |
68 | /** | |
69 | * Clone a 2D histogram | |
70 | * | |
71 | * @param in Histogram to clone. | |
72 | * @param name New name of clone. | |
73 | * | |
74 | * @return The clone | |
75 | */ | |
76 | TH2D* CloneHist(TH2D* in, const char* name); | |
77 | /** | |
78 | * Make a copy of the input histogram and rebin that histogram | |
79 | * | |
80 | * @param h Histogram to rebin | |
81 | * | |
82 | * @return New (rebinned) histogram | |
83 | */ | |
84 | TH1D* Rebin(const TH1D* h) const; | |
85 | /** | |
86 | * Set histogram graphical options, etc. | |
87 | * | |
88 | * @param h Histogram to modify | |
89 | * @param colour Marker color | |
90 | * @param marker Marker style | |
91 | * @param title Title of histogram | |
92 | * @param ytitle Title on y-axis. | |
93 | */ | |
94 | void SetHistogramAttributes(TH1D* h, Int_t colour, Int_t marker, const char* title, | |
95 | const char* ytitle="#frac{1}{N} #frac{dN_{ch}}{d#eta}"); | |
96 | /** | |
97 | * Trigger histogram bins | |
98 | */ | |
99 | enum { | |
100 | kAll = 1, | |
101 | kB = 2, | |
102 | kA = 3, | |
103 | kC = 4, | |
104 | kE = 5, | |
105 | kMB = 6, | |
106 | kWithTrigger= 7, | |
107 | kWithVertex = 8, | |
108 | kAccepted = 9 | |
109 | }; | |
110 | ||
111 | TH2D* fSumCentral; // Sum of histograms | |
112 | TH2D* fSumCentralMC; // Sum of MC histograms (if any) | |
113 | ||
114 | TList* fSums; // Container of sums | |
115 | TList* fOutput; // Container of outputs | |
116 | ||
117 | TH1D* fTriggers; // Histogram of triggers | |
118 | ||
119 | Double_t fVtxMin; // Minimum v_z | |
120 | Double_t fVtxMax; // Maximum v_z | |
121 | Int_t fTriggerMask; // Trigger mask | |
122 | Int_t fRebin; // Rebinning factor | |
123 | Bool_t fCutEdges; // Whether to cut edges when rebinning | |
124 | ||
125 | ClassDef(AliCentraldNdetaTask,1); // Determine multiplicity in central area | |
126 | }; | |
127 | ||
128 | #endif |