jaxdem.integrators.velocity_verlet_rescaling#
Velocity Verlet integrator with periodic velocity-rescaling thermostat.
Classes
|
Velocity Verlet with periodic velocity-rescaling thermostat. |
- class jaxdem.integrators.velocity_verlet_rescaling.VelocityVerletRescaling(k_B: Array, temperature: Array, rescale_every: Array, can_rotate: Array, subtract_drift: Array)#
Bases:
LinearIntegratorVelocity Verlet with periodic velocity-rescaling thermostat.
Every
rescale_everysteps, the translational (and optionally rotational) velocities are uniformly rescaled so that the instantaneous kinetic temperature matchestemperature. Between rescalings the dynamics are purely Newtonian (standard Velocity Verlet).The rescaling is applied at the end of
step_after_force, after the second Verlet half-kick, so that the terminal velocities on rescaling steps are exactly at the target temperature.- Parameters:
k_B (jax.Array) – Boltzmann constant (set to 1.0 for reduced units).
temperature (jax.Array) – Target temperature \(T\).
rescale_every (jax.Array) – Rescale velocities every this many steps (scalar integer).
can_rotate (jax.Array) – Whether to include rotational DOF in the thermostat (0 or 1). When 1, angular velocities are rescaled together with linear velocities and rotational KE counts toward the temperature.
subtract_drift (jax.Array) – Whether to remove centre-of-mass drift before rescaling (0 or 1). When 1, the COM velocity is subtracted on rescaling steps before measuring temperature. Mainly relevant for small systems.
- k_B: Array#
- temperature: Array#
- rescale_every: Array#
- can_rotate: Array#
- subtract_drift: Array#