The tracking and regulation problem for a class of generalized systems