]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
setting the number of bins
authorsnelling <snelling@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 30 Nov 2010 10:08:18 +0000 (10:08 +0000)
committersnelling <snelling@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 30 Nov 2010 10:08:18 +0000 (10:08 +0000)
PWG2/FLOW/AliFlowCommon/AliFlowAnalysisWithQCumulants.cxx
PWG2/FLOW/macros/AddTaskFlowCentrality.C

index 584774b601585d7d272bb95d20686a794a60db5c..7f87090c41992dd2df74314997f276b3692b21ca 100644 (file)
@@ -2940,6 +2940,7 @@ void AliFlowAnalysisWithQCumulants::StorePhiDistributionForOneEvent(AliFlowEvent
   vEBE = pow(-1.*cumulant4thEBE,0.25);
   if((vEBE>vMin && vEBE<vMax) && (fReferenceMultiplicityEBE>refMultMin && fReferenceMultiplicityEBE<refMultMax))
   {
+   fPhiDistributionForOneEvent->SetTitle(Form("v_{%i} = %f",fHarmonic,vEBE));
    for(Int_t p=0;p<anEvent->NumberOfTracks();p++)
    {
     if(anEvent->GetTrack(p)->InRPSelection())
@@ -2947,7 +2948,11 @@ void AliFlowAnalysisWithQCumulants::StorePhiDistributionForOneEvent(AliFlowEvent
      fPhiDistributionForOneEvent->Fill(anEvent->GetTrack(p)->Phi());
     }
    } // end of for(Int_t p=0;p<anEvent->NumberOfTracks();p++)
-  }
+  } else
+    {
+     fPhiDistributionForOneEvent->SetTitle(Form("v_{%i} = %f, out of specified boundaries",fHarmonic,vEBE));  
+    } 
+   
  } // end of if(cumulant4thEBE<0.)
  
 } // end of void AliFlowAnalysisWithQCumulants::StorePhiDistributionForOneEvent(AliFlowEventSimple *anEvent)
index 5d92e764a9c5514dc8c350fc6cb7229b41db9f3c..0893ca9c777486220af2fe3849d645fe8cc19361 100644 (file)
@@ -136,8 +136,24 @@ void AddTaskFlowCentrality( Int_t refMultMin=0,
   //cutsPOI->SetMaxNsigmaToVertex(1.e+10);
   //cutsPOI->SetRequireSigmaToVertex(kFALSE);
   cutsPOI->SetAcceptKinkDaughters(kFALSE);
-
-
+  
+  // common constants:
+  Int_t nBinsMult = 10000;  
+  Int_t nBinsPt = 100;  
+  Int_t nBinsPhi = 360;  
+  Int_t nBinsEta = 100;  
+  Int_t nBinsQ = 500;
+  Double_t dMultMin = 0.;            
+  Double_t dMultMax = 10000.;
+  Double_t dPtMin = 0.;             
+  Double_t dPtMax = 10.;
+  Double_t dPhiMin(0.);            
+  Double_t dPhiMax(TMath::TwoPi());
+  Double_t dEtaMin(-5.);            
+  Double_t dEtaMax(5.);             
+  Double_t dQMin(0.);       
+  Double_t dQMax(3.);  
+  
   Bool_t useWeights  = WEIGHTS[0] || WEIGHTS[1] || WEIGHTS[2];
   if (useWeights) cout<<"Weights are used"<<endl;
   else cout<<"Weights are not used"<<endl;
@@ -306,8 +322,23 @@ void AddTaskFlowCentrality( Int_t refMultMin=0,
   taskFE->SetCutsRP(cutsRP);
   taskFE->SetCutsPOI(cutsPOI);
  
-
-
+  // Pass common constants:
+  taskFE->SetNbinsMult(nBinsMult);
+  taskFE->SetNbinsPt(nBinsPt);
+  taskFE->SetNbinsPhi(nBinsPhi); 
+  taskFE->SetNbinsEta(nBinsEta);
+  taskFE->SetNbinsQ(nBinsQ);
+  taskFE->SetMultMin(dMultMin);
+  taskFE->SetMultMax(dMultMax);
+  taskFE->SetPtMin(dPtMin);
+  taskFE->SetPtMax(dPtMax);
+  taskFE->SetPhiMin(dPhiMin);
+  taskFE->SetPhiMax(dPhiMax);
+  taskFE->SetEtaMin(dEtaMin);
+  taskFE->SetEtaMax(dEtaMax);
+  taskFE->SetQMin(dQMin);
+  taskFE->SetQMax(dQMax);
   // Create the analysis tasks, add them to the manager.
   //===========================================================================
   if (SP){