CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Static Public Attributes | Private Attributes
CTPPSPixelLocalTrack Class Reference

#include <CTPPSPixelLocalTrack.h>

Public Types

typedef math::Error< dimension >::type CovarianceMatrix
 
typedef math::Vector< dimension >::type ParameterVector
 covariance matrix size More...
 
enum  TrackPar { TrackPar::x0 = 0, TrackPar::y0 = 1, TrackPar::tx = 2, TrackPar::ty = 3 }
 

Public Member Functions

void addHit (unsigned int detId, const CTPPSPixelFittedRecHit &hit)
 
float chiSquared () const
 
float chiSquaredOverNDF () const
 
const CovarianceMatrixcovarianceMatrix () const
 
 CTPPSPixelLocalTrack ()
 
 CTPPSPixelLocalTrack (float z0, const ParameterVector &track_params_vector, const CovarianceMatrix &par_covariance_matrix, float chiSquared)
 
GlobalVector directionVector () const
 
const edm::DetSetVector< CTPPSPixelFittedRecHit > & hits () const
 
bool isValid () const
 
int ndf () const
 
unsigned short numberOfPointsUsedForFit () const
 
bool operator< (const CTPPSPixelLocalTrack &r)
 
const ParameterVectorparameterVector () const
 
CTPPSpixelLocalTrackReconstructionInfo recoInfo () const
 
void setRecoInfo (CTPPSpixelLocalTrackReconstructionInfo recoInfo)
 
void setValid (bool valid)
 
void setZ0 (float z0)
 
GlobalPoint trackCentrePoint ()
 
GlobalPoint trackPoint (float z) const
 returns the point from which the track is passing by at the selected z More...
 
AlgebraicSymMatrix22 trackPointInterpolationCovariance (float z) const
 
float tx () const
 
float txSigma () const
 
float ty () const
 
float tySigma () const
 
float x0 () const
 
float x0Sigma () const
 
float x0Variance () const
 
float y0 () const
 
float y0Sigma () const
 
float y0Variance () const
 
float z0 () const
 
 ~CTPPSPixelLocalTrack ()
 

Static Public Attributes

static constexpr int covarianceSize = dimension * dimension
 
static constexpr int dimension = 4
 

Private Attributes

float chiSquared_
 fit chi^2 More...
 
int numberOfPointsUsedForFit_
 number of points used for the track fit More...
 
CovarianceMatrix par_covariance_matrix_
 
CTPPSpixelLocalTrackReconstructionInfo recoInfo_
 
edm::DetSetVector< CTPPSPixelFittedRecHittrack_hits_vector_
 
ParameterVector track_params_vector_
 track parameters: (x0, y0, tx, ty); x = x0 + tx*(z-z0) ... More...
 
bool valid_
 fit valid? More...
 
float z0_
 

Detailed Description

Definition at line 84 of file CTPPSPixelLocalTrack.h.

Member Typedef Documentation

◆ CovarianceMatrix

Definition at line 90 of file CTPPSPixelLocalTrack.h.

◆ ParameterVector

covariance matrix size

Definition at line 91 of file CTPPSPixelLocalTrack.h.

Member Enumeration Documentation

◆ TrackPar

Enumerator
x0 
y0 
tx 
ty 

Definition at line 86 of file CTPPSPixelLocalTrack.h.

86 { x0 = 0, y0 = 1, tx = 2, ty = 3 };

Constructor & Destructor Documentation

◆ CTPPSPixelLocalTrack() [1/2]

CTPPSPixelLocalTrack::CTPPSPixelLocalTrack ( )
inline

Definition at line 96 of file CTPPSPixelLocalTrack.h.

◆ CTPPSPixelLocalTrack() [2/2]

CTPPSPixelLocalTrack::CTPPSPixelLocalTrack ( float  z0,
const ParameterVector track_params_vector,
const CovarianceMatrix par_covariance_matrix,
float  chiSquared 
)

Definition at line 27 of file CTPPSPixelLocalTrack.cc.

31  : track_params_vector_(track_params_vector),
32  z0_(z0),
33  par_covariance_matrix_(par_covariance_matrix),
35  valid_(true),

