The Principles of Thermodynamics