random#
- classmethod Miller.random(phase: Phase, shape: int | tuple = 1, coordinate_format: str = 'xyz') Self [source]#
Create random Miller indices.
- Parameters:
- phase
A phase with a crystal lattice and symmetry.
- shape
Shape of the indices.
- coordinate_format
Coordinate format of indices, either
"xyz"
(default),"uvw"
,"UVTW"
,"hkl"
, or"hkil"
.
- Returns:
m
Random Miller indices.
Examples
>>> from orix.crystal_map import Phase >>> from orix.vector import Miller >>> phase = Phase(point_group="m-3m") >>> _ = Miller.random(phase) >>> _ = Miller.random(phase, (3, 4)) >>> _ = Miller.random(phase, (3, 4), "hkl")