# Continued fractions

#### math_grl

Ok I need to know which is the right answer for evaluating the continued fraction $$\langle 1, 2, 1, 2, \ldots \rangle$$?

Here's my work:
$$x = 1 + \frac{1}{2+x} \Rightarrow x^2 + x - 3 = 0$$ and by quadratic formula, we get $$x = \frac{-1 \pm \sqrt{13}}{2}$$ but we only want the positive root so I get $$x = \frac{-1 + \sqrt{13}}{2}$$ for my answer but the answer given was $$x = \frac{1 + \sqrt{3}}{2}$$, so I'm confused at which it is....

Moreover, I can't seem to find any other example except for $$\langle 1, 1, 1, \ldots \rangle$$ to see if I'm doing my computation right. Please help.

Related Linear and Abstract Algebra News on Phys.org

#### Petek

Your equation for x is incorrect. It should be

$$1 + \frac{1}{2 + \frac{1}{x}}$$

#### math_grl

that's embarassing.

#### Petek

You'll do better next time!