region
Functions and attributes

class
atomman.region.
Plane
(normal, point) Bases:
object
Class representing a plane in space. Useful for making slices.

above
(pos, inclusive=False) Indicates if position(s) are above the plane. Note that identifying points as above or below is dependent on the sign of the plane normal.
 Parameters
pos (arraylike object) – Nx3 array of coordinates.
inclusive (bool, optional) – Indicates if points in the plane are to be included. Default value is False.
 Returns
N array of bool values: True if above the plane
 Return type
numpy.NDArray

below
(pos, inclusive=True) Indicates if position(s) are below the plane. Note that identifying points as above or below is dependent on the sign of the plane normal.
 Parameters
pos (arraylike object) – Nx3 array of coordinates.
inclusive (bool, optional) – Indicates if points in the plane are to be included. Default value is True.
 Returns
N array of bool values: True if below the plane
 Return type
numpy.NDArray


class
atomman.region.
Sphere
(center, radius) Bases:
atomman.region.Shape.Shape
Class representing a sphere in space.

inside
(pos, inclusive=True) Indicates if position(s) are inside the shape.
 Parameters
pos (arraylike object) – Nx3 array of coordinates.
inclusive (bool, optional) – Indicates if points on the shape’s boundaries are to be included. Default value is True.
 Returns
N array of bool values: True if inside shape
 Return type
numpy.NDArray


class
atomman.region.
Cylinder
(center1, center2, radius, endcaps=True) Bases:
atomman.region.Shape.Shape
Class representing a cylinder in space.

inside
(pos, inclusive=True) Indicates if position(s) are inside the shape.
 Parameters
pos (arraylike object) – Nx3 array of coordinates.
inclusive (bool, optional) – Indicates if points on the shape’s boundaries are to be included. Default value is True.
 Returns
N array of bool values: True if inside shape
 Return type
numpy.NDArray


class
atomman.region.
Shape
Bases:
object
Template class for defining geometric regions in space.

inside
(pos, inclusive=True) Indicates if position(s) are inside the shape.
 Parameters
pos (arraylike object) – Nx3 array of coordinates.
inclusive (bool, optional) – Indicates if points on the shape’s boundaries are to be included. Default value is True.
 Returns
N array of bool values: True if inside shape
 Return type
numpy.NDArray

outside
(pos, inclusive=False) Indicates if position(s) are inside the shape.
 Parameters
pos (arraylike object) – Nx3 array of coordinates.
inclusive (bool, optional) – Indicates if points on the shape’s boundaries are to be included. Default value is False.
 Returns
N array of bool values: True if outside shape
 Return type
numpy.NDArray
