Modeling the Spatial Dynamics of Robotic Manipulators with Flexible Links and Joint Clearances