I have a PDF:
$$f_y(y) = \frac{\lambda^n}{\Gamma(n)} (y-n\tau)^{n-1}e^{-\lambda(y-n\tau)}$$
I want to find the moment generating function for it: (I believe I made a mistake somewhere?)
$$\begin{aligned}
M(t) = E[e^{Yt}] &= \int_0^\infty e^{yt} \frac{\lambda^n}{\Gamma(n)} (y-n\tau)^{n-1}e^{-\lambda(y-n\tau)} \; dy \\
&= \frac{\lambda^n e^{\lambda n \tau}}{\Gamma(n)} \int_0^\infty e^{-y(\lambda-t)(y-n\tau)^{n-1} \; dy} \\
& \text{... let } u = y(\lambda-t) \\
&= \frac{\lambda^n e^{\lambda n \tau}}{\Gamma(n)} \int_0^\infty e^{-u} (\frac{u}{\lambda-t}-n\tau)^{n-1} \frac{1}{\lambda-t} \, du
\end{aligned}$$
Usually after the substitution I would get something that I know how to integrate like a PDF of some distribution or in this case perhaps a gamma function? But in this case it looks complex? Maybe I made a wrong substitution?
Since the PDF is that of a gamma distribution, I expected the MGF of a gamma distribution which I belive should be $$\frac{\lambda}{\lambda-t}n$$ in this case?
UPDATE
Ok probably 1 of my mistakes is after changing variables, my limits of integration should change ... but I am not sure how to proceed after:
after change of variables
$$\begin{aligned}
&= \frac{\lambda^n e^{\lambda n \tau}}{\Gamma(n)} \int_{n\tau (\lambda - t)}^\infty e^{-u} (\frac{u}{\lambda-t} - n\tau)^{n-1} \frac{1}{\lambda-t} \, du \\
&= \frac{\lambda^n e^{\lambda n \tau}}{\Gamma(n) (\lambda - t)^n} \int_{n\tau (\lambda - t)}^\infty e^{-u} (u-n\tau (\lambda-t))^{n-1} \, du
\end{aligned}$$
The integral looks like a gamma function? But how do I handle $u-n\tau (\lambda-t)$? I got a feeling it have something to do with the limits of integration, but I am not sure what ...
Answer
You wanted to shift the gamma distribution, but you didn't shift it. Your integral should start from $n\tau$.
\begin{aligned}
M(t) = \int_{n\tau}^\infty e^{yt} \frac{\lambda^n}{\Gamma(n)} (y-n\tau)^{n-1}e^{-\lambda(y-n\tau)} \; dy.
\end{aligned}
Now apply the change of variables $u = y-n\tau$ to get
\begin{aligned}
M(t) = e^{n\tau t}\int_{0}^\infty e^{ut} \frac{\lambda^n}{\Gamma(n)} u^{n-1}e^{-\lambda u} \; du. = e^{n\tau t}\times\mbox{MGF of unshifted Gamma}(t)
\end{aligned}
Meanwhile, we have also shown that the MGF of the shifted PDF is just $e^{t\,\mathtt{SHIFTAMOUNT}}$ times the unshifted MGF, and all this calculation was actually not necessary :)
No comments:
Post a Comment