1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
7 #ifndef ALIFLOWANALYSISWITHSCALARPRODUCT_H
8 #define ALIFLOWANALYSISWITHSCALARPRODUCT_H
10 class AliFlowTrackSimple;
11 class AliFlowEventSimple;
12 class AliFlowCommonHist;
13 class AliFlowCommonHistResults;
22 /////////////////////////////////////////////////////////////////////////////
23 // Description: Maker to analyze Flow from the Event Plane method.
24 // Adaptation based on Scalar Product
25 // authors: Naomi van del Kolk (kolk@nikhef.nl)
26 // Ante Bilandzic (anteb@nikhef.nl)
27 // mods: Carlos Perez (cperez@nikhef.nl)
28 /////////////////////////////////////////////////////////////////////////////
30 class AliFlowAnalysisWithScalarProduct {
33 AliFlowAnalysisWithScalarProduct(); //default constructor
34 virtual ~AliFlowAnalysisWithScalarProduct(); //destructor
36 void Init(); //Define output objects
37 void Make(AliFlowEventSimple* anEvent); //Main routine
38 void GetOutputHistograms(TList *outputListHistos); //Copy output objects from TList
39 void Finish(); //Fill results
40 void WriteHistograms(TDirectoryFile *outputFileName); //writes histograms locally (for OnTheFly)
43 void SetHarmonic(Int_t iHarmonic) { fHarmonic = iHarmonic; }
44 void SetApplyCorrectionForNUA(Bool_t iVal) { fApplyCorrectionForNUA = iVal?1:0; }
45 void SetNormalizationType(Int_t iVal) { fNormalizationType = iVal; }
46 void SetDebug(Bool_t bVal) { fDebug = bVal; }
47 void SetTotalQvector(Int_t iVal) { fTotalQvector = iVal; }
49 void SetUsePhiWeights(Bool_t bVal) { fUsePhiWeights = bVal; }
50 void SetWeightsList(TList* const aWeightsList) { fWeightsList = (TList*)aWeightsList->Clone(); }
52 TList* GetHistList() { return fHistList; }
53 TProfile* GetHistProConfig() { return fHistProConfig; }
54 TProfile* GetHistProUQ(Int_t iRFPorPOI, Int_t iPTorETA) { return fHistProUQ[iRFPorPOI][iPTorETA]; }
55 TProfile* GetHistProQaQbNorm() { return fHistProQaQbNorm; }
56 TProfile* GetHistProNUAq() { return fHistProNUAq; }
57 TProfile* GetHistProNUAu(Int_t iRFPorPOI, Int_t iPTorETA, Int_t iIMorRE) { return fHistProNUAu[iRFPorPOI][iPTorETA][iIMorRE]; }
58 TH1D* GetHistSumOfWeights() { return fHistSumOfWeights; }
59 TProfile* GetHistProUQQaQb( Int_t iRFPorPOI, Int_t iPTorETA ) { return fHistProUQQaQb[iRFPorPOI][iPTorETA]; }
60 TH1D* GetHistSumOfWeightsu(Int_t iRFPorPOI, Int_t iPTorETA, Int_t iWeight) { return fHistSumOfWeightsu[iRFPorPOI][iPTorETA][iWeight]; }
61 AliFlowCommonHist* GetCommonHists() { return fCommonHists; }
62 AliFlowCommonHistResults* GetCommonHistsRes() { return fCommonHistsRes; }
65 AliFlowAnalysisWithScalarProduct(const AliFlowAnalysisWithScalarProduct& anAnalysis); //copy constructor
66 AliFlowAnalysisWithScalarProduct& operator=(const AliFlowAnalysisWithScalarProduct& anAnalysis); //assignment operator
67 Double_t CalculateStatisticalError( Int_t RFPorPOI, Int_t PTorETA, Int_t bin, Double_t errV );
68 Double_t computeResolution( Double_t x );
69 Double_t findXi( Double_t res, Double_t prec );
72 Int_t fDebug ; // flag for analysis: more print statements
73 Int_t fUsePhiWeights; // use phi weights
74 Int_t fApplyCorrectionForNUA; // apply correction for non-uniform acceptance
75 Int_t fHarmonic; // harmonic
76 Int_t fNormalizationType; // 0: EP mode || 1: SP mode
77 Int_t fTotalQvector; // 1:Qa 2:Qb 3:QaQb
79 TList* fWeightsList; // list holding input histograms with phi weights
80 TList* fHistList; // list to hold all output histograms
81 TProfile* fHistProConfig; // configuration values
82 TProfile* fHistProQaQbNorm; // average of QaQb
83 TH1D* fHistSumOfWeights; // holds sum of Na*Nb and (Na*Nb)^2
84 TProfile* fHistProNUAq; // NUA related qq
87 TProfile* fHistProQNorm; // QNorm
88 TProfile* fHistProQaQb; // QaQb
89 TProfile* fHistProQaQbM; // QaQb/MaMb
90 TH2D* fHistMaMb; // MaMb
91 TH2D* fHistQNormQaQbNorm; // QNorm vs QaQbNorm
92 TH2D* fHistQaNormMa; // QaNorm Ma
93 TH2D* fHistQbNormMb; // QbNorm Mb
94 TH1D* fResolution; // Resolution
95 TH1D* fHistQaQb; // QaQb
96 TH1D* fHistQaQbCos; // QaQbCos
98 AliFlowCommonHist* fCommonHists; // control histograms
99 AliFlowCommonHist* fCommonHistsuQ; // control histograms
100 AliFlowCommonHistResults* fCommonHistsRes; // results histograms
102 TH1F* fPhiWeightsSub[2]; // histogram holding phi weights for subevents
103 TProfile* fHistProUQ[2][2]; // uQ for RP|POI PT|ETA
104 TProfile* fHistProUQQaQb[2][2]; // holds weighted average of <QuQaQb> for RP|POI PT|ETA
105 TH1D* fHistSumOfWeightsu[2][2][3]; // holds sums of 0: Nq', 1: Nq'^2, 2: Nq'*Na*Nb
106 TProfile* fHistProNUAu[2][2][2]; // NUA related qq for RP|POI PT|ETA
108 ClassDef(AliFlowAnalysisWithScalarProduct,0) // class version