Suppose that the sequence $S = (s_0, s_1, \dots )$ is defined by:
$s_0 = 0$, $s_1= 1$ and $s_{n+2} = s_{n+1}+2s_n$ for $n \ge 0$. Thus, $S = (0, 1, 1, 3, 5, 11, 21,...)$.
Show that the generating function $S(x) = s_0 + s_1 x + s_2 x^2 + \dots$ satisfies $S(x) = \frac{x}{1 - x - 2x^2}$.
I would start this problem with $(1,1,1,1,1,1,...) = 1/(1-x)$ and manipulate it until I end up with $S(x) = x/(1-x-2x^2)$, but I don't know how to manipulate it.
There are many ways to do this; here’s the one that I prefer. Start with your recurrence:
$$s_n=s_{n-1}+2s_{n-2}\;.\tag{1}$$
This holds for $n\ge 2$, and in addition you have the initial conditions $s_0=0$ and $s_1=1$. If we assume that $s_n=0$ for all negative integers $n$, $(1)$ also works for $n=0$; it fails only for $n=1$, when it gives $s_1=0$ instead of $s_1=1$. I’ll fix this by adding a term:
$$s_n=s_{n-1}+2s_{n-2}+[n=1]\;,\tag{2}$$
where $[n=1]$ is an Iverson bracket whose value is $1$ if $n=1$ and $0$ otherwise. The modified recurrence $(2)$ gives the correct value for all $s_n$, again on the assumption that $s_n=0$ for $n<0$.
Now multiply $(2)$ by $x^n$ and sum over $n\ge 0$:
$$\begin{align*} \sum_{n\ge 0}s_nx^n&=\sum_{n\ge 0}\left(s_{n-1}+2s_{n-2}+[n=1]\right)x^n\\\\ &=\sum_{n\ge 0}s_{n-1}x^n+2\sum_{n\ge 0}s_{n-2}x^n+\sum_{n\ge 0}[n=1]x^n\\\\ &=x\sum_{n\ge 0}s_{n-1}x^{n-1}+2x^2\sum_{n\ge 0}s_{n-2}x^{n-2}+x\\\\ &=x\sum_{n\ge 0}s_nx^n+2x^2\sum_{n\ge 0}s_nx^n+x\;. \end{align*}\tag{3}$$
Now let $g(x)$ be the generating function: by definition
$$g(x)=\sum_{n\ge 0}s_nx^n\;.$$
From $(3)$ we see that $g(x)=xg(x)+2x^2g(x)+x$, and solving this for $x$ yields
$$g(x)=\frac{x}{1-x-2x^2}\;.$$