◆ ~CTPPSPixelLocalTrack()

CTPPSPixelLocalTrack::~CTPPSPixelLocalTrack ( )
inline

Definition at line 108 of file CTPPSPixelLocalTrack.h.

108 {}

Member Function Documentation

◆ addHit()

void CTPPSPixelLocalTrack::addHit ( unsigned int  detId,
const CTPPSPixelFittedRecHit hit 
)
inline

◆ chiSquared()

float CTPPSPixelLocalTrack::chiSquared ( ) const
inline

Definition at line 155 of file CTPPSPixelLocalTrack.h.

155 { return chiSquared_; }

References chiSquared_.

◆ chiSquaredOverNDF()

float CTPPSPixelLocalTrack::chiSquaredOverNDF ( ) const
inline

Definition at line 157 of file CTPPSPixelLocalTrack.h.

157  {
159  return -999.;
160  else
162  }

References chiSquared_, dimension, and numberOfPointsUsedForFit_.

Referenced by RPixPlaneCombinatoryTracking::findTracks().

◆ covarianceMatrix()

const CovarianceMatrix& CTPPSPixelLocalTrack::covarianceMatrix ( ) const
inline

Definition at line 153 of file CTPPSPixelLocalTrack.h.

153 { return par_covariance_matrix_; }

References par_covariance_matrix_.

◆ directionVector()

GlobalVector CTPPSPixelLocalTrack::directionVector ( ) const
inline

Definition at line 146 of file CTPPSPixelLocalTrack.h.

146  {
147  GlobalVector vect(tx(), ty(), 1);
148  return vect.unit();
149  }

References tx(), ty(), and Vector3DBase< T, FrameTag >::unit().

◆ hits()

const edm::DetSetVector<CTPPSPixelFittedRecHit>& CTPPSPixelLocalTrack::hits ( ) const
inline

Definition at line 110 of file CTPPSPixelLocalTrack.h.

110 { return track_hits_vector_; }

References track_hits_vector_.

Referenced by RPixPlaneCombinatoryTracking::findTracks().

◆ isValid()

bool CTPPSPixelLocalTrack::isValid ( void  ) const
inline

◆ ndf()

int CTPPSPixelLocalTrack::ndf ( void  ) const
inline

Definition at line 164 of file CTPPSPixelLocalTrack.h.

164 { return (2 * numberOfPointsUsedForFit_ - dimension); }

References dimension, and numberOfPointsUsedForFit_.

Referenced by RPixPlaneCombinatoryTracking::findTracks().

◆ numberOfPointsUsedForFit()

unsigned short CTPPSPixelLocalTrack::numberOfPointsUsedForFit ( ) const
inline

Definition at line 191 of file CTPPSPixelLocalTrack.h.

191 { return numberOfPointsUsedForFit_; }

References numberOfPointsUsedForFit_.

◆ operator<()

bool CTPPSPixelLocalTrack::operator< ( const CTPPSPixelLocalTrack r)

Definition at line 39 of file CTPPSPixelLocalTrack.cc.

39  {
40  if (z0_ < r.z0_)
41  return true;
42  if (z0_ > r.z0_)
43  return false;
44 
45  for (int i = 0; i < CTPPSPixelLocalTrack::dimension; ++i) {
46  if (track_params_vector_[i] < r.track_params_vector_[i])
47  return true;
48  if (track_params_vector_[i] > r.track_params_vector_[i])
49  return false;
50  }
51 
52  return false;
53 }

References dimension, mps_fire::i, alignCSCRings::r, track_params_vector_, and z0_.

◆ parameterVector()

const ParameterVector& CTPPSPixelLocalTrack::parameterVector ( ) const
inline

Definition at line 151 of file CTPPSPixelLocalTrack.h.

151 { return track_params_vector_; }

References track_params_vector_.

◆ recoInfo()

CTPPSpixelLocalTrackReconstructionInfo CTPPSPixelLocalTrack::recoInfo ( ) const
inline

Definition at line 188 of file CTPPSPixelLocalTrack.h.

188 { return recoInfo_; }

References recoInfo_.

Referenced by setRecoInfo().

◆ setRecoInfo()

