BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
Public Member Functions | Private Attributes
BDSFieldEMInterpolated4D Class Reference

A 4D field from an interpolated array with any interpolation. More...

#include <BDSFieldEMInterpolated4D.hh>

Inheritance diagram for BDSFieldEMInterpolated4D:
Inheritance graph
Collaboration diagram for BDSFieldEMInterpolated4D:
Collaboration graph

Public Member Functions

 BDSFieldEMInterpolated4D (BDSInterpolator4D *eInterpolatorIn, BDSInterpolator4D *bInterpolatorIn, const G4Transform3D &offset=G4Transform3D::Identity, G4double eScalingIn=1.0, G4double bScalingIn=1.0)
 
virtual std::pair< G4ThreeVector, G4ThreeVector > GetField (const G4ThreeVector &position, const G4double t=0) const
 Return the interpolated field value at a given point. More...
 
const BDSInterpolator4DEInterpolator () const
 
const BDSInterpolator4DBInterpolator () const
 
- Public Member Functions inherited from BDSFieldEMInterpolated
 BDSFieldEMInterpolated (const BDSInterpolator *eInterpolator, const BDSInterpolator *bInterpolator, const G4Transform3D &offset, G4double eScalingIn=1.0, G4double bScalingIn=1.0)
 
G4double SmallestSpatialStep () const
 
G4double EScaling () const
 Accessor. More...
 
G4double BScaling () const
 Accessor. More...
 
void SetEScaling (G4double eScalingIn)
 Setter. More...
 
void SetBScaling (G4double bScalingIn)
 Setter. More...
 
- Public Member Functions inherited from BDSFieldEM
 BDSFieldEM ()
 
 BDSFieldEM (G4Transform3D transformIn)
 
virtual std::pair< G4ThreeVector, G4ThreeVector > GetField (const G4ThreeVector &position, const G4double t=0) const =0
 
virtual void GetFieldValue (const G4double point[4], G4double *field) const
 
virtual std::pair< G4ThreeVector, G4ThreeVector > GetFieldTransformed (const G4ThreeVector &position, const G4double t) const
 Get the field value after applying transform for local offset. More...
 
virtual void SetTransform (const G4Transform3D &transformIn)
 
virtual G4bool DoesFieldChangeEnergy () const
 Required overload by Geant4. More...
 
G4bool FiniteStrength () const
 Accessor. More...
 

Private Attributes

BDSInterpolator4DeInterpolator
 E Interpolator the field is based on. More...
 
BDSInterpolator4DbInterpolator
 B Interpolator the field is based on. More...
 

Additional Inherited Members

- Protected Attributes inherited from BDSFieldEM
G4bool finiteStrength
 Flag to cache whether finite nor not. More...
 
G4Transform3D transform
 Transform to apply for the field relative to the local coordinates of the geometry. More...
 

Detailed Description

A 4D field from an interpolated array with any interpolation.

Owns interpolators.

This provides a simple interface for em fields to use a 4D interpolator irrespective of which type of interpolator it is.

Author
Laurie Nevay

Definition at line 42 of file BDSFieldEMInterpolated4D.hh.

Constructor & Destructor Documentation

◆ BDSFieldEMInterpolated4D()

BDSFieldEMInterpolated4D::BDSFieldEMInterpolated4D ( BDSInterpolator4D eInterpolatorIn,
BDSInterpolator4D bInterpolatorIn,
const G4Transform3D &  offset = G4Transform3D::Identity,
G4double  eScalingIn = 1.0,
G4double  bScalingIn = 1.0 
)

Definition at line 27 of file BDSFieldEMInterpolated4D.cc.

◆ ~BDSFieldEMInterpolated4D()

BDSFieldEMInterpolated4D::~BDSFieldEMInterpolated4D ( )
virtual

Definition at line 37 of file BDSFieldEMInterpolated4D.cc.

Member Function Documentation

◆ BInterpolator()

const BDSInterpolator4D * BDSFieldEMInterpolated4D::BInterpolator ( ) const
inline

Definition at line 59 of file BDSFieldEMInterpolated4D.hh.

◆ EInterpolator()

const BDSInterpolator4D * BDSFieldEMInterpolated4D::EInterpolator ( ) const
inline

Definition at line 58 of file BDSFieldEMInterpolated4D.hh.

◆ GetField()

std::pair< G4ThreeVector, G4ThreeVector > BDSFieldEMInterpolated4D::GetField ( const G4ThreeVector &  position,
const G4double  t = 0 
) const
virtual

Return the interpolated field value at a given point.

Implements BDSFieldEM.

Definition at line 43 of file BDSFieldEMInterpolated4D.cc.

References bInterpolator, BDSFieldEMInterpolated::BScaling(), eInterpolator, BDSFieldEMInterpolated::EScaling(), and BDSInterpolator4D::GetInterpolatedValue().

Here is the call graph for this function:

Field Documentation

◆ bInterpolator

BDSInterpolator4D* BDSFieldEMInterpolated4D::bInterpolator
private

B Interpolator the field is based on.

Definition at line 63 of file BDSFieldEMInterpolated4D.hh.

Referenced by GetField().

◆ eInterpolator

BDSInterpolator4D* BDSFieldEMInterpolated4D::eInterpolator
private

E Interpolator the field is based on.

Definition at line 62 of file BDSFieldEMInterpolated4D.hh.

Referenced by GetField().


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