Let $X_1, X_2, X_3$ be three independent identically distributed random variables. Does this mean that

$$ X_3 - X_2, \ X_2 - X_1 $$

are also independent random variables? We can instead inspect the independence of

$$ X_3-X_2 \text{ and } X_1 - X_2 .$$


$$X_3 \text{ and }X_1$$

are independent. Does adding $-X_2$ (which is independent of $X_3$ and $X_1$) to both sides preserve the independence?


4 Answers 4



Counterexample: $X_1=X_3=0$, $X_2$ any nonconstant random variable.

EDIT : sorry I missed the "identically distributed part".

Another counterexample: any (square-integrable) nonconstant random variables. Indeed, let $\sigma^2$ be their common variance. Then $X_3-X_2$, $X_2-X_1$ and $X_3-X_1$ all have variance $2\sigma^2$. But if $X_3-X_2$ and $X_2-X_1$ were independent, then their sum $X_3-X_1$ would have variance $4\sigma^2\neq2\sigma^2$.

  • $\begingroup$ Thank you for your answer. What if we add the condition that all of them cannot be constant random variables? $\endgroup$
    – user1165177
    Mar 31, 2023 at 19:32
  • $\begingroup$ @DavideGiraudo reread the first sentence. We do have that. $\endgroup$
    – Alborz
    Mar 31, 2023 at 20:27
  • $\begingroup$ I did thanks: the counter-example should also satisfy the assumption of i.i.d. If $X_1=0$ and $X_2$ is not constant, how can they be identically distributed? $\endgroup$ Mar 31, 2023 at 20:30
  • $\begingroup$ @DavideGiraudo yes you are right, this is not a valid counter-example $\endgroup$
    – Alborz
    Mar 31, 2023 at 20:34
  • $\begingroup$ Sorry for this I misread the statement. I edited my answer. $\endgroup$
    – Will
    Mar 31, 2023 at 21:31

Actually, if $X_1,X_2,X_3$ are i.i.d. and such that $X_3-X_2$ and $X_2-X_1$ are independent, then necessarily, $X_1$ is almost surely constant.

