1 // ************************************************************************
2 // This file is property of and copyright by the ALICE HLT Project *
3 // ALICE Experiment at CERN, All rights reserved. *
4 // See cxx source for full Copyright notice *
6 //*************************************************************************
9 #ifndef ALIHLTTPCCATRACKLINEARISATION_H
10 #define ALIHLTTPCCATRACKLINEARISATION_H
12 #include "AliHLTTPCCATrackParam.h"
16 * @class AliHLTTPCCATrackLinearisation
18 * AliHLTTPCCATrackLinearisation class describes the parameters which are used
19 * to linearise the transport equations for the track trajectory.
21 * The class is used during track (re)fit, when the AliHLTTPCTrackParam track is only
22 * partially fitted, and there is some apriory knowledge about trajectory.
23 * This apriory knowledge is used to linearise the transport equations.
25 * In case the track is fully fitted, the best linearisation point is
26 * the track trajectory itself (AliHLTTPCCATrackLinearisation = AliHLTTPCTrackParam ).
29 class AliHLTTPCCATrackLinearisation
34 AliHLTTPCCATrackLinearisation()
35 : fSinPhi( 0 ), fCosPhi( 1 ), fDzDs( 0 ), fQPt( 0 ) {}
37 AliHLTTPCCATrackLinearisation( float SinPhi1, float CosPhi1, float DzDs1, float QPt1 )
38 : fSinPhi( SinPhi1 ), fCosPhi( CosPhi1 ), fDzDs( DzDs1 ), fQPt( QPt1 ) {}
40 AliHLTTPCCATrackLinearisation( const AliHLTTPCCATrackParam &t );
42 GPUd() void Set( float SinPhi1, float CosPhi1, float DzDs1, float QPt1 );
45 GPUd() float SinPhi()const { return fSinPhi; }
46 GPUd() float CosPhi()const { return fCosPhi; }
47 GPUd() float DzDs() const { return fDzDs; }
48 GPUd() float QPt() const { return fQPt; }
50 GPUd() float GetSinPhi()const { return fSinPhi; }
51 GPUd() float GetCosPhi()const { return fCosPhi; }
52 GPUd() float GetDzDs() const { return fDzDs; }
53 GPUd() float GetQPt() const { return fQPt; }
55 GPUd() void SetSinPhi( float v ) { fSinPhi = v; }
56 GPUd() void SetCosPhi( float v ) { fCosPhi = v; }
57 GPUd() void SetDzDs( float v ) { fDzDs = v; }
58 GPUd() void SetQPt( float v ) { fQPt = v; }
61 float fSinPhi; // SinPhi
62 float fCosPhi; // CosPhi
68 GPUd() inline AliHLTTPCCATrackLinearisation::AliHLTTPCCATrackLinearisation( const AliHLTTPCCATrackParam &t )
69 : fSinPhi( t.SinPhi() ), fCosPhi( 0 ), fDzDs( t.DzDs() ), fQPt( t.QPt() )
71 if ( fSinPhi > .999 ) fSinPhi = .999;
72 else if ( fSinPhi < -.999 ) fSinPhi = -.999;
73 fCosPhi = CAMath::Sqrt( 1 - fSinPhi * fSinPhi );
74 if ( t.SignCosPhi() < 0 ) fCosPhi = -fCosPhi;
78 GPUd() inline void AliHLTTPCCATrackLinearisation::Set( float SinPhi1, float CosPhi1,
79 float DzDs1, float QPt1 )