We develop a method for generating smooth trajectories for a set of mobile robots. Given two end configurations, by tuning one parameter, the user can choose an interpolating trajectory from a continuum of curves varying from that corresponding to maintaining a rigid formation to motion of the robots toward each other. The idea behind our method is to change the original constant kinetic energy metric in the configuration space and can be summarized into three steps. First, the energy of the motion as a rigid structure is decoupled from the energy of motion along directions that violate the rigid constraints. Second, the metric is “shaped” by assigning different weights to each term, and, third, geodesic flow is constructed for the modified metric. The optimal motions generated on the manifolds of rigid body displacements in 3-D space (Ë ´¿µ) or in plane (Ë ´¾µ) and the uniform rectilinear motion of each robot corresponding to a totally uncorrelated approach are partic...