CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
reco::TrackExtra Class Reference

#include <DataFormats/TrackReco/interface/TrackExtra.h>

Inheritance diagram for reco::TrackExtra:
reco::TrackExtraBase

Public Types

enum  { dimension = 5 }
 tracker parameter dimension More...
 
enum  { covarianceSize = dimension * (dimension + 1) / 2 }
 track error matrix size More...
 
typedef math::Error< 5 >::type CovarianceMatrix
 5 parameter covariance matrix More...
 
typedef unsigned int index
 index type More...
 
typedef math::XYZPoint Point
 point in the space More...
 
typedef math::XYZVector Vector
 spatial vector More...
 
- Public Types inherited from reco::TrackExtraBase
using Chi2sFive = std::vector< unsigned char >
 
using TrajParams = std::vector< LocalTrajectoryParameters >
 

Public Member Functions

CovarianceMatrixfillInner (CovarianceMatrix &v) const
 fill outermost trajectory state curvilinear errors More...
 
CovarianceMatrixfillOuter (CovarianceMatrix &v) const
 fill outermost trajectory state curvilinear errors More...
 
unsigned int innerDetId () const
 DetId of the detector on which surface the innermost state is located. More...
 
const VectorinnerMomentum () const
 momentum vector at innermost hit position More...
 
bool innerOk () const
 returns true if the innermost hit is valid More...
 
const PointinnerPosition () const
 innermost hit position More...
 
CovarianceMatrix innerStateCovariance () const
 innermost trajectory state curvilinear errors More...
 
unsigned int outerDetId () const
 DetId of the detector on which surface the outermost state is located. More...
 
double outerEta () const
 pseudorapidity the momentum vector at the outermost hit position More...
 
const VectorouterMomentum () const
 momentum vector at outermost hit position More...
 
bool outerOk () const
 returns true if the outermost hit is valid More...
 
double outerP () const
 magnitude of momentum vector at the outermost hit position More...
 
double outerPhi () const
 azimuthal angle of the momentum vector at the outermost hit position More...
 
const PointouterPosition () const
 outermost hit position More...
 
double outerPt () const
 transverse momentum at the outermost hit position More...
 
double outerPx () const
 x coordinate of momentum vector at the outermost hit position More...
 
double outerPy () const
 y coordinate of momentum vector at the outermost hit position More...
 
double outerPz () const
 z coordinate of momentum vector at the outermost hit position More...
 
double outerRadius () const
 polar radius of the outermost hit position More...
 
CovarianceMatrix outerStateCovariance () const
 outermost trajectory state curvilinear errors More...
 
double outerTheta () const
 polar angle of the momentum vector at the outermost hit position More...
 
double outerX () const
 x coordinate the outermost hit position More...
 
double outerY () const
 y coordinate the outermost hit position More...
 
double outerZ () const
 z coordinate the outermost hit position More...
 
const TrackResidualsresiduals () const
 get the residuals More...
 
const PropagationDirectionseedDirection () const
 
const edm::RefToBase< TrajectorySeed > & seedRef () const
 
void setResiduals (const TrackResiduals &r)
 set the residuals More...
 
void setSeedRef (const edm::RefToBase< TrajectorySeed > &r)
 
 TrackExtra ()
 default constructor More...
 
 TrackExtra (const Point &outerPosition, const Vector &outerMomentum, bool ok, const Point &innerPosition, const Vector &innerMomentum, bool iok, const CovarianceMatrix &outerState, unsigned int outerId, const CovarianceMatrix &innerState, unsigned int innerId, PropagationDirection seedDir, edm::RefToBase< TrajectorySeed > seedRef=edm::RefToBase< TrajectorySeed >())
 constructor from outermost/innermost position and momentum and Seed information More...
 
- Public Member Functions inherited from reco::TrackExtraBase
Chi2sFive const & chi2sX5 () const
 
unsigned int firstRecHit () const
 
TrackingRecHitRef recHit (unsigned int i) const
 get i-th recHit More...
 
TrackingRecHitRef recHitRef (unsigned int i) const
 get a ref to i-th recHit More...
 
auto recHits () const
 accessor to RecHits More...
 
trackingRecHit_iterator recHitsBegin () const
 first iterator over RecHits More...
 
trackingRecHit_iterator recHitsEnd () const
 last iterator over RecHits More...
 
TrackingRecHitCollection const & recHitsProduct () const
 
unsigned int recHitsSize () const
 number of RecHits More...
 
