BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
BmnNewFieldMap Class Reference

Field Map does not have any symmetries w.r.t coordinate axises. More...

#include <BmnNewFieldMap.h>

Inheritance diagram for BmnNewFieldMap:
Collaboration diagram for BmnNewFieldMap:

Public Member Functions

 BmnNewFieldMap ()
 BmnNewFieldMap (const char *mapFileName)
 BmnNewFieldMap (BmnFieldPar *fieldPar)
virtual ~BmnNewFieldMap ()
virtual Double_t GetBx (Double_t x, Double_t y, Double_t z)
virtual Double_t GetBy (Double_t x, Double_t y, Double_t z)
virtual Double_t GetBz (Double_t x, Double_t y, Double_t z)
Bool_t IsInside (Double_t x, Double_t y, Double_t z, Int_t &ix, Int_t &iy, Int_t &iz, Double_t &dx, Double_t &dy, Double_t &dz)
void FillParContainer ()
 BmnNewFieldMap ()
 BmnNewFieldMap (const char *mapFileName)
 BmnNewFieldMap (BmnFieldPar *fieldPar)
virtual ~BmnNewFieldMap ()
virtual Double_t GetBx (Double_t x, Double_t y, Double_t z)
virtual Double_t GetBy (Double_t x, Double_t y, Double_t z)
virtual Double_t GetBz (Double_t x, Double_t y, Double_t z)
Bool_t IsInside (Double_t x, Double_t y, Double_t z, Int_t &ix, Int_t &iy, Int_t &iz, Double_t &dx, Double_t &dy, Double_t &dz)
void FillParContainer ()
Public Member Functions inherited from BmnFieldMap
 BmnFieldMap ()
 BmnFieldMap (const char *mapFileName)
 BmnFieldMap (BmnFieldPar *fieldPar)
virtual ~BmnFieldMap ()
virtual void Init ()
void WriteAsciiFile (const char *asciiFileName)
 Write the field map to an ASCII file.
void WriteRootFile (const char *rootFileName, const char *mapFileName)
 Write field map data to a ROOT file.
void SetPosition (Double_t x, Double_t y, Double_t z)
 Set the position of the field centre.
void SetScale (Double_t factor)
 Set a global field scaling factor.
void SetFieldOff (Bool_t is_off=kTRUE)
 Turn magnetic field off.
void SetFileName (const char *map_file_name)
 Set field map file path.
Double_t GetXmin () const
 Accessors to field parameters in local coordinate system.
Double_t GetYmin () const
Double_t GetZmin () const
Double_t GetXmax () const
Double_t GetYmax () const
Double_t GetZmax () const
Double_t GetXstep () const
Double_t GetYstep () const
Double_t GetZstep () const
Int_t GetNx () const
Int_t GetNy () const
Int_t GetNz () const
Double_t GetPositionX () const
 Accessor to field centre position in global system.
Double_t GetPositionY () const
Double_t GetPositionZ () const
Double_t GetScale () const
 Accessor to global scaling factor.
Bool_t IsFieldOff () const
 Whether magnetic field is off.
TArrayF * GetBx () const
 Accessors to the field value arrays.
TArrayF * GetBy () const
TArrayF * GetBz () const
const char * GetFileName ()
 Accessor to field map file.
virtual void Print (Option_t *) const
 Screen output.
void Reset ()
 Reset the field parameters and data.
 BmnFieldMap ()
 BmnFieldMap (const char *mapFileName)
 BmnFieldMap (BmnFieldPar *fieldPar)
virtual ~BmnFieldMap ()
virtual void Init ()
void WriteAsciiFile (const char *asciiFileName)
 Write the field map to an ASCII file.
void WriteRootFile (const char *rootFileName, const char *mapFileName)
 Write field map data to a ROOT file.
void SetPosition (Double_t x, Double_t y, Double_t z)
 Set the position of the field centre.
void SetScale (Double_t factor)
 Set a global field scaling factor.
void SetFieldOff (Bool_t is_off=kTRUE)
 Turn magnetic field off.
void SetFileName (const char *map_file_name)
 Set field map file path.
Double_t GetXmin () const
 Accessors to field parameters in local coordinate system.
