AliPhysics  bba8f44 (bba8f44)
AliAnalysisTaskChargedParticlesRef.h
Go to the documentation of this file.
1 #ifndef ALIANALYSISTASKCHARGEDPARTICLESREF_H
2 #define ALIANALYSISTASKCHARGEDPARTICLESREF_H
3 /* Copyright(c) 1998-2015, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice */
5 
7 #include "AliCutValueRange.h"
8 #include <vector>
9 #include <TCustomBinning.h>
10 #include <TString.h>
11 
12 class THistManager;
14 
15 namespace EMCalTriggerPtAnalysis {
16 
30 public:
31 
41  kpPb = 1,
42  kPbp = -1
43  };
44 
49 
54  AliAnalysisTaskChargedParticlesRef(const char *name);
55 
60 
69  void EnableSumw2(Bool_t doEnable) { fEnableSumw2 = doEnable; }
70 
79  void InitializeTrackCuts(TString cutname, bool isAOD);
80 
86  void SetRapidityShift(Double_t yshift) { fYshift = yshift; }
87 
92  void SetBeamDirection(BeamDirection_t beamdir) { fEtaSign = static_cast<Double_t>(beamdir); }
93 
98  void SetPlotPID(Bool_t plotPID) { fStudyPID = plotPID; }
99 
105 
113 
119  void SetEtaLabCut(double etamin, double etamax) { fEtaLabCut.SetLimits(etamin, etamax); }
120 
126  void SetEtaCMSCut(double etamin, double etamax) { fEtaCmsCut.SetLimits(etamin, etamax); }
127 
133  void SetTrackPhiCut(double phimin, double phimax) { fPhiCut.SetLimits(phimin, phimax); }
134 
139  void SetMinPtTracks(Double_t minpt) { fMinPt = minpt; }
140 
145  void SetStudyEMCALgeo(Bool_t doStudy) { fStudyEMCALgeo = doStudy; }
146 
154 
161 
168 
169 protected:
170 
174  virtual void CreateUserHistos();
175 
183  virtual void CreateUserObjects();
184 
193  virtual bool Run();
194 
200  virtual void UserFillHistosBeforeEventSelection();
201 
207  virtual void UserFillHistosAfterEventSelection();
208 
220  void FillTrackHistos(const TString &eventclass, const TString &histtag, Bool_t posCharge, Double_t pt, Double_t eta, Double_t etacent, Double_t phi, Bool_t inEmcal);
221 
227  void FillPIDHistos(const TString &eventclass, const AliVTrack &track);
228 
237  Int_t GetTOFBunchCrossing(const AliVTrack *trk, Double_t b = 0, Double_t spacing = 25, Bool_t pidTPConly = kTRUE) const;
238 
249  bool IsExoticsTrigger(const TString &trg);
250 
252 
255 
260 
266 
267 private:
268 
273  class PtBinning : public TCustomBinning{
274  public:
275 
279  PtBinning();
280 
284  virtual ~PtBinning() {}
285  };
286 
289 
293 };
294 
295 } /* namespace EMCalTriggerPtAnalysis */
296 
297 #endif /* ALIANALYSISTASKCHARGEDPARTICLESREF_H */
Interface for virtual track selection.
BeamDirection_t
Direction of the beams in an asymmetric collision system.
virtual bool Run()
Simple task testing particle spectra in triggered events.
void SetRequireTOFBunchCrossing(Bool_t doRequire)
Require bunch crossing information of track obtained from TOF (if available) matches the bunch crossi...
double Double_t
Definition: External.C:58
Double_t fEtaSign
Sign of the eta distribution (swaps when beam directions swap): p-Pb: +1, Pb-p: -1.
static AliAnalysisTaskChargedParticlesRef * AddTaskChargedParticlesRef(const TString &suffix)
Pre-configure task so that it can be used in subwagons.
void SetTrackPhiCut(double phimin, double phimax)
Define cut on used to select tracks.
Int_t GetTOFBunchCrossing(const AliVTrack *trk, Double_t b=0, Double_t spacing=25, Bool_t pidTPConly=kTRUE) const
void EnableSumw2(Bool_t doEnable)
Enable Sumw2 when creating the histograms.
void SetEtaLabCut(double etamin, double etamax)
Define cut on used to select tracks.
virtual void UserFillHistosBeforeEventSelection()
Implementation of framework function UserFillHistosBeforeEventSelection.
void SetPlotPID(Bool_t plotPID)
Enable PID-related plots (THnSparses, might be big)
bool IsExoticsTrigger(const TString &trg)
Check if the trigger is fired by an exotic cluster.
const Double_t etamin
Bool_t fStudyEMCALgeo
Add histograms for tracks pointing to the EMCAL acceptance.
void SetRapidityShift(Double_t yshift)
Define rapidity shift applied to convert to .
static AliAnalysisTaskChargedParticlesRef * AddTaskChargedParticlesRefDefault(const TString &cutname="standard")
Fully configure task, not intended for subwagons. Using a default cut configuration.
int Int_t
Definition: External.C:63
Bool_t fStudyExoticTriggers
Switch on whether to study exotic triggers or not.
void SetStudyEMCALgeo(Bool_t doStudy)
Add histograms for tracks pointing to EMCAL supermodules.
void SetEMCALTrackSelection(AliEmcalTrackSelection *sel)
Set the virtual track selection.
Helper class creating user defined custom binning.
void SetMinPtTracks(Double_t minpt)
Set minimum used to select track candidate.
void SetStudyExoticTriggers(Bool_t doStudy)
Switch on-/off- study of exotic triggers (default: off)
void SetBeamDirection(BeamDirection_t beamdir)
Specify directions of the incoming beams (p-Pb or Pb-p)
Analysis of high- tracks in triggered events.
void SetEtaCMSCut(double etamin, double etamax)
Define cut on used to select tracks.
void FillPIDHistos(const TString &eventclass, const AliVTrack &track)
Fill PID-related histograms.
const Double_t etamax
void FillTrackHistos(const TString &eventclass, const TString &histtag, Bool_t posCharge, Double_t pt, Double_t eta, Double_t etacent, Double_t phi, Bool_t inEmcal)
Fill track (kinematic) histograms.
Container class for histograms.
Definition: THistManager.h:99
void InitializeTrackCuts(TString cutname, bool isAOD)
Set the track selection.
Bool_t fRequireTOFBunchCrossing
Require that the bunch crossing ID determined by TOF matches the bunch crossing ID of the event...
AliAnalysisTaskChargedParticlesRef & operator=(const AliAnalysisTaskChargedParticlesRef &)
bool Bool_t
Definition: External.C:53
virtual void UserFillHistosAfterEventSelection()
Implementation of framework function UserFillHistosAfterEventSelection.
const Double_t phimin