Coordination of multi-agent leader-follower system with time-varying objective function