1 Forces, Moments and Static Equilibrium

For a rigid body to be in static equilibrium certain conditions have to be met. Specifically, there can be no net moment about its centre of mass and no net force acting on it.

1.1 Forces as Dual Lines in CGA

Let us consider how we might go about representing a force as a line in CGA (a detailed description of CGA is beyond the scope of this paper, instead for background the reader is directed towards [7]). First, consider a force represented by the 3D vector f and passing through point a, we could write this as a 6D vector representing the ‘force line’ F. This 6D representation is known as the Plücker coordinates of the line [2], and is made up of the force vector and moment:

$$ F = \begin{bmatrix} f \\ a\times f \end{bmatrix}{} $$

We could represent this same force line in CGA as the outer product of two points and infinity. This object has a magnitude equal to the intensity of the force:

$$ F = \text {up}\left( a\right) \wedge \text {up}\left( a+f\right) \wedge n_{\infty }, \qquad F^2 = |f|^2 $$

where \(\text {up}\left( x\right) \) denotes the standard embedding of a point x as a 5D conformal point \(X = \frac{1}{2}x^2n_{\infty }+ x + n_{0}\). Consider the dual form of this CGA line:

$$ FI_5 = fI_3 - (a\wedge f)I_3n_{\infty }$$

This looks very similar to the 6D Plücker representation and in fact, on inspection, we see that there is a direct mapping between the two. First, look at the first term, \(fI_3\). This is the 3D dual to a 3D vector, giving a bivector, specifically the Euclidean bivector orthogonal to f. Now consider the second term: \(-(a\wedge f)I_3n_{\infty }\). \(-(a\wedge f)I_3\) is the 3D GA equivalent of the cross product, i.e. a vector equal to \(a\times f\), just like the lower 3 elements of the 6D plucker representation. As \(-(a\wedge f)I_3\) is a Euclidean vector this makes \(-(a\wedge f)I_3n_{\infty }\) the form of a CGA ‘direction bivector’. An important point to note is that under addition the two terms in the formula behave independently, just like in the 6D Plücker representation, i.e.

$$ \lambda _1 F_1I_5 + \lambda _2 F_2I_5 = (\lambda _1 f_1+\lambda _2 f_2)I_3 - (\lambda _1 a_1\wedge f_1 + \lambda _2 a_2\wedge f_2)I_3n_{\infty }$$

Setting \(\lambda _1 = \lambda _2\) and \(f_1 = f = -f_2\) in the above leaves us with two anti-parallel forces:

$$ F_1I_5 + F_2I_5 = -(a_1\wedge f - a_2\wedge f)I_3n_{\infty }$$

which we could re-write as:

$$ B = bn_{\infty }$$

As previously mentioned this is in the form of a CGA ‘direction bivector’. These bivectors have the interesting property of being invariant to the action of translation rotors, effectively making them free vectors in the physics sense. Physically two anti-parallel forces create a force couple, a pure moment, and so we will take objects of the form \(bn_{\infty }\) to be representations of moments in our scheme. This seems apt as, physically, a pure moment is often thought of as a free vector.

We can now write down the static equilibrium conditions directly as:

$$ \sum _i F_iI_5 + \sum _j B_j = 0 $$

where \(F_i\) represent external forces acting on a rigid body and \(B_j\) represent external moments acting on the body.

1.2 Forces as Lines in PGA

In PGA the canonical way to describe a line is as the intersection of two planes. As by default in PGA we are in a so called ‘inner product null space’ or IPNS we perform the intersection of these two planes by the outer product. Let’s break this down component-wise for the intersection of two planes:

$$\begin{aligned} \begin{aligned} P_1&= m_1 + d_1e_0, \,\,\,\,\,\,\, P_2 = m_2 + d_2e_0 \\ L&= P_1\wedge P_2 = (m_1 + d_1e_0)\wedge (m_2 + d_2e_0) \\&= m_1\wedge m_2 + (d_2m_1 - d_1m_2)\wedge e_0 \end{aligned} \end{aligned}$$

we can now re-write this in terms that look more familiar:

$$ L = m_lI_3 - (a\wedge m_l)I_3e_0 $$

