Poisson distribution with exponential parameter

I don't know how to solve Exercise 8, Section 5.2 from Geoffrey G. Grimmett, David R. Stirzaker, Probability and Random Processes, Oxford University Press 2001. For those who don't have this book:

Let $X$ have a Poisson distribution with parameter $\Lambda$, where $\Lambda$ is exponential with parameter $\mu$. Show that $X$ has a geometric distribution.

$X \sim Poiss(\Lambda),\ \ \Lambda \sim Exp(\mu)$.

So we know that generating function of $X$ is $G_x(s) = \sum_{i=0} s^i \frac{\Lambda^i}{i!} e^{-\Lambda}= e^{\Lambda(s-1)}$.

Probability density function of $\Lambda$ is $f_{\Lambda} = \mu e^{-\mu x}$.

And I don't know what I should do next. How to decompose $\Lambda$ in $G_x$ (or maybe this is not a good idea?).

-
Why use generating functions? One can compute directly $\mathbb P(X=n)$ for each $n$. – Did Jan 17 '13 at 21:56
And how to do this? – user52354534 Jan 18 '13 at 1:05
See my answer... – Did Jan 18 '13 at 7:13

For every nonnegative integer $n$, $\mathbb P(X=n\mid\Lambda)=\mathrm e^{-\Lambda}\Lambda^n/n!$ hence $$\mathbb P(X=n)=\int_0^{+\infty}\left(\mathrm e^{-\lambda}\frac{\lambda^n}{n!}\right)\,f_\Lambda(\lambda)\,\mathrm d\lambda=\int_0^{+\infty}\left(\mathrm e^{-\lambda}\frac{\lambda^n}{n!}\right)\,\mu\mathrm e^{-\mu\lambda}\,\mathrm d\lambda.$$ The change of variable $x=(1+\mu)\lambda$ yields $$\mathbb P(X=n)=\frac{\mu}{(1+\mu)^{n+1}}\int_0^{+\infty}\mathrm e^{-x}\frac{x^n}{n!}\mathrm dx=\frac{\mu}{(1+\mu)^{n+1}}.$$ One gets $$\mathbb P(X=n)=(1-p)p^n,\qquad p=\frac1{1+\mu}.$$ Thus, the distribution of $X$ is geometric with parameter $p$.

-
After changing of variable I get different result, please correct me: $$x = \mu \lambda \\ dx = \mu d\lambda \\ \int_0^{\infty} e^{-\frac{x}{\mu}} \frac{x^n}{\mu^n n!} \mu e^{-x} \frac{1}{\mu} dx = \frac{1}{\mu^n} \int_0^{\infty} e^{-x} \frac{x^n}{n!} e^{-\frac{x}{\mu}} dx$$ – user52354534 Jan 18 '13 at 17:26
And why does $\int_0^{\infty} e^{-x} \frac{x^n}{n!} dx$ equal $1$ ? – user52354534 Jan 18 '13 at 17:45
Oh, I see - this is the Gamma Function, so I guess there is no simple explanation? :) Could you also explain me the first two equality: $$P(X=n|\Lambda) = e^{-\Lambda} \Lambda^n / n! \\ P(X=n) = \int_0^{\infty} e^{-\lambda} \frac{\lambda^n}{n!} f_{\Lambda} (\lambda) d\lambda$$ What formula or theorem it is? – user52354534 Jan 18 '13 at 18:08
The correct change of variable is $x=(1+\mu)\lambda$, sorry about that. – Did Jan 18 '13 at 20:45
Regarding the formula for $P(X=n\mid\Lambda)$, I wonder what is to explain. Here is a question: how would you translate the hypothesis that the distribution of $X$ is Poisson with parameter $\Lambda$? – Did Jan 18 '13 at 20:47

Be careful, $\Lambda$ is a random variable! So your computation only shows that $$E[s^X \mid \Lambda] = \sum_{n=0}^\infty \frac{(s\Lambda)^n}{n!}e^{-\Lambda} = e^{\Lambda (s-1)}.$$

Now you should be able to compute $$G_X(s) = E[s^X] = E\left[E[s^X\mid \Lambda]\right].$$

-
I don't quite understand second equality, could you explain it? Why $s^X = E(s^X | \Lambda)$ ? Provided that, $G_X(s) = E(e^{\Lambda (s-1)}) = \int e^{x(s-1)} \mu e^{-\mu x} dx = \frac {\mu e^{x(s-1-\mu)}}{s-1-\mu}$. Is it okay? If yes, how to deduce that $X$ has a geometric distribution? – user52354534 Jan 17 '13 at 22:26
I never wote such a thing as $s^X = E(s^X\mid\Lambda)$. I am only using the very basic property of conditional expectation $E[Z]=E\left[E[Z\mid \mathcal{F}]\right]$. Besides, the value of the integral cannot depend on the variable of integration $x$... – Siméon Jan 18 '13 at 11:21