Random walks and diffusion

Reference: Daniel V. Schroeder, An Introduction to Thermal Physics, (Addison-Wesley, 2000) – Problem 2.25.

A random walk is a model used in statistical physics (and mathematics) to simulate systems that take seemingly random steps in various directions. The simpliest random walk occurs in one dimension and starts with the object at the origin. At each time interval, a step is taken either to the left or to the right. In the simplest case, the steps are all the same size and the probabilities of going left or right are equal to {\frac{1}{2}}.

This system is mathematically identical to a coin flipping experiment, with a step to the right being equivalent to getting a head and to the left, a tail. As such, the the number of possible step sequences in a random walk of {N} steps is {2^{N}} and the probability of ending up {n} steps from the origin, where {-N\le n\le+N} is therefore

\displaystyle  p\left(n\right)=\frac{1}{2^{N}}\frac{N!}{n!\left(N-n\right)!} \ \ \ \ \ (1)

The most probable outcome is, as usual, an equal number of steps to the left and to the right, so that it is most probable that the walk will end at its starting point (assuming an even number of steps). However, it’s also reasonably probable that you’ll end up a few steps to either side of the origin, since the probability curve can be approximated by a Gaussian around its peak. The number of microstates near the peak is given approximately by

\displaystyle  \Omega\left(x\right)\approx2^{N}e^{-2x^{2}/N} \ \ \ \ \ (2)

where {x\equiv\frac{N}{2}-n} is the number of steps away from the origin after {N} steps in total.

A commonly used measure of the width (well, half the width) of the peak is the value of {x} for which {\Omega\left(x_{width}\right)=\Omega_{max}/e} which is

\displaystyle  x_{width}=\sqrt{\frac{N}{2}} \ \ \ \ \ (3)

Thus if we ended up {\sqrt{N/2}} steps away from the starting point, we shouldn’t be very surprised. For a random walk of {10^{4}} steps, we could therefore end up somewhere in the region {-70\le x\le+70}.

One application of a random walk is to the process of diffusion in an ideal gas. Using the same model as earlier, we take the mean free path {\ell} of a gas molecule of radius {r} to be

\displaystyle  \ell=\frac{1}{4\pi r^{2}}\frac{V}{N_{mol}} \ \ \ \ \ (4)

where now {N_{mol}} refers to the number of gas molecules in a volume {V} (be careful not to get this confused with the number {N} of steps in the random walk!). The average speed of a molecule is taken to be approximately the same as the root-mean-square speed obtained from kinetic theory, and is

\displaystyle  \bar{v}=\sqrt{\frac{3kT}{m}} \ \ \ \ \ (5)

where {T} is the temperature and {m} is the mass of one gas molecule. Typical values for air at room temperature and standard pressure are

\displaystyle   \ell \displaystyle  = \displaystyle  1.5\times10^{-7}\mbox{ m}\ \ \ \ \ (6)
\displaystyle  \bar{v} \displaystyle  = \displaystyle  500\mbox{ m s}^{-1} \ \ \ \ \ (7)

To model diffusion as a random walk, we can estimate the number of steps in a time {t} as the number of collisions, which is, on average,

\displaystyle  N=\frac{\bar{v}t}{\ell} \ \ \ \ \ (8)

Using the width of the multiplicity curve 3 a reasonable distance for a gas molecule to diffuse is therefore (where each step has length {\ell}):

\displaystyle  d\approx x_{width}\ell=\sqrt{\frac{\bar{v}t}{2\ell}}\ell=\sqrt{\frac{1}{2}\bar{v}\ell t} \ \ \ \ \ (9)

With the values above and taking {t=1\mbox{ s}}, the distance diffused is around

\displaystyle  d\approx\sqrt{\frac{500\times1.5\times10^{-7}}{2}}\approx6\mbox{ mm} \ \ \ \ \ (10)

It’s interesting to note that this is exactly the same estimate for the diffusion distance that we got when we calculated a rough estimate for the diffusion constant {D} and applied this to an example of a molecule diffusing through air. In that calculation, we found that

\displaystyle   D \displaystyle  \approx \displaystyle  \frac{1}{2}\ell\bar{v}\ \ \ \ \ (11)
\displaystyle  \left(\Delta x\right)^{2} \displaystyle  \approx \displaystyle  D\Delta t \ \ \ \ \ (12)

It’s also worth noting that although a gas molecule diffuses 6 mm in 1 second, this doesn’t mean that the molecule is travelling at a constant speed of 6 mm per second as it diffuses. The distance diffused depends on the square root of the time, so the diffusion speed declines over time. As we saw earlier, it takes around 4 months for a gas molecule to diffuse the length of a 10 m room which is much slower than 6 mm per second.

If we increased the temperature, holding everything else constant, then from 5, the speed increases while the mean free path {\ell} stays the same, so the number of steps in a given time increases, which means that the molecule would diffuse a bit further. However, we see from 9 that {d} depends on {\sqrt{\bar{v}}}, and hence on {T^{1/4}}, so an increase in temperature wouldn’t increase the distance diffused by all that much.

Leave a Reply

Your email address will not be published. Required fields are marked *