]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWG0/AliPWG0Helper.h
Updated AliUnfolding class. The regularization schemas have changed taking into accou...
[u/mrichter/AliRoot.git] / PWG0 / AliPWG0Helper.h
CommitLineData
04a7657f 1/* $Id$ */
2
3#ifndef ALIPWG0HELPER_H
4#define ALIPWG0HELPER_H
5
6#include <TObject.h>
70fdd197 7#include <AliTriggerAnalysis.h>
04a7657f 8
9// static helper functions
10
770a1f1d 11class AliESDEvent;
116083b1 12class AliESDVertex;
04a7657f 13class TParticle;
dd367a14 14class TH1;
15class TH2;
25db2d85 16class TH3;
116083b1 17class AliHeader;
6b62a9c7 18class AliGenEventHeader;
116083b1 19class AliStack;
9cd015f7 20class TTree;
ff8c4f30 21class AliOfflineTrigger;
81be4ee8 22class AliMultiplicity;
04a7657f 23
24class AliPWG0Helper : public TObject
25{
26 public:
d879a92d 27 enum AnalysisMode { kInvalid = -1, kSPD = 0x1, kTPC = 0x2, kTPCITS = 0x4, kFieldOn = 0x8, kSPDOnlyL0 = 0x10 };
6b62a9c7 28 // in case we want to use bitmaps...
81be4ee8 29 enum MCProcessType { kInvalidProcess = -1, kND = 0x1, kDD = 0x2, kSD = 0x4, kOnePart = 0x8 };
30 enum DiffTreatment { kMCFlags = 0, kUA5Cuts = 1, kE710Cuts, kALICEHadronLevel };
e9c3977b 31
81be4ee8 32 static const AliESDVertex* GetVertex(const AliESDEvent* aEsd, AnalysisMode analysisMethod, Bool_t debug = kFALSE);
a6e0ebfe 33 static Bool_t TestVertex(const AliESDVertex* vertex, AnalysisMode analysisMode, Bool_t debug = kFALSE);
ff8c4f30 34
7584d357 35 static Bool_t IsPrimaryCharged(TParticle* aParticle, Int_t aTotalPrimaries, Bool_t adebug = kFALSE);
36
81be4ee8 37 static MCProcessType GetEventProcessType(AliESDEvent* esd, AliHeader* header, AliStack* stack, DiffTreatment diffTreatment);
38 static MCProcessType GetEventProcessType(AliHeader* aHeader, Bool_t adebug = kFALSE);
39 static MCProcessType GetPythiaEventProcessType(AliGenEventHeader* aHeader, Bool_t adebug = kFALSE);
40 static MCProcessType GetDPMjetEventProcessType(AliGenEventHeader* aHeader, Bool_t adebug = kFALSE);
a67484a6 41 static Int_t GetLastProcessType() { return fgLastProcessType; }
6b62a9c7 42
116083b1 43 static TParticle* FindPrimaryMother(AliStack* stack, Int_t label);
44 static Int_t FindPrimaryMotherLabel(AliStack* stack, Int_t label);
45
29771dc8 46 static void CreateProjections(TH3* hist, Bool_t save = kFALSE);
47 static void CreateDividedProjections(TH3* hist, TH3* hist2, const char* axis = 0, Bool_t putErrors = kFALSE, Bool_t save = kFALSE);
4c351225 48 static const char* GetAxisTitle(TH3* hist, const char axis);
116083b1 49
dd367a14 50 static void NormalizeToBinWidth(TH1* hist);
51 static void NormalizeToBinWidth(TH2* hist);
52
81be4ee8 53 static void PrintConf(AnalysisMode analysisMode, AliTriggerAnalysis::Trigger trigger, DiffTreatment diffTreatment);
54
55 static Double_t Rapidity(Double_t pt, Double_t pz, Double_t m);
56 static Bool_t IsHadronLevelSingleDiffractive(AliStack* stack, Float_t cms, Float_t xiMin, Float_t xiMax);
ff8c4f30 57
04a7657f 58 protected:
d879a92d 59 static Int_t fgLastProcessType; // stores the raw value of the last process type extracted
a67484a6 60
04a7657f 61 ClassDef(AliPWG0Helper, 0)
61385583 62
63 private:
64 AliPWG0Helper(const AliPWG0Helper&);
65 AliPWG0Helper& operator=(const AliPWG0Helper&);
04a7657f 66};
67
68#endif
69