BoxVariant¶
- class hoomd.variant.box.BoxVariant¶
Box-like vector variant base class.
hoomd.variant.box.BoxVariant
provides an interface to vector variants that are validhoomd.box.box_like
objects. The return value of the__call__
method is a list of scalar values that represent the quantitiesLx
,Ly
,Lz
,xy
,xz
, andyz
of a simulation box.Subclasses should override the
__call__
method and must explicitly call the base class constructor in__init__
:class CustomBoxVariant(hoomd.variant.box.BoxVariant): def __init__(self): hoomd.variant.box.BoxVariant.__init__(self) def __call__(self, timestep): return [10 + timestep / 1e6, 10, 10, 0, 0, 0]