random-walk-is-binomial

Fri Jul 03 2026

The Problem

A particle starts at 0 on the number line and takes nn steps. Each step is +1+1 or 1-1 with equal probability. After nn steps, what is the distribution of its position?

I worked it out by hand for the first few nn. Some things jumped out of those PX1,PX2,PX3P_{X_1}, P_{X_2}, P_{X_3} tables:

  • After 1 step it sits on ±1\pm 1. After 2 steps, only even positions. After 3 steps, only odd positions. The reachable set flips parity with nn.
  • Each distribution is symmetric about 0, with the most mass near 0 and less toward the edges.
  • It looked like a bell, or like the triangle you get from summing two dice, which peaks at 7.

bh-ch3-random-walk-pmf

What I could not do was jump to general nn. Redoing the tree for every nn is hopeless. I needed the position's PMF as a formula, and I did not see how to get there.

Where I Got Stuck

Those tables were positions: X1X_1 the position after one step, X2X_2 after two, X3X_3 after three. I was treating each one as a random variable whose distribution I did not know, and grinding it out by hand with a tree. The instinct was to keep going the same way for general nn: build XnX_n's table too, so Y=XnY = X_n.

That is the trap. Each new step splits every position into two, so the tree doubles and after nn steps the bookkeeping explodes. Redoing it for every nn is hopeless, and it hands me no formula for P(Xn=y)P(X_n = y). I was trying to compute the position's distribution in one piece, directly, instead of building it from simpler pieces I already understood.

The Reframe: Count Rights, Not the Running Sum

The way out is to build the position from simple pieces instead of computing it whole. Let XiX_i be the ii-th step, +1+1 for a right and 1-1 for a left (reusing XiX_i, now for the step itself rather than the running position). Each step is a trivial fair two-outcome trial, and the position is just their sum:

Y=X1+X2++Xn,Xi{1,+1}.Y = X_1 + X_2 + \dots + X_n, \qquad X_i \in \{-1, +1\}.

This is the reframe. Adding up nn independent identical fair steps builds a Binomial, so YY is a Binomial in disguise and I never have to grind out its distribution by hand: I know one step, and YY is nn of them summed. Whether I write a step as right or left, +1+1 or 1-1, or a 0/10/1 indicator, is just notation for the same coin. What is left is bookkeeping to pin down exactly which Binomial.

That bookkeeping is cleanest if you stop tracking the running sum and count the two kinds of step instead. Let RR be the number of right steps and LL the number of left steps. Two facts then pin down everything:

n=R+L,Y=RL.n = R + L, \qquad Y = R - L.

The first says every step is either a right or a left. The second is the position, since each right adds 1 and each left subtracts 1.

Now RR is easy to name. Over nn independent steps, each going right with probability 1/21/2, RR is a count of successes in nn fair trials. So RBin(n,1/2)R \sim \text{Bin}(n, 1/2) and

P(R=r)=(nr)(12)r(12)nr=(nr)12n.P(R = r) = \binom{n}{r} \left(\tfrac{1}{2}\right)^{r} \left(\tfrac{1}{2}\right)^{n-r} = \binom{n}{r} \frac{1}{2^{n}}.

Both probabilities are 1/21/2, so pr(1p)nrp^{r}(1-p)^{n-r} collapses to 1/2n1/2^{n} no matter what rr is. The entire shape of the distribution is carried by the count (nr)\binom{n}{r} alone.

From R to the Position y

I still had the probability in terms of RR, not the position yy I actually care about. The same two equations bridge them. Adding n=R+Ln = R + L and Y=RLY = R - L drops LL and gives R=n+y2R = \frac{n + y}{2}. Landing at position yy forces exactly n+y2\frac{n+y}{2} of the steps to have been rights. Substitute:

P(Y=y)=(nn+y2)12n.P(Y = y) = \binom{n}{\frac{n+y}{2}} \frac{1}{2^{n}}.

That is the whole PMF. Two constraints fix its domain, and they explain the parity pattern I had noticed by hand:

  • Parity. The count n+y2\frac{n+y}{2} has to be a whole number, so n+yn + y must be even, so yy shares the parity of nn. Even nn lands on even positions, odd nn on odd positions, and off-parity positions get probability 0.
  • Range. The number of rights runs 0n+y2n0 \le \frac{n+y}{2} \le n, which is just nyn-n \le y \le n. You cannot get further from 0 than the number of steps you took.

