0
$\begingroup$

I try to find the formula for the following recurrence relation:

$a_n = 2a_{n-1} + a_{n-2} $

$ a_0 = 1 $

$ a_1 = 3 $

I solve it as follow:

$ a_n - 2a_{n-1} - a_{n-2} = 0 $

$ t^2 - 2t - 1 = 0 $

$ t_1 = 1 - \sqrt{2} $

$ t_2 = \sqrt{2} + 1 $

I need to find values of $A$ and $B$, given the following equations:

$a_0 = A + B = 1$

$a_1 = A(1 - \sqrt{2}) + B(\sqrt{2} + 1) = 3$

Regards.

$\endgroup$
0
$\begingroup$

It is a system of linear equations \begin{cases} &A + &B & = 1\\ (1 - \sqrt{2})& A+ (1+\sqrt{2})&B & = 3 \end{cases}

You can use the so-called method of substiution or method of elimination, or any advanced methods including Cramer's rule, Gaussian elimination, LU factorization.

For example, if we would like to use method of elimination, subtracting $1 - \sqrt{2}$ times the first equation from the second equation we have $$((1+\sqrt{2}) - (1-\sqrt{2}))B = 3 - (1-\sqrt{2})$$ which is $$2\sqrt{2} B = \sqrt{2} + 2$$ and therefore $$B = \frac{1}{2}(1 + \sqrt{2})$$ Finally substituting $B = \frac{1}{2}(\sqrt{2} - 1)$ back to the first equation, we have $$A = \frac{1}{2}(1 - \sqrt{2})$$

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.