Skip to content
Snippets Groups Projects
Commit c34b6204 authored by Moritz Kiehn's avatar Moritz Kiehn Committed by Fabian Klimpel
Browse files

Utilities: update bound parameters index enum

parent 6097eb5d
No related branches found
No related tags found
1 merge request!785Clean up the parameter definitions
......@@ -15,23 +15,54 @@
#include "Acts/Utilities/ParameterTypes.hpp"
namespace Acts {
enum ParDef : unsigned int {
eLOC_0 = 0, ///< first coordinate in local surface frame
eLOC_1 = 1, ///< second coordinate in local surface frame
/// Components of a bound track parameters vector.
///
/// To be used to access components by named indices instead of just numbers.
/// This must be a regular `enum` and not a scoped `enum class` to allow
/// implicit conversion to an integer. The enum value are thus visible directly
/// in `namespace Acts` and are prefixed to avoid naming collisions.
enum BoundParametersIndices : unsigned int {
// Local position on the reference surface.
// This is intentionally named different from the position components in
// the other data vectors, to clarify that this is defined on a surface
// while the others are defined in free space.
eBoundLoc0 = 0,
eBoundLoc1 = 1,
// Direction angles
eBoundPhi = 2,
eBoundTheta = 3,
// Global inverse-momentum-like parameter, i.e. q/p or 1/p
// The naming is inconsistent for the case of neutral track parameters where
// the value is interpreted as 1/p not as q/p. This is intentional to avoid
// having multiple aliases for the same element and for lack of an acceptable
// common name.
eBoundQOverP = 4,
eBoundTime = 5,
// Last uninitialized value contains the total number of components
eBoundParametersSize,
// The following aliases without prefix exist for historical reasons
// Generic spatial coordinates on the local surface
eLOC_0 = eBoundLoc0,
eLOC_1 = eBoundLoc1,
// Spatial coordinates on a disk in polar coordinates
eLOC_R = eLOC_0,
eLOC_PHI = eLOC_1,
eLOC_RPHI = eLOC_0,
eLOC_Z = eLOC_1,
// Spatial coordinates on a disk in Cartesian coordinates
eLOC_X = eLOC_0,
eLOC_Y = eLOC_1,
// Spatial coordinates on a cylinder
eLOC_RPHI = eLOC_0,
eLOC_Z = eLOC_1,
// Closest approach coordinates on a virtual perigee surface
eLOC_D0 = eLOC_0,
eLOC_Z0 = eLOC_1,
ePHI = 2, ///< phi direction of momentum in global frame
eTHETA = 3, ///< theta direction of momentum in global frame
eQOP = 4, ///< charge/momentum for charged tracks, for neutral tracks it is
/// 1/momentum
eT = 5, /// < The time of the particle
BoundParsDim /// < The local dimensions
// Direction angles
ePHI = eBoundPhi,
eTHETA = eBoundTheta,
eQOP = eBoundQOverP,
eT = eBoundTime,
BoundParsDim = eBoundParametersSize,
};
/// Components of a free track parameters vector.
......@@ -89,7 +120,8 @@ enum SpacePointIndices : unsigned int {
SpacePointDim = eSpacePointSize,
};
using ParID_t = ParDef;
using ParDef = BoundParametersIndices;
using ParID_t = BoundParametersIndices;
using ParValue_t = double;
///
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment