AliTracker::GetSign() (no comment on the method!) get sign curvature, not charge...
authordibari <dibari@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 26 Nov 2004 06:43:51 +0000 (06:43 +0000)
committerdibari <dibari@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 26 Nov 2004 06:43:51 +0000 (06:43 +0000)
RICH/AliRICHTracker.cxx

index 63c025a..b8ed01e 100644 (file)
@@ -44,7 +44,7 @@ void AliRICHTracker::RecWithESD(AliESD *pESD)
     pTrack->GetXYZ(xb); 
     pTrack->GetPxPyPz(pb); 
     Int_t status=pTrack->GetStatus()&AliESDtrack::kTOFout;//get running track parameters
-    Int_t charge = (Int_t)TMath::Sign(1.,pTrack->GetSign()*b);
+    Int_t charge = (Int_t)(-TMath::Sign(1.,pTrack->GetSign()*b));
     AliDebug(1,Form("Track %i pmod=%f charge=%i stat=%i",iTrackN,pTrack->GetP(),charge,status));
     x0.SetXYZ(xb[0],xb[1],xb[2]); p0.SetXYZ(pb[0],pb[1],pb[2]);
     AliRICHHelix helix(x0,p0,charge,b);