EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::InterpolatedBFieldMap< Mapper_t > Class Template Referencefinal

interpolate magnetic field value from field values on a given grid More...

#include <acts/blob/sPHENIX/Core/include/Acts/MagneticField/InterpolatedBFieldMap.hpp>

+ Collaboration diagram for Acts::InterpolatedBFieldMap< Mapper_t >:

Classes

struct  Cache
 
struct  Config
 configuration object for magnetic field interpolation More...
 

Public Member Functions

 InterpolatedBFieldMap (Config config)
 create interpolated magnetic field map
 
Config getConfiguration () const
 get configuration object
 
Vector3D getField (const Vector3D &position) const
 retrieve magnetic field value
 
Vector3D getField (const Vector3D &position, Cache &cache) const
 retrieve magnetic field value
 
Vector3D getFieldGradient (const Vector3D &position, ActsMatrixD< 3, 3 > &) const
 retrieve magnetic field value & its gradient
 
Vector3D getFieldGradient (const Vector3D &position, ActsMatrixD< 3, 3 > &, Cache &) const
 retrieve magnetic field value & its gradient
 
double getScale () const
 get global scaling factor for magnetic field
 
Mapper_t getMapper () const
 convenience method to access underlying field mapper
 
bool isInside (const Vector3D &position) const
 check whether given 3D position is inside look-up domain
 
void setConfiguration (const Config &config)
 update configuration
 

Private Member Functions

Mapper_t::FieldCell getFieldCell (const Vector3D &position) const
 retrieve field cell for given position
 

Private Attributes

Config m_config
 configuration object
 

Detailed Description

template<typename Mapper_t>
class Acts::InterpolatedBFieldMap< Mapper_t >

interpolate magnetic field value from field values on a given grid

This class implements a magnetic field service which is initialized by a field map defined by:

  • a list of field values on a regular grid in some n-Dimensional space,
  • a transformation of global 3D coordinates onto this n-Dimensional space.
  • a transformation of local n-Dimensional magnetic field coordinates into global (cartesian) 3D coordinates

The magnetic field value for a given global position is then determined by:

  • mapping the position onto the grid,
  • looking up the magnetic field values on the closest grid points,
  • doing a linear interpolation of these magnetic field values.

Definition at line 232 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 232 of file InterpolatedBFieldMap.hpp

Constructor & Destructor Documentation

template<typename Mapper_t>
Acts::InterpolatedBFieldMap< Mapper_t >::InterpolatedBFieldMap ( Config  config)
inline

create interpolated magnetic field map

Parameters
[in]configconfiguration object

Definition at line 265 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 265 of file InterpolatedBFieldMap.hpp

Member Function Documentation

template<typename Mapper_t>
Config Acts::InterpolatedBFieldMap< Mapper_t >::getConfiguration ( ) const
inline

get configuration object

Returns
copy of the internal configuration object

Definition at line 270 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 270 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config.

template<typename Mapper_t>
Vector3D Acts::InterpolatedBFieldMap< Mapper_t >::getField ( const Vector3D position) const
inline

retrieve magnetic field value

Parameters
[in]positionglobal 3D position
Returns
magnetic field vector at given position

Definition at line 277 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 277 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::mapper.

template<typename Mapper_t>
Vector3D Acts::InterpolatedBFieldMap< Mapper_t >::getField ( const Vector3D position,
Cache cache 
) const
inline

retrieve magnetic field value

Parameters
[in]positionglobal 3D position
[in,out]cacheCache object. Contains field cell used for interpolation
Returns
magnetic field vector at given position

Definition at line 288 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 288 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::Cache::fieldCell, and Acts::InterpolatedBFieldMap< Mapper_t >::getFieldCell().

+ Here is the call graph for this function:

template<typename Mapper_t>
Mapper_t::FieldCell Acts::InterpolatedBFieldMap< Mapper_t >::getFieldCell ( const Vector3D position) const
inlineprivate

retrieve field cell for given position

Parameters
[in]positionglobal 3D position
Returns
field cell containing the given global position
Precondition
The given position must lie within the range of the underlying magnetic field map.

Definition at line 356 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 356 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::mapper.

Referenced by Acts::InterpolatedBFieldMap< Mapper_t >::getField().

+ Here is the caller graph for this function:

template<typename Mapper_t>
Vector3D Acts::InterpolatedBFieldMap< Mapper_t >::getFieldGradient ( const Vector3D position,
ActsMatrixD< 3, 3 > &   
) const
inline

retrieve magnetic field value & its gradient

Parameters
[in]positionglobal 3D position
[out]derivativegradient of magnetic field vector as (3x3) matrix
Returns
magnetic field vector
Note
currently the derivative is not calculated

Definition at line 303 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 303 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::mapper.

template<typename Mapper_t>
Vector3D Acts::InterpolatedBFieldMap< Mapper_t >::getFieldGradient ( const Vector3D position,
ActsMatrixD< 3, 3 > &  ,
Cache  
) const
inline

retrieve magnetic field value & its gradient

Parameters
[in]positionglobal 3D position
[out]derivativegradient of magnetic field vector as (3x3) matrix
[in,out]cacheCache object. Contains field cell used for
Returns
magnetic field vector
Note
currently the derivative is not calculated
Cache is not used currently

Definition at line 318 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 318 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::mapper.

template<typename Mapper_t>
Mapper_t Acts::InterpolatedBFieldMap< Mapper_t >::getMapper ( ) const
inline

convenience method to access underlying field mapper

Returns
the field mapper

Definition at line 332 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 332 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::mapper.

template<typename Mapper_t>
double Acts::InterpolatedBFieldMap< Mapper_t >::getScale ( ) const
inline

get global scaling factor for magnetic field

Returns
global factor for scaling the magnetic field

Definition at line 327 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 327 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::scale.

template<typename Mapper_t>
bool Acts::InterpolatedBFieldMap< Mapper_t >::isInside ( const Vector3D position) const
inline

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

Parameters
[in]positionglobal 3D position
Returns
true if position is inside the defined BField map, otherwise false

Definition at line 339 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 339 of file InterpolatedBFieldMap.hpp

References Acts::InterpolatedBFieldMap< Mapper_t >::m_config, and Acts::InterpolatedBFieldMap< Mapper_t >::Config::mapper.

template<typename Mapper_t>
void Acts::InterpolatedBFieldMap< Mapper_t >::setConfiguration ( const Config config)
inline

update configuration

Parameters
[in]confignew configuration object

Definition at line 346 of file InterpolatedBFieldMap.hpp.

View newest version in sPHENIX GitHub at line 346 of file InterpolatedBFieldMap.hpp

References configureMap::config, and Acts::InterpolatedBFieldMap< Mapper_t >::m_config.

Member Data Documentation


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