void setHits (TrackingRecHitRefProd const &prod, unsigned firstH, unsigned int nH)
 
void setTrajParams (TrajParams tmps, Chi2sFive chi2s)
 
 TrackExtraBase ()
 default constructor More...
 
TrajParams const & trajParams () const
 

Private Attributes

float innerCovariance_ [covarianceSize]
 innermost trajectory state More...
 
unsigned int innerDetId_
 
Vector innerMomentum_
 momentum vector at innermost hit position More...
 
bool innerOk_
 innermost hit validity flag More...
 
Point innerPosition_
 innermost hit position More...
 
float outerCovariance_ [covarianceSize]
 outermost trajectory state curvilinear errors More...
 
unsigned int outerDetId_
 
Vector outerMomentum_
 momentum vector at outermost hit position More...
 
bool outerOk_
 outermost hit validity flag More...
 
Point outerPosition_
 outermost hit position More...
 
PropagationDirection seedDir_
 
edm::RefToBase< TrajectorySeedseedRef_
 
TrackResiduals trackResiduals_
 unbiased track residuals More...
 

Detailed Description

Additional information about a reconstructed track. It is stored in RECO and supplements the basic information stored in the Track class that is stored on AOD only. If you wish to use information in the TrackExtra class, you should access it via the reference supplied in the Track class.

Author
Luca Lista, INFN

Definition at line 26 of file TrackExtra.h.

Member Typedef Documentation

◆ CovarianceMatrix

5 parameter covariance matrix

Definition at line 37 of file TrackExtra.h.

◆ index

typedef unsigned int reco::TrackExtra::index

index type

Definition at line 39 of file TrackExtra.h.

◆ Point

point in the space

Definition at line 33 of file TrackExtra.h.

◆ Vector

spatial vector

Definition at line 35 of file TrackExtra.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

tracker parameter dimension

Enumerator
dimension 

Definition at line 29 of file TrackExtra.h.

29 { dimension = 5 };

◆ anonymous enum

anonymous enum

track error matrix size

Enumerator
covarianceSize 

Definition at line 31 of file TrackExtra.h.

31 { covarianceSize = dimension * (dimension + 1) / 2 };

Constructor & Destructor Documentation

◆ TrackExtra() [1/2]

reco::TrackExtra::TrackExtra ( )
inline

default constructor

Definition at line 42 of file TrackExtra.h.

43  : outerMomentum_(),
44  outerOk_(false),
45  outerDetId_(0),
48  innerOk_(false),
49  innerDetId_(0),
51  seedRef_() {
52  for (index i = 0; i < covarianceSize; ++i) {
53  outerCovariance_[i] = 0;
54  innerCovariance_[i] = 0;
55  }
56  }

References covarianceSize, mps_fire::i, innerCovariance_, and outerCovariance_.

◆ TrackExtra() [2/2]

TrackExtra::TrackExtra ( const Point outerPosition,
const Vector outerMomentum,
bool  ok,
const Point innerPosition,
const Vector innerMomentum,
bool  iok,
const CovarianceMatrix outerState,
unsigned int  outerId,
const CovarianceMatrix innerState,
unsigned int  innerId,
PropagationDirection  seedDir,
edm::RefToBase< TrajectorySeed seedRef = edm::RefToBase<TrajectorySeed>() 
)

constructor from outermost/innermost position and momentum and Seed information

Definition at line 6 of file TrackExtra.cc.

18  :
19 
23  outerOk_(ok),
24  outerDetId_(outerId),
27  innerOk_(iok),
28  innerDetId_(innerId),
29  seedDir_(seedDir),
30  seedRef_(seedRef) {
31  index idx = 0;
32  for (index i = 0; i < dimension; ++i) {
33  for (index j = 0; j <= i; ++j) {
34  outerCovariance_[idx] = outerCov(i, j);
35  innerCovariance_[idx] = innerCov(i, j);
36  ++idx;
37  }
38  }
39 }

References dimension, mps_fire::i, heavyIonCSV_trainingSettings::idx, innerCovariance_, dqmiolumiharvest::j, and outerCovariance_.

Member Function Documentation

◆ fillInner()

TrackExtra::CovarianceMatrix & TrackExtra::fillInner ( CovarianceMatrix v) const

fill outermost trajectory state curvilinear errors

Definition at line 57 of file TrackExtra.cc.

57  {
59 }

References reco::fillCovariance(), innerCovariance_, and findQualityFiles::v.

◆ fillOuter()

