DD4hep  1.30.0
Detector Description Toolkit for High Energy Physics
Public Member Functions | Public Attributes | Private Attributes | List of all members
dd4hep::MultipoleField Class Reference

Implementation object of a Multipole magnetic field. More...

#include <FieldTypes.h>

Inheritance diagram for dd4hep::MultipoleField:
dd4hep::CartesianField::Object dd4hep::CartesianField::TypedObject dd4hep::NamedObject

Public Member Functions

 MultipoleField ()
 Initializing constructor. More...
 
virtual void fieldComponents (const double *pos, double *field)
 Call to access the field components at a given location. More...
 
- Public Member Functions inherited from dd4hep::CartesianField::Object
 Object ()
 Default constructor. More...
 
virtual ~Object ()
 Default destructor. More...
 
- Public Member Functions inherited from dd4hep::CartesianField::TypedObject
 NamedObject (const char *nam, const char *typ="")
 Default constructor. More...
 
 NamedObject (const std::string &nam)
 Default constructor. More...
 
 NamedObject (const std::string &nam, const std::string &typ)
 Default constructor. More...
 
 NamedObject ()=default
 Default constructor. More...
 
 NamedObject (const NamedObject &c)=default
 Default constructor. More...
 
 NamedObject (NamedObject &&c)=default
 Default constructor. More...
 
- Public Member Functions inherited from dd4hep::NamedObject
 NamedObject (const char *nam, const char *typ="")
 Initializing constructor. More...
 
 NamedObject (const std::string &nam)
 Initializing constructor. More...
 
 NamedObject (const std::string &nam, const std::string &typ)
 Initializing constructor. More...
 
 NamedObject ()=default
 Standard constructor. More...
 
 NamedObject (const NamedObject &c)=default
 Copy constructor. More...
 
 NamedObject (NamedObject &&c)=default
 Move constructor. More...
 
virtual ~NamedObject ()=default
 Default destructor. More...
 
NamedObjectoperator= (const NamedObject &c)=default
 Assignment operator. More...
 
NamedObjectoperator= (NamedObject &&c)=default
 Move assignment operator. More...
 
const char * GetName () const
 Access name. More...
 
void SetName (const char *nam)
 Set name (used by Handle) More...
 
void SetTitle (const char *tit)
 Set Title (used by Handle) More...
 
const char * GetTitle () const
 Get name (used by Handle) More...
 

Public Attributes

Coefficents coefficents { }
 Multi-pole coefficients. More...
 
Coefficents skews { }
 Multi-pole skews. More...
 
Solid volume { }
 Boundary volume (optional) More...
 
Transform3D transform { }
 Position transformation of the field. Only stored here for reference. More...
 
Transform3D inverse { }
 Inverse position transformation of the field. More...
 
Rotation3D rotation { }
 The rotation part of the transformation. Need to rotate the field. More...
 
double B_z { 0e0 }
 Constant Z field overlay. More...
 
- Public Attributes inherited from dd4hep::CartesianField::Object
Properties properties
 Field extensions. More...
 
- Public Attributes inherited from dd4hep::CartesianField::TypedObject
int field_type { UNKNOWN }
 Field type. More...
 
- Public Attributes inherited from dd4hep::NamedObject
std::string name
 The object name. More...
 
std::string type
 The object type. More...
 

Private Attributes

unsigned char flag { 0 }
 The access to the field will be optimized. Remember properties. More...
 
Transform3D::Point translation { }
 Translation of the transformation. More...
 

Additional Inherited Members

- Public Types inherited from dd4hep::CartesianField::Object
typedef std::vector< double > Coefficents
 Utility definition for concrete implementations. More...
 

Detailed Description

Implementation object of a Multipole magnetic field.

Generic multipole magnetic field using the Multipole approach. The dipole is assumed to be horizontal as it is used for bending beams in large colliders ie. the dipole field lines are vertical.

The different momenta are given by:

