Projected dynamical systems