Interface IMagField
- All Known Implementing Classes:
CompositeField, MagneticField, RotatedCompositeField, Solenoid, StandardSolenoid, Torus, TransverseSolenoid
public interface IMagField
-
Method Summary
Modifier and TypeMethodDescriptionbooleancontains(double x, double y, double z) Checks whether the field boundary contain the given point.floatgetB1(int index) Get B1 at a given index.floatgetB2(int index) Get B2 at a given index.floatgetB3(int index) Get B3 at a given index.floatObtain the maximum field magnitude of any point in the map.getName()Get the name of the fielddoubleGet the scale factorbooleanChecks whether the field has been set to always return zero.voidPrint the current configuration
-
Method Details
-
isZeroField
boolean isZeroField()Checks whether the field has been set to always return zero.- Returns:
trueif the field is set to return zero.
-
getB1
float getB1(int index) Get B1 at a given index.- Parameters:
index- the index into the field buffer.- Returns:
- the B1 at the given index.
-
getB2
float getB2(int index) Get B2 at a given index.- Parameters:
index- the index into the field buffer.- Returns:
- the B2 at the given index.
-
getB3
float getB3(int index) Get B3 at a given index.- Parameters:
index- the index into the field buffer.- Returns:
- the B3 at the given index.
-
getName
-
getMaxFieldMagnitude
float getMaxFieldMagnitude()Obtain the maximum field magnitude of any point in the map.- Returns:
- the maximum field magnitude in the units of the map.
-
getScaleFactor
double getScaleFactor()Get the scale factor- Returns:
- the scale factor
-
printConfiguration
Print the current configuration- Parameters:
ps- the print stream
-
contains
boolean contains(double x, double y, double z) Checks whether the field boundary contain the given point.- Parameters:
x- the x coordinate in cmy- the y coordinate in cmz- the z coordinate in cm- Returns:
trueif the field contains the given point
-