If I have a state-space model, so that matrices $A$, $B$, $C$ and $D$ are known, how can I design the right input $u$, so that $y$ is a desired signal, say, a sine wave with constant amplitude?
$$\begin{aligned} \dot{x} &= A x + B u \\ y &= C x + D u \end{aligned}$$