ok so maybe im just being stupid here...

$\displaystyle \int_0^\infty xe^{-x} dx $

so by using integration by parts....

= $\displaystyle \left[ -xe^{-x} - \int -e^{-x} dx \right]_0^\infty $

= $\displaystyle \left[ -xe^{-x} - e^{-x} \right]_0^\infty $

= $\displaystyle \left[ (-x-1)e^{-x}\right]_0^\infty $

so is that right? if so, pluging in $\displaystyle \infty $ doesn't really make sense or give me an answer that looks right!

any help will be much appreciated!