OPAL (Object Oriented Parallel Accelerator Library)  2021.1.99
OPAL
Public Member Functions | Private Attributes | List of all members
BDipoleField Class Reference

The field of a magnetic dipole. More...

#include <BDipoleField.h>

Inheritance diagram for BDipoleField:
Inheritance graph
[legend]
Collaboration diagram for BDipoleField:
Collaboration graph
[legend]

Public Member Functions

 BDipoleField ()
 Default constructor. More...
 
virtual ~BDipoleField ()
 
virtual BVector Bfield (const Point3D &P) const
 Get field. More...
 
virtual BVector Bfield (const Point3D &P, double t) const
 Get field. More...
 
virtual double getBx () const
 Get horizontal component. More...
 
virtual double getBy () const
 Get vertical component. More...
 
virtual void setBx (double Bx)
 Set horizontal component. More...
 
virtual void setBy (double By)
 Set vertical component. More...
 
BDipoleFieldaddField (const BDipoleField &field)
 Add to field. More...
 
BDipoleFieldsubtractField (const BDipoleField &field)
 Subtract from field. More...
 
virtual void scale (double scalar)
 Scale the field. More...
 
- Public Member Functions inherited from ConstBField
 ConstBField ()
 Default constructor. More...
 
virtual ~ConstBField ()
 
virtual double getBz () const
 Get component. More...
 
virtual void setBz (double)
 Set component. More...
 
- Public Member Functions inherited from StaticMagneticField
 StaticMagneticField ()
 
virtual ~StaticMagneticField ()
 
- Public Member Functions inherited from EMField
 EMField ()
 Default constructor. More...
 
 EMField (const EMField &right)
 
virtual ~EMField ()
 
const EMFieldoperator= (const EMField &right)
 
virtual EVector Efield (const Point3D &P) const
 Get field. More...
 
virtual EVector Efield (const Point3D &P, double t) const
 Get field. More...
 
virtual EBVectors EBfield (const Point3D &P) const
 Get field. More...
 
virtual EBVectors EBfield (const Point3D &P, double t) const
 Get field. More...
 

Private Attributes

double Bx
 
double By
 

Additional Inherited Members

- Static Public Attributes inherited from EMField
static const EVector ZeroEfield
 The constant representing a zero electric field. More...
 
static const BVector ZeroBfield
 The constant representing a zero magnetic field. More...
 
static const EBVectors ZeroEBfield
 The constant representing a zero electromagnetic field. More...
 

Detailed Description

The field of a magnetic dipole.

Definition at line 31 of file BDipoleField.h.

Constructor & Destructor Documentation

◆ BDipoleField()

BDipoleField::BDipoleField ( )

Default constructor.

Definition at line 27 of file BDipoleField.cpp.

◆ ~BDipoleField()

BDipoleField::~BDipoleField ( )
virtual

Definition at line 31 of file BDipoleField.cpp.

Member Function Documentation

◆ addField()

BDipoleField & BDipoleField::addField ( const BDipoleField field)

Add to field.

Definition at line 63 of file BDipoleField.cpp.

References Bx, and By.

◆ Bfield() [1/2]

BVector BDipoleField::Bfield ( const Point3D P) const
virtual

Get field.

Reimplemented from EMField.

Definition at line 35 of file BDipoleField.cpp.

References Bx, and By.

◆ Bfield() [2/2]

BVector BDipoleField::Bfield ( const Point3D P,
double  t 
) const
virtual

Get field.

Reimplemented from EMField.

Definition at line 40 of file BDipoleField.cpp.

References Bx, and By.

◆ getBx()

double BDipoleField::getBx ( ) const
virtual

Get horizontal component.

Reimplemented from ConstBField.

Definition at line 45 of file BDipoleField.cpp.

References Bx.

Referenced by CorrectorRep::getBx().

◆ getBy()

double BDipoleField::getBy ( ) const
virtual

Get vertical component.

Reimplemented from ConstBField.

Definition at line 49 of file BDipoleField.cpp.

References By.

Referenced by CorrectorRep::getBy().

◆ scale()

void BDipoleField::scale ( double  scalar)
virtual

Scale the field.

Implements EMField.

Definition at line 77 of file BDipoleField.cpp.

References Bx, and By.

◆ setBx()

void BDipoleField::setBx ( double  Bx)
virtual

Set horizontal component.

Reimplemented from ConstBField.

Definition at line 54 of file BDipoleField.cpp.

References Bx.

Referenced by CorrectorRep::setBx().

◆ setBy()

void BDipoleField::setBy ( double  By)
virtual

Set vertical component.

Reimplemented from ConstBField.

Definition at line 58 of file BDipoleField.cpp.

References By.

Referenced by CorrectorRep::setBy().

◆ subtractField()

BDipoleField & BDipoleField::subtractField ( const BDipoleField field)

Subtract from field.

Definition at line 70 of file BDipoleField.cpp.

References Bx, and By.

Member Data Documentation

◆ Bx

double BDipoleField::Bx
private

Definition at line 82 of file BDipoleField.h.

Referenced by addField(), Bfield(), getBx(), scale(), setBx(), and subtractField().

◆ By

double BDipoleField::By
private

Definition at line 82 of file BDipoleField.h.

Referenced by addField(), Bfield(), getBy(), scale(), setBy(), and subtractField().


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