fix warnings
[u/mrichter/AliRoot.git] / PWG0 / dNdEta / AlidNdEtaCorrection.h
CommitLineData
55e05544 1/* $Id$ */
2
3#ifndef ALIDNDETACORRECTION_H
4#define ALIDNDETACORRECTION_H
5
6
7// ------------------------------------------------------
8//
9// Class to handle corrections for dN/dEta measurements
10//
11// ------------------------------------------------------
12//
13// TODO:
55e05544 14// - add functionality to set the bin sizes
1afae8ff 15// - update MERge function
45e97e28 16//
55e05544 17
7ca4655f 18#include <TCollection.h>
55e05544 19#include <TNamed.h>
770a1f1d 20#include "AliPWG0Helper.h"
55e05544 21
74fd10b3 22class AliCorrection;
3dfa46a4 23class TH1;
55e05544 24
25class AlidNdEtaCorrection : public TNamed
26{
55e05544 27public:
74fd10b3 28 enum CorrectionType {
0448e811 29 kNone = 0,
74fd10b3 30 kTrack2Particle, // measured events
31 kVertexReco, // MB sample
32 kINEL,
33 kNSD,
34 kND
35 };
36
8b3563f4 37 AlidNdEtaCorrection();
770a1f1d 38 AlidNdEtaCorrection(const Char_t* name, const Char_t* title, AliPWG0Helper::AnalysisMode analysis = AliPWG0Helper::kTPC);
55e05544 39
74fd10b3 40 virtual Long64_t Merge(TCollection* list);
41
38233af1 42 ~AlidNdEtaCorrection();
43
74fd10b3 44 void FillMCParticle(Float_t vtx, Float_t eta, Float_t pt, Bool_t trigger, Bool_t vertex, Int_t processType);
45 void FillTrackedParticle(Float_t vtx, Float_t eta, Float_t pt);
46 void FillEvent(Float_t vtx, Float_t n, Bool_t trigger, Bool_t vertex, Int_t processType);
55e05544 47
45e97e28 48 void Finish();
49
74fd10b3 50 AliCorrection* GetTrack2ParticleCorrection() {return fTrack2ParticleCorrection;}
51 AliCorrection* GetVertexRecoCorrection() {return fVertexRecoCorrection;}
52 AliCorrection* GetTriggerBiasCorrectionINEL() {return fTriggerBiasCorrectionMBToINEL;}
53 AliCorrection* GetTriggerBiasCorrectionNSD() {return fTriggerBiasCorrectionMBToNSD;}
54 AliCorrection* GetTriggerBiasCorrectionND() {return fTriggerBiasCorrectionMBToND;}
0448e811 55 AliCorrection* GetCorrection(CorrectionType correctionType);
55e05544 56
2e88424e 57 void Reset(void);
58 void Add(AlidNdEtaCorrection* aCorrectionsToAdd, Float_t c=1);
59
55e05544 60 void SaveHistograms();
74fd10b3 61 Bool_t LoadHistograms(const Char_t* dir = 0);
2e88424e 62 void DrawHistograms();
dd367a14 63 void DrawOverview(const char* canvasName = 0);
847489f7 64
c17301f3 65 Float_t GetMeasuredFraction(CorrectionType correctionType, Float_t ptCutOff, Float_t eta = -100, Int_t vertexBegin = -1, Int_t vertexEnd = -1, Bool_t debug = kFALSE);
3dfa46a4 66 TH1* GetMeasuredEventFraction(CorrectionType correctionType, Int_t multCut);
8b3563f4 67
0fc41645 68 void ReduceInformation();
0ab29cfa 69
45e97e28 70protected:
74fd10b3 71 AliCorrection* fTrack2ParticleCorrection; //-> handles the track-to-particle correction (only track level (vtx_z, eta, pt))
72 AliCorrection* fVertexRecoCorrection; //-> handles the vertex reconstruction efficiency, (n, vtx_z)
73 AliCorrection* fTriggerBiasCorrectionMBToINEL; //-> handles the trigger bias MB->INEL, function of n and vtx_z
74 AliCorrection* fTriggerBiasCorrectionMBToNSD; //-> handles the trigger bias MB->NSD, function of n and vtx_z
75 AliCorrection* fTriggerBiasCorrectionMBToND; //-> handles the trigger bias MB->ND, function of n and vtx_z
55e05544 76
61385583 77private:
78 AlidNdEtaCorrection(const AlidNdEtaCorrection&);
79 AlidNdEtaCorrection& operator=(const AlidNdEtaCorrection&);
80
8b3563f4 81 ClassDef(AlidNdEtaCorrection, 1)
55e05544 82};
83
84#endif