1

I am trying to use Geometric Algebra to rotate a 4D vector, given 6 rotation angles for each of the planes. So for $e_1e_2$:

Vector: $ v = ae_1 + be_2 + ce_3 + de_4 $

Rotor in $e_1e_2$ plane: $R_{e_1e_2\theta} = \cos\theta/2 - \sin\theta/2e_1e_2 = e^{-e_1e_2\theta/2} $

Rotation of $v$ in plane $e_1e_2$: $R(v) =R_{e_1e_2\theta} (v)R_{-e_1e_2\theta} $

Writing $A = cos\theta/2$, $ B = \sin\theta/2$

the equation becomes:

$R(v) = (A-Be_1e_2)(ae_1 + be_2 + ce_3 + de_4)(A+Be_1e_2)$

After spending a very long time expanding these brackets I ended up with the new vector:

$v' = (a\cos\theta - b\sin\theta) e_1 + (a\sin\theta + b\cos\theta)e_2 + ce_3 + de_4 $

This looks like the the standard rotation formula I was trying to avoid to prevent gimball lock.

I am very confused. Is there a way to implement rotations with Geometric Algebra or Quaternions for a given set of angles? I have found lots of methods for rotating a 4D vector to another predefined vector but nothing using angles.

I have been considering specifiying a new vector to rotate to instead of using angles. Could I add a scaled unit vector to rotate my 4D vector?

Something like: $v_{old} = ae_1 + be_2 + ce_3+ de_4\\ v_{rotateTo} = \frac{ae_1 + be_2 +ce_3 + de_4 + fe_1}{|ae_1 + be_2 +ce_3 + de_4 + fe_1|} $

I would greatly appreciate any help you could offer me

  • 1
    What do you mean by "a given set of angles"? Are they for rotating in each plane in a certain order (which will probably cause gimbal lock), or are they the 6 components of a single bivector (whose exponential is a rotor)? – mr_e_man Aug 07 '19 at 04:45
  • @mr_e_man I was referring to the six planes in which you can rotate. If possible I would like to avoid rotating in order. Do you mean that a single bivector can take the form: B = ae1e2 + be1e3 + ce1e4 + de2e3 + fe2e4 + ge3e4, and that a rotor e^B could be used to rotate a vector in one go? This looks like it would be implemented as the composition of rotations: exp(B) (v) exp(-B) = exp(ae1e2) ... * exp(ge3e4) v * exp(-ge3e4) ... * exp(-a*e1e2). Is this correct? I don't get why this is different from multiplying out a standard set of 6 rotation matrices? – user2784462 Aug 07 '19 at 12:32
  • 1
    Yes, almost; but the exponential function has $\exp(A+B)=\exp(A)\exp(B)$ only when $A$ and $B$ commute ($A\times B=0$). This works for something like $ae_1e_2+be_3e_4$, which represents a double rotation in two independent planes. In general, to calculate the exponential, you need to decompose the bivector into commuting simple bivectors: https://math.stackexchange.com/questions/2786995/how-to-decompose-a-bivector-into-a-sum-of-orthogonal-blades – mr_e_man Aug 08 '19 at 02:45
  • 1
    To rotate the unit vector $v_{old}$ to $v_{new}$ within that plane (meaning a simple rotation, not a double rotation), you can take the rotor to be $$R=\frac{v_{new}v_{old}+1}{\lVert v_{new}v_{old}+1\rVert}$$ which is equivalent to taking a complex square root of $v_{new}v_{old}$. – mr_e_man Aug 08 '19 at 03:01

0 Answers0