2 // Dijet analysis task.
6 #include <TClonesArray.h>
10 #include <THnSparse.h>
12 #include <TLorentzVector.h>
19 #include "AliVCluster.h"
20 #include "AliVTrack.h"
21 #include "AliEmcalJet.h"
22 #include "AliRhoParameter.h"
24 #include "AliAnalysisUtils.h"
25 #include "AliEmcalParticle.h"
26 #include "AliMCEvent.h"
27 #include "AliGenPythiaEventHeader.h"
28 #include "AliAODMCHeader.h"
29 #include "AliMCEvent.h"
30 #include "AliAnalysisManager.h"
31 #include "AliJetContainer.h"
32 #include "AliCentrality.h"
34 #include "AliAnalysisTaskEmcalDiJetAna.h"
36 ClassImp(AliAnalysisTaskEmcalDiJetAna)
38 //________________________________________________________________________
39 AliAnalysisTaskEmcalDiJetAna::AliAnalysisTaskEmcalDiJetAna() :
40 AliAnalysisTaskEmcalDiJetBase("AliAnalysisTaskEmcalDiJetAna"),
41 fDoMatchFullCharged(kTRUE),
44 fh3PtEtaPhiJetFull(0),
45 fh3PtEtaPhiJetCharged(0),
48 fhnDiJetVarsFullCharged(0),
49 fhnMatchingFullCharged(0),
50 fh3JetPtFullFractionDR(0)
52 // Default constructor.
54 for(Int_t i=0; i<4; i++) {
55 fh3DiJetKtNEFPtAssoc[i] = 0;
56 fCentCorrPtAssocCh[i] = 0;
57 fCentCorrPtAssocFuCh[i] = 0;
58 fAjPtAssocCentCh[i] = 0;
59 fAjPtAssocCentFuCh[i] = 0;
62 SetMakeGeneralHistograms(kTRUE);
65 //________________________________________________________________________
66 AliAnalysisTaskEmcalDiJetAna::AliAnalysisTaskEmcalDiJetAna(const char *name) :
67 AliAnalysisTaskEmcalDiJetBase(name),
68 fDoMatchFullCharged(kTRUE),
71 fh3PtEtaPhiJetFull(0),
72 fh3PtEtaPhiJetCharged(0),
75 fhnDiJetVarsFullCharged(0),
76 fhnMatchingFullCharged(0),
77 fh3JetPtFullFractionDR(0)
79 // Standard constructor.
81 for(Int_t i=0; i<4; i++) {
82 fh3DiJetKtNEFPtAssoc[i] = 0;
83 fCentCorrPtAssocCh[i] = 0;
84 fCentCorrPtAssocFuCh[i] = 0;
85 fAjPtAssocCentCh[i] = 0;
86 fAjPtAssocCentFuCh[i] = 0;
89 SetMakeGeneralHistograms(kTRUE);
92 //________________________________________________________________________
93 AliAnalysisTaskEmcalDiJetAna::~AliAnalysisTaskEmcalDiJetAna()
98 //________________________________________________________________________
99 Bool_t AliAnalysisTaskEmcalDiJetAna::RetrieveEventObjects() {
101 // retrieve event objects
104 if (!AliAnalysisTaskEmcalDiJetBase::RetrieveEventObjects())
110 //________________________________________________________________________
111 void AliAnalysisTaskEmcalDiJetAna::UserCreateOutputObjects()
113 // Create user output.
117 AliAnalysisTaskEmcalDiJetBase::UserCreateOutputObjects();
119 Bool_t oldStatus = TH1::AddDirectoryStatus();
120 TH1::AddDirectory(kFALSE);
122 const Int_t nBinsCent = 100;
123 Double_t minCent = 0.;
124 Double_t maxCent = 100.;
126 const Int_t nBinsRho = 200;
127 Double_t minRho = 0.;
128 Double_t maxRho = 20.;
129 fh2CentRhoCh = new TH2F("fh2CentRhoCh","fh2CentRhoCh;centrality;#rho_{ch}",nBinsCent,minCent,maxCent,nBinsRho,minRho,maxRho);
130 fOutput->Add(fh2CentRhoCh);
131 fh2CentRhoScaled = new TH2F("fh2CentRhoScaled","fh2CentRhoScaled;centrality;s_{EMC}#rho_{ch}",nBinsCent,minCent,maxCent,nBinsRho,minRho,maxRho);
132 fOutput->Add(fh2CentRhoScaled);
134 const Int_t nBinsPt = 150;
135 Double_t minPt = -20.;
136 Double_t maxPt = 130.;
137 const Int_t nBinsEta = 40;
138 Double_t minEta = -1.;
139 Double_t maxEta = 1.;
140 const Int_t nBinsPhi = 18*6;
141 Double_t minPhi = 0.;
142 Double_t maxPhi = TMath::TwoPi();
144 fh3PtEtaPhiJetFull = new TH3F("fh3PtEtaPhiJetFull","fh3PtEtaPhiJetFull;#it{p}_{T}^{jet};#eta;#varphi",nBinsPt,minPt,maxPt,nBinsEta,minEta,maxEta,nBinsPhi,minPhi,maxPhi);
145 fOutput->Add(fh3PtEtaPhiJetFull);
147 fh3PtEtaPhiJetCharged = new TH3F("fh3PtEtaPhiJetCharged","fh3PtEtaPhiJetCharged;#it{p}_{T}^{jet};#eta;#varphi",nBinsPt,minPt,maxPt,nBinsEta,minEta,maxEta,nBinsPhi,minPhi,maxPhi);
148 fOutput->Add(fh3PtEtaPhiJetCharged);
150 const Int_t nBinsSparse0 = 7;
151 const Int_t nBinsPtW = 30;
152 const Int_t nBinsDPhi = 72;
153 const Int_t nBinsKt = 50;
154 const Int_t nBinsDiJetEta = 40;
155 const Int_t nBinsCentr = 5;
156 const Int_t nBinsAj = 50;
157 const Int_t nBins0[nBinsSparse0] = {nBinsPtW,nBinsPtW,nBinsDPhi,nBinsKt,nBinsDiJetEta,nBinsCentr,nBinsAj};
158 //pT1, pT2, deltaPhi, kT
159 const Double_t xmin0[nBinsSparse0] = { minPt, minPt, -0.5*TMath::Pi(), 0.,-1.,0. , 0.};
160 const Double_t xmax0[nBinsSparse0] = { maxPt, maxPt, 1.5*TMath::Pi(), 100., 1.,100., 1.};
162 if(fDoChargedCharged) {
163 fhnDiJetVarsCh = new THnSparseF("fhnDiJetVarsCh",
164 "fhnDiJetVarsCh;#it{p}_{T,1} (GeV/#it{c});#it{p}_{T,2} (GeV/#it{c});#Delta#varphi;#it{k}_{T} = #it{p}_{T,1}sin(#Delta#varphi) (GeV/#it{c});(#eta_{1}+#eta_{2})/2);centrality;#it{A}_{j}",
165 nBinsSparse0,nBins0,xmin0,xmax0);
166 fOutput->Add(fhnDiJetVarsCh);
170 fhnDiJetVarsFullCharged = new THnSparseF("fhnDiJetVarsFullCharged",
171 "fhnDiJetVarsFullCharged;#it{p}_{T,1} (GeV/#it{c});#it{p}_{T,2} (GeV/#it{c});#Delta#varphi;#it{k}_{T} = #it{p}_{T,1}sin(#Delta#varphi) (GeV/#it{c});(#eta_{1}+#eta_{2})/2);centrality;#it{A}_{j}",
172 nBinsSparse0,nBins0,xmin0,xmax0);
173 fOutput->Add(fhnDiJetVarsFullCharged);
177 fhnDiJetVarsFull = new THnSparseF("fhnDiJetVarsFull",
178 "fhnDiJetVarsFull;#it{p}_{T,1} (GeV/#it{c});#it{p}_{T,2} (GeV/#it{c});#Delta#varphi;#it{k}_{T} = #it{p}_{T,1}sin(#Delta#varphi) (GeV/#it{c});(#eta_{1}+#eta_{2})/2);centrality;#it{A}_{j}",
179 nBinsSparse0,nBins0,xmin0,xmax0);
180 fOutput->Add(fhnDiJetVarsFull);
183 for(Int_t i=0; i<4; i++) {
184 TString histoName = Form("fh3DiJetKtNEFPtAssoc_TrigBin%d",i);
185 fh3DiJetKtNEFPtAssoc[i] = new TH3F(histoName.Data(),histoName.Data(),nBinsKt,-100.,100.,100,0.,1.,nBinsPt,minPt,maxPt);
186 fOutput->Add(fh3DiJetKtNEFPtAssoc[i]);
188 histoName = Form("fCentCorrPtAssocCh_TrigBin%d",i);
189 fCentCorrPtAssocCh[i] = new TH3F(histoName.Data(),histoName.Data(),100,0.,100.,100,0.,100.,nBinsPt,minPt,maxPt);
190 fOutput->Add(fCentCorrPtAssocCh[i]);
192 histoName = Form("fCentCorrPtAssocFuCh_TrigBin%d",i);
193 fCentCorrPtAssocFuCh[i] = new TH3F(histoName.Data(),histoName.Data(),100,0.,100.,100,0.,100.,nBinsPt,minPt,maxPt);
194 fOutput->Add(fCentCorrPtAssocFuCh[i]);
196 histoName = Form("fAjPtAssocCentCh_TrigBin%d",i);
197 fAjPtAssocCentCh[i] = new TH3F(histoName.Data(),histoName.Data(),100,0.,1.,nBinsPt,minPt,maxPt,100,0.,100.);
198 fOutput->Add(fAjPtAssocCentCh[i]);
200 histoName = Form("fAjPtAssocCentFuCh_TrigBin%d",i);
201 fAjPtAssocCentFuCh[i] = new TH3F(histoName.Data(),histoName.Data(),100,0.,1.,nBinsPt,minPt,maxPt,100,0.,100.);
202 fOutput->Add(fAjPtAssocCentFuCh[i]);
207 const Int_t nBinsSparseMatch = 7;
208 const Int_t nBinsDPhiMatch = 80;
209 const Int_t nBinsDEtaMatch = 80;
210 const Int_t nBinsDR = 20;
211 const Int_t nBinsFraction = 21;
212 const Int_t nBinsType = 3;
213 const Int_t nBinsMatch[nBinsSparseMatch] = {nBinsPt,nBinsPt,nBinsDPhiMatch,nBinsDEtaMatch,nBinsDR,nBinsFraction,nBinsType};
214 //pTfull, pTch, deltaPhi, deltaEta, deltaR, fraction, jet type (leading,subleading,other)
215 const Double_t xminMatch[nBinsSparseMatch] = { minPt, minPt, -0.5,-0.5, 0.,0. ,0};
216 const Double_t xmaxMatch[nBinsSparseMatch] = { maxPt, maxPt, 0.5, 0.5, 0.5,1.05,3};
217 fhnMatchingFullCharged = new THnSparseF("fhnMatchingFullCharged","fhnMatchingFullCharged;#it{p}_{T,full} (GeV/#it{c});#it{p}_{T,ch} (GeV/#it{c});#Delta#varphi;#Delta#eta;#Delta R;f_{ch};type",
218 nBinsSparseMatch,nBinsMatch,xminMatch,xmaxMatch);
219 fOutput->Add(fhnMatchingFullCharged);
221 fh3JetPtFullFractionDR = new TH3F("fh3JetPtFullFractionDR","fh3JetPtFullFractionDR;#it{p}_{T,full} (GeV/#it{c}); #it{f}_{ch};#Delta R",nBinsPt,minPt,maxPt,nBinsFraction,0.,1.05,nBinsDR,0.,1.);
222 fOutput->Add(fh3JetPtFullFractionDR);
224 // =========== Switch on Sumw2 for all histos ===========
225 for (Int_t i=0; i<fOutput->GetEntries(); ++i) {
226 TH1 *h1 = dynamic_cast<TH1*>(fOutput->At(i));
231 THnSparse *hn = dynamic_cast<THnSparse*>(fOutput->At(i));
238 TH1::AddDirectory(oldStatus);
240 PostData(1, fOutput); // Post data for ALL output slots > 0 here.
243 //________________________________________________________________________
244 Bool_t AliAnalysisTaskEmcalDiJetAna::FillHistograms()
248 fh2CentRhoCh->Fill(fCent,fRhoChVal);
249 fh2CentRhoScaled->Fill(fCent,fRhoFullVal);
252 Int_t nJetsFull = GetNJets(fContainerFull);
253 for(Int_t ij=0; ij<nJetsFull; ij++) {
254 AliEmcalJet *jet = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ij, fContainerFull));
255 if(!jet) continue; //jet not selected
257 Double_t jetPt = GetJetPt(jet,0);
258 fh3PtEtaPhiJetFull->Fill(jetPt,jet->Eta(),jet->Phi());
262 Int_t nJetsCh = GetNJets(fContainerCharged);
263 for(Int_t ij=0; ij<nJetsCh; ij++) {
264 AliEmcalJet *jet = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ij, fContainerCharged));
265 if(!jet) continue; //jet not selected
267 Double_t jetPt = GetJetPt(jet,1);
268 fh3PtEtaPhiJetCharged->Fill(jetPt,jet->Eta(),jet->Phi());
276 //________________________________________________________________________
277 Bool_t AliAnalysisTaskEmcalDiJetAna::Run()
279 // Run analysis code here, if needed. It will be executed before FillHistograms().
281 //Check if event is selected (vertex & pile-up)
285 fHistTrialsSelEvents->Fill(fPtHardBin, fNTrials);
292 fRhoFullVal = GetRhoVal(fContainerFull);
293 fRhoChVal = GetRhoVal(fContainerCharged);
299 // MatchFullAndChargedJets();
300 if(fDoChargedCharged) CorrelateJets(1);
302 if(fDoMatchFullCharged) FillMatchFullChargedHistos(fContainerFull,fContainerCharged);
305 SetChargedFractionIndex();
309 return kTRUE; // If return kFALSE FillHistogram() will NOT be executed.
312 //________________________________________________________________________
313 void AliAnalysisTaskEmcalDiJetAna::CorrelateJets(const Int_t type) {
315 // Correlate jets and fill histos
318 if( fJetCorrelationType==kCorrelateAll )
319 CorrelateAllJets(type);
320 else if( fJetCorrelationType==kCorrelateTwo )
321 CorrelateTwoJets(type);
322 else if( fJetCorrelationType==kCorrelateLS )
323 CorrelateLeadingSubleadingJets(type);
329 //________________________________________________________________________
330 void AliAnalysisTaskEmcalDiJetAna::CorrelateTwoJets(const Int_t type) {
332 // Correlate jets and fill histos
337 if(type==0) { //full-full
338 typet = fContainerFull;
339 typea = fContainerFull;
341 else if(type==1) { //charged-charged
342 typet = fContainerCharged;
343 typea = fContainerCharged;
345 else if(type==2) { //full-charged
346 typet = fContainerFull;
347 typea = fContainerCharged;
350 AliWarning(Form("%s: type %d of dijet correlation not defined!",GetName(),type));
355 Int_t nJetsAssoc = 0;
357 nJetsTrig = GetNJets(fContainerFull);
358 nJetsAssoc = nJetsTrig;
361 nJetsTrig = GetNJets(fContainerCharged);
362 nJetsAssoc = nJetsTrig;
365 nJetsTrig = GetNJets(fContainerFull);
366 nJetsAssoc = GetNJets(fContainerCharged);
369 for(Int_t ijt=0; ijt<nJetsTrig; ijt++) {
371 AliEmcalJet *jetTrig = NULL;
373 jetTrig = static_cast<AliEmcalJet*>(GetJetFromArray(ijt, typet));
374 if(TMath::Abs(jetTrig->Eta())>0.5)
378 jetTrig = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ijt, typet));
382 continue; //jet not selected
384 Double_t jetTrigPt = GetJetPt(jetTrig,typet);
386 if(jetTrigPt<fPtMinTriggerJet)
389 AliEmcalJet *jetAssoc = GetLeadingAssociatedJet(typea,jetTrig);
393 if(type==0 || type==1) {
394 if(GetJetPt(jetAssoc,typea)>jetTrigPt)
398 FillDiJetHistos(jetTrig,jetAssoc, type);
405 //________________________________________________________________________
406 AliEmcalJet* AliAnalysisTaskEmcalDiJetAna::GetLeadingJet(const Int_t type) {
408 //Get associated jet which is the leading jet in the opposite hemisphere
411 if(type==0) //full-full
412 cont = fContainerFull;
413 else if(type==1) //charged-charged
414 cont = fContainerCharged;
415 else if(type==2) //full-charged
416 cont = fContainerFull;
418 Int_t nJets = GetNJets(cont);
419 Double_t ptLead = -999;
421 for(Int_t ij=0; ij<nJets; ij++) {
423 AliEmcalJet *jet = NULL;
425 jet = static_cast<AliEmcalJet*>(GetJetFromArray(ij, cont));
426 if(TMath::Abs(jet->Eta())>0.5)
430 jet = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ij, cont));
435 Double_t jetPt = GetJetPt(jet,cont);
444 AliEmcalJet *jetLead = static_cast<AliEmcalJet*>(GetJetFromArray(iJetLead, cont));
450 //________________________________________________________________________
451 AliEmcalJet* AliAnalysisTaskEmcalDiJetAna::GetLeadingAssociatedJet(const Int_t type, AliEmcalJet *jetTrig) {
453 //Get associated jet which is the leading jet in the opposite hemisphere
456 if(type==0) //full-full
457 typea = fContainerFull;
458 else if(type==1) //charged-charged
459 typea = fContainerCharged;
460 else if(type==2) //full-charged
461 typea = fContainerCharged;
463 AliEmcalJet *jetAssocLead = GetLeadingJetOppositeHemisphere(type, typea, jetTrig);
469 //________________________________________________________________________
470 void AliAnalysisTaskEmcalDiJetAna::CorrelateAllJets(const Int_t type) {
472 // Correlate jets and fill histos
477 if(type==0) { //full-full
478 typet = fContainerFull;
479 typea = fContainerFull;
481 else if(type==1) { //charged-charged
482 typet = fContainerCharged;
483 typea = fContainerCharged;
485 else if(type==2) { //full-charged
486 typet = fContainerFull;
487 typea = fContainerCharged;
490 AliWarning(Form("%s: type %d of dijet correlation not defined!",GetName(),type));
495 Int_t nJetsAssoc = 0;
497 nJetsTrig = GetNJets(fContainerFull);
498 nJetsAssoc = nJetsTrig;
501 nJetsTrig = GetNJets(fContainerCharged);
502 nJetsAssoc = nJetsTrig;
505 nJetsTrig = GetNJets(fContainerFull);
506 nJetsAssoc = GetNJets(fContainerCharged);
509 for(Int_t ijt=0; ijt<nJetsTrig; ijt++) {
511 AliEmcalJet *jetTrig = NULL;
513 jetTrig = static_cast<AliEmcalJet*>(GetJetFromArray(ijt, typet));
514 if(TMath::Abs(jetTrig->Eta())>0.5)
518 jetTrig = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ijt, typet));
522 continue; //jet not selected
524 Double_t jetTrigPt = GetJetPt(jetTrig,typet);
526 if(jetTrigPt<fPtMinTriggerJet)
529 for(Int_t ija=0; ija<nJetsAssoc; ija++) {
530 if(IsSameJet(ijt,ija,type)) continue;
532 AliEmcalJet *jetAssoc = NULL;
534 jetAssoc = static_cast<AliEmcalJet*>(GetJetFromArray(ija, typea));
535 if(TMath::Abs(jetAssoc->Eta())>0.5)
539 jetAssoc = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ija, typea));
544 Double_t jetAssocPt = GetJetPt(jetAssoc,typea);
546 if(jetTrigPt>jetAssocPt)
547 FillDiJetHistos(jetTrig,jetAssoc, type);
549 } // associate jet loop
554 //________________________________________________________________________
555 void AliAnalysisTaskEmcalDiJetAna::CorrelateLeadingSubleadingJets(const Int_t type) {
557 // Correlate leading jet in event with leading jet in opposite hemisphere
562 if(type==0) { //full-full
563 typet = fContainerFull;
564 typea = fContainerFull;
566 else if(type==1) { //charged-charged
567 typet = fContainerCharged;
568 typea = fContainerCharged;
570 else if(type==2) { //full-charged
571 typet = fContainerFull;
572 typea = fContainerCharged;
575 AliWarning(Form("%s: type %d of dijet correlation not defined!",GetName(),type));
579 AliEmcalJet *jetTrig = GetLeadingJet(type);
583 Double_t jetTrigPt = GetJetPt(jetTrig,typet);
585 if(jetTrigPt<fPtMinTriggerJet)
588 AliEmcalJet *jetAssoc = GetLeadingAssociatedJet(typea,jetTrig);
593 FillDiJetHistos(jetTrig,jetAssoc, type);
598 //________________________________________________________________________
599 void AliAnalysisTaskEmcalDiJetAna::FillDiJetHistos(const AliEmcalJet *jet1, const AliEmcalJet *jet2, const Int_t mode) {
602 // mode: full vs full = 0
603 // charged vs charged = 1
604 // full vs charged = 2
622 AliWarning(Form("%s: mode %d of dijet correlation not defined!",GetName(),mode));
626 Double_t jetTrigPt = GetJetPt(jet1,typet);
627 Double_t jetAssocPt = GetJetPt(jet2,typea);
629 Double_t deltaPhi = GetDeltaPhi(jet1->Phi(),jet2->Phi());
630 if(fDebug>10) Printf("deltaPhi:%.2f",deltaPhi);
632 Double_t kT = TMath::Abs(jetTrigPt*TMath::Sin(deltaPhi));
634 Double_t dijetEta = (jet1->Eta()+jet2->Eta())/2.;
636 Double_t aj = (jetTrigPt-jetAssocPt)/(jetTrigPt+jetAssocPt);
638 Double_t diJetVars[7] = {jetTrigPt,jetAssocPt,deltaPhi,kT,dijetEta,fCent,aj};
641 fhnDiJetVarsFull->Fill(diJetVars);
643 fhnDiJetVarsCh->Fill(diJetVars);
645 fhnDiJetVarsFullCharged->Fill(diJetVars);
647 Double_t dPhiMin = TMath::Pi()-0.9;
648 Double_t dPhiMax = TMath::Pi()+0.9;
649 Int_t trigBin = GetPtTriggerBin(jetTrigPt);
651 if(trigBin>-1 && trigBin<4) {
652 if(deltaPhi>dPhiMin && deltaPhi<dPhiMax)
653 fh3DiJetKtNEFPtAssoc[trigBin]->Fill(kT, jet1->NEF(), jetAssocPt);
657 //Fill centrality correlation histos in case a dijet is present in acceptance
658 Double_t centZNA = -1.;
659 AliCentrality *aliCent = InputEvent()->GetCentrality();
661 centZNA = aliCent->GetCentralityPercentile("ZNA");
663 if(trigBin>-1 && trigBin<4) {
664 if(deltaPhi>dPhiMin && deltaPhi<dPhiMax) {
666 fCentCorrPtAssocCh[trigBin]->Fill(fCent,centZNA,jetAssocPt);
667 fAjPtAssocCentCh[trigBin]->Fill(aj,jetAssocPt,fCent);
670 fCentCorrPtAssocFuCh[trigBin]->Fill(fCent,centZNA,jetAssocPt);
671 fAjPtAssocCentFuCh[trigBin]->Fill(aj,jetAssocPt,fCent);
678 //________________________________________________________________________
679 Int_t AliAnalysisTaskEmcalDiJetAna::GetPtTriggerBin(Double_t pt) {
684 else if(pt>=40 && pt<60)
686 else if(pt>=60 && pt<80)
688 else if(pt>=80 && pt<100)
695 //________________________________________________________________________
696 void AliAnalysisTaskEmcalDiJetAna::FillMatchFullChargedHistos(Int_t cFull,Int_t cCharged) {
698 // Match full to charged jets and fill histo
701 Int_t match = MatchFullAndChargedJets(cFull,cCharged);
703 if(fDebug>1) AliWarning(Form("%s: matching failed",GetName()));
707 for(int ig = 0;ig < GetNJets(cFull);++ig){
708 AliEmcalJet *jetFull = static_cast<AliEmcalJet*>(GetAcceptJetFromArray(ig, cFull));
709 if(!jetFull) continue;
711 AliEmcalJet *jetCh = jetFull->ClosestJet();
714 Double_t shFraction = GetFractionSharedPt(jetFull,jetCh);
715 if(fDebug>10) Printf("shared charged pT:%.2f",shFraction);
716 Double_t matchVars[7] = {
719 GetDeltaPhi(jetFull->Phi(),jetCh->Phi()),
720 jetFull->Eta()-jetCh->Eta(),
721 GetDeltaR(jetFull,jetCh),
722 shFraction,TMath::Min((Float_t)ig+0.5,2.5)
724 fhnMatchingFullCharged->Fill(matchVars);
726 }//loop over full jets
731 //________________________________________________________________________
732 Int_t AliAnalysisTaskEmcalDiJetAna::MatchFullAndChargedJets(Int_t cFull, Int_t cCharged) {
734 // Match charged jets to full jets
737 if(GetNJets(cFull)<1) {
738 if(fDebug>1) AliInfo(Form("%s: no full jets: %d", GetName(),GetNJets(cFull)));
742 if(GetNJets(cCharged)<1) {
743 if(fDebug>1) AliInfo(Form("%s: no charged jets: %d", GetName(),GetNJets(cCharged)));
747 TClonesArray *cJetsFull = GetJetArray(cFull);
748 TClonesArray *cJetsCharged = GetJetArray(cCharged);
751 if(fDebug>1) AliInfo(Form("%s: no full jet array",GetName()));
756 if(fDebug>1) AliInfo(Form("%s: no charged jet array",GetName()));
762 MatchJetsGeo(cFull, cCharged, fDebug);
765 if(fDebug>1) AliInfo(Form("%s: Matching already done before",GetName()));
771 //_______________________________________________________________________
772 void AliAnalysisTaskEmcalDiJetAna::Terminate(Option_t *)
774 // Called once at the end of the analysis.