differentiation with respect to a quaternion

273 Views Asked by At

My question is as follows: if I have a unit quaternion(used to represent the rotation) $q=[q_{0}\,\textbf{q}]$ and a pure quaternion $v=[0\,\textbf{v}]$,where $\textbf{v}$ is a 3x1 vector.* is the quaternion multiplication.

  1. what is $\frac{\partial (q*v*q^{-1})}{\partial v}$? could you show me which one of following options is right?

I have searched some materials about quaternion derivatives, and one of them(https://web.cs.iastate.edu/~cs577/handouts/quaternion.pdf) show an result like:$\frac{\partial (q*v*q^{-1})}{\partial v}=(q_{0}^2-||\textbf{q}||^2)I_{3}+2\textbf{q}\textbf{q}^T-2q_{0}\textbf{q}\times$

Another potential answer is:$\frac{\partial (q*v*q^{-1})}{\partial v}=q*e_{i}*q^{-1}$, where $e_{i}$ are basis of inertial frame.

  1. what is $\frac{\partial (q*v*q^{-1})}{\partial q}$?

  2. what is $\frac{\partial (q*p^{-1})}{\partial q}$? p is also a unit quaternion.

1

There are 1 best solutions below

2
On BEST ANSWER

I'll change your notation slightly, denoting multiplication as$$[a,\,u][b,\,v]=[ab-u\cdot v,\,av+bu+u\times v]$$so$$\begin{align}qvq^{-1}&=\frac{[q_0,\,q][0,\,v][q_0,\,-q]}{q_0^2+q^2}\\&=\frac{[-q\cdot v,\,q_0v-q\times v][q_0,\,-q]}{q_0^2+q^2}\\&=\frac{[0,\,2(q\cdot v)q+(q_0^2-q^2)v+2q_0v\times q]}{q_0^2+q^2},\end{align}$$with $q^2=q\cdot q$ in terms of the $3$-vector $q$. Differentiation with respect to $v_a,\,a\in\{1,\,2,\,3\}$ gives a pure quaternion whose $b$th imaginary entry, $b\in\{1,\,2,\,3\}$, is$$\frac{2q_aq_b+(q_0^2-q^2+2q_0\times q)\delta_{ab}}{q_0^2+q^2}.$$You can treat parts 2, 3 similarly.