]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGLF/SPECTRA/AntiprotonToProton/configProtonFeedDownAnalysis.C
Merge branch 'feature-movesplit'
[u/mrichter/AliRoot.git] / PWGLF / SPECTRA / AntiprotonToProton / configProtonFeedDownAnalysis.C
1 //__________________________________________________________
2
3 Double_t test1(Double_t *x,Double_t *p)
4 {
5         /*if(x[0]<1.5) 
6                 return -1.0*x[0]+2.5; 
7         else 
8                 return 1.0;*/
9         if(x[0]<3.0) 
10                 return -0.2*x[0]+1.6; 
11         else 
12                 return 1.0;     
13 }
14 //_____________________________________________________________
15 Double_t test2(Double_t *x,Double_t *p)
16 {
17         if(x[0]<1.5) 
18                 return -1.0*x[0]+2.5; 
19         else 
20                 return 1.0;
21 }
22
23 //__________________________________________________//
24 AliProtonFeedDownAnalysis *GetProtonFeedDownAnalysisObject() {
25 //gROOT->LoadMacro("$ALICE_ROOT/PWG2/SPECTRA/macros/configProtonAnalysisBaseObject.C"); 
26   //Function to setup the AliProtonAnalysis object and return it
27  // AliProtonAnalysisBase *baseAnalysis = GetProtonAnalysisBaseObject(analysisLevel,esdAnalysisType,pidMode);
28
29   AliProtonFeedDownAnalysis *analysis = new AliProtonFeedDownAnalysis();
30 //  analysis->SetBaseAnalysis(baseAnalysis);
31   //if(analysisBase->GetEtaMode()) analysis->SetEtaMode();
32 TF1* weightfunction=new TF1("weightfunction","1");
33 //TF1* weightfunction=new TF1("weightfunction",test1,0.5,4.0,0);        
34 //TF1* weightfunction=new TF1("weightfunction",test2,0.5,4.0,0);                           
35  analysis->SetWeightFunction(weightfunction);      
36     
37   return analysis;
38 }
39
40