# PDF On Quaternions

Before we can fully understand quaterions, we must first understand where they came from. The root of quaternions is based on the concept of the complex number system. In addition to the well-known number sets Natural , Integer , Real , and Rational , the Complex Number system introduces a new set of numbers called imaginary numbers. Imaginary numbers were invented to solve certain equations that had no solutions such as:.

Complex numbers can be added and subtracted by adding or subtracting the real, and imaginary parts. We can also map complex numbers in a 2D grid called the Complex Plane by mapping the Real part on the horizontal axis and the Imaginary part on the vertical axis. If we plot these complex numbers on the complex plane, we get the following result.

We can also perform arbitrary rotations in the complex plane by defining a complex number of the form:. The first ordered pair is a Real quaternion and the second is a Pure quaternion. These two ordered pairs can be combined into a single ordered pair:. We can also express quaternions as an addition of the Real and Pure quaternion parts:. To compute the inverse of a quaternion, we take the conjugate of the quaternion and divide it by the square of the norm:.

We can also confirm that the magnitude of the resulting vector is maintained:. However, all is not lost. One of the most important reasons for using quaternions in computer graphics is that quaternions are very good at representing rotations in space.

## (IUCr) Bernal Prize Essay on quaternions

Quaternions overcome the issues that plague other methods of rotating points in 3D space such as Gimbal lock which is an issue when you represent your rotation with euler angles. Using quaternions, we can define several methods that represents a rotational interpolation in 3D space. The first method I will examine is called SLERP which is used to smoothly interpolate a point between two orientations. SLERP provides a method to smoothly interpolate a point about two orientations.

With regards to quaternions, this is equivalent to computing the angular difference between the two quaternions. We can apply a similar formula for performing a spherical interpolation of vectors to quaternions. The general form of a spherical interpolation for vectors is defined as:. To solve this problem, we can test the result of the dot product and if it is negative, then we can negate one of the orientations. However for all of the advantages in favor of using quaternions, there are also a few disadvantages.

### mathematics and statistics online

There are several math libraries that implement quaternions and a few of those libraries implement quaternions correctly. If you are interested in using quaternions in your own applications, this is the library I would recommend. I created a small demo that demonstrates how a quaternion is used to rotate an object in space. The demo was created with Unity 3. The zip file also contains a Windows binary executable but Using Unity, you can also generate a Mac application and Unity 4 introduces Linux builds as well.

Understanding Quaternions. This is a wonderfully clear and concise introduction to quaternions! There are a few typos that could be corrected. Well done! I find this website through google and found it very informative and useful. Thank you very much. Also knowledge of basic lighting equations is important. Thanks for pointing this out. A few weeks after creating this tutorial, the LaTeX generator I was using went offline and i had to switch to another provider.

This provider seems to have a different parser than the one I was using when I created the page on quaternions in the first place. I switched again and some of the formulas that were not showing up before are fixed now but others are broken. I have moved the script that is used to generate the formulas to a new server. There have been some hiccups with this script but I hope to have them all fixed now.

That source has since become unavailable so I had to switch to another source which apparently handles LaTeX differently. This is the only coherent introduction to quaternions I have found on the web. It is failry complex and I will have to read through this several times. I am assuming you are drawing heavily from Vince, as Dunn is pretty sketchy. Thanks for pulling this together—I feel like I have found a startting point! While familiar with the use of rotational matrices all my previous attempts to get a hold of quaternions have failed.

What worked for me with your explanation is that you explained it by analogy to rotation in the complex plane which I already understood: the next step was then easy for me. Very nice article. Very well presented too. Can you attach or sent a full pdf format to read it please? Sorry if the formulas did not show up for you. The images for the formulas are generated on another sever than where the article itself is hosted. If the server that generates the images is inaccessible, then the formulas may not show up.

