microstructpy.geometry.n_box.NBox¶

class
microstructpy.geometry.n_box.
NBox
(**kwargs)[source]¶ Bases:
object
Ndimensional box
This class contains a generic, ndimensinoal box.
Parameters:  side_lengths (list) – (optional) Side lengths.
 center (list) – (optional) Center of box.
 corner (list) – (optional) Bottomleft corner.
 bounds (list) – (optional) Bounds of box. Expected in the form [(xmin, xmax), (ymin, ymax), …].
 limits – Alias for bounds.
 matrix (list, numpy.ndarray) – (optional) Rotation matrix, nxn

within
(points)[source]¶ Test if points are within nbox.
This function tests whether a point or set of points are within the nbox. For the set of points, a list of booleans is returned to indicate which points are within the nbox.
Parameters: points (list or numpy.ndarray) – Point or list of points. Returns: Flags set to True for points in geometry. Return type: bool or numpy.ndarray