CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PerigeeTrajectoryParameters.h
Go to the documentation of this file.
1 #ifndef PerigeeTrajectoryParameters_H
2 #define PerigeeTrajectoryParameters_H
3 
15 
17 {
18 
19 public:
20 
22 
23 
24 
25  explicit PerigeeTrajectoryParameters(const AlgebraicVector5 &aVector, bool charged = true):
26  theVector(aVector) {
27  if ( charged )
28  theCharge = theVector[0]>0 ? -1 : 1;
29  else
30  theCharge = 0;
31  }
32 
33  PerigeeTrajectoryParameters(double aCurv, double aTheta, double aPhi,
34  double aTip, double aLip, bool charged = true) {
35  theVector[0] = aCurv;
36  theVector[1] = aTheta;
37  theVector[2] = aPhi;
38  theVector[3] = aTip;
39  theVector[4] = aLip;
40 
41  if ( charged )
42  theCharge = aCurv>0 ? -1 : 1;
43  else
44  theCharge = 0;
45  }
46 
51  TrackCharge charge() const {return theCharge;}
52 
57  double transverseCurvature() const {return ((charge()!=0)?theVector[0]:0.);}
58 
63  double theta() const {return theVector[1];}
64 
69  double phi() const {return theVector[2];}
70 
75  double transverseImpactParameter() const {return theVector[3];}
76 
81  double longitudinalImpactParameter() const {return theVector[4];}
82 
89  const AlgebraicVector5 & vector() const { return theVector;}
90 
91 
92 private:
95 };
96 #endif
const AlgebraicVector5 & vector() const
int TrackCharge
Definition: TrackCharge.h:4
ROOT::Math::SVector< double, 5 > AlgebraicVector5
PerigeeTrajectoryParameters(const AlgebraicVector5 &aVector, bool charged=true)
PerigeeTrajectoryParameters(double aCurv, double aTheta, double aPhi, double aTip, double aLip, bool charged=true)