  This chapter reviews the basic physics and thermodynamics that govern
magnetocaloric materials. The thermodynamics of magnetic materials is discussed
by introducing relevant free energy terms together with their microscopic
origin leading to a discussion of the sources of entropy that can change in an
applied magnetic field. Such entropies account for measurable magnetocaloric
effects, especially in the vicinity of magnetic phase transitions. Particular
attention is devoted to first order magnetic transitions that involve the
coupling of spin, lattice, electronic and anisotropic magneto-crystalline
degrees of freedom. The problem of irreversibility and hysteresis, present in
magnetocaloric materials with first order phase transitions is discussed in the
context of out-of-equilibrium thermodynamics and hysteresis modeling.
