LDMX Software
Public Member Functions | Private Member Functions | Private Attributes | List of all members
ldmx::TrigScintTrack Class Reference

Represents a track of trigger scintillator clusters. More...

#include <TrigScintTrack.h>

Public Member Functions

 TrigScintTrack ()
 Class constructor.
 
virtual ~TrigScintTrack ()
 Class destructor.
 
void Print () const
 Print a description of this object.
 
void Clear ()
 Reset the TrigScintTrack object.
 
float getCentroid () const
 Get the detector ID centroid of the track.
 
float getCentroidX () const
 Get the x centroid of the track.
 
float getCentroidY () const
 Get the y centroid of the track.
 
float getCentroidZ () const
 Get the z centroid of the track.
 
float getResidual () const
 Get the detector ID residual of the track.
 
float getResidualX () const
 Get the x residual of the track.
 
float getResidualY () const
 Get the y residual of the track.
 
float getResidualZ () const
 Get the z residual of the track.
 
float getPE () const
 Get the (average) pe of the track.
 
int getNclusters () const
 Get the number of clusters forming the track.
 
float getX () const
 Get the x coordinate of the track.
 
float getY () const
 Get the y coordinate of the track.
 
float getSigmaX () const
 Get the uncertainty on the x coordinate of the track.
 
float getSigmaY () const
 Get the uncertainty on the y coordinate of the track.
 
std::vector< ldmx::TrigScintClustergetConstituents () const
 Get the cluster constituents of the track.
 
std::vector< double > getMomentum () const
 Get the XYZ momentum of the particle at the position at which the track took place [MeV].
 
float getBeamEfrac () const
 Get beam energy fraction of hit.
 
void setBeamEfrac (float e)
 Set beam energy fraction of hit.
 
void setCentroid (float centroid)
 Set the detector ID centroid of the track.
 
void setCentroidX (float centroid)
 Set the x centroid of the track.
 
void setCentroidY (float centroid)
 Set the y centroid of the track.
 
void setCentroidZ (float centroid)
 Set the z centroid of the track.
 
void setResidual (float resid)
 Set the detector ID residual of the track.
 
void setResidualX (float resid)
 Set the x residual of the track.
 
void setResidualY (float resid)
 Set the y residual of the track.
 
void setResidualZ (float resid)
 Set the z residual of the track.
 
void setPE (float pe)
 Set the average cluster pe of the track.
 
void setNclusters (uint nCl)
 Set the number of clusters forming the track.
 
void addConstituent (TrigScintCluster cl)
 Add a cluster to the list of track constituents.
 
void setPosition (const float x, const float y)
 Set the position of the track [mm].
 
void setSigmaXY (const float sx, const float sy)
 Set the uncertainty on the position of the track [mm].
 
void setSigmaX (const float sx)
 Set the uncertainty on the position of the track [mm].
 
void setSigmaY (const float sy)
 Set the uncertainty on the position of the track [mm].
 
void setMomentum (const float px, const float py, const float pz)
 Set the momentum of the particle at the position at which the track took place [GeV].
 
bool operator< (const TrigScintTrack &rhs) const
 Sort by track residual.
 

Private Member Functions

 ClassDef (TrigScintTrack, 2)
 The ROOT class definition.
 

Private Attributes

float centroid_ {-1}
 The detector centroid.
 
float centroidX_ {-1}
 The detector x coordinate centroid.
 
float centroidY_ {-1}
 The detector y coordinate centroid.
 
float centroidZ_ {-99999}
 The detector z coordinate centroid.
 
float residual_ {0}
 The detector residual.
 
float residualX_ {0}
 The x coordinate residual.
 
float residualY_ {0}
 The y coordinate residual.
 
float residualZ_ {0}
 The z coordinate residual.
 
int nClusters_ {0}
 The number of clusters forming the track.
 
std::vector< ldmx::TrigScintClusterconstituents_ {0}
 The list of clusters constituting the track.
 
float beamEfrac_ {0.}
 The fraction of the energy deposited in the track constituents that was deposited by a beam electron.
 
float PE_ {0.}
 The average pe count of the clusters making up the track.
 
float x_ {-99999.}
 The X position.
 
