Package cnuphys.adaptiveSwim
Class AAdaptiveStopper
java.lang.Object
cnuphys.adaptiveSwim.AAdaptiveStopper
- All Implemented Interfaces:
- IAdaptiveStopper
- Direct Known Subclasses:
- AdaptiveCylinderStopper,- AdaptiveDefaultStopper,- AdaptiveLineStopper,- AdaptivePlaneStopper,- AdaptiveRhoStopper,- AdaptiveSphereStopper,- AdaptiveSStopper,- AdaptiveZStopper
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprotected final doubleprotected final intprotected doubleprotected doubleprotected final doubleprotected static final doubleprotected SwimTrajectoryprotected double[]
- 
Constructor SummaryConstructorsConstructorDescriptionAAdaptiveStopper(double[] u0, double sf, double accuracy, SwimTrajectory trajectory) Create an stopper
- 
Method SummaryModifier and TypeMethodDescriptionprotected voidaccept(double snew, double[] unew) Accept a new integration stepprotected voidcopy(double[] uSrc, double[] uDest) Copy a state vectordoubleGet the max step size.doublegetS()Get the current path lengthdoublegetSmax()Get the max or final value of the path length in metersdouble[]getU()Get the current state vectorprotected voidsetMaxStep(double maxStep) Set the current max stepMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface cnuphys.adaptiveSwim.IAdaptiveStopperstopIntegration
- 
Field Details- 
_THEMAXSTEPprotected static final double _THEMAXSTEP- See Also:
 
- 
_accuracyprotected final double _accuracy
- 
_sprotected double _s
- 
_sfprotected final double _sf
- 
_dimprotected final int _dim
- 
_uprotected double[] _u
- 
_hLastprotected double _hLast
- 
_trajectory
 
- 
- 
Constructor Details- 
AAdaptiveStopperCreate an stopper- Parameters:
- u0- the initial state vector
- sf- the maximum value of the pathlength in meters
- accuracy- the required accuracy in meters
- trajectory- an optional trajectory
 
 
- 
- 
Method Details- 
getSpublic double getS()Get the current path length- Specified by:
- getSin interface- IAdaptiveStopper
- Returns:
- the current path length in meters
 
- 
getUpublic double[] getU()Get the current state vector- Specified by:
- getUin interface- IAdaptiveStopper
- Returns:
- the current state vector
 
- 
acceptprotected void accept(double snew, double[] unew) Accept a new integration step- Parameters:
- snew- the new value of s in meters
- unew- the new state vector
 
- 
getSmaxpublic double getSmax()Get the max or final value of the path length in meters- Specified by:
- getSmaxin interface- IAdaptiveStopper
- Returns:
- the max or final value of the path length
 
- 
copyprotected void copy(double[] uSrc, double[] uDest) Copy a state vector- Parameters:
- uSrc- the source
- uDest- the destination
 
- 
getMaxStepSizepublic double getMaxStepSize()Get the max step size. This can vary with conditions, primarily with the proximity to a target- Specified by:
- getMaxStepSizein interface- IAdaptiveStopper
- Returns:
- the current max step in meters
 
- 
setMaxStepprotected void setMaxStep(double maxStep) Set the current max step- Parameters:
- maxStep- the current max step in meters
 
 
-