ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::InterpolatedMagneticField Class Referenceabstract

Base class for interpolated magnetic field providers. More...

#include <Acts/MagneticField/InterpolatedBFieldMap.hpp>

Inheritance diagram for Acts::InterpolatedMagneticField:
[legend]
Collaboration diagram for Acts::InterpolatedMagneticField:
[legend]

Public Member Functions

virtual Vector3 getFieldUnchecked (const Vector3 &position) const =0
 Get a field value without checking if the lookup position is within the interpolation domain.
virtual std::vector< double > getMax () const =0
 get the maximum value of all axes of the field map
virtual std::vector< double > getMin () const =0
 get the minimum value of all axes of the field map
virtual std::vector< std::size_t > getNBins () const =0
 get the number of bins for all axes of the field map
virtual bool isInside (const Vector3 &position) const =0
 check whether given 3D position is inside look-up domain
Public Member Functions inherited from Acts::MagneticFieldProvider
virtual ~MagneticFieldProvider ()=default
virtual Result< Vector3getField (const Vector3 &position, Cache &cache) const =0
 Retrieve magnetic field value at a given location.
virtual Cache makeCache (const MagneticFieldContext &mctx) const =0
 Make an opaque cache for the magnetic field.

Additional Inherited Members

Public Types inherited from Acts::MagneticFieldProvider
using Cache = Acts::AnyBase<sizeof(char) * 512>
 Opaque cache type that can store arbitrary implementation specific cache data.

Detailed Description

Base class for interpolated magnetic field providers.

This class can be used for non-trivial magnetic field implementations.

The key idea here is to calculate an interpolated value of the magnetic field from a grid of known field values. In 3D, this means the interpolation is done from the 8 corner points of a field cell. The field cell can be retrieved for any given position. Since during typical access patterns, e.g. the propagation, subsequent steps are relatively likely to not cross the field cell boundary, the field cell can be cached.

Illustration of the field cell concept. Subsequent steps are clustered in the same field cell. The field cell only needs to be refetched when the propagation crosses into the next grid region.

Member Function Documentation

◆ getFieldUnchecked()

virtual Vector3 Acts::InterpolatedMagneticField::getFieldUnchecked ( const Vector3 & position) const
pure virtual

Get a field value without checking if the lookup position is within the interpolation domain.

Parameters
positionThe lookup position in 3D
Returns
The field value at position

Implemented in Acts::InterpolatedBFieldMap< grid_t >.

◆ getMax()

virtual std::vector< double > Acts::InterpolatedMagneticField::getMax ( ) const
pure virtual

get the maximum value of all axes of the field map

Returns
vector returning the maxima of all field map axes

Implemented in Acts::InterpolatedBFieldMap< grid_t >.

◆ getMin()

virtual std::vector< double > Acts::InterpolatedMagneticField::getMin ( ) const
pure virtual

get the minimum value of all axes of the field map

Returns
vector returning the minima of all field map axes

Implemented in Acts::InterpolatedBFieldMap< grid_t >.

◆ getNBins()

virtual std::vector< std::size_t > Acts::InterpolatedMagneticField::getNBins ( ) const
pure virtual

get the number of bins for all axes of the field map

Returns
vector returning number of bins for all field map axes

Implemented in Acts::InterpolatedBFieldMap< grid_t >.

◆ isInside()

virtual bool Acts::InterpolatedMagneticField::isInside ( const Vector3 & position) const
pure virtual

check whether given 3D position is inside look-up domain

Parameters
[in]positionglobal 3D position
Returns
true if position is inside the defined look-up grid, otherwise false

Implemented in Acts::InterpolatedBFieldMap< grid_t >.