setter to assume pion mass for clusters
[u/mrichter/AliRoot.git] / PWGJE / EMCALJetTasks / AliJetContainer.h
CommitLineData
421b12a3 1#ifndef AliJetContainer_H
2#define AliJetContainer_H
3
9239b066 4// $Id$
421b12a3 5
421b12a3 6class TClonesArray;
7class TString;
6421eeb0 8
421b12a3 9class AliEMCALGeometry;
10class AliEmcalJet;
11class AliVEvent;
6421eeb0 12class AliParticleContainer;
13class AliClusterContainer;
9e5eee5d 14class AliLocalRhoParameter;
421b12a3 15
421b12a3 16#include "AliRhoParameter.h"
421b12a3 17
6421eeb0 18#include "AliEmcalContainer.h"
421b12a3 19
20class AliJetContainer : public AliEmcalContainer {
21 public:
6421eeb0 22
421b12a3 23 enum JetAcceptanceType {
24 kTPC = 0, // TPC acceptance
25 kEMCAL = 1, // EMCal acceptance
4c9493a7 26 kUser = 2 // User defined acceptance
421b12a3 27 };
28
29
30 AliJetContainer();
31 AliJetContainer(const char *name);
6421eeb0 32 virtual ~AliJetContainer() {;}
421b12a3 33
421b12a3 34 void SetEMCALGeometry();
35 void SetEMCALGeometry(AliEMCALGeometry *p) {fGeom = p;}
36 void LoadRho(AliVEvent *event);
9e5eee5d 37 void LoadLocalRho(AliVEvent *event);
4d3b366f 38 void LoadRhoMass(AliVEvent *event);
421b12a3 39
40 void SetJetAcceptanceType(JetAcceptanceType type) { fJetAcceptanceType = type ; }
6c3dc2d6 41 void PrintCuts();
421b12a3 42 void ResetCuts();
421b12a3 43 void SetJetEtaPhiEMCAL() ;
44 void SetJetEtaPhiTPC() ;
56f370b0 45 void SetRunNumber(Int_t r) { fRunNumber = r; }
421b12a3 46 void SetJetEtaLimits(Float_t min, Float_t max) { fJetMinEta = min, fJetMaxEta = max ; }
47 void SetJetPhiLimits(Float_t min, Float_t max) { fJetMinPhi = min, fJetMaxPhi = max ; }
7a615dc4 48 void SetJetPtCut(Float_t cut) { fJetPtCut = cut ; }
49 void SetJetRadius(Float_t r) { fJetRadius = r ; }
421b12a3 50 void SetJetAreaCut(Float_t cut) { fJetAreaCut = cut ; }
9239b066 51 void SetPercAreaCut(Float_t p) { if(fJetRadius==0.) AliWarning("JetRadius not set. Area cut will be 0");
52 fJetAreaCut = p*TMath::Pi()*fJetRadius*fJetRadius; }
7a615dc4 53 void SetAreaEmcCut(Double_t a = 0.99) { fAreaEmcCut = a ; }
413ab3a3 54 void SetZLeadingCut(Float_t zemc, Float_t zch) { fZLeadingEmcCut = zemc; fZLeadingChCut = zch ; }
9e5eee5d 55 void SetNEFCut(Float_t min = 0., Float_t max = 1.) { fNEFMinCut = min; fNEFMaxCut = max; }
3c9775d9 56 void SetFlavourCut(Int_t myflavour) { fFlavourSelection = myflavour;}
421b12a3 57 void SetMaxClusterPt(Float_t b) { fMaxClusterPt = b ; }
58 void SetMaxTrackPt(Float_t b) { fMaxTrackPt = b ; }
59 void SetPtBiasJetClus(Float_t b) { fPtBiasJetClus = b ; }
60 void SetNLeadingJets(Int_t t) { fNLeadingJets = t ; }
61 void SetPtBiasJetTrack(Float_t b) { fPtBiasJetTrack = b ; }
421b12a3 62 void SetLeadingHadronType(Int_t t) { fLeadingHadronType = t ; }
63 void SetJetBitMap(UInt_t m) { fJetBitMap = m ; }
6421eeb0 64 void SetJetTrigger(UInt_t t=AliVEvent::kEMCEJE) { fJetTrigger = t ; }
7a615dc4 65 void SetTagStatus(Int_t i) { fTagStatus = i ; }
66
67 virtual void SetRhoName(const char *n) { fRhoName = n ; }
68 virtual void SetLocalRhoName(const char *n) { fLocalRhoName = n ; }
4d3b366f 69 virtual void SetRhoMassName(const char *n) { fRhoMassName = n ; }
7cd832c7 70 void ConnectParticleContainer(AliParticleContainer *c) { fParticleContainer = c ; }
71 void ConnectClusterContainer(AliClusterContainer *c) { fClusterContainer = c ; }
ba7663ad 72
b6f970ad 73 AliEmcalJet *GetLeadingJet(const char* opt="") ;
6421eeb0 74 AliEmcalJet *GetJet(Int_t i) const;
421b12a3 75 AliEmcalJet *GetAcceptJet(Int_t i) const;
7cd832c7 76 AliEmcalJet *GetJetWithLabel(Int_t lab) const;
77 AliEmcalJet *GetAcceptJetWithLabel(Int_t lab) const;
b6f970ad 78 AliEmcalJet *GetNextAcceptJet(Int_t i=-1) ;
7cd832c7 79 AliEmcalJet *GetNextJet(Int_t i=-1) ;
6421eeb0 80 void GetMomentum(TLorentzVector &mom, Int_t i) const;
81 Bool_t AcceptJet(AliEmcalJet* jet) const;
3c9775d9 82 Bool_t AcceptBiasJet(AliEmcalJet* jet) const;
83 Int_t GetFlavourCut() const {return fFlavourSelection;}
421b12a3 84 Int_t GetNJets() const {return GetNEntries();}
85 Double_t GetLeadingHadronPt(AliEmcalJet* jet) const;
6421eeb0 86 void GetLeadingHadronMomentum(TLorentzVector &mom, AliEmcalJet* jet) const;
413ab3a3 87 Double_t GetZ(AliEmcalJet *jet, TLorentzVector mom) const;
88 Double_t GetZLeadingEmc(AliEmcalJet *jet) const;
89 Double_t GetZLeadingCharged(AliEmcalJet *jet) const;
421b12a3 90 AliRhoParameter *GetRhoParameter() {return fRho;}
3c9775d9 91 Double_t GetRhoVal() const {if (fRho) return fRho->GetVal(); else return 0;}
421b12a3 92 const TString& GetRhoName() const {return fRhoName;}
9e5eee5d 93 AliLocalRhoParameter *GetLocalRhoParameter() const {return fLocalRho;}
94 const TString& GetLocalRhoName() const {return fLocalRhoName;}
4d3b366f 95 AliRhoParameter *GetRhoMassParameter() {return fRhoMass;}
96 Double_t GetRhoMassVal() const {if (fRhoMass) return fRhoMass->GetVal(); else return 0;}
97 const TString& GetRhoMassName() const {return fRhoMassName;}
421b12a3 98 Double_t GetJetPtCorr(Int_t i) const;
9e5eee5d 99 Double_t GetJetPtCorrLocal(Int_t i) const;
56f370b0 100 Float_t GetJetRadius() const {return fJetRadius;}
4c9493a7 101 Float_t GetJetEtaMin() const {return fJetMinEta;}
102 Float_t GetJetEtaMax() const {return fJetMaxEta;}
103 Float_t GetJetPhiMin() const {return fJetMinPhi;}
104 Float_t GetJetPhiMax() const {return fJetMaxPhi;}
b6f970ad 105 void SetClassName(const char *clname);
106 void SetArray(AliVEvent *event);
7cd832c7 107 AliParticleContainer *GetParticleContainer() {return fParticleContainer;}
108 AliClusterContainer *GetClusterContainer() {return fClusterContainer;}
ba7663ad 109 Double_t GetFractionSharedPt(AliEmcalJet *jet) const;
421b12a3 110
111 protected:
112 JetAcceptanceType fJetAcceptanceType; // acceptance type
113 Float_t fJetRadius; // jet radius
114 TString fRhoName; // Name of rho object
9e5eee5d 115 TString fLocalRhoName; // Name of local rho object
4d3b366f 116 TString fRhoMassName; // Name of rho mass object
3c9775d9 117 Int_t fFlavourSelection; // selection on jet flavour
421b12a3 118 Float_t fPtBiasJetTrack; // select jets with a minimum pt track
119 Float_t fPtBiasJetClus; // select jets with a minimum pt cluster
120 Float_t fJetPtCut; // cut on jet pt
121 Float_t fJetAreaCut; // cut on jet area
122 Float_t fAreaEmcCut; // minimum cut on jet emcal area
123 Float_t fJetMinEta; // minimum eta jet acceptance
124 Float_t fJetMaxEta; // maximum eta jet acceptance
125 Float_t fJetMinPhi; // minimum phi jet acceptance
126 Float_t fJetMaxPhi; // maximum phi jet acceptance
127 Float_t fMaxClusterPt; // maximum cluster constituent pt to accept the jet
128 Float_t fMaxTrackPt; // maximum track constituent pt to accept the jet
413ab3a3 129 Float_t fZLeadingEmcCut; // maximum z,leading neutral
130 Float_t fZLeadingChCut; // maximum z,leading charged
9e5eee5d 131 Float_t fNEFMinCut; // minimum NEF in a jet
132 Float_t fNEFMaxCut; // maximum NEF in a jet
421b12a3 133 Int_t fLeadingHadronType; // 0 = charged, 1 = neutral, 2 = both
134 Int_t fNLeadingJets; // how many jets are to be considered the leading jet(s)
135 UInt_t fJetBitMap; // bit map of accepted jets
6421eeb0 136 UInt_t fJetTrigger; // jet trigger
7a615dc4 137 Int_t fTagStatus; // jet tag status
7cd832c7 138 AliParticleContainer *fParticleContainer; // particle container (jet constituents)
139 AliClusterContainer *fClusterContainer; // cluster container (jet constituents)
6421eeb0 140 AliRhoParameter *fRho; //! event rho for these jets
9e5eee5d 141 AliLocalRhoParameter *fLocalRho; //! event local rho for these jets
4d3b366f 142 AliRhoParameter *fRhoMass; //! event rho mass for these jets
6421eeb0 143 AliEMCALGeometry *fGeom; //! emcal geometry
144 Int_t fRunNumber; //! run number
421b12a3 145
146 private:
147 AliJetContainer(const AliJetContainer& obj); // copy constructor
148 AliJetContainer& operator=(const AliJetContainer& other); // assignment
149
4d3b366f 150 ClassDef(AliJetContainer,9);
421b12a3 151
152};
153
154#endif