determining sum of the series given recursively

Let $f(x)=\sum_{n=0}^{\infty}a_nx^n$ where $a_0=1$. Remaining coefficients are determined by

$$e^{-2x}=\sum_{n=0}^{\infty}\bigg(2a_n+(n+1)a_{n+1}\bigg)x^n$$

Now I write

$$e^{-2x}=\sum_{n=0}^{\infty}\frac{2^n(-1)^n}{n!}x^n$$

Obviously both sequences are equal if the coefficients are equal. But if I try to equate them, or try to determine the $a_{n+1}$ in terms of $a_0$ I don't get far. Now I could

$$\sum_{n=0}^{\infty}\bigg(2a_n+(n+1)a_{n+1}\bigg)x^n=2\sum_{n=0}^{\infty}a_nx^n+\sum_{n=0}^{\infty}a_{n+1}x^n+\sum_{n=0}^{\infty}na_{n+1}x^n$$

turn these three sums in terms of $f(x)$ but I get stuck trying to make the last sum because of the $n$ in the way. So how should I try to evaluate the sum $f(x)$? If the latter approach is suitable, how could I rewrite $\sum_{n=0}^{\infty}na_{n+1}x^n$ in terms of $f(x)$? Thanks!

-

Hint: The function $f(x)$ satisfies a simple differential equation.

-

Note that $$\sum_{n=0}^{\infty} a_n x^n = f(x)$$ $$\sum_{n=0}^{\infty} (n+1) a_{n+1} x^n = \dfrac{d}{dx} \left( \sum_{n=0}^{\infty} a_n x^n\right) = \dfrac{df(x)}{dx}$$

-

Does this help?

$$e^{-2x}=\sum_{n=0}^\infty(2a_n+(n+1)a_{n+1})x^n=2\sum_{n=0}^\infty a_nx^n + \frac{d}{dx}\sum_{n=0}^\infty a_n x^n = 2f(x)+f'(x)$$ therefore $2f(x)+f'(x)=e^{-2x}$ with initial condition $f(0)=1$, which one can easily check is satisfied by $f(x)=xe^{-2x}$.

-