2 // Task to analyse the AOD for for dN/deta in the forward regions
4 #ifndef ALIMCTRUTHDNDETATASK_H
5 #define ALIMCTRUTHDNDETATASK_H
7 * @file AliMCTruthdNdetaTask.h
8 * @author Christian Holm Christensen <cholm@dalsgaard.hehi.nbi.dk>
9 * @date Wed Mar 23 14:04:54 2011
14 * @ingroup pwglf_forward_dndeta
16 #include "AliBasedNdetaTask.h"
22 * Tasks to determine @f$ dN/d\eta@f$ in the forward regions
24 * @ingroup pwglf_forward_tasks_dndeta
25 * @ingroup pwglf_forward_dndeta
27 class AliMCTruthdNdetaTask : public AliBasedNdetaTask
34 AliMCTruthdNdetaTask();
38 * @param name Name of task
40 AliMCTruthdNdetaTask(const char* name);
45 virtual ~AliMCTruthdNdetaTask() {}
47 * Called at end of event processing.
49 * This is called once in the master
51 virtual Bool_t Finalize();
56 * @param o Object to copy from
58 AliMCTruthdNdetaTask(const AliMCTruthdNdetaTask& o);
60 * Assigmement operator
62 * @return Reference to this
64 AliMCTruthdNdetaTask& operator=(const AliMCTruthdNdetaTask&);
67 * Retrieve the histogram
69 * @param aod AOD event
70 * @param mc Whether to get the MC histogram or not
72 * @return Retrieved histogram or null
74 TH2D* GetHistogram(const AliAODEvent& aod, Bool_t mc);
76 * Get the marker style
78 * @return Marker style
80 virtual Int_t GetMarker() const { return GetMarkerStyle(kStar); }
82 * Get the colour to use for markers (only pp - in PbPb we use a rainbow)
84 * @return Marker colour
86 virtual Int_t GetColor() const { return kGray+2; }
88 * Make a new centrality bin
90 * @param name Histogram names
94 * @return Newly allocated object (of our type)
96 AliBasedNdetaTask::CentralityBin*
97 MakeCentralityBin(const char* name, Short_t l, Short_t h) const;
100 * Class that holds data for a single centrality bin
103 class CentralityBin : public AliBasedNdetaTask::CentralityBin
109 CentralityBin() : AliBasedNdetaTask::CentralityBin(), fSumTruth(0) {}
113 * @param name Name used for histograms (e.g., Forward)
114 * @param low Lower centrality cut in percent
115 * @param high Upper centrality cut in percent
117 CentralityBin(const char* name, Short_t low, Short_t high)
118 : AliBasedNdetaTask::CentralityBin(name, low, high),
124 * @param other Object to copy from
126 CentralityBin(const CentralityBin& other)
127 : AliBasedNdetaTask::CentralityBin(other),
128 fSumTruth(other.fSumTruth)
133 virtual ~CentralityBin() {}
135 * Assignement operator
140 CentralityBin& operator=(const CentralityBin&) { return *this; }
144 * @param forward Forward data (for trigger, vertex, & centrality)
145 * @param triggerMask Trigger mask
146 * @param isZero True if this is a zero bin event
147 * @param vzMin Minimum IP z coordinate
148 * @param vzMax Maximum IP z coordinate
149 * @param data Data histogram
150 * @param mc MC histogram
152 virtual Bool_t ProcessEvent(const AliAODForwardMult* forward,
162 * @param sums List of sums
163 * @param results Output list of results
164 * @param scheme Normalisation scheme options
165 * @param shapeCorr Shape correction or nil
166 * @param trigEff Trigger efficiency
167 * @param trigEff0 0-bin trigger efficiency
168 * @param symmetrice Whether to symmetrice the results
169 * @param rebin Whether to rebin the results
170 * @param rootProj If true, use TH2::ProjectionX
171 * @param corrEmpty Whether to correct for empty bins
172 * @param cutEdges Whether to cut edges when rebinning
173 * @param triggerMask Trigger mask
174 * @param color Marker colour
175 * @param marker Marker style
176 * @param mclist List of MC results
177 * @param truthlist List of MC truth results
179 virtual void End(TList* sums,
182 const TH2F* shapeCorr,
196 TH2D* fSumTruth; // Sum of primary histograms
197 ClassDef(CentralityBin,2); // A centrality bin
199 Bool_t fHasData; // whether we actually have data or not
200 ClassDef(AliMCTruthdNdetaTask,2); // Determine multiplicity in forward region