BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
A perfect magetic dipole in 3D, normal field inside 1/2 poleTipRadius. More...
#include <BDSFieldMagDipoleOuterOld.hh>
Public Member Functions | |
BDSFieldMagDipoleOuterOld (const BDSMagnetStrength *strength, G4double poleTipRadius, G4double arbitraryScaling=1.0) | |
virtual G4ThreeVector | GetField (const G4ThreeVector &position, const double t=0) const |
Access the field value. | |
![]() | |
BDSFieldMag () | |
BDSFieldMag (G4Transform3D transformIn) | |
virtual G4ThreeVector | GetField (const G4ThreeVector &position, const G4double t=0) const =0 |
virtual G4bool | TimeVarying () const |
virtual void | GetFieldValue (const G4double point[4], G4double *field) const |
virtual G4ThreeVector | GetFieldTransformed (const G4ThreeVector &position, const G4double t) const |
Get the field value after applying transform for local offset. | |
virtual void | SetTransform (const G4Transform3D &transformIn) |
void | SetModulator (BDSModulator *modulatorIn) |
Set the optional modulator. | |
G4bool | FiniteStrength () const |
Accessor. | |
Private Attributes | |
G4double | poleTipRadius |
Used as radial limit for returning normal field. | |
G4double | normalisation |
Storage of the overal normalisation factor. | |
G4ThreeVector | localField |
Nominal dipole field. | |
G4ThreeVector | m |
Dipole moment as unit vector of field direction. | |
Static Private Attributes | |
static G4double | transitionLengthScale = 1*CLHEP::cm |
Additional Inherited Members | |
![]() | |
G4bool | finiteStrength |
Flag to cache whether finite nor not. | |
G4Transform3D | transform |
Transform to apply for the field relative to the local coordinates of the geometry. | |
G4bool | transformIsNotIdentity |
Cache of whether to use transform at all. | |
BDSModulator * | modulator |
Optional modulator;. | |
A perfect magetic dipole in 3D, normal field inside 1/2 poleTipRadius.
Field for the far field of a pure magnetic dipole. Inside 0.5*poleTipRadius, the nominal uniform field is returned and tanh is used as a sigmoid function to smoothly vary between the two on a length scale of transitionLengthScale, which is 1cm by default.
Definition at line 44 of file BDSFieldMagDipoleOuterOld.hh.
BDSFieldMagDipoleOuterOld::BDSFieldMagDipoleOuterOld | ( | const BDSMagnetStrength * | strength, |
G4double | poleTipRadius, | ||
G4double | arbitraryScaling = 1.0 |
||
) |
Definition at line 34 of file BDSFieldMagDipoleOuterOld.cc.
|
inlinevirtual |
Definition at line 51 of file BDSFieldMagDipoleOuterOld.hh.
|
virtual |
Access the field value.
Definition at line 59 of file BDSFieldMagDipoleOuterOld.cc.
References BDSFieldMag::finiteStrength, localField, m, normalisation, and poleTipRadius.
|
private |
Nominal dipole field.
Definition at line 60 of file BDSFieldMagDipoleOuterOld.hh.
Referenced by GetField().
|
private |
Dipole moment as unit vector of field direction.
Definition at line 61 of file BDSFieldMagDipoleOuterOld.hh.
Referenced by GetField().
|
private |
Storage of the overal normalisation factor.
Definition at line 59 of file BDSFieldMagDipoleOuterOld.hh.
Referenced by GetField().
|
private |
Used as radial limit for returning normal field.
Definition at line 58 of file BDSFieldMagDipoleOuterOld.hh.
Referenced by GetField().
|
staticprivate |
Definition at line 63 of file BDSFieldMagDipoleOuterOld.hh.