]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
charged hadrons up to 10 GeV/c
authorlmilano <lmilano@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 21 Jun 2012 09:49:31 +0000 (09:49 +0000)
committerlmilano <lmilano@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 21 Jun 2012 09:49:31 +0000 (09:49 +0000)
PWGLF/SPECTRA/PiKaPr/TestAOD/AliSpectraAODEventCuts.cxx
PWGLF/SPECTRA/PiKaPr/TestAOD/AliSpectraAODHistoManager.cxx
PWGLF/SPECTRA/PiKaPr/TestAOD/AliSpectraAODHistoManager.h
PWGLF/SPECTRA/PiKaPr/TestAOD/Histograms.h
PWGLF/SPECTRA/PiKaPr/TestAOD/runGrid.C

index b251045778ec83b94b61ee83731d49bed86d3611..9ef5148b4ca0680dc1290f9bb82bcc3661463cc2 100644 (file)
@@ -102,7 +102,7 @@ Bool_t AliSpectraAODEventCuts::IsSelected(AliAODEvent * aod,AliSpectraAODTrackCu
       Nch++;
     }
   }
-  Printf("NCHARGED_EvSel : %d",Nch);
+  //Printf("NCHARGED_EvSel : %d",Nch);
   if(fIsSelected)fHistoNChAftSel->Fill(Nch);
   return fIsSelected;
 }
@@ -148,7 +148,7 @@ Bool_t AliSpectraAODEventCuts::CheckMultiplicityCut()
     if (!fTrackCuts->IsSelected(track,kFALSE)) continue;
     Ncharged++;
   }
-  Printf("NCHARGED_cut : %d",Ncharged);
+  //Printf("NCHARGED_cut : %d",Ncharged);
   if(Ncharged>fMultiplicityCutMin && Ncharged<fMultiplicityCutMax)return kTRUE;
   
   return kFALSE;
index 43309d7be733487f0e6ebb7344f619e64ee3ad96..12b2b3bf9a8eadc036d14402e4af76bdf7b80245 100644 (file)
@@ -67,8 +67,10 @@ AliSpectraAODHistoManager::AliSpectraAODHistoManager(const char *name,Int_t nreb
   for (Int_t ihist  = 0; ihist < kNHist ; ihist++)
     {
       if (ihist <= kNPtGenHist) BookPtGenHistogram(kHistName[ihist]);  // PT histos
-      if (ihist > kNPtGenHist && ihist <= kNPtRecHist) BookPtRecHistogram(kHistName[ihist]);  // PT histos
-      if (ihist > kNPtRecHist && ihist <= kNHistPID) BookPIDHistogram(kHistName[ihist]);  // PID histos
+      if (ihist > kNPtGenHist && ihist <= kNPtGenAllChHist) BookPtGenAllChHistogram(kHistName[ihist]);  // PT histos
+      if (ihist > kNPtGenAllChHist && ihist <= kNPtRecHist) BookPtRecHistogram(kHistName[ihist]);  // PT histos
+      if (ihist > kNPtRecHist && ihist <= kNPtRecAllChHist) BookPtRecAllChHistogram(kHistName[ihist]);  // PT histos
+      if (ihist > kNPtRecAllChHist && ihist <= kNHistPID) BookPIDHistogram(kHistName[ihist]);  // PID histos
       if (ihist > kNHistPID && ihist <= kNHistNSig) BookNSigHistogram(kHistName[ihist]);  // NSigmaSep histos
       if (ihist > kNHistNSig) BookqVecHistogram(kHistName[ihist]);  // qDistr histos
     }
@@ -97,6 +99,27 @@ TH2F* AliSpectraAODHistoManager::BookPtGenHistogram(const char * name)
   return hist;
 }
 
