1 /**************************************************************************
2 * Author: Panos Christakoglou. *
3 * Contributors are mentioned in the code where appropriate. *
5 * Permission to use, copy, modify and distribute this software and its *
6 * documentation strictly for non-commercial purposes is hereby granted *
7 * without fee, provided that the above copyright notice appears in all *
8 * copies and that both the copyright notice and this permission notice *
9 * appear in the supporting documentation. The authors make no claims *
10 * about the suitability of this software for any purpose. It is *
11 * provided "as is" without express or implied warranty. *
12 **************************************************************************/
13 //-------------------------------------------------------------------------
15 // This class include into LRC library for Long-Range Correlation analysis
16 // it is the PtPt class
17 // calculates PtPt correlations for abs and rel var
18 // Origin: Petr Naumenko, SPbSU-CERN, Petr.Naoumenko@cern.ch
19 //-------------------------------------------------------------------------
23 //-------------------------------------------------------------------------
24 // LRC library for Long-Range Correlation analysis
26 // Origin: Petr Naumenko, SPbSU-CERN, Petr.Naoumenko@cern.ch
27 //-------------------------------------------------------------------------
29 #include "AliLRCPtPt.h"
33 /******************************************************
35 ******************************************************/
36 AliLRCPtPt::AliLRCPtPt():AliLRCAnalysis() {
40 AliLRCPtPt::~AliLRCPtPt() {
44 AliLRCPtPt::AliLRCPtPt(char *name, TH2D* sourceHist, double ptd, TH2D* nb):AliLRCAnalysis() {
45 //Make PtPt form 2d histogram
47 CreateHist(name, (char*)"PAliLRCPt_abs", (char*)"PAliLRCPt_rel", (char*)"Pt_{F}", (char*)"Pt_{B}", (char*)"#frac{Pt_{F}}{<Pt_{F}>}", (char*)"#frac{<Pt_{B}>_{Pt_{F}}}{<Pt_{B}>}", sourceHist);
48 SetErrors(sourceHist, name, ptd, nb);
51 AliLRCPtPt::AliLRCPtPt(char *fileHistname, char *histname, char *profname, double ptd, char *errhistname):AliLRCAnalysis() {
52 //Make PtPt form 2d histogram from root file
54 fileHist = new TFile(fileHistname);
55 TH2D* sourceHist = (TH2D*) fileHist->Get(histname);
56 TH2D* nb = (TH2D*) fileHist->Get(errhistname);
57 CreateHist(profname, (char*)"PAliLRCPt_abs", (char*)"PAliLRCPt_rel", (char*)"Pt_{F}", (char*)"Pt_{B}", (char*)"#frac{Pt_{F}}{<Pt_{F}>}", (char*)"#frac{<Pt_{B}>_{Pt_{F}}}{<Pt_{B}>}", sourceHist);
58 SetErrors(sourceHist, profname, ptd, nb);
61 void AliLRCPtPt::MakeHistogramm(char *name, TH2D* sourceHist, double ptd, TH2D* nb) {
62 //Make PtPt form 2d histogram
64 CreateHist(name, (char*)"PAliLRCPt_abs", (char*)"PAliLRCPt_rel", (char*)"Pt_{F}", (char*)"Pt_{B}", (char*)"#frac{Pt_{F}}{<Pt_{F}>}", (char*)"#frac{<Pt_{B}>_{Pt_{F}}}{<Pt_{B}>}", sourceHist);
65 SetErrors(sourceHist, name, ptd, nb);
68 void AliLRCPtPt::MakeHistogramm(char *fileHistname, char *histname, char *profname, double ptd, char *errhistname) {
69 //Make PtPt form 2d histogram from root file
71 fileHist = new TFile(fileHistname);
72 TH2D* sourceHist = (TH2D*) fileHist->Get(histname);
73 TH2D* nb = (TH2D*) fileHist->Get(errhistname);
74 CreateHist(profname, (char*)"PAliLRCPt_abs", (char*)"PAliLRCPt_rel", (char*)"Pt_{F}", (char*)"Pt_{B}", (char*)"#frac{Pt_{F}}{<Pt_{F}>}", (char*)"#frac{<Pt_{B}>_{Pt_{F}}}{<Pt_{B}>}", sourceHist);
75 SetErrors(sourceHist, profname, ptd, nb);