q_prod#
- static GeometryOperators.q_prod(p, q)[source]#
Evaluate the product of two quaternions,
p
andq
, defined as: p = p0 + p’ = p0 + ip1 + jp2 + kp3. q = q0 + q’ = q0 + iq1 + jq2 + kq3. r = pq = p0q0 - p’ • q’ + p0q’ + q0p’ + p’ x q’.- Parameters:
- p
List
List of
[p1, p2, p3, p4]
coordinates for quaternionp
.- q
List
List of
[p1, p2, p3, p4]
coordinates for quaternionq
.
- p
- Returns:
List
List of [r1, r2, r3, r4] coordinates for the result quaternion.