ConstantForce

class hoomd.mpcd.force.ConstantForce(force)

Bases: BodyForce

Constant force.

Parameters:

force (tuple [float, float, float]) – Force vector per particle.

The same constant force is applied to all MPCD particles, independently of time and position. This force is useful for simulating pressure-driven flow in conjunction with a confined geometry having no-slip boundary conditions. It is also useful for measuring diffusion coefficients with nonequilibrium methods.

Example:

force = hoomd.mpcd.force.ConstantForce((1.0, 0, 0))
stream = hoomd.mpcd.stream.Bulk(period=1, mpcd_particle_force=force)
simulation.operations.integrator.streaming_method = stream
force

Force vector per particle.

Example:

force.force = (1.0, 0.0, 0.0)
Type:

tuple [float, float, float]