void CTPPSPixelLocalTrack::setRecoInfo ( CTPPSpixelLocalTrackReconstructionInfo  recoInfo)
inline

Definition at line 189 of file CTPPSPixelLocalTrack.h.

189 { recoInfo_ = recoInfo; }

References recoInfo(), and recoInfo_.

◆ setValid()

void CTPPSPixelLocalTrack::setValid ( bool  valid)
inline

Definition at line 184 of file CTPPSPixelLocalTrack.h.

184 { valid_ = valid; }

References RunInfoPI::valid, and valid_.

Referenced by RPixPlaneCombinatoryTracking::fitTrack().

◆ setZ0()

void CTPPSPixelLocalTrack::setZ0 ( float  z0)
inline

Definition at line 134 of file CTPPSPixelLocalTrack.h.

134 { z0_ = z0; }

References z0(), and z0_.

◆ trackCentrePoint()

GlobalPoint CTPPSPixelLocalTrack::trackCentrePoint ( )
inline

Definition at line 175 of file CTPPSPixelLocalTrack.h.

175  {
176  return GlobalPoint(
177  track_params_vector_[(unsigned int)TrackPar::x0], track_params_vector_[(unsigned int)TrackPar::y0], z0_);
178  }

References track_params_vector_, x0, y0, and z0_.

◆ trackPoint()

GlobalPoint CTPPSPixelLocalTrack::trackPoint ( float  z) const
inline

returns the point from which the track is passing by at the selected z

Definition at line 167 of file CTPPSPixelLocalTrack.h.

167  {
168  float delta_z = z - z0_;
169  return GlobalPoint(
170  track_params_vector_[(unsigned int)TrackPar::x0] + track_params_vector_[(unsigned int)TrackPar::tx] * delta_z,
171  track_params_vector_[(unsigned int)TrackPar::y0] + track_params_vector_[(unsigned int)TrackPar::ty] * delta_z,
172  z);
173  }

References track_params_vector_, tx, ty, x0, y0, z, and z0_.

◆ trackPointInterpolationCovariance()

AlgebraicSymMatrix22 CTPPSPixelLocalTrack::trackPointInterpolationCovariance ( float  z) const

Definition at line 15 of file CTPPSPixelLocalTrack.cc.

15  {
17  h(0, 0) = 1;
18  h(1, 1) = 1;
19  h(0, 2) = z - z0_;
20  h(1, 3) = z - z0_;
21 
22  return ROOT::Math::Similarity(h, par_covariance_matrix_);
23 }

References h, par_covariance_matrix_, z, and z0_.

◆ tx()

float CTPPSPixelLocalTrack::tx ( ) const
inline

Definition at line 136 of file CTPPSPixelLocalTrack.h.

136 { return track_params_vector_[(unsigned int)TrackPar::tx]; }

References createfilelist::int, track_params_vector_, and tx.

Referenced by directionVector().

◆ txSigma()

float CTPPSPixelLocalTrack::txSigma ( ) const
inline

Definition at line 137 of file CTPPSPixelLocalTrack.h.

137  {
138  return sqrt(par_covariance_matrix_[(unsigned int)TrackPar::tx][(unsigned int)TrackPar::tx]);
139  }

References par_covariance_matrix_, mathSSE::sqrt(), and tx.

◆ ty()

float CTPPSPixelLocalTrack::ty ( ) const
inline

Definition at line 141 of file CTPPSPixelLocalTrack.h.

141 { return track_params_vector_[(unsigned int)TrackPar::ty]; }

References createfilelist::int, track_params_vector_, and ty.

Referenced by directionVector().

◆ tySigma()

float CTPPSPixelLocalTrack::tySigma ( ) const
inline

Definition at line 142 of file CTPPSPixelLocalTrack.h.

142  {
143  return sqrt(par_covariance_matrix_[(unsigned int)TrackPar::ty][(unsigned int)TrackPar::ty]);
144  }

References par_covariance_matrix_, mathSSE::sqrt(), and ty.

◆ x0()

float CTPPSPixelLocalTrack::x0 ( ) const
inline

Definition at line 117 of file CTPPSPixelLocalTrack.h.

117 { return track_params_vector_[(unsigned int)TrackPar::x0]; }

