The radial distribution function (RDF) denoted in equations by g(r) defines the probability of finding a particle at a distance r from another tagged particle. The RDF is strongly dependent on the type of matter so will vary greatly for solids, gases, and liquids. The average density at any point in a liquid is referred to as the bulk density, ρ. This density is always the same for a given liquid. The density of the liquid at a given distance of r from another molecule is referred to as the local density, ρ(r), and is dependent on the structure of the liquids.

The radial distribution function can be evaluated as follows:

 computing g(r) $g(r)={\frac {dn_{r}}{dV_{r}*\rho }}\approx {\frac {dn_{r}}{4\pi r^{2}dr*\rho }}$ where $dn_{r}$ is a function that computes the number of particles within a shell of thickness $dr$ , and $dV_{r}\approx 4\pi r^{2}dr$ is the spherical shell volume (with the approximation holding for small shell thicknesses.

The correlation function, g(r), relates the bulk density to the local density. The local density can be calculated as follows:

 Calculating local density $\rho (r)=\rho ^{bulk}g(r)$ Solids have regular, periodic structures, with molecules fluctuating near their lattice positions. The structure is very specific over a long-range, therefore it is rare to see defects in solids. Discrete peaks at values of σ, ${\sqrt {2}}$ σ, ${\sqrt {3}}$ σ, etc, can be seen in the RDF of a solid. Each peak has a broadened shape which is caused by particles vibrating around their lattice sites. There is zero probability of finding a particle in regions between these peaks as all molecules are packed regularly to fill the space most efficiently. Each peak represents a coordination shell for the solid, with the nearest neighbours being found in the first coordination shell, the second nearest neighbours being found in the second, and so on.

Gases do not have a regular structure which heavily influences their RDF. The RDF of a real gas will have only a single coordination sphere which will rapidly decay to the normal bulk density of a gas, g(r)=1. The RDF of a real gas is fairly simplistic, with values of g(r) as follows:

• $g(r)=0$  when $r<\sigma$
• $g(r)>1$  in the area where London Forces are strongest when $\sigma
• $g(r)=1$  when $r>2\sigma$

Liquids follow the hard-sphere model of repulsion indicating that there is zero density when atoms overlap. Due to their ability to move dynamically liquids do not maintain a constant structure and lose all of their long-range structure. The first coordination sphere for a liquid will occur at ~σ. At large values of r, the molecules become independent of each other, and the distribution returns to the bulk density (g(r)=1). The first peak will be the sharpest and indicates the first coordination sphere of the liquid. Subsequent peaks will occur roughly in intervals of σ but be much smaller than the first. Liquids are more loosely packed than solids and therefore do not have exact intervals. Although it is possible for there to be multiple coordination spheres, there is a depleted probability of finding particles outside the first sphere due to repulsion caused by the first sphere.

## Coordination Numbers

The coordination number indicates how many molecules are found in the range of each coordination sphere. Integrating g(r) in spherical coordinates to the first minimum of the RDF will give the coordination number of a molecule.

 Calculating the coordination number $n(r')=4\pi \rho \int _{0}^{r'}g(r)r^{2}dr$ A coordination number of 12 reflects the optimal packing of hard spheres. Due to the fact that attractive forces are weak and isotropic and that repulsive forces are very strong and short-range many molecules can be approximated as "hard spheres". This indicates that simple liquids, a liquid that does not experience hydrogen bonding or electrostatic forces, will pack in the most efficient way and will avoid repulsive interactions. The most efficient way for a fluid of spherical particles to fill a volume is to have 12 neighbors to every molecule. This explains why many simple liquids, such as argon, have a coordination number of 12.

Liquids which have hydrogen bonding and electrostatic interactions, such as water, will have a much lower coordination number (water has a coordination number of 4-5 in the first sphere). This is influenced by the fact that these more complex liquids will try to maximize their hydrogen-bonding interactions in the first sphere. Thus results in more energetic but less efficient packing. The RDF of these liquids will have a notably sharper peak for the first coordination sphere which will occur earlier than that of a simple liquid. The radial distribution functions of argon and water, calculated from molecular simulation. The argon rdf shows regular and definite coordination spheres. The water rdf is dominated by the first coordination sphere. Secondary coordination spheres are much less ordered than in simple liquids. The first coordination sphere of water indicated on the O-O rdf.