Suppose a point mass $m$ is attached to one end of a spring of spring constant $k$. The other end of the spring is fixed on a massless cart that is being moved uniformly on a horizontal plane by an external device with speed $v_{0}$. If the position $q$ of the mass in the stationary system is taken as the generalized coordinate, then the Lagrangian of the system is
1. $\frac{m}{2} \dot{q}^{2}-\frac{k}{2}\left(q-v_{0} t\right)$
2. $\frac{m}{2} \dot{q}^{2}-\frac{k}{2}\left(q-v_{0} t\right)^{2}$
3. $\frac{m}{2} \dot{q}^{2}+\frac{k}{2}\left(q-v_{0} t\right)$
4. $\frac{m}{2} \dot{q}^{2}+\frac{k}{2}\left(q-v_{0} t\right)^{2}$