polymerist.maths.lattices.bravais ================================= .. py:module:: polymerist.maths.lattices.bravais .. autoapi-nested-parse:: Representations and calculation methods for crystallographic unit cells and lattice parameters Attributes ---------- .. autoapisummary:: polymerist.maths.lattices.bravais.COMMON_UNIT_LATTICE_VECTORS polymerist.maths.lattices.bravais.lattice_generator Classes ------- .. autoapisummary:: polymerist.maths.lattices.bravais.LatticeParameters Functions --------- .. autoapisummary:: polymerist.maths.lattices.bravais.identify_bravais_points_within_bbox Module Contents --------------- .. py:function:: identify_bravais_points_within_bbox(lattice_vectors: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[polymerist.genutils.typetools.numpytypes.D, polymerist.genutils.typetools.numpytypes.D], numbers.Number], bbox: polymerist.maths.lattices.coordinates.BoundingBox) -> tuple[polymerist.maths.lattices.coordinates.Coordinates, polymerist.maths.lattices.integral.CubicIntegerLattice] Locate all lattice points generated by a set of Bravais lattice vectors in D-dimensions which fall within a given bounding box Returns the coordinate vector of the internal lattice points and a CubicIntegerLattice containing the corresponding lattice vector multiplicities .. py:class:: LatticeParameters For storing the lengths of and the angles between the 3 lattice vectors of a crystallographic unit cell .. py:attribute:: a :type: float .. py:attribute:: b :type: float .. py:attribute:: c :type: float .. py:attribute:: alpha :type: float .. py:attribute:: beta :type: float .. py:attribute:: gamma :type: float .. py:property:: lengths_are_positive :type: tuple[bool, Optional[str]] Check whether all axial lengths are well-defined (i.e. positive) .. py:method:: reduce_angles() -> None Ensure all angles are within the principal [0, 2*pi) interval .. py:property:: axial_lengths :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3], float] View of just the axial lengths .. py:attribute:: lengths .. py:property:: angles :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3], float] Property alias of angles() method for convenience .. py:method:: axial_angles(in_degrees: bool = False) -> numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3], float] View of just the angles .. py:property:: volume :type: float The volume of the unit cell (in arbitrary units) .. py:method:: from_lattice_vectors(vectors: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3, 3], float]) -> LatticeParameters :classmethod: Obtain axial lengths and inter-vector angles from a matrix of lattice vectors .. py:method:: to_lattice_vectors() -> numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3, 3], float] The restricted lattice vectors corresponding to the lattice parameters, where vector A lies along the x-axis and vector B is in the xy-plane Vectors are returned as a 3x3 matrix, where each row represents a lattice vector .. py:property:: lattice_vectors :type: numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3, 3], float] Property alias of to_lattice_vectors() method for convenience .. py:data:: COMMON_UNIT_LATTICE_VECTORS :type: dict[str, numpy.ndarray[polymerist.genutils.typetools.numpytypes.Shape[3, 3], float]] .. py:data:: lattice_generator