Thermodynamics and ice melt flows