7 #include <TClonesArray.h>
11 #include <THnSparse.h>
13 #include <TLorentzVector.h>
15 #include "AliVCluster.h"
16 #include "AliAODCaloCluster.h"
17 #include "AliESDCaloCluster.h"
18 #include "AliVTrack.h"
40 fHistJetsPtLeadHad(0),
41 fHistJetsCorrPtArea(0),
58 fHistTracksPt =
new TH1*[fNcentBins];
59 fHistTracksEtaPhi =
new TH2*[fNcentBins];
60 fHistClustersPt =
new TH1*[fNcentBins];
61 fHistLeadingJetPt =
new TH1*[fNcentBins];
62 fHistJetsPhiEta =
new TH2*[fNcentBins];
63 fHistJetsPtArea =
new TH2*[fNcentBins];
64 fHistJetsPtLeadHad =
new TH2*[fNcentBins];
65 fHistJetsCorrPtArea =
new TH2*[fNcentBins];
67 for (
Int_t i = 0; i < fNcentBins; i++) {
69 fHistTracksEtaPhi[i] = 0;
70 fHistClustersPt[i] = 0;
71 fHistLeadingJetPt[i] = 0;
72 fHistJetsPhiEta[i] = 0;
73 fHistJetsPtArea[i] = 0;
74 fHistJetsPtLeadHad[i] = 0;
75 fHistJetsCorrPtArea[i] = 0;
84 SetMakeGeneralHistograms(kTRUE);
96 fHistJetsPtLeadHad(0),
97 fHistJetsCorrPtArea(0),
173 histname =
"fHistTracksPt_";
176 fHistTracksPt[i]->GetXaxis()->SetTitle(
"p_{T,track} (GeV/c)");
179 histname =
"fHistTracksEtaPhi_";
188 histname =
"fHistClustersPt_";
197 histname =
"fHistLeadingJetPt_";
204 histname =
"fHistJetsPhiEta_";
206 fHistJetsPhiEta[i] =
new TH2F(histname.Data(), histname.Data(), 50, -1, 1, 101, 0, TMath::Pi()*2 + TMath::Pi()/200);
211 histname =
"fHistJetsPtArea_";
218 histname =
"fHistJetsPtLeadHad_";
227 histname =
"fHistJetsCorrPtArea_";
238 Double_t xmin[] = { 0,-0.7, 0, 0, 0};
239 Double_t xmax[] = {150, 0.7,TMath::TwoPi(), 1, 150};
240 fHistJet1 =
new THnSparseF(
"Jets1Collection",
"Jets1Collection",5,nbins,xmin,xmax);
242 fHistJet1m =
new THnSparseF(
"Jets1CollectionMatched",
"Jets1Collection",5,nbins,xmin,xmax);
244 fHistJet1nm =
new THnSparseF(
"Jets1CollectionNotMatched",
"Jets1Collection",5,nbins,xmin,xmax);
246 fHistJet2 =
new THnSparseF(
"Jets2Collection",
"Jets2Collection",5,nbins,xmin,xmax);
249 Int_t nbins2[] = {150,100,100,100,150,100,100,100,100};
250 Double_t xmin2[] = {0,-0.7,0,0,0,-0.7,0,0,0};
251 Double_t xmax2[] = {150,0.7,6.28,1,150,0.7,6.28,1,0.2};
252 fHistJet1to2 =
new THnSparseF(
"Jets1to2Collection",
"Jets1to2Collection",9,nbins2,xmin2,xmax2);
255 Int_t nbins3[] = {150,100,100,100,150,100,100,100,100};
256 Double_t xmin3[] = {0,-0.7,0,0,0,-0.7,0,0,0};
257 Double_t xmax3[] = {150,0.7,6.28,1,150,0.7,6.28,1,1};
258 fHistDiJet1 =
new THnSparseF(
"fHistDiJet1",
"fHistDiJet1",9,nbins3,xmin3,xmax3);
261 Int_t nbins4[] = {150,100,100,100,150,100,100,100,100,150,100,100,100};
262 Double_t xmin4[] = {0,-0.7,0,0,0,-0.7,0,0,0,0,-0.7,0,0};
263 Double_t xmax4[] = {150,0.7,6.28,1,150,0.7,6.28,1,1,150,0.7,6.28,0.2};
264 fHistDiJet1m =
new THnSparseF(
"fHistDiJet1m",
"fHistDiJet1m",13,nbins4,xmin4,xmax4);
291 TLorentzVector nPart;
292 cluster->GetMomentum(nPart,
fVertex);
343 bool ismatched =
false;
386 if (fabs(fabs(dphi)-TMath::Pi())< TMath::Pi()/3.0){
397 Double_t dR = pow(tdeta2+tdphi2,0.5);
400 Double_t jetarray3[] = {jet1->
Pt(),jet1->
Eta(),jet1->
Phi(),jet1->
NEF(),jet3->
Pt(),jet3->
Eta(),jet3->
Phi(),jet3->
NEF(),Aj,jet2->
Pt(),jet2->
Eta(),jet2->
Phi(),jet2->
NEF(),dR};
422 if (vphi < -1*TMath::Pi()) vphi += (2*TMath::Pi());
423 else if (vphi > TMath::Pi()) vphi -= (2*TMath::Pi());
424 if (mphi < -1*TMath::Pi()) mphi += (2*TMath::Pi());
425 else if (mphi > TMath::Pi()) mphi -= (2*TMath::Pi());
426 double dphi = mphi-vphi;
427 if (dphi < -1*TMath::Pi()) dphi += (2*TMath::Pi());
428 else if (dphi > TMath::Pi()) dphi -= (2*TMath::Pi());
TObjArray fClusterCollArray
cluster collection array
virtual AliVParticle * GetNextAcceptParticle()
Double_t GetRhoVal() const
TH2 ** fHistTracksEtaPhi
Track pt spectrum.
Bool_t FillHistograms()
Function filling histograms.
THnSparse * fHistJet1to2
jet collection 2
Bool_t Run()
Run function. This is the core function of the analysis and contains the user code. Therefore users have to implement this function.
AliJetContainer * GetJetContainer(Int_t i=0) const
const TString & GetRhoName(Int_t c=0) const
Double_t fMinBinPt
min pt in histograms
void ExecOnce()
Perform steps needed to initialize the analysis.
AliClusterContainer * GetClusterContainer() const
Int_t fCentBin
!event centrality bin
THnSparse * fHistJet2
jet collection 1 unmatched
AliJetContainer * fJetsCont2
Jets Jet 1.
TH1 ** fHistClustersPt
Track eta phi.
TObjArray fParticleCollArray
particle/track collection array
AliParticleContainer * GetParticleContainer(Int_t i=0) const
Get particle container attached to this task.
virtual ~AliAnalysisTaskDcalDijetPerf()
AliParticleContainer * GetParticleContainer() const
AliEmcalJet * GetLeadingJet(const char *opt="")
AliJetContainer * fJetsCont
Dijet collection 1 and 3 matched.
AliClusterContainer * fCaloClustersCont
Tracks.
Double_t GetLeadingHadronPt(const AliEmcalJet *jet) const
Int_t fNcentBins
how many centrality bins
AliClusterContainer * GetClusterContainer(Int_t i=0) const
Get cluster container attached to this task.
THnSparse * fHistJet1m
jet collection 1
TH2 ** fHistJetsPtLeadHad
Jet pt vs. area.
TH2 ** fHistJetsPhiEta
Leading jet pt spectrum.
TH2 ** fHistJetsPtArea
Phi-Eta distribution of jets.
AliEmcalJet * GetNextAcceptJet()
THnSparse * fHistDiJet1
jet collection 1 and 2
TObjArray fJetCollArray
jet collection array
TH2 ** fHistJetsCorrPtArea
Jet pt vs. leading hadron.
AliParticleContainer * fTracksCont
Jets DiJet.
AliEmcalList * fOutput
!output list
Double_t fMaxBinPt
max pt in histograms
Float_t RelativePhi(Double_t mphi, Double_t vphi) const
AliAnalysisTaskDcalDijetPerf()
Double_t fVertex[3]
!event vertex
void UserCreateOutputObjects()
void SetMakeGeneralHistograms(Bool_t g)
THnSparse * fHistJet1nm
jet collection 1 matched
Base task in the EMCAL jet framework.
THnSparse * fHistDiJet1m
Dijet collection 1 and 3.
Represent a jet reconstructed using the EMCal jet framework.
THnSparse * fHistJet1
Jet pt - bkg vs. area.
void UserCreateOutputObjects()
Main initialization function on the worker.
TH1 ** fHistLeadingJetPt
Cluster pt spectrum.
AliJetContainer * fJetsCont3
Jets Trigger Jer.
AliVCluster * GetNextAcceptCluster()
Int_t fNbins
no. of pt bins
void Terminate(Option_t *option)