Simulation of Non Spherical Particles, Orientation Representation

You might also like

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 9

Simulation of

Non-Spherical
Particles
I - Orientation Representation
Representation of rotations
Mathematically, rotations in 3 dimensions, can be represented using
different formalisms

• Euler’s angles
• are three angles introduced by Leonhard Euler to describe the
orientation of a rigid body (or a second coordinate system) with
respect to a fixed coordinate system
• Matrix belonging to SO(3) (special orthogonal group in 3 dimensions)
• Square matrices 3x3 that can rotate a vector by simple linear
algebra matrix-vector product
• Quaternions
• A set of four numbers, that obey a special rule for multiplication,
that can effectively map rotations

We will focus on quaternions since


• it is easy to build them, given the axis and angle of rotation
• The composition of rotations is a product between quaternions
• For numerical purposes they are more stable than matrices and
Euler’s angles
Quaternions

They were introduced to simulate rotations of particles in the ‘70s by


Evans and Murad [Quat1], who reported (compared to Euler’s angle
formalism)

• Computational time savings of one order of magnitude


• Better conservation of energy

[Quat1] Evans, D. J., & Murad, S. (1977). Singularity free algorithm for molecular
dynamics simulation of rigid polyatomics. Molecular physics, 34(2), 327-331.
Quaternions
Are used to represent rotations in 3 dimensional space, and can be
seen as an extension of the complex numbers.

You might be familiar with the representation of rotations in 2


dimensions with complex numbers.

Using the exponential notation for


complex numbers it is possible to
represent any 2D vector of length and
forming an angle with the x-axis as

This formalism gives an extremely


elegant way to represent a generic
rotation. To apply to the vector a
rotation of , it is enough to multiply it:
Euler’s formula illustrated in the
complex plane. Wikimedia commons
Quaternions
In mathematical terms, quaternions are a 4 dimensional division
algebra, and a quaternion can be represented as

where are real numbers, and the product is defined according to .


Exercise: compute the product of two general quaternions. (Note: the
product is not commutative , proof it!)

For the purpose of this lecture is enough to know that,


in analogy with the complex numbers, it is possible to represent
quaternions in a more compact way, highlighting the relation with
rotations

Where is the unit imaginary quaternion.


Exercise: verify that , as defined above, has length 1.
Quaternions
Now we can see how quaternions can be used for rotations

We can represent a general vector in 3D space as a quaternion, it is


enough the simple mapping

where are the usual cartesian versors, to obtain the quaternion


representation

To rotate any vector by an angle , around the axis , it is enough to


compute the product

Exercise: Compute the above product! (To simplify the algebra we


suggest to choose a simple case e.g. )
Quaternions
We mentioned that the product of quaternions is not commutative,
this is strictly connected to the nature of rotations.

Try to rotate an object around two different axes, you can see that the
order of rotations matter
Further readings
• A good book to have to have a practical overview on simulations, focused on granular
materials:
Pöschel, T. and Schwager, T., 2005. Computational granular dynamics: models and
algorithms. Springer Science & Business Media

• A great book on computational physics, written by some of the masters of molecular


dynamics and Monte Carlo simulations
Frenkel, D. and Smit, B., 2001. Understanding molecular simulation: from algorithms to
applications (Vol. 1). Elsevier.

• Another one of the classics


Rapaport, D.C. and Rapaport, D.C.R., 2004. The art of molecular dynamics simulation.
Cambridge university press.

• To know more about quaternions, groups of matrices, this book is an excellent, clear, deep
(and fun) mathematical introduction:
Tapp, K., 2016. Matrix groups for undergraduates (Vol. 79). American Mathematical Soc.

• To dig into the fundamentals equations, a book that never gets old, for people (motivated
and) passionate about the theory of physics:
Landau, L.D. and Lifshitz, E.M., 1982. Mechanics: Volume 1 (Vol. 1). Elsevier

You might also like