TrackExtra::CovarianceMatrix & TrackExtra::fillOuter ( CovarianceMatrix v) const

fill outermost trajectory state curvilinear errors

Definition at line 53 of file TrackExtra.cc.

53  {
55 }

References reco::fillCovariance(), outerCovariance_, and findQualityFiles::v.

◆ innerDetId()

unsigned int reco::TrackExtra::innerDetId ( ) const
inline

DetId of the detector on which surface the innermost state is located.

Definition at line 120 of file TrackExtra.h.

120 { return innerDetId_; }

References innerDetId_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ innerMomentum()

const Vector& reco::TrackExtra::innerMomentum ( ) const
inline

momentum vector at innermost hit position

Definition at line 81 of file TrackExtra.h.

81 { return innerMomentum_; }

References innerMomentum_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ innerOk()

bool reco::TrackExtra::innerOk ( ) const
inline

returns true if the innermost hit is valid

Definition at line 83 of file TrackExtra.h.

83 { return innerOk_; }

References innerOk_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ innerPosition()

const Point& reco::TrackExtra::innerPosition ( ) const
inline

innermost hit position

Definition at line 79 of file TrackExtra.h.

79 { return innerPosition_; }

References innerPosition_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ innerStateCovariance()

TrackExtra::CovarianceMatrix TrackExtra::innerStateCovariance ( ) const

innermost trajectory state curvilinear errors

Definition at line 47 of file TrackExtra.cc.

47  {
50  return v;
51 }

References reco::fillCovariance(), innerCovariance_, and findQualityFiles::v.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ outerDetId()

unsigned int reco::TrackExtra::outerDetId ( ) const
inline

DetId of the detector on which surface the outermost state is located.

Definition at line 118 of file TrackExtra.h.

118 { return outerDetId_; }

References outerDetId_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ outerEta()

double reco::TrackExtra::outerEta ( ) const
inline

pseudorapidity the momentum vector at the outermost hit position

Definition at line 103 of file TrackExtra.h.

103 { return outerMomentum().Eta(); }

References outerMomentum().

◆ outerMomentum()

const Vector& reco::TrackExtra::outerMomentum ( ) const
inline

momentum vector at outermost hit position

Definition at line 75 of file TrackExtra.h.

75 { return outerMomentum_; }

References outerMomentum_.

Referenced by outerEta(), outerP(), outerPhi(), outerPt(), outerTheta(), and MuonReducedTrackExtraProducer::produce().

◆ outerOk()

bool reco::TrackExtra::outerOk ( ) const
inline

returns true if the outermost hit is valid

Definition at line 77 of file TrackExtra.h.

77 { return outerOk_; }

References outerOk_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ outerP()

double reco::TrackExtra::outerP ( ) const
inline

magnitude of momentum vector at the outermost hit position

Definition at line 97 of file TrackExtra.h.

97 { return outerMomentum().R(); }

References outerMomentum().

◆ outerPhi()

double reco::TrackExtra::outerPhi ( ) const
inline

azimuthal angle of the momentum vector at the outermost hit position

Definition at line 101 of file TrackExtra.h.

101 { return outerMomentum().Phi(); }

References outerMomentum().

◆ outerPosition()

const Point& reco::TrackExtra::outerPosition ( ) const
inline

outermost hit position

Definition at line 73 of file TrackExtra.h.

73 { return outerPosition_; }

References outerPosition_.

Referenced by outerRadius(), and MuonReducedTrackExtraProducer::produce().

◆ outerPt()

double reco::TrackExtra::outerPt ( ) const
inline

transverse momentum at the outermost hit position

Definition at line 99 of file TrackExtra.h.

99 { return outerMomentum().Rho(); }

References outerMomentum().

◆ outerPx()

double reco::TrackExtra::outerPx ( ) const
inline

x coordinate of momentum vector at the outermost hit position

Definition at line 85 of file TrackExtra.h.

85 { return outerMomentum_.X(); }

References outerMomentum_.

◆ outerPy()

double reco::TrackExtra::outerPy ( ) const
inline

y coordinate of momentum vector at the outermost hit position

Definition at line 87 of file TrackExtra.h.

87 { return outerMomentum_.Y(); }

References outerMomentum_.

◆ outerPz()

double reco::TrackExtra::outerPz ( ) const
inline

z coordinate of momentum vector at the outermost hit position

Definition at line 89 of file TrackExtra.h.

89 { return outerMomentum_.Z(); }

References outerMomentum_.

◆ outerRadius()

double reco::TrackExtra::outerRadius ( ) const
inline

