Does power rule holds for time functions of unit quaternions? I'm trying to understand quaternion calculus. Let's suppose I have a time function of unit quaternion: $q(t) = (\cos \theta(t), (\sin \theta(t)) \mathbf{a}(t)), \mathbf{a}(t) \in \mathbb{R}^3$, $||\mathbf{a}(t)|| = 1$ $\forall$ $t$ to the power $f(t) \in \mathbb{R}$. Would someone clarify if $\dfrac{d\left(q(t)^{f(t)}\right)}{dt}$ $$= \left(−\sin(fθ) \dfrac{d(f\theta)}{dt}, \mathbf{a}\cos(fθ)\dfrac{d(f\theta)}{dt} + \dfrac{d(\mathbf{a})}{dt}\sin(fθ)\right)$$ or $$
= q(t)^{f(t)} \times \dfrac{d}{dt} \left[f(t) \ln q(t)\right] = q(t)^{f(t)} \times \dfrac{d}{dt} \left[f(t) \cdot (0, \theta(t) \mathbf{a}(t)) \right] \\
= (\cos (f\theta), (\sin (f\theta))\mathbf{a}) \times (0, f'\theta\mathbf{a} + f\theta'\mathbf{a} + f\theta\mathbf{a}') $$ or both are correct? (BTW, do we have a general formula for $\mathbf{a} \times \mathbf{a}'$?) Thanks a lot.
 A: Technically the power $q^f$ is ill-defined, but I guess it's ok shorthand for $\exp(f\theta\mathbf{a})$.
Your first application of the chain rule is correct.
Your second application seems to be using the idea that $(e^\mathbf{v})'=e^\mathbf{v} \mathbf{v}'$. This is wrong. First of all, there's no reason to expect $e^\mathbf{v}\mathbf{v}'$ any more than $\mathbf{v}'e^\mathbf{v}$, but if these were the same then $e^\mathbf{v}\mathbf{v}'e^{-\mathbf{v}}=\mathbf{v}'$ which means rotating $\mathbf{v}'$ around $\mathbf{v}$ by an angle of $\|\mathbf{v}\|$ fixes $\mathbf{v}'$, which is easy to cook up a counterexample to.
Indeed, writing $\mathbf{v}=\theta\mathbf{u}$ with $\mathbf{u}$ a unit vector (so $f=1$ here), we have
$$ (e^\mathbf{v})'=(e^{\theta\mathbf{u}})'
=(\cos\theta+\sin\theta\,\mathbf{u})'
=\color{Green}{(-\sin\theta+\cos\theta\,\mathbf{u})\theta'}+\color{Blue}{\sin\theta\,\mathbf{u}'} $$
whereas
$$ e^\mathbf{v}\mathbf{v}'
=(\cos\theta+\sin\theta\,\mathbf{u})(\theta'\mathbf{u}+\theta\mathbf{u}')
=\color{Green}{(-\sin\theta+\cos\theta\,\mathbf{u})\theta'} +\color{Purple}{\theta\cos\theta\,\mathbf{u}'}+\color{Red}{\theta\sin\theta\mathbf{u}\mathbf{u}'}. $$
Notice $\color{Blue}{\sin\theta\,\mathbf{u}'}$ doesn't match $\color{Purple}{\theta\cos\theta\,\mathbf{u}'}$ and $\color{Red}{\theta\sin\theta\mathbf{u}\mathbf{u}'}$ doesn't match anything.
Keep in mind $\mathbf{u},\mathbf{u}',\mathbf{u}\mathbf{u}'$ are three orthogonal vectors. (Differentiating $\mathbf{u}\cdot\mathbf{u}=1$ yields $\mathbf{u}\cdot\mathbf{u}'=0$, so we know $\mathbf{u}$ and $\mathbf{u}'$ are orthogonal, which means $\mathbf{u}\mathbf{u}'=\mathbf{u}\times\mathbf{u}'$ is orthogonal by properties of the cross product; also note the quaternion product of vectors is $\mathbf{ab}=-\mathbf{a}\cdot\mathbf{b}+\mathbf{a}\times\mathbf{b}$.)
