artivis / manif

A small C++11 header-only library for Lie theory.
https://artivis.github.io/manif
MIT License
1.46k stars 239 forks source link

Question about left Jacobian trick in exp of SE(3). Is it just a special case? #264

Closed strasdat closed 1 year ago

strasdat commented 1 year ago

Here, the left Jacobian ljac is used to calculate the exponential of the transnational part of the tangent vector lin:

asSO3().ljac()*lin()`

https://github.com/artivis/manif/blob/devel/include/manif/impl/se3/SE3Tangent_base.h#L156.

However, this trick seems only to work co-incidentally, since for SE(3), the dimension of the translation (3) matches the number of degrees of freedom (3) accidentally.

For SE(2) for instance, we have translation dimension of 2, but degrees of freedom of 1 (angle).

I have not seen the notion of Left Jacobian for Lie Groups much outside of the field of Robotics - in particular when computing exponential maps. So, I'm wondering whether this is a general principal, and there is a way to generalize it to other (semi direct product) Lie groups such as SE2(2), Sim(2), Sim(3) etc., or whether it is rather a special case - for SE(3).

joansola commented 1 year ago

Hello Hauke,

I guess you checked the paper "Micro Lie theory...". There, the left Jacobian is I think well explained and justified. As per the exp map of SE(3), the appearance of this left Jacobian is purely coincidental as you say. In the paper I just introduce the matrix block V(theta), and say that it matches the left Jacobian exactly. I could have added that this is a coincidence. Indeed in SE(2) this does not apply at all.

I do not think this can be generalized in any sense. But I do believe that this or similar coincidences can appear in other groups, and would not be surprised to find it in Sim(3) for example.

strasdat commented 1 year ago

Hi Joan,

Thanks for getting back so quickly and confirming my understanding of the Left Jacobian here!

While reading about it, I have not used the concept of Left Jacobian myself much - though I do use the adjoint matrix quite a lot. Thanks, your paper describes nicely how the two concepts relate. I'm still digesting some of the details, but it seems the Left Jacobian is more general since it is with respect to a non-linear function f, while the adjoint is a merely linear mapping.

joansola commented 1 year ago

Hi Hauke,

I just love this topic :-)

A quick explanation of the notion of Left Jacobian follows.

The thing is: the terminology may be quite confusing.

First, there is the notion of "left Jacobian". It applies to any function f():G->H from group G to group H, and it is defined as the derivative when the infinitesimals, both of x and of f(x), are considered around the origin or identity (therefore composed on the left):

df(x)/dx | left = lim_(dx->0) log(f(exp (dx) * x) * f^-1(x)) / dx

Then, when you apply the left Jacobian above to the exponential map, that is when f(x) = exp(x), and x is a tangent vector of a given group G, then you get what is called the "left Jacobian of G":

Jl = dexp(x)/dx | left = lim_(x->0) log (exp(x+dx) exp^-1(x)) / dx

So, the "left Jacobian of G" is the same as, or a shortcut for, "left Jacobian of the exponential map of G".

Likewise, you define right Jacobians, where the infinitesimals are defined locally to the group elements, that is on the right. Just for completeness:

df/dx | right = lim_(dx->0) log (f^-1(x) * f ( x * exp(dx) ) ) / dx