CbmRoot
Loading...
Searching...
No Matches
cbm::algo::trd::Hit Class Reference

A light-weight TRD hit class for online reconstruction, based on CbmTrdHit. . More...

#include <Hit.h>

Public Types

enum  HitDef { kType = 0 , kMaxType , kRowCross , kOvfl }
 

Public Member Functions

 Hit ()
 Default constructor.
 
 Hit (int32_t address, const ROOT::Math::XYZVector &pos, const ROOT::Math::XYZVector &dpos, double dxy, int32_t refId, double eLoss, double time=0., double timeError=0.)
 Standard constructor.
 
 Hit (int32_t address, double x, double y, double z, double dx, double dy, double dz, double dxy, int32_t refId, double time=-1., double timeError=-1.)
 Standard constructor.
 
 ~Hit ()
 Destructor.
 
int32_t GetPlaneId () const
 
double GetELoss () const
 
bool GetClassType () const
 
bool GetMaxType () const
 
bool HasOverFlow () const
 
bool IsRowCross () const
 
bool IsUsed () const
 
double X () const
 
double Y () const
 
double Z () const
 
double Dx () const
 
double Dy () const
 
double Dz () const
 
double Dxy () const
 
int32_t GetRefId () const
 
int32_t Address () const
 
double Time () const
 
double TimeError () const
 
void Position (ROOT::Math::XYZVector &pos) const
 Copies hit position to pos.
 
void PositionError (ROOT::Math::XYZVector &dpos) const
 Copies hit position error to pos.
 
void SetELoss (double loss)
 
void SetOverFlow (bool set=true)
 Mark overflow in one or more digits which define the hit.
 
void SetRowCross (bool set=true)
 Mark hit reconstructed between pad rows.
 
void SetClassType (bool set=true)
 Type of pad layout used in reconstruction R[0], T[1].
 
void SetMaxType (bool set=true)
 Extra bool definition for the hit (e.g. the type of maximum for triangular pads).
 
void SetX (double x)
 
void SetY (double y)
 
void SetZ (double z)
 
void SetDx (double dx)
 
void SetDy (double dy)
 
void SetDz (double dz)
 
void SetDxy (double dxy)
 
void SetRefId (int32_t refId)
 
void SetAddress (int32_t address)
 
void SetTime (double time)
 
void SetTime (double time, double error)
 
void SetTimeError (double error)
 
void SetPosition (const ROOT::Math::XYZVector &pos)
 Sets position of the hit.
 
void SetPositionError (const ROOT::Math::XYZVector &dpos)
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, unsigned int)
 

Private Attributes

double fX
 
double fY
 
double fZ
 X, Y, Z positions of hit [cm].
 
double fDx
 
double fDy
 
double fDz
 X, Y, Z errors [cm].
 
double fDxy
 X-Y covariance of the hit [cm**2].
 
int32_t fRefId
 some reference id (usually to cluster, digi or MC point)
 
int32_t fAddress
 detector unique identifier
 
double fTime
 Hit time [ns].
 
double fTimeError
 Error of hit time [ns].
 
uint8_t fDefine
 
int32_t fNeighborId
 
Double32_t fELoss
 

Friends

class boost::serialization::access
 

Detailed Description

A light-weight TRD hit class for online reconstruction, based on CbmTrdHit. .

Definition at line 33 of file detectors/trd/Hit.h.

Member Enumeration Documentation

◆ HitDef

Enumerator
kType 

set type of pad layout

kMaxType 

set type of pad on which the maximum charge is found

kRowCross 

mark hit defined by 2 clusters

kOvfl 

mark over-flow in the data

Definition at line 35 of file detectors/trd/Hit.h.

Constructor & Destructor Documentation

◆ Hit() [1/3]

cbm::algo::trd::Hit::Hit ( )

Default constructor.

Definition at line 15 of file Hit.cxx.

◆ Hit() [2/3]

cbm::algo::trd::Hit::Hit ( int32_t address,
const ROOT::Math::XYZVector & pos,
const ROOT::Math::XYZVector & dpos,
double dxy,
int32_t refId,
double eLoss,
double time = 0.,
double timeError = 0. )

Standard constructor.

Parameters
addressUnique detector ID
posPosition in global c.s. [cm]
dposErrors of position in global c.s. [cm]
dxyXY correlation of the hit
refIdIndex of digi or cluster
eLossTR + dEdx

Definition at line 17 of file Hit.cxx.