In this form the line looks very similar to the CGA representation of the line. The line squares to a scalar, there is a section that is a euclidean bivector and a section that is a null bivector. In fact the only thing that we have changed is the form of the null element. In CGA we typically use the null element \(n_{\infty }\) constructed from the sum of two orthogonal basis vectors, one squaring to +1 and one to \(-1\). Here in PGA the null element \(e_0\) is itself a basis vector. For our 6D force line representation we therefore have exactly the same mapping as we did in CGA:

$$ F = fI_3 - (a\wedge f)I_3e_0 $$

and so moments appear as:

$$ B = be_0 $$

We note that this is, in fact, the same formulation as is used by Gunn in [1].

2 Time Derivatives of Frame Transformations

Before diving into dynamics, we will lay down some notation. A rotor R takes a multivector U from a frame attached to the rigid body to a multivector V expressed in the world frame:

$$ V = RU\tilde{R} , \,\,\,\,\, U = \tilde{R}VR $$

We will also take first and second time derivatives as we will need them later:

$$ \dot{U} = \dot{\tilde{R}}VR + \tilde{R}(\dot{V}R + V\dot{R}) $$
$$\begin{aligned} \ddot{U} = \ddot{\tilde{R}}VR + 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \tilde{R}\ddot{V}R + 2\tilde{R}\dot{V}\dot{R} + \tilde{R}V\ddot{R} \end{aligned}$$
(1)

Standard results [3,4,5] tell us we can write:

$$\begin{aligned} \dot{R} = -\frac{1}{2}\dot{B}_w R \end{aligned}$$
(2)

where the quantity \(\dot{B}_w\) is a generalised instantaneous screw velocity, expressed in the world frame. Geometrically it is a screw and we can transform it just like any other screw between frames. We can therefore write \(\dot{B}_w = R\dot{B}\tilde{R}\) and change Eq. (2) to:

$$\begin{aligned} \dot{R} = -\frac{1}{2}R\dot{B}\tilde{R} R = -\frac{1}{2}R\dot{B} \end{aligned}$$
(3)

where \(\dot{B}\) is the velocity bivector expressed in the body frame. For reference the reverse of this quantity is:

$$ \dot{\tilde{R}} = -\frac{1}{2}\dot{\tilde{B}}\tilde{R} $$

To take further time derivatives we can just use the chain rule:

$$\begin{aligned} \ddot{R} = -\frac{1}{2}R\ddot{B} - \frac{1}{2}\dot{R}\dot{B} , \,\,\,\,\,\,\,\, \ddot{\tilde{R}} = -\frac{1}{2}\ddot{\tilde{B}}\tilde{R} - \frac{1}{2}\dot{\tilde{B}}\dot{\tilde{R}} \end{aligned}$$
(4)

3 Momentum and Inertia

3.1 Screw Momentum

In traditional 3D dynamics formulations we specify that resultant force is the rate of change of linear momentum and resultant moment is the rate of change of angular momentum. In a screw formulation we can specify that, for a body under the influence of multiple external forces \(W_i\), the resultant wrench \(W_r\) is the rate of change of screw momentum \(\varOmega \) with time:

$$ W_r = \sum W_i = \frac{\partial \varOmega }{\partial t} $$

We can, of course, write this whether we are working in CGA or PGA.

3.2 The Screw Inertia Tensor

In 3D dynamics we are used to the idea of converting between linear velocity and linear momentum via multiplication or division by the mass of the rigid body:

$$ \rho _l = mv_l $$

When it comes to angular velocity and angular momentum however we have a more complicated relationship. In fact, for a body centred reference frame, the two are related by a diagonal matrix known as the inertia tensor that we label here as M:

$$ \rho _a = Mv_a $$

We can extend the inertia tensor concept to the CGA motor bivectors (by which we mean the bivectors that when exponentiated produce the motors) using their reciprocal frame. An important thing to note here is that this is different to the concept in screw theory [8] of a screw and a twist being reciprocal, which we will come to later when considering virtual work and power.

The reciprocal frame of the motor bivectors in CGA is as follows:

