# Thread: moment generating function of binomial distribution

1. ## moment generating function of binomial distribution

I need some help understanding how to derive the moment generating function of a binomial distribution. I know that the solution is supposed to be:

$m(t) = (pe^t+q)^n$

so far I have:

$m(t) = \sum_{y=0}^{\infty} e^{ty}p(y) = \sum_{y=0}^{\infty} e^{ty} \binom{n}{y}p^y q^{n-y} = \sum_{y=0}^{\infty} \frac{n!}{y!(n-y)!} (pe^t)^y q^{n-y}$

at which point I don't know how to carry on.

2. Originally Posted by lllll
I need some help understanding how to derive the moment generating function of a binomial distribution. I know that the solution is supposed to be:

$m(t) = (pe^t+q)^n$

so far I have:

$m(t) = \sum_{y=0}^{\infty} e^{ty}p(y) = \sum_{y=0}^{{\color{red}n}} e^{ty} \binom{n}{y}p^y q^{n-y} = \sum_{y=0}^{{\color{red}n}} \frac{n!}{y!(n-y)!} (pe^t)^y q^{n-y}$

at which point I don't know how to carry on.
First the correction of some mistakes (the edit is in red). Do you understand why?

One or two more steps and you have it!

The key observation is the binomial theorem:

$(A + B)^n = \sum_{y=0}^{n} \frac{n!}{y!(n-y)!} A^y B^{n-y}$.

In your case $A = p e^t$ and $B = q$. Capisce?