# Is it appropriate to use $P(X=x^2)=P(X=x)$ in a secondary statistics textbook in this content?

Immediately got my attention is that where it wrote

$\text{Note } P(X=x^2)=P(X=x).$

I just don't think it should be written like this, as this is wrong! Also, I think the following is wrong:

$E(X^2)=\sum x^2 P(X=x^2) = ...$ this clearly contradicts the formula given just below the section heading.

Given the context, I think it could be changed to this:

The distribution for the random variable $Y=X^2$ is

and then make a note:

$\text{Note } P(Y=y)=P(X=x).$

So we have $$E(X^2)=E(Y)=\sum y P(Y=y) = ...$$

As a side note, I think this is all making it even worse for students to understand. As a textbook, it can just use the formula from first principle: $$E(X^2)=\sum x^2 P(X=x) = ...$$ which is straightforward!

What do you think?

• As for the first point (P(X=x) = P(X=x^2)) , although it's not true in general.. It is true for this Random Variable X in particular so I don't see how it's incorrect to state it like that. Apr 23, 2015 at 21:09
• @OmarHaque The random variable $X$ only takes FOUR values, namely 1,2,3,4. If you look the big $X$ in the 2nd table, the probability $P(X=x^2=4)$, is given as $6/25$. But the random variable $P(X=4)=3/25$ in the 1st table! So the random variable $X=x$ is not the same as $X=x^2$. Apr 23, 2015 at 21:15
• maybe it means $P(X=x)=P(X^2=x^2)$? Apr 23, 2015 at 21:24
• @danimal That would be one case, which is valid. It's just the way why it's given as this? I am trying to understand why it's not using the simple straightforward approach? The current version is confusion to the student and wrong to me. Apr 23, 2015 at 21:27

The "Note: $P(X=x^2)=P(X=x)$" is simply wrong.
They should have stated: $P(X^2=x^2)=P(X=x)$   so that: \begin{align}E(X^2) & = \sum\limits_{x^2\in\{1,4, 9, 16\}} x^2 \;\mathsf P(X^2=x^2) & \color{silver}{= \sum\limits_{y\in\{1,4, 9, 16\}} y\; \mathsf P(X^2=y)} \\ & = \sum_{x=1}^4 x^2\; P(X=x)\end{align}
More generally $P(X^2=x^2)=P(X=x\cup X=-x)$ but in this case $X$ is never negative .
I think this is just an error in the book. It looks to me like every occurence of $P(X = x^2)$ on the page should be $P(X^2 = x^2)$.