From c55ca9e5ff7ba48642d44e3cc714cd5d35693441 Mon Sep 17 00:00:00 2001 From: martinez Date: Tue, 2 Mar 2004 15:33:57 +0000 Subject: [PATCH] Defining properly momentum components in AliMUONHit constructors (thanks Artur) --- MUON/AliMUONHit.cxx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/MUON/AliMUONHit.cxx b/MUON/AliMUONHit.cxx index 00d6d90fde3..e39a385f539 100644 --- a/MUON/AliMUONHit.cxx +++ b/MUON/AliMUONHit.cxx @@ -15,6 +15,7 @@ /* $Id$ */ +#include "TMath.h" #include "AliMUONHit.h" ClassImp(AliMUONHit) @@ -63,6 +64,9 @@ AliMUONHit::AliMUONHit(Int_t shunt, Int_t track, Int_t iChamber, Int_t idpart, fPHfirst = 0; fPHlast = 0; fPTot = momentum; + fPx = momentum * TMath::Sin(theta) * TMath::Cos(phi); + fPy = momentum * TMath::Sin(theta) * TMath::Sin(phi); + fPx = momentum * TMath::Cos(theta) ; fAge = tof; fXref = 0.; fYref = 0.; @@ -88,6 +92,9 @@ AliMUONHit::AliMUONHit(Int_t shunt, Int_t track, Int_t iChamber, Int_t idpart, fPHfirst = 0; fPHlast = 0; fPTot = momentum; + fPx = momentum * TMath::Sin(theta) * TMath::Cos(phi); + fPy = momentum * TMath::Sin(theta) * TMath::Sin(phi); + fPx = momentum * TMath::Cos(theta) ; fAge = tof; fXref = Xref; fYref = Yref; -- 2.43.5