# Expected value of a certain exponential distribution

I need to find the expected value of this distribution. I think I just need to integrate the function from $$0$$ to $$\infty$$. Having trouble doing this integral though.

$$f(x; \mu) = \frac{1}{\mu} \cdot e^{− x/\mu },\ 0 ≤ x < \infty,\ \mu > 0$$

• What have you tried? Can you write said integral down? As a hint, integration by parts will help you with the integral you need. – AlkaKadri Oct 8 '18 at 23:07

The expected value is $$\int_0^\infty \frac{x}{\mu} e^{-x/\mu}\ dx.$$

By the change of variables $$x/\mu = y$$, $$dx = \mu\ dy$$, and integrating by part we get $$\int_0^\infty \frac{x}{\mu} e^{-x/\mu}\ dx = \mu \int_0^\infty y e^{-y}\ dx = \mu [-ye^{-y}]_0^{\infty} + \mu \int_0^\infty e^{-y}\ dx = \mu [-e^{-y}]_0^\infty = \mu.$$