References fELoss.

◆ Hit() [3/3]

cbm::algo::trd::Hit::Hit ( int32_t address,
double x,
double y,
double z,
double dx,
double dy,
double dz,
double dxy,
int32_t refId,
double time = -1.,
double timeError = -1. )

Standard constructor.

Parameters
[in]addressDetector unique identifier.
[in]xX position of the hit [cm].
[in]yY position of the hit [cm].
[in]zZ position of the hit [cm].
[in]dxX position error of the hit [cm].
[in]dyY position error of the hit [cm].
[in]dzZ position error of the hit [cm].
[in]dxyX-Y covariance of the hit [cm**2].
[in]refIdSome reference ID.
[in]timeHit time [ns].
[in]timeErrorError of hit time [ns].

Definition at line 24 of file Hit.cxx.

◆ ~Hit()

cbm::algo::trd::Hit::~Hit ( )
inline

Destructor.

Definition at line 83 of file detectors/trd/Hit.h.

Member Function Documentation

◆ Address()

int32_t cbm::algo::trd::Hit::Address ( ) const
inline

Definition at line 101 of file detectors/trd/Hit.h.

References fAddress.

Referenced by GetPlaneId().

◆ Dx()

double cbm::algo::trd::Hit::Dx ( ) const
inline

Definition at line 96 of file detectors/trd/Hit.h.

References fDx.

Referenced by PositionError().

◆ Dxy()

double cbm::algo::trd::Hit::Dxy ( ) const
inline

Definition at line 99 of file detectors/trd/Hit.h.

References fDxy.

◆ Dy()

double cbm::algo::trd::Hit::Dy ( ) const
inline

Definition at line 97 of file detectors/trd/Hit.h.

References fDy.

Referenced by PositionError().

◆ Dz()

double cbm::algo::trd::Hit::Dz ( ) const
inline

Definition at line 98 of file detectors/trd/Hit.h.

References fDz.

Referenced by PositionError().

◆ GetClassType()

bool cbm::algo::trd::Hit::GetClassType ( ) const
inline

Definition at line 88 of file detectors/trd/Hit.h.

References fDefine, kType, and TESTBIT.

◆ GetELoss()

double cbm::algo::trd::Hit::GetELoss ( ) const
inline

Definition at line 87 of file detectors/trd/Hit.h.

References fELoss.

◆ GetMaxType()

bool cbm::algo::trd::Hit::GetMaxType ( ) const
inline

Definition at line 89 of file detectors/trd/Hit.h.

References fDefine, kMaxType, and TESTBIT.

◆ GetPlaneId()

int32_t cbm::algo::trd::Hit::GetPlaneId ( ) const
inline

Definition at line 86 of file detectors/trd/Hit.h.

References Address(), and CbmTrdAddress::GetLayerId().

◆ GetRefId()

int32_t cbm::algo::trd::Hit::GetRefId ( ) const
inline

Definition at line 100 of file detectors/trd/Hit.h.

References fRefId.

Referenced by IsUsed().

◆ HasOverFlow()

bool cbm::algo::trd::Hit::HasOverFlow ( ) const
inline

Definition at line 90 of file detectors/trd/Hit.h.

References fDefine, kOvfl, and TESTBIT.

◆ IsRowCross()

bool cbm::algo::trd::Hit::IsRowCross ( ) const
inline

Definition at line 91 of file detectors/trd/Hit.h.

References fDefine, kRowCross, and TESTBIT.

◆ IsUsed()

bool cbm::algo::trd::Hit::IsUsed ( ) const
inline

Definition at line 92 of file detectors/trd/Hit.h.

References GetRefId().

Referenced by cbm::algo::trd::HitMerger2D::operator()().

◆ Position()

void cbm::algo::trd::Hit::Position ( ROOT::Math::XYZVector & pos) const

Copies hit position to pos.

Parameters
posOutput hit position.

Definition at line 43 of file Hit.cxx.

References pos, X(), Y(), and Z().

◆ PositionError()

void cbm::algo::trd::Hit::PositionError ( ROOT::Math::XYZVector & dpos) const

Copies hit position error to pos.

Parameters
posOutput hit position error.

Definition at line 45 of file Hit.cxx.

References dpos, Dx(), Dy(), and Dz().

◆ serialize()

template<class Archive >
void cbm::algo::trd::Hit::serialize ( Archive & ar,
unsigned int  )
inlineprivate