References createfilelist::int, track_params_vector_, and x0.

◆ x0Sigma()

float CTPPSPixelLocalTrack::x0Sigma ( ) const
inline

Definition at line 118 of file CTPPSPixelLocalTrack.h.

118  {
119  return sqrt(par_covariance_matrix_[(unsigned int)TrackPar::x0][(unsigned int)TrackPar::x0]);
120  }

References par_covariance_matrix_, mathSSE::sqrt(), and x0.

◆ x0Variance()

float CTPPSPixelLocalTrack::x0Variance ( ) const
inline

Definition at line 121 of file CTPPSPixelLocalTrack.h.

121  {
122  return par_covariance_matrix_[(unsigned int)TrackPar::x0][(unsigned int)TrackPar::x0];
123  }

References createfilelist::int, par_covariance_matrix_, and x0.

◆ y0()

float CTPPSPixelLocalTrack::y0 ( ) const
inline

Definition at line 125 of file CTPPSPixelLocalTrack.h.

125 { return track_params_vector_[(unsigned int)TrackPar::y0]; }

References createfilelist::int, track_params_vector_, and y0.

◆ y0Sigma()

float CTPPSPixelLocalTrack::y0Sigma ( ) const
inline

Definition at line 126 of file CTPPSPixelLocalTrack.h.

126  {
127  return sqrt(par_covariance_matrix_[(unsigned int)TrackPar::y0][(unsigned int)TrackPar::y0]);
128  }

References par_covariance_matrix_, mathSSE::sqrt(), and y0.

◆ y0Variance()

float CTPPSPixelLocalTrack::y0Variance ( ) const
inline

Definition at line 129 of file CTPPSPixelLocalTrack.h.

129  {
130  return par_covariance_matrix_[(unsigned int)TrackPar::y0][(unsigned int)TrackPar::y0];
131  }

References createfilelist::int, par_covariance_matrix_, and y0.

◆ z0()

float CTPPSPixelLocalTrack::z0 ( ) const
inline

Definition at line 133 of file CTPPSPixelLocalTrack.h.

133 { return z0_; }

References z0_.

Referenced by setZ0().

Member Data Documentation

◆ chiSquared_

float CTPPSPixelLocalTrack::chiSquared_
private

fit chi^2

Definition at line 206 of file CTPPSPixelLocalTrack.h.

Referenced by chiSquared(), and chiSquaredOverNDF().

◆ covarianceSize

constexpr int CTPPSPixelLocalTrack::covarianceSize = dimension * dimension
staticconstexpr

Definition at line 94 of file CTPPSPixelLocalTrack.h.

◆ dimension

constexpr int CTPPSPixelLocalTrack::dimension = 4
staticconstexpr

◆ numberOfPointsUsedForFit_

int CTPPSPixelLocalTrack::numberOfPointsUsedForFit_
private

number of points used for the track fit

Definition at line 212 of file CTPPSPixelLocalTrack.h.

Referenced by addHit(), chiSquaredOverNDF(), ndf(), and numberOfPointsUsedForFit().

◆ par_covariance_matrix_

CovarianceMatrix CTPPSPixelLocalTrack::par_covariance_matrix_
private

◆ recoInfo_

CTPPSpixelLocalTrackReconstructionInfo CTPPSPixelLocalTrack::recoInfo_
private

Definition at line 214 of file CTPPSPixelLocalTrack.h.

Referenced by recoInfo(), and setRecoInfo().

◆ track_hits_vector_

edm::DetSetVector<CTPPSPixelFittedRecHit> CTPPSPixelLocalTrack::track_hits_vector_
private

Definition at line 194 of file CTPPSPixelLocalTrack.h.

Referenced by addHit(), and hits().

◆ track_params_vector_

ParameterVector CTPPSPixelLocalTrack::track_params_vector_
private

track parameters: (x0, y0, tx, ty); x = x0 + tx*(z-z0) ...

Definition at line 197 of file CTPPSPixelLocalTrack.h.

Referenced by operator<(), parameterVector(), trackCentrePoint(), trackPoint(), tx(), ty(), x0(), and y0().

◆ valid_

bool CTPPSPixelLocalTrack::valid_
private

