major dielectron update (included also the data and plotting macros for paper)
[u/mrichter/AliRoot.git] / PWG3 / dielectron / AliDielectronCF.h
CommitLineData
b2a297fa 1#ifndef ALIDIELECTRONCF_H
2#define ALIDIELECTRONCF_H
3/* Copyright(c) 1998-2009, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6//#############################################################
7//# #
8//# Class AliDielectronCF #
9//# Dielectron Correction Framework Manager #
10//# #
11//# Authors: #
12//# Anton Andronic, GSI / A.Andronic@gsi.de #
13//# Ionut C. Arsene, GSI / I.C.Arsene@gsi.de #
14//# Julian Book, Uni Ffm / Julian.Book@cern.ch #
15//# Frederick Kramer, Uni Ffm, / Frederick.Kramer@cern.ch #
16//# Magnus Mager, CERN / Magnus.Mager@cern.ch #
17//# WooJin J. Park, GSI / W.J.Park@gsi.de #
18//# Jens Wiechula, Uni HD / Jens.Wiechula@cern.ch #
19//# #
20//#############################################################
21
22
23
24#include <TNamed.h>
61d106d3 25#include <TVectorDfwd.h>
b2a297fa 26#include "AliDielectronVarManager.h"
27
28class AliAnalysisCuts;
29class AliAnalysisFilter;
30class AliCFContainer;
6551594b 31class AliDielectronPair;
61d106d3 32class TObjArray;
b2a297fa 33
34class AliDielectronCF : public TNamed {
35public:
36 enum {kNmaxAddSteps=50};
37
38 AliDielectronCF();
39 AliDielectronCF(const char* name, const char* title);
40 virtual ~AliDielectronCF();
41
e123f993 42 void SetStepForMCtruth(Bool_t steps=kTRUE) { fStepForMCtruth=steps; }
ba15fdfb 43 Bool_t GetStepForMCtruth() const { return fStepForMCtruth; }
e123f993 44 void SetStepForNoCutsMCmotherPid(Bool_t steps=kTRUE) { fStepForNoCutsMCmotherPid=steps; }
45 void SetStepForAfterAllCuts(Bool_t steps=kTRUE) { fStepForAfterAllCuts=steps; }
554e40f8 46 void SetStepForPreFilter(Bool_t steps=kTRUE) { fStepForPreFilter=steps; }
e123f993 47 void SetStepsForEachCut(Bool_t steps=kTRUE) { fStepsForEachCut=steps; }
48 void SetStepsForCutsIncreasing(Bool_t steps=kTRUE) { fStepsForCutsIncreasing=steps; }
572b0139 49 void SetStepsForSignal(Bool_t steps=kTRUE) { fStepsForSignal=steps; }
50 void SetStepsForBackground(Bool_t steps=kTRUE) { fStepsForBackground=steps; }
b2a297fa 51
52 void SetPdgMother(Int_t pdg) { fPdgMother=pdg; }
ba15fdfb 53 void SetSignalsMC(TObjArray* array) {fSignalsMC = array;}
b2a297fa 54
55 void AddStepMask(UInt_t mask) { fStepMasks[fNStepMasks++]=mask; }
56
3505bfad 57 void AddVariable(AliDielectronVarManager::ValueTypes type, Int_t nbins,
58 Double_t min, Double_t max, Bool_t leg=kFALSE, Bool_t log=kFALSE);
59 void AddVariable(AliDielectronVarManager::ValueTypes type, const char* binLimitStr, Bool_t leg=kFALSE);
60 void AddVariable(AliDielectronVarManager::ValueTypes type, TVectorD *binLimits, Bool_t leg=kFALSE);
61d106d3 61
b2a297fa 62 void InitialiseContainer(const AliAnalysisFilter& filter);
63
6551594b 64// void Fill(UInt_t mask, const TObject *particle);
65 void Fill(UInt_t mask, const AliDielectronPair *particle);
b2a297fa 66 void FillMC(const TObject *particle);
ba15fdfb 67 void FillMC(Int_t label1, Int_t label2, Int_t nSignal);
68
b2a297fa 69 AliCFContainer* GetContainer() const { return fCfContainer; }
70
6551594b 71private:
b2a297fa 72 UInt_t fVariables[AliDielectronVarManager::kNMaxValues]; //configured variables
6551594b 73 UInt_t fVariablesLeg[AliDielectronVarManager::kNMaxValues]; //configured variables for the legs
b2a297fa 74
75 Int_t fNSteps; // number of selection steps
6551594b 76
b2a297fa 77 Int_t fNVars; // number of variables
3505bfad 78 TObjArray *fVarBinLimits; // array of bin limits
79
80 Int_t fNVarsLeg; // number of variables for the legs
81 TObjArray *fVarBinLimitsLeg; // array of bin limits of the legs
6551594b 82
83 Int_t fNCuts; // Number of cuts in the filter concerned
b2a297fa 84
572b0139 85 Double_t *fValues; //! Value array for filling the container
6551594b 86
e123f993 87 Bool_t fStepForMCtruth; //create a step for the MC truth
88 Bool_t fStepForNoCutsMCmotherPid; //create a step for before cuts, but with MC truth of the mother
89 Bool_t fStepForAfterAllCuts; //create a step for before cuts, but with MC truth of the mother
554e40f8 90 Bool_t fStepForPreFilter; //create a step after PreFilter application
e123f993 91 Bool_t fStepsForEachCut; //create steps for each cut?
92 Bool_t fStepsForCutsIncreasing; //create steps for increasing cut combinatons?
93 //e.g. cut1&cut2, cut1&cut2&cut3 ...
572b0139 94 Bool_t fStepsForSignal; //steps for pure signal
95 Bool_t fStepsForBackground; //steps for pure background
96
b2a297fa 97 UInt_t fStepMasks[kNmaxAddSteps]; //steps for additional cut combinatons
98 UInt_t fNStepMasks; //number of configured step masks
99
100 Int_t fPdgMother; //Pdg code of MCtruth validation
ba15fdfb 101 TObjArray* fSignalsMC; //! array of MC signals to be studied
b2a297fa 102 AliCFContainer* fCfContainer; //the CF container
572b0139 103
104 Bool_t fHasMC; //if MC info is available
105 Int_t fNAddSteps; //number of additional MC related steps per cut step
3505bfad 106
107 TVectorD* MakeLogBinning(Int_t nbinsX, Double_t xmin, Double_t xmax) const;
108 TVectorD* MakeLinBinning(Int_t nbinsX, Double_t xmin, Double_t xmax) const;
b2a297fa 109
110 AliDielectronCF(const AliDielectronCF &c);
111 AliDielectronCF &operator=(const AliDielectronCF &c);
112
3505bfad 113 ClassDef(AliDielectronCF,4) //Dielectron Correction Framework handler
b2a297fa 114};
115
116#endif