BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
Interpolated field array that gives the nearest neighbour value. More...
#include <BDSInterpolator2DNearest.hh>
Public Member Functions | |
BDSInterpolator2DNearest (BDSArray2DCoords *arrayIn) | |
![]() | |
BDSInterpolator2D (BDSArray2DCoords *arrayIn) | |
G4ThreeVector | GetInterpolatedValue (G4double x, G4double y) const |
Public interface to a 2D interpolator. Returns Geant4 type as that's what will be needed. | |
const BDSArray2DCoords * | Array () const |
BDSDimensionType | FirstDimension () const |
Accessor for the active dimension this represents (first). | |
BDSDimensionType | SecondDimension () const |
Accessor for the active dimension this represents (second). | |
virtual BDSExtent | Extent () const |
Extent of field. | |
virtual G4bool | TimeVarying () const |
![]() | |
BDSInterpolator (BDSArray4DCoords *arrayIn=nullptr) | |
virtual BDSExtent | Extent () const =0 |
Interface each derived class must provide. | |
virtual G4bool | TimeVarying () const =0 |
G4double | SmallestSpatialStep () const |
Protected Member Functions | |
virtual BDSFieldValue | GetInterpolatedValueT (G4double x, G4double y) const |
virtual BDSFieldValue | GetInterpolatedValueT (G4double x, G4double y) const =0 |
Private Member Functions | |
BDSInterpolator2DNearest ()=delete | |
Private default constructor to force use of provided one. | |
Additional Inherited Members | |
![]() | |
BDSArray2DCoords * | array |
The field data. | |
![]() | |
G4double | smallestSpatialStep |
Interpolated field array that gives the nearest neighbour value.
Does not own array - so multiple interpolators could be used on same data.
Definition at line 37 of file BDSInterpolator2DNearest.hh.
|
explicit |
Definition at line 23 of file BDSInterpolator2DNearest.cc.
|
virtual |
Definition at line 27 of file BDSInterpolator2DNearest.cc.
|
protectedvirtual |
Each derived class should implement this function. Note T suffix (was templated) to distinguish it from GetInterpolatedValue which returns Geant4 types and is the main interface to should have the clean name.
Implements BDSInterpolator2D.
Definition at line 30 of file BDSInterpolator2DNearest.cc.
References BDSInterpolator2D::array, and BDSArray2DCoords::ExtractNearest().