$$ -e_1I_3,\,\, -e_2I_3,\,\, -e_3I_3,\,\, e_1\wedge n_{0},\,\, e_2\wedge n_{0},\,\, e_3\wedge n_{0}$$

Which we can break into the two groups:

$$ l_i = e_iI_3, \,\,\,\, l^i = -e_iI_3 $$
$$ t_i = e_i\wedge n_{\infty }, \,\,\,\, t^i = e_i\wedge n_{0}$$

and so with these we can construct an inertia tensor:

$$ \varOmega = M(\dot{B}) = m\sum _{i=1}^{i=3} \left[ (\dot{B}\cdot t^i)l_i + \gamma _i(\dot{B}\cdot l^i)t_i \right] $$

we can also construct the inverse inertia tensor:

$$ M^{-1}(\varOmega ) = \dot{B} = \frac{1}{m}\sum _{i=1}^{i=3}\left[ \frac{1}{\gamma _i}(\varOmega \cdot t^i)l_i + (\varOmega \cdot l^i)t_i \right] $$

This inertia tensor performs a ‘flip’ of the input bivectors, as well as re-scaling component-wise. Effectively our inertia tensor does the following mapping:

$$\begin{aligned} e_1I_3&\,\,\rightarrow \,\, e_1\wedge n_{\infty },&e_1\wedge n_{\infty }&\,\,\rightarrow \,\, e_1I_3 \\ e_2I_3&\,\,\rightarrow \,\, e_2\wedge n_{\infty },&e_2 \wedge n_{\infty }&\,\,\rightarrow \,\, e_2I_3 \\ e_3I_3&\,\,\rightarrow \,\, e_3\wedge n_{\infty },&e_3\wedge n_{\infty }&\,\,\rightarrow \,\, e_3I_3 \end{aligned}$$

This reciprocal frame construction works for many algebras but for degenerate metric algebras such as PGA the fact that we have an element squaring to zero means this setup won’t work. Instead we need to do something a little different. The degenerate metric approach to reciprocal frames [6] is to consider some blade which we will label \(x^i\) that wedges with a given blade of magnitude \(b_i\) i.e. \(b_ix_i\) to produce the pseudoscalar with magnitude \(b_i\) i.e. \(b_ix_i\wedge x^i = b_iI\). Clearly, despite us labelling it \(x^i\), this object is not quite the same as the reciprocal frame although it allows us to perform the same function of coordinate free coefficient selection producing the magnitude \(b_i\) as the scalar coefficient of the pseudoscalar. Let’s identify this pseudo-reciprocal frame for the PGA bivectors:

$$\begin{aligned} e_1\wedge e_2&\,\,\rightarrow \,\, -e_3\wedge e_0,&e_1\wedge e_0&\,\,\rightarrow \,\, -e_2\wedge e_3 \\ e_1\wedge e_3&\,\,\rightarrow \,\, e_2 \wedge e_0,&e_2 \wedge e_0&\,\,\rightarrow \,\, e_1\wedge e_3 \\ e_2\wedge e_3&\,\,\rightarrow \,\, -e_1\wedge e_0,&e_3\wedge e_0&\,\,\rightarrow \,\, -e_1\wedge e_2 \end{aligned}$$

Comparing the PGA pseudo-reciprocal frame mapping with that of our CGA-inertia tensor mapping it is immediately clear that they are equivalent up to a minus sign. Let’s define a function to perform this PGA mapping, we will call it J and it will do the following:

$$ J(b_ix_i) = \langle b_ix_i\wedge x^i\rangle _{e1230}x^i = b_ix^i $$

where the syntax \(\langle A \rangle _{e1230}\) returns the scalar coefficient of \(e_1\wedge e_2\wedge e_3\wedge e_0\) in A. We can extend this operation to combinations of basis elements by linearity so that for \(X = \sum _i b_ix_i\):

$$ X^J = J(X) = J\left( \sum _i b_ix_i\right) = \sum _i J(b_ix_i) $$

As with our CGA reciprocal frame let’s now write our PGA pseudo-reciprocal frame in two groups:

