31 if (std::fabs(deltaPosition.
GetZ()) > std::numeric_limits<float>::epsilon())
32 return (deltaPosition.
GetZ() > std::numeric_limits<float>::epsilon());
34 if (std::fabs(deltaPosition.
GetX()) > std::numeric_limits<float>::epsilon())
35 return (deltaPosition.
GetX() > std::numeric_limits<float>::epsilon());
37 if (std::fabs(deltaPosition.
GetY()) > std::numeric_limits<float>::epsilon())
38 return (deltaPosition.
GetY() > std::numeric_limits<float>::epsilon());
46 m_d0(parameters.m_d0.Get()),
47 m_z0(parameters.m_z0.Get()),
48 m_particleId(parameters.m_particleId.Get()),
49 m_charge(parameters.m_charge.Get()),
50 m_mass(parameters.m_mass.Get()),
51 m_momentumAtDca(parameters.m_momentumAtDca.Get()),
52 m_energyAtDca(std::sqrt(m_mass * m_mass + m_momentumAtDca.GetMagnitudeSquared())),
53 m_trackStateAtStart(parameters.m_trackStateAtStart.Get()),
54 m_trackStateAtEnd(parameters.m_trackStateAtEnd.Get()),
55 m_trackStateAtCalorimeter(parameters.m_trackStateAtCalorimeter.Get()),
56 m_timeAtCalorimeter(parameters.m_timeAtCalorimeter.Get()),
57 m_reachesCalorimeter(parameters.m_reachesCalorimeter.Get()),
58 m_isProjectedToEndCap(parameters.m_isProjectedToEndCap.Get()),
59 m_canFormPfo(parameters.m_canFormPfo.Get()),
60 m_canFormClusterlessPfo(parameters.m_canFormClusterlessPfo.Get()),
61 m_pAssociatedCluster(nullptr),
62 m_pParentAddress(parameters.m_pParentAddress.Get()),
98 return STATUS_CODE_INVALID_PARAMETER;
101 return STATUS_CODE_ALREADY_INITIALIZED;
104 return STATUS_CODE_SUCCESS;
112 return STATUS_CODE_NOT_FOUND;
115 return STATUS_CODE_SUCCESS;
123 return STATUS_CODE_INVALID_PARAMETER;
126 return STATUS_CODE_ALREADY_PRESENT;
129 return STATUS_CODE_SUCCESS;
137 return STATUS_CODE_INVALID_PARAMETER;
140 return STATUS_CODE_ALREADY_PRESENT;
143 return STATUS_CODE_SUCCESS;
151 return STATUS_CODE_INVALID_PARAMETER;
154 return STATUS_CODE_ALREADY_PRESENT;
157 return STATUS_CODE_SUCCESS;
Header file for the track class.
float GetX() const
Get the cartesian x coordinate.
float GetZ() const
Get the cartesian z coordinate.
float GetY() const
Get the cartesian y coordinate.
StatusCodeException class.
MCParticleWeightMap m_mcParticleWeightMap
The mc particle weight map.
StatusCode SetAssociatedCluster(const Cluster *const pCluster)
Set the cluster associated with the track.
void SetMCParticleWeightMap(const MCParticleWeightMap &mcParticleWeightMap)
Set the mc particles associated with the track.
float GetEnergyAtDca() const
Get the track energy at the 2D distance of closest approach.
const int m_charge
The charge of the tracked particle.
StatusCode AddSibling(const Track *const pTrack)
Add a sibling track to the sibling track list.
bool operator<(const Track &rhs) const
operator< sorting by position at calorimeter, then energy at the 2D distance of closest approach
const float m_energyAtDca
The track energy at the 2D distance of closest approach, units GeV.
const Cluster * GetAssociatedCluster() const
Get address of the cluster associated with the track.
void RemoveMCParticles()
Remove the mc particles associated with the track.
Track(const object_creation::Track::Parameters ¶meters)
Constructor.
StatusCode AddDaughter(const Track *const pTrack)
Add a daughter track to the daughter track list.
virtual ~Track()
Destructor.
StatusCode RemoveAssociatedCluster(const Cluster *const pCluster)
Remove the association with a cluster.
TrackList m_siblingTrackList
The list of sibling track addresses.
StatusCode AddParent(const Track *const pTrack)
Add a parent track to the parent track list.
TrackList m_parentTrackList
The list of parent track addresses.
const TrackState & GetTrackStateAtCalorimeter() const
Get the (sometimes projected) track state at the calorimeter.
TrackList m_daughterTrackList
The list of daughter track addresses.
const Cluster * m_pAssociatedCluster
The address of an associated cluster.
const CartesianVector & GetPosition() const
Get the track position vector.
std::unordered_map< const MCParticle *, float > MCParticleWeightMap
StatusCode
The StatusCode enum.