0

Let $X$ (respectively, $X^2$) be a random variable with a given probability density function $f_X$ (respectively, $f_{X^2}$).

Is the following statement true:

$$EXX^2 = EX^3 = \int_{-\infty}^{\infty}x f_{X^2}\left(x\right) f_X\left( x \right)\;dx = \int_{-\infty}^{\infty}x^3f_{X}\left( x \right)\;dx $$

I've tried this on some example functions and it really seems to hold true. But I cannot say for certain.

David K
  • 98,388
  • 2
    $XX^2 = X^3$??? Also you tacitly assumed $X$ and $X^2$ are independent in the third part of your equation. – Stefan Perko Nov 29 '17 at 21:15
  • $f_X \cdot f_{X^2}$ is not the density function for $X(X^2)$; it is the density for $YX^2$ where $Y$ is an independent copy of $X$. – angryavian Nov 29 '17 at 21:18
  • When you say "$X$ ($X^2$) is a random variable", do you mean "$Y$ is a random variable, where $Y=X(X^2)$," or do you mean "$X$ and $X^2$ are random variables"? – David K Nov 29 '17 at 21:19
  • Well since $X$ is formally a function I think it is not obvious it should work like this. The last part of the equation is right? – SlowerPhoton Nov 29 '17 at 21:19
  • I mean $X$ and $X^2$ are random variables (obviously dependent), sorry for the confusion. – SlowerPhoton Nov 29 '17 at 21:21
  • 1
    I've inserted a couple of words to clarify what I think you meant to write. You can further edit the question or roll back my edit if it isn't right. – David K Nov 29 '17 at 21:23

2 Answers2

2

$X X^2 = X^3$ of course, and $\mathbb E X^3 = \int_{-\infty}^\infty x^3 f_X(x)\; dx$ by the Law of the Unconscious Statistician. But $ \int_{-\infty}^\infty x f_{X}(x) f_{X^2}(x^2)\; dx$ makes no sense.

Robert Israel
  • 448,999
  • It was meant to be $ \int_{-\infty}^\infty x f_{X}(x) f_{X^2}(x); dx$. And in case $X$ and $Y$ are independent variables, is $EXY = \int_{-\infty}^\infty x f_{X}(x) f_{Y}(x); dx$? I think it doesn't work only because $X$ and $X^2$ are dependent, right? – SlowerPhoton Nov 29 '17 at 21:23
  • @SlowerPhoton $X,X^2$ are dependent... often. If not, then $X^2$ is constant almost surely. – Stefan Perko Nov 29 '17 at 21:30
  • I am not saying they aren't. – SlowerPhoton Nov 29 '17 at 21:37
  • No, the formula for independent random variables would be $$\mathbb E [XY] = \int_{-\infty}^\infty \int_{-\infty}^\infty x y f_X(x) f_Y(y); dx ; dy = \mathbb E[X] \mathbb E[Y]$$ – Robert Israel Nov 29 '17 at 22:38
1

Let $X \sim U[0,1].$ Then $$f_X(x) = \begin{cases} 1 & 0 \leq x\leq 1,\\ 0 & \text{otherwise} \end{cases} $$ and $$ f_{X^2}(x) = \begin{cases} \dfrac{1}{2\sqrt x} & 0 \leq x\leq 1,\\ 0 & \text{otherwise} \end{cases}. $$

(See Does the square of uniform distribution have density function?)

Therefore $$ \int_{-\infty}^\infty x f_{X^2}(x) f_X( x )\;dx = \int_0^1 \dfrac{\sqrt x}{2}\;dx = \frac 13 $$ whereas $$ \int_{-\infty}^\infty x^3 f_X( x )\;dx = \int_0^1 x^3 \;dx = \frac 14. $$ And indeed $E(X^3) = \frac14.$

In general, it's true that $E(XX^2) = E(X^3) = \int_{-\infty}^\infty x^3 f_X( x )\;dx,$ but the middle part of your sequence of equations isn't generally correct.

David K
  • 98,388