$$ l_i = e_iI_3, \,\,\,\, l^i = e_i\wedge e_0 $$
$$ t_i = e_i\wedge e_0, \,\,\,\, t^i = e_iI_3 $$

This means we can write our PGA inertia tensor and inverse as:

$$\begin{aligned} \varOmega = M(\dot{B}) = -m\sum _{i=1}^{i=3} \left[ \langle \dot{B}\wedge l^i\rangle _{e1230}l^i + \gamma _i\langle \dot{B}\wedge t^i\rangle _{e1230}t^i\right] \end{aligned}$$
(5)
$$\begin{aligned} M^{-1}(\varOmega ) = \dot{B} = -\frac{1}{m}\sum _{i=1}^{i=3}\left[ \frac{1}{\gamma _i}\langle \varOmega \wedge l^i\rangle _{e1230}l^i + \langle \varOmega \wedge t^i\rangle _{e1230}t^i \right] \end{aligned}$$
(6)

We could also apply the J map first to first ‘flip’ the input and apply a component-wise scaling A to the result:

$$ \varOmega = M(\dot{B}) = A[J(\dot{B})] $$

4 Unconstrained Rigid Body Dynamics

Fig. 1.
figure 1

A cuboid is simulated spinning about its 2nd principal axis of inertia while translating linearly. Due to the intermediate axis theorem small instabilities in the rotation build quickly causing rapid flips in orientation. Despite these rapid flips the linear motion of the centre of mass is unaffected. Blue: the path of the centre of mass, Green, Red, Orange: the path of several vertices on the cuboid as it undergoes a flip in orientation. (Color figure online)

Equipped with forces, moments, momentum, velocities and inertia tensors we are now at a position where we can formulate the equations of motion and simulate them. We will start by considering the dynamics of an unconstrained rigid body moving under the influence of external forces and moments. We can write the state of our rigid body at a time t and its first time derivative as (Fig. 1):

$$ Y_t = \begin{bmatrix} R_t\\ \varOmega _t \end{bmatrix}, \quad \dot{Y_t} = \begin{bmatrix} \dot{R_t}\\ \dot{\varOmega }_t \end{bmatrix} = \begin{bmatrix} -\frac{1}{2}R_t\dot{B}_t\\ R_tW_{bt}\tilde{R}_t \end{bmatrix} $$

where \(\varOmega _t\) is the momentum bivector at time t expressed in the world frame and \(W_{bt}\) is the result external wrench acting on the body expressed in the body frame. From this point on we will drop the t subscript and simply state that all variables are functions of time. From our discussion in the previous section we know that we can further expand \(\dot{B}\) using the inverse inertia tensor \(M^{-1}\):

$$ \dot{B} = M^{-1}[\tilde{R}\varOmega R] $$

Re-writing the time derivative of the state with this equation for \(\dot{B}\) gives:

$$ \dot{Y} = \begin{bmatrix} \dot{R}\\ \dot{\varOmega } \end{bmatrix} = \begin{bmatrix} -\frac{1}{2}RM^{-1}[\tilde{R}\varOmega R]\\ RW_{b}\tilde{R} \end{bmatrix} $$

5 Constrained Dynamics via Virtual Power

To impose a constraint on our dynamics model we will use the concept of a reaction wrench. The reaction wrench provides a combined external force and moment that acts on the rigid body in addition to the other external wrenches and, in doing so, forces the body to move in a way that respects the constraints. We will write \(W_b\) as the sum of external wrenches S plus some reaction wrench F caused by the constraints. As we already know S, all we need to calculate F is the value of \(W_b\) required to keep the constraints valid.

In traditional constrained dynamics work the concepts of virtual work and virtual power are widespread. In the virtual work/virtual power literature constraints are enforced by imagining several independent virtual reaction forces and moments at the constraint position and ensuring that any velocity of the body produces zero power against these forces/moments. In the screw framework that we have developed the virtual power P produced by a virtual world frame wrench T when the body moves with a body frame screw velocity \(\dot{B}\) is given by:

$$ P = \dot{B}\wedge (\tilde{R}TR) $$

and, for CGA, is of the form:

