3 #ifndef ALIPWG0HELPER_H
4 #define ALIPWG0HELPER_H
8 // static helper functions
20 class AliPWG0Helper : public TObject
23 enum Trigger { kMB1 = 0, kMB2 }; // definition from ALICE-INT-2005-025
25 static Bool_t IsEventTriggered(const AliESD* aEsd, Trigger trigger = kMB2);
26 static Bool_t IsEventTriggered(ULong64_t triggerMask, Trigger trigger = kMB2);
27 static Bool_t IsVertexReconstructed(const AliESD* aEsd);
28 static Bool_t IsVertexReconstructed(const AliESDVertex* vtxESD);
29 static Bool_t IsPrimaryCharged(TParticle* aParticle, Int_t aTotalPrimaries, Bool_t adebug = kFALSE);
31 static Int_t GetPythiaEventProcessType(AliHeader* aHeader, Bool_t adebug = kFALSE);
32 static TParticle* FindPrimaryMother(AliStack* stack, Int_t label);
33 static Int_t FindPrimaryMotherLabel(AliStack* stack, Int_t label);
35 static void CreateProjections(TH3* hist, Bool_t save = kFALSE);
36 static void CreateDividedProjections(TH3* hist, TH3* hist2, const char* axis = 0, Bool_t putErrors = kFALSE, Bool_t save = kFALSE);
37 static const char* GetAxisTitle(TH3* hist, const char axis);
39 static void SetBranchStatusRecursive(TTree* tree, char *bname, Bool_t status, Bool_t debug = kFALSE);
41 static void NormalizeToBinWidth(TH1* hist);
42 static void NormalizeToBinWidth(TH2* hist);
45 ClassDef(AliPWG0Helper, 0)
48 AliPWG0Helper(const AliPWG0Helper&);
49 AliPWG0Helper& operator=(const AliPWG0Helper&);