The textbook runs the same derivation in its random walk example (Example 3.7.2 in the 2nd edition), writing the position as Y=2XnY = 2X - n with XBin(n,1/2)X \sim \text{Bin}(n, 1/2) counting the right steps. That is the same RLR - L in different letters, since X=RX = R and nX=Ln - X = L.

Quick check against my hand tables: for n=3n = 3, P(Y=1)=(32)18=38P(Y = 1) = \binom{3}{2}\frac{1}{8} = \frac{3}{8}, exactly the 3/83/8 I had written for position 1 under PX3P_{X_3}.

The Click: One Shape, Three Disguises

Once the PMF is (n(n+y)/2)/2n\binom{n}{(n+y)/2} / 2^{n}, the bell stops being a surprise. The 1/2n1/2^{n} is a constant. The whole shape is the binomial coefficient (nk)\binom{n}{k} swept across kk, and I already knew that coefficient peaks in the middle and drops off toward the ends.

Why the coefficient peaks

Two arguments, and the second is the one worth keeping.

Symmetry rules out a monotonic slide. Choosing kk items to take is the same as choosing the nkn - k to leave behind, so (nk)=(nnk)\binom{n}{k} = \binom{n}{n-k}. The values at kk and nkn-k match, which forces a symmetric hump rather than a curve that just keeps falling.

The ratio test says where the hump turns over. Compare one coefficient to the next:

(nk+1)(nk)=nkk+1.\frac{\binom{n}{k+1}}{\binom{n}{k}} = \frac{n-k}{k+1}.

While this ratio is above 1, the sequence is still climbing. Setting nkk+11\frac{n-k}{k+1} \ge 1 rearranges to nkk+1n - k \ge k + 1, that is kn12k \le \frac{n-1}{2}. So the coefficients grow up to about the middle and shrink after it. For even nn there is a single peak at k=n/2k = n/2. For odd nn the ratio equals exactly 1 at the center, so the two middle values tie.

bh-ch3-binomial-peak

The same shape everywhere

Map that back to the walk. The count of rights is k=n+y2k = \frac{n+y}{2}, and (nk)\binom{n}{k} is largest at k=n/2k = n/2. Setting n+y2=n2\frac{n+y}{2} = \frac{n}{2} gives y=0y = 0. The most likely place to end up is where you started, with the probability decaying symmetrically toward ±n\pm n. That is the same peak, relabeled from "number of rights kk" to "position yy".

It is also the same shape as summing two dice. There, middle sums like 7 have many more combinations (1+6,2+5,3+4,1{+}6, 2{+}5, 3{+}4, \dots) than edge sums like 2, which only comes from 1+11{+}1, so mass piles up in the center.

bh-ch3-dice-sum-triangle

Worth pinning down what that dice sum actually is. With XX and YY the two dice, X+YX + Y is not a Binomial. A die is uniform on {1,,6}\{1, \dots, 6\}, not a Bernoulli, so the sum is a triangular distribution, the convolution of two uniforms, which is why its plot has straight sides rather than a smooth hump. It shares the Binomial's shape through the mechanism, not the formula: both are sums of independent identical pieces, and summing independent pieces piles mass in the middle, since more input pairs land on the central values. The walk lands on the Binomial exactly because its pieces are ±1\pm 1 Bernoulli steps, while the dice sum lands on a triangle because its pieces are uniform. Same family, different members.

Binomial coefficients, dice sums, and the random walk are the same peaked, symmetric object wearing different labels. The random-walk PMF is a relabeled Bin(n,1/2)\text{Bin}(n, 1/2), and nothing more. The reason it keeps smoothing toward a cleaner bell as nn grows has a name, the Central Limit Theorem: a sum of many independent identical pieces tends toward a bell whatever the pieces look like, and the walk is exactly such a sum.

Aside: y on Both Sides Is Fine

For a while the formula bothered me because yy shows up on the left and the right of P(Y=y)=P(Y = y) = \dots. That looked like an equation I should solve for yy. It is not. P(Y=y)P(Y = y) is a function definition, read as "the probability that the random variable YY takes the specific value yy". Capital YY is the random variable, lowercase yy is a particular number you plug in, and the PMF is often written pY(y)p_Y(y) to make that explicit. It is no stranger than f(x)=x2f(x) = x^2 having xx on both sides. That capital-vs-lowercase split is exactly the machinery behind probability-distributions-and-random-variables.