CMS 3D CMS Logo

Track.h
Go to the documentation of this file.
1 #ifndef TrackReco_Track_h
2 #define TrackReco_Track_h
3 
24 
25 namespace reco
26 {
27 
28 class Track : public TrackBase
29 {
30 
31 public:
32 
34  Track() { }
35 
37  ~Track() override;
38 
40  Track(double chi2, double ndof, const Point & referencePoint,
41  const Vector & momentum, int charge, const CovarianceMatrix &,
43  float t0 = 0, float beta = 0,
44  float covt0t0 = -1., float covbetabeta = -1.);
45 
47  bool outerOk() const {
48  return extra_->outerOk();
49  }
50 
52  bool innerOk() const {
53  return extra_->innerOk();
54  }
55 
57  const math::XYZPoint & innerPosition() const {
58  return extra_->innerPosition();
59  }
60 
62  const math::XYZVector & innerMomentum() const {
63  return extra_->innerMomentum();
64  }
65 
67  const math::XYZPoint & outerPosition() const {
68  return extra_->outerPosition();
69  }
70 
72  const math::XYZVector & outerMomentum() const {
73  return extra_->outerMomentum();
74  }
75 
78  return extra_->outerStateCovariance();
79  }
80 
83  return extra_->innerStateCovariance();
84  }
85 
88  return extra_->fillOuter(v);
89  }
90 
92  return extra_->fillInner(v);
93  }
94 
96  unsigned int outerDetId() const {
97  return extra_->outerDetId();
98  }
99 
101  unsigned int innerDetId() const {
102  return extra_->innerDetId();
103  }
104 
106  auto recHits() const { return extra_->recHits(); }
107 
110  return extra_->recHitsBegin();
111  }
112 
115  return extra_->recHitsEnd();
116  }
117 
119  TrackingRecHitRef recHit(size_t i) const {
120  return extra_->recHit(i);
121  }
122 
124  size_t recHitsSize() const {
125  return extra_->recHitsSize();
126  }
127 
129  double outerPx() const {
130  return extra_->outerPx();
131  }
132 
134  double outerPy() const {
135  return extra_->outerPy();
136  }
137 
139  double outerPz() const {
140  return extra_->outerPz();
141  }
142 
144  double outerX() const {
145  return extra_->outerX();
146  }
147 
149  double outerY() const {
150  return extra_->outerY();
151  }
152 
154  double outerZ() const {
155  return extra_->outerZ();
156  }
157 
159  double outerP() const {
160  return extra_->outerP();
161  }
162 
164  double outerPt() const {
165  return extra_->outerPt();
166  }
167 
169  double outerPhi() const {
170  return extra_->outerPhi();
171  }
172 
174  double outerEta() const {
175  return extra_->outerEta();
176  }
177 
179  double outerTheta() const {
180  return extra_->outerTheta();
181  }
182 
184  double outerRadius() const {
185  return extra_->outerRadius();
186  }
187 
189  void setExtra(const TrackExtraRef & ref) {
190  extra_ = ref;
191  }
192 
194  const TrackExtraRef & extra() const {
195  return extra_;
196  }
197 
199  unsigned short found() const {
200  return numberOfValidHits();
201  }
202 
204  unsigned short lost() const {
205  return numberOfLostHits();
206  }
207 
210  return extra_->seedDirection();
211  }
212 
219  return extra_->seedRef();
220  }
221 
223  const TrackResiduals &residuals() const {return extra_->residuals();}
224 
225 
226 private:
229 
230 };
231 
232 }
233 
234 #endif
235 
const edm::RefToBase< TrajectorySeed > & seedRef() const
Definition: Track.h:218
double t0() const
time at the reference point
Definition: TrackBase.h:720
const Point & referencePoint() const
Reference point on the track.
Definition: TrackBase.h:714
unsigned short lost() const
Number of lost (=invalid) hits on track.
Definition: Track.h:204
~Track() override
virtual destructor
Definition: Track.cc:16
double outerPy() const
y coordinate of momentum vector at the outermost hit position
Definition: Track.h:134
const TrackExtraRef & extra() const
reference to "extra" object
Definition: Track.h:194
TrackExtraRef extra_
Reference to additional information stored only on RECO.
Definition: Track.h:228
size_t recHitsSize() const
Get number of RecHits. (Warning, this includes invalid hits, which are not physical hits)...
Definition: Track.h:124
CovarianceMatrix & fillInner(CovarianceMatrix &v) const
Definition: Track.h:91
double outerP() const
magnitude of momentum vector at the outermost hit position
Definition: Track.h:159
bool innerOk() const
return true if the innermost hit is valid
Definition: Track.h:52
unsigned short numberOfLostHits() const
number of cases where track crossed a layer without getting a hit.
Definition: TrackBase.h:895
PropagationDirection
const Vector & momentum() const
track momentum vector
Definition: TrackBase.h:708
const math::XYZPoint & outerPosition() const
position of the outermost hit
Definition: Track.h:67
Track()
default constructor
Definition: Track.h:34
TrackAlgorithm
track algorithm
Definition: TrackBase.h:99
double outerZ() const
z coordinate of the outermost hit position
Definition: Track.h:154
const math::XYZPoint & innerPosition() const
position of the innermost hit
Definition: Track.h:57
double beta() const
velocity at the reference point in natural units
Definition: TrackBase.h:726
double chi2() const
chi-squared of the fit
Definition: TrackBase.h:582
double ndof() const
number of degrees of freedom of the fit
Definition: TrackBase.h:588
CovarianceMatrix outerStateCovariance() const
outermost trajectory state curvilinear errors
Definition: Track.h:77
unsigned int outerDetId() const
DetId of the detector on which surface the outermost state is located.
Definition: Track.h:96
auto recHits() const
Access to reconstructed hits on the track.
Definition: Track.h:106
#define CMS_THREAD_SAFE
unsigned short numberOfValidHits() const
number of valid hits found
Definition: TrackBase.h:889
double outerX() const
x coordinate of the outermost hit position
Definition: Track.h:144
trackingRecHit_iterator recHitsBegin() const
Iterator to first hit on the track.
Definition: Track.h:109
double outerPz() const
z coordinate of momentum vector at the outermost hit position
Definition: Track.h:139
double outerPt() const
transverse momentum at the outermost hit position
Definition: Track.h:164
double outerRadius() const
polar radius of the outermost hit position
Definition: Track.h:184
double outerEta() const
pseudorapidity of the momentum vector at the outermost hit position
Definition: Track.h:174
void setExtra(const TrackExtraRef &ref)
set reference to "extra" object
Definition: Track.h:189
const math::XYZVector & outerMomentum() const
momentum vector at the outermost hit position
Definition: Track.h:72
bool outerOk() const
return true if the outermost hit is valid
Definition: Track.h:47
const PropagationDirection & seedDirection() const
direction of how the hits were sorted in the original seed
Definition: Track.h:209
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:30
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
CovarianceMatrix innerStateCovariance() const
innermost trajectory state curvilinear errors
Definition: Track.h:82
This class analyses the reconstruction quality for a given track.
Definition: TrackQuality.h:28
bool quality(const TrackQuality) const
Track quality.
Definition: TrackBase.h:543
double covt0t0() const
error on t0
Definition: TrackBase.h:865
fixed size matrix
Structure Point Contains parameters of Gaussian fits to DMRs.
Definition: DMRtrends.cc:55
const math::XYZVector & innerMomentum() const
momentum vector at the innermost hit position
Definition: Track.h:62
TrackingRecHitRef recHit(size_t i) const
Get i-th hit on the track.
Definition: Track.h:119
unsigned short found() const
Number of valid hits on track.
Definition: Track.h:199
double outerY() const
y coordinate of the outermost hit position
Definition: Track.h:149
const TrackResiduals & residuals() const
get the residuals
Definition: Track.h:223
int charge() const
track electric charge
Definition: TrackBase.h:600
double outerTheta() const
polar angle of the momentum vector at the outermost hit position
Definition: Track.h:179
unsigned int innerDetId() const
DetId of the detector on which surface the innermost state is located.
Definition: Track.h:101
math::XYZVector Vector
spatial vector
Definition: TrackBase.h:80
double outerPhi() const
azimuthal angle of the momentum vector at the outermost hit position
Definition: Track.h:169
CovarianceMatrix & fillOuter(CovarianceMatrix &v) const
fill outermost trajectory state curvilinear errors
Definition: Track.h:87
double outerPx() const
x coordinate of momentum vector at the outermost hit position
Definition: Track.h:129
trackingRecHit_iterator recHitsEnd() const
Iterator to last hit on the track.
Definition: Track.h:114