# Thread: Another exponential generating function

1. ## Another exponential generating function

I am stuck on the following problem, perhaps one of the fine experts can show me the error of my ways?

Use an EGF to solve the recurrence relation $\displaystyle a_{0}=2$ and $\displaystyle a_{n}=na_{n-1}-n!$ for $\displaystyle n\geq1$.

$\displaystyle \sum_{n\geq1}\frac{a_{n}x^{n}}{n!}=\sum_{n\geq1}\f rac{na_{n-1}x^{n}}{n!}-\sum_{n\geq1}\frac{n!x^{n}}{n!}$

$\displaystyle E(x)-2=xE(x)-\frac{1}{1-x}+1$

$\displaystyle E(x)(1-x)=\frac{-1}{1-x}+3=-\frac{1+3-3x}{1-x}$

$\displaystyle E(x)=-\frac{4-3x}{(1-x)^{2}}=\frac{A}{1-x}+\frac{B}{(1-x)^{2}};$ A=-3 B=-1

$\displaystyle E(x)=\frac{-1}{(1-x)^{2}}-\frac{3}{1-x}$

I cannot come up with the solution, any hints, nudges?
Anyone want to give me a push in the right direction or perhaps off a cliff?

2. Is it $\displaystyle \frac{-1}{(1-x)^2}$ that's the bothering you?

If so, differentiate $\displaystyle \frac{1}{1-x} = \sum_{i=0}^{\infty} x^i$
to find a series for $\displaystyle \frac{1}{(1-x)^2}$ .

(I haven't checked your intermediate steps.)

3. A should have been +3 instead of -3. Just an arithmetic mistake.