+//_______________________________________________________
+
+TH2F* AliSpectraAODHistoManager::BookPtGenAllChHistogram(const char * name)
+{
+  // Return a pt histogram with predefined binning, set the ID and add it to the output list
+  AliInfo(Form("Booking pt gen histogram - no PID %s", name));
+   
+  //standard histo
+  const Double_t templBins[] = {0.05,0.1,0.12,0.14,0.16,0.18,0.20,0.25,0.30,0.35,0.4,0.45,0.5,0.55,0.6,0.65,0.7,0.75,0.8,0.85,0.9,0.95,1.0,1.1,1.2,1.3,1.4,1.5,1.6,1.7,1.8,1.9,2.0,2.1,2.2,2.3,2.4,2.5,2.6,2.7,2.8,2.9,3.0,3.2,3.4,3.6,3.8,4.0,4.2,4.4,4.6,4.8,5.0,5.5,6.0,6.5,7,7.5,8,8.5,9,9.5,10};
+  Int_t nbinsTempl=62;
+   
+  TH2F * hist = new TH2F(name,Form("P_{T} distribution (All Ch) (%s)", name),nbinsTempl,templBins,2,-0.5,1.5);//need to be at least 1 becuase the generated are filled with (pt,IsPhysPrim)
+  hist->GetXaxis()->SetTitle("generated P_{T} (GeV / c)");
+  hist->GetYaxis()->SetTitle("IsPhysicalPrimary()");
+  hist->SetMarkerStyle(kFullCircle);
+  hist->Sumw2();
+  fOutputList->Add(hist);
+   
+  return hist;
+}
+
 
 //_______________________________________________________
 TH2F* AliSpectraAODHistoManager::BookPtRecHistogram(const char * name)
@@ -119,6 +142,27 @@ TH2F* AliSpectraAODHistoManager::BookPtRecHistogram(const char * name)
   return hist;
 }
 
+//_______________________________________________________
+TH2F* AliSpectraAODHistoManager::BookPtRecAllChHistogram(const char * name)
+{
+  // Return a pt histogram with predefined binning, set the ID and add it to the output list
+  AliInfo(Form("Booking pt rec histogram %s,  rebin:%d", name, fNRebin));
+   
+  //standard histo
+  const Double_t templBins[] = {0.05,0.1,0.12,0.14,0.16,0.18,0.20,0.25,0.30,0.35,0.4,0.45,0.5,0.55,0.6,0.65,0.7,0.75,0.8,0.85,0.9,0.95,1.0,1.1,1.2,1.3,1.4,1.5,1.6,1.7,1.8,1.9,2.0,2.1,2.2,2.3,2.4,2.5,2.6,2.7,2.8,2.9,3.0,3.2,3.4,3.6,3.8,4.0,4.2,4.4,4.6,4.8,5.0,5.5,6.0,6.5,7,7.5,8,8.5,9,9.5,10};
+  Int_t nbinsTempl=62;
+   
+  TH2F * hist = new TH2F(name,Form("reconstructed P_{T} distribution (All Ch)  (%s)", name),nbinsTempl,templBins,3000,-3,3);//need to be at least 1 becuase the generated are filled with (pt,IsPhysPrim)
+  if(fNRebin!=0)hist->RebinY(fNRebin);
+  hist->GetXaxis()->SetTitle("P_{T} (GeV / c)");
+  hist->GetYaxis()->SetTitle("DCA xy");
+  hist->SetMarkerStyle(kFullCircle);
+  hist->Sumw2();
+  fOutputList->Add(hist);
+
+  return hist;
+}
+
 //_____________________________________________________________________________
 
 TH2F* AliSpectraAODHistoManager::BookPIDHistogram(const char * name)
index 0314fb59ec3a8bc4766e98a3017ac91d9017b4d4..fa03fd101fea13d9e2890458869380d28ebe0d67 100644 (file)
@@ -73,7 +73,9 @@ public:
 
 
    TH2F*   BookPtGenHistogram(const char * name);
+   TH2F*   BookPtGenAllChHistogram(const char * name);
    TH2F*   BookPtRecHistogram(const char * name);
+   TH2F*   BookPtRecAllChHistogram(const char * name);
    TH2F*   BookPIDHistogram(const char * name);
    TH2F*   BookNSigHistogram(const char * name);
    TH2F*   BookqVecHistogram(const char * name);
