# Math Help - Generating Functions

1. ## Generating Functions

A random variable X assumes only the values 0,1,2,3....., and the probabilities that X assumes these values are (2/3), (2/3)(1/3) , (2/3)(1/3)^2 , (2/3)(1/3)^3 , ................ respectively. Find the E(x) and Var(x).

E(X) = 1/2
Var(x) = 3/4

I dont know where to start. Can someone show me how this problem should be done?

F(z) = P(X=0) +P(X=1)z+(p(x=2)z^2 + .......
F(z) = (2/3) + (2/3)(1/3)(z) +(2/3)(1/3)^2 z^2 + .........
F'(z) = (2/3)(1/3) + 2(2/3)(1/3)^2 z + ...........
F''(z) = .................

I know that
E(X) = P'(1)
and
Var(X) = f''(1) + f'(1) - [f'(1)]^2
[/I]

2. Hello,

Get inspired by this : Geometric distribution - Wikipedia, the free encyclopedia

Or consider the equality $\frac{1}{1-x}=\sum_{k=0}^\infty x^k$ and differentiate it as you wish to compute the series you're dealing with.

3. Originally Posted by Moo
Hello,

Get inspired by this : Geometric distribution - Wikipedia, the free encyclopedia

Or consider the equality $\frac{1}{1-x}=\sum_{k=0}^\infty x^k$ and differentiate it as you wish to compute the series you're dealing with.

Thanks alot. I was able to work out the problem.

4. Hello, jjbrian!

A random variable $x$ assumes only the values $0,1,2,3\,\hdots$
and the probabilities that $x$ assumes these values are
. . $(\tfrac{2}{3}),\; (\tfrac{2}{3})(\tfrac{1}{3}),\;(\tfrac{2}{3}(\tfra c{1}{3})^2,\; (\tfrac{2}{3})(\tfrac{1}{3})^3\; \hdots$ resp.

Find the $E(x)$ and $Var(x)$.

Book Answer: . $E(X) = \frac{1}{2},\;\;Var(x) = \frac{3}{4}$

We have: . $\begin{array}{c|c} n & P(n) \\ \hline \\[-3mm]
0 & \frac{2}{3} \\ \\[-3mm] 1 & (\frac{2}{3})(\frac{1}{3}) \\ \\[-3mm] 2 & (\frac{2}{3})(\frac{1}{3})^2 \\ \\[-3mm] 3 & (\frac{2}{3})(\frac{1}{3})^3 \\ \vdots & \vdots\end{array}$

$\begin{array}{cccccc}\text{We have:} & E(x) &=& 0(\frac{2}{3}) + 1(\frac{2}{3})(\frac{1}{3}) + 2(\frac{2}{3})(\frac{1}{3})^2 + 3(\frac{2}{3})(\frac{1}{3})^3 + \hdots & [1] \\ \\[-4mm]

\text{Multiply by }\frac{1}{3}\!:& \frac{1}{3}E(x) &=& \qquad\;\;\; 0(\frac{2}{3})(\frac{1}{3}) + 1(\frac{2}{3})(\frac{1}{3})^2 + 2(\frac{2}{3})(\frac{1}{3})^2 + \hdots & [2]\end{array}$

$\text{Subtract [1] - [2]: }\;\tfrac{2}{3}E(x) \;=\;0(\tfrac{2}{3}) + (\tfrac{2}{3})(\tfrac{1}{3}) + (\tfrac{2}{3})(\tfrac{1}{3})^2 + (\tfrac{2}{3})(\tfrac{1}{3})^3 + \hdots$

. . $\text{And we have: }\;\tfrac{2}{3}E(x) \;=\;(\tfrac{2}{3})(\tfrac{1}{3})\underbrace{\bigg[1 + (\tfrac{1}{3}) + (\tfrac{1}{3})^2 +(\tfrac{1}{3})^3 + \hdots \bigg]}_{\text{Geometric series}}$

The geometric series has the sum: . $\frac{1}{1-\frac{1}{3}} \:=\:\frac{3}{2}$

Hence, we have: . $\frac{2}{3}E(x) \;=\;\left(\frac{2}{9}\right)\left(\frac{3}{2}\rig ht) \quad\Rightarrow\quad \frac{2}{3}E(x)\;=\;\frac{1}{3}$

. . Therefore: . $E(x) \;=\;\frac{1}{2}$