]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
A small change in histogram names and a tiny bug fix
authorhdalsgaa <hdalsgaa@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 9 Aug 2009 18:24:03 +0000 (18:24 +0000)
committerhdalsgaa <hdalsgaa@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 9 Aug 2009 18:24:03 +0000 (18:24 +0000)
FMD/analysis/AliFMDAnalysisTaskBackgroundCorrection.cxx
FMD/analysis/AliFMDAnalysisTaskDndeta.cxx

index 14a9fb7e3ba404cea73d420466aca01c804f3fa6..ee9f95646b879eb803ebccfe21d36f0ce717b898 100644 (file)
@@ -157,7 +157,9 @@ void AliFMDAnalysisTaskBackgroundCorrection::Exec(Option_t */*option*/)
       TH2F* hMultInput = (TH2F*)fInputList->FindObject(Form("FMD%d%c_vtxbin%d",det,ringChar,vtxbin));
       TH2F* hHits      = (TH2F*)fOutputList->FindObject(Form("hits_FMD%d%c_vtxbin%d",det,ringChar,vtxbin));
       
       TH2F* hMultInput = (TH2F*)fInputList->FindObject(Form("FMD%d%c_vtxbin%d",det,ringChar,vtxbin));
       TH2F* hHits      = (TH2F*)fOutputList->FindObject(Form("hits_FMD%d%c_vtxbin%d",det,ringChar,vtxbin));
       
-      hHits->Add(hMultInput);
+      if(pars->GetProcessHits())
+        hHits->Add(hMultInput);
+      
       TH2F* hBg        = pars->GetBackgroundCorrection(det, ringChar, vtxbin);
       
       hMultTotal->Add(hMultInput);
       TH2F* hBg        = pars->GetBackgroundCorrection(det, ringChar, vtxbin);
       
       hMultTotal->Add(hMultInput);
index c76e614c9290cbee3c3ae9eb3cc9a9c8137828be..934da9b7aa785324d930d45671424809e615ee6b 100644 (file)
@@ -262,36 +262,33 @@ void AliFMDAnalysisTaskDndeta::ProcessPrimary() {
     }
     if(pars->GetProcessHits()) {
       for(Int_t j=0; j<particle->GetNumberOfTrackReferences();j++) {
     }
     if(pars->GetProcessHits()) {
       for(Int_t j=0; j<particle->GetNumberOfTrackReferences();j++) {
-      
-      AliTrackReference* ref = particle->GetTrackReference(j);
-      UShort_t det,sec,strip;
-      Char_t   ring;
-      if(ref->DetectorId() != AliTrackReference::kFMD)
-       continue;
-      AliFMDStripIndex::Unpack(ref->UserId(),det,ring,sec,strip);
-      Float_t thisStripTrack = fLastTrackByStrip(det,ring,sec,strip);
-      if(particle->Charge() != 0 && i != thisStripTrack ) {
-       //Double_t x,y,z;
-       
-       Float_t   eta   = pars->GetEtaFromStrip(det,ring,sec,strip,vertex.At(2));//-1*TMath::Log(TMath::Tan(0.5*theta));
-       TH1F* hHits = (TH1F*)fOutputList->FindObject(Form("hHits_FMD%d%c_vtxbin%d",det,ring,vertexBin));
-       hHits->Fill(eta);
-       Float_t nstrips = (ring =='O' ? 256 : 512);
-       
-       fLastTrackByStrip(det,ring,sec,strip) = (Float_t)i;
-       
-       if(strip >0)
-         fLastTrackByStrip(det,ring,sec,strip-1) = (Float_t)i;
-       if(strip < (nstrips - 1))
-         fLastTrackByStrip(det,ring,sec,strip+1) = (Float_t)i;
        
        
+       AliTrackReference* ref = particle->GetTrackReference(j);
+       UShort_t det,sec,strip;
+       Char_t   ring;
+       if(ref->DetectorId() != AliTrackReference::kFMD)
+         continue;
+       AliFMDStripIndex::Unpack(ref->UserId(),det,ring,sec,strip);
+       Float_t thisStripTrack = fLastTrackByStrip(det,ring,sec,strip);
+       if(particle->Charge() != 0 && i != thisStripTrack ) {
+         //Double_t x,y,z;
+         
+         Float_t   eta   = pars->GetEtaFromStrip(det,ring,sec,strip,vertex.At(2));//-1*TMath::Log(TMath::Tan(0.5*theta));
+         TH1F* hHits = (TH1F*)fOutputList->FindObject(Form("hHits_FMD%d%c_vtxbin%d",det,ring,vertexBin));
+         hHits->Fill(eta);
+         Float_t nstrips = (ring =='O' ? 256 : 512);
+         
+         fLastTrackByStrip(det,ring,sec,strip) = (Float_t)i;
        
        
-      }
+         if(strip >0)
+           fLastTrackByStrip(det,ring,sec,strip-1) = (Float_t)i;
+         if(strip < (nstrips - 1))
+           fLastTrackByStrip(det,ring,sec,strip+1) = (Float_t)i;
+         
+       }
       }
     }
       }
     }
-    
   }
   }
-  
 }
 //_____________________________________________________________________
 //
 }
 //_____________________________________________________________________
 //