1
$\begingroup$

I am building a biomechanical model that consists of spherical joints. I wanted to represent these spherical joints by quaternions. I am struggling to derive how the muscles contribute to the dynamical system.

When you model a system where your joints are represented by Euler or Tait-Bryan angles, you take a derivative of the muscle length w.r.t. generalized coordinate and that is your moment arm ( $R_{q_i} = \partial l(\textbf{q})/\partial q_i$ ). It is based on the virtual work equivalence ($sdl = \tau_{\phi}d\phi$, where $s$ is muscle tension force, $l=l(\phi)$ is path length along which tension $s$ is acting). You just multiply it by the muscle force and you can add it to your EoMs as generalized forces like this:

$\textbf{M} \ddot q = \textit{f} + R*muscleForce $.

The problem is, how to apply this method (or another approach that would work) when using quaternion as an representation of rotation. The muscle length is now a function of quaternion and the equations of motion now have angular velocities instead of generalized speeds, so now the muscle should probably act as an external torque in the body's frame.

As quaternion basically represents the axis and angle of a rotation, so there may be a way how to calculate the axis around which the torque is acting based on the current length of the muscle, but I haven't found a way how to do it. Thanks for help.

Edit:

So I have found out the way how to do it. The tendon excursion method is basically calculating the jacobian. So I tried to calculate it the same way with the quaternion representation. The jacobian of the tendon length $J$ is now $J = \partial l(\textbf{Q})/ \partial Q_i$, where $\textbf{Q}$ is a quaternion and $Q_i$ are the elements of quaternion. Since I have my equations of motion in terms of angular velocities, I need to map the jacobian from generalized coordinates to spatial coordinates of the rigid body. I used the mapping based on this article - https://arxiv.org/abs/0811.2889:

$\omega' = 2G\dot{\textbf{Q}}$,

$G = \begin{bmatrix}-Q_1 & Q_0 & Q_3 & -Q_2\\ -Q_2&-Q_3& Q_0& Q_1 \\ -Q_3& Q_2& -Q_1& Q_0\end{bmatrix}$

where $\omega'$ is angular velocity in body reference frame, $\dot{\textbf{Q}}$ is time derivative of quaternion and $G$ is the mapping matrix. The correct spatial moments acting on the rigid body from the muscles forces are now:

$M^B = \frac{1}{2} G \frac{\partial l(\textbf{Q})}{\partial Q_i} * MuscleForce$

I have checked that the results with this method are correct. The problem is I don't actually know why this is now divided by 2 instead of multiplying by 2 as I have came to this fraction experimentally.

$\endgroup$
4
  • $\begingroup$ The differential equation for the quaternion is: \begin{align*} &\mathbf{\dot{q}}=\frac 12 \begin{bmatrix} 0 & -\mathbf{\omega}^T_b \\ \mathbf{\omega}_b & -\mathbf{\omega}_b \\ \end{bmatrix}\,\mathbf{q}+\frac{P}{2}\left( 1-\mathbf{q}^T\,\mathbf{q}\right)\,\mathbf{q} \end{align*} where b state for body system. P is some constant to make $~\mathbf q^T\,\mathbf q=1~$ . The rotation matrix $~\mathbf R~$ is a function of the quaternion $~\mathbf q$ $\endgroup$
    – Eli
    Commented Jul 13 at 17:14
  • $\begingroup$ I have problem with your notation you use $~\mathbf q~$ for the generalized coordinate and for the quaternion ?. $\endgroup$
    – Eli
    Commented Jul 13 at 17:22
  • $\begingroup$ I edited the text so it's clear. $q$ is for Euler or Tait-Bryan angles and $Q$ is for quaternion. I have used the mapping G that maps the time derivative of quaternion to angular velocity and it works for the muscle jacobian as well, I just wasn't sure about the 1/2 there as a constant. $\endgroup$
    – blenderman
    Commented Jul 15 at 15:10
  • 1
    $\begingroup$ I have found a chapter in the paper cited that deals with with mapping from spatial torques to generalized forces (where generalized coordinates are now quaternion coordinates). It says $\textbf{F}_Q = 2G^T T'$, where $T'$ is applied torque. From this you have $\frac{1}{2} G\textbf{F}_Q = T'$, which probably answers my question. Now however the problem is the seconds equation works but it seems the I am not able to map it back (using the first equation) and I don't know why not. $\endgroup$
    – blenderman
    Commented Jul 15 at 16:34

1 Answer 1

0
$\begingroup$

The answer is actually in the same paper I cited. The mapping between generalized forces and spatial forces is derived using virtual work:

$F_{Q} = 2G^T T'$

where $F_Q$ is a $4 \times 1$ vector of generalized forces, $T'$ is a $3 \times 1$ vector of spatial forces and G is the mapping matrix. From this the answer on my question is easily obtained.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.