The major issues in the analysis of the motion of a constrained dynamic system are to determine this motion and calculate constraint forces. In the analytical mechanics, only the first of the two problems is analysed. Here, the problem is solved simultaneously using: 1) Principle of liberation of constraints; 2) Principle of generalized virtual displacement; 3) Idea of ideal constraints; 4) Concept of generalized and ``supplementary" generalized coordinates. The Lagrange-D'Alembert principle of virtual work is generalized introducing virtual displacement as vectorial sum of the classical virtual displacement and virtual displacement in the ``supplementary" directions. From such principle of virtual work we derived Lagrange equations of the second kind and equations of dynamical equilibrium in the ``supplementary" directions. Constrained forces are calculated from the equations of dynamic equilibrium. At the same time, this principle can be used for consideration of equilibrium of system of material particles. This principle simultaneously gives the connection between applied forces at equilibrium state and the constrained forces. Finally, the principle is applied to a few particular problems.