Given a sequence $\{x_n\}$ where $x_n = 2x_{n-1} + 3x_{n-2}$ how can one express it in terms of ${x_0, x_1, n}$. Can this be generalized for ${x_n = \alpha x_{n-1} + \beta x_{n-2}}$
I've tried to use the following approach: $$\eqalign{ & 1x_0 = x_01 \\ & zx_1 = x_1z \\ & z^2x_2 = (2x_1 + 3x_0)z^2 \\ & z^3x_3 = (2x_2 + 3x_1)z^3 \\ & z^4x_4 = (2x_3 + 3x_2)z^4 \\ & ... \\ & z^nx_n = (2x_{n-1} + 3x_{n-2})z^n }$$
Then sum LHS with RHS which will produce:
$${ x_0 + \sum\limits_{k = 1 }^na_nz^n = x_0 +zx_1 + 2\sum\limits_{k = 2}^nx_{n-1}z^n + 3 \sum\limits_{k = 2}^n x_{n-2}z^n }$$
Let $${ G(z) = x_0 + \sum\limits_{k = 1 }^na_nz^n }$$
Then RHS may be expressed in terms of ${G(z)}$. For example $${ 2\sum\limits_{k = 2}^na_{n-1}z^n = 2z\sum\limits_{k = 2}^na_{n-1}z^{n-1} = 2z(\sum\limits_{k = 1}^na_{n}z^{n} + x_0 - x_0) = 2z(G(z) - x_0) }$$
Applying those transformations I eventually got ${G(z)}$ expressed in terms of z and ${x_1, x_0}$. But at this point I got stuck.
I got a sum of fractions: $${ \frac{3x_0 - x_1}{4(1+z)}+\frac{x_0+x_1}{4(1-3z)} }$$
I guess i could expand the fractions into series and find their sum, but i am not supposed to know about such expansions at the point of the book i took the problem from.
All of the above feels like a wrong approach. So the question is whether this can be done in a more elegant way.
Solving recurrence relations is actually very similar to solving ODEs. For simplicity, lets stick with the general second order recurrence relation
$$a_n=\alpha a_{n-1}+\beta a_{n-2}$$
Firstly, observe that if $a_n=f(x_0,x_1,n)$ and $a_n=g(x_0,x_1,n)$ are both solutions, then $a_n=(f+g)(x_0,x_1,n)$ is also a solution.
Now, we guess the solution $a_n=\lambda^n$ for some constant $\lambda$ to be determined. Plugging this in:
\begin{align} \ & a_n=\alpha a_{n-1}+\beta a_{n-2} \\ \ \implies & \lambda^n=\alpha \lambda^{n-1}+\beta \lambda^{n-2} \\ \ \implies & \lambda^2-\alpha\lambda-\beta=0 \end{align}
i.e. $\lambda$ is a root to this quadratic. Let the two roots of this quadratic be $\lambda_1$ and $\lambda_2$. Then the general solution would be
$$a_n=A\lambda_1^n+B\lambda_2^n$$
where the constants $A$ and $B$ are to be determined by the initial conditions. As per your question with the general case, if $a_0=a_0$ and $a_1=a_1$, then we have
$$a_0=a_0 \implies a_0=A+B$$
$$a_1=a_1 \implies a_1=A\lambda_1+B\lambda_2$$
and we solve for $A$ and $B$ from here.
In your example where you had the recurrence relation
$$a_n=2a_{n-1}+3a_{n-2}$$
By guessing the solution $a_n=\lambda^n$, we arrive at the quadratic
$$\lambda^2-2\lambda-3=0$$
giving the roots $\lambda_1=3$ and $\lambda_2=-1$. Thus, the general solution is
$$a_n=A\cdot 3^n+B\cdot (-1)^n$$
Plugging in $n=0$ and $n=1$, we get
$$a_0=A+B \qquad a_1=3A-B$$
Hence $A=\frac{a_0+a_1}{4}$ and $B=\frac{3a_0-a_1}{4}$, giving
$$a_n=\frac{a_0+a_1}{4}\cdot 3^n+\frac{3a_0-a_1}{4}\cdot (-1)^n$$