Maximum entropy principle and hydrodynamic models in statistical mechanics