polar radius of the outermost hit position

Definition at line 107 of file TrackExtra.h.

107 { return outerPosition().Rho(); }

References outerPosition().

◆ outerStateCovariance()

TrackExtra::CovarianceMatrix TrackExtra::outerStateCovariance ( ) const

outermost trajectory state curvilinear errors

Definition at line 41 of file TrackExtra.cc.

41  {
44  return v;
45 }

References reco::fillCovariance(), outerCovariance_, and findQualityFiles::v.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ outerTheta()

double reco::TrackExtra::outerTheta ( ) const
inline

polar angle of the momentum vector at the outermost hit position

Definition at line 105 of file TrackExtra.h.

105 { return outerMomentum().Theta(); }

References outerMomentum().

◆ outerX()

double reco::TrackExtra::outerX ( ) const
inline

x coordinate the outermost hit position

Definition at line 91 of file TrackExtra.h.

91 { return outerPosition_.X(); }

References outerPosition_.

◆ outerY()

double reco::TrackExtra::outerY ( ) const
inline

y coordinate the outermost hit position

Definition at line 93 of file TrackExtra.h.

93 { return outerPosition_.Y(); }

References outerPosition_.

◆ outerZ()

double reco::TrackExtra::outerZ ( ) const
inline

z coordinate the outermost hit position

Definition at line 95 of file TrackExtra.h.

95 { return outerPosition_.Z(); }

References outerPosition_.

◆ residuals()

const TrackResiduals& reco::TrackExtra::residuals ( ) const
inline

get the residuals

Definition at line 135 of file TrackExtra.h.

135 { return trackResiduals_; }

References trackResiduals_.

◆ seedDirection()

const PropagationDirection& reco::TrackExtra::seedDirection ( ) const
inline

Definition at line 122 of file TrackExtra.h.

122 { return seedDir_; }

References seedDir_.

Referenced by MuonReducedTrackExtraProducer::produce().

◆ seedRef()

const edm::RefToBase<TrajectorySeed>& reco::TrackExtra::seedRef ( ) const
inline

return the edm::reference to the trajectory seed in the original seeds collection. If the collection has been dropped from the Event, the reference may be invalid. Its validity should be tested, before the reference is actually used.

Definition at line 129 of file TrackExtra.h.

129 { return seedRef_; }

References seedRef_.

Referenced by MuonReducedTrackExtraProducer::produce(), and ExtraFromSeeds::produce().

◆ setResiduals()

void reco::TrackExtra::setResiduals ( const TrackResiduals r)
inline

◆ setSeedRef()

void reco::TrackExtra::setSeedRef ( const edm::RefToBase< TrajectorySeed > &  r)
inline

Definition at line 130 of file TrackExtra.h.

130 { seedRef_ = r; }

References alignCSCRings::r, and seedRef_.

Member Data Documentation

◆ innerCovariance_

float reco::TrackExtra::innerCovariance_[covarianceSize]
private

innermost trajectory state

Definition at line 155 of file TrackExtra.h.

Referenced by fillInner(), innerStateCovariance(), and TrackExtra().

◆ innerDetId_

unsigned int reco::TrackExtra::innerDetId_
private

Definition at line 156 of file TrackExtra.h.

Referenced by innerDetId().

◆ innerMomentum_

Vector reco::TrackExtra::innerMomentum_
private

momentum vector at innermost hit position

Definition at line 151 of file TrackExtra.h.

Referenced by innerMomentum().

◆ innerOk_

bool reco::TrackExtra::innerOk_
private

innermost hit validity flag

Definition at line 153 of file TrackExtra.h.

Referenced by innerOk().

◆ innerPosition_

Point reco::TrackExtra::innerPosition_
private

innermost hit position

Definition at line 149 of file TrackExtra.h.

Referenced by innerPosition().

◆ outerCovariance_

float reco::TrackExtra::outerCovariance_[covarianceSize]
private

outermost trajectory state curvilinear errors

Definition at line 145 of file TrackExtra.h.

Referenced by fillOuter(), outerStateCovariance(), and TrackExtra().

◆ outerDetId_

unsigned int reco::TrackExtra::outerDetId_
private

Definition at line 146 of file TrackExtra.h.

Referenced by outerDetId().

◆ outerMomentum_

Vector reco::TrackExtra::outerMomentum_
private

momentum vector at outermost hit position

Definition at line 141 of file TrackExtra.h.

Referenced by outerMomentum(), outerPx(), outerPy(), and outerPz().

