# Expectation about Generalized exponential distribution

I would like to ask this question here too.

The probability density function is $$$$f\left(x;\alpha,\beta,\mu\right)=\alpha\beta\left(1-e^{-\left(x-\mu\right)\beta}\right)^{\alpha-1}e^{-\left(x-\mu\right)\beta},\ x>\mu,\ \alpha>0,\ \beta>0$$$$

I need to show that

$$\begin{eqnarray*} E\left(\frac{\left(X-\mu\right)e^{-\left(X-\mu\right)\beta}}{1-e^{-\left(X-\mu\right)\beta}}\right) & = & \int_{\mu}^{\infty}\frac{\left(x-\mu\right)e^{-\left(x-\mu\right)\beta}}{1-e^{-\left(x-\mu\right)\beta}}\cdot f\left(x;\alpha,\beta,\mu\right)\enspace dx\\ & = & {\left[\frac{\alpha}{\beta\left(\alpha-1\right)}\left(\psi\left(\alpha\right)-\psi\left(1\right)\right)-\frac{1}{\beta}\left(\psi\left(\alpha+1\right)-\psi\left(1\right)\right)\right]}\tag{1} \end{eqnarray*}$$

($$\psi$$ is digamma function)

When i applied the transformation $$t=e^{-\left(x-\mu\right)\beta}$$ the integral became $$E\left(\frac{\left(X-\mu\right)e^{-\left(X-\mu\right)\beta}}{1-e^{-\left(X-\mu\right)\beta}}\right)=-\frac{\alpha}{\beta}\int_{0}^{1}t\left(1-t\right)^{\alpha-2}\log t\ dt.$$ how can i go to the next step?

I verified you substituion and got the same answer so we will pick up where you left off. We have $$I=-\frac{\alpha}{\beta}\int_0^1(\log t) t (1-t)^{\alpha-2}\,\mathrm dt.$$ Using $$\partial_x t^x=t^x\log t$$ gives $$I(x)=-\frac{\alpha}{\beta}\partial_x\int_0^1t^x (1-t)^{\alpha-2}\,\mathrm dt,$$ where $$I=I(1)$$. Notive that $$I(x)$$ is very closely related to the integral definition of the beta function leaving us with $$I(x)=-\frac{\alpha}{\beta}\partial_x\frac{\Gamma(\alpha-1)\Gamma(x+1)}{\Gamma(\alpha +x)}.$$ Since $$\partial_z\log\Gamma(z):=\psi(z)=\Gamma^\prime(z)/\Gamma(z)\implies\partial_z\Gamma(z)=\psi(z)\Gamma(z)$$ we are able to evaluate the derivative yielding $$I(x)=-\frac{\alpha\Gamma(\alpha-1)}{\beta}\frac{\Gamma(x)}{\Gamma(\alpha+x)}% \left(1+x\psi(x)-x\psi(a+x)\right).$$ Substituting $$x=1$$ and using the properties $$z\Gamma(z)=\Gamma(z+1)$$, $$\psi(1)=-\gamma$$ (Euler-Mascheroni constant), and $$H_z=\psi(z+1)-\gamma$$ (generalized harmonic numbers) gives after some simplification $$I=\frac{H_\alpha-1}{(\alpha-1)\beta}.$$ This is clearly different from $$(1)$$ given in your post. If we use the abovementioned properties we can simplify $$(1)$$ to $$\frac{\psi(\alpha)+\frac{1}{\alpha}+\gamma-1}{(\alpha-1) \beta}.$$ Then using the relationship $$\psi(z+1)=\psi(z)+\frac{1}{z}$$ and the definition of the generalized harmonic numbers shows that the solution for $$I$$ agrees with the form $$(1)$$ given in your post.