Double_t GetYmin () const
Double_t GetZmin () const
Double_t GetXmax () const
Double_t GetYmax () const
Double_t GetZmax () const
Double_t GetXstep () const
Double_t GetYstep () const
Double_t GetZstep () const
Int_t GetNx () const
Int_t GetNy () const
Int_t GetNz () const
Double_t GetPositionX () const
 Accessor to field centre position in global system.
Double_t GetPositionY () const
Double_t GetPositionZ () const
Double_t GetScale () const
 Accessor to global scaling factor.
Bool_t IsFieldOff () const
 Whether magnetic field is off.
TArrayF * GetBx () const
 Accessors to the field value arrays.
TArrayF * GetBy () const
TArrayF * GetBz () const
const char * GetFileName ()
 Accessor to field map file.
virtual void Print (Option_t *) const
 Screen output.
void Reset ()
 Reset the field parameters and data.

Protected Member Functions

Double_t FieldInterpolate (TArrayF *fcomp, Double_t x, Double_t y, Double_t z)
Double_t FieldInterpolate (TArrayF *fcomp, Double_t x, Double_t y, Double_t z)
Protected Member Functions inherited from BmnFieldMap
void ReadAsciiFile (const char *asciiFileName)
 Reset the field parameters and data.
void ReadRootFile (const char *rootFileName)
 Read field map from a ROOT file.
void ReadRootFileNewFormat (const char *rootFileName)
void ReadRootFileNewFormatExtrap (const char *rootFileName)
void SetField (const BmnFieldMapData *data)
 Set field parameters and data.
Double_t Interpolate (Double_t dx, Double_t dy, Double_t dz)
 Get field values by interpolation of the grid.
void ReadAsciiFile (const char *asciiFileName)
 Reset the field parameters and data.
void ReadRootFile (const char *rootFileName)
 Read field map from a ROOT file.
void ReadRootFileNewFormat (const char *rootFileName)
void ReadRootFileNewFormatExtrap (const char *rootFileName)
void SetField (const BmnFieldMapData *data)
 Set field parameters and data.
Double_t Interpolate (Double_t dx, Double_t dy, Double_t dz)
 Get field values by interpolation of the grid.

Additional Inherited Members

Static Public Member Functions inherited from BmnFieldMap
static TString GetMapFilePath (TString mapName)
 Get the expanded path to the field map file in the current installation.
static TString GetMapFilePath (TString mapName)
 Get the expanded path to the field map file in the current installation.
