]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PWG3/dielectron/AliDielectronMC.cxx
framework update; new classes for track rotation (for background), cuts grouping...
[u/mrichter/AliRoot.git] / PWG3 / dielectron / AliDielectronMC.cxx
index 943124ce10fc8ff20e6a3dc0517c52636e2f5d1f..b7c332f9aa873ee85e85d0569d26f8ecad3a3cdd 100644 (file)
@@ -113,6 +113,26 @@ Int_t AliDielectronMC::GetNMCTracksFromStack()
   return fStack->GetNtrack();
 }
 
+//____________________________________________________________
+Int_t AliDielectronMC::GetNPrimary()
+{
+  //
+  //  return the number of primary track from MC event
+  //
+  if (!fMCEvent){ AliError("No fMCEvent"); return 0; }
+  return fMCEvent->GetNumberOfPrimaries();
+}
+
+//____________________________________________________________
+Int_t AliDielectronMC::GetNPrimaryFromStack()
+{
+  //
+  //  return the number of primary track from stack
+  //
+  if (!fStack){ AliError("No fStack"); return -999; }
+  return fStack->GetNprimary();
+}
+
 //____________________________________________________________
 AliVParticle* AliDielectronMC::GetMCTrackFromMCEvent(Int_t itrk)
 {