]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG2/EVCHAR/runAliCentralityGlauberFit.C
Added pass1 and pass2 directories
[u/mrichter/AliRoot.git] / PWG2 / EVCHAR / runAliCentralityGlauberFit.C
1 {
2   //load libraries
3   //gSystem->SetBuildDir("/tmp");
4   gSystem->Load("libCore.so");  
5   gSystem->Load("libTree.so");
6   gSystem->Load("libGeom.so");
7   gSystem->Load("libVMC.so");
8   gSystem->Load("libPhysics.so");
9   gSystem->Load("libSTEERBase");
10   gROOT->ProcessLine(".include $ALICE_ROOT/include");
11   gROOT->LoadMacro("AliCentralityGlauberFit.cxx+");
12   
13   const char *finname ="../centrality/cvetan/VZero_366.root"; // name input file
14   const char *foutname="test.root"; // name output file
15
16   float percentXsec=100.0;
17   
18   AliCentralityGlauberFit *mPM = new AliCentralityGlauberFit();
19   mPM.SetOutputFile(foutname);
20
21   // latest V0 cvetan corrected 
22   mPM.AddHisto("fCorrMult1d");
23   //mPM.SetGlauberParam(1,27.550,28., 10,0.4,0.8, 1,1.116,0.825, 1,0.974,0.98); //minuit Npart**alpha
24   mPM.SetGlauberParam(1,23.5,25., 1,0.3,1.5, 1,1.115,0.83, 1,0.99,0.99); 
25   mPM.SetRebin(10);
26   mPM.SetRangeToFit(100., 21000.);   
27   mPM.MakeFitsMinuitNBD(finname);  
28   //mPM->MakeFits(finname);  
29
30   TFile * f = new TFile (foutname);
31   gDirectory->Get("fCorrMult1d")->Draw();;
32   TH1 * hg = (TH1*) gDirectory->Get("fCorrMult1d_GLAU");
33   hg->SetLineColor(kRed);
34   hg->Draw("same");
35 }
36