index f357477338568fa87ba374e724ffbaec0ba8ee6b..422867b1e66322564f97d391543dc82843d96668 100644 (file)
@@ -20,8 +20,9 @@ namespace AliSpectraNameSpace
       kHistPtGenTruePrimaryPionMinus,           // Pt histo for pions -, generated tracks, true ID, primary Event
       kHistPtGenTruePrimaryKaonMinus,           // Pt histo for kaons -, generated tracks, true ID, primary Event
       kHistPtGenTruePrimaryProtonMinus,         // Pt histo for protons -, generated tracks, true ID, primary Event
+      kNPtGenHist = kHistPtGenTruePrimaryProtonMinus,                    // Number of ptGen-likehistos histos - PID
       kHistPtGen,                               // Pt histo for all particles, generated tracks
-      kNPtGenHist = kHistPtGen,                    // Number of ptGen-likehistos histos
+      kNPtGenAllChHist = kHistPtGen,                    // Number of ptGen-likehistos histos - AllCh
       
       // 6 Pt Reconstructed Sigma
       kHistPtRecSigmaPionPlus,                  // Pt histo for pions +, reconstructed tracks, sigma ID
@@ -84,11 +85,12 @@ namespace AliSpectraNameSpace
       kHistPtRecTruePrimaryProtonMinus,         // Pt histo for protons -, reconstructed tracks, true ID, primary event
       kHistPtRecTruePrimaryMuonPlus,            // Pt histo for muons +, reconstructed tracks, true ID, primary event
       kHistPtRecTruePrimaryMuonMinus,            // Pt histo for muons +, reconstructed tracks, true ID, primary event
+      kNPtRecHist = kHistPtRecTruePrimaryMuonMinus,                    // Number of ptRec-likehistos histos
       
       // Rest
       kHistPtRec,                               // Pt histo for all particles, reconstructed tracks
       kHistPtRecPrimary,                               // Pt histo for all particles, reconstructed tracks
-      kNPtRecHist = kHistPtRecPrimary,                    // Number of ptRec-likehistos histos
+      kNPtRecAllChHist = kHistPtRecPrimary,                    // Number of ptRec-likehistos histos - no PID
       
       kHistPIDTPC,                              // Particle Identification histo
       kHistPIDTOF,                              
index 841084836f95e2e4f07e1302cae7d81d72a8fb77..aa7e57005ce5797e4ee0434f4641f387bb3a1f17 100644 (file)
@@ -62,8 +62,8 @@ void runGrid(TString mode="test",Bool_t mc=0,Int_t day=15,Int_t month=6, Int_t y
   Double_t EtaMin[4]={       -0.8,-0.8,-0.8,-0.8};
   Double_t EtaMax[4]={        0.8, 0.8, 0.8, 0.8};
   Double_t Nsigmapid=3.;
-  Double_t pt=5.;
-  Double_t p=5.;
+  Double_t pt=10.;
+  Double_t p=10.;
   Double_t y=.5;
   Double_t ptTofMatch=.6;
   UInt_t trkbit=1024;
@@ -75,7 +75,7 @@ void runGrid(TString mode="test",Bool_t mc=0,Int_t day=15,Int_t month=6, Int_t y
   TString opt="";
   
   for(Int_t icut=0;icut<4;icut++){
-    //if(icut!=0)continue;
+    if(icut!=0)continue;
     AliAnalysisTaskSpectraAOD *taskAOD =AddTaskSpectraAOD(mc,CentCutMin[icut],CentCutMax[icut],QvecCutMin[icut],QvecCutMax[icut],EtaMin[icut],EtaMax[icut],Nsigmapid,pt,p,y,ptTofMatch,trkbit,trkbitQVector,UseCentPatchAOD049,DCA,minNclsTPC,nrebin,opt.Data());
     
     taskAOD->GetOutputSlot(1)->GetContainer()->SetName(Form("%s_%s",taskAOD->GetOutputSlot(1)->GetContainer()->GetName(),taskAOD->GetName()));