The canonical ensemble in statistical mechanics is characteristic of thermodynamic systems under constant temperature in which there is an accompanying change in the energy of the system. The system in canonical ensemble is in thermal equilibrium state with a heat reservoir, so that there can be energy transfer between the two systems. As a result, the probability for this system is proportional to a factor which includes the energy variable. This factor is called Boltzamn factor and has the following form;
The probability of finding the system in a state of energy E is proportional to the Boltzman factor. So we can write:
Probabibilty density = a*exp (-E/kT) where a is the proportionality constant.
Summing both sides of the equation gives
1 = Sum (a*exp (-E/kT))
The one arises due to the fact that the total probability is one. Dividing by the sum gives:
a = 1 / sum (exp (-E/kT))
This factor is called the partition function and is typical of the canonical ensemble. Therefore, the average value of the energy is equal to:
Average (E) = sum(Ei*exp (-E/kT)) / sum (exp (-E/kT)) = -dlnZ/dbeta
Where beta = 1/kT and Z is the partition function in the canonical ensemble.
The Boltzman distribution of the canonical ensemble is itself derived from a more general ensemble which is called the micro-canonical ensemble which depicts adiabatic systems in which the system is isolated and there is no energy exchange of the system with the surroundings.
In the micro-canonical ensemble there is permission for temperature change but not for energy change. Therefore, calculations in the canonical ensemble usually involve constant temperature where;
beta= 1/ kT where T is the temperaure and k is boltzman constant.
In the micro-canonical ensemble
Beta= 1/k*(dS/dE) for a paramagnet. where S is the entropy and E is the energy.
For the similarities between the two ensembles, in the canonical ensemble the controlled variables of a paramagnet are T, N, H where T is the temperature and N is the number of particles and H is the magnetic field. In the micro-canonical ensemble the controlled variables are E, N, H where E is the energy and N is the number of particles and H is the magnetic field.
For a micro-canonical ensemble the states have similar energies. All these states have the same probability. In the canonical ensemble the system can exchange energy with the surrounding but it is in thermal equilibrium with the heat reservoir. Therefore, it has a distinct defined average energy. The amount of energy that is exchanged with the heat reservoir is less than the average energy of the system. By finding the work of the system which is volume work and summing E and W we can get the entropy of the system.