]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PWGJE/EMCALJetTasks/AliHadCorrTask.h
Merge branch 'master' of https://git.cern.ch/reps/AliRoot
[u/mrichter/AliRoot.git] / PWGJE / EMCALJetTasks / AliHadCorrTask.h
index dee7140f74dd4d8eb4a1390f0faae752664342cf..db7d0389c05ecb0e7b2b2be196420c009dafe1cb 100644 (file)
@@ -5,8 +5,8 @@
 
 class TClonesArray;
 class TList;
-class TH1F;
-class TH2F;
+class TH1;
+class TH2;
 class AliEmcalParticle;
 class TString;
 
@@ -27,47 +27,62 @@ class AliHadCorrTask : public AliAnalysisTaskEmcal {
   void                   SetOutClusName(const char *n)           { fOutCaloName    = n    ; }
   void                   SetPhiMatch(Double_t phi)               { fPhiMatch       = phi  ; }
   void                   SetTrackClus(Int_t c)                   { fDoTrackClus    = c    ; }
+  void                   SetDoExact(Bool_t d)                    { fDoExact        = d    ; }
 
  protected:
   Double_t               ApplyHadCorrOneTrack(AliEmcalParticle *emccluster, Double_t hadCorr);
   Double_t               ApplyHadCorrAllTracks(AliEmcalParticle *emccluster, Double_t hadCorr);
-  void                   DoMatchedTracksLoop(AliEmcalParticle *emccluster, Double_t &totalTrkP, Int_t &Nmatches);
+  void                   DoMatchedTracksLoop(AliEmcalParticle *emccluster, Double_t &totalTrkP, Int_t &Nmatches, Double_t &trkPMCfrac, Int_t &NMCmatches);
   void                   DoTrackLoop();
   Double_t               GetEtaSigma(Int_t pbin)                   const;
-  Int_t                  GetMomBin(Double_t pt)                    const;
+  UInt_t                 GetMomBin(Double_t pt)                    const;
   Double_t               GetPhiMean(Int_t pbin, Int_t centbin)     const;
   Double_t               GetPhiSigma(Int_t pbin, Int_t centbin)    const;
-  virtual Bool_t         Run()                                          ;
-  virtual void           ExecOnce()                                     ;
+  Bool_t                 Run()                                          ;
+  void                   ExecOnce()                                     ;
 
+  // Task configuration
   TString                fOutCaloName;               // name of output clusters
   Double_t               fPhiMatch;                  // phi match value (pp=0.050)
   Double_t               fEtaMatch;                  // eta match value (pp=0.025)
   Int_t                  fDoTrackClus;               // loop over tracks first
   Double_t               fHadCorr;                   // hadronic correction (fraction)
   Double_t               fEexclCell;                 // energy/cell that we cannot subtract from the clusters
+  Bool_t                 fDoExact;                   // do exact correction (embedding only) 
+
+  // Service fields (non-streamed)
   Bool_t                 fEsdMode;                   //!ESD/AOD mode
   TClonesArray          *fOutClusters;               //!output cluster collection
-  TH2F                  *fHistMatchEtaPhi[8][9][2];  //!output histograms
-  TH2F                  *fHistMatchEvsP[4];          //!output histograms
-  TH2F                  *fHistNMatchEnergy[4];       //!output histograms
-  TH2F                  *fHistNCellsEnergy[4][4];    //!output histograms
-  TH2F                  *fHistMatchdRvsEP[4];        //!output histograms
-  TH1F                  *fHistNclusvsCent;           //!output histograms
-  TH1F                  *fHistNclusMatchvsCent;      //!output histograms
-  TH1F                  *fHistEbefore;               //!output histograms
-  TH1F                  *fHistEafter;                //!output histograms
-  TH2F                  *fHistEoPCent;               //!output histograms
-  TH2F                  *fHistNMatchCent;            //!output histograms
-  TH2F                  *fHistNClusMatchCent;        //!output histograms
-  TH1F                  *fHistEsubPch[8];            //!output histograms
-  TH2F                  *fHistEsubPchRat[8];         //!output histograms
-  TH2F                  *fHistEsubPchRatAll[8];         //!output histograms
+
+  // QA plots
+  TH2                   *fHistMatchEtaPhi[8][9][2];  //!deta vs. dphi of matched cluster-track pairs
+  TH2                   *fHistMatchEtaPhiAll;        //!deta vs. dphi of matched cluster-track pairs
+  TH2                   *fHistMatchEtaPhiAllTr;      //!deta vs. dphi of all cluster-track pairs (tr loop)
+  TH2                   *fHistMatchEtaPhiAllCl;      //!deta vs. dphi of all cluster-track pairs (cl loop)
+  TH2                   *fHistMatchEvsP[4];          //!cluster energy vs. track momentum of matched pairs
+  TH2                   *fHistNMatchEnergy[4];       //!n matches vs. cluster energy
+  TH2                   *fHistNCellsEnergy[4][4];    //!n cells vs. cluster energy
+  TH2                   *fHistMatchdRvsEP[4];        //!matching distance vs. E/P
+  TH1                   *fHistNclusvsCent;           //!n clusters vs. centrality
+  TH1                   *fHistNclusMatchvsCent;      //!n clusters matched to some track vs. centrality
+  TH1                   *fHistEbefore;               //!average energy of clusters before correction vs. centrality
+  TH1                   *fHistEafter;                //!average energy of clusters after correction vs. centrality
+  TH2                   *fHistEoPCent;               //!E/P vs. centrality
+  TH2                   *fHistNMatchCent;            //!n matches vs. centraity
+  TH2                   *fHistNClusMatchCent;        //!n clusters macthed to some track (tracks allowed to match more than one cluster)
+  TH1                   *fHistEsubPch[8];            //!Esub vs. total momentum of matched tracks (only 1 match)
+  TH2                   *fHistEsubPchRat[8];         //!Esub/momentum of matched tracks vs. total momentum of matched tracks (only 1 match)
+  TH2                   *fHistEsubPchRatAll[8];      //!Esub/momentum of matched tracks vs. total momentum of matched tracks (all number of matches)
+  TH2                   *fHistEmbTrackMatchesOversub[4];    //!Over-subtracted energy / cluster energy with embedded track matches (non-embedded matches < 5%)
+  TH2                   *fHistNonEmbTrackMatchesOversub[4]; //!Over-subtracted energy / cluster energy with non-embedded track matches (embedded matches < 5%)
+  TH2                   *fHistOversubMCClusters[4];         //!Over-subtracted energy / cluster energy (cluster MC energy fraction > 95%)
+  TH2                   *fHistOversubNonMCClusters[4];      //!Over-subtracted energy / cluster energy (cluster MC energy fraction < 5%)
+  TH2                   *fHistOversub[4];                   //!Over-subtracted energy / cluster energy
 
  private:
   AliHadCorrTask(const AliHadCorrTask&);            // not implemented
   AliHadCorrTask &operator=(const AliHadCorrTask&); // not implemented
 
-  ClassDef(AliHadCorrTask, 11) // Hadronic correction task
+  ClassDef(AliHadCorrTask, 14) // Hadronic correction task
 };
 #endif