Shamelessly ripping from Tom Moore's answer to the same question some years back (https://answers.ros.org/question/192273/how-to-implement-velocity-transformation/).
To add on more concisely, a velocity vector is just a vector like any other quantity. You can transform vectors from one frame to another through some simple matrix multiplication that TF (TF2) will take care of for you.
See TF2 docs for specifics http://docs.ros.org/melodic/api/tf2/html/
Originally posted by stevemacenski with karma: 8272 on 2019-08-19
This answer was ACCEPTED on the original site
Post score: 1
Original comments
Comment by rayane on 2019-08-20:
Thank you for your answer. As far as I understood, the velocity vector transformation depends only on the rotational matrix!! but I found that: if we have a transformation matrix that transforms Frame_2 (F2) to Frame_1(F1) given by: T= [R T ; 0 0 0 1] where R is the rotational matrix and T is the translational matrix then a vector V2 with coordinates in F2 is expressed in F1 by : V1 = [R ass(T)*R ; 0(3x3) R] V2 where ass is the skew symetric matrix.
so from this we notice that the first three components of the velocity which is the linear one depend on the translational vector T !!Is what I was saying wrong!!!
another question: If I am to use tf TransformListene. the methode transformVectortakes three arguments: target_frame: I guess is the frame where we want the coordinates to be expressed. butwhat are
stamped_in and stamped_out.
thanks in advance