# Taking square of a PDF

I have obtained the pdf and its distribution seems to be a triangle. Now, I want to take the square of this pdf like

$${f_Y(y)}^2$$

How can I obtain the square of this pdf?

Do, I just need to simply multiply the two $f_Y(y)$?

-
What do you want to achieve by "taking the square" of the PDF? –  Henning Makholm Dec 23 '12 at 2:37
I have to calculate pdf for----> function^2=(variable1-variable2)^2+(variable11-variable22)^2. So I am done with calculating pdf for variable1-variable2.Now I want to take the square of this pdf. –  Zara Dec 23 '12 at 2:47
You presumably obtain the square of a pdf by squaring. Buty what is the real problem? –  André Nicolas Dec 23 '12 at 2:55
The pdf of x^2 is not the pdf squared - very far from it. –  leonbloy Dec 23 '12 at 3:10
Evidently, you already know that the PDF of the sum of two random variables is not the sum of the PDFs of the variables. So you should not expect the PDF of the square of a variable to be the same as the square of the PDF of the variable! What you want is the former, but in your question you are asking for the latter, which as you can tell is not a PDF. –  Rahul Dec 23 '12 at 3:10

If $f(x)$ is the pdf of $X$, then $f(x)^2$ is NOT the pdf of $X^2$. Write $F(x)$ as the cdf of $X$: $F(x)=P(X\leq x)$. Then if $G$ is the cdf of $Y:=X^2$, $G(y):=P(Y\leq y)=P(x^2\leq y)=P(-\sqrt{y}\leq x\leq \sqrt{y})$, and assuming $X$ has a continuous cdf, $G(y)=F(\sqrt{y})-F(-\sqrt{y})$, which gives $g(y)=G'(y)=\frac{1}{2\sqrt{y}}(f(\sqrt{y})+f(-\sqrt{y}))$