|
CbmRoot
|
Magnetic field manager class. More...
#include <KfField.h>
Public Types | |
| template<EFieldMode Mode> | |
| using | ConcreteField_t = typename detail::ConcreteField<T, Mode> |
| using | Interpolated_t = ConcreteField_t<EFieldMode::Interpolated> |
| using | Original_t = ConcreteField_t<EFieldMode::Original> |
| using | FieldVariant_t = typename std::variant<Interpolated_t, Original_t> |
| using | SlicesContainer_t = typename Interpolated_t::SlicesContainer_t |
Public Member Functions | |
| Field ()=default | |
| Default constructor. | |
| Field (const Field &)=default | |
| Copy constructor for the same class. | |
| Field (Field &&)=default | |
| Move constructor. | |
| ~Field ()=default | |
| Destructor. | |
| Field & | operator= (const Field &other)=default |
| Copy assignment operator. | |
| Field & | operator= (Field &&other)=default |
| Move assignment operator. | |
| template<EFieldMode FieldMode> | |
| const ConcreteField_t< FieldMode > * | GetConcrete () const |
| Gets a pointer to the concrete field instance. | |
| EFieldMode | GetFieldMode () const |
| Gets stored mode of the field. | |
| FieldValue< T > | GetFieldValue (int sliceId, T x, T y) const |
| Creates field value object. | |
| const FieldValue< T > | GetFieldValueForLine (int sliceId, const TrackParam< T > &tp) const |
| Creates field value for the intersection with a straight track. | |
| EFieldType | GetFieldType () const |
| Gets field type. | |
| FieldRegion< T > | GetFieldRegion (const FieldValue< T > &b0, const FieldValue< T > &b1, const FieldValue< T > &b2) const |
| Creates field region object from nodes. | |
| const FieldRegion< T > & | GetPrimVertexField () const |
| Gets field region near primary vertex. | |
| void | RemoveSlice (int iLayer) |
| Removes a field slice. | |
| std::string | ToString (int indentLevel, int verbose) const |
| String representation of the class. | |
Static Public Member Functions | |
| template<EFieldMode FieldMode, typename... Args> | |
| static constexpr Field | Create (Args... args) |
| Creates a field (compile-time mode selection) | |
| template<typename I> | |
| static Field | CopyConvert (const Field< I > &other) |
| Creates a converted copy of the field with a different floating point type. | |
Private Member Functions | |
| Field (SlicesContainer_t &fieldSlices, FieldRegion< T > &vtxField, EFieldType fieldType, Tag< EFieldMode::Interpolated >) | |
| Constructor for interpolated field. | |
| Field (FieldFn_t fieldFn, std::vector< T > &fieldSliceZ, FieldRegion< T > &vtxField, EFieldType fieldType, Tag< EFieldMode::Original >) | |
| Constructor for original field. | |
| template<typename I, EFieldMode FieldMode> | |
| Field (const Field< I > &other, Tag< FieldMode >) | |
| Constructor from a field of another type. | |
| template<class Archive> | |
| void | load (Archive &ar, const unsigned int) |
| Serialization load method. | |
| template<class Archive> | |
| void | save (Archive &ar, const unsigned int) const |
| Serialization save method. | |
| template<class Archive> | |
| void | serialize (Archive &ar, const unsigned int version) |
| Serialization method. | |
Private Attributes | |
| FieldVariant_t | fFieldVariant |
| Concrete field implementation. | |
Friends | |
| template<typename> | |
| class | Field |
| class | boost::serialization::access |
Magnetic field manager class.
| T | Underlying floating point type (float/double/fvec) |
| using cbm::algo::kf::Field< T >::ConcreteField_t = typename detail::ConcreteField<T, Mode> |
| using cbm::algo::kf::Field< T >::FieldVariant_t = typename std::variant<Interpolated_t, Original_t> |
| using cbm::algo::kf::Field< T >::Interpolated_t = ConcreteField_t<EFieldMode::Interpolated> |
| using cbm::algo::kf::Field< T >::Original_t = ConcreteField_t<EFieldMode::Original> |
| using cbm::algo::kf::Field< T >::SlicesContainer_t = typename Interpolated_t::SlicesContainer_t |
|
default |
Default constructor.
|
default |
Copy constructor for the same class.
References Field.
|
default |
Move constructor.
References Field.
|
default |
Destructor.
|
inlineprivate |
|
inlineprivate |
Constructor for original field.
| fieldFn | Magnetic field function |
| fieldSliceZ | z-coordinates of field slices (NOTE: resource is moved) |
| vtxField | Field in the primary vertex region (NOTE: resource is moved) |
| fieldType | A type of the field |
Definition at line 439 of file KfField.h.
References fFieldVariant.
|
inlineprivate |
Constructor from a field of another type.
| I | Underlying floating point type of another field region |
Definition at line 449 of file KfField.h.
References fFieldVariant, and Field.
|
inlinestatic |
Creates a converted copy of the field with a different floating point type.
| I | underlying type of the class |
| other | A source field of different type |
Definition at line 328 of file KfField.h.
References fFieldVariant, and Field.
|
inlinestaticconstexpr |
Creates a field (compile-time mode selection)
| FieldMode | Mode of the field |
| args | Parameters for construction of the concrete field |
Parameters for FieldMode == EFieldMode::Interpolated: (1) std::vector<FieldSlices<T>>& vector of field slices (moved) (2) FieldRegion<t>& a field region near target (3) EFieldType a type of the field
Parameters for FieldMode == EFieldMode::Original: (1) FieldFn_t field function (2) std::vector<T> vector of reference z-positions of field slices (moved) (3) FieldRegion<t>& a field region near target (4) EFieldType a type of the field
Definition at line 319 of file KfField.h.
References Field.
|
inline |
Gets a pointer to the concrete field instance.
| FieldMode | Field mode |
Definition at line 338 of file KfField.h.
References fFieldVariant.
|
inline |
Gets stored mode of the field.
Definition at line 345 of file KfField.h.
References fFieldVariant.
|
inline |
Creates field region object from nodes.
| n0 | First node |
| n1 | Second node |
| n2 | Third node |
Makes field region object
| b0 | Field value in the first node |
| b1 | Field value in the second node |
| b2 | Field value in the third node |
Definition at line 393 of file KfField.h.
References fFieldVariant.
|
inline |
|
inline |
Creates field value object.
| sliceId | Index of slice |
| x | x-coordinate of the point [cm] |
| y | y-coordinate of the point [cm] |
Definition at line 355 of file KfField.h.
References fFieldVariant, x, and y.
|
inline |
Creates field value for the intersection with a straight track.
| sliceID | Index of slice |
| tp | Track parameter set |
Definition at line 365 of file KfField.h.
References fFieldVariant.
|
inline |
Gets field region near primary vertex.
Definition at line 406 of file KfField.h.
References fFieldVariant.
|
inlineprivate |
|
default |
Copy assignment operator.
References Field.
|
default |
Move assignment operator.
References Field.
|
inline |
Removes a field slice.
| iLayer | Index of field slice |
Definition at line 414 of file KfField.h.
References fFieldVariant.
|
inlineprivate |
|
inlineprivate |
| std::string Field::ToString | ( | int | indentLevel, |
| int | verbose ) const |
String representation of the class.
| indentLevel | Indent level of the string output |
| verbose | Verbosity level |
Definition at line 61 of file KfField.cxx.
References fFieldVariant, and v.
|
friend |
Definition at line 274 of file KfField.h.
References Field.
Referenced by CopyConvert(), Create(), Field, Field(), Field(), Field(), operator=(), and operator=().
|
private |
Concrete field implementation.
Definition at line 488 of file KfField.h.
Referenced by CopyConvert(), Field(), Field(), Field(), GetConcrete(), GetFieldMode(), GetFieldRegion(), GetFieldType(), GetFieldValue(), GetFieldValueForLine(), GetPrimVertexField(), load(), RemoveSlice(), save(), and ToString().