float y_ {-99999.}
 The Y position.
 
float sx_ {-9999.}
 The uncertainty on the X position.
 
float sy_ {-9999.}
 The uncertainty on the Y position.
 
float px_ {0}
 The X momentum.
 
float py_ {0}
 The Y momentum.
 
float pz_ {0}
 The Z momentum.
 
float z_ {0}
 The Z position.
 

Detailed Description

Represents a track of trigger scintillator clusters.

Definition at line 21 of file TrigScintTrack.h.

Constructor & Destructor Documentation

◆ TrigScintTrack()

ldmx::TrigScintTrack::TrigScintTrack ( )
inline

Class constructor.

Definition at line 26 of file TrigScintTrack.h.

26{};

◆ ~TrigScintTrack()

virtual ldmx::TrigScintTrack::~TrigScintTrack ( )
inlinevirtual

Class destructor.

Definition at line 31 of file TrigScintTrack.h.

31{};

Member Function Documentation

◆ addConstituent()

void ldmx::TrigScintTrack::addConstituent ( TrigScintCluster  cl)
inline

Add a cluster to the list of track constituents.

Definition at line 203 of file TrigScintTrack.h.

203{ constituents_.push_back(cl); };
std::vector< ldmx::TrigScintCluster > constituents_
The list of clusters constituting the track.

References constituents_.

◆ getBeamEfrac()

float ldmx::TrigScintTrack::getBeamEfrac ( ) const
inline

Get beam energy fraction of hit.

Definition at line 143 of file TrigScintTrack.h.

143{ return beamEfrac_; }
float beamEfrac_
The fraction of the energy deposited in the track constituents that was deposited by a beam electron.

References beamEfrac_.

◆ getCentroid()

float ldmx::TrigScintTrack::getCentroid ( ) const
inline

Get the detector ID centroid of the track.

