density function defined over the system's phase space. The phase space has generalized coordinates called , and associated canonical momenta called . The probability density function for the microcanonical ensemble is: where is the total energy (Hamiltonian) of the system, a function of the phase , is an arbitrary but predetermined constant with the units of , setting the extent of one microstate and providing correct dimensions to . is an overcounting correction factor, often used for particle systems where identical particles are able to change place with each other. Again, the value of is determined by demanding that is a normalized probability density function: This integral is taken over the entire phase space. The state volume function (used to calculate entropy) is defined by As the energy width is taken to zero, the value of decreases in proportion to as . Based on the above definition, the microcanonical ensemble can be visualized as an infinitesimally thin shell in phase space, centered on a constant-energy surface. Although the microcanonical ensemble is confined to this surface, it is not necessarily uniformly distributed over that surface: if the gradient of energy in phase space varies, then the microcanonical ensemble is "thicker" (more concentrated) in some parts of the surface than others. This feature is an unavoidable consequence of requiring that the microcanonical ensemble is a steady-state ensemble. Examples Ideal gas The fundamental quantity in the microcanonical ensemble is , which is equal to the phase space volume compatible with given . From , all thermodynamic quantities can be calculated. For an ideal gas, the energy is independent of the particle positions, which therefore contribute a factor of to . The momenta, by contrast, are constrained to a -dimensional (hyper-)spherical shell of radius ; their contribution is equal to the surface volume of this shell. The resulting expression for is: where is the gamma function, and the factor has been included to account for the indistinguishability of particles (see Gibbs paradox). In the large limit, the Boltzmann entropy is This is also known as the Sackur–Tetrode equation. The temperature is given by which agrees with analogous result from the kinetic theory of gases. Calculating the pressure gives the ideal gas law: Finally, the chemical potential is Ideal gas in a uniform gravitational field The microcanonical phase volume can also be calculated explicitly for an ideal gas in a uniform gravitational field. The results