$$ P = pI_3n_{\infty }$$

where p is a virtual scalar power. Differentiating this gives:

$$ \dot{P} = \ddot{B}\wedge (\tilde{R}TR) + \dot{B}\wedge \left( \dot{\tilde{R}}TR + \tilde{R}(\dot{T}R + T\dot{R})\right) $$

We can now substitute in our dynamics equation for \(\ddot{B}\):

$$\begin{aligned} \begin{array}{c} \displaystyle \ddot{B} = M^{-1}[\dot{\tilde{R}}\varOmega R + W_b + \tilde{R}\varOmega \dot{R}] \\ \displaystyle \dot{P} = M^{-1}[\dot{\tilde{R}}\varOmega R + W_b + \tilde{R}\varOmega \dot{R}]\wedge (\tilde{R}TR) + \dot{B}\wedge \left( \dot{\tilde{R}}TR + \tilde{R}(\dot{T}R + T\dot{R})\right) \end{array} \end{aligned}$$

Setting the virtual power and rate of change of virtual power to 0 gives us the virtual power condition for our constraint:

$$ 0 = \dot{B}\wedge (\tilde{R}TR) $$

Setting the rate of change of virtual power to be zero allows us to write:

$$\begin{aligned} \begin{array}{c} \displaystyle M^{-1}[\dot{\tilde{R}}\varOmega R + W_b + \tilde{R}\varOmega \dot{R}]\wedge (\tilde{R}TR) = - \dot{B}\wedge \left( \dot{\tilde{R}}TR + \tilde{R}(\dot{T}R + T\dot{R})\right) \\ \displaystyle M^{-1}[W_b]\wedge (\tilde{R}TR) = - M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}]\wedge (\tilde{R}TR) - \dot{B}\wedge \left( \dot{\tilde{R}}TR + \tilde{R}(\dot{T}R + T\dot{R})\right) \end{array} \end{aligned}$$

If T is a static constraint we can specify that \(\dot{T} = 0\) leaving us with:

$$ M^{-1}[W_b]\wedge (\tilde{R}TR) = - M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}]\wedge (\tilde{R}TR) - \dot{B}\wedge \left( \dot{\tilde{R}}TR + \tilde{R}T\dot{R}\right) $$

Which can again be solved for \(W_b\) and hence F.

If we specify the way that T varies with time we can add curved surface constraints. Consider a situation in which a rigid body is constrained such that one point A always touches a sphere centred at point V. Given the point is always touching the sphere we know that T must always be parallel to the line joining A and V, we would therefore write:

$$ T = A\wedge V \wedge n_{\infty }$$

taking a time derivative of this we see:

$$ \dot{T} = \dot{A}\wedge V \wedge n_{\infty }$$

As A is driven by the rotor R, we get:

$$ A = RA_0\tilde{R}, \,\,\,\,\,\,\,\, \dot{A} = \dot{R}A_0\tilde{R} + RA_0\dot{\tilde{R}} $$

and so:

$$ \dot{T} = (\dot{R}A_0\tilde{R} + RA_0\dot{\tilde{R}})\wedge V \wedge n_{\infty }$$

We can then directly substitute this into:

$$ M^{-1}[W_b]\wedge (\tilde{R}TR) = - M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}]\wedge (\tilde{R}TR) - \dot{B}\wedge \left( \dot{\tilde{R}}TR + \tilde{R}(\dot{T}R + T\dot{R})\right) $$

and so calculate \(W_b\). To constrain this same point to a circle we would add an additional planar constraint (or indeed another spherical one), i.e. the point must lie on the plane in which the circle lies and on the sphere of which the circle is the equator.

6 Constrained Dynamics by Pinned Multivectors

As in Sect. 2 consider again a geometric primitive represented by multivector U in the body frame and the same geometric primitive represented by multivector V when expressed in the world frame. As we saw before the two multivectors can be related by the rotor R:

$$ V = RU\tilde{R}, \,\,\,\,\,\,\, U = \tilde{R}VR $$

We also saw previously that we can calculate the first and second time derivatives of this relationship giving us the expressions:

