Cylinder

class hoomd.md.manifold.Cylinder(r, P=(0, 0, 0))

Bases: Manifold

Cylinder manifold.

Parameters:
  • r (float) – radius of the cylinder constraint \([\mathrm{length}]\).

  • P (tuple [float, float, float]) – point defining position of the cylinder axis (default origin) \([\mathrm{length}]\).

Cylinder defines a right circular cylinder along the z axis:

\[F(x,y,z) = (x - P_x)^{2} + (y - P_y)^{2} - r^{2}\]

Example:

cylinder1 = manifold.Cylinder(r=10)
cylinder2 = manifold.Cylinder(r=5, P=(1, 1, 1))