]> git.uio.no Git - u/mrichter/AliRoot.git/blame - HLT/TPCLib/tracking-ca/AliHLT3DTrackParam.h
Bug in cluster position corected (Diaz, Conesa)
[u/mrichter/AliRoot.git] / HLT / TPCLib / tracking-ca / AliHLT3DTrackParam.h
CommitLineData
326c2d4b 1//-*- Mode: C++ -*-
2// @(#) $Id$
3
dc4788ec 4//* This file is property of and copyright by the ALICE HLT Project *
5//* ALICE Experiment at CERN, All rights reserved. *
6//* See cxx source for full Copyright notice *
7
8//* *
9//* AliHLT3DTrackParam class is under development and currently not in use *
10//* *
326c2d4b 11
12#ifndef ALIHLT3DTRACKPARAM_H
13#define ALIHLT3DTRACKPARAM_H
14
15#include "Rtypes.h"
16
17/**
18 * @class AliHLT3DTrackParam
19 */
20class AliHLT3DTrackParam{
21 public:
22
23 //*
24 //* INITIALIZATION
25 //*
26
27 //* Constructor
28
29 AliHLT3DTrackParam(): fChi2(0),fNDF(0),fSignQ(0){}
30
31 //* Destructor (empty)
32
33 virtual ~AliHLT3DTrackParam(){}
34
35 //*
36 //* ACCESSORS
37 //*
38
39
40 //* Simple accessors
41
42 Double_t GetX() const { return fParam[0]; }
43 Double_t GetY() const { return fParam[1]; }
44 Double_t GetZ() const { return fParam[2]; }
45 Double_t GetPx() const { return fParam[3]; }
46 Double_t GetPy() const { return fParam[4]; }
47 Double_t GetPz() const { return fParam[5]; }
48 Double_t GetChi2() const { return fChi2; }
49 Int_t GetNDF() const { return fNDF; }
50 Int_t GetCharge() const { return fSignQ; }
51
dc4788ec 52 Double_t GetParameter ( int i ) const { return fParam[i]; }
53 Double_t GetCovariance( int i ) const { return fCov[i]; }
54 Double_t GetCovariance( int i, int j ) const { return fCov[( j<=i ) ? i*(i+1)/2+j :j*(j+1)/2+i]; }
326c2d4b 55
56 //* Accessors with calculations( &value, &estimated sigma )
57 //* error flag returned (0 means no error during calculations)
58
59
60 //*
61 //* MODIFIERS
62 //*
63
64 Double_t *Param() { return fParam; }
65 Double_t *Cov() { return fCov; }
66 Double_t &X() { return fParam[0]; }
67 Double_t &Y() { return fParam[1]; }
68 Double_t &Z() { return fParam[2]; }
69 Double_t &Px() { return fParam[3]; }
70 Double_t &Py() { return fParam[4]; }
71 Double_t &Pz() { return fParam[5]; }
72 Double_t &Chi2() { return fChi2; }
73 Int_t &NDF() { return fNDF; }
74 Int_t &Charge() { return fSignQ; }
75
76
77 //*
78 //* UTILITIES
79 //*
80
81 //* Transport utilities
82
83 Double_t GetDStoPoint( Double_t Bz, const Double_t xyz[3], const Double_t *T0=0 ) const;
84
85 void TransportToDS( Double_t Bz, Double_t DS, Double_t *T0=0 );
86
87 void TransportToPoint( Double_t Bz, const Double_t xyz[3], Double_t *T0=0 )
88 {
89 TransportToDS( Bz,GetDStoPoint(Bz, xyz, T0), T0 ) ;
90 }
91
92 void TransportToPoint( Double_t Bz, Double_t x, Double_t y, Double_t z, Double_t *T0=0 )
93 {
94 Double_t xyz[3] = {x,y,z};
95 TransportToPoint( Bz, xyz, T0 );
96 }
97
98 //* Fit utilities
99
100 void InitializeCovarianceMatrix();
101
102 void GetGlueMatrix( const Double_t p[3], Double_t G[6], const Double_t *T0=0 ) const ;
103
104 void Filter( const Double_t m[3], const Double_t V[6], const Double_t G[6] );
105
106 //* Other utilities
107
108 void SetDirection( Double_t Direction[3] );
109
110 void RotateCoordinateSystem( Double_t alpha );
111
112 void Get5Parameters( Double_t alpha, Double_t T[6], Double_t C[15] ) const;
113
114 protected:
115
116 Double_t fParam[6]; // Parameters ( x, y, z, px, py, pz ): 3-position and 3-momentum
117 Double_t fCov[21]; // Covariance matrix
118 Double_t fChi2; // Chi^2
119 Int_t fNDF; // Number of Degrees of Freedom
120 Int_t fSignQ; // Charge
121
122 ClassDef(AliHLT3DTrackParam, 0);
123
124};
125
126
127#endif