hoomd.md

Details

Molecular Dynamics.

Perform Molecular Dynamics simulations with HOOMD-blue.

class hoomd.md.Integrator(dt, aniso='auto', forces=None, constraints=None, methods=None, rigid=None)

Enables a variety of standard integration methods.

Parameters
  • dt (float) – Integrator time step size \([\mathrm{time}]\).

  • methods (Sequence[hoomd.md.methods.Method]) – Sequence of integration methods. Each integration method can be applied to only a specific subset of particles. The intersection of the subsets must be null. The default value of None initializes an empty list.

  • forces (Sequence[hoomd.md.force.Force]) – Sequence of forces applied to the particles in the system. All the forces are summed together. The default value of None initializes an empty list.

  • aniso (str or bool) – Whether to integrate rotational degrees of freedom (bool), default ‘auto’ (autodetect if there is anisotropic factor from any defined active or constraint forces).

  • constraints (Sequence[hoomd.md.constrain.Constraint]) – Sequence of constraint forces applied to the particles in the system. The default value of None initializes an empty list. Rigid body objects (i.e. hoomd.md.constrain.Rigid) are not allowed in the list.

  • rigid (hoomd.md.constrain.Rigid) – A rigid bodies object defining the rigid bodies in the simulation.

Classes of the following modules can be used as elements in methods:

The classes of following modules can be used as elements in forces

The classes of the following module can be used as elements in constraints

Examples:

nlist = hoomd.md.nlist.Cell()
lj = hoomd.md.pair.LJ(nlist=nlist)
lj.params.default = dict(epsilon=1.0, sigma=1.0)
lj.r_cut[('A', 'A')] = 2**(1/6)
nve = hoomd.md.methods.NVE(filter=hoomd.filter.All())
integrator = hoomd.md.Integrator(dt=0.001, methods=[nve], forces=[lj])
sim.operations.integrator = integrator
dt

Integrator time step size \([\mathrm{time}]\).

Type

float

methods

List of integration methods. Each integration method can be applied to only a specific subset of particles.

Type

list[hoomd.md.methods.Method]

forces

List of forces applied to the particles in the system. All the forces are summed together.

Type

list[hoomd.md.force.Force]

aniso

Whether rotational degrees of freedom are integrated.

Type

str

constraints

List of constraint forces applied to the particles in the system.

Type

list[hoomd.md.constrain.Constraint]

rigid

The rigid body definition for the simulation associated with the integrator.

Type

hoomd.md.constrain.Rigid

Modules