# How to evaluate the integral $\int_0^{\infty}[I_{(0,2)}(z)]\frac{(n-1)(y-z)^{n-2}}{y^{n-1}}dy$

I am doing a statistical calculation from a statistical exercise but get stuck at the following integral.

$$\int_0^{\infty}[I_{(0,2)}(z)] \frac{(n-1)(y-z)^{n-2}}{y^{n-1}}dy$$ $0<z<y$

$I_{(0,2)}(z)$ is an indicator function.

• Looks to me to diverge by limit comparison with $\frac{1}{y}$. Sep 13, 2015 at 15:05
• I totally agree with John Brevik, the integral is clearly divergent. There is also a non-integrable singularity in the origin. Time to discuss this kind of questions on Meta. Sep 13, 2015 at 15:23
• @JackD'Aurizio If you ask a question on Meta, do you provide a link here to that discussion? Sep 13, 2015 at 15:24
• @mickep: sure - meta.math.stackexchange.com/questions/21406/… Sep 13, 2015 at 16:00
• Suddenly, in your new question (your calculation in the end), it looks like you are integrating with respect to $z$. Please clarify. Sep 14, 2015 at 7:20

Ok,I solved the problem, in fact, our book has a typo it should be $dz$,not $dy$. Thank you for all your comments.

Now the problem becomes easy.

The indicator function is just $1$ or $0$, if , $z\in (0,2)$ then the function is $1$ else is $0$. If it is $0$ integral will be $0$.

So when $z\in (0,2)$

$$\int_0^2 \frac{(n-1)(y-z)^{n-2}}{y^{n-1}}dz\\=\frac{n-1}{y^{n-1}}\int_0^{2} (y-z)^{n-2}dz\\=-\frac{(n-1)}{y^{n-1}}\int_0^2 (y-z)^{n-2}d(y-z)\\=-\frac{(n-1)}{y^{n-1}}\frac{(y-z)^{n-1}}{n-1}\mid_0^2\\=-\frac{(n-1)}{y^{n-1}}[\frac{(y-2)^{n-1}}{n-1}-\frac{(y-0)^{n-1}}{n-1}]\\=1-(\frac{y-2}{y})^{n-1}$$

Which is the solution.

When I try to solve the problem I find that the integral $$\int_0^{\infty}[I_{(0,2)}(z)] \frac{(n-1)(y-z)^{n-2}}{y^{n-3}}dy$$ is solvable just by a small modification.