polymerist.maths.lattices.integral ================================== .. py:module:: polymerist.maths.lattices.integral .. autoapi-nested-parse:: Core tools for manipulating integer lattices in D-dimensions Classes ------- .. autoapisummary:: polymerist.maths.lattices.integral.CubicIntegerLattice Functions --------- .. autoapisummary:: polymerist.maths.lattices.integral.generate_int_lattice polymerist.maths.lattices.integral.nearest_int_coord_along_normal Module Contents --------------- .. py:function:: generate_int_lattice(*dims: Iterable[int]) -> numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N, polymerist.genutils.typetools.numpytypes.D], int] Generate all D-D coordinates of points on a integer lattice with the sizes of all D dimensions given .. py:function:: nearest_int_coord_along_normal(point: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.D], numbers.Number], normal: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.D], numbers.Number]) -> numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.D], int] Takes an D-dimensional control point and an D-dimensional normal vector Returns the integer-valued point nearest to the control point which lies in the normal direction relative to the control point .. py:class:: CubicIntegerLattice(counts_along_dims: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.D], int]) Bases: :py:obj:`polymerist.maths.lattices.coordinates.Coordinates`\ [\ :py:obj:`int`\ ] For representing an n-dimensional integer lattice, consisting of all n-tuples of integers with values constrained by side lengths in each dimension .. py:attribute:: counts_along_dims .. py:method:: counts_along_dims_as_str(multip_char: str = 'x') -> str Stringify the lattice sidelengths .. py:property:: capacity :type: int The maximum number of points that the lattice could contains .. py:property:: lex_ordered_weights :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.D], int] Vector of the number of points corresponding Can be viewed as a linear transformation between indices and point coordinates when coords are placed in lexicographic order .. py:property:: odd_even_idxs :type: tuple[numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N], int], numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N], int]] Return two vectors of indices, corresponding to points in the "odd" and "even" non-neighboring sublattices, respectively .. py:property:: odd_idxs :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N], int] Indices of the point in the in "odd" sublattice .. py:property:: even_idxs :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N], int] Indices of the point in the in "even" sublattice .. py:property:: odd_sublattice :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N, polymerist.genutils.typetools.numpytypes.D], int] Returns points within the odd sublattice of the lattice points .. py:attribute:: odd_points .. py:property:: even_sublattice :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.N, polymerist.genutils.typetools.numpytypes.D], int] Returns points within the even sublattice of the lattice points .. py:attribute:: even_points