Lyapunov function as potential function: A dynamical equivalence