Marginal stability
In the theory of dynamical systems, and control theory, a continuous linear time-invariant system is marginally stable if and only if the real part of every pole in the system's transfer-function is non-positive, and all poles with zero real value are simple roots (i.e. the poles on the imaginary axis are all distinct from one another). If all the poles have strictly negative real parts, the system is instead asymptotically stable.
A discrete linear time-invariant system is marginally stable if and only if the transfer function's spectral radius is 1. That is, the greatest magnitude of any of the poles of the transfer function is 1. The values of the poles must also be distinct. If the spectral radius is less than 1, the system is instead asymptotically stable.
Practical consequences
A marginally stable system is one that, if given an impulse of finite magnitude as input, will not "blow up" and give an unbounded output. However, oscillations in the output will persist indefinitely, and so there will, in general, be no final steady-state output. If the system is given an input at a pole frequency, the system's output will increase indefinitely.
A system having imaginary poles, i.e. having zero real part in the pole(s), will produce sustained oscillations in the output. For example, an undamped second order system such as the suspension system in an automobile (mass-spring-damper), from where damper has been removed and spring is ideal i.e. no friction is there, will in theory oscillate forever once disturbed. A system with a pole at the origin is also marginally stable but in this case there will be no oscillation in the response as the imaginary part is also zero (jw = 0 means w = 0 rad/sec).