ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::BoundaryTolerance Class Reference

Variant-like type to capture different types of boundary tolerances. More...

#include <Acts/Surfaces/BoundaryTolerance.hpp>

Classes

struct  AbsoluteEuclideanParams
struct  Chi2BoundParams
struct  Chi2CartesianParams
struct  InfiniteParams
struct  NoneParams

Public Types

enum class  ToleranceMode { Extend , None , Shrink }
 Enumeration defining how tolerance should be applied to boundaries. More...

Public Member Functions

 BoundaryTolerance (BoundaryTolerance &&other) noexcept=default
 Move constructor.
 BoundaryTolerance (const BoundaryTolerance &other) noexcept=default
 Copy constructor.
constexpr const AbsoluteEuclideanParamsasAbsoluteEuclidean () const
 Get the tolerance as absolute Euclidean.
constexpr const Chi2BoundParamsasChi2Bound () const
 Get the tolerance as chi2 bound.
constexpr const Chi2CartesianParamsasChi2Cartesian () const
 Get the tolerance as chi2 Cartesian.
constexpr bool hasAbsoluteEuclidean () const
 Check if the tolerance is absolute with Euclidean distance.
constexpr bool hasChi2Bound () const
 Check if the tolerance is chi2 with bound coordinates.
constexpr bool hasChi2Cartesian () const
 Check if the tolerance is chi2 with Cartesian coordinates.
constexpr bool isInfinite () const
 Check if the tolerance is infinite.
constexpr bool isNone () const
 Check if the is no tolerance.
bool isTolerated (const Vector2 &boundDelta, const SquareMatrix2 &boundToCartesian) const
 Check if the bound position delta is tolerated.
BoundaryTolerance & operator= (BoundaryTolerance &&other) noexcept=default
 Move assignment operator.
BoundaryTolerance & operator= (const BoundaryTolerance &other) noexcept=default
 Copy assignment operator.
ToleranceMode toleranceMode () const
 Get the tolerance mode.

Static Public Member Functions

static constexpr auto AbsoluteEuclidean (double tolerance) noexcept
 Absolute tolerance in Euclidean distance.
static auto Chi2Bound (const SquareMatrix2 &weight, double maxChi2) noexcept
 Chi2 tolerance in bound coordinates.
static auto Chi2Cartesian (const SquareMatrix2 &weight, double maxChi2) noexcept
 Chi2 tolerance in Cartesian coordinates.
static constexpr auto Infinite () noexcept
 Infinite tolerance i.e.
static constexpr auto None () noexcept
 No tolerance i.e.

Detailed Description

Variant-like type to capture different types of boundary tolerances.

Since our track hypothesis comes with uncertainties, we sometimes need to check if the track is not just within the boundary of the surface but also within a certain tolerance. This class captures different parameterizations of such tolerances. The surface class will then use these tolerances to check if a ray is within the boundary+tolerance of the surface.

Different types of boundary tolerances implemented:

  • Infinite: Infinite tolerance i.e. no boundary check will be performed.
  • None: No tolerance i.e. exact boundary check will be performed.
  • AbsoluteEuclidean: Absolute tolerance in Euclidean distance. The tolerance is defined as a single absolute value for the Euclidean distance. The Euclidean distance can be calculated via the local bound Jacobian and the bound coordinate residual. If the distance is within the tolerance, the boundary check is considered as passed.
  • Chi2Bound: Chi2 tolerance in bound coordinates. The tolerance is defined as a maximum chi2 value and a weight matrix, which is the inverse of the bound covariance matrix. The chi2 value is calculated from the bound coordinates residual and the weight matrix. If the chi2 value is below the maximum chi2 value, the boundary check is considered as passed.
  • Chi2Cartesian: Chi2 tolerance in Cartesian coordinates. Similar to Chi2Bound, but the chi2 value is calculated in Cartesian coordinates.

The bound coordinates residual is defined as the difference between the point checked and the closest point on the boundary. The Jacobian is the derivative of the bound coordinates with respect to the Cartesian coordinates.

Member Enumeration Documentation

◆ ToleranceMode

Enumeration defining how tolerance should be applied to boundaries.

Enumerator
Extend 
None 
Shrink 

Constructor & Destructor Documentation

◆ BoundaryTolerance() [1/2]

Acts::BoundaryTolerance::BoundaryTolerance ( const BoundaryTolerance & other)
defaultnoexcept

Copy constructor.

Parameters
otherThe BoundaryTolerance object to copy

◆ BoundaryTolerance() [2/2]

Acts::BoundaryTolerance::BoundaryTolerance ( BoundaryTolerance && other)
defaultnoexcept

Move constructor.

Parameters
otherThe BoundaryTolerance object to move

Member Function Documentation

◆ AbsoluteEuclidean()