$$\begin{aligned} \begin{aligned} \dot{U}&= \dot{\tilde{R}}VR + \tilde{R}(\dot{V}R + V\dot{R}) \\ \ddot{U}&= \ddot{\tilde{R}}VR + \dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \tilde{R}(\ddot{V}R + 2\dot{V}\dot{R} + V\ddot{R}) \\&= \ddot{\tilde{R}}VR + 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \tilde{R}\ddot{V}R + 2\tilde{R}\dot{V}\dot{R} + \tilde{R}V\ddot{R} \end{aligned} \end{aligned}$$

Let’s take a second and think about what these expressions mean physically. Essentially we have two ‘views’ of the same object, one in body space and one in world space. For example we can imagine the U is a point attached to our rigid body and V is a point in the world that point is also attached to. In a sense we are ‘pinning’ the rigid body to V by its extremity U (Fig. 2).

Fig. 2.
figure 2

Left: A physical pendulum moves under the effect of gravity and with a starting linear momentum. It is constrained such that a line, coincident with one end of the pendulum shown in blue, is pinned between the body and world reference frames. The symmetry of the line leads to constrained motion along and about the line. Right: A spinning cone is affected by gravity but is constrained such that its end point, shown in blue, does not move. Precession and nutation are observable in the movement of the centre of mass, shown in green, and a point on the rim of the cone, shown in red. (Color figure online)

Lets consider first the case that both of these ‘views’ of the object are fixed, i.e. the position and orientation of U cannot change with respect to the coordinate system of the body and the position and orientation of V cannot change with respect to the origin. Mathematically we are stating that \(\dot{U}, \ddot{U}, \dot{V}, \ddot{V} = 0\). If we substitute these values into (1) for the time derivatives we end up with the following equation:

$$\begin{aligned} 0 = \ddot{\tilde{R}}VR + \tilde{R}V\ddot{R} + 2\dot{\tilde{R}}V\dot{R} \end{aligned}$$
(7)

This equation is a constraint on the second time derivative of R that will ensure that U and V do not vary with time. We can go a step further here and substitute our expression for \(\ddot{R}\) from Eq. (4), leading to:

$$ 0 = -\frac{1}{2}\ddot{\tilde{B}}\tilde{R}VR - \frac{1}{2}\dot{\tilde{B}}\dot{\tilde{R}}VR - \frac{1}{2}\tilde{R}V R\ddot{B} - \frac{1}{2}\tilde{R}V \dot{R}\dot{B} + 2\dot{\tilde{R}}V\dot{R} $$

Now if we substitute in \(\dot{R} = -\frac{1}{2}R\dot{B}\) and \(\dot{\tilde{R}} = -\frac{1}{2}\dot{\tilde{B}}\tilde{R}\):

$$ 0 = -\frac{1}{2}\ddot{\tilde{B}}\tilde{R}VR + \frac{1}{4}\dot{\tilde{B}}\dot{\tilde{B}}\tilde{R}VR - \frac{1}{2}\tilde{R}V R\ddot{B} + \frac{1}{4}\tilde{R}VR\dot{B}\dot{B} + \frac{1}{2}\dot{\tilde{B}}\tilde{R}VR\dot{B} $$

Simplify and gather, substituting \(U = \tilde{R}VR\):

$$ 0 = -\frac{1}{2}\ddot{\tilde{B}}U - \frac{1}{2}U\ddot{B} + \frac{1}{4}\dot{\tilde{B}}^2U + \frac{1}{4}U\dot{B}^2 + \frac{1}{2}\dot{\tilde{B}}U\dot{B} $$

Now separate the terms with \(\ddot{B}\):

$$ \frac{1}{2}\ddot{\tilde{B}}U + \frac{1}{2}U\ddot{B} = \frac{1}{4}\dot{\tilde{B}}^2U + \frac{1}{4}U\dot{B}^2 + \frac{1}{2}\dot{\tilde{B}}U\dot{B} $$

As \(\dot{B}, \ddot{B}\) are bivectors their reverse is just a negation:

