Temperature is defined in thermodynamics as the partial derivative of the internal energy U with respect to entropy S, at constant volume V:
T = (∂U/∂S)_V
The internal energy is the sum of the total kinetic energy of the atoms in the gas, as well as the potential energy due to the interaction...