mul#
- Quaternion.mul(other)#
Performs quaternion multiplication with another quaternion or compatible value.
- Parameters:
- other
Quaternion
,List
,tuple
,float
,or
int
The value to multiply with this quaternion. It can be another Quaternion or a sequence that can be interpreted as one. It can also be a scalar value (float or int).
- other
- Returns:
Quaternion
A new quaternion representing the product of this quaternion and the given value.
Examples
>>> from ansys.aedt.core.generic.quaternion import Quaternion >>> q1 = Quaternion(1, 2, 3, 4) >>> q2 = Quaternion(5, 6, 7, 8) >>> q1.mul(q2) Quaternion(-60, 12, 30, 24) >>> q1.mul(2) Quaternion(2, 4, 6, 8)