fit valid?

Definition at line 209 of file CTPPSPixelLocalTrack.h.

Referenced by isValid(), and setValid().

◆ z0_

float CTPPSPixelLocalTrack::z0_
private

z where x0 and y0 are evaluated. filled from TotemRPGeometry::GetRPGlobalTranslation

Definition at line 201 of file CTPPSPixelLocalTrack.h.

Referenced by operator<(), setZ0(), trackCentrePoint(), trackPoint(), trackPointInterpolationCovariance(), and z0().

Vector3DBase
Definition: Vector3DBase.h:8
edm::DetSet::push_back
void push_back(const T &t)
Definition: DetSet.h:66
mps_fire.i
i
Definition: mps_fire.py:428
CTPPSPixelLocalTrack::x0
float x0() const
Definition: CTPPSPixelLocalTrack.h:117
CTPPSPixelLocalTrack::recoInfo
CTPPSpixelLocalTrackReconstructionInfo recoInfo() const
Definition: CTPPSPixelLocalTrack.h:188
CTPPSPixelLocalTrack::dimension
static constexpr int dimension
Definition: CTPPSPixelLocalTrack.h:89
CTPPSPixelLocalTrack::chiSquared_
float chiSquared_
fit chi^2
Definition: CTPPSPixelLocalTrack.h:206
CTPPSpixelLocalTrackReconstructionInfo::invalid
h
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
CTPPSPixelLocalTrack::z0
float z0() const
Definition: CTPPSPixelLocalTrack.h:133
CTPPSPixelLocalTrack::z0_
float z0_
Definition: CTPPSPixelLocalTrack.h:201
CTPPSPixelLocalTrack::track_params_vector_
ParameterVector track_params_vector_
track parameters: (x0, y0, tx, ty); x = x0 + tx*(z-z0) ...
Definition: CTPPSPixelLocalTrack.h:197
math::Matrix::type
ROOT::Math::SMatrix< double, N, M > type
Definition: Matrix.h:9
CTPPSPixelLocalTrack::track_hits_vector_
edm::DetSetVector< CTPPSPixelFittedRecHit > track_hits_vector_
Definition: CTPPSPixelLocalTrack.h:194
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
DDAxes::z
CTPPSPixelLocalTrack::tx
float tx() const
Definition: CTPPSPixelLocalTrack.h:136
h
GlobalPoint
Global3DPoint GlobalPoint
Definition: GlobalPoint.h:10
CTPPSPixelLocalTrack::TrackPar::y0
CTPPSPixelLocalTrack::par_covariance_matrix_
CovarianceMatrix par_covariance_matrix_
Definition: CTPPSPixelLocalTrack.h:203
CTPPSPixelLocalTrack::chiSquared
float chiSquared() const
Definition: CTPPSPixelLocalTrack.h:155
createfilelist.int
int
Definition: createfilelist.py:10
alignCSCRings.r
r
Definition: alignCSCRings.py:93
CTPPSPixelLocalTrack::valid_
bool valid_
fit valid?
Definition: CTPPSPixelLocalTrack.h:209
CTPPSPixelLocalTrack::y0
float y0() const
Definition: CTPPSPixelLocalTrack.h:125
CTPPSPixelLocalTrack::TrackPar::tx
CTPPSPixelLocalTrack::recoInfo_
CTPPSpixelLocalTrackReconstructionInfo recoInfo_
Definition: CTPPSPixelLocalTrack.h:214
edm::DetSetVector::find_or_insert
reference find_or_insert(det_id_type id)
Definition: DetSetVector.h:234
RunInfoPI::valid
Definition: RunInfoPayloadInspectoHelper.h:16
CTPPSPixelLocalTrack::TrackPar::ty
CTPPSPixelLocalTrack::ty
float ty() const
Definition: CTPPSPixelLocalTrack.h:141
CTPPSPixelLocalTrack::numberOfPointsUsedForFit_
int numberOfPointsUsedForFit_
number of points used for the track fit
Definition: CTPPSPixelLocalTrack.h:212
CTPPSPixelLocalTrack::TrackPar::x0
hit
Definition: SiStripHitEffFromCalibTree.cc:88