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
, orhkil
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 isNone
.- 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 isNone
.- 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
Return or set the vector coordinate format.
Return the vector coordinates.
Return the first reciprocal lattice vector index.
Return or set the reciprocal lattice vectors expressed as 4-index Miller-Bravais indices.
Return or set the reciprocal lattice vectors.
Return the third reciprocal lattice vector index in 4-index Miller-Bravais indices, equal to \(-(h + k)\).
Return whether the crystal reference frame is hexagonal/trigonal.
Return the second reciprocal lattice vector index.
Return the third reciprocal lattice vector index, or fourth index in 4-index Miller Bravais indices.
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"
.Return the number of symmetrically equivalent directions per vector.
Return whether the vector is in direct (
"d"
) or reciprocal ("r"
) space.Return the first direct lattice vector index.
Return unit vectors.
Return or set the direct lattice vectors.
Return the second direct lattice vector index.
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
.