Package ffx.openmm
Class VariableVerletIntegrator
java.lang.Object
ffx.openmm.Integrator
ffx.openmm.VariableVerletIntegrator
This class implements a Verlet integrator with variable time stepping.
The integrator automatically adjusts the step size to maintain a specified
error tolerance, making it suitable for systems with widely varying time scales.
Unlike the standard Verlet integrator which uses a fixed step size, this variable step size algorithm monitors the local truncation error and adjusts the step size accordingly. This can lead to more efficient integration for systems where different parts evolve on different time scales.
-
Field Summary
Fields inherited from class ffx.openmm.Integrator
pointer
-
Constructor Summary
ConstructorsConstructorDescriptionVariableVerletIntegrator
(double errorTol) Create a VariableVerletIntegrator. -
Method Summary
Modifier and TypeMethodDescriptionvoid
destroy()
Destroy the integrator.double
Get the error tolerance for adaptive step sizing.double
Get the maximum step size the integrator is allowed to use (in ps).void
setErrorTolerance
(double tol) Set the error tolerance for adaptive step sizing.void
setMaximumStepSize
(double size) Set the maximum step size the integrator is allowed to use (in ps).void
step
(int steps) Advance a simulation through time by taking a series of time steps.void
stepTo
(double time) Advance the simulation by integrating until a specified time is reached.Methods inherited from class ffx.openmm.Integrator
getConstraintTolerance, getIntegrationForceGroups, getPointer, getStepSize, setConstraintTolerance, setIntegrationForceGroups, setPointer, setStepSize
-
Constructor Details
-
VariableVerletIntegrator
public VariableVerletIntegrator(double errorTol) Create a VariableVerletIntegrator.- Parameters:
errorTol
- The error tolerance for adaptive step sizing.
-
-
Method Details
-
destroy
public void destroy()Destroy the integrator.- Specified by:
destroy
in classIntegrator
-
getErrorTolerance
public double getErrorTolerance()Get the error tolerance for adaptive step sizing.- Returns:
- The error tolerance.
-
getMaximumStepSize
public double getMaximumStepSize()Get the maximum step size the integrator is allowed to use (in ps).- Returns:
- The maximum step size.
-
setErrorTolerance
public void setErrorTolerance(double tol) Set the error tolerance for adaptive step sizing.- Parameters:
tol
- The error tolerance.
-
setMaximumStepSize
public void setMaximumStepSize(double size) Set the maximum step size the integrator is allowed to use (in ps).- Parameters:
size
- The maximum step size.
-
step
public void step(int steps) Advance a simulation through time by taking a series of time steps.- Overrides:
step
in classIntegrator
- Parameters:
steps
- The number of time steps to take.
-
stepTo
public void stepTo(double time) Advance the simulation by integrating until a specified time is reached.- Parameters:
time
- The time to which the simulation should be advanced (in ps).
-