Definition at line 174 of file detectors/trd/Hit.h.

References fAddress, fDefine, fDx, fDxy, fDy, fDz, fELoss, fNeighborId, fRefId, fTime, fTimeError, fX, fY, and fZ.

◆ SetAddress()

void cbm::algo::trd::Hit::SetAddress ( int32_t address)
inline

Definition at line 135 of file detectors/trd/Hit.h.

References fAddress.

Referenced by cbm::algo::trd::HitFinder2D::MakeHit().

◆ SetClassType()

void cbm::algo::trd::Hit::SetClassType ( bool set = true)
inline

Type of pad layout used in reconstruction R[0], T[1].

Definition at line 124 of file detectors/trd/Hit.h.

References CLRBIT, fDefine, kType, and SETBIT.

◆ SetDx()

void cbm::algo::trd::Hit::SetDx ( double dx)
inline

Definition at line 130 of file detectors/trd/Hit.h.

References fDx.

Referenced by SetPositionError().

◆ SetDxy()

void cbm::algo::trd::Hit::SetDxy ( double dxy)
inline

Definition at line 133 of file detectors/trd/Hit.h.

References fDxy.

◆ SetDy()

void cbm::algo::trd::Hit::SetDy ( double dy)
inline

Definition at line 131 of file detectors/trd/Hit.h.

References fDy.

Referenced by SetPositionError().

◆ SetDz()

void cbm::algo::trd::Hit::SetDz ( double dz)
inline

Definition at line 132 of file detectors/trd/Hit.h.

References fDz.

Referenced by SetPositionError().

◆ SetELoss()

void cbm::algo::trd::Hit::SetELoss ( double loss)
inline

Definition at line 118 of file detectors/trd/Hit.h.

References fELoss.

◆ SetMaxType()

void cbm::algo::trd::Hit::SetMaxType ( bool set = true)
inline

Extra bool definition for the hit (e.g. the type of maximum for triangular pads).

Definition at line 126 of file detectors/trd/Hit.h.

References CLRBIT, fDefine, kMaxType, and SETBIT.

◆ SetOverFlow()

void cbm::algo::trd::Hit::SetOverFlow ( bool set = true)
inline

Mark overflow in one or more digits which define the hit.

Definition at line 120 of file detectors/trd/Hit.h.

References CLRBIT, fDefine, kOvfl, and SETBIT.

◆ SetPosition()

void cbm::algo::trd::Hit::SetPosition ( const ROOT::Math::XYZVector & pos)

Sets position of the hit.

Parameters
posnew hit position.

Definition at line 47 of file Hit.cxx.

References pos, SetX(), SetY(), and SetZ().

◆ SetPositionError()

void cbm::algo::trd::Hit::SetPositionError ( const ROOT::Math::XYZVector & dpos)

\breif Sets position error of the hit.

Parameters
dposnew hit position error

Definition at line 54 of file Hit.cxx.

References dpos, SetDx(), SetDy(), and SetDz().

◆ SetRefId()

void cbm::algo::trd::Hit::SetRefId ( int32_t refId)
inline

Definition at line 134 of file detectors/trd/Hit.h.

References fRefId.

Referenced by cbm::algo::trd::HitFinder2D::MakeHit().

◆ SetRowCross()

void cbm::algo::trd::Hit::SetRowCross ( bool set = true)
inline

Mark hit reconstructed between pad rows.

Definition at line 122 of file detectors/trd/Hit.h.

References CLRBIT, fDefine, kRowCross, and SETBIT.

Referenced by cbm::algo::trd::HitMerger2D::operator()().

◆ SetTime() [1/2]

void cbm::algo::trd::Hit::SetTime ( double time)
inline

Definition at line 136 of file detectors/trd/Hit.h.

References fTime.

◆ SetTime() [2/2]

void cbm::algo::trd::Hit::SetTime ( double time,
double error )
inline

Definition at line 137 of file detectors/trd/Hit.h.

References fTime, and fTimeError.

◆ SetTimeError()

void cbm::algo::trd::Hit::SetTimeError ( double error)
inline

Definition at line 142 of file detectors/trd/Hit.h.

References fTimeError.

◆ SetX()

void cbm::algo::trd::Hit::SetX ( double x)
inline

Definition at line 127 of file detectors/trd/Hit.h.

References fX, and x.

Referenced by SetPosition().

◆ SetY()

void cbm::algo::trd::Hit::SetY ( double y)
inline