Indeed, independence between $X_3-X_2$ and $X_2-X_1$ translate in terms of characteristic functions as $$ \forall s,t\in\mathbb R, \quad \mathbb E\left[e^{is(X_3-X_2)+it(X_2-X_1)}\right]=\mathbb E\left[e^{is(X_3-X_2)} \right] \mathbb E\left[e^{it(X_2-X_1)}\right] $$ and denoting by $\varphi$ the characteristic function of $X_1$ (which is also that of $X_2$ and that of $X_3$), we get $$ \varphi(s)\varphi(t-s)\varphi(-t)=\varphi(s)\varphi(-s)\varphi(t)\varphi(-t). $$ Taking $s=t$ shows that $\lvert\varphi(s)\rvert^2\in\{0,1\}$ for each $s\in\mathbb R$. By continuity and $\varphi(0)=1$, we infer that $\lvert\varphi(s)\rvert^2=1$ for each $s$ hence the characteristic function of $X_2-X_1$ is constant equal to $1$, which shows that $X_1=X_2$ almost surely. Consequently, for each $a$, letting $F(a)=\mathbb P(X_1\leqslant a)$, one has $0=\mathbb P(X_1\leqslant a,a<X_2)=F(a)(1-F(a))=0$ hence $X_1$ is constant.

  • 1
    $\begingroup$ This does not answer the question which is: does $X_1, X_2, X_3$ i.i.d. give that $X_3 - X_2, X_2 - X_1$ independent? $\endgroup$
    – Alborz
    Mar 31, 2023 at 20:16
  • 1
    $\begingroup$ Why? This shows that the answer is no, unless $X_1$ is almost surely constant. $\endgroup$ Mar 31, 2023 at 20:19
  • 1
    $\begingroup$ Well, I answer something more general and give a necessary and sufficient condition. $\endgroup$ Mar 31, 2023 at 20:29
  • 1
    $\begingroup$ No: let $\mathcal I$ be the set of 3-uples of real-valued random variables $(X_1,X_2,X_3)$, such that $X_1,X_2,X_3$ are i.i.d. The initial question was: if $(X_1,X_2,X_3)$ belongs to $\mathcal I$, do we have independence between $X_2-X_1$ and $X_3-X_2$? The answer to this question is no (for example, if $X_1$ has a finite moment of order two, the computation of the covariance shows that a non-constant $X_1$ gives a counter-example. The question I address is: suppose that $(X_1,X_2,X_3)\in\mathcal I$. A necessary and sufficient condition for the independence between $X_2-X_1$ and $X_3-X_2$ $\endgroup$ Mar 31, 2023 at 20:38
  • 1
    $\begingroup$ is that $X_1$ is constant. In particular, if you take $X_1,X_2,X_3$ iid and $X_1$ not almost surely constant, you do have a counter-example. In general, it is better, when we can, to characterize the counter-examples than settling for giving one. $\endgroup$ Mar 31, 2023 at 20:39

Computational answer: a slight variant (no pun intended) on Will's answer: instead of looking at variance you can look at covariance. Independent random variables must have covariance zero, provided that they have second moments. So if you compute the covariance and don't get zero, they can't be independent. (However it is also possible for dependent random variables to have zero covariance, so the test only works one way.

Here, using the bilinearity we have $$\begin{align*}\newcommand{\Cov}{\operatorname{Cov}}\Cov(X_3 - X_2, X_2 - X_1) &= \Cov(X_3, X_2) - \Cov(X_2, X_2) - \Cov(X_3, X_1) + \Cov(X_2, X_1)\\ &= - \operatorname{Var}(X_2)\end{align*}$$ which cannot be zero unless $X_2$ is constant. So we didn't even need the assumption of identical distribution.

Covariance has so many nice properties that it's often quite easy to compute. So next time you are wondering whether two random variables are independent, covariance can be one of the first things you check.

Intuitive answer: what it means to be independent is that if you are allowed to observe the value of one of the variables, you do not under any circumstances gain even the slightest amount of information about the other, nor do you become able to predict it any more accurately than before.

To see that's not true here, think about the $X$s as having a distribution which is zero with some high probability, and some large positive number with low probability (like the value of a lottery ticket). Suppose you observe $X_3 - X_2$ and see that it is a large negative number: not very likely, but possible. Then you know that $X_2$ had the large value, and so with this information (in the sense of conditional probability), it is extremely likely that $X_2 - X_1$ has a large positive value. The only way that would fail is if $X_1$ also had the large value, which even given your information about $X_3 - X_2$, is still highly unlikely (in fact, by independence, the observation of $X_3 - X_2$ told you nothing at all about $X_1$).

Or, to see it another way, if you observe that $X_3 - X_2$ is negative, then you know that $X_2 - X_1$ is possibly positive or possibly zero, but definitely not negative. Prior to your observation, there was a nonzero probability for $X_2 - X_1$ to be negative, so you have gained relevant information, and that means they are dependent.


No, and this has nothing to do with constant random variables or otherwise (referring to your comment on Will's answer). Think of it intuitively. $X_2$ is playing a direct role in both $X_3 - X_2$ and $X_2 - X_1$, this causes them to be highly dependent. If $X_2$ is an extreme value (or any value, really, besides $0$), it will affect both the same way (technically, the opposite way, but you get what I'm saying)

  • 2
    $\begingroup$ This has does to do with constant random variables, as it is the only case where we can have $X_3-X_2$ independent of $X_2-X_1$. $\endgroup$ Mar 31, 2023 at 20:11
  • $\begingroup$ @DavideGiraudo that's not what is being asked, we're not tasked with finding the situation where they are independent. I'm pointing out how that, in general, this is not going to guarantee independence $\endgroup$
    – Alborz
    Mar 31, 2023 at 20:43

You must log in to answer this question.