ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::SharedBField< BField > Class Template Reference

allows to use a shared magnetic field in several places and with multiple steppers mainly targeted to save memory More...

#include <acts/blob/master/Core/include/Acts/MagneticField/SharedBField.hpp>

Public Types

using Cache = typename BField::Cache
 

Public Member Functions

 SharedBField (std::shared_ptr< const BField > bField)
 the constructur with a shared pointer
 
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 > &derivative) const
 retrieve magnetic field value & its gradient
 
Vector3D getFieldGradient (const Vector3D &position, ActsMatrixD< 3, 3 > &derivative, Cache &cache) const
 retrieve magnetic field value & its gradient
 

Private Attributes

std::shared_ptr< const BField > m_bField
 

Detailed Description

template<typename BField>
class Acts::SharedBField< BField >

allows to use a shared magnetic field in several places and with multiple steppers mainly targeted to save memory

Definition at line 21 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 21 of file SharedBField.hpp

Member Typedef Documentation

template<typename BField>
using Acts::SharedBField< BField >::Cache = typename BField::Cache

Definition at line 24 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 24 of file SharedBField.hpp

Constructor & Destructor Documentation

template<typename BField>
Acts::SharedBField< BField >::SharedBField ( std::shared_ptr< const BField >  bField)
inline

the constructur with a shared pointer

Note
since it is a shared field, we enforce it to be const
Template Parameters
bFieldis the shared BField to be stored

Definition at line 29 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 29 of file SharedBField.hpp

Member Function Documentation

template<typename BField>
Vector3D Acts::SharedBField< BField >::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 36 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 36 of file SharedBField.hpp

References Acts::SharedBField< BField >::m_bField.

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

Retrieve magnetic field value.

Parameters
[in]positionglobal 3D position
[in,out]cacheCache object, passed through to wrapped BField

Definition at line 44 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 44 of file SharedBField.hpp

References Acts::SharedBField< BField >::m_bField.

template<typename BField>
Vector3D Acts::SharedBField< BField >::getFieldGradient ( const Vector3D position,
ActsMatrixD< 3, 3 > &  derivative 
) 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 56 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 56 of file SharedBField.hpp

References Acts::SharedBField< BField >::m_bField.

template<typename BField>
Vector3D Acts::SharedBField< BField >::getFieldGradient ( const Vector3D position,
ActsMatrixD< 3, 3 > &  derivative,
Cache 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, passed through to wrapped BField
Returns
magnetic field vector
Note
currently the derivative is not calculated

Definition at line 70 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 70 of file SharedBField.hpp

References Acts::SharedBField< BField >::m_bField.

Member Data Documentation

template<typename BField>
std::shared_ptr<const BField> Acts::SharedBField< BField >::m_bField
private

Definition at line 76 of file SharedBField.hpp.

View newest version in sPHENIX GitHub at line 76 of file SharedBField.hpp

Referenced by Acts::SharedBField< BField >::getField(), and Acts::SharedBField< BField >::getFieldGradient().


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