# Miller#

class orix.vector.Miller(xyz: Union[np.ndarray, list, tuple, None] = None, uvw: Union[np.ndarray, list, tuple, None] = None, UVTW: Union[np.ndarray, list, tuple, None] = None, hkl: Union[np.ndarray, list, tuple, None] = None, hkil: Union[np.ndarray, list, tuple, None] = None, phase: Optional['orix.crystal_map.Phase'] = None)[source]#

Bases: Vector3d

Direct crystal lattice vectors (uvw or UVTW) and reciprocal crystal lattice vectors (hkl or hkil), the latter known as Miller indices, describing directions with respect to the crystal reference frame defined by a phase’s crystal lattice and symmetry.

Exactly one of xyz, uvw, UVTW, hkl, or hkil must be passed.

The vectors are stored internally as cartesian coordinates in data.

Parameters:
xyz

Vector(s) given in cartesian coordinates. Default is None.

uvw

Indices of direct lattice vector(s). Default is None.

UVTW

Indices of direct lattice vector(s), often preferred over uvw in trigonal and hexagonal lattices. Default is None.

hkl

Indices of reciprocal lattice vector(s). Default is None.

hkil

Indices of reciprocal lattice vector(s), often preferred over hkl in trigonal and hexagonal lattices. Default is None.

phase

A phase with a crystal lattice and symmetry. Must be passed whenever direct or reciprocal lattice vectors are created.

Notes

The Miller-Bravais indices $$UVTW$$ are defined as

$\begin{split}U &= \frac{2u - v}{3}, \\ V &= \frac{2v - u}{3}, \\ T &= -\frac{u + v}{3}, \\ W &= w.\end{split}$

Attributes

 Miller.coordinate_format Return or set the vector coordinate format. Miller.coordinates Return the vector coordinates. Miller.h Return the first reciprocal lattice vector index. Miller.hkil Return or set the reciprocal lattice vectors expressed as 4-index Miller-Bravais indices. Miller.hkl Return or set the reciprocal lattice vectors. Miller.i Return the third reciprocal lattice vector index in 4-index Miller-Bravais indices, equal to $$-(h + k)$$. Miller.is_hexagonal Return whether the crystal reference frame is hexagonal/trigonal. Miller.k Return the second reciprocal lattice vector index. Miller.l Return the third reciprocal lattice vector index, or fourth index in 4-index Miller Bravais indices. Miller.length Return the length of each vector given in lattice parameter units if the coordinate_format attribute equals "uvw" or "UVTW", and inverse lattice parameter units if the attribute equals "hkl" or "hkil". Miller.multiplicity Return the number of symmetrically equivalent directions per vector. Miller.space Return whether the vector is in direct ("d") or reciprocal ("r") space. Miller.u Return the first direct lattice vector index. Miller.unit Return unit vectors. Miller.uvw Return or set the direct lattice vectors. Miller.v Return the second direct lattice vector index. Miller.w Return the third direct lattice vector index.

Methods

 Miller.angle_with(other[, use_symmetry, degrees]) Return the angles between these vectors and the other vectors possibly using symmetrically equivalent vectors to find the smallest angle under symmetry. Miller.cross(other) Return the cross products of the vectors with the other vectors, which is considered the zone axes between the vectors. Return a deepcopy of the instance. Miller.dot(other) Return the dot products of the vectors and the other vectors. Miller.dot_outer(other) Return the outer dot products of the vectors and the other vectors. Return the flattened vectors. Miller.from_highest_indices(phase[, uvw, hkl]) Create a set of unique direct or reciprocal lattice vectors from three highest indices and a phase (crystal lattice and symmetry). Miller.from_min_dspacing(phase[, min_dspacing]) Create a set of unique reciprocal lattice vectors with a a direct space interplanar spacing greater than a lower threshold. Miller.get_nearest(*args) NotImplemented. Miller.in_fundamental_sector([symmetry]) Project Miller indices to a symmetry's fundamental sector (inverse pole figure). Miller.mean([use_symmetry]) Return the mean vector of the set of vectors. Miller.reshape(*shape) Return a new instance with the vectors reshaped. Miller.round([max_index]) Round a set of index triplet (Miller) or quartet (Miller-Bravais/Weber) to the closest smallest integers. Miller.symmetrise([unique, ...]) Return vectors symmetrically equivalent to the vectors. Miller.transpose(*axes) Return a new instance with the data transposed. Miller.unique([use_symmetry, return_index]) Unique vectors in self.