General theory of dynamical systems