1 /* This file is property of and copyright *
\r
2 * ALICE Experiment at CERN, All rights reserved. *
\r
3 * See cxx source for full Copyright notice */
\r
5 /// @file AliAnalysisTaskGammaJet.h
\r
6 /// @author Svein Lindal
\r
7 /// @brief Class used to run isolation studies of conversion gamma/pions
\r
10 #ifndef ALIANACONVISOLATION_H
\r
11 #define ALIANACONVISOLATION_H
\r
14 #include "TObject.h"
\r
17 #include "TString.h"
\r
21 class AliAODConversionPhoton;
\r
22 class AliAODConversionParticle;
\r
26 using namespace std;
\r
28 class AliAnaConvIsolation : public TObject {
\r
32 AliAnaConvIsolation();
\r
33 AliAnaConvIsolation(Float_t coneSize, Float_t maxPtThreshold, Float_t sumPtThreshold, Float_t maxPtFraction, Float_t sumPtFraction);
\r
34 virtual ~AliAnaConvIsolation();
\r
37 //void CreateHistograms();
\r
40 ///Set And get cone size
\r
41 void SetConeSize(Float_t cs) {fConeSize = cs*cs;}
\r
42 Float_t GetConeSize() const {return TMath::Sqrt(fConeSize);}
\r
45 //Set and get max pt threshold
\r
46 void SetMaxPtThreshold(Float_t cs) {fMaxPtThreshold = cs;}
\r
47 Float_t GetPtThreshold() const {return fMaxPtThreshold;}
\r
50 //Set and get sum pt threshold
\r
51 void SetSumPtThreshold(Float_t cs) {fSumPtThreshold = cs;}
\r
52 Float_t GetPtSumThreshold() const {return fSumPtThreshold;}
\r
54 //Set and get max Pt fraction threshold
\r
55 void SetMaxPtFraction(Float_t cs) {fMaxPtFraction = cs;}
\r
56 Float_t GetPtFraction() const {return fMaxPtFraction;}
\r
58 //Set and get sum pt fraction threshold
\r
59 void SetSumPtFraction(Float_t cs) {fSumPtFraction = cs;}
\r
60 Float_t GetPtSumFraction() const {return fSumPtFraction;}
\r
62 //Set min pt for a particle to be counted in bg
\r
63 void SetMinPt( Float_t minpt) {fMinPt = minpt; }
\r
65 //Get isolation curve
\r
66 TF1 * GetIsolationCurve() const { return fIsoCurve; }
\r
68 //Set function of isolation curve
\r
69 void SetIsolationCurve(TString curve) {
\r
70 fCurveFunction = curve;
\r
73 Bool_t IsLeading(AliAODConversionParticle * particle, const TObjArray * tracks, const TObjArray * aodParticles);
\r
77 //void FillHistograms(Float_t pt, Float_t ptMax, Float_t ptSum, Bool_t isolated, Int_t nTracks);
\r
79 //Get list of histograms
\r
80 //TList * GetHistograms() const { return fHistograms;}
\r
82 //Is particle isolated
\r
83 Bool_t IsIsolated( const AliAODConversionPhoton * const particle, const TClonesArray * const tracks, Bool_t &leading);
\r
84 Bool_t IsIsolated( AliAODConversionPhoton * const particle, const TClonesArray * const tracks, const Int_t nSpawn, const Int_t * const spawn, Bool_t &leading );
\r
85 Int_t IsLeading(const AliAODConversionParticle * particle, const TObjArray * tracks, const Int_t * tIDs) const;
\r
87 //Is eta - phi distance smaller than conesize ?
\r
88 Bool_t IsInCone(Float_t dEta, Float_t dPhi, const Float_t coneSize) const {
\r
89 dPhi = (TMath::Abs(dPhi) < TMath::Pi()) ? dPhi : TMath::TwoPi() - TMath::Abs(dPhi);
\r
90 return ( (dEta*dEta + dPhi*dPhi) < coneSize);
\r
95 ///Evaluate whether particle is isolated according to criterie
\r
96 Bool_t EvaluateIsolationCriteria(Float_t ptSum, Float_t pt) const;
\r
98 TF1 * fIsoCurve; ///Curve defining if particle is isolated or not
\r
99 TString fCurveFunction; ///Funtion defining curve
\r
101 Float_t fConeSize; //Size of isolation cone
\r
102 Float_t fMinPt; //min pt for bg particles
\r
103 Float_t fMaxPtThreshold; //max pt threshold
\r
104 Float_t fSumPtThreshold; //sum pt threhold
\r
105 Float_t fMaxPtFraction; //max pt fraction threshold
\r
106 Float_t fSumPtFraction; //sum pt fraction threshold
\r
108 // TList * fHistograms; //list of histograms
\r
110 // TH2F * fhMaxPtInCone[2]; //histogram of max pt in cone
\r
111 // TH2F * fhSumPtInCone[2]; //histogram of sum pt in cone
\r
112 // TH2F * fhSumPtVsMaxPt[2];//sum pt vs max pt
\r
114 // // TH1F * fHistSumPt[2][2];
\r
115 // // TH1F * fHistMaxPt[2][2];
\r
117 // TH1F * fhPtCandidates[2]; //pt distribution of isolation candidates
\r
118 // TH1F * fhTrackMult[2]; //Track multiplicity of events with / wo isolated particles
\r
121 // Float_t fHistogramMaxPt; //Upper pt limit in histograms
\r
124 AliAnaConvIsolation(const AliAnaConvIsolation&); // not implemented
\r
125 AliAnaConvIsolation& operator=(const AliAnaConvIsolation&); // not implemented
\r
126 ClassDef(AliAnaConvIsolation, 2); // example of analysis
\r