Vertex¶
- class hoomd.hpmc.shape_move.Vertex(default_step_size=None, vertex_move_probability=1)¶
Bases:
ShapeMove
Apply shape moves where particle vertices are translated.
Vertices are rescaled during each shape move to ensure that the shape maintains a constant volume. To preserve detail balance, the maximum step size is rescaled by volume**(1/3) every time a move is accepted.
- Parameters:
Vertex
moves apply a uniform move on each vertex with probabilityvertex_move_probability
in a shape up to a maximum displacement ofstep_size
for the composing instance. The shape volume is rescaled at the end of all the displacements to the specified volume. To preserve detail balance, the maximum step size is rescaled by \(V^{1 / 3}\) every time a move is accepted.Shape support.
The following shapes are supported:
Note
hoomd.hpmc.integrate.ConvexPolyhedron
models shapes that are the the convex hull of the given vertices.Example:
mc = hoomd.hpmc.integrate.ConvexPolyhedron(23456) cube_verts = [(1, 1, 1), (1, 1, -1), (1, -1, 1), (-1, 1, 1), (1, -1, -1), (-1, 1, -1), (-1, -1, 1), (-1, -1, -1)]) mc.shape["A"] = dict(vertices=numpy.asarray(cube_verts) / 2) vertex_move = shape_move.Vertex() vertex_move.volume["A"] = 1
Members inherited from
ShapeMove
:- step_size¶
Maximum size of the shape trial moves.
Read more...
Members defined in
Vertex
:- volume¶
Volume of the particles to hold constant. The particles size is always rescaled to maintain this volume.
- Type:
TypeParameter
[particle type
,float
]