A system is said to exist in a state of thermodynamic equilibrium when no change in any macroscopic property is registered if the system is isolated from its surroundings.
An isolated system always reaches a state of thermodynamic equilibrium in course of time and can never depart from it spontaneously. Therefore there can be no spontaneous change in any macroscopic property if the system exists in an equilibrium state.
A system will be in a state of thermodynamic equilibrium, if the conditions for the following three types of equilibrium are satisfied-
When the conditions for any one of the three types of equilibrium are not satisfied a system is said to be in a non-equilibrium state and cannot be described by thermodynamic properties which represent the system as a whole.
A system is said to be in mechanical equilibrium when there are no unbalanced forces within the system and that the system is in force-balance with its surroundings. If an unbalanced force exists, either the system alone or the system and the surroundings both undergo changes until mechanical equilibrium is reached.
A system is said to be in chemical equilibrium if it experiences no change in either its chemical composition or aggregation with time.
When a system existing in mechanical and chemical equilibrium is separated from its surroundings by a diathermic wall (which allows heat to flow but not work) and if there is no spontaneous change in any property of the system the system is said to exist in a state of thermal equilibrium. When this is not satisfied the system will undergo a change of state till thermal equilibrium is restored.