$$\begin{aligned} -\frac{1}{2}\ddot{B}U + \frac{1}{2}U\ddot{B} = \frac{1}{4}\dot{B}^2U + \frac{1}{4}U\dot{B}^2 - \frac{1}{2}\dot{B}U\dot{B} \end{aligned}$$
(8)

We have done a lot of algebra but so far appear to be no closer to calculating our reaction wrench. If we calculate an expression for \(\ddot{B}\) however we start to make headway towards a solution:

$$ \ddot{B} = M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\dot{\varOmega }R + \tilde{R}\varOmega \dot{R}] $$

using \(W_b = \tilde{R}\dot{\varOmega }R\) we can also write:

$$\begin{aligned} \ddot{B} = M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}] + M^{-1}[W_b] \end{aligned}$$
(9)

and so we can now substitute in on the left hand side of Eq. (8) for \(\ddot{B}\):

$$ LHS =-\frac{1}{2}\left( M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}] + M^{-1}[W_b] \right) U + \frac{1}{2}U \left( M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}] + M^{-1}[W_b] \right) $$

Now we separate out the terms with \(W_b\)

$$ = -\frac{1}{2}M^{-1}[W_b]U + \frac{1}{2}UM^{-1}[W_b] + \left( -\frac{1}{2} M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}]U + \frac{1}{2}U M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}] \right) $$

and take all the stuff in brackets onto the right side of the equation. We now have something of the form:

$$ -\frac{1}{2}M^{-1}[W_b]U + \frac{1}{2}UM^{-1}[W_b] = \text {Some function of }R, \varOmega , U $$

We can rewrite this to use the commutator product:

$$\begin{aligned} (U\times M^{-1}[W_b]) = \text {Some function of } R, \varOmega , U \end{aligned}$$
(10)

If we now decide to write our total bivector wrench \(W_b\) as the sum of external wrenches S plus some reaction wrench F caused by the constraints:

$$ (U\times M^{-1}[F]) = -(U\times M^{-1}[S]) + \text {Some function of }R, \varOmega , U $$

we now have a constraint expression that fixes the reaction wrench F as a function of the state of the system and the forces applied to it.

For a given \(R, \varOmega , U\) this constraint is linear in F and can be solved for F so long as we provide a correct basis for the constraint wrench. An important point to make here is that this discussion has been entirely algebra agnostic, i.e. this framework works equally well for CGA, PGA or indeed many other geometric algebras, a topic that we will return to later on.

7 Pinning Parametric Multivectors Paths

So far in our construction of multivector pinning constraints we have assumed that the objects that we are pinning are static in both the world and body frame. When working with constrained dynamics in the real world we often want to affix parts of our rigid body to moving things in the real world, such as a manipulator attached to the moving end-point of a robot, or a flywheel fixed in a moving vehicle. Consider once again Eq. (1):

$$ \ddot{U} = \ddot{\tilde{R}}VR + 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \tilde{R}\ddot{V}R + 2\tilde{R}\dot{V}\dot{R} + \tilde{R}V\ddot{R} $$

In the previous section we enforced static multivector constraints by setting \(\dot{U},\ddot{U},\dot{V},\ddot{V}\) to zero, rearranging to isolate the \(\ddot{R}\) terms and solving the resultant linear equation for \(W_b\). Now we will relax the static constraint and consider the cases when UV are known time varying multivector functions, i.e. when \(\dot{U},\ddot{U},\dot{V},\ddot{V} \ne 0\).

First note we can still rearrange to separate terms in \(\ddot{R}\):

$$ \ddot{\tilde{R}}VR + \tilde{R}V\ddot{R} = - 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) - \tilde{R}\ddot{V}R - 2\tilde{R}\dot{V}\dot{R} + \ddot{U} $$

and we can continue as in our previous analysis by breaking up \(\ddot{R}\) as a function of \(\ddot{B}\) and extracting \(W_b\):

$$ \ddot{\tilde{R}}VR + \tilde{R}V\ddot{R} = (-\frac{1}{2}\ddot{\tilde{B}}\tilde{R} - \frac{1}{2}\dot{\tilde{B}}\dot{\tilde{R}})VR + \tilde{R}V(-\frac{1}{2}R\ddot{B} - \frac{1}{2}\dot{R}\dot{B}) $$