constexpr auto Acts::BoundaryTolerance::AbsoluteEuclidean ( double tolerance)
staticconstexprnoexcept

Absolute tolerance in Euclidean distance.

Parameters
toleranceThe tolerance value in Euclidean distance
Returns
BoundaryTolerance configured for absolute Euclidean tolerance

◆ asAbsoluteEuclidean()

const AbsoluteEuclideanParams & Acts::BoundaryTolerance::asAbsoluteEuclidean ( ) const
constexpr

Get the tolerance as absolute Euclidean.

Returns
Reference to the absolute Euclidean tolerance parameters

◆ asChi2Bound()

const Chi2BoundParams & Acts::BoundaryTolerance::asChi2Bound ( ) const
constexpr

Get the tolerance as chi2 bound.

Returns
Reference to the chi2 bound tolerance parameters

◆ asChi2Cartesian()

const Chi2CartesianParams & Acts::BoundaryTolerance::asChi2Cartesian ( ) const
constexpr

Get the tolerance as chi2 Cartesian.

Returns
Reference to the chi2 Cartesian tolerance parameters

◆ Chi2Bound()

auto Acts::BoundaryTolerance::Chi2Bound ( const SquareMatrix2 & weight,
double maxChi2 )
staticnoexcept

Chi2 tolerance in bound coordinates.

Parameters
weightThe weight matrix for the chi2 calculation
maxChi2The maximum chi2 value allowed
Returns
BoundaryTolerance configured for chi2 tolerance in bound coordinates

◆ Chi2Cartesian()

auto Acts::BoundaryTolerance::Chi2Cartesian ( const SquareMatrix2 & weight,
double maxChi2 )
staticnoexcept

Chi2 tolerance in Cartesian coordinates.

Parameters
weightThe weight matrix for the chi2 calculation
maxChi2The maximum chi2 value allowed
Returns
BoundaryTolerance configured for chi2 tolerance in Cartesian coordinates

◆ hasAbsoluteEuclidean()

bool Acts::BoundaryTolerance::hasAbsoluteEuclidean ( ) const
constexpr

Check if the tolerance is absolute with Euclidean distance.

Returns
True if configured for absolute Euclidean tolerance, false otherwise

◆ hasChi2Bound()

bool Acts::BoundaryTolerance::hasChi2Bound ( ) const
constexpr

Check if the tolerance is chi2 with bound coordinates.

Returns
True if configured for chi2 tolerance in bound coordinates, false otherwise

◆ hasChi2Cartesian()

bool Acts::BoundaryTolerance::hasChi2Cartesian ( ) const
constexpr

Check if the tolerance is chi2 with Cartesian coordinates.

Returns
True if configured for chi2 tolerance in Cartesian coordinates, false otherwise

◆ Infinite()

constexpr auto Acts::BoundaryTolerance::Infinite ( )
staticconstexprnoexcept

Infinite tolerance i.e.

no boundary check

Returns
BoundaryTolerance configured for infinite tolerance

◆ isInfinite()

bool Acts::BoundaryTolerance::isInfinite ( ) const
constexpr

Check if the tolerance is infinite.

Returns
True if configured for infinite tolerance, false otherwise

◆ isNone()

bool Acts::BoundaryTolerance::isNone ( ) const
constexpr

Check if the is no tolerance.

Returns
True if configured for no tolerance (exact checking), false otherwise

◆ isTolerated()

bool Acts::BoundaryTolerance::isTolerated ( const Vector2 & boundDelta,
const SquareMatrix2 & boundToCartesian ) const

Check if the bound position delta is tolerated.

Parameters
boundDeltaThe delta in bound coordinates
boundToCartesianThe transformation matrix from bound to Cartesian
Returns
True if the delta is within tolerance, false otherwise

◆ None()

constexpr auto Acts::BoundaryTolerance::None ( )
staticconstexprnoexcept

No tolerance i.e.

exact boundary check

Returns
BoundaryTolerance configured for no tolerance (exact checking)

◆ operator=() [1/2]

BoundaryTolerance & Acts::BoundaryTolerance::operator= ( BoundaryTolerance && other)
defaultnoexcept

Move assignment operator.

Parameters
otherThe BoundaryTolerance object to move
Returns
Reference to this BoundaryTolerance after moving

◆ operator=() [2/2]

BoundaryTolerance & Acts::BoundaryTolerance::operator= ( const BoundaryTolerance & other)
defaultnoexcept

Copy assignment operator.

Parameters
otherThe BoundaryTolerance object to copy
Returns
Reference to this BoundaryTolerance after copying

◆ toleranceMode()

ToleranceMode Acts::BoundaryTolerance::toleranceMode ( ) const

Get the tolerance mode.

Returns
ToleranceMode indicating how the tolerance should be applied