Returns
The detector ID centroid of the track. `

Definition at line 47 of file TrigScintTrack.h.

47{ return centroid_; };
float centroid_
The detector centroid.

References centroid_.

Referenced by trigscint::TrigScintTrackProducer::produce().

◆ getCentroidX()

float ldmx::TrigScintTrack::getCentroidX ( ) const
inline

Get the x centroid of the track.

Returns
The x centroid of the track in units of bars.

Definition at line 53 of file TrigScintTrack.h.

53{ return centroidX_; };
float centroidX_
The detector x coordinate centroid.

References centroidX_.

◆ getCentroidY()

float ldmx::TrigScintTrack::getCentroidY ( ) const
inline

Get the y centroid of the track.

Returns
The y centroid of the track in units of bars.

Definition at line 59 of file TrigScintTrack.h.

59{ return centroidY_; };
float centroidY_
The detector y coordinate centroid.

References centroidY_.

◆ getCentroidZ()

float ldmx::TrigScintTrack::getCentroidZ ( ) const
inline

Get the z centroid of the track.

Returns
The z centroid of the track.

Definition at line 65 of file TrigScintTrack.h.

65{ return centroidZ_; };
float centroidZ_
The detector z coordinate centroid.

References centroidZ_.

◆ getConstituents()

std::vector< ldmx::TrigScintCluster > ldmx::TrigScintTrack::getConstituents ( ) const
inline

Get the cluster constituents of the track.

Returns
The list of track constituents.

Definition at line 131 of file TrigScintTrack.h.

131 {
132 return constituents_;
133 };

References constituents_.

Referenced by trigscint::TrigScintTrackProducer::produce().

◆ getMomentum()

std::vector< double > ldmx::TrigScintTrack::getMomentum ( ) const
inline

Get the XYZ momentum of the particle at the position at which the track took place [MeV].

Returns
The momentum of the particle.

Definition at line 140 of file TrigScintTrack.h.

140{ return {px_, py_, pz_}; };
float pz_
The Z momentum.
float py_
The Y momentum.
float px_
The X momentum.

References px_, py_, and pz_.

◆ getNclusters()

int ldmx::TrigScintTrack::getNclusters ( ) const
inline

Get the number of clusters forming the track.

Returns
The number of clusters in the track.

Definition at line 101 of file TrigScintTrack.h.

101{ return nClusters_; };
int nClusters_
The number of clusters forming the track.

References nClusters_.

◆ getPE()

float ldmx::TrigScintTrack::getPE ( ) const
inline

Get the (average) pe of the track.

Returns
The cluster pe count averaged over the track.

Definition at line 95 of file TrigScintTrack.h.

95{ return PE_; };
float PE_
The average pe count of the clusters making up the track.

References PE_.

◆ getResidual()

float ldmx::TrigScintTrack::getResidual ( ) const
inline

Get the detector ID residual of the track.

Returns
The detector ID residual of the track.

Definition at line 71 of file TrigScintTrack.h.

71{ return residual_; };
float residual_
The detector residual.

References residual_.

Referenced by operator<().

◆ getResidualX()

float ldmx::TrigScintTrack::getResidualX ( ) const
inline

Get the x residual of the track.

Returns
The x residual of the track.

Definition at line 77 of file TrigScintTrack.h.

77{ return residualX_; };
float residualX_
The x coordinate residual.

References residualX_.

◆ getResidualY()

float ldmx::TrigScintTrack::getResidualY ( ) const
inline

Get the y residual of the track.

Returns
The y residual of the track.

Definition at line 83 of file TrigScintTrack.h.

83{ return residualY_; };
float residualY_
The y coordinate residual.

References residualY_.

◆ getResidualZ()

float ldmx::TrigScintTrack::getResidualZ ( ) const
inline

Get the z residual of the track.

Returns
The z residual of the track.

Definition at line 89 of file TrigScintTrack.h.

89{ return residualZ_; };
float residualZ_
The z coordinate residual.

References residualZ_.

◆ getSigmaX()

float ldmx::TrigScintTrack::getSigmaX ( ) const
inline

Get the uncertainty on the x coordinate of the track.

Returns
The uncertainty on the x coordinate of the track in mm [mm].

Definition at line 119 of file TrigScintTrack.h.

119{ return sx_; };
float sx_
The uncertainty on the X position.

References sx_.

◆ getSigmaY()

float ldmx::TrigScintTrack::getSigmaY ( ) const
inline

Get the uncertainty on the y coordinate of the track.

Returns
The uncertainty on the y coordinate of the track in mm [mm].

Definition at line 125 of file TrigScintTrack.h.

125{ return sy_; };
float sy_
The uncertainty on the Y position.

References sy_.

◆ getX()

float ldmx::TrigScintTrack::getX ( ) const
inline

Get the x coordinate of the track.

Returns
The x coordinate of the track in mm [mm].

Definition at line 107 of file TrigScintTrack.h.

107{ return x_; };
float x_
The X position.

References x_.

◆ getY()

float ldmx::TrigScintTrack::getY ( ) const
inline

Get the y coordinate of the track.

Returns
The y coordinate of the track [mm].

Definition at line 113 of file TrigScintTrack.h.

113{ return y_; };
float y_
The Y position.

References y_.

◆ operator<()

bool ldmx::TrigScintTrack::operator< ( const TrigScintTrack rhs) const
inline

Sort by track residual.

Definition at line 249 of file TrigScintTrack.h.

249 {
250 return this->getResidual() < rhs.getResidual();
251 }
float getResidual() const
Get the detector ID residual of the track.

References getResidual().

◆ setBeamEfrac()

void ldmx::TrigScintTrack::setBeamEfrac ( float  e)
inline

Set beam energy fraction of hit.

Definition at line 148 of file TrigScintTrack.h.

148{ beamEfrac_ = e; }

References beamEfrac_.

◆ setCentroid()

void ldmx::TrigScintTrack::setCentroid ( float  centroid)
inline

Set the detector ID centroid of the track.

Definition at line 153 of file TrigScintTrack.h.

153{ centroid_ = centroid; };

References centroid_.

◆ setCentroidX()

void ldmx::TrigScintTrack::setCentroidX ( float  centroid)
inline

Set the x centroid of the track.

Definition at line 158 of file TrigScintTrack.h.

158{ centroidX_ = centroid; };

References centroidX_.

◆ setCentroidY()

void ldmx::TrigScintTrack::setCentroidY ( float  centroid)
inline

Set the y centroid of the track.

Definition at line 163 of file TrigScintTrack.h.

163{ centroidY_ = centroid; };

References centroidY_.

◆ setCentroidZ()

void ldmx::TrigScintTrack::setCentroidZ ( float  centroid)
inline

Set the z centroid of the track.

Definition at line 168 of file TrigScintTrack.h.

168{ centroidZ_ = centroid; };

References centroidZ_.

◆ setMomentum()

void ldmx::TrigScintTrack::setMomentum ( const float  px,
const float  py,
const float  pz 
)

Set the momentum of the particle at the position at which the track took place [GeV].

Parameters
pxThe X momentum.
pyThe Y momentum.
pzThe Z momentum.

◆ setNclusters()

void ldmx::TrigScintTrack::setNclusters ( uint  nCl)
inline

Set the number of clusters forming the track.

Definition at line 198 of file TrigScintTrack.h.

198{ nClusters_ = nCl; };

References nClusters_.

◆ setPE()

void ldmx::TrigScintTrack::setPE ( float  pe)
inline

Set the average cluster pe of the track.

Definition at line 193 of file TrigScintTrack.h.

193{ PE_ = pe; };

References PE_.

◆ setPosition()

void ldmx::TrigScintTrack::setPosition ( const float  x,
const float  y 
)
inline

Set the position of the track [mm].

Parameters
xThe X position.
yThe Y position.

Definition at line 210 of file TrigScintTrack.h.

210 {
211 x_ = x;
212 y_ = y;
213 };

References x_, and y_.

◆ setResidual()

void ldmx::TrigScintTrack::setResidual ( float  resid)
inline

Set the detector ID residual of the track.

Definition at line 173 of file TrigScintTrack.h.

173{ residual_ = resid; };

References residual_.

◆ setResidualX()

void ldmx::TrigScintTrack::setResidualX ( float  resid)
inline

Set the x residual of the track.

Definition at line 178 of file TrigScintTrack.h.

178{ residualX_ = resid; };

References residualX_.

◆ setResidualY()

void ldmx::TrigScintTrack::setResidualY ( float  resid)
inline

Set the y residual of the track.

Definition at line 183 of file TrigScintTrack.h.

183{ residualY_ = resid; };

References residualY_.

◆ setResidualZ()

void ldmx::TrigScintTrack::setResidualZ ( float  resid)
inline

Set the z residual of the track.

Definition at line 188 of file TrigScintTrack.h.

188{ residualZ_ = resid; };

References residualZ_.

◆ setSigmaX()

void ldmx::TrigScintTrack::setSigmaX ( const float  sx)
inline

Set the uncertainty on the position of the track [mm].

Parameters
xThe X position uncertainty.

Definition at line 229 of file TrigScintTrack.h.

229{ sx_ = sx; }

References sx_.

◆ setSigmaXY()

void ldmx::TrigScintTrack::setSigmaXY ( const float  sx,
const float  sy 
)
inline

Set the uncertainty on the position of the track [mm].

Parameters
xThe X position uncertainty.
yThe Y position uncertainty.

Definition at line 220 of file TrigScintTrack.h.

220 {
221 sx_ = sx;
222 sy_ = sy;
223 }

References sx_, and sy_.

◆ setSigmaY()

void ldmx::TrigScintTrack::setSigmaY ( const float  sy)
inline

Set the uncertainty on the position of the track [mm].

Parameters
yThe Y position uncertainty.

Definition at line 235 of file TrigScintTrack.h.

235{ sy_ = sy; }

References sy_.

Member Data Documentation

◆ beamEfrac_

float ldmx::TrigScintTrack::beamEfrac_ {0.}
private

The fraction of the energy deposited in the track constituents that was deposited by a beam electron.

WARNING: this is a "truth" variable and will never be measureable in actual data.

Definition at line 310 of file TrigScintTrack.h.

310{0.};

Referenced by getBeamEfrac(), and setBeamEfrac().

◆ centroid_

float ldmx::TrigScintTrack::centroid_ {-1}
private

The detector centroid.

Definition at line 257 of file TrigScintTrack.h.

257{-1};

Referenced by getCentroid(), and setCentroid().

◆ centroidX_

float ldmx::TrigScintTrack::centroidX_ {-1}
private

The detector x coordinate centroid.

Definition at line 262 of file TrigScintTrack.h.

262{-1};

Referenced by getCentroidX(), and setCentroidX().

◆ centroidY_

float ldmx::TrigScintTrack::centroidY_ {-1}
private

The detector y coordinate centroid.

Definition at line 267 of file TrigScintTrack.h.

267{-1};

Referenced by getCentroidY(), and setCentroidY().

◆ centroidZ_

float ldmx::TrigScintTrack::centroidZ_ {-99999}
private

The detector z coordinate centroid.

Definition at line 272 of file TrigScintTrack.h.

272{-99999};

Referenced by getCentroidZ(), and setCentroidZ().

◆ constituents_

std::vector<ldmx::TrigScintCluster> ldmx::TrigScintTrack::constituents_ {0}
private

The list of clusters constituting the track.

Definition at line 302 of file TrigScintTrack.h.

302{0};

Referenced by addConstituent(), and getConstituents().

◆ nClusters_

int ldmx::TrigScintTrack::nClusters_ {0}
private

The number of clusters forming the track.

Definition at line 297 of file TrigScintTrack.h.

297{0};

Referenced by getNclusters(), and setNclusters().

◆ PE_

float ldmx::TrigScintTrack::PE_ {0.}
private

The average pe count of the clusters making up the track.

Definition at line 315 of file TrigScintTrack.h.

315{0.};

Referenced by getPE(), and setPE().

◆ px_

float ldmx::TrigScintTrack::px_ {0}
private

The X momentum.

Definition at line 342 of file TrigScintTrack.h.

342{0};

Referenced by getMomentum().

◆ py_

float ldmx::TrigScintTrack::py_ {0}
private

The Y momentum.

Definition at line 347 of file TrigScintTrack.h.

347{0};

Referenced by getMomentum().

◆ pz_

float ldmx::TrigScintTrack::pz_ {0}
private

The Z momentum.

Definition at line 352 of file TrigScintTrack.h.

352{0};

Referenced by getMomentum().

◆ residual_

float ldmx::TrigScintTrack::residual_ {0}
private

The detector residual.

Definition at line 277 of file TrigScintTrack.h.

277{0};

Referenced by getResidual(), and setResidual().

◆ residualX_

float ldmx::TrigScintTrack::residualX_ {0}
private

The x coordinate residual.

Definition at line 282 of file TrigScintTrack.h.

282{0};

Referenced by getResidualX(), and setResidualX().

◆ residualY_

float ldmx::TrigScintTrack::residualY_ {0}
private

The y coordinate residual.

Definition at line 287 of file TrigScintTrack.h.

287{0};

Referenced by getResidualY(), and setResidualY().

◆ residualZ_

float ldmx::TrigScintTrack::residualZ_ {0}
private

The z coordinate residual.

Definition at line 292 of file TrigScintTrack.h.

292{0};

Referenced by getResidualZ(), and setResidualZ().

◆ sx_

float ldmx::TrigScintTrack::sx_ {-9999.}
private

The uncertainty on the X position.

Definition at line 330 of file TrigScintTrack.h.

330{-9999.};

Referenced by getSigmaX(), setSigmaX(), and setSigmaXY().

◆ sy_

float ldmx::TrigScintTrack::sy_ {-9999.}
private

The uncertainty on the Y position.

Definition at line 335 of file TrigScintTrack.h.

335{-9999.};

Referenced by getSigmaY(), setSigmaXY(), and setSigmaY().

◆ x_

float ldmx::TrigScintTrack::x_ {-99999.}
private

The X position.

Definition at line 320 of file TrigScintTrack.h.

320{-99999.};

Referenced by getX(), and setPosition().

◆ y_

float ldmx::TrigScintTrack::y_ {-99999.}
private

The Y position.

Definition at line 325 of file TrigScintTrack.h.

325{-99999.};

Referenced by getY(), and setPosition().

◆ z_

float ldmx::TrigScintTrack::z_ {0}
private

The Z position.

Definition at line 357 of file TrigScintTrack.h.

357{0};

The documentation for this class was generated from the following file: