2.1: Microcanonical and Canonical Ensembles

Chem 371: P-Chem 2 to Folow Combined Biophysical and P-Chem 1 · LibreTexts

0%

Contents

    Text

    Size
    100%
    Theme
    Typeface
    Line length
    Spacing

    From LibreTexts, under CC BY-NC-SA 4.0, as the source states it; its equations are written in TeX, which the PDF shows typeset. This page at LibreTexts.

    2.1: Microcanonical and Canonical Ensembles

    Introduction

    Statistical thermodynamics (statistical mechanics) is our connection between the microscopic behavior and properties of matter and macroscopic thermodynamic behavior. Statistical thermodynamics involves calculating weighted averages of the microscopic behavior of the constituents of the system of interest to arrive at the macroscopic properties of the system. To do these calculations we must decide which parameters we will allow to vary and which will be held constant. We will use statistical concepts to average over the quantities that can vary. In the language of statistical mechanics this means choosing which ensemble to work with. There are many, but we will consider only two.

    Definition of an ensemble

    An ensemble is an imaginary replication of the system of interest so that every possible arrangement of the quantities that can vary exist in one of the replications. As an example consider a system consisting of three quantum mechanical particles (A, B and C) each with a ground state and two equally spaced excited state in an isolated system (fixed volume and insulated from the surroundings). If the system contains enough energy for three quanta of excitation we can identify all the different arrangements of energy that use all of it. They are shown below using * to indicate a quantum of excitation:

    A*  B*  C* A**  B  C* A**  B*  C
      A  B**  C* A*  B**  C
      A  B*  C** A*  B  C**

    There is only one real system, which would be found in one of these seven arrangements, but each one of the possible arrangements is part of the imaginary ensemble representing the system. Another name for an arrangement is a microstate.

    When building an ensemble, we will make the a priori (before hand) assumption that any microstate that satisfies our constraints is equally likely. This means that if we take many measurements of the distribution of the quanta we will get each of the microstates 1/7 of the time.

    Microcanonical ensemble and a statistical definition of entropy

    The example ensemble above is a very small microcanonical ensemble, which are isolated systems with the total energy of the system (E), volume (V) and number of particles (N) held constant. In the above example we said nothing about the volume, but because the particles are isolated from the rest of the universe they must be contained is some isolated volume.

    Notice that six of the arrangements have one doubly excited molecule, one singly excited molecule and one unexcited (ground state) molecule. If the molecules are indistinguishable any one of these microstates is equivalent (the same configuration or macrostate).  This means one doubly excited, one singly excited and one unexcited molecule is the most likely configuration for us to measure (6/7 of the time). Enumeration is the hard way to find the most likely distribution. This is equivalent to the statistical problem of distributing objects among bins, which has a well known solution. From statistics if ni objects are in bin i and there are N total objects and k bins (meaning i = 0, 1, 2, ... k-1) the weight (W) is the number of ways of distributing those particles in groups of ni into the k bins:

    \[W = \frac{N!}{n_1!n_2!,…}.\label{EQ:statweight}\]

    Think of the energy levels (0, 1 or 2 quanta) as the bins. In the first case all the particles are in the 1 quanta of excitation bin: n1 = 3 and n0 = n2 = 0. This yields:

    \[W_1 = \frac{3!}{3!0!0!} = \frac{3\cdot 2\cdot 1}{3\cdot 2\cdot 1\cdot 1\cdot 1} = 1. \nonumber\]

    In the second case 1 particle is in the 0 state, one in the 1 state and one in the 2 state:

    \[W_2 = \frac{3!}{1!1!1!} = \frac{3\cdot 2\cdot 1}{1\cdot 1\cdot 1} = 6. \nonumber\]

    Because we have only two excited states there are no more bins and thus no other configurations. The total number of microstates is just the sums of all the weights (W1 + W2 = 7).

    Entropy is a measure of disorder. A higher weighting for a configuration corresponds to more ways of getting the configuration and therefore more disorder. Thus, we would expect a larger W to indicate higher entropy. The other property that entropy must have is that it is additive. If we have two systems with entropies SA and SB the total entropy Stot = SA + SB. But the total number of configurations we can make with two systems with WA and WB is Wtot = WAWB. Thus we need a definition in terms of weights that is additive, but also consistent with the fact that the weight of a combined system should be the product of the weights of the individual systems.

    Example \(\PageIndex{1}\): Number of microstates of a larger system made of two isolated systems

    Show that the number of microstates available goes as the product of the number of microstates when a new system is constructed of two isolated systems each in a configuration with W = 2.

    Solution

    Call the microstates in system 1 A and B and in system 2 C and D. The combinations we can make are: AC, AD, BC and BD for a total of 4 distinct microstates = 2x2 = W1W2.

     The solution is to utilize the properties of logs. In particular ln(ab) = ln(a) + ln(b). We will define the statistical entropy of a particular configuration as Si = kBlnWi, where kB = Boltzmann constant. This means that SA + SB = kBln(WA) + kBln(WB) = kBln(WAWB), satisfying both the statistical and thermodynamic requirements for an entropy.

    Thus for a microcanonical ensemble the entropy is:

    \[S = k_BlnW = k_B ln \left(\frac{N!}{\prod_i{n_i !}}\right) =  k_B \left(ln N!- \sum_i{ln(n_i!)}\right).\label{microcan_S}\]

    Real systems have huge numbers of particles making the factorials impractical. Luckily, there is a very good approximation \(\ln x! \approx x\ln x – x \) called Stirling's approximation, which has very small fractional errors for large x. Applying this we can rewrite equation \(\ref{microcan_S}\) as:

    \[S = k_B \left(NlnN-N- \sum_i({n_i ln(n_i) -n_i})\right).\label{microcan_S_approx}\]

    Since \(\sum_i{n_i} = N\) this simplifies further to:

    \[S = k_B \left(NlnN-\sum_i{n_i ln(n_i)}\right) =  k_B \left(\sum_i{n_i lnN} -\sum_i{n_i ln(n_i)}\right)= k_B \left(\sum_i{n_i lnN -n_i ln(n_i)}\right) 
    \\=k_B \left(\sum_i{n_i ln\left(\frac{N}{n_i}\right)}\right)  = -k_B \left(\sum_i{n_i ln\left(\frac{n_i}{N}\right)}\right) = -Nk_B \left(\sum_i{\frac{n_i}{N} ln\left(\frac{n_i}{N}\right)}\right).\label{microcan_S_prob_form}\]

    Notice that the fractions \(\frac{n_i}{N}\) is the fraction of the total molecules that will be found in the energy level i. Although nice and compact this is still not a very practical way of calculating the entropy if N and thus i are large. The traditional approach is to apply the method of Lagrange multipliers to constrain the energy to our fixed value and maximize the number of microstates. Instead we will develop more generally useful expressions by working with the canonical ensemble.

    Canonical ensemble1

    This ensemble is used for constant temperature systems. The volume (V), number particles (N) and temperature (T) of the system are constant. This is a chemically useful way to describe a system. In most cases chemical systems consist of a container in equilibrium with the surroundings, which have a particular temperature. At any given time the system can exchange energy with the surroundings as long as the temperature of the system remains in equilibrium with the surroundings. This is less constrained than the microcanonical ensemble where the system has a fixed total energy. By using the canonical ensemble we will be able to use the thermodynamic definition of temperature to get a very general expression for the entropy of the system. From there we will be able to go on to derive general statistical expressions for other thermodynamic quantities.

    Our discussion begins by applying the idea of the weight of our configurations in a more general way. The trick is to express this weight in terms of the surroundings, which are so much larger than the system that we can use an approximate Taylor series expansion to express the entropy without significant error.

    For this system in contact with the surroundings, which is part of the Universe, the total energy is fixed at ET = Esur + Esys. We will refer to a particular energy configuration of the system as Ei. Thus for a particular Ei Esur = ET - Ei.

    Start by considering the canonical equivalent of the microcanonical ratio \(\frac{n_i}{N}\), which we will call \(P(i)\):

    \[P(i) = \frac{\text{number of ways of getting the system with energy }E_i}{\text{all ways of arranging}E_T} = \frac{W_{sur}(E_{sur})}{W_T (E_T)}\label{Pi1}\]

    To convert this to a more useful general expression we need to express the entropy of the surroundings in terms of the total energy, ET, and the energy of the system, Ei. Then we will use that to express P(i) in terms of Ei. 

    The entropy of the surroundings

    From the Boltzmann definition of entropy we have:

    \[S_{sur} = k_B ln W_{sur}(E_{sur}).\nonumber\]

    Now consider expanding Ssur in a Taylor series about ET.

    \[S_{sur}(E_{sur}) \approx S_{sur}(E_T) + \left(\frac{\partial S_{sur}}{\partial E_{sur}}\right)_{V,N}\vert_{E_T}(E_T-E_{sur})\label{S_taylor}\]

     This is approximate because we have only kept the first term of the Taylor series. However,  Esur =ET - Ei and Ei << ET so the error from dropping higher order terms will be negligible.

    We can re-express the derivative in terms of the system energy, Ei, using the fact that ET is a constant and Esur =ET - Ei. This implies the differential 

    dEsur = d(ET - dEi) = 0 - dEi.

    We also need to convert dSsur to a differential in terms of the system. First write it as the differential of the Boltzmann entropy:

    \[dS_{sur} = d(k_BlnW_{sur}(E_{sur}))\nonumber\]

    The Wsur can be replaced by using the fact that weights multiply. Thus WT(ET) = Wsur(Esur)Wi(Ei) => Wsur(Esur) = WT(ET)/Wi(Ei). Substituting this in:

    \[dS_{sur} = d\left(k_Bln\left(\frac{W_T(E_T)}{W_i(E_i)}\right) \right)= d\left(k_BlnW_T(E_T) -k_B lnW_i(E_i) \right) = 0 -d(k_B lnW_i(E_i) )=-dS_i.\nonumber\]

    Substituting the differentials and Esur =ET - Ei into equation \(\ref{S_taylor}\):

    \[S_{sur}(E_T - E_i) \approx S_{sur}(E_T) + \left(\frac{\partial S_i}{\partial E_i}\right)_{V,N}\vert_{E_T}(E_T-(E_T - E_i))\nonumber\]

    From thermodynamics we know that \(\left(\frac{\partial U}{\partial S}\right)_{V,N} = T\). The energy Ei  = Ui - Ui(0), where Ui(0) is the constant internal energy of the system that it has at absolute 0. Thus \(\left(\frac{\partial E_i}{\partial S_i}\right)_{V,N}=\left(\frac{\partial U}{\partial S}\right)_{V,N} = T\). Replacing the derivative with 1/T our expression for \(S_{sur}(E_T - E_i)\) can be further simplified to:

    \[S_{sur}(E_T - E_i) \approx S_{sur}(E_T)  - \frac{E_i}{T}\label{S_sur}\]

    P(i) in a generally useful form

    Our goal is to find a general form of P(i) (equation \(\ref{Pi1}\)) that we can use to calculate system thermodynamic quantities. We start by assuming that our approximation in calculating Ssur(ET - Ei) is accurate so we have:

    \[S_{sur}(E_T - E_i) = S_{sur}(E_T)  - \frac{E_i}{T} \implies k_B ln W_{sur}(E_{sur}) = k_B lnW_{sur}(E_T) - \frac{E_i}{T} \\
    \implies k_B ln\left(\frac{W_{sur}(E_{sur})}{W_{sur}(E_T)}\right) =  - \frac{E_i}{T}
    \implies \frac{W_{sur}(E_{sur})}{W_{sur}(E_T)} = exp\left( - \frac{E_i}{k_B T}\right)
    \implies W_{sur}(E_{sur}) = W_{sur}(E_T) exp\left( - \frac{E_i}{k_B T}\right). \nonumber\]

    We can substitute this into our original expression for P(i) (equation \(\ref{Pi1}\)) to get:

    \[P(i) =\frac{W_{sur}(E_{sur})}{W_T (E_T)} = \frac{W_{sur}(E_T) }{W_T (E_T)}exp\left( - \frac{E_i}{k_B T}\right)\label{Pi2}\]

    As P(i) is a probability it must be normalized. So,

    \[\sum_{i=1}^{\infty}{P(i)} = \sum_{i=1}^{\infty}{\frac{W_{sur}(E_T) }{W_T (E_T)}exp\left( - \frac{E_i}{k_B T}\right) }= 1.\label{Pi3}\]

    Because ET is a constant the fraction of weights on the right hand side can be removed from the sum:

    \[\frac{W_{sur}(E_T) }{W_T (E_T)}\sum_{i=1}^{\infty}exp\left( - \frac{E_i}{k_B T}\right) = 1\implies  \frac{W_{sur}(E_T) }{W_T (E_T)}= \frac{1}{ \sum_{i=1}^{\infty}exp\left( - \frac{E_i}{k_B T}\right)}.\]

    Substituting this final result into P(i) yields:

    \[P(i) = \frac{W_{sur}(E_T) }{W_T (E_T)} exp\left( - \frac{E_i}{k_B T}\right) = \frac{exp\left( - \frac{E_i}{k_B T}\right)}{\sum_{i=1}^{\infty}exp\left( - \frac{E_i}{k_B T}\right)}\label{Pi5}\]

    This is entirely in terms of the energy of the configuration i. The sum on the bottom is referred to as Q(T), the canonical partition function. It is the normalization constant. The larger Q(T) the more energy states are accessible. Q(T) is the key parameter necessary to calculate thermodynamic quantities. You may also notice that P(i) looks like the Boltzmann energy distribution. This is the more general canonical probability distribution.

    References

    1. This discussion is based on Section 2.4 of A. Cooksy Physical Chemistry: Thermodynamics (Pearson Education, Inc. Columbus, OH, 2014). 


    This page titled 2.1: Microcanonical and Canonical Ensembles was last modified on Tue, 16 Sep 2025 12:45:13 GMT and is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by Jonathan Gutow.