# Thread: random sample from a geometric distribution

1. ## random sample from a geometric distribution

Hello everyone!

I've got this problem on multivariable distributions I'm stuck on...

Let $X_1;X_2;X_3$denote a random sample of size n = 3 from a distribution with the geometric pdf
$P(X=k)=(\frac{3}{4}) ( \frac{1}{4} )^{k-1}$ and given the distribution $Z = X_1 + X_2 + X_3$
Question find the pdf of $Z$ then find $P(Z=15)$.
Now I considered using the moment generating function for 3 reasons: (a) $X_1, X_2, \text{and} X_3$ are a random sample size $\rightarrow \ X_1, X_2, \text{and } X_3$ are independent (b) they have the same pdf thus mgf, and (c) well, mgf can be used for this.
So i started out like this:
$M_Z (t) = E(e^{tZ})=E(e^{(X_1+X_2+X_3 )\cdot t})=E(e^{X_1 t} \cdot e^{X_2 t} \cdot e^{X_3 t})= ( E(e^{X_i t}) )^3$ $= (\frac{p e^t}{1-(1-p) e^t})^3$

Then I got stuck there... I presume I don't know how to "transform" variables in descrete distributions unlike continuous ones.
So any help is much appreciated!

2. Originally Posted by rebghb
Hello everyone!

I've got this problem on multivariable distributions I'm stuck on...

Let $X_1;X_2;X_3$denote a random sample of size n = 3 from a distribution with the geometric pdf
$P(X=k)=(\frac{3}{4}) ( \frac{1}{4} )^{k-1}$ and given the distribution $Z = X_1 + X_2 + X_3$
Question find the pdf of $Z$ then find $P(Z=15)$.
Now I considered using the moment generating function for 3 reasons: (a) $X_1, X_2, \text{and} X_3$ are a random sample size $\rightarrow \ X_1, X_2, \text{and } X_3$ are independent (b) they have the same pdf thus mgf, and (c) well, mgf can be used for this.
So i started out like this:
$M_Z (t) = E(e^{tZ})=E(e^{(X_1+X_2+X_3 )\cdot t})=E(e^{X_1 t} \cdot e^{X_2 t} \cdot e^{X_3 t})= ( E(e^{X_i t}) )^3$ $= (\frac{p e^t}{1-(1-p) e^t})^3$

Then I got stuck there... I presume I don't know how to "transform" variables in descrete distributions unlike continuous ones.
So any help is much appreciated!
Try comparing your moment generating function with the MGF of a negative binomial distribution.

3. I tried but there's no exponential in the denominator, I looked up the binomial mgf too... Still, no success

4. Ok, is it right to say:
$\frac{0.75^3e^{3t}}{(1-0.25e^{3t})^3}$ $=27\cdot (\frac{0.25}{1-0.25e^{3t}})^3 \ e^{3t}$ $=27 C_{k+3+3-1}^{3-1}(0.25)^3(0.75)^k$ $=27 C_{k+5}^{4}(0.25)^3(0.75)^k$

5. Originally Posted by rebghb
I tried but there's no exponential in the denominator, I looked up the binomial mgf too... Still, no success
Unfortunately, there is no agreement on how to define the geometrical and negative binomial distributions. You have to use a consistent set of definitions if you want your MGFs to match.

Try defining the geometrical distribution as
$f(x) = (1-p)^x p$ for $x=0,1,2, \dots$.
That should get rid of the exponential in the denominator of the MGF. Then I think you will have a match with your definition of the negative binomial.

Another possible source of confusion is whether p is the probability of success or the probability of failure. Again, you need a consistent set of definitions in order for everything to work out.