9. Let $\alpha, \beta, \gamma$ satisfy $0<\alpha<\beta<\gamma<2 \pi$. If for any $x \in \mathbf{R}, \cos (x+\alpha)+\cos (x+\beta)+$ $\cos (x+\gamma)=0$, then $\gamma-\alpha=$ $\qquad$ .
9. $\frac{4 \pi}{3}$.

Let $f(x)=\cos (x+\alpha)+\cos (x+\beta)+\cos (x+\gamma)$.
Given $x \in \mathbf{R}, f(x) \equiv 0$, we know
$$
f(-\alpha)=0, f(-\gamma)=0, f(-\beta)=0,
$$

which means
$$
\begin{array}{l}
\cos (\beta-\alpha)+\cos (\gamma-\alpha)=-1, \\
\cos (\alpha-\beta)+\cos (\gamma-\beta)=-1, \\
\cos (\alpha-\gamma)+\cos (\beta-\gamma)=-1 .
\end{array}
$$

Thus, $\cos (\beta-\alpha)=\cos (\gamma-\beta)=\cos (\gamma-\alpha)=-\frac{1}{2}$.
Since $0<\alpha<\beta<\gamma<2 \pi$, we have
$$
\beta-\alpha, \gamma-\alpha, \gamma-\beta \in\left\{\frac{2 \pi}{3}, \frac{4 \pi}{3}\right\} \text {. }
$$

Also, since $\beta-\alpha<\gamma-\alpha, \gamma-\beta<\gamma-\alpha$, we have $\beta-\alpha=$ $\gamma-\beta=\frac{2 \pi}{3}$. Therefore, $\gamma-\alpha=\frac{4 \pi}{3}$.

Furthermore, when $\beta-\alpha=\gamma-\beta=\frac{2 \pi}{3}$, we have $\beta=\alpha+\frac{2 \pi}{3}$, $\gamma=\alpha+\frac{4 \pi}{3}$. For any $x \in \mathbf{R}$, let $x+\alpha=\theta$. The three points
$$
\begin{array}{l}
(\cos \theta, \sin \theta),\left(\cos \left(\theta+\frac{2 \pi}{3}\right), \sin \left(\theta+\frac{2 \pi}{3}\right)\right), \\
\left(\cos \left(\theta+\frac{4 \pi}{3}\right), \sin \left(\theta+\frac{4 \pi}{3}\right)\right)
\end{array}
$$

form the vertices of an equilateral triangle on the unit circle $x^{2}+y^{2}=1$, with its center at the origin. Clearly, we have
$$
\cos \theta+\cos \left(\theta+\frac{2 \pi}{3}\right)+\cos \left(\theta+\frac{4 \pi}{3}\right)=0,
$$

which means $\cos (x+\alpha)+\cos (x+\beta)+\cos (x+\gamma)=0$.