Introduction to Boltzmann Statistics
The canonical ensemble is a probability space which models physical systems at a fixed temperature, but for which the energy can vary.
In this situation we imagine that our system, described by states $(\Omega, \mathcal H, \lambda)$, is allowed to exchange energy with some other system usually referred to as a heat bath. The internal structure of the heat bath is unknown to us (it may be the rest of the universe), but there is some constant $\beta > 0$ that explains how easily energy can transfer between it and our system. This constant has physical significance and in physical situations it often appears as $\beta = (k T)^{-1}$ where $T \geq 0$ is temperature and $k$ is Boltzmann’s constant (which makes $\beta$ a dimensionless number).
We now consider the energy of our system as variable (that is the system may transition between states in different $L_u$) with $\beta$ a constant whose intuition should agree with inverse temperature. Once we know the energy $u$ we know the probability measure on $L_u$, it remains to understand the distribution of energies—a question that was completely irrelevant in the microcanonical ensemble.
Definition: The canonical ensemble on $(\Omega, \mathcal H)$ is the probability measure $P$ given by $$\frac{d P}{d \lambda}(\omega) = \frac{1}{Z} e^{-\beta E(\omega)} \qquad Z = \int_{\Omega} e^{-\beta E(\omega)} d\lambda(\omega) .$$ $Z$ is called the partition function, $e^{-\beta E(\omega)}$ the Boltzmann factor, and $f(\omega) := \frac{1}{Z} e^{-\beta E(\omega)}$ the density of states.
The interesting thing here is that higher energies are exponentially less likely, and we see how $\beta$ acts to govern the rate of exchange of energy between our system and the heat bath.
The partition function is named that because it is a function of $\beta$ (and in particle systems $V$ and $N$) and has significance beyond just normalizing the Boltzmann factor to arrive at the density of states. We will focus considerable energy looking at the partition function and its relatives.
Particle Models
In the situation of $N$ particles in $(V, \mathcal H, \lambda)$ the state space is given by $(V^N, \mathcal H^{\otimes N}, \lambda^N)$. The density of states and partition function are then given by $$f(\mathbf x) = \frac{e^{-\beta E(\mathbf x)}}{Z}; \qquad Z = \int_{V^N} e^{-\beta E(\mathbf x)} \, d\lambda^N(\mathbf x).$$
In many particle models, the particles are indistinguishable. In these situations, when $\mathbf x$ and $\mathbf x’$ are states whose coordinates are permutations of the other, the state of the system is indistinguishable to an observer. If we want to represent states uniquely we can define the state space to be orbits of $\mathbf x$ under the action of the symmetric group.
When $V$ is a subset of $\mathbb R$ (or other ordered set) then we can find a representative for each orbit in the principal chamber in $V^N$, $$V^{\wedge N} := \{ \mathbf x \in V^N : x_1 \leq x_2 \leq \cdots \leq x_N \}.$$ The other chambers are the images under the action of $S_N$, and the boundary of the chambers consist of states where two or more particles are colocated. The density of states and partition function when representing states in the principal chamber are given by $$\widetilde f(\mathbf x) := \frac{e^{-\beta E(\mathbf x)}}{\widetilde Z}; \qquad \widetilde Z = \int_{V^{\wedge N}} e^{-\beta E(\mathbf x)} \, d\lambda^N(\mathbf x).$$ $\widetilde Z$ and $Z$ only differ by a factor of $N!$ (which cancels in the density of states). Thus it is sometimes useful to use $\widetilde f$ on the principal chamber and other times it is useful to use $f$ on all of $V^N$, but note that it is invariant under the action of $S_N$. $f = N! \widetilde f$ . This $N!$ becomes relevant when we allow the number of particles to vary—a situation where it is important to have unique representatives for states. More about that later.
One implication of the Pauli Exclusion Principal is that no two fermions can be located at the same point in space. In this situation we must almost never observe a state $\mathbf x$ with $x_n = x_m$ (that is the probability is equal to zero). If the density of states $f$ is continuous then it must vanish on all chamber boundaries $\{\mathbf x : x_n = x_m \mbox{ for some } n \neq m \}.$
Notation
It is useful to explicitly denote the dependence of certain quantities like energy, and the partition function on the parameters $\beta, N, V$ etc. We do this with subscripts when appropriate, or we list relevant parameters in parenthesis. Thus the partition function $Z$ in the last section might be written variously as $Z_N, Z_N(\beta), Z_N(V, \beta), Z(N, V, \beta), Z(N, \beta)$ etc. depending on which variables/parameters are most relevant to the discussion. The density of states can likewise be written as $f_N, f_N(\beta, \mathbf x), f(N, \beta, \mathbf x),$ etc.