CDTK.Dynamics.MDIntegrators module
- CDTK.Dynamics.MDIntegrators.velocityVerlet(x0, v0, g0, m, dt, grad, **opts)[source]
Perform a velocity-Verlet integration step
x(t) -> x(t+dt) v(t) -> v(t+dt)
Input parameters: x0 - positions x(t) v0 - velocities v(t) g0 - gradient g(t) m - mass of each coordinate dt - integration step grad - function returning the gradient
Options:
- constraints - List of constraints of the form
g(x) = 0 where g(x) are functions of all coordinates …
- The RATTLE algorithm is used to enforce the constraints:
H.C.Andersen, J.Comput.Phys. 52, 24-34, (1983)
A modified version is implemented here that uses numerical differentiation of the constraints. This makes the procedure not restricted to particular types of constraints (e.g. bonds or bond angles): any holonomic constraint on the system of point particles can be defined.
tol - tolerance for the constraints enforcement in RATTLE maxiter - maximum number of iterations in RATTLE step
Output: x1 - x(t+dt) v1 - v(t+dt) g1 - g(t+dt)