Protected Attributes inherited from BmnFieldMap
Double_t fScale
 Global scaling factor (w.r.t.
Double_t fPosX
 Field centre position in global coordinates.
Double_t fPosY
Double_t fPosZ
Double_t fPosBx
Double_t fPosBy
Double_t fPosBz
Double_t fXmin
 Field limits in local coordinate system.
Double_t fXmax
Double_t fXstep
Double_t fYmin
Double_t fYmax
Double_t fYstep
Double_t fZmin
Double_t fZmax
Double_t fZstep
Int_t fNx
 Number of grid points.
Int_t fNy
Int_t fNz
TArrayF * fBx
 Arrays with the field values.
TArrayF * fBy
TArrayF * fBz
Double_t fHa [2][2][2]
 Variables for temporary storage Used in the very frequently called method GetFieldValue.
Double_t fHb [2][2]
 Field at corners of a grid cell.
Double_t fHc [2]
 Interpolated field (2-dim).
Bool_t fDebugInfo
 Interpolated field (1-dim).
Bool_t fIsOff
 Whether magnetic field is off.

Detailed Description

Definition at line 15 of file BmnNewFieldMap.h.

Constructor & Destructor Documentation

◆ BmnNewFieldMap() [1/6]

BmnNewFieldMap::BmnNewFieldMap ( )

Definition at line 15 of file BmnNewFieldMap.cxx.

References BmnFieldMap::BmnFieldMap().

Referenced by FieldInterpolate().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ BmnNewFieldMap() [2/6]

BmnNewFieldMap::BmnNewFieldMap ( const char * mapFileName)

Definition at line 21 of file BmnNewFieldMap.cxx.

References BmnFieldMap::BmnFieldMap().

Here is the call graph for this function:

◆ BmnNewFieldMap() [3/6]

BmnNewFieldMap::BmnNewFieldMap ( BmnFieldPar * fieldPar)

Definition at line 27 of file BmnNewFieldMap.cxx.

References BmnFieldMap::BmnFieldMap().

Here is the call graph for this function:

◆ ~BmnNewFieldMap() [1/2]

BmnNewFieldMap::~BmnNewFieldMap ( )
virtual

Definition at line 33 of file BmnNewFieldMap.cxx.

◆ BmnNewFieldMap() [4/6]

BmnNewFieldMap::BmnNewFieldMap ( )

◆ BmnNewFieldMap() [5/6]

BmnNewFieldMap::BmnNewFieldMap ( const char * mapFileName)

◆ BmnNewFieldMap() [6/6]

BmnNewFieldMap::BmnNewFieldMap ( BmnFieldPar * fieldPar)

◆ ~BmnNewFieldMap() [2/2]

virtual BmnNewFieldMap::~BmnNewFieldMap ( )
virtual

Member Function Documentation

◆ FieldInterpolate() [1/2]

Double_t BmnNewFieldMap::FieldInterpolate ( TArrayF * fcomp,
Double_t x,
Double_t y,
Double_t z )
protected

Definition at line 83 of file BmnNewFieldMap.cxx.

References TArrayF::At(), BmnFieldMap::fHa, BmnFieldMap::fNy, BmnFieldMap::fNz, BmnFieldMap::fXmax, BmnFieldMap::fXmin, BmnFieldMap::fXstep, BmnFieldMap::fYmax, BmnFieldMap::fYmin, BmnFieldMap::fYstep, BmnFieldMap::fZmax, BmnFieldMap::fZmin, BmnFieldMap::fZstep, BmnFieldMap::Interpolate(), x, y, and z.

Referenced by GetBx(), GetBy(), and GetBz().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FieldInterpolate() [2/2]

Double_t BmnNewFieldMap::FieldInterpolate ( TArrayF * fcomp,
Double_t x,
Double_t y,
Double_t z )
protected

References BmnNewFieldMap(), x, y, and z.

Here is the call graph for this function:

◆ FillParContainer() [1/2]

void BmnNewFieldMap::FillParContainer ( )
virtual

Implements BmnFieldMap.

Definition at line 126 of file BmnNewFieldMap.cxx.

References BmnFieldPar::SetParameters().

Here is the call graph for this function:

◆ FillParContainer() [2/2]

void BmnNewFieldMap::FillParContainer ( )
virtual

Implements BmnFieldMap.

◆ GetBx() [1/2]

Double_t BmnNewFieldMap::GetBx ( Double_t x,
Double_t y,
Double_t z )
virtual

Implements BmnFieldMap.

Definition at line 35 of file BmnNewFieldMap.cxx.

References BmnFieldMap::fBx, FieldInterpolate(), x, y, and z.

Here is the call graph for this function:

◆ GetBx() [2/2]

virtual Double_t BmnNewFieldMap::GetBx ( Double_t x,
Double_t y,
Double_t z )
virtual

Implements BmnFieldMap.

References x, y, and z.

◆ GetBy() [1/2]

Double_t BmnNewFieldMap::GetBy ( Double_t x,
Double_t y,
Double_t z )
virtual

Implements BmnFieldMap.

Definition at line 40 of file BmnNewFieldMap.cxx.

References BmnFieldMap::fBy, FieldInterpolate(), x, y, and z.

Here is the call graph for this function:

◆ GetBy() [2/2]

virtual Double_t BmnNewFieldMap::GetBy ( Double_t x,
Double_t y,
Double_t z )
virtual

Implements BmnFieldMap.

References x, y, and z.

◆ GetBz() [1/2]

Double_t BmnNewFieldMap::GetBz ( Double_t x,
Double_t y,
Double_t z )
virtual

Implements BmnFieldMap.

Definition at line 45 of file BmnNewFieldMap.cxx.

References BmnFieldMap::fBz, FieldInterpolate(), x, y, and z.

Here is the call graph for this function:

◆ GetBz() [2/2]

virtual Double_t BmnNewFieldMap::GetBz ( Double_t x,
Double_t y,
Double_t z )
virtual

Implements BmnFieldMap.

References x, y, and z.

◆ IsInside() [1/2]

◆ IsInside() [2/2]

Bool_t BmnNewFieldMap::IsInside ( Double_t x,
Double_t y,
Double_t z,
Int_t & ix,
Int_t & iy,
Int_t & iz,
Double_t & dx,
Double_t & dy,
Double_t & dz )
virtual

Implements BmnFieldMap.

References x, y, and z.


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