Definition at line 128 of file detectors/trd/Hit.h.

References fY, and y.

Referenced by SetPosition().

◆ SetZ()

void cbm::algo::trd::Hit::SetZ ( double z)
inline

Definition at line 129 of file detectors/trd/Hit.h.

References fZ.

Referenced by SetPosition().

◆ Time()

double cbm::algo::trd::Hit::Time ( ) const
inline

Definition at line 102 of file detectors/trd/Hit.h.

References fTime.

Referenced by cbm::algo::trd::HitMerger2D::operator()().

◆ TimeError()

double cbm::algo::trd::Hit::TimeError ( ) const
inline

Definition at line 103 of file detectors/trd/Hit.h.

References fTimeError.

◆ X()

double cbm::algo::trd::Hit::X ( ) const
inline

Definition at line 93 of file detectors/trd/Hit.h.

References fX.

Referenced by cbm::algo::trd::HitMerger2D::operator()(), and Position().

◆ Y()

double cbm::algo::trd::Hit::Y ( ) const
inline

Definition at line 94 of file detectors/trd/Hit.h.

References fY.

Referenced by cbm::algo::trd::HitMerger2D::operator()(), and Position().

◆ Z()

double cbm::algo::trd::Hit::Z ( ) const
inline

Definition at line 95 of file detectors/trd/Hit.h.

References fZ.

Referenced by Position().

Friends And Related Symbol Documentation

◆ boost::serialization::access

friend class boost::serialization::access
friend

Definition at line 171 of file detectors/trd/Hit.h.

Member Data Documentation

◆ fAddress

int32_t cbm::algo::trd::Hit::fAddress
private

detector unique identifier

Definition at line 162 of file detectors/trd/Hit.h.

Referenced by Address(), serialize(), and SetAddress().

◆ fDefine

uint8_t cbm::algo::trd::Hit::fDefine
private

◆ fDx

double cbm::algo::trd::Hit::fDx
private

Definition at line 159 of file detectors/trd/Hit.h.

Referenced by Dx(), serialize(), and SetDx().

◆ fDxy

double cbm::algo::trd::Hit::fDxy
private

X-Y covariance of the hit [cm**2].

Definition at line 160 of file detectors/trd/Hit.h.

Referenced by Dxy(), serialize(), and SetDxy().

◆ fDy

double cbm::algo::trd::Hit::fDy
private

Definition at line 159 of file detectors/trd/Hit.h.

Referenced by Dy(), serialize(), and SetDy().

◆ fDz

double cbm::algo::trd::Hit::fDz
private

X, Y, Z errors [cm].

Definition at line 159 of file detectors/trd/Hit.h.

Referenced by Dz(), serialize(), and SetDz().

◆ fELoss

Double32_t cbm::algo::trd::Hit::fELoss
private

Definition at line 168 of file detectors/trd/Hit.h.

Referenced by GetELoss(), Hit(), serialize(), and SetELoss().

◆ fNeighborId

int32_t cbm::algo::trd::Hit::fNeighborId
private

Definition at line 167 of file detectors/trd/Hit.h.

Referenced by serialize().

◆ fRefId

int32_t cbm::algo::trd::Hit::fRefId
private

some reference id (usually to cluster, digi or MC point)

Definition at line 161 of file detectors/trd/Hit.h.

Referenced by GetRefId(), serialize(), and SetRefId().

◆ fTime

double cbm::algo::trd::Hit::fTime
private

Hit time [ns].

Definition at line 163 of file detectors/trd/Hit.h.

Referenced by serialize(), SetTime(), SetTime(), and Time().

◆ fTimeError

double cbm::algo::trd::Hit::fTimeError
private

Error of hit time [ns].

Definition at line 164 of file detectors/trd/Hit.h.

Referenced by serialize(), SetTime(), SetTimeError(), and TimeError().

◆ fX

double cbm::algo::trd::Hit::fX
private

Definition at line 158 of file detectors/trd/Hit.h.

Referenced by serialize(), SetX(), and X().

◆ fY

double cbm::algo::trd::Hit::fY
private

Definition at line 158 of file detectors/trd/Hit.h.

Referenced by serialize(), SetY(), and Y().

◆ fZ

double cbm::algo::trd::Hit::fZ
private

X, Y, Z positions of hit [cm].

Definition at line 158 of file detectors/trd/Hit.h.

Referenced by serialize(), SetZ(), and Z().


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