\begin{eqnarray*} B_y + i*B_x &=& ( 1/(n-1)! )* C_n * (x + iy)^{n-1} \\ B_sum = B_y + i B_x &=& Sum_{n=1..4} ( 1/(n-1)! )*(b_n + ia_n) (x + iy)^{n-1} \\ \end{eqnarray*}

With C_n being the complex multipole coefficients and b_n the "normal multipole coefficients" and a_n the "skew multipole coefficients".

The maximal momentum used is the octopole momentum.

The lower momenta are:

\begin{eqnarray*} B_y &=& b_2 x - a_2 y \\ B_x &=& b_2 y + a_2 x \\ \end{eqnarray*}

\begin{eqnarray*} B_y + i B_x &=& (1/2) * (b_3 +ia_3) (x^2 + 2ixy - y^2) \\ B_y &=& (1/2) * ( b_3 x^2 - b_3 y^2 - 2 a_3 xy) \\ B_x &=& (1/2) * (a_3 x^2 - a_3 y^2 + 2 b_3 xy) \\ \end{eqnarray*}

\begin{eqnarray*} B_y + i B_x &=& (1/6) * (b_4 +ia_4) (x^3 + 3ix^2y - 3xy^2 -iy^3) \\ B_y &=& (1/6) * (b_4 x^3 - 3 b_4 x y^2 - 3 a_4 x^2 y + a_4 y^3) \\ B_x &=& (1/6) * (3 b_4 x^2 y - b_4 y^3 + a_4 x^3 - 3 a_4 x y^2) \ \ \end{eqnarray*}

The defined field components only apply within the shape 'volume'. If 'volume' is an invalid shape (ie. not defined), then the field components are valied throughout the 'universe'.

See also
http://cas.web.cern.ch/sites/cas.web.cern.ch/files/lectures/bruges-2009/wolski-1.pdf
http://cas.web.cern.ch/sites/cas.web.cern.ch/files/lectures/varna-2010/brandt-1-web.pdf
https://en.wikipedia.org/wiki/Multipole_magnet
Author
M.Frank
Version
1.0

Definition at line 152 of file FieldTypes.h.

Constructor & Destructor Documentation

◆ MultipoleField()

MultipoleField::MultipoleField ( )

Initializing constructor.

Definition at line 101 of file FieldTypes.cpp.

Member Function Documentation

◆ fieldComponents()

void MultipoleField::fieldComponents ( const double *  pos,
double *  field 
)
virtual

Call to access the field components at a given location.

Compute the field components at a given location and add to given field.

Implements dd4hep::CartesianField::Object.

Definition at line 106 of file FieldTypes.cpp.

Member Data Documentation

◆ B_z

double dd4hep::MultipoleField::B_z { 0e0 }

Constant Z field overlay.

Definition at line 167 of file FieldTypes.h.

◆ coefficents

Coefficents dd4hep::MultipoleField::coefficents { }

Multi-pole coefficients.

Definition at line 155 of file FieldTypes.h.

◆ flag

unsigned char dd4hep::MultipoleField::flag { 0 }
private

The access to the field will be optimized. Remember properties.

Definition at line 171 of file FieldTypes.h.

◆ inverse

Transform3D dd4hep::MultipoleField::inverse { }

Inverse position transformation of the field.

Definition at line 163 of file FieldTypes.h.

◆ rotation

Rotation3D dd4hep::MultipoleField::rotation { }

The rotation part of the transformation. Need to rotate the field.

Definition at line 165 of file FieldTypes.h.

◆ skews

Coefficents dd4hep::MultipoleField::skews { }

Multi-pole skews.

Definition at line 157 of file FieldTypes.h.

◆ transform

Transform3D dd4hep::MultipoleField::transform { }

Position transformation of the field. Only stored here for reference.

Definition at line 161 of file FieldTypes.h.

◆ translation

Transform3D::Point dd4hep::MultipoleField::translation { }
private

Translation of the transformation.

Definition at line 173 of file FieldTypes.h.

◆ volume

Solid dd4hep::MultipoleField::volume { }

Boundary volume (optional)

Definition at line 159 of file FieldTypes.h.


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