PowerPoint - My Illinois State

Download Report

Transcript PowerPoint - My Illinois State

THE MAN WHO
VANDALIZED A BRIDGE IN
THE NAME OF SCIENCE
HAMILTON AND HIS QUATERNIONS
Fusun Akman (ISU)
Undergraduate Mathematics Colloquium
February 10, 2016
William Rowan Hamilton (1805-1865):
• Born in Dublin of Scottish parents
• Read Euclid at age 12
• Presented paper predicting conical
refraction as a college student
• Became Andrews Professor of Astronomy
while an undergraduate!
• BTW, his position came with the title
“Astronomer Royal of Ireland”
• First non-American in the National Academy of
Sciences
• Studied complex numbers as pairs of reals and
invented quaternions
• Coined the words “scalar” and “vector”, and
influenced creation of linear algebra
• Introduced momentum as an independent
variable and wrote the “Hamiltonian”
OUTLINE:
1. Dirac’s belt trick
2. Gimbal lock, video games, and Apollo 11
3. Rotations, complex numbers, quaternions,
vectors, scalars
4. The demise
5. The resurrection
1. Dirac’s Belt Trick
Idea: Nature (a belt, at any rate) distinguishes between 360 and 720
degree turns!
Experiment: Holding one end of the belt fixed, give it two complete turns. Now,
holding both ends fixed, untwist the belt by keeping the endpoints fixed, and
just moving the rest of the belt continuously. It can be done.
A mere 360 degree twist cannot be undone in this manner.
Why? Hold your horses.
Real life analog: Spinors in physics. These are vector-like objects that go
to their negatives after one 360 degree rotation and back to their
original selves only after a 720 degree rotation. They describe states of
half-spin particles such as electrons in Quantum Mechanics.
2. Gimbal Lock, Video Games, and Apollo 11
A gimbal is a ring that is suspended so it can rotate
about an axis. Gimbals are typically nested one within
another to accommodate rotation about multiple axes.
They appear in gyroscopes and in inertial measurement
units to allow the inner gimbal’s orientation to remain
fixed while the outer gimbal suspension assumes any
orientation.
Have you had objects spinning out of control
in a video game, however hard you tried to
steer them? Blame the programmers for not
employing quaternions: the q’s smoothly
interpolate between various orientations.
What is gimbal lock?
Apollo 11 and 13 astronauts had serious
problems with gimbal lock.
Really, really bad!
Good
Bad
3a. 2-D Rotations and Complex Numbers
Complex numbers form a field that contains the real numbers: we can add, multiply, subtract and
divide them. They were reluctantly introduced by mathematicians who needed roots for real
polynomials. Soon they became indispensable in algebra, geometry, physics, engineering…
Hamilton:
𝑎 + 𝑏𝑖 ± 𝑐 + 𝑑𝑖 = 𝑎 ± 𝑐 + 𝑏 ± 𝑑 𝑖
𝑎, 𝑏 + 𝑐, 𝑑 = 𝑎 + 𝑐, 𝑏 + 𝑑
𝑎 + 𝑏𝑖 𝑐 + 𝑑𝑖 = 𝑎𝑐 − 𝑏𝑑 + 𝑎𝑑 + 𝑏𝑐 𝑖
𝑎, 𝑏 𝑐, 𝑑 = (𝑎𝑐 − 𝑏𝑑, 𝑎𝑑 + 𝑏𝑐)
𝑎 + 𝑏𝑖 (𝑎 + 𝑏𝑖)(𝑐 − 𝑑𝑖)
=
𝑐 + 𝑑𝑖
𝑐 2 + 𝑑2
𝑖 2 = −1
Polar form (Euler) →
Add angles, multiply lengths
Geometry:
(Hamilton:
Parallelogram law)
Complex numbers in real matrix form:
𝑎 + 𝑏𝑖 ↔
𝑖2 ↔
0 −1 0
1 0 1
𝑎
𝑏
−𝑏
𝑎
−1
−1 0
=
= −𝐼 ↔ −1
0
0 −1
2-D rotations in the plane are
COMMUTATIVE!
𝑒 𝑖𝛼 𝑒 𝑖𝛽 = 𝑒 𝑖(𝛼+𝛽) = 𝑒 𝑖𝛽 𝑒 𝑖𝛼
Rotation matrices are complex numbers of unit length:
𝑒 𝑖𝜃
cos 𝜃
= cos 𝜃 + 𝑖 sin 𝜃 ↔
sin 𝜃
− sin 𝜃
cos 𝜃
They rotate vectors by angle 𝜃 via matrix multiplication:
cos 𝜃
sin 𝜃
−sin 𝜃 𝑐
cos 𝜃 𝑑
COMPLEX NUMBERS FORM A 2-D REAL VECTOR SPACE WITH BASIS {1, 𝑖}, OR (1,0), (0,1) , OR
1 0 0
,
0 1 1
−1
0
Hamilton was intrigued by the relationship between complex numbers and plane rotations. He
wanted to find a field structure on 3-D real space, with 3-D rotations. He thought of appending yet
another “imaginary” number to the complex numbers. Such a field would be a 3-D vector space
over the reals. Alas, there is no such thing, as Frobenius was to prove later:
Frobenius’ Theorem. There are only three finite-dimensional “division algebras” (not necessarily
commutative fields) over the reals: real numbers (1-D), complex numbers (2-D), and quaternions
(4-D).
You can imagine Hamilton’s excitement when he figured out he needed an extra dimension to get
a field (of the noncommutative variety) : he needed THREE imaginary numbers, not two, one for
every “Euler rotation” (coming soon to a slide near you). Coincidence? We don’t think so!
3b. Quaternions, vectors, and scalars
After polishing the theory of “algebraic couples”, Hamilton went on a 13-year quest for a similar
theory of “triplets”. We now know that no such field (commutative or noncommutative) can exist,
otherwise, he would have found it!
It is very likely that Hamilton was eventually inspired by another genius, Eisenstein, who had made his
debut at age 20 with a mere 25 mathematical papers, where he discussed some early form of
matrices and their multiplication, which is of course, associative but noncommutative.
On October 16th, 1843, he was walking towards Dublin with his wife and thinking about his multiplication
scheme for triples. He had envisioned the two axes for complex numbers 𝑎 + 𝑏𝑖, plus one perpendicular to
them, to have numbers of the form 𝑎 + 𝑏𝑖 + 𝑐𝑗, or triplets (𝑎, 𝑏, 𝑐). He had already decided that for
symmetry, he would take 𝑗 2 = −1, and for the sake of associativity and distributivity, he would have to have
𝑖𝑗 = −𝑗𝑖, so this is where things stood:
𝑎 + 𝑏𝑖 + 𝑐𝑗 𝑥 + 𝑦𝑖 + 𝑧𝑗 = 𝑎𝑥 − 𝑏𝑦 − 𝑐𝑧 + 𝑎𝑦 + 𝑏𝑥 𝑖 + 𝑎𝑧 + 𝑐𝑥 𝑗 + 𝑏𝑧 − 𝑐𝑦 𝑖𝑗.
There were four, not three, terms in the product. What the heck was he going to do with the product
of 𝑖 and 𝑗? Set it equal to zero? Hamilton was thinking along these lines while walking along the Royal
Canal when it came to him (as he said later) in a “spark”, when it felt like an “electric circuit closed”: he
was going to let in a third imaginary, 𝑘, and let 𝑖𝑗 = 𝑘. He quickly made some mental calculations and
decided that the square of 𝑘 would also have to be −1. Afraid that he would die and take this
discovery to his grave, he carved the now famous equations on Broome Bridge, which happened to be
handy:
𝑖 2 = 𝑗 2 = 𝑘 2 = 𝑖𝑗𝑘 = −1
Given the multiplication table for the imaginary elements, it is straightforward to compute the products of
two quaternions. Hamilton went on to interpret the quaternion in two parts: the “scalar” part representing
time, and the “vector” part representing space. He was the first scientist to talk about 4-D space-time!
𝑄 = 𝑞0 + (𝑞1 𝒊 + 𝑞2 𝒋 + 𝑞3 𝒌) = 𝑞0 + 𝒒 = scalar + vector
We use his notation and terminology for 3-D vectors today. Reminder:
Dot product:
Cross product:
𝒑 ∙ 𝒒 = 𝑝1 𝑞1 + 𝑝2 𝑞2 + 𝑝3 𝑞3 (scalar)
𝒊
𝒑 × 𝒒 = 𝑝1
𝑞1
𝒋
𝑝2
𝑞2
𝒌
𝑝3 = 𝑝2 𝑞3 − 𝑝3 𝑞2 𝒊
𝑞3
+ 𝑝3 𝑞1 − 𝑝1 𝑞3 𝒋 + 𝑝1 𝑞2 − 𝑝2 𝑞1 𝒌
(vector)
These operations are the remnants of quaternion multiplication! By themselves, they are quite strange.
But: if we multiply two quaternions that are vectors (zero scalar part), we naturally obtain
𝒑𝒒 = −𝒑 ∙ 𝒒 + 𝒑 × 𝒒
The symbols and operations for quaternions and today’s vectors are maddeningly similar but at odds:
both systems ascribe the same meaning to the vectors 𝒊, 𝒋, 𝒌. However, we have
𝒊 × 𝒊 = 𝟎, 𝒊 × 𝒋 = 𝒌
versus
2
𝒊 = −1, 𝒊𝒋 = 𝒌.
The discrepancy is explained when we use the first formula on top:
2
𝒊 = −𝒊 ∙ 𝒊 + 𝒊 × 𝒊 = −1 + 𝟎
𝒊𝒋 = −𝒊 ∙ 𝒋 + 𝒊 × 𝒋 = 0 + 𝒌
3c. 3-D Rotations: Euler Angles
Recall that rotations in the 2-D plane are commutative, and correspond to complex numbers of unit
length (points on the unit circle), or 2 × 2 rotation matrices:
1𝑒 𝑖𝜃 = cos 𝜃 + 𝑖 sin 𝜃 ↔
cos 𝜃
sin 𝜃
− sin 𝜃
↔ 𝑆1
cos 𝜃
Rotation matrices have determinant 1, and are orthogonal: 𝐴𝐴𝑇 = 𝐼 .
Rotations in 3-D space are also accomplished by matrix multiplication. They do not commute!
Three special kinds of 3-D rotation are called Euler rotations: in the 𝑦𝑧-plane (about the 𝑥-axis), in the 𝑥𝑧plane (about the 𝑦-axis), and in the 𝑥𝑦-plane (about the 𝑧-axis). They are given by the following matrices
(also orthogonal and of determinant 1). For example, a rotation by angle 𝜃 in the 𝑥𝑦-plane, with normal
vector 𝒌, is given by
𝑅𝑧,𝜃
cos 𝜃
= sin 𝜃
0
− sin 𝜃
cos 𝜃
0
0
0
1
We can compose many such rotations by matrix multiplication, and may obtain a resultant rotation in some
non-coordinate plane through the origin, with normal vector 𝒏. A rotation sequence (Euler angle sequence)
such as XZXYZY tells us that we have a composition of six rotations, about the 𝑥, 𝑧, 𝑥, 𝑦, 𝑧, 𝑦-axes
respectively. Here is an incredible result by Euler:
Euler’s Theorem (1775) Every rotation has an axis. Any two independent orthonormal coordinate frames can be
related by a sequence of rotations (not more than three) about coordinate axes, where no two successive rotations
may be about the same axis. That is, only the rotation sequences
XYZ, XZY, XYX, XZX, YZX, YXZ, YZY, YXY, ZXY, ZYX, ZXZ, ZYZ
are needed.
All 3 × 3 orthogonal matrices of determinant 1 form a group called the special orthogonal group, 𝑆𝑂(3).
They correspond to all possible (proper) rotations as described by Euler’s Theorem. The number 1 is always
an eigenvalue of a rotation matrix 𝑅, and any eigenvector for 1 gives the rotation axis 𝒏. Moreover, the
rotation angle in the plane orthogonal to 𝒏 is determined by the trace: Trace 𝑅 = 1 + 2 cos 𝜃.
There is a problem with Euler rotations, called singularities, which is a headache for pilots and game
programmers: When making a rotation by 𝛼 about (say) the 𝑧-axis, followed by a rotation of angle 𝛽 about
the new 𝑦-axis, everything will be fine if −𝜋 < 𝛼 ≤ 𝜋 and 𝛽 < 𝜋/2. However, if 𝛽 approaches and
crosses 𝜋/2, 𝛼 becomes undefined: it has to make an instantaneous jump from 𝛼 to 𝛼 + 𝜋. Every Euler
angle sequence in 𝑆𝑂(3) has at least one singular point like (𝛼, 𝜋 2). If your object crosses these values,
then the gimbal/gyroscope system that depends on Eulerian angles goes bananas.
https://en.wikipedia.org/wiki/Gimbal_lock
3.d How are quaternions related to 3-D rotations?
Let us first point out that a quaternion has 4 entries, whereas a rotation matrix has 9. If we could do
rotations using quaternions, that would simplify a lot of computations. Another advantage will be that
singularities would disappear. But how does a quaternion in 4-D act on a vector in 3-D?
One possibility is to omit the scalar part, and just multiply the “vector” by the given
vector in 3-D as quaternions. But the product is NOT another vector in 3-D; it
involves the dot product as well. Scratch that idea.
Wait! We have used complex numbers of unit length for rotations in 2-D. The
length (norm) of a quaternion 𝑄 = 𝑎 + 𝑏𝒊 + 𝑐𝒋 + 𝑑𝒌 = 𝑎 + 𝒗 is given by
Q = 𝑎2 + 𝑏 2 + 𝑐 2 + 𝑑 2 = 𝑎2 + |𝒗|2 . So for any angle 𝜃 and any unit
vector 𝒖, 𝑄 = cos 𝜃 + sin 𝜃 𝒖 is a unit quaternion. Unit quaternions form the
so-called 3-sphere, 𝑆 3 , in 4-D space, which is 3-D (just like the ordinary sphere
𝑆 2 in space is 2-D). Not bad. The (also unit) quaternion 𝑄∗ = cos 𝜃 − sin 𝜃 𝒖 is
called the conjugate of 𝑄. Got it?
Indeed we are. Suppose we want to rotate a vector 𝒗 in space
about the axis given by the unit vector 𝒖 by an angle 𝜃. The
rotated vector is given by the quaternion product
𝑅𝑣 = 𝑄𝑣𝑄 ∗ ,
where 𝑄 = cos 𝜃/2 + sin 𝜃/2 𝒖 and 𝑄 ∗ = cos 𝜃/2 − sin 𝜃/2 𝒖.
Example. Suppose we choose our rotation direction as that of the unit vector 𝒌, and the angle to be
𝜋/2. This should send 𝒊 to 𝒋. Check:
cos 𝜋 4 + sin 𝜋 4 𝒌 𝒊 cos 𝜋 4 − sin 𝜋 4 𝒌
1
2
1
2
1
2
1
2
= 𝒊 − 𝒊𝒌 + 𝒌𝒊 − 𝒌𝒊𝒌 =
1
2
𝒊 + 𝒋 + 𝒋 − 𝒊 = 𝒋.
Odds and ends:
• Since the distinct unit quaternions 𝑄 and −𝑄 give rise to the same rotation in 3-D, the group of
unit quaternions, isomorphic to 𝑆𝑈(2), is a double cover of 𝑆𝑂(3). In Quantum Mechanics, halfspin particles rotated by 360 degrees in space do not return to the same state: they need to be
rotated 720 degrees; so we need to describe internal rotation symmetry by 𝑆𝑈(2) rather than
𝑆𝑂(3).
• No singularities arise in quaternion rotation sequences. Using quaternions avoids gimbal lock.
There is no need for a discrete sequence; we can interpolate smoothly between two fixed
orientations.
• Normalization and multiplication of quaternions is much faster than matrix multiplication.
Finally, there is also a matrix realization of quaternions, as the span of four complex matrices over the
real numbers. Part of the basis is given by multiples of the Pauli spin matrices:
1↔𝐼=
1 0
0 1
𝒊 ↔= −𝑖
0 1
1 0
𝒋 ↔ −𝑖
0 −𝑖
𝑖 0
𝒌 ↔ −𝑖
1 0
0 −1
4. The Demise
Hamilton continued to do extensive work on the properties of quaternions until his death. He even
invented the del operator. James Clerk Maxwell was the most important physicist of the 19th century, and
had written his famous equations for electromagnetism. He learned about quaternions from Peter Tait,
his close friend and Hamilton’s follower. Maxwell publicly supported the use of quaternions, praising
Hamilton’s distinction between scalar and vector quantities. However, he (like many others) did not see
them as labor-saving devices. He presented his equations both in coordinate form and in quaternion
notation.
Both Josiah Willard Gibbs and Oliver Heaviside, greatly influenced by Tait and Maxwell, started
developing their own vector analysis notation: to them, the dot product and the cross product were
more user-friendly and intuitive. There was a prolonged and pointless battle between vector and
quaternion enthusiasts, and vectors prevailed. E.T. Bell called Hamilton “The Irish Tragedy” in his book,
Men of Mathematics. Maxwell’s equations started showing up on T-shirts and mugs.
Hamilton was in fact a pioneer of abstract thinking, who had freed algebraists to invent mathematical
symbols and define their properties. Dozens of new algebraic structures were discovered in his wake. He
paved the way to linear algebra. His two vector products are still heavily used in physics.
5. The Resurrection
• Quaternions eventually played a big role in physics, as Hamilton had predicted,
but could never have imagined. There are many areas of physics that can be or
has been described by quaternions. The heavy use of SU(2) in quantum
mechanics is one example. Maxwell’s equations can be written as one
quaternion equation.
• Computer graphics, robotics, navigation, signal processing, quantum computing…
but especially their use in video games makes quaternions a presence that’s hard
to ignore.
• The contribution of quaternions, and the philosophy behind their invention, has
made algebra and mathematics in general advance in leaps and bounds. For
today’s mathematicians, quaternions are as natural as complex numbers.
• Hamilton has been amply vindicated!
References
Wikipedia
Mark Staley, Understanding quaternions and the Dirac belt trick, arXiv: 1001.1778v2
[physics.pop-ph], 2010