Algorithmic approach to coordinate transformation for robotic manipulators