Continuing to substitute expressions as before we can expand this to the form:

$$\begin{aligned} \begin{aligned} (\tilde{R}VR) \times M^{-1}[F] =&- \ddot{U} + M^{-1}[S]\times (\tilde{R}VR) + 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \tilde{R}\ddot{V}R + 2\tilde{R}\dot{V}\dot{R} \\&+ \, M^{-1}[\dot{\tilde{R}}\varOmega R + \tilde{R}\varOmega \dot{R}] \times (\tilde{R}VR) - \frac{1}{2}\dot{\tilde{B}}\dot{\tilde{R}}VR - \frac{1}{2}\tilde{R}V\dot{R}\dot{B} \end{aligned} \end{aligned}$$

if we substitute \(U=\tilde{R}VR\) we have eventually got to a position where:

$$ (U\times M^{-1}[F]) = \text {Some function of }R, \varOmega , U, \dot{U}, \ddot{U}, V, \dot{V}, \ddot{V}, S $$

Again this is a linear function in F and solvable so long as it is of sufficient rank. What this means practically is that we can set U and V to follow any desired path we like in their respective spaces and extract the reaction forces and moments acting on the body that are required to keep them pinned to each other.

Fig. 3.
figure 3

A physical pendulum moves under gravity is constrained such that one end of it, shown in blue, is always in contact with the surface of an object. The green trace shows the midpoint of the pendulum and the red shows the free end. Left: a sphere. Right: a circle. (Color figure online)

8 Pinning Linear Functions of Parametric Multivector Paths

In the previous two sections we dealt directly with transformations that pin static multivectors or time varying multivector paths directly to each other in space. In many practical situations what we would really like to pin is a linear function of one multivector to another. For example we could pin the outer product of a point in the body frame and a plane in the world frame to 0, effectively forcing them to be coincident without specifying anything about their relative orientation (unlike in the transformed plane invariant case). Mathematically we can express our linear function constraint as \(A[\,]\) and time derivatives as:

$$\begin{aligned} \begin{array}{c} \displaystyle U = A\left[ \tilde{R}VR\right] , \,\,\,\,\,\,\,\, \dot{U} = A\left[ \dot{\tilde{R}}VR + \tilde{R}(\dot{V}R + V\dot{R})\right] \\ \displaystyle \ddot{U} = A\left[ \ddot{\tilde{R}}VR + 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) + \tilde{R}\ddot{V}R + 2\tilde{R}\dot{V}\dot{R} + \tilde{R}V\ddot{R} \right] \end{array} \end{aligned}$$

Once again we can rearrange:

$$ A\left[ \ddot{\tilde{R}}VR + \tilde{R}V\ddot{R}\right] = A\left[ - 2\dot{\tilde{R}}(\dot{V}R + V\dot{R}) - \tilde{R}\ddot{V}R - 2\tilde{R}\dot{V}\dot{R} \right] + \ddot{U} $$

leading to an equation of the form:

$$ A\left[ (\tilde{R}VR)\times M^{-1}[F]\right] = A\left[ -((\tilde{R}VR)\times M^{-1}[S]) + \text {Some function of }R, \varOmega , U, \dot{U}, \ddot{U}, V, \dot{V}, \ddot{V} \right] - \ddot{U} $$

Again this is linear and solvable as before. Figure 3 shows the simulation with the Clifford Python library [9] of two cases in which the linear function is the outer product with one end of a physical pendulum.

9 Conclusion

In this paper we have looked at forces, moments, free and constrained dynamics in both CGA and PGA. As well as considering how to apply virtual power as a constraint mechanism in our GA formulations we have constructed a novel technique for constrained dynamics in GA via the concept of multivector pinning. While in this paper we have only considered two algebras, CGA and PGA, the techniques are expected to work across the board for algebras with easily representable line elements and motor bivectors. Using other higher dimensional algebras such as Cl(4, 4) [10], Cl(8, 2) [11] or even Cl(9, 6) [12] with this technique in future should allow for easy configurations of exotic constraints such as pinning dynamic objects to the surface of quadrics.