Quaternion Equations and Quaternion Polynomial Matrices
Quaternion Equations and Quaternion Polynomial Matrices
by
Liji Huang
MASTER OF SCIENCE
Department of Mathematics
University of Manitoba
Winnipeg
Abstract i
Acknowledgments iii
1. Introduction 1
1.1. History of Quaternions . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.2. Background for Quaternion Equations . . . . . . . . . . . . . . . . . 5
1.3. Background for Quaternion Polynomial Matrices . . . . . . . . . . . . 8
2. Quaternion Equations 9
2.1. Quaternions and Equivalence Classes . . . . . . . . . . . . . . . . . . 9
2.2. General Quaternion Quadratic Equations . . . . . . . . . . . . . . . . 15
2.3. Special Quaternion Equations and problems . . . . . . . . . . . . . . 20
2.3.1. A quadratic equation . . . . . . . . . . . . . . . . . . . . . . . 20
2.3.2. Another quadratic equation . . . . . . . . . . . . . . . . . . . 36
2.3.3. A homogeneous quadratic equation . . . . . . . . . . . . . . . 40
2.3.4. A pair of quaternion equations . . . . . . . . . . . . . . . . . . 48
2.3.5. Another pair of quaternion equations . . . . . . . . . . . . . . 52
2.3.6. A least norm problem . . . . . . . . . . . . . . . . . . . . . . 55
2.3.7. Another least norm problem . . . . . . . . . . . . . . . . . . . 58
3. Quaternion Polynomial Matrices 61
3.1. Generalized Inverse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
3.2. Leverrier-Faddeev Method . . . . . . . . . . . . . . . . . . . . . . . . 74
3.3. Generalized Inversion by Interpolation . . . . . . . . . . . . . . . . . 82
A. Maple Codes 89
A.1. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
A.2. The Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
Bibliography 119
Abstract
The topic of the second chapter is solving quadratic and other quaternion equations.
Many mathematicians have worked on solving various quaternion equations. How-
ever, due to the complex nature of quaternions, the current "best" non-numerical
result is a special case of quadratic quaternion equation presented in (Au-Yeung,
2003), which pales in comparison to what is known about equations in complex
numbers. In this chapter, we present a new way to solve not only almost all of the
quaternion equations that have been solved so far, including Au-Yeung’s result, but
also several more complicated ones. This method can also be easily implemented
into computer algebra systems such as Maple. Examples will be included.
The topic of the third chapter is calculating the generalized inverses of quaternion
polynomial matrices. It has been shown that a real (Karampetakis, 1997) or complex
(Stanimirović et al., 2007) polynomial matrix has the generalized inverse that can
be calculated using the Leverrier-Faddeev algorithm (Faddeeva, 1959). It is natural
to ask whether a quaternion polynomial matrix has a generalized inverse, and if yes,
how it can be calculated. In this chapter, we first give conditions that a quaternion
polynomial matrix must satisfy in order to have the generalized inverse. We then
i
Contents
present an interpolation method that can be used to calculate the generalized inverse
of a given quaternion polynomial matrix.
ii
Acknowledgments
First and foremost, I would like to express my most sincere gratitude to my thesis
advisor, Dr. Zhang Yang. I greatly appreciate his encouragement and dedicated
support. Countless hours of discussion with Dr. Zhang helped me overcome many
obstacles during the writing up of this thesis. Without his wisdom and motivation
this thesis would not have been possible.
I greatly appreciate the faculty and staff in the Department of Mathematics for
their teaching and support during my two years of being a graduate student in
mathematics.
I greatly thank my thesis committee members, Dr. Guenter Krause, Dr. Xikui
Wang and Dr. Joe Williams, for reading my thesis and giving me feedback.
On behalf of myself and my wife, I would like to thank Dr. Zhang, the Faculty of
Graduate Studies, the Faculty of Science, and the Department of Mathematics, for
financially supporting me through my graduate studies.
I would like to thank the University of Manitoba library system for providing a rich
supply of online and offline publications. I would also like to thank mapleprimes.com
and latex-community.org for all of the excellent technical support I received from
iii
Acknowledgments
them, and their continued voluntary service to current and future graduate students
and academics all over the world.
Finally, I would like to express my appreciation to my family and friends, for all of
their support and love.
iv
Dedicated to my wife Zifang.
1. Introduction
Every morning in the early part of [October 1843], on my coming down to breakfast,
your (then) little brother, William Edwin, and yourself, used to ask me, “Well, papa,
can you multiply triplets?” Whereto I was always obliged to reply, with a sad shake
of the head: “No, I can only add and subtract them”.
But on the 16th day of the same month—which happened to be Monday, and a
Council day of the Royal Irish Academy—I was walking in to attend and preside,
and your mother was walking with me along the Royal Canal, to which she had
perhaps driven; and although she talked with me now and then, yet an undercurrent
of thought was going on in my mind which gave at last a result, whereof it is not
too much to say that I felt at once the importance. An electric circuit seemed to
close; and a spark flashed forth the herald (as I foresaw immediately) of many long
years to come of definitely directed thought and work by myself, if spared, and, at all
1
1.1 History of Quaternions
events, on the part of others if I should even be allowed to live long enough distinctly
to communicate the discovery. Nor could I resist the impulse—unphilosophical as it
may have been—to cut with a knife on a stone of Brougham Bridge, as we passed
it, the fundamental formula with the symbols i, j, k:
i2 = j2 = k2 = ijk = −1
which contains the Solution of the Problem, but, of course, the inscription has long
since mouldered away (Derbyshire, 2006).
It was a breakthrough discovery in the sense that after the step from one-dimensional
real numbers to two-dimensional complex numbers, the next step was not the natural
one to three-dimensional super-complex numbers but to four-dimensional ones, i.e.,
quaternions. Hamilton embarked on an eight-year journey to develop an algebra for
bracketed triplets but ended up discovering quaternions in a moment of euphoria.
The Dutch mathematician Van der Waerden called Hamilton’s inspiration "the leap
into the fourth dimension" (van der Waerden, 1985). The Scottish mathematical
physicist Peter Guthrie Tait, the leading quaternions exponent of his time, claimed
"...no figure, nor even model, can be more expressive or intelligible than a quaternion
equation" (Tait, 1890). However, Tait’s lifetime friend, William Thomson, 1st Baron
Kelvin, disliked quaternions and would have nothing to do with them (Smith and
Wise, 1989). Tait’s other great friend, the Scottish mathematical physicist James
Clerk Maxwell, remained unconvinced of quaternion’s value in actual calculation, as
he put it "...quaternions...is a mathematical method, but it is a method of thinking,
and not, at least for the present generation, a method of saving thought" (Maxwell,
1873).
Furthermore, the American scientist Josiah Willard Gibbs did not find quaternions
suited to his needs and rejected the quaternionic analysis in favor of his own in-
2
1.1 History of Quaternions
vention: vector analysis (Hastings, 2010; Gibbs et al., 1902). The English electrical
engineer Oliver Heaviside, who independently formulated vector analysis similar to
Gibbs’s system, wrote "...it is impossible to think in quaternions, you can only pre-
tend to do it" (Nahin, 2002). The British mathematician Arthur Cayley gave a
poetic illustration on the matter "...I compare a quaternion formula to a pocket-
map, a capital thing to put in one’s pocket, but which for use must be unfolded; the
formula, to be understood, must be translated into coordinates" (Cayley, 1894). Even
the English mathematician Alexander McAulay, a quaternion advocate, stated that
"...not much advance in physics has been made by the aid of quaternions" (McAulay,
1892). Indeed, in the century that has passed since McAulay wrote, it can be argued
that quaternions faded away to a minor role in mathematics and physics while the
Gibbs-Heaviside vector algebra became the everyday work tool of all modern engi-
neers and scientists. In 1892, Heaviside, hinting subtly that quaternions are what
he called "a positive evil of no inconsiderable magnitude", summarized the matter
in this way, and probably the best way "...the invention of quaternions must be re-
garded as a most remarkable feat of human ingenuity...but to find out quaternions
required a genius" (Nahin).
Today, quaternions still play a role in quantum physics (Adler, 1995; Finkelstein
et al., 1962) and other branches of physics (Churchill, 1990). Quaternions are now
used throughout the aerospace industry for attitude control of aircraft and space-
craft (Kuipers, 2002). Some people claim that quaternions are an important aspect
in modern computer graphics for calculations involving three-dimensional rotations
because quaternions use less memory, compose faster, and are naturally suited for ef-
ficient interpolation (Hanson, 2005). Although, like in the academic circle of physics
over a century ago, there are controversies regarding the advantages of quaternion
orientation representations in today’s computer graphics and modeling community
3
1.1 History of Quaternions
(Hanson, 2005). Quaternions are also attracting more and more attention in math-
ematics. There has been a new surge of interest in quaternions in the mathemat-
ics world—a quick search in the American Mathematical Society’s database shows
that more than half of the 3232 publications containing the word “quaternion” or
“quaternionic” in the title have been published after the year of 1996.
4
1.2 Background for Quaternion Equations
This section attempts to give a general and brief review on what has been done
on quaternion equations, §2.1 offers a more detailed introduction to quaternions
themselves.
xm − am = 0.
In 1944, Eilenberg and Niven showed that even the most general equation with a
unique highest term,
where φ (x) is a sum of finite number of monomials of the form b1 xb2 x · · · xbk , k < m,
has at least one quaternion root. This is also known as the "fundamental theorem
of algebra" for quaternions.
In 1944, Johnson gave necessary and sufficient conditions for the equation
xa1 + a2 x + a3 = 0
xa1 + a2 x + a3 = 0
5
1.2 Background for Quaternion Equations
and
xa1 x + a2 = 0,
Very little was done to obtain formula solutions of quaternion equations after John-
son’s result, until, in 2002, Huang and So solved the special quadratic equation:
x2 + a1 x + a2 = 0. (1.2)
Then in the following year, Au-Yeung solved another special quadratic equation,
which included both Johnson’s and Huang and So’s results as special cases:
x2 + a1 x + xa2 + a3 = 0. (1.3)
Au-Yeung’s paper was the latest non-numerical attempt to find the exact roots of a
non-linear quaternion equation.
In 2010, Tian studied and solved two pairs of linear quaternion equations
xa1 y = a2 ,
(1.4)
ya2 x
= a1 ,
and
xa1 y = a2 ,
(1.5)
ya2 x
= a1 ,
x2 + a1 xa2 = 0,
6
1.2 Background for Quaternion Equations
In §A.2, we present some maple codes to solve these quaternion equations and
problems.
7
1.3 Background for Quaternion Polynomial Matrices
In 1955, Penrose introduced the term generalized inverse that exists for any matrix
with complex elements. In 1965, Decell gave a method for computing the general-
ized inverse of a constant complex matrix based on Leverrier-Faddeev’s algorithm
(Faddeeva, 1959), which recursively computes coefficients of the characteristic poly-
nomial of the matrix. This method was later extended by Karampetakis to real
polynomial matrices. In 2006, Stanimirović and Petković applied an interpolation
method to the result of Karampetakis. Then in the following year, Stanimirović
et al. extended Stanimirović and Petković’s result to include complex polynomial
matrices with interpolations at real number data points.
In §A.2, we include our Maple codes for calculating the generalized inverse of a given
quaternion matrix or quaternion polynomial matrix. We also include our Maple
codes that can be used to do Newton and Lagrange quaternionic interpolation, which
are closely related to the interpolation of the generalized inverse of a quaternion
polynomial matrix.
8
2. Quaternion Equations
In this section, we will outline some definitions and properties of quaternions. First,
recall the definition of quaternions:
Definition 2.1.1. Let R denote the field of the real numbers. Let H be a four-
dimensional vector space over R with basis 1, i, j and k. A quaternion is a vector
x = x0 · 1 + x1 i + x2 j + x3 k ∈ H
9
2.1 Quaternions and Equivalence Classes
xy =x0 y0 − x1 y1 − x2 y2 − x3 y3
+ (x0 y1 + x1 y0 + x2 y3 − x3 y2 ) i
+ (x0 y2 − x1 y3 + x2 y0 + x3 y1 ) j
+ (x0 y3 + x1 y2 − x2 y1 + x3 y0 ) k.
ii = jj = kk = −1,
It is also worth noting that with the above equations, the multiplication defined in
Definition 2.1.2 follows.
Lemma 2.1.6. Let x, y ∈ H. Then |x| is non-negative and |·| is a norm on H, i.e.,
|x| = 0 ⇔ x = 0,
|x + y| ≤ |x| + |y| ,
10
2.1 Quaternions and Equivalence Classes
Proof. We will only show that |x + y| ≤ |x| + |y|. The rest of the lemma is true by
direct calculation. Since
=x20 + x21 + x22 + x23 + y02 + y12 + y22 + y32 + 2x0 y0 + 2x1 y1 + 2x2 y2 + 2x3 y3
⇔
(x0 y0 + x1 y1 + x2 y2 + x3 y3 )2 ≤ x20 + x21 + x22 + x23 y02 + y12 + y22 + y32 ,
Next, inverse and conjugacy class for quaternions are defined as follows:
Definition 2.1.8. Two quaternions x and y are said to be similar, or in the same
11
2.1 Quaternions and Equivalence Classes
1
x v y ⇒ v −1 xv = y ⇒ |y| = v −1 xv = |x| |v| = |x| .
|v|
Proof. We only prove the forward direction of the theorem. The backward direction
is straightforward.
= (v0 + v1 i + v2 j + v3 k) (y0 + y1 i + y2 j + y3 k) .
12
2.1 Quaternions and Equivalence Classes
Multiplying the four equations of 2.3 by (x0 + y0 ), (x1 + y1 ), (x2 + y2 ) and (x3 + y3 )
respectively, then adding them, we get
x0 (v1 y1 + v2 y2 + v3 y3 ) = y0 (v1 x1 + v2 x2 + v3 x3 )
x0 (y0 v0 − A) = y0 (x0 v0 − A)
Ax0 = Ay0 .
x0 (y1 v0 − y2 v3 + y3 v2 ) = y0 (x2 v3 − x3 v2 + x1 v0 )
x0 (B − y0 v1 ) = y0 (B − x0 v1 )
Bx0 = By0 .
Since x0 6= y0 , B = 0.
Next, multiplying the four equations of 2.3 by (x2 + y2 ), (x3 − y3 ), − (x0 + y0 ) and
13
2.1 Quaternions and Equivalence Classes
x0 (y2 v0 + y1 v3 − y3 v1 ) = y0 (x2 v0 + x3 v1 − x1 v3 )
x0 (C − y0 v2 ) = y0 (C − x0 v2 )
Cx0 = Cy0 .
Since x0 6= y0 , C = 0.
Lastly, multiplying the four equations of 2.3 by (x3 + y3 ), − (x2 − y2 ), (x1 − y1 ) and
− (x0 + y0 ) respectively, then adding them, we get
x0 (y3 v0 + y2 v1 − y1 v2 ) = y0 (x3 v0 + x1 v2 − x2 v1 )
x0 (D − y0 v3 ) = y0 (D − x0 v3 )
Dx0 = Dy0 .
14
2.2 General Quaternion Quadratic Equations
where k ∈ N.
(2.5)
+ m33 ) x3 = −c3 + x0 n3 ,
m31 x1 + m32 x2 + (2x0 (3)
x2 − x2 − x2 − x2 + d 1 x0 + d2 x1 + d3 x2 + d4 x3 + c0 = 0, (4)
0 1 2 3
M = (mij )3×3
k ai0 bi0 − ai1 bi1 + ai2 bi2 + ai3 bi3 ai0 bi3 − ai1 bi2 − ai2 bi1 − ai3 bi0 −ai0 bi2 − ai1 bi3 + ai2 bi0 − ai3 bi1
X
= −ai0 bi3 − ai1 bi2 − ai2 bi1 + ai3 bi0 ai0 bi0 + ai1 bi1 − ai2 bi2 + ai3 bi3 ai0 bi1 − ai1 bi0 − ai2 bi3 − ai3 bi2 ,
i=1
ai0 bi2 − ai1 bi3 − ai2 bi0 − ai3 bi1 −ai0 bi1 + ai1 bi0 − ai2 bi3 − ai3 bi2 ai0 bi0 + ai1 bi1 + ai2 bi2 − ai3 bi3
X k
(−ai0 bi1 − ai1 bi0 − ai2 bi3 + ai3 bi2 )
i=1
k
X
N = (ni )3×1 =
(−ai0 bi2 + ai1 bi3 − ai2 bi0 − ai3 bi1 )
,
i=1
k
X
(−ai0 bi3 − ai1 bi2 + ai2 bi1 − ai3 bi0 )
i=1
15
2.2 General Quaternion Quadratic Equations
and
k
X
(ai0 bi0 − ai1 bi1 − ai2 bi2 − ai3 bi3 )
i=1
X k
(−ai0 bi1 − ai1 bi0 + ai2 bi3 − ai3 bi2 )
i=1
D = (di )4×1 = .
k
X
(−ai0 bi2 − ai1 bi3 − ai2 bi0 + ai3 bi1 )
i=1
X k
(−ai0 bi3 + ai1 bi2 − ai2 bi1 − ai3 bi0 )
i=1
Treating x0 as a constant, let M̌ be the coefficient matrix of (1), (2) and (3) of 2.5:
2x0 + m11 m12 m13
m21 2x0 + m22 m23 .
m31 m32 2x0 + m33
σ (x0 ) = det M̌
+ 2 (m11 m22 + m11 m33 − m12 m21 − m13 m31 − m23 m32 + m22 m33 ) x0
p1 (x0 )
x1 = , (2.6)
σ (x0 )
p2 (x0 )
x2 = (2.7)
σ (x0 )
16
2.2 General Quaternion Quadratic Equations
and
p3 (x0 )
x3 = , (2.8)
σ (x0 )
where
p1 (x0 ) =4n1 x30 + 2 (n1 (m22 + m33 ) − n2 m12 − n3 m13 − 2c1 ) x20
p2 (x0 ) =4n2 x30 + 2 (n2 (m11 + m33 ) − n1 m21 − n3 m23 − 2c2 ) x20
and
p3 (x0 ) =4n3 x30 + 2 (n3 (m11 + m22 ) − n1 m31 − n2 m32 − 2c3 ) x20
17
2.2 General Quaternion Quadratic Equations
Substituting 2.6, 2.7 and 2.8 back into (4) of 2.5, we obtain:
2.9 is an 8th order equation of x0 . After solving 2.9 for a real solution
x0 , we substitute its value back into 2.6, 2.7 and 2.8 to get x1 , x2 and
x3 respectively to obtain a solution to 2.4. The prime difficulty here is
that, by Galois theory, there is no formula solution for general eighth
degree equations (Morandi, 1996). Furthermore, there does not seem to
be a general formula to factor 2.9. However, as we will show in the next
section, under certain conditions, 2.9 can be solved.
It is clear that 2.5 has a solution only if the last row of the reduced row
echelon form of the augmented matrix M̌ | Ň is a zero row. Under
these conditions, (1), (2) and (3) of 2.5, now viewed as a linear system
18
2.2 General Quaternion Quadratic Equations
+ x20 + d1 x0 + c0 .
The parameters y and z must satisfy 2.11, therefore 2.11 can be seen as
a quadratic equation of, WLOG, y:
19
2.3 Special Quaternion Equations and problems
In this section, we give solutions to some specific quaternion equations and least
norm problems.
In this subsection, we consider the quadratic equation that was studied and solved
in (Au-Yeung, 2003):
t2 + αt + tβ + γ = 0, (2.13)
α0 +β0
Let x = t + 2
. Then 2.13 becomes:
!2 ! !
α0 + β0 α 0 + β0 α0 + β0
0 = x− +α x− + x− β+γ
2 2 2
= x2 + ax + xb + c, (2.14)
α0 +β0 2
where a = Im α, b = Im β and c = 2
− (α + β) α0 +β
2
0
+ γ. The advantage
of 2.14 over 2.13 is that the left and right coefficients of the indeterminate are both
pure imaginary.
20
2.3 Special Quaternion Equations and problems
x1 = −a1 ,
Case 1. If c = c0 ∈ R, then 2.16 can have solutions only if x0 = 0 or x2 = −a2 ,
x3 =
−a3 ,
is part of the solution.
⇔
3 3
(xi + ai )2 = c + a2i = c − a2 .
X X
(2.17)
i=1 i=1
a2 − c = x20 .
21
2.3 Special Quaternion Equations and problems
and
q
2
− (c0 + a21 + a22 + a23 ) + (c21 + c22 + c23 ) − (c0 + a21 + a22 + a23 )
< 0.
2
So
vq
u 2
c0 + a21 + a22 + a23 + c21 + c22 + c23 − c0 + a21 + a22 + a23
u
t
x0 = ±
2
vq
u
2 2
t (c0 − a2 ) − (Im c) − (c0 − a2 )
u
= ,
2
22
2.3 Special Quaternion Equations and problems
and
−c1
x1 = − a1 ,
2x0
−c2
x2 = 2x0
− a2 ,
−c3
x3 = − a3 .
2x0
From now on, we can and we will assume that a 6= b. The deter-
minant
of the coefficient matrix
of (1), (2) and (3) of 2.15, M̌ =
2x0 −a3 + b3 a2 − b2
a3 − b3 −a1 + b1 , is:
2x0
−a2 + b2 a1 − b1 2x0
σ (x0 ) = det M̌
=8x30 + 2 (a1 − b1 )2 + (a2 − b2 )2 + (a3 − b3 )2 x0
=2x0 4x20 + (a1 − b1 )2 + (a2 − b2 )2 + (a3 − b3 )2 .
2.15 can have infinitely many solutions only if σ (x0 ) = 0, this would
mean that x0 = 0.
⇔
3 3
2
a2i = c − a2 .
X X
(xi + ai ) = c +
i=1 i=1
Next, when x0 = 0, the augmented matrix of (1), (2) and (3) of 2.15 is
0 −a3 + b3 a2 − b 2 −c1
A=
a3 − b 3 0 −a1 + b1 .
−c2
−a2 + b2 a1 − b 1 0 −c3
23
2.3 Special Quaternion Equations and problems
We will show that A is the augmented matrix of a consistent linear system if and
only if
3
X
ci (ai − bi ) = 0.
i=1
+ b2 ) x1 = −c3
(−a2
(a2 − b2 ) c2 + (a3 − b3 ) c3 = 0
⇒
3
X
ci (ai − bi ) = 0.
i=1
24
2.3 Special Quaternion Equations and problems
25
2.3 Special Quaternion Equations and problems
26
2.3 Special Quaternion Equations and problems
27
2.3 Special Quaternion Equations and problems
c3 + (a1 − b1 ) s 2 −c1 2
0= + s2 + − c0
a2 − b2 a2 − b2
c3 + (a1 − b1 ) s −c1
+ (a1 + b1 ) + (a2 + b2 ) s + (a3 + b3 )
a2 − b2 a2 − b2
⇔
0 = (a1 − b1 )2 + (a2 − b2 )2 s2 + O (s) , (2.20)
This concludes our discussion for possible scenarios where 2.15 can have infinitely
many solutions.
When x0 6= 0, we have σ (x0 ) 6= 0. Applying Cramer’s rule to (1), (2) and (3) of
2.15, we obtain x1 , x2 and x3 as rational polynomials of x0 as follows:
p1 (x0 )
x1 = , (2.21)
σ (x0 )
p2 (x0 )
x2 = (2.22)
σ (x0 )
and
p3 (x0 )
x3 = , (2.23)
σ (x0 )
28
2.3 Special Quaternion Equations and problems
where
and
Substituting 2.21, 2.23 and 2.23 back into (4) of 2.15, we obtain:
29
2.3 Special Quaternion Equations and problems
0 =f (y)
=16y 3 + 8 a21 + a22 + a23 + b21 + b22 + b23 + 2c0 y 2
+ 4c0 (a1 − b1 )2 + (a2 − b2 )2 + (a3 − b3 )2 y
2
+ a21 + a22 + a23 − b21 − b22 − b23 y
+ (8a2 b3 − 8a3 b2 ) c1 − 4c21 y
+ (8a3 b1 − 8a1 b3 ) c2 − 4c22 y
+ (8a1 b2 − 8a2 b1 ) c3 − 4c23 y
3
!2
X
− ci (ai − bi )
i=1
=16y 3 + D2 y 2 + D1 y + D0 . (2.24)
30
2.3 Special Quaternion Equations and problems
This gives:
2
4c0 (a1 − b1 )2 + (a2 − b2 )2 + (a3 − b3 )2 + a21 + a22 + a23 − b21 − b22 − b23
2
D1 =4c0 (a1 − b1 )2 + (a2 − b2 )2 + (a3 − b3 )2 + a21 + a22 + a23 − b21 − b22 − b23
≤0.
√
Therefore, f has exactly one strictly positive solution z. We can plug x0 = ± z
into 2.21, 2.23 and 2.23 to get x1 , x2 and x3 respectively.
31
2.3 Special Quaternion Equations and problems
α0 +β0
t0 = x0 − 2 ,
t1 = x1 ,
t = x − α0 +β
2
0
= x0 − α0 +β0
2
+ x1 i + x2 j + x3 k, that is, for each
t2 = x2 ,
t3 = x3 ,
x.
We are now able to give a theorem that sums up our result so far in this subsection.
t2 + αt + tβ + γ = 0, (2.25)
1. a = b.
a) c ∈ R.
i. c − a2 > 0. t0 = − α0 +β
2
0
and (t1 , t2 , t3 ) can be any real number triple
(ti + ai )2 = c − a2 . This is the only
P3
that satisfies the equation i=1
32
2.3 Special Quaternion Equations and problems
ii. a2 − c ≥ 0.
√ α0 +β0
t0 = ± a2 − c − ,
2
t1 = −a1 ,
= −a2 ,
t2
t = −a3 .
3
b) c ∈
/ R.
α0 +β0
t0 = s− ,
2
c1
t1 = −a1 − ,
2s
c2
−a2 −
t2 = 2s
,
c2
t = −a2 − ,
3 2s
or
α0 +β0
t0 = −s − ,
2
c1
t1 = −a1 + ,
2s
c2
= −a2 +
t2 2s
,
c2
t = −a2 + ,
3 2s
r√
(c0 −a2 )2 −(Im c)2 −(c0 −a2 )
where = 2
.
33
2.3 Special Quaternion Equations and problems
c1 +(a2 −b2 )s
t2 = a3 −b3
,
t = s,
3
c2
t2 = a1 −b1
,
−c3
t = ,
3 a1 −b1
34
2.3 Special Quaternion Equations and problems
The following steps have been implemented into a single procedure in Maple. For
details, see the “AY” procedure of §A.2.
We have
3
X
ci (ai − bi ) = (−2) · (−2 − 1) + 6 · (−2 + 3) + (−1) · (−2 − 1) = 15 6= 0.
i=1
By Theorem 2.3.1, there are only standard solutions and we obtain a cubic poly-
nomial of y = x20 :
13 √ 1 18 √ 1 19
y= 13 sin arctan 10091901 + π − = s.
6 3 85634 6 6
and
√ √ √
√ p1 (− s) p2 (− s) p3 (− s)
− s−1 + √ i+ √ j+ √ k ≈ −2.41 + 0.87i + 1.65j − 1.93k
σ (− s) σ (− s) σ (− s)
35
2.3 Special Quaternion Equations and problems
x2 + axb + c = 0, (2.28)
(2.29)
m31 x1 + m32 x2 + (2x0 + m33 ) x3 = (−a1 b2 + a2 b1 ) x0 , (3)
x2 − x2 − x2 − x2 + d + d2 x1 + d3 x2 + d4 x3 + c = 0, (4)
1 x0
0 1 2 3
M = (mij )3×3
−a1 b1 + a2 b2 + a3 b3 −a1 b2 − a2 b1 −a1 b3 − a3 b1
=
−a1 b2 − a2 b1 a1 b 1 − a2 b 2 + a3 b 3 −a2 b3 − a3 b2 ,
−a1 b3 − a3 b1 −a2 b3 − a3 b2 a1 b1 + a2 b2 − a3 b3
and
−a1 b1 − a2 b2 − a3 b3
a2 b 3 − a3 b 2
D = (di )4×1 =
.
−a1 b3 + a3 b1
a1 b 2 − a2 b 1
We already discussed in §2.2 how to solve 2.28 if the determinant of the coefficient
36
2.3 Special Quaternion Equations and problems
2x0 + m11 m12 m13
matrix, M̌ =
m21 2x0 + m22 m23 ,
is zero. We can and will assume
m31 m32 2x0 + m33
that det M̌ 6= 0.
σ (x0 ) = det M̌
= (b1 a1 + a2 b2 + a3 b3 + 2x0 ) 4x20 − a21 + a22 + a23 b21 + b22 + b23 6= 0,
therefore, 4x20 − (a21 + a22 + a23 ) (b21 + b22 + b23 ) 6= 0. Applying Cramer’s rule to (1), (2)
and (3) of 2.29, we obtain x1 as a rational polynomial of x0 ,
Similarly,
x0 (a1 b3 − a3 b1 )
x2 = = p2 (x0 ) (2.31)
b1 a1 + a2 b2 + a3 b3 + 2x0
and
x0 (a2 b1 − a1 b2 )
x3 = = p3 (x0 ) . (2.32)
b1 a1 + a2 b2 + a3 b3 + 2x0
Substituting 2.30, 2.31 and 2.32 back into (4) of 2.29, then multiplying through by
(b1 a1 + a2 b2 + a3 b3 + 2x0 )2 , we obtain a quartic equation of x0 ,
3 1 1
f (x0 ) = x40 + c − α x20 + β (4c − α) x0 + cβ 2 = 0, (2.33)
4 4 4
where
α = a21 + a22 + a23 b21 + b22 + b23
and
β = a1 b 1 + a2 b 2 + a3 b 3 .
37
2.3 Special Quaternion Equations and problems
The discriminant of f is 4f = 1
256
β2 (α − β 2 ) (α + 4c) (3α − 4c)3 − 1024c3 β 2 .
Since α − β 2 ≥ 0 by the Cauchy–Schwartz inequality, 4f < 0 if an only if
(α + 4c) (3α − 4c)3 − 1024c3 β 2 < 0.
Once we solve f for x0 , we substitute its value back into 2.30, 2.31 and 2.32 to get
x1 , x2 and x3 respectively to obtain a solution to 2.28.
The following steps have been implemented into a single procedure in Maple. For
details, see the “AXBc” procedure of §A.2.
2.34 is equivalent to
(2x0 − 7) x1 − 5x2 + 3x3 = −x0 , (1)
−5x1 + (2x0 + 3) x2 − 5x3 = 5x0 , (2)
(2.35)
3x1 − 5x2 + (2x0
+ 1) x3 = 7x0 , (3)
x2 + x2 + x2 − x + 5x2 + 7x3 = x20 + 21. (4)
1 2 3 1
2x0 − 7 −5 3
When the determinant of the coefficient matrix, −5 −5 , is 0,
2x0 + 3
3 −5 2x0 + 1
that is, when σ (x0 ) = 8x30 − 12x20 − 168x0 + 252 =
0, 2.35 has no solutions because
2x0 − 7 −5 3 −x0
the last row of the reduced row echelon form of −5
2x0 + 3 −5 5x0
3 −5 2x0 + 1 7x0
is not a zero row. Otherwise, by 2.33, we obtain a quartic polynomial of x0 ,
189
f (x0 ) = x40 − 42x20 +
4
q √
f (x0 ) has four positive roots x0 = ± 21 84 ± 30 7. Therefore, by 2.30, 2.31 and
38
2.3 Special Quaternion Equations and problems
q √ q √ q √ q √
84 − 30 7 84 − 30 7 84 − 30 7 84 − 30 7
+ p1 i + p2 j + p3 k
2 2 2 2
q √ q √ q √ q √
− 84 + 30 7 − 84 + 30 7 − 84 + 30 7 − 84 + 30 7
+ p1 i + p2 j + p3 k
2 2 2 2
and
q √ q √ q √ q √
− 84 − 30 7 − 84 − 30 7 − 84 − 30 7 − 84 − 30 7
+ p1 i + p2 j + p3 k
2 2 2 2
39
2.3 Special Quaternion Equations and problems
x2 + axb = 0, (2.36)
M = (mij )3×3
a0 b 0 − a1 b 1 + a2 b 2 + a3 b 3 a0 b 3 − a1 b 2 − a2 b 1 − a3 b 0 −a0 b2 − a1 b3 + a2 b0 − a3 b1
=
−a0 b3 − a1 b2 − a2 b1 + a3 b0 a0 b0 + a1 b1 − a2 b2 + a3 b3 ,
a0 b 1 − a1 b 0 − a2 b 3 − a3 b 2
a0 b 2 − a1 b 3 − a2 b 0 − a3 b 1 −a0 b1 + a1 b0 − a2 b3 − a3 b2 a0 b 0 + a1 b 1 + a2 b 2 − a3 b 3
−a0 b1 − a1 b 0 − a2 b 3 + a3 b 2
N = (ni )3×1 = −a b
0 2 ,
+ a1 b 3 − a2 b 0 − a3 b 1
−a0 b3 − a1 b2 + a2 b1 − a3 b0
40
2.3 Special Quaternion Equations and problems
and
a0 b 0 − a1 b 1 − a2 b 2 − a3 b 3
−a b − a b + a b − a b
0 1 1 0 2 3 3 2
D = (di )4×1 =
.
−a b − a b − a b + a b
0 2 1 3 2 0 3 1
−a0 b3 + a1 b2 − a2 b1 − a3 b0
σ (x0 ) = det M̌
+ 2 (m11 m22 + m11 m33 − m12 m21 − m13 m31 − m23 m32 + m22 m33 ) x0
Applying Cramer’s rule to (1), (2) and (3) of 2.37, we obtain x1 , x2 and x3 as rational
polynomials of x0 as follows:
p1 (x0 )
x1 = , (2.38)
σ (x0 )
p2 (x0 )
x2 = (2.39)
σ (x0 )
and
p3 (x0 )
x3 = , (2.40)
σ (x0 )
41
2.3 Special Quaternion Equations and problems
where
and
Substituting 2.38, 2.39 and 2.40 back into (4) of 2.37, we obtain:
0 =x20 + d1 x0
p1 (x0 )2 + p2 (x0 )2 + p3 (x0 )2 d2 p1 (x0 ) + d3 p2 (x0 ) + d4 p3 (x0 )
− + ,
σ (x0 )2 σ (x0 )
42
2.3 Special Quaternion Equations and problems
x0 ,
0 =f (x0 ) (2.41)
=σ (x0 )2 x20 + d1 x0 − d21 x20 − p2 (x0 )2 − p3 (x0 )2
2.41 can be factored into the product of x0 , a cubic and a quartic polynomial of x0 ,
1 1 1
g (x0 ) = x40 + 2a0 b0 x30 + Ax20 + a0 b0 Bx0 + B 2 , (2.43)
2 2 16
with
A = 4a20 b20 − a21 + a22 + a23 − a20 b21 + b22 + b23 − b20
and
B = a20 + a21 + a22 + a23 b20 + b21 + b22 + b23 .
43
2.3 Special Quaternion Equations and problems
where
1
g1 (x0 ) = x20 + sx0 + B
4
and
1
g2 (x0 ) = x20 + tx0 + B,
4
with
q
s = a0 b 0 + (b21 + b22 + b23 ) (a21 + a22 + a23 )
and
q
t = a0 b 0 − (b21 + b22 + b23 ) (a21 + a22 + a23 ).
4g1 = − b23 a20 − a21 b20 − a22 b20 − a23 b20 − b22 a20 − a20 b21
q
+ 2b0 a0 (b21 + b22 + b23 ) (a21 + a22 + a23 )
q q 2
= − a0 (b21 + b22 + b23 ) − b0 (a21 + a22 + a23 ) ≤0
and
4g2 = − b23 a20 − a21 b20 − a22 b20 − a23 b20 − b22 a20 − a20 b21
q
− 2b0 a0 (b21 + b22 + b23 ) (a21 + a22 + a23 )
q q 2
= − a0 (b21 + b22 + b23 ) + b0 (a21 + a22 + a23 ) ≤ 0.
Case 1. When a0 = b0 = 0.
44
2.3 Special Quaternion Equations and problems
1 2
h (x0 ) =x30 − 3a1 + 3a22 + 3a23 3b21 + 3b22 + 3b23 x0 (2.44)
12
1 2
− a1 + a22 + a23 b21 + b22 + b23 (a1 b1 + a2 b2 + a3 b3 ) ,
4
2
1 2
g (x0 ) = x20 − a1 + a22 + a23 b21 + b22 + b23 (2.45)
4
and
1 2
σ (x0 ) = 4 (2x0 + a1 b1 + a2 b2 + a3 b3 ) x20 − a1 + a22 + a23 b21 + b22 + b23 .
4
(2.46)
Note that we already assumed that σ (x0 ) 6= 0, and therefore 2.45 does
not contribute any roots. We next show that 2.44 always has three real
solutions. The discriminant of h is
27 2 2 2
4h = a1 + a22 + a23 b21 + b22 + b23
16
× (a1 b2 − a2 b1 )2 + (a1 b3 − a3 b1 )2 + (a2 b3 − a3 b2 )2
≥0.
45
2.3 Special Quaternion Equations and problems
Once we obtain x0 , we substitute its value back into 2.38, 2.39 and 2.40 to get x1 ,
x2 and x3 respectively to obtain a solution to 2.36.
The following steps have been implemented into a single procedure in Maple. For
details, see the “AXB” procedure of §A.2.
2.48 is equivalent to
(2x0 − 207) x1 − 219x2 − 345x3 = 21x0 , (1)
359x1 + (2x0 + 85) x2 − 271x3 = −27x0 , (2)
(2.49)
−175x1 + 379x2 + (2x0 − 127) x3 =
141x0 , (3)
x2 + x2 + x2 − 89x + 107x − 41x = x20 − 435x0 . (4)
1 2 3 1 2 3
is 0, that is, when σ (x0 ) = 8x30 − 996x20 + 237708x0 − 91470060 = 0, 2.49 has no
solutions because the last row of the reduced row echelon form of
2x0 − 207 −219 −345 21x0
359 2x0 + 85 −271 −27x0
−175 379 2x0 − 127 141x0
46
2.3 Special Quaternion Equations and problems
3 √ 1 7140
x0 = 3710932 + 4 853947883289 3 + √ 1 + 114
2
3710932 + 4 853947883289 3
=δ.
Therefore, by 2.38, 2.39 and 2.40, the solutions to 2.48 are 0 and
47
2.3 Special Quaternion Equations and problems
Two nonzero quaternions a and b are said to be semisimilar if the following system
has a solution:
yax = b,
(2.50)
xby
= a,
where x and y are nonzero quaternion indeterminates. 2.50 was studied and solved
in (Tian, 2010). In this subsection, we present a somewhat simpler solution.
= b−1 x−1 a,
y
this gives:
Therefore, a and b must satisfy the following equation for 2.55 to have solutions,
48
2.3 Special Quaternion Equations and problems
M = (mij )4×4
d −2 (a0 a3 + b0 b3 ) 2 (a0 a2 + b0 b2 ) 2 (a0 a1 − b0 b1 )
2 (a a + b b )
0 3 0 3 d −2 (a0 a1 + b0 b1 ) 2 (a0 a2 − b0 b2 )
,
−2 (a a + b b ) 2 (a0 a1 + b0 b1 ) d 2 (a0 a3 − b0 b3 )
0 2 0 2
−2 (a0 a1 − b0 b1 ) −2 (a0 a2 − b0 b2 ) −2 (a0 a3 − b0 b3 ) d
where the diagonal entries are d = a20 − a21 − a22 − a23 − b20 + b21 + b22 + b23 . By 2.52,
Therefore, M becomes:
a20
− b20 − (a0 a3 + b0 b3 ) a0 a2 + b 0 b 2 a0 a1 − b 0 b 1
a a +b b
0 3 0 3 a20 − b20 − (a0 a1 + b0 b1 ) a0 a2 − b 0 b 2
.
− (a a + b b )
0 2 0 2 a0 a1 + b 0 b 1 a20 − b20 a0 a3 − b 0 b 3
− (a0 a1 − b0 b1 ) − (a0 a2 − b0 b2 ) − (a0 a3 − b0 b3 ) a20 − b20
= bx−1 a−1 .
y
Case 2. Otherwise, we show that 2.50 has no solutions. Let A = a20 + a21 + a22 + a23
and B = b20 + b21 + b22 + b23 . Direct calculation yields:
det M =a20 b20 (A − B) A − B − 4a20 + 4b20
49
2.3 Special Quaternion Equations and problems
= (a0 + b0 )2 (a0 − b0 )2 A2 .
Example 2.3.5. Find all (x, y) such that the following system holds
y (2 + 5i + 12j − 5k) x = 2 + 4i − 3j + 13k,
(2.54)
x (2 + 4i − 3j + 13k) y = 2 + 5i + 12j − 5k.
The following steps have been implemented into a single procedure in Maple. For
details, see the “SemiSim” procedure of §A.2.
2.54 has infinitely many solutions. First we solve the linear system
−16x2 + 18x3 − 2x0 = 0,
16x1 − 18x3 − 30x0 = 0,
18x1 − 18x2 − 36x0 = 0,
2x + 30x − 36x = 0.
1 2 3
50
2.3 Special Quaternion Equations and problems
x2 = t2 ,
x = t3 ,
3
11 12 1 3
= − 710 − − −
y
i j k.
355 355 710
51
2.3 Special Quaternion Equations and problems
where x and y are nonzero quaternion indeterminates. 2.55 was studied and solved
in (Tian, 2010). In this subsection, we present a somewhat simpler solution.
= b−1 x−1 a,
y
this gives:
Therefore a and b must satisfy the following equation in order for 2.55 to have
solutions,
2.56 is equivalent to x−1 ba−1 = ab−1 x−1 . On the other hand, we have:
a0 − a1 i − a2 j − a3 k a
a−1 = 2 2 2 2
= 2
a0 + a1 + a2 + a3 a0 + a1 + a22 + a23
2
and
b0 − b 1 i − b2 j − b3 k b
b−1 = 2 2 2 2
= 2 .
b0 + b1 + b2 + b3 b0 + b1 + b22 + b23
2
52
2.3 Special Quaternion Equations and problems
By 2.57, 2.56 is equivalent to bax = xab ⇔ xab = bax, which is equivalent to the
following system:
m11 x1 + m12 x2 + m13 x3 + m14 x0 = 0,
m21 x1 + m22 x2 + m23 x3 + m24 x0 = 0,
(2.58)
m31 x1 + m32 x2 + m33 x3 + m34 x0 = 0,
m x + m42 x2 + m43 x3 + m44 x0 = 0,
41 1
M = (mij )4×4
0 a0 b 3 + a3 b 0 − (a0 b2 + a2 b0 ) a2 b 3 − a3 b 2
− (a b + a b ) 0 a0 b1 + a1 b0 − (a1 b3 − a3 b1 )
0 3 3 0
=
.
a b +a b
0 2 2 0 − (a0 b1 + a1 b0 ) 0 a1 b 2 − a2 b 1
− (a2 b3 − a3 b2 ) a1 b 3 − a3 b 1 − (a1 b2 − a2 b1 ) 0
Direct calculation yields det M = 0. Therefore, the homogeneous system 2.58 has a
solution set with an infinite number of solutions (x0 , x1 , x2 , x3 ). Each such x gives
a solution to 2.55:
x = x,
b−1 x−1 a.
y
=
Example 2.3.6. Find all (x, y) such that the following system holds:
y (1 − 25i + 8j + 15k) x = 17 + i − 24j − 7k,
(2.59)
x (17 + i − 24j − 7k) y = 1 − 25i + 8j + 15k.
The following steps have been implemented into a single procedure in Maple. For
details, see the “CSSim” procedure of §A.2.
53
2.3 Special Quaternion Equations and problems
Since
2.59 has infinitely many solutions. First we solve the linear system:
248x2 − 112x3 − 304x0 = 0,
−248x1 − 424x3 + 160x0 = 0,
+ 424x2 − 592x0 = 0,
112x1
304x − 160x2 + 592x3 = 0,
1
to obtain:
31 53
x0 = − 20 t1 − t,
20 3
x1 = t1 ,
19 37
x2 = t
10 1
+ t,
10 3
x = t3 ,
3
54
2.3 Special Quaternion Equations and problems
min |ax − xb − c| ,
x∈H
We consider:
ax − xb = c. (2.60)
Case 1. a ∼ b. Then det M = 0. Therefore, we can find the least norm solution
55
2.3 Special Quaternion Equations and problems
y1
y2
of 2.61 by calculating
= M † c0 where M † is the Moore-Penrose
y3
y0
c1
c2
pseudoinverse of M and c0 = (Bjõrck, 1996). This means that
c3
c0
x = y0 + y1 i + y2 j + y3 k satisfies |ax − xb − c| ≤ |az − zb − c| for all
z ∈ H.
The following steps have been implemented into a single procedure in Maple. For
details, see the “LN1” procedure of §A.2.
56
2.3 Special Quaternion Equations and problems
− 14x2 + 2x3 + 10x0 = −2,
9x1
6x + x2 − 10x3 + 2x0 = −9,
1
to obtain:
x0 = − 3364 ,
2905
128
x1 = ,
415
= − 1073
x2 2905
,
2372
x = .
3 2905
57
2.3 Special Quaternion Equations and problems
We consider:
ax − x̄b − c = 0. (2.64)
Case 1. a ∼ b. Then det M = 0. Therefore, we can find the least norm solution
58
2.3 Special Quaternion Equations and problems
y1
y2
of 2.65 by calculating
= M † c0 where M † is the Moore-Penrose
y3
y0
c1
c2
pseudoinverse of M and c0 = (Bjõrck, 1996). This means that
c3
c0
x = y0 + y1 i + y2 j + y3 k satisfies |ax − x̄b − c| ≤ |az − zb − c| for all
z ∈ H.
The following steps have been implemented into a single procedure in Maple. For
details, see the “LN2” procedure of §A.2.
59
2.3 Special Quaternion Equations and problems
12 −13 −4 −9 1
13 12 9 −4 1
M=
and c0 =
to obtain:
4 −9 12 13 −5
7 −6 3 0 −3
39
x0 = − 205 ,
119
x1 = − 7380 ,
1133
x2 = 8610
,
2519
x = − 17220 .
3
60
3. Quaternion Polynomial Matrices
61
3.1 Generalized Inverse
AXA = A (3.1)
XAX = X (3.2)
(AX)∗ = AX (3.3)
(XA)∗ = XA (3.4)
We first show some elementary properties that will be used often throughout this
chapter.
∗
Proof. We show that A† satisfies the defining relations of a generalized inverse
stated in Definition 3.1.3,
∗ ∗
A∗ A† A∗ = AA† A = A∗ ,
∗ ∗ ∗ ∗
A† A∗ A† = A† AA† = A† ,
h ∗ i ∗ h ∗ i ∗ ∗ ∗
A∗ A† = A† A = A† A = A† A = A∗ A† ,
h ∗ i∗ h ∗ i ∗ ∗ ∗
A† A∗ = AA† = AA† = AA† = A† A∗ .
62
3.1 Generalized Inverse
∗
Therefore, (A∗ )† = A† .
Proof. First,
∗ ∗
A† A† A∗ =A† AA† = A† AA† = A†
∗ ∗
=A† AA† = A† A A† = A∗ A† A† .
Next,
∗ ∗
A† AA∗ = A† A A∗ = AA† A = A∗
∗ ∗ ∗
= AA† A = A∗ A† A∗ = A∗ AA† = A∗ AA† .
XX ∗ A∗ = X. (3.5)
63
3.1 Generalized Inverse
XAA∗ = A∗ . (3.6)
Therefore, 3.5 and 3.6 are equivalent to 3.1, 3.2, 3.3 and 3.4.
Likewise the following two equations are also equivalent to 3.1, 3.2, 3.3 and 3.4,
X ∗ A∗ A = A (3.7)
A∗ X ∗ X = X. (3.8)
Suppose A† satisfies 3.5 and 3.6, B satisfies 3.7 and 3.8. Then
∗ ∗
A† =A† A† A∗ = A† A† (B ∗ A∗ A)∗
∗
=A† A† A∗ AB = A† AB = A† AA∗ B ∗ B = A∗ B ∗ B = B.
64
3.1 Generalized Inverse
Adapting ideas from (Puystjens and de Smet, 1980), we will give conditions that
quaternion polynomial matrices must satisfy to have generalized inverses. We need
to prove some lemmas first.
Proof. We show that A† U ∗ satisfies the defining relations of the generalized inverse
stated in Definition 3.1.3,
U A A† U ∗ U A = U AA† A = U A,
A† U ∗ (U A) A† U ∗ = A† AA† U ∗ = A† U ∗ ,
∗ ∗
U AA† U ∗ = U AA† U ∗ = U AA† U ∗ ,
∗ ∗
A† U ∗ U A = A† A = A† A = A† U ∗ U A.
Therefore, (U A)† = A† U ∗ .
65
3.1 Generalized Inverse
∗
where AP ∈ H [x]m×1 and A† P ∈ H [x]m×1 . Therefore, ImageA ⊆ ImageAA∗
and ImageA ⊆ ImageAA† .
For any Q ∈ H [x]m×1 , it is clear that AA∗ Q = A (A∗ Q) where A∗ Q ∈ H [x]n×1 and
that AA† Q = A A† Q where A† Q ∈ H [x]n×1 . Thus, ImageAA∗ ⊆ ImageA and
ImageAA† ⊆ ImageA.
Since f1 = f1 , the leading coefficient of f12 is a positive real number. Note that the
Pm
leading coefficient of i=2 fi fi is also a positive real number. Thus,
m m
! ( !)
f12 f12 f12
X X
deg ≥ deg f1 = deg + fi fi = max deg , deg fi fi
i=2 i=2
≥ deg f12 .
P
m
This shows that f1 ∈ H. Furthermore, 0 = deg f1 = deg i=2 fi fi and therefore
fi ∈ H for all 1 ≤ i ≤ m.
The same can be done for the other rows of E. Therefore, E ∈ Hm×m .
Now we are ready to give conditions that quaternion polynomial matrices must
satisfy in order to have generalized inverses.
66
3.1 Generalized Inverse
By Lemma 3.1.14, AA† ∈ Hm×m . AA† is hermitian and hence, by Lemma 3.1.10,
there exists a unitary matrix U ∈ Hm×m such that U ∗ AA† U = D where D is
diagonal. Since
Set A0 =
U ∗ A. By Lemma
3.1.11,
A0 has its own generalized inverse A0† and
Ir 0 A1 A2
A0 A0† = . Set A0 = , for arbitrary quaternion polynomial matrices
0 0 A3 A4
A1 ∈ H [x]r×r , A2∈ H [x]
r×(n−r)
3 ∈ H [x]
, A
(m−r)×r
and A4 ∈ H [x](m−r)×(n−r)
. Since
Ir 0 A1 A2 A1 A2 A1 A2
A0 = A0 A0† A0 =
= , we must have A0 =
0 0 A3 A4 0 0 0 0
∗ ∗
A1 A1 + A2 A2 0 B1 0
and therefore A0 A0∗ = . Similarly, A0† = for some B1
0 0 B2 0
and B2 .
67
3.1 Generalized Inverse
By Lemma 3.1.13,
Ir 0
ImageA0 A0∗ = ImageA0 = ImageA0 A0† = Image
.
0 0
This implies the surjectivity of A1 A∗1 + A2 A∗2 on H [x]r×1 . Therefore, A1 A∗1 + A2 A∗2
is a unit in H [x]r×r and
A1 A2
A = U A0 = U
.
0 0
which gives:
∗
A1 + (A1 A∗1 0 ∗ A2 A∗2 )−1
A† = U .
∗ −1
∗ ∗
A2 (A1 A1 + A2 A2 ) 0
We show that A† U ∗ satisfies the defining relations of the generalized inverse stated
in Definition 3.1.3,
68
3.1 Generalized Inverse
ABA
A1 A2 A∗1 (A1 A∗1 + A2 A∗2 )−1 0 A1 A2
=U U ∗U
A2 A∗2 )−1
0 0 A∗2 (A1 A∗1 + 0 0 0
A1 A2 A∗1 (A1 A∗1 + A2 A∗2 )−1 0 A1 A2
=U
A2 A∗2 )−1
0 0 A∗2 (A1 A∗1 + 0 0 0
A1 A2
=U
= A,
0 0
BAB
∗
A1 (A1 A∗1
+ A2 A∗2 )−1
0 ∗ A1 A2 A∗1 (A1 A∗1 + A2 A∗2 )−1 0
= U U U∗
∗ −1
A2 A∗2 )−1
∗ ∗
A2 (A1 A1 + A2 A2 ) 0 0 0 A∗2 (A1 A∗1 + 0
∗
A1 (A1 A1
∗
+ A2 A∗2 )−1 0 A1 A2 A∗1 (A1 A∗1 + A2 A∗2 )−1 0
= U∗
A2 A∗2 )−1 A2 A∗2 )−1
A∗2 (A1 A∗1 + 0 0 0 A∗2 (A1 A∗1 + 0
∗
A1 (A1 A1
∗
+ A2 A∗2 )−1 0
= U∗ = B,
A2 A∗2 )−1
A∗2 (A1 A∗1 + 0
69
3.1 Generalized Inverse
∗ ∗ ∗ −1 0
A1 (A1 A1 + A2 A2 )
Therefore, B = U∗ = A† . The uniqueness of A† is the
A∗2 (A1 A∗1 + A2 A∗2 )−1 0
result of Lemma 3.1.8.
Lemma 3.1.16. Let A ∈ Hm×m be hermitian. Then the eigenvalues of A are real.
X ∗ Xλ = λ∗ X ∗ X = (X ∗ Xλ)∗
⇒
x1
∗
. X X
(x1 , · · · xm ) .
. λ = xi xi λ = xi xi λ
xm
X ∗ X
= λ∗ xi xi = λ∗ x i xi .
70
3.1 Generalized Inverse
Definition 3.1.18. Let A ∈ H [x]m×n have the generalized inverse A† . For any
x ∈ R, set B = AA∗ . Then fB (λ) = det (λI2m − χB ) is called the characteristic
polynomial of B. By Lemma 3.1.16, λ can be assumed to be an indeterminate that
enjoys the following: λ = λ and λ commutes element-wise with H [x].
Lemma 3.1.19. Let A ∈ H [x]m×n have the generalized inverse A† . For any x ∈ R,
set B = AA∗ . Then fB (λ) = g (λ)2 where g (λ) ∈ (R [x]) [λ].
we have that:
Next, we show that fB (λ) = g (λ)2 where g (λ) ∈ (C [x]) [λ]. Let B = P + Qi. For
any fixed 1 ≤ i, j ≤ m, we have Bij = a + bi + cj + dk where a, b, c and d ∈ R [x].
Since B is hermitian, Bji = a − bi − cj − dk and therefore Pij = a + bi, Pji = a − bi
and Qij = c + di, Qji = −c − di. So P T = P and Q = −QT . Therefore,
P Q P Q
χB =
=
T
−Q P −Q P
71
3.1 Generalized Inverse
λIm −P Q
λI2m − χB =
.
−Q λIm − P T
Next, we have:
Im −Im Im 0 Im −Im λIm − P Q
0 Im Im Im 0 Im −Q λIm − P T
T
Q P − λIm
=
λIm − P Q
and
Im −Im Im 0
det
= det
= 1.
0 Im Im Im
Therefore,
T
λIm −P Q Q P − λIm
fB (λ) = det
= det
.
T
−Q λIm − P λIm − P Q
Note that:
T
T T
Q P − λIm Q P − λIm
−
=
,
λIm − P Q λIm − P Q
Q P T − λIm
which implies that is skew-symmetric. By (Muir, 2003), the
λIm − P Q
Q PT − λIm
determinant of , also called its Pfaffian, can be written as
λIm − P Q
the square of a polynomial in its entries. Therefore, fB (λ) = g (λ)2 where g (λ) ∈
(C [x]) [λ].
Finally we show that g (λ) ∈ (R [x]) [λ]. Suppose otherwise. Then g (λ) =
a (λ) + b (λ) i where a and b ∈ (R [x]) [λ] with b (λ) 6= 0. By 3.9, g (λ)2 ∈
(R [x]) [λ]. So a (λ) = 0 and therefore fB (λ) = g (λ)2 = (b (λ) i)2 = −b (λ)2
72
3.1 Generalized Inverse
where b (λ) ∈ (R [x]) [λ]. For a fixed x ∈ R, let λ0 ∈ R be large enough such that
λ0 I2m − χB ∈ C2m×2m is diagonally dominant with non-negative diagonal entries
and that (b (x)) (λ0 ) 6= 0. Since λ0 I2m − χB is also hermitian, λ0 I2m − χB is positive
definite (Horn and Johnson, 1990). But det (λ0 I2m − χB ) = − ((b (x)) (λ0 ))2 < 0.
Contradiction. So, b = 0 and therefore fB (λ) = g (λ)2 where g (λ) ∈ (R [x]) [λ].
Corollary 3.1.20. Let A ∈ H [x]m×n have the generalized inverse A† . For any
x ∈ R, set B = AA∗ and fB (λ) = g (λ)2 . Then g (B) = 0. We will call g (λ) the
generalized characteristic polynomial of A.
Proof. g (λ) ∈ (R [α]) [λ] by Lemma 3.1.19, so χg(B) = g (χB ). Next, fB (χB ) = 0 by
the Cayley-Hamilton theorem for complex polynomial matrices (Horn and Johnson,
1990), so g (χB ) = 0. Therefore 0 = g (χB ) = χg(B) , that is, g (B) = 0.
73
3.2 Leverrier-Faddeev Method
Lemma 3.2.1. Let A ∈ H [x]m×n have the generalized inverse A† . Set B = AA∗ .
Then B † = (A∗ )† A† and B † B = BB † .
Proof. First we show that (A∗ )† A† satisfies the defining relations of the generalized
inverse stated in Definition 3.1.3,
74
3.2 Leverrier-Faddeev Method
which is, B † B = BB † .
Lemma 3.2.2. Let A ∈ H [x]m×n have the generalized inverse A† . Set B = AA∗ .
k †
Then B † = Bk where k ∈ N.
k
Proof. We show that B † satisfies the defining relations of the generalized inverse
stated in Definition 3.1.3,
k †
Therefore, B † = Bk where k ∈ N.
X = A† CB † + Y − A† AY BB † ,
75
3.2 Leverrier-Faddeev Method
For the general solution, we must solve AXB = 0. Any expression of the form
X = Y − A† AY BB † satisfies AXB = 0, and conversely if AXB = 0 then X =
A† CB † + Y − A† AY BB † .
Theorem 3.2.4. (Adaption of (Penrose, 1955)) Let A ∈ H [x]m×n have the general-
ized inverse A† . For any x ∈ R, set B = AA∗ . Suppose the generalized characteristic
polynomial of A is
where ai ∈ R [x]. If k is the largest integer such that ak 6= 0, then the generalized
inverse of A is given by
1 ∗ h k−1 i
A† = − A B + a1 B k−2 + · · · + ak−1 I .
ak
This equation guarantees a solution of the matrix equation B m−k X = 0 and hence,
76
3.2 Leverrier-Faddeev Method
A† B k + a1 A† B k−1 + · · · + ak−1 A† B + ak A† = 0.
which gives:
1 ∗ h k−1 i
A† = − A B + a1 B k−2 + · · · + ak−1 I .
ak
Lemma 3.2.5. (Adaption of (Kalman, 1978)) Let A ∈ H [x]m×n have the generalized
inverse A† . For any real x ∈ R, set B = AA∗ . Let λ1 , · · · , λm0 , where m0 ≤ m, be
all the non-zero eigenvalues of B. Then for 1 ≤ k ≤ m,
h i
tr B k + a1 B k−1 + · · · + ak−1 B = −kak ,
77
3.2 Leverrier-Faddeev Method
g (Y ) = (Y − B)
× Y m−1 + (B + a1 I) Y m−2 + B 2 + a1 B + a2 I Y m−3 + · · ·
+ B m−1 + a1 B m−2 + · · · + am I .
(Y − B)−1 Z = Zζ.
78
3.2 Leverrier-Faddeev Method
1
(Y − B) Z = Z
ζ
⇒
!
1
BZ = Z y − .
ζ
Therefore, y − 1
ζ
= λi ⇒ ζ = 1
y−λi
for some 1 ≤ i ≤ m0 .
trC = g 0 (y)
Therefore,
⇒
h i
ak (m − k) = tr B k + a1 B k−1 + · · · + ak−1 B + trak I
⇒
h i
−kak = tr B k + a1 B k−1 + · · · + ak−1 B
Lemma 3.2.6. (Adaption of (Decell, 1965; Faddeeva, 1959)) Let A ∈ H [x]m×n have
79
3.2 Leverrier-Faddeev Method
the generalized inverse A† . For any x ∈ R, set B = AA∗ . Suppose the generalized
characteristic polynomial of A is
A0 = 0 −1 = q0 B0 = I
.. .. ..
. . .
trAp−1
Ap−1 = AA∗ Bp−2 = qp−1 Bp−1 = Ap−1 − qp−1 I
p−1
trAp
Ap = AA∗ Bp−1 = qp Bp = Ap − qp I
p
P0 is the statement:
q0 = −a0 ,
80
3.2 Leverrier-Faddeev Method
Ak =BBk−1
=B (Ak−1 − qk−1 I)
=···
=B k + a1 B k−1 + · · · + ak−1 B.
Therefore,
h i
tr Ak = tr B k + a1 B k−1 + · · · + ak−1 B ,
tr Ak
which by Lemma 3.2.5 is equal to −kak . So qk = k
= −ak .
Thus, Pk holds.
81
3.3 Generalized Inversion by Interpolation
Lemma 3.3.1. (See (Lam, 2001) for more details) An element r ∈ H is a root of a
nonzero polynomial f ∈ H [x] iff x − r is a right divisor of f . The set of polynomials
in H [x] having r as a root is the left ideal H [x] · (x − r).
Lemma 3.3.2. (See (Lam, 2001) for more details) Let f , g and h ∈ H [x], f = gh
and r ∈ H be such that β = h (r) 6= 0. Then
f (r) = g βrβ −1 h (r) .
Pn Pn Pn
Proof. Let g = i=0 ai xi . Then f = ( i=0 ai x i ) h = i=0 ai hxi . Therefore,
n n
ai h (r) ri = ai βri
X X
f (r) =
i=0 i=0
n n i
ai βri β −1 β = ai βrβ −1 β
X X
=
i=0 i=0
n
!
i
ai βrβ −1 β = g βrβ −1 h (r) .
X
=
i=0
82
3.3 Generalized Inversion by Interpolation
Let f ∈ H [x] be of degree n. Then the roots of f lie in at most n conjugacy classes.
P1 is the statement:
Let f ∈ H [x] be of degree 1. Then the root of f lies in at most 1 conjugacy class.
P1 is trivially true.
f = g · (x − c) ,
where g has a root that is, by Lemma 3.3.2, conjugate to d. Invoking the inductive
hypothesis, d lies in at most k − 1 conjugacy classes. So, the roots of f lie in at most
k conjugacy classes. Thus, Pk holds. Therefore, by the principle of mathematical
induction, Pn holds for all n ≥ 1.
P1 is the statement:
83
3.3 Generalized Inversion by Interpolation
P1 is trivially true as g = x − c1 .
We next show that gn is unique for all n ≥ 1. For some fixed n, let g 0 6= gn be monic
of degree n, such that g 0 (c1 ) = · · · = g 0 (cn ) = 0 too. Then deg (gn − g 0 ) ≤ n − 1 but
gn − g 0 has roots c1 , · · · , cn which lie in n conjugacy classes of H. This contradicts
Theorem 3.3.3. Therefore, gn is unique for all n ≥ 1.
gS = hS (cs0 )−1 hS .
We can then construct the polynomial f , of degree at most n, such that f (ci ) = di
84
3.3 Generalized Inversion by Interpolation
Lemma 3.3.7. Let A ∈ H [x]m×n have the generalized inverse A† . Then deg A† ≤
(2m − 1) deg A.
Proof. By Theorem 3.2.4, deg A† ≤ deg A∗ (AA∗ )m−2 ≤ deg (A2m−1 ) ≤
(2m − 1) deg A.
Remark 3.3.8. The upper bound mentioned in Lemma 3.3.7 is rarely achieved in
practice, because some elements of AA∗ (and other matrices) do not have maximal
degree.
85
3.3 Generalized Inversion by Interpolation
0 α ∈ S,
where gS (cα ) = . Since n1 and m1 are chosen randomly, a lowest degree
1 0
α=s
matrix A that satisfies A (ci ) = Ai for all 1 ≤ i ≤ k + 1 is determined by A =
Pk+1
s0 =1 As0 gS .
A0 = 0 −1 = q0 B0 = I
.. .. ..
. . .
trAp−1
Ap−1 = AA∗ Bp−2 = qp−1 Bp−1 = Ap−1 − qp−1 I
p−1
trAp
Ap = AA∗ Bp−1 = qp Bp = Ap − qp I
p
Theorem 3.3.10. In the above setting, let k = (2m − 1) deg A and c1 , · · · , ck+1 ∈
R be k + 1 distinct real numbers such that qp (cs0 ) 6= 0 for any 1 ≤ s0 ≤ k + 1. Let
S = {1, · · · , k + 1} \ {s0 }. Then
k+1
A† = A (cs0 )† gS
X
s0 =1
where
1 h i
A (cs0 )† = A (cs0 )∗ B (cs0 )p−1 − q1 (cs0 ) B (cs0 )p−2 − · · · − qp−1 (cs0 ) I
qp (cs0 )
86
3.3 Generalized Inversion by Interpolation
and
0 α ∈ S,
gS (cα ) =
α = s0 .
1
−4x − 4 + 4i − 20j − 16k −16 + 8i + 20j − 20k −8j + 16k −4x + 16 + 28i + 4j + 16k
The following steps have been implemented into a single procedure in Maple. For
details, see the “LFI” procedure of §A.2.
As mentioned in Remark 3.3.8, here we only need two data points because direct
calculation shows that deg A† = 2. Let c1 = 0 and c2 = 1. We have:
14 + 76i + 70j + 56k 56 − 28i − 70j + 70k 28j − 56k −56 − 8i − 14j − 56k
−2 − 43i − 10j − 8k −8 + 4i + 10j − 10k −4j + 8k 8 − 31i + 2j + 8k
A (c1 ) =
−3 + 3i − 15j − 12k −12 + 6i + 15j − 15k −6j + 12k 12 + 21i + 3j + 12k
and
28 + 76i + 70j + 56k 56 − 28i − 70j + 70k 28j − 56k −42 − 8i − 14j − 56k
−4 − 43i − 10j − 8k −8 + 4i + 10j − 10k −4j + 8k 6 − 31i + 2j + 8k
A (c2 ) = .
−6 + 3i − 15j − 12k −12 + 6i + 15j − 15k −6j + 12k 9 + 21i + 3j + 12k
−140 − 122i + 228j + 342k −355 + 2021i + 96j − 81k 255 − 1176i − 126j − 54k 340 − 1568i − 168j − 72k
87
3.3 Generalized Inversion by Interpolation
and
1
A (c2 )† = A (1)† = ×
230175
152 − 550i − 244j − 330k 289 + 1675i − 8j + 15k −219 − 840i + 78j + 90k −292 − 1120i + 104j + 120k
268 + 104i + 406j − 402k 326 + 328i + 17j − 39k −276 − 228i − 132j + 144k −368 − 304i − 176j + 192k
.
32 + 16i − 160j + 300k −176 − 88i − 20j + 150k 96 + 48i + 60j − 180k 128 + 64i + 80j − 240k
−152 − 132i + 244j + 330k −289 + 2076i + 8j − 15k 219 − 1206i − 78j − 90k 292 − 1608i − 104j − 120k
Direct calculation shows that A† satisfies the defining relations of the generalized
inverse stated in Definition 3.1.3.
88
A. Maple Codes
A.1. Overview
At the early stage of my graduate studies, I realized the need of utilizing Maple
when trying to solve quaternion quadratic equations. There are existing Maple
packages dedicated to quaternions (Carter, 2007; Harder, 2010), but not quaternion
polynomials or quaternion polynomial matrices. Therefore, I started writing my
own Maple module. During my two years of graduate studies, I gradually extended
this module to have over thirty procedures. These procedures enable the user to do
basic quaternion and quaternion polynomial matrix operations such as additions and
multiplications; to do Lagrange and Newton interpolations of a list of quaternion
pairs; to obtain the generalized inverse of a quaternion polynomial matrix; to solve
multiple quaternion equations and quaternion least norm problems; and so on. In
§A2 the codes of the procedures are provided with descriptions and examples.
89
A.2 The Codes
Q := module()
option package;
M := proc(a,b)
return
end proc;
90
A.2 The Codes
ncolsA := LinearAlgebra:-ColumnDimension(A),
ncolsB := LinearAlgebra:-ColumnDimension(B),
AB := Matrix(1..nrowsA, 1..ncolsB), i, j;
end do;
end do;
end proc;
QMultiplyScalar := proc(A::Matrix, B)
ncolsA := LinearAlgebra:-ColumnDimension(A),
AB := Matrix(1..nrowsA, 1..ncolsA), i, j;
end do;
end do;
91
A.2 The Codes
end proc;
ncolsB := LinearAlgebra:-ColumnDimension(B),
AB := Matrix(1..nrowsB, 1..ncolsB), i, j;
end do;
end do;
end proc;
‘*‘ := proc(m, n)
options remember;
QMatrixMultiply(m, n);
QMultiplyScalar(m, n);
QScalarMultiply(m, n);
92
A.2 The Codes
end if;
end proc;
options remember;
local i, p := 1;
for i from 1 to n do
p := M(p, m);
end do;
return p;
else m^n;
end if;
end proc;
Qdef := proc(a, b, c, d)
end proc:
93
A.2 The Codes
end proc:
local j := k;
end proc;
Mrand := proc(m, n, p, q)
for i from 1 to p do
for j from 1 to q do
end do;
end do;
end proc:
for i from 1 to p do
for j from 1 to q do
94
A.2 The Codes
end do;
end do;
end proc:
Qreal := proc(a)
subs(I = 0, J = 0, K = 0, a);
end proc:
Qimag := proc(a)
a - Qreal(a);
end proc:
Qconj := proc(f)
end proc:
Mconj := proc(A)
local nrowsA:=LinearAlgebra:-RowDimension(A),
ncolsA:=LinearAlgebra:-ColumnDimension(A),
AC := Matrix(1..nrowsA, 1..ncolsA), i, j;
95
A.2 The Codes
end do;
end do;
end proc:
end proc;
eval := proc(N, n)
options remember;
local i, f := 1, m := N;
expand(N);
map(eval,expand(N),n);
f := M(f, n);
end do;
end if;
end proc;
96
A.2 The Codes
Meval := proc(N, n)
options remember;
local i, j,
m := Matrix(LinearAlgebra:-RowDimension(N),
LinearAlgebra:-ColumnDimension(N));
end do;
end do;
end proc;
PRotate := proc(m::integer)
for i from 1 to m do
M(i, i + m) := -1;
end do;
M(i, i - m) := 1;
end do;
end proc;
97
A.2 The Codes
Qnorm := proc(a)
end proc:
Qinv := proc(a)
end proc:
NoSim1 := proc(A::list)
options remember;
local i, j, k, B := A, n := nops(B);
for i from 2 to n do
for j from 1 to i - 1 do
for k from j + 1 to i - 1 do
end if;
end do;
end if;
98
A.2 The Codes
end do;
end do;
end proc;
ZeroP := proc(B::list)
options remember;
for i from 2 to n do
end do;
end proc;
NoSim2 := proc(A::listlist)
options remember;
for i from 2 to n1 do
for j from 1 to i - 1 do
99
A.2 The Codes
B := subsop([i,1] = z, B);
end if;
end do;
end do;
for i from 3 to n2 do
for k from j + 1 to i - 1 do
end if;
end do;
end if;
end do;
end do;
end proc;
LagrangeP := proc(B::listlist)
options remember;
100
A.2 The Codes
for i from 1 to n do
end do;
for i from 1 to n do
end do;
for i from 1 to n do
end do;
end proc:
QAdjointMatrix := proc(A::Matrix)
ncolsA := LinearAlgebra:-ColumnDimension(A),
AM := Matrix(1..2*nrowsA, 1..2*ncolsA), i, j;
101
A.2 The Codes
end do;
end do;
end do;
end do;
end do;
end do;
end do;
end do;
102
A.2 The Codes
end do;
end proc;
QMFNorm := proc(A::Matrix)
ncolsA := LinearAlgebra:-ColumnDimension(A), i, j, N := 0;
end do;
end do;
return (expand(N))^(1/2);
end proc;
NewtonP := proc(B::listlist)
#Calculates the Newton polynomials and the divided difference for a list of quater-
nion pairs.
options remember;
103
A.2 The Codes
for i from 1 to n do
end do;
for i from 1 to n - 1 do
end do;
end proc;
H := LinearAlgebra:-Transpose(Mconj(A)),
P := QMatrixMultiply(A, H),
B[0] := LinearAlgebra:-IdentityMatrix(nrowsA);
a[i] := -LinearAlgebra:-Trace(AA[i])/i;
104
A.2 The Codes
end do;
k := j;
end if;
LFI := 0;
else
end if;
end proc:
105
A.2 The Codes
f := 16*x^3
106
A.2 The Codes
(t + subs(x = t,one/d)*I
{sqrt(Z), -sqrt(Z)});
end proc:
d := 2*x + b,
f := x^4 + (c - (3/4)*a)*x^2
{sol});
end proc:
107
A.2 The Codes
108
A.2 The Codes
+ n1*(m22*m33 - m23*m32)*x
+ n2*(m13*m32 - m12*m33)*x
+ n3*(m12*m23 - m13*m22)*x,
+ n1*(m23*m31 - m21*m33)*x
+ n2*(m11*m33 - m13*m31)*x
+ n3*(m13*m21 - m11*m23)*x,
+ n1*(m21*m32 - m22*m31)*x
+ n2*(m12*m31 - m11*m32)*x
+ n3*(m11*m22 - m12*m21)*x,
g := x^4 + 2*a0*b0*x^3
+ (1/2)*(4*a0^2*b0^2
+ (1/2)*a0*b0*ab*x + (1/16)*ab^2,
109
A.2 The Codes
if a0 = 0 and b0 = 0 then
{solh});
else
{solg, solh});
end if;
end proc:
else Z := LinearAlgebra:-LinearSolve(
110
A.2 The Codes
free = ’t’);
end if;
end proc:
else Z := LinearAlgebra:-LinearSolve(
111
A.2 The Codes
free = ’t’);
end if;
end proc:
Z := LinearAlgebra:-MatrixMatrixMultiply(LinearAlgebra:-MatrixInverse(
else
Z := LinearAlgebra:-LinearSolve(
112
A.2 The Codes
[-a1 + b1, -a2 + b2, -a3 + b3, a0 - b0, c0]]), free = ’t’);
end if;
end proc:
Z := LinearAlgebra:-MatrixMatrixMultiply(LinearAlgebra:-MatrixInverse(
else
Z := LinearAlgebra:-LinearSolve(
113
A.2 The Codes
[-a1 - b1, -a2 - b2, -a3 - b3, a0 - b0, c0]]), free = ’t’);
end if;
end proc:
end module:
114
A.2 The Codes
115
A.2 The Codes
116
A.2 The Codes
117
A.2 The Codes
118
Bibliography
Adler, S., 1995. Quaternionic quantum mechanics and quantum fields. International
Series of Monographs on Physics. Oxford University Press, USA.
Baker, A., 1999. Right eigenvalues for quaternionic matrices: a topological approach.
Linear Algebra Appl. 286 (1-3), 303–309.
Bjõrck, A., 1996. Numerical methods for least squares problems. Society for Indus-
trial and Applied Mathematics.
Bray, U., Whaples, G., 1983. Polynomials with coefficients from a division ring.
Canad. J. Math. 35 (3), 509–515.
Cayley, A., 1894. On coordinates versus quaternions. Proc. Roy. Soc. Edinburgh 20,
271–275.
119
Bibliography
Derbyshire, J., 2006. Unknown quantity: a real and imaginary history of algebra.
Joseph Henry Press.
Eilenberg, S., Niven, I., 1944. The “fundamental theorem of algebra” for quaternions.
Bull. Amer. Math. Soc. 50, 246–248.
Faddeeva, V., 1959. Computational methods of linear algebra. Dover books on ad-
vanced mathematics. Dover Publications.
Finkelstein, D., Jauch, J., Schiminovich, S., Speiser, D., 1962. Foundations of quater-
nion quantum mechanics. Journal of Mathematical Physics 3 (2), 207–220.
Gibbs, J., Bumstead, H., Van Name, R., Longley, W., 1902. The collected works of
J. Willard Gibbs. No. v. 2 in The Collected Works of J. Willard Gibbs. Longman,
Green and Co.
Gordon, B., Motzkin, T. S., 1965. On the zeros of polynomials over division rings.
Trans. Amer. Math. Soc. 116, 218–226.
Hanson, A., 2005. Visualizing quaternions. The Morgan Kaufmann Series In Inter-
active 3D Technology. Morgan Kaufmann.
Horn, R., Johnson, C., 1990. Matrix analysis. Cambridge University Press.
Huang, L., So, W., 2002. Quadratic formulas for quaternions. Appl. Math. Lett.
15 (5), 533–540.
120
Bibliography
Kuipers, J., 2002. Quaternions and rotation sequences: a primer with applications
to orbits, aerospace and virtual reality. Princeton University Press.
Lam, T., 2001. A first course in noncommutative rings. Graduate Texts in Mathe-
matics (131). Springer.
Lee, H. C., 1949. Eigenvalues and canonical forms of matrices with quaternion co-
efficients. Proc. Roy. Irish Acad. Sect. A. 52, 253–260.
Morandi, P., 1996. Field and Galois theory. Graduate Texts in Mathematics.
Springer.
Muir, T., 2003. A treatise on the theory of determinants. Dover Phoenix Editions.
Dover Publications.
Nahin, P., 2002. Oliver Heaviside: the life, work, and times of an electrical genius
of the Victorian age. Oliver Heaviside. Johns Hopkins University Press.
Niven, I., 1941. Equations in quaternions. Amer. Math. Monthly 48, 654–661.
Niven, I., 1942. The roots of a quaternion. Amer. Math. Monthly 49, 386–388.
Penrose, R., 1955. A generalized inverse for matrices. Proc. Cambridge Philos. Soc.
51, 406–413.
Puystjens, R., de Smet, H., 1980. The Moore-Penrose inverse for matrices over skew
121
Bibliography
polynomial rings. Ring Theory Antwerp, Lecture Notes in Mathematics 825, 94–
103.
Smith, C., Wise, N., 1989. Energy and empire: a biographical study of Lord Kelvin.
Cambridge University Press.
Stanimirović, P., Tasić, M., Krtolica, P., Karampetakis, N., 2007. Generalized in-
version by interpolation. Filomat 21 (1), 67–86.
Tait, P., 1890. Vii. On the importance of quaternions in physics. Philosophical Mag-
azine Series 5 29 (176), 84–97.
Tian, Y., 2010. Solving two pairs of quadratic equations in quaternions. Adv. Appl.
Clifford Algebr. 20 (1), 185–193.
van der Waerden, B., 1985. A history of algebra: from al-Khwārizmı̄ to Emmy
Noether. Springer.
Zhang, F., 1997. Quaternions and matrices of quaternions. Linear Algebra and its
Applications 251 (0), 21–57.
122