Can this be fixed? David: The formulas on this page are rendered by your browser using a JavaScript library called MathJax. If the formulas are not rendering for you, it is probably because you have disabled JavaScript in your browser. This is a great explanation but I got really stuck at why the product of two quaternions is minus the dot product. That would make a. You are right about the fact that as is stated in the section titled Quaternions. So we are not adding any extra negatives, we are just factoring out the from the dot-product to get the real part of the quaternion product.

- Topic Notification;
- Kritik der reinen Vernunft (Erste Fassung 1781) (German Edition).
- The Trade?
- Creating Your Personal Image Online: How to Enhance Your Career Prospects By Building an Impressive Personal Profile on the Internet (Business Matters Book 28)?

No, Gaz is right! The squared terms of i, j, and k should be left out of the dot product equation of a dot b. Then it makes sense. As others have said, the best explanation of quaternions that I have seen. This explanation is still not right. The algebraic result of squaring i, j and k to yield -1 gives us -a. There is some confusion in quaternion theory over when to treat i, j and k as imaginary numbers and when to treat them as unit vectors in the Cartesian system. Doh, you are right! I was treating , , and as imaginary numbers but in the equation they are unit vectors!

This is a great tutoria, but I think Gaz was onto something as I think the dot product is incorrectly defined and is then substituted into the equations incorrectly i. I was treating , , and as imaginary numbers but they are actually unit vectors. I understand why it is SaSb — a. But your explain is not true. In here, we represent vector a and b in bases i, j, k. This is the reason why we need minus before a.

The original equation for the real part is: If you factor out a from the vector part you get: Which can be rewritten as:. Yes, you are right. I hope I have fixed all of the places in this page where formulas were not rendered correctly anymore but if you seen any more then please let me know!

### Your Answer

Yes, again you are correct. Thanks, this was really useful. I finally understood quaternions. Thanks for the article. I suggest you try mathjax. If the quaternion correctly rotated the vector then the result should also be a pure quaternion with no scalar part and the magnitude of the vector part should be the same as the original vector because a rotation should not scale the original vector however this example shows that this is not the case.

Sorry, the matrix representation of a complex number is not explained in this article. I will try to briefly explain it here. We can represent a complex number as the matrix which is the sum of two other matrices representing the real and the imaginary parts note that bold, upper-case characters represent matrices :. It is also interesting to note that if we express the equation in matrix form we get:.

I recently switched LaTeX engines. The new one seems to be a bit more picky about separating parts of the equation for correct rendering. Thank you! Thank you sooo much for this explanation! I searched for good ones in the web for nearly a month and this is far the best and most detailed I read. Now I can implement Quaternion rotation without shaming me for not knowing the stuff I am using…. Many thanks for this extraordinary introduction into quaternions. I really appreciate this work! Thank you. Keep up the magnificent work. The best tutorial of quaternion ever. Hello, I am a little confused about whether I, j and k are all equal to the square root of -1 or whether they are Cartesian unit vectors.

To my mind I cannot see how in one step you can multiply a Cartesian unit vector and get -1 and still say their cross product is another unit vector. Are you defining I, j, and k as imaginary numbers or as unit vectors? I would really appreciate a reply to this question as I otherwise very impressed with the presentation that you have laid out above.

Can you provide a reference to your SLERP equation that shows a proof of the equation you are providing? Note that it does not provide a method to maintain linear velocity over the curve. But this is not a problem if the quaternions are normalized. Perhaps your formula can better achieve constant linear velocity while allowing for non-normalized quaternions?

## On quaternions and octonions: Their geometry, arithmetic, and symmetry

Thank you for pointing this out. I recently moved 3dgep. I have since resolved the issue and confirmed that the equations are showing up now. I am looking into using a different plugin MathJax to have the client browser generate the equations instead of relying on a server side script to generate gifs for all of the equations.

Although Hamilton had previously published several articles on quaternions, it wasn't until the appearance of his book, Lectures on Quaternions , that his invention was given full expression. PMM Provenance : Light pencil ownership signature on half-title dated of A.

Dublin: Hodges and Smith, Octavo, original cloth; custom cloth box. Scattered foxing as usual ; fading to spine and general light wear to cloth. Check all topics that are of interest to you.