]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STEER/AliESDMuonTrack.cxx
new functions, mc analysis can be performed also for pi0 and k0. eta of seed can...
[u/mrichter/AliRoot.git] / STEER / AliESDMuonTrack.cxx
index ad9db0989d584cae064440a21d6f1080eeae119f..d3d3861038ce682a4b4a581e691d01839e31b06a 100644 (file)
@@ -517,6 +517,24 @@ void AliESDMuonTrack::LorentzPUncorrected(TLorentzVector& vP) const
   vP.SetPxPyPzE(pX, pY, pZ, e);
 }
 
+//_____________________________________________________________________________
+Int_t AliESDMuonTrack::GetNDF() const
+{
+  /// return the number of degrees of freedom
+  
+  Int_t ndf = 2 * static_cast<Int_t>(fNHit) - 5;
+  return (ndf > 0) ? ndf : 0;
+}
+
+//_____________________________________________________________________________
+Double_t AliESDMuonTrack::GetNormalizedChi2() const
+{
+  /// return the chi2 value divided by the number of degrees of freedom
+  
+  Int_t ndf = GetNDF();
+  return (ndf > 0) ? fChi2 / static_cast<Double_t>(ndf) : 0.;
+}
+
 //_____________________________________________________________________________
 Int_t AliESDMuonTrack::GetMatchTrigger() const
 {