{\dfrac{\partial L}{\partial x_i}-\dfrac{d}{dt}\dfrac{\partial L}{\partial \dot{x}_i}=0 \Rightarrow m\ddot{x}+kx=0 \Rightarrow m\ddot{x}=-kx}