]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PWGHF/hfe/AliHFEspectrum.h
Add components for jet analysis on mc and rec jets
[u/mrichter/AliRoot.git] / PWGHF / hfe / AliHFEspectrum.h
index a2261053041a6964397d7803097cb206b423baed..f3b18af1e2c93344acd751d1d497d66169bf3dfe 100644 (file)
@@ -76,6 +76,7 @@ class AliHFEspectrum : public TNamed{
     AliCFDataGrid *CorrectParametrizedEfficiency(AliCFDataGrid* const bgsubpectrum = 0x0);
    
     TList *Unfold(AliCFDataGrid* const bgsubpectrum = 0x0);
+    void UnfoldBG(AliCFDataGrid* const bgsubpectrum);
     AliCFDataGrid *CorrectForEfficiency(AliCFDataGrid* const bgsubpectrum = 0x0);
    
     TGraphErrors *Normalize(THnSparse * const spectrum,Int_t i = 0) const;
@@ -88,6 +89,7 @@ class AliHFEspectrum : public TNamed{
     void SetContainer(AliCFContainer *cont, AliHFEspectrum::CFContainer_t type);
     void SetEfficiencyFunction(TF1 *efficiencyFunction) { fEfficiencyFunction = efficiencyFunction; };
     void SetPbPbAnalysis(Bool_t isPbPb = kFALSE) { fBeamType=(Char_t) isPbPb; };
+    void SetEtaSyst(Bool_t etaSyst = kTRUE) { fEtaSyst = etaSyst; };
 
     void SetParameterizedEff(AliCFContainer *container, AliCFContainer *containermb, AliCFContainer *containeresd, AliCFContainer *containeresdmb, Int_t *dimensions);
     
@@ -104,6 +106,8 @@ class AliHFEspectrum : public TNamed{
     void SetEtaRange(Double_t etamin, Double_t etamax) { fEtaRange[0] = etamin; fEtaRange[1] = etamax; fEtaSelected = kTRUE; }
     void SetUnSetCorrelatedErrors(Bool_t unsetcorrelatederrors) {fUnSetCorrelatedErrors = unsetcorrelatederrors;};
     void SetSmoothing(Bool_t setSmoothing) {fSetSmoothing = setSmoothing;};
+    void SetTestOneBinCentrality(Double_t centralitymin, Double_t centralitymax) { fTestCentralityLow = centralitymin; fTestCentralityHigh = centralitymax;}
+    void SetFillMoreCorrelationMatrix(Bool_t fillMoreCorrelationMatrix) { fFillMoreCorrelationMatrix = fillMoreCorrelationMatrix;}
 
     void SetNCentralityBinAtTheEnd(Int_t nCentralityBinAtTheEnd) {fNCentralityBinAtTheEnd = nCentralityBinAtTheEnd; };
     void SetLowHighBoundaryCentralityBinAtTheEnd(Int_t low, Int_t high, Int_t i) { fLowBoundaryCentralityBinAtTheEnd[i] = low; fHighBoundaryCentralityBinAtTheEnd[i] = high;};
@@ -118,10 +122,12 @@ class AliHFEspectrum : public TNamed{
 
     void SetStepGuessedUnfolding(Int_t stepGuessedUnfolding) { fStepGuessedUnfolding = stepGuessedUnfolding; };
     void SetNumberOfIteration(Int_t numberOfIteration) { fNumberOfIterations = numberOfIteration; };
+    void SetUnfoldingRandomIterations(Int_t niter) { fNRandomIter = niter; }
     
     void SetDumpToFile(Bool_t dumpToFile) { fDumpToFile=dumpToFile; }; 
   
     void SetDebugLevel(Int_t debugLevel, Bool_t writeToFile = kFALSE) { fDebugLevel = debugLevel; fWriteToFile = writeToFile; };
+    void SetUnfoldBG() { fUnfoldBG = kTRUE; };
 
 
     AliCFDataGrid* GetRawBspectra2ndMethod();
@@ -129,7 +135,7 @@ class AliHFEspectrum : public TNamed{
     AliCFDataGrid* GetConversionBackground();
     AliCFDataGrid* GetNonHFEBackground();
     THnSparse* GetCharmWeights();
-    THnSparse* GetBeautyIPEff();
+    THnSparse* GetBeautyIPEff(Bool_t isMCpt);
     THnSparse* GetPIDxIPEff(Int_t source);
     void CalculateNonHFEsyst(Int_t centrality = 0);
 
@@ -142,8 +148,8 @@ class AliHFEspectrum : public TNamed{
   protected:
        
     AliCFContainer *GetContainer(AliHFEspectrum::CFContainer_t contt);
-    AliCFContainer *GetSlicedContainer(AliCFContainer *cont, Int_t ndim, Int_t *dimensions,Int_t source=-1,Chargetype_t charge=kAllCharge,Int_t centrality=-1);
-    THnSparseF *GetSlicedCorrelation(THnSparseF *correlationmatrix,Int_t nDim, Int_t *dimensions) const;
+    AliCFContainer *GetSlicedContainer(AliCFContainer *cont, Int_t ndim, Int_t *dimensions,Int_t source=-1,Chargetype_t charge=kAllCharge,Int_t centralitylow=-1, Int_t centralityhigh=-1);
+    THnSparseF *GetSlicedCorrelation(THnSparseF *correlationmatrix,Int_t nDim, Int_t *dimensions,Int_t centralitylow=-1, Int_t centralityhigh=-1) const;
     TObject* GetSpectrum(const AliCFContainer * const c, Int_t step);
     TObject* GetEfficiency(const AliCFContainer * const c, Int_t step, Int_t step0);
  
@@ -166,6 +172,7 @@ class AliHFEspectrum : public TNamed{
     TF1 *fEfficiencyesdTOFPIDD[kCentrality];    // TOF PID efficiency parameterized
     TF1 *fEfficiencyIPCharmD[kCentrality];      // IP efficiency parameterized for charm
     TF1 *fEfficiencyIPBeautyD[kCentrality];     // IP efficiency parameterized for beauty 
+    TF1 *fEfficiencyIPBeautyesdD[kCentrality];  // IP efficiency parameterized for beauty for esd
     TF1 *fEfficiencyIPConversionD[kCentrality]; // IP efficiency parameterized for conversion
     TF1 *fEfficiencyIPNonhfeD[kCentrality];     // IP efficiency parameterized for nonhfe 
 
@@ -201,6 +208,7 @@ class AliHFEspectrum : public TNamed{
     Int_t fStepAfterCutsV0;       // After cuts V0
     Int_t fStepGuessedUnfolding;  // Step for first guessed unfolding
     Int_t fNumberOfIterations;    // Number of iterations
+    Int_t fNRandomIter;           // Number of random iterations
     Chargetype_t fChargeChoosen;         // Select positive or negative electrons
 
     Double_t fEtaRange[2];        // Eta range 
@@ -209,10 +217,14 @@ class AliHFEspectrum : public TNamed{
     Int_t fNCentralityBinAtTheEnd;// Number of centrality class at the end
     Int_t fLowBoundaryCentralityBinAtTheEnd[20];  // Boundary of the bins
     Int_t fHighBoundaryCentralityBinAtTheEnd[20];  // Boundary of the bins
+    Int_t fTestCentralityLow;                      // To test one bin in centrality only
+    Int_t fTestCentralityHigh;                     // To test one bin in centrality only
+    Bool_t fFillMoreCorrelationMatrix;             // For low stats to have reasonable errors
 
     THnSparseF *fHadronEffbyIPcut;// container for hadron efficiency by IP cut
     TH1D *fEfficiencyCharmSigD[kCentrality]; // charm IP cut eff from signal enhanced MC
     TH1D *fEfficiencyBeautySigD[kCentrality]; // beauty IP cut eff from signal enhanced MC
+    TH1D *fEfficiencyBeautySigesdD[kCentrality]; // beauty IP cut eff from signal enhanced MC for esd
     TH1D *fConversionEff[kCentrality];     // conversion IP cut eff
     TH1D *fNonHFEEff[kCentrality];         // nonhfe IP cut eff
     TH1D *fCharmEff[kCentrality];          // charm IP cut eff
@@ -222,10 +234,12 @@ class AliHFEspectrum : public TNamed{
     TH1D *fBSpectrum2ndMethod;             // beauty spectrum for 2nd method
     const char *fkBeauty2ndMethodfilename;      // name of file, which contains beauty spectrum for 2ndmethod
     Char_t fBeamType;             // beamtype; default -1; pp =0; PbPb=1
+    Bool_t fEtaSyst;              // pp 2.76 TeV (= kTRUE) or 7 TeV (= kFALSE)
 
 
     Int_t fDebugLevel;            // Debug Level
     Bool_t fWriteToFile;           // Write plots to eps files
+    Bool_t fUnfoldBG;             // flag to unfold backgroud
 
     ClassDef(AliHFEspectrum, 1) 
 };