Theory and problems of thermodynamics