Quaternion Function Reference

peirce

Peirce decomposition

Syntax

[chi, d, a, b] = peirce(q)

Description

Computes a decomposition of a real quaternion/octonion into a pair of conjugate complex eigenvalues. The eigenvalues permit functions of the quaternion/octonion argument to be computed using complex functions (for example, powers, trigonometric functions).

The decomposition was first published by Roger M. Oba for the quaternion case alone, but the algorithm works without modification for octonions.

chi is the 'positive' eigenvalue. The complex conjugate of chi gives the 'negative' eigenvalue.

d is the 'positive' idempotent. This is a biquaternion/bioctonion with real scalar part and imaginary vector part. d.^2 = d (definition of an idempotent).

a and b are the products of the eigenvalues and idempotents such that q = a + b (see code for the formula).

The utility of this decomposition is that it satisfies: f(q) = f(chi) .* d* + f(chi*) .* d, where d* is the complex conjugate of d and chi* is the complex conjugate of chi, for a wide range of functions, and the right-hand side may be evaluated using only complex implementations of f(x).

Note that f(chi) .* d* and f(chi*) .* d are conjugates so that it is not necessary to compute both. Instead one of them can be computed and the imaginary part discarded to give the same result with half the computation.

Examples

>> q = randq .* randn
 
q = -0.2071 + 0.308 * I + 0.5571 * J + 0.5434 * K
 
>> [chi, d, a, b] = peirce(q)

chi = -0.2071 + 0.8369i

d = 0.5 + (0+0.184i) * I + (0+0.3328i) * J + (0+0.3246i) * K
 
a = (-0.1035+0.4185i) + (0.154+0.0381i) * I + (0.2786+0.06892i) * J + (0.2717+0.06722i) * K
 
b = (-0.1035-0.4185i) + (0.154-0.0381i) * I + (0.2786-0.06892i) * J + (0.2717-0.06722i) * K
 
>> a + b - q
 
ans = 0 + 0 * I + 0 * J + 0 * K
 
>> d^2 - d
 
ans = -5.551e-17 + 0 * I + 0 * J + 0 * K
 
>> sin(q), sin(chi) .* conj(d) + sin(conj(chi)) .* d
 
ans = -0.2819 + 0.3378 * I + 0.6111 * J + 0.5961 * K
 
ans = -0.2819 + 0.3378 * I + 0.6111 * J + 0.5961 * K

See Also

References

  1. Roger M. Oba, 'Eigen-Decomposition of Quaternions', Advances in Applied Clifford Algebras, October 2018, 28(5), p94. DOI: 10.1007/s00006-018-0911-6.

© 2008-2022 Stephen J. Sangwine and Nicolas Le Bihan

License terms.