CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
GsfTrackExtra.h
Go to the documentation of this file.
1 #ifndef GsfTrackReco_GsfTrackExtra_h
2 #define GsfTrackReco_GsfTrackExtra_h
3 
9 // #include "DataFormats/Math/interface/Error.h"
12 
13 #include <iostream>
14 
15 namespace reco {
16  class GsfTrackExtra {
17  public:
19  enum { dimension = 5 };
28 
32  GsfTrackExtra( const std::vector<GsfComponent5D>& outerStates,
33  const double& outerLocalPzSign,
34  const std::vector<GsfComponent5D>& innerStates,
35  const double& innerLocalPzSign,
36  const std::vector<GsfTangent>& tangents);
38  double outerStateLocalPzSign() const {return positiveOuterStatePz_ ? 1. : -1.;}
40  std::vector<double> outerStateWeights() const { return weights(outerStates_); }
42  std::vector<LocalParameterVector> outerStateLocalParameters() const {
43  return parameters(outerStates_);
44  }
46  std::vector<LocalCovarianceMatrix> outerStateCovariances() const {
47  return covariances(outerStates_);
48  }
50  double innerStateLocalPzSign() const {return positiveInnerStatePz_ ? 1. : -1.;}
52  std::vector<double> innerStateWeights() const { return weights(innerStates_); }
54  std::vector<LocalParameterVector> innerStateLocalParameters() const {
55  return parameters(innerStates_);
56  }
58  std::vector<LocalCovarianceMatrix> innerStateCovariances() const {
59  return covariances(innerStates_);
60  }
62  inline unsigned int tangentsSize() const {return tangents_.size();}
64  const std::vector<GsfTangent>& tangents() const {
65  return tangents_;
66  }
68  const Point& tangentPosition (unsigned int index) const {
69  return tangents_[index].position();
70  }
72  const Vector& tangentMomentum (unsigned int index) const {
73  return tangents_[index].momentum();
74  }
76  Measurement1D tangentDeltaP (unsigned int index) const {
77  return tangents_[index].deltaP();
78  }
79 
80  private:
82  std::vector<double> weights (const std::vector<GsfComponent5D>& states) const;
84  std::vector<LocalParameterVector> parameters (const std::vector<GsfComponent5D>& states) const;
86  std::vector<LocalCovarianceMatrix> covariances (const std::vector<GsfComponent5D>& states) const;
87 
88  private:
90  std::vector<GsfComponent5D> outerStates_;
94  std::vector<GsfComponent5D> innerStates_;
98  std::vector<GsfTangent> tangents_;
99  };
100 
101 }
102 
103 #endif
double outerStateLocalPzSign() const
sign of local P_z at outermost state
Definition: GsfTrackExtra.h:38
Measurement1D tangentDeltaP(unsigned int index) const
deltaP for tangent
Definition: GsfTrackExtra.h:76
std::vector< double > innerStateWeights() const
weights at innermost state
Definition: GsfTrackExtra.h:52
bool positiveInnerStatePz_
positive sign of P_z(local) at innermost State?
Definition: GsfTrackExtra.h:96
const Vector & tangentMomentum(unsigned int index) const
global momentum for tangent
Definition: GsfTrackExtra.h:72
std::vector< LocalParameterVector > innerStateLocalParameters() const
local parameters at innermost state
Definition: GsfTrackExtra.h:54
bool positiveOuterStatePz_
positive sign of P_z(local) at outermost State?
Definition: GsfTrackExtra.h:92
std::vector< LocalCovarianceMatrix > outerStateCovariances() const
local covariance matrices at outermost state
Definition: GsfTrackExtra.h:46
std::vector< GsfComponent5D > innerStates_
states at innermost point
Definition: GsfTrackExtra.h:94
double innerStateLocalPzSign() const
sign of local P_z at innermost state
Definition: GsfTrackExtra.h:50
ErrorD< N >::type type
Definition: Error.h:30
math::Error< dimension >::type LocalCovarianceMatrix
local covariance matrix
Definition: GsfTrackExtra.h:23
unsigned int tangentsSize() const
number of objects with information for tangents to the electron track
Definition: GsfTrackExtra.h:62
fixed size vector
Definition: Vector.h:23
const std::vector< GsfTangent > & tangents() const
access to tangent information
Definition: GsfTrackExtra.h:64
std::vector< LocalCovarianceMatrix > covariances(const std::vector< GsfComponent5D > &states) const
extract covariance matrices from states
math::Vector< dimension >::type LocalParameterVector
local parameter vector
Definition: GsfTrackExtra.h:21
std::vector< LocalCovarianceMatrix > innerStateCovariances() const
local covariance matrices at innermost state
Definition: GsfTrackExtra.h:58
std::vector< LocalParameterVector > outerStateLocalParameters() const
local parameters at outermost state
Definition: GsfTrackExtra.h:42
std::vector< double > outerStateWeights() const
weights at outermost state
Definition: GsfTrackExtra.h:40
std::vector< double > weights(const std::vector< GsfComponent5D > &states) const
extract weights from states
std::vector< GsfComponent5D > outerStates_
states at outermost point
Definition: GsfTrackExtra.h:90
const Point & tangentPosition(unsigned int index) const
global position for tangent
Definition: GsfTrackExtra.h:68
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:13
math::XYZPoint Point
point in the space
Definition: GsfTrackExtra.h:25
std::vector< LocalParameterVector > parameters(const std::vector< GsfComponent5D > &states) const
extract parameters from states
GsfTrackExtra()
default constructor
Definition: GsfTrackExtra.h:30
math::XYZVector Vector
spatial vector
Definition: GsfTrackExtra.h:27
std::vector< GsfTangent > tangents_
information for tangents
Definition: GsfTrackExtra.h:98