An explanation of the mechanism of irreversible dynamics in systems with mixing is offered. The procedure of splitting a system into subsystems in equilibrium and studying the dynamics of one of them as it interacts with the other subsystems is the basis of the approach to the analysis of nonequilibrium systems. The problem of "coarse-grain" dynamics is used. The "coarse-grain" problem on the phase space is eliminated with this method. The formula, that expresses the entropy through the work of forces between systems, is submitted. The essential link between thermodynamics and classical mechanics was found.