Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm having trouble with the following random variable transformation:

$Y = X^2 + X$

I am looking for the pdf of Y. I tried the following method:

$p_Y(y) = \int_{X} p_{Y|X=x}(y)\cdot p_{X}(x)dx$ and we know that $(Y|X=x) \sim (x^2+x) \Rightarrow p_{Y|X=x} = \delta_{x^2+x}(y)$ thus: $p_Y(y) = \int_{X} \delta_{x^2+x}(y)\cdot p_{X}(x)dx$

But I don't see a way to reduce this further.

Then I tried a different approach:

$p_Y(y) = DF(Y < y) = DF(X^2 + X < y) = ...$

But then I don't see a way to find the inverse of $X^2 + X$.

Can anyone help me further on this?

share|cite|improve this question
up vote 1 down vote accepted

Let $Y = X^2 + X = \left( X+\frac{1}{2} \right)^2 - \frac{1}{4}$. Then $$ F_Y(y) = \mathbb{P}(Y \le y) = \mathbb{P}\left( \left( X+\frac{1}{2} \right)^2 \le y + \frac{1}{4} \right) $$ Assume, additionally, that $y+\frac{1}{4} > 0$. Then $$ \begin{eqnarray} F_Y(y) &=& \mathbb{P}\left( -\sqrt{y + \frac{1}{4}} \le X+\frac{1}{2} \le \sqrt{y + \frac{1}{4}} \right) \\ &=& F_X\left( -\frac{1}{2} + \sqrt{y + \frac{1}{4}} \right) - F_X\left( -\frac{1}{2} -\sqrt{y + \frac{1}{4}} \right) + \mathbb{P}\left( X = -\frac{1}{2} - \sqrt{y + \frac{1}{4}} \right) \end{eqnarray} $$

If $X$ is continuous rv, the last term is zero.

Differentiating with respect to $y$, we get $$ f_Y(y) = \frac{1}{\sqrt{4y+1}} \left( f_X\left(-\frac{1}{2} + \sqrt{y + \frac{1}{4}} \right) + f_X\left( -\frac{1}{2} -\sqrt{y + \frac{1}{4}} \right) \right) \cdot \mathbf{1}\left(y > -\frac{1}{4}\right) $$

share|cite|improve this answer
Thanks for the hint. Indeed, when Y = X^2 + X, this reduction works, but actually I was looking for a way to transform a general case X^n + X^n-1 + ... + 1. But I suppose that will not be possible, as that function will not always be invertable – James Nov 23 '11 at 21:07
$Y = X^n + X^{n-1} + \ldots + 1 = \frac{X^{n+1}-1}{X-1}$. Notice that the polynomial in $X$ only has 1 real root for even $n$ and no real roots for odd $n$. I think it is possible to work the solution out, but it will involve symmetric function of complex roots. – Sasha Nov 23 '11 at 21:14

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.