Belle II Software development
|
Magnetic field map. More...
#include <MagneticField.h>
Public Member Functions | |
MagneticField () | |
Empty Constructor. | |
~MagneticField () | |
Delete all components. | |
MagneticField (const MagneticField &)=delete | |
Disallow copying the magnetic field. | |
MagneticField (MagneticField &&other) noexcept | |
But allow move construction. | |
ROOT::Math::XYZVector | getField (const ROOT::Math::XYZVector &pos) const |
Calculate the magnetic field at a given position. | |
ROOT::Math::XYZVector | getFieldInTesla (const ROOT::Math::XYZVector &pos) const |
Convenience function to get the field directly in Tesla. | |
void | addComponent (MagneticFieldComponent *component) |
Add a new component to the magnetic field. | |
Private Member Functions | |
ClassDef (MagneticField, 1) | |
ROOT dictionary definition. | |
Private Attributes | |
std::vector< MagneticFieldComponent * > | m_components |
Magnetic field components to evaluate the field. | |
Magnetic field map.
It can be used directly using a DBObjPtr<MagneticField> instance in your class. Alternatively there is a BFieldManager class which encapsulates the DBObjPtr already. Field evaluation is then a simple call to BFieldManager::getField().
This class contains the Magnetic field map to be stored in the Database and used during simulation and reconstruction. The field can be assembled from multiple components (constant, 3D, 2D, ...) in different regions. By default all components valid in a certain region will be added to obtain the final field value but components can also be flagged as exclusive in which case only the field of this particular component will be returned.
Definition at line 32 of file MagneticField.h.
|
inline |
|
inline |
Delete all components.
Definition at line 37 of file MagneticField.h.
|
inlinenoexcept |
But allow move construction.
Definition at line 45 of file MagneticField.h.
|
inline |
Add a new component to the magnetic field.
Ownership is taken over by the MagneticField instance
Definition at line 59 of file MagneticField.h.
|
inline |
Convenience function to get the field directly in Tesla.
pos | position where the field should be evaluated in framework units. |
Definition at line 57 of file MagneticField.h.
|
private |
Magnetic field components to evaluate the field.
Definition at line 62 of file MagneticField.h.