I want to use matlab for estimating the position of end effector given joint angles. I saw convenient tool to build robot model using RigidBodyTree. My manipulator is planar, with only revolute joints with N number of joints. I want for a given manipulator (where N can be changed) to give as an input angles for manipulator's joints and to get position of the end effector.

I only found InverseKinematics which does exactly the opposite. But nothing about Forward Kinematics. How could I possibly do that in Matlab?


1 Answer 1


There is the gettransform() function for this. It gives you the transformaation matrix of the entire robot, from base to end-effector (if you inpput the paremeters accordingly).

It returns a 4x4 transformation matrix, you can convert the 3x3 rotation part of the 4x4 matrix using the dcm2angle() function to euler angles, the first three rows of the last column of the 4x4 matrix are your positions.


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.