◆ outerOk_

bool reco::TrackExtra::outerOk_
private

outermost hit validity flag

Definition at line 143 of file TrackExtra.h.

Referenced by outerOk().

◆ outerPosition_

Point reco::TrackExtra::outerPosition_
private

outermost hit position

Definition at line 139 of file TrackExtra.h.

Referenced by outerPosition(), outerX(), outerY(), and outerZ().

◆ seedDir_

PropagationDirection reco::TrackExtra::seedDir_
private

Definition at line 158 of file TrackExtra.h.

Referenced by seedDirection().

◆ seedRef_

edm::RefToBase<TrajectorySeed> reco::TrackExtra::seedRef_
private

Definition at line 159 of file TrackExtra.h.

Referenced by seedRef(), and setSeedRef().

◆ trackResiduals_

TrackResiduals reco::TrackExtra::trackResiduals_
private

unbiased track residuals

Definition at line 162 of file TrackExtra.h.

Referenced by residuals(), and setResiduals().

reco::TrackExtra::trackResiduals_
TrackResiduals trackResiduals_
unbiased track residuals
Definition: TrackExtra.h:162
reco::TrackExtra::innerDetId_
unsigned int innerDetId_
Definition: TrackExtra.h:156
mps_fire.i
i
Definition: mps_fire.py:428
anyDirection
Definition: PropagationDirection.h:4
reco::TrackExtra::innerMomentum_
Vector innerMomentum_
momentum vector at innermost hit position
Definition: TrackExtra.h:151
reco::TrackExtra::covarianceSize
Definition: TrackExtra.h:31
CovarianceMatrix
Definition: CovarianceMatrix.h:28
reco::TrackExtraBase::TrackExtraBase
TrackExtraBase()
default constructor
Definition: TrackExtraBase.h:28
reco::TrackExtra::dimension
Definition: TrackExtra.h:29
findQualityFiles.v
v
Definition: findQualityFiles.py:179
convertSQLiteXML.ok
bool ok
Definition: convertSQLiteXML.py:98
reco::TrackExtra::outerMomentum
const Vector & outerMomentum() const
momentum vector at outermost hit position
Definition: TrackExtra.h:75
heavyIonCSV_trainingSettings.idx
idx
Definition: heavyIonCSV_trainingSettings.py:5
reco::TrackExtra::seedRef_
edm::RefToBase< TrajectorySeed > seedRef_
Definition: TrackExtra.h:159
reco::TrackExtra::innerMomentum
const Vector & innerMomentum() const
momentum vector at innermost hit position
Definition: TrackExtra.h:81
reco::TrackExtra::outerOk_
bool outerOk_
outermost hit validity flag
Definition: TrackExtra.h:143
reco::fillCovariance
PerigeeCovarianceMatrix & fillCovariance(PerigeeCovarianceMatrix &v, const float *data)
Definition: fillCovariance.cc:5
reco::TrackExtra::outerMomentum_
Vector outerMomentum_
momentum vector at outermost hit position
Definition: TrackExtra.h:141
reco::TrackExtra::outerPosition
const Point & outerPosition() const
outermost hit position
Definition: TrackExtra.h:73
reco::TrackExtra::outerPosition_
Point outerPosition_
outermost hit position
Definition: TrackExtra.h:139
alignCSCRings.r
r
Definition: alignCSCRings.py:93
reco::TrackExtra::index
unsigned int index
index type
Definition: TrackExtra.h:39
reco::TrackExtra::innerOk_
bool innerOk_
innermost hit validity flag
Definition: TrackExtra.h:153
reco::TrackExtra::seedDir_
PropagationDirection seedDir_
Definition: TrackExtra.h:158
reco::TrackExtra::outerCovariance_
float outerCovariance_[covarianceSize]
outermost trajectory state curvilinear errors
Definition: TrackExtra.h:145
reco::TrackExtra::seedRef
const edm::RefToBase< TrajectorySeed > & seedRef() const
Definition: TrackExtra.h:129
reco::TrackExtra::innerPosition_
Point innerPosition_
innermost hit position
Definition: TrackExtra.h:149
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
reco::TrackExtra::innerPosition
const Point & innerPosition() const
innermost hit position
Definition: TrackExtra.h:79
reco::TrackExtra::innerCovariance_
float innerCovariance_[covarianceSize]
innermost trajectory state
Definition: TrackExtra.h:155
reco::TrackExtra::outerDetId_
unsigned int outerDetId_
Definition: TrackExtra.h:146