Belle II Software  release-08-01-10
TrackBase_t< TTrackCluster > Struct Template Reference

Struct to hold variables from a track which contains a vector of data type like TrackCluster. More...

#include <PXDPerformanceStructs.h>

Collaboration diagram for TrackBase_t< TTrackCluster >:

Public Member Functions

 TrackBase_t ()
 Default constructor.
 
void setTrackVariables (const TrackFitResult *tfrPtr, const ROOT::Math::XYZVector &ip)
 update track level variables from TrackFitResult More...
 
void setValues (const RecoTrack &recoTrack, const ROOT::Math::XYZVector &ip=ROOT::Math::XYZVector(0, 0, 0), const std::string &recoTracksName="", const std::string &pxdInterceptsName="", const std::string &pxdTrackClustersName="PXDClustersFromTracks")
 Update values from a RecoTrack. More...
 

Public Attributes

float d0
 Impact parameter in r-phi.
 
float z0
 Impact parameter in z.
 
float phi0
 Track direction in r-phi.
 
float pt
 Transverse momentum.
 
float tanLambda
 Tangent of the dip angle.
 
float d0p
 Corrected impact parameter in r-phi.
 
float z0p
 Corrected impact parameter in z.
 
unsigned short nPXDHits
 Number of PXD Hits.
 
unsigned short nSVDHits
 Number of SVD Hits.
 
unsigned short nCDCHits
 Number of CDC Hits.
 
std::vector< TTrackCluster > trackClusters
 Vector of track cluster structs.
 

Detailed Description

template<typename TTrackCluster>
struct Belle2::PXD::TrackBase_t< TTrackCluster >

Struct to hold variables from a track which contains a vector of data type like TrackCluster.

Definition at line 113 of file PXDPerformanceStructs.h.

Member Function Documentation

◆ setTrackVariables()

void setTrackVariables ( const TrackFitResult tfrPtr,
const ROOT::Math::XYZVector &  ip 
)

update track level variables from TrackFitResult

Template implementation.

Parameters
tfrPtra pointer of TrackFitResult
ipThe interaction point for correcting d0 and z0

Definition at line 158 of file PXDPerformanceStructs.h.

161  {
162  if (!tfrPtr) {
163  B2ERROR("Expect the track fit result. Found Nothing!");
164  }
165  nCDCHits = tfrPtr->getHitPatternCDC().getNHits();
166  nSVDHits = tfrPtr->getHitPatternVXD().getNSVDHits();
167  nPXDHits = tfrPtr->getHitPatternVXD().getNPXDHits();
168  tanLambda = tfrPtr->getCotTheta();
169  pt = tfrPtr->getMomentum().Rho();
170  d0 = tfrPtr->getD0();
171  z0 = tfrPtr->getZ0();
172  phi0 = tfrPtr->getPhi0();
173  d0p = d0;
174  z0p = z0;
175  if (ip != ROOT::Math::XYZVector(0, 0, 0)) {
176  // get a helix and change coordinate origin to ip
177  auto uHelix = tfrPtr->getUncertainHelix();
178  uHelix.passiveMoveBy(ip);
179  d0p = uHelix.getD0();
180  z0p = uHelix.getZ0();
181  }
182  }
float z0
Impact parameter in z.
float pt
Transverse momentum.
float d0p
Corrected impact parameter in r-phi.
float d0
Impact parameter in r-phi.
float phi0
Track direction in r-phi.
unsigned short nCDCHits
Number of CDC Hits.
unsigned short nSVDHits
Number of SVD Hits.
float z0p
Corrected impact parameter in z.
unsigned short nPXDHits
Number of PXD Hits.
float tanLambda
Tangent of the dip angle.

◆ setValues()

void setValues ( const RecoTrack recoTrack,
const ROOT::Math::XYZVector &  ip = ROOT::Math::XYZVector(0, 0, 0),
const std::string &  recoTracksName = "",
const std::string &  pxdInterceptsName = "",
const std::string &  pxdTrackClustersName = "PXDClustersFromTracks" 
)

Update values from a RecoTrack.

Parameters
recoTrackA RecoTrack object.
ipThe interaction point for correcting d0 and z0
recoTracksNameName of RecoTrack collection
pxdInterceptsNameName of PXDIntercept collection
pxdTrackClustersNameName of track matched PXDClusters

Definition at line 185 of file PXDPerformanceStructs.h.


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