0
$\begingroup$

tl;dr

What would be the equivalent of Givens Rotations for unit quaternions?

Or, equivalently:

How do I extract an intrinsic rotation from a unit quaternion using only elementary operations? That is, arithmetic, integer power and square root operators, but not trigonometry or transcendental functions.


Background:

I want to remove the influence of an intrinsic rotation from a quaternion. Because of computational constraints, I only want to use basic arithmetic, integer power (e.g. square) and square-root operators. If I could use trigonometry operators, then wikipedia or this question tells me everything I need to know.

That is, given a quaternion $\mathbf{q}$, I want to calculate $\mathbf{b} = \begin{bmatrix} b_w & b_x & b_y & b_z \end{bmatrix}$, $c_\theta$ and $s_\theta$ from: $$ \mathbf{q} = \begin{bmatrix} c_\theta \\ 0 \\ 0 \\ s_ \theta\end{bmatrix} \otimes \begin{bmatrix} b_w \\ b_x \\ b_y \\ b_z \end{bmatrix} $$ where $\mathbf{b}$ is calculated from the remaining two intrinsic rotations, the order of which are not important to this problem.

Using rotation matrices, the process is easy enough using Givens Rotations:

Given: $$ \begin{bmatrix} c & -s & 0 \\ s & c & 0 \\ 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} R_{11} & R_{12} & R_{13} \\ R_{21} & R_{22} & R_{23} \\ R_{31} & R_{32} & R_{33} \end{bmatrix} = \begin{bmatrix} M_{11} & M_{12} & M_{13} \\ 0 & M_{22} & M_{23} \\ M_{31} & M_{32} & M_{33} \end{bmatrix}$$

then $c$, $s$, and $M_{11}$ are easily solvable as: $$ \begin{align} M_{11} = \sqrt{R_{11}^2 + R_{21}^2} \\ c = \frac{ R_{11}}{M_{11}} \\ s = \frac{-R_{21}}{M_{11}} \end{align} $$

From this, determining the remaining elements of $\mathbf{M}$ is straightforward.

Is there an equivalent "Givens Rotation" operation for quaternions?

$\endgroup$
4
  • $\begingroup$ Are you saying: given a unit quaternion $u$, you want to write the 3D rotation $x\mapsto uxu^{-1}$ as a product of three coordinate axis rotations? (Note that a rotation by $\theta$ around the $i$ axis is given by $x\mapsto uxu^{-1}$ where $u=\exp(i\theta/2)$, and similarly for the $j$ and $k$ axes.) Otherwise I don't understand what it is that you want. $\endgroup$
    – anon
    Commented Aug 29, 2017 at 3:38
  • $\begingroup$ @anon, I will edit the question. $\endgroup$
    – Damien
    Commented Aug 29, 2017 at 3:42
  • $\begingroup$ It seems like your question is indeed the one I posed for you in my comment. Right? Or at least finding the first factor $e^{i\theta/2}$ in a factorization $q=\pm e^{i\theta/2}e^{j\phi/2}e^{k\rho/2}$. $\endgroup$
    – anon
    Commented Aug 29, 2017 at 3:56
  • $\begingroup$ @anon, yes, the first factor is all I am interested in. $\endgroup$
    – Damien
    Commented Aug 29, 2017 at 3:59

0

You must log in to answer this question.

Browse other questions tagged .