I was working on this problem but I didn't get the right answer, though I can't find my mistake.
Here is the question and my attempt:
$\int_a^\infty xe^{-x}dx$ evaluate.
$\lim_{b\to \infty} \int_a^b xe^{-x}dx$
then using parts, by letting $u = x$ and $dv/dx = e^{-x}$,
I got:
=$\lim_{b\to \infty}(-e^{-x})_a^b + \int_a^b e^{-x}dx$
=$\lim_{b\to \infty}((-e^{-x})_a^b + -e^{-b}+e^{-a})$
=$\lim_{b\to \infty}(-e^{-b}+e^{-a} -e^{-b}+e^{-a})$
=$2e^{-a}$
Integrating by parts gives $$\int xe^{-x}\,dx=-xe^{-x}+e^{-x}.$$