Energy Criterion for Lyapunov Stability