OrientationRegion#

class orix.quaternion.OrientationRegion(data: ndarray | Rotation | list | tuple)[source]#

Bases: Rotation

Some subset of the complete space of orientations.

The complete orientation space represents every possible orientation of an object. The whole space is not always needed, for example if the orientation of an object is constrained or (most commonly) if the object is symmetrical. In this case, the space can be segmented using sets of Rotations representing boundaries in the space. This is clearest in the Rodrigues parametrisation, where the boundaries are planes, such as the example here: the asymmetric domain of an adjusted 432 symmetry.

Boundaries of an orientation region in Rodrigues space.

Rotations or orientations can be inside or outside of an orientation region.

Attributes

OrientationRegion.a

Return or set the scalar quaternion component.

OrientationRegion.angle

Return the angle of rotation \(\omega = 2\arccos{|a|}\).

OrientationRegion.antipodal

Return the rotation and its antipodal.

OrientationRegion.axis

Return the axis of rotation \(\hat{\mathbf{n}} = (b, c, d)\).

OrientationRegion.b

Return or set the first vector quaternion component.

OrientationRegion.c

Return or set the second vector quaternion component.

OrientationRegion.conj

Return the conjugate of the quaternion \(Q^* = a - bi - cj - dk\).

OrientationRegion.d

Return or set the third vector quaternion component.

OrientationRegion.data

Return the data.

OrientationRegion.improper

Return True for improper rotations and False otherwise.

OrientationRegion.ndim

Return the number of navigation dimensions of the object.

OrientationRegion.norm

Return the norm of the data.

OrientationRegion.shape

Return the shape of the object.

OrientationRegion.size

Return the total number of entries in this object.

OrientationRegion.unit

Return the unit object.

Methods

OrientationRegion.angle_with(other[, degrees])

Return the angles of rotation transforming the rotations to the other rotations.

OrientationRegion.angle_with_outer(other[, ...])

Return the angles of rotation transforming the rotations to all the other rotations.

OrientationRegion.dot(other)

Return the dot products of the quaternions and the other quaternions.

OrientationRegion.dot_outer(other)

Return the outer dot products of the rotations and the other rotations.

OrientationRegion.empty()

Return an empty object with the appropriate dimensions.

OrientationRegion.faces()

OrientationRegion.flatten()

Return a new rotation instance collapsed into one dimension.

OrientationRegion.from_align_vectors(other, ...)

Estimate a quaternion to optimally align two sets of vectors.

OrientationRegion.from_axes_angles(axes, angles)

Create unit quaternions from axis-angle pairs \((\hat{\mathbf{n}}, \omega)\) [Rowenhorst et al., 2015].

OrientationRegion.from_euler(euler[, ...])

Create unit quaternions from Euler angle sets [Rowenhorst et al., 2015].

OrientationRegion.from_homochoric(ho)

Create unit quaternions from homochoric vectors \(\mathbf{h}\) [Rowenhorst et al., 2015].

OrientationRegion.from_matrix(matrix)

Create unit quaternions from orientation matrices [Rowenhorst et al., 2015].

OrientationRegion.from_neo_euler(neo_euler)

[Deprecated] Create unit quaternion(s) from a neo-euler (vector) representation.

OrientationRegion.from_rodrigues(ro[, angles])

Create unit quaternions from three-component Rodrigues vectors \(\hat{\mathbf{n}}\) or four-component Rodrigues-Frank vectors \(\mathbf{\rho}\) [Rowenhorst et al., 2015].

OrientationRegion.from_scipy_rotation(rotation)

Create unit quaternions from scipy.spatial.transform.Rotation.

OrientationRegion.from_symmetry(s1[, s2])

The set of unique (mis)orientations of a symmetrical object.

OrientationRegion.get_plot_data()

Suitable Rotations for the construction of a wireframe.

OrientationRegion.get_random_sample([size, ...])

Return a new flattened object from a random sample of a given size.

OrientationRegion.identity([shape])

Create identity quaternions.

OrientationRegion.inv()

Return the inverse rotations \(R^{-1}\).

OrientationRegion.mean()

Return the mean quaternion with unitary weights.

OrientationRegion.outer(other[, lazy, ...])

Return the outer rotation products of the rotations and the other rotations or vectors.

OrientationRegion.random([shape])

Create object with random data.

OrientationRegion.random_vonmises([shape, ...])

Return random rotations with a simplified Von Mises-Fisher distribution.

OrientationRegion.reshape(*shape)

Return a new object with the same data in a new shape.

OrientationRegion.squeeze()

Return a new object with the same data with length 1-dimensions removed.

OrientationRegion.stack(sequence)

Return a stacked object from the sequence.

OrientationRegion.to_axes_angles()

Return the unit quaternions as axis-angle vectors [Rowenhorst et al., 2015].

OrientationRegion.to_euler([degrees])

Return the unit quaternions as Euler angles in the Bunge convention [Rowenhorst et al., 2015].

OrientationRegion.to_homochoric()

Return the unit quaternions as homochoric vectors [Rowenhorst et al., 2015].

OrientationRegion.to_matrix()

Return the unit quaternions as orientation matrices [Rowenhorst et al., 2015].

OrientationRegion.to_rodrigues([frank])

Return the unit quaternions as Rodrigues or Rodrigues-Frank

OrientationRegion.transpose(*axes)

Return a new object with the same data transposed.

OrientationRegion.triple_cross(q1, q2, q3)

Pointwise cross product of three quaternions.

OrientationRegion.unique([return_index, ...])

Return the unique rotations from these rotations.

OrientationRegion.vertices()

Return the vertices of the asymmetric domain.