Last change
on this file since 127644a was df408d2, checked in by Franco BEDESCHI <bed@…>, 4 years ago |
Fixed compatibility with ROOT5/minor changes to TrkUtil
|
-
Property mode
set to
100644
|
File size:
1.6 KB
|
Line | |
---|
1 | //
|
---|
2 | #ifndef G__TRKUTIL_H
|
---|
3 | #define G__TRKUTIL_H
|
---|
4 | //
|
---|
5 | #include <TVector3.h>
|
---|
6 | #include <TVectorD.h>
|
---|
7 | #include <TMatrixDSym.h>
|
---|
8 | //
|
---|
9 | //
|
---|
10 | // Class test
|
---|
11 |
|
---|
12 | class TrkUtil {
|
---|
13 | //
|
---|
14 | //
|
---|
15 | protected:
|
---|
16 | Double_t fBz; // Solenoid magnetic field
|
---|
17 | //
|
---|
18 | // Service routines
|
---|
19 | //
|
---|
20 | void SetBfield(Double_t Bz) { fBz = Bz; }
|
---|
21 | TVectorD XPtoPar(TVector3 x, TVector3 p, Double_t Q);
|
---|
22 | TVector3 ParToP(TVectorD Par);
|
---|
23 | //
|
---|
24 | // Conversion to ACTS parametrization
|
---|
25 | //
|
---|
26 | TVectorD ParToACTS(TVectorD Par); // Parameter conversion
|
---|
27 | TMatrixDSym CovToACTS(TVectorD Par, TMatrixDSym Cov); // Covariance conversion
|
---|
28 | //
|
---|
29 | // Conversion to ILC parametrization
|
---|
30 | //
|
---|
31 | TVectorD ParToILC(TVectorD Par); // Parameter conversion
|
---|
32 | TMatrixDSym CovToILC(TMatrixDSym Cov); // Covariance conversion
|
---|
33 |
|
---|
34 | public:
|
---|
35 | //
|
---|
36 | // Constructors
|
---|
37 | TrkUtil();
|
---|
38 | TrkUtil(Double_t Bz);
|
---|
39 | // Destructor
|
---|
40 | ~TrkUtil();
|
---|
41 | //
|
---|
42 | // Overload methods to allow call without instantiating class
|
---|
43 | //
|
---|
44 | static Double_t cSpeed()
|
---|
45 | {
|
---|
46 | Double_t c = 2.99792458e8; // speed of light m/sec
|
---|
47 | //return TMath::C()*1.0e-9; // Incompatible with root5
|
---|
48 | return c*1.0e-9; // Reduced speed of light
|
---|
49 | }
|
---|
50 | //
|
---|
51 | // Service routines
|
---|
52 | //
|
---|
53 | static TVectorD XPtoPar(TVector3 x, TVector3 p, Double_t Q, Double_t Bz);
|
---|
54 | static TVector3 ParToX(TVectorD Par); // position of minimum distance from z axis
|
---|
55 | static TVector3 ParToP(TVectorD Par, Double_t Bz); // Get Momentum from track parameters
|
---|
56 | static Double_t ParToQ(TVectorD Par); // Get track charge
|
---|
57 | //
|
---|
58 | // Conversion from meters to mm
|
---|
59 | //
|
---|
60 | static TVectorD ParToMm(TVectorD Par); // Parameter conversion
|
---|
61 | static TMatrixDSym CovToMm(TMatrixDSym Cov); // Covariance conversion
|
---|
62 |
|
---|
63 | };
|
---|
64 |
|
---|
65 | #endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.