Find the value of the periodic continued fraction with given terms 
Find the value of the periodic continued fraction with the terms
  $1, 3, 4, 3, 2, 3, 4, 3, 2, 3, 4, 3, 2, . . .$

We see that it starts to be periodic after $1$, i.e, $3,4,3,2$ then  $3,4,3,2$ etc...
I know that $x= \frac{A_{k+1}}{B_{k+1}}$ = $\frac{A_{k-1}+x.A_K}{B_{k-1}+x.B_K}$ where $q_{k+1}=x$
I have $$x={3+\cfrac{1}{4+\cfrac{1}{3+\cfrac{1}{2+\cfrac{1}{x}}}}}$$ for the periodic part.  If I use my formula to compute the right-hand side, I will end up with a quadratic in $x$.  Solving for $x$ gives me the following quadratic formula: $5x^2-14x-7=0$, then I did $1+\frac1x$ to find the whole continued fraction, and I got the same quadratic equation. Is this correct?
 A: Yes, you're right. We have $5x^2-14x-7=0$. This is the answer.
\begin{eqnarray}
x&=&3+\dfrac{1}{4+\dfrac{1}{3+\dfrac{1}{2+\dfrac{1}{x}}}}\\
&=&3+\dfrac{1}{4+\dfrac{1}{3+\dfrac{1}{\dfrac{2x+1}{x}}}}\\
&=&3+\dfrac{1}{4+\dfrac{1}{3+\dfrac{x}{2x+1}}}\\
&=&3+\dfrac{1}{4+\dfrac{1}{\dfrac{6x+3}{2x+1}+\dfrac{x}{2x+1}}}\\
&=&3+\dfrac{1}{4+\dfrac{1}{\dfrac{7x+3}{2x+1}}}\\
&=&3+\dfrac{1}{4+\dfrac{2x+1}{7x+3}}\\
&=&3+\dfrac{1}{\dfrac{28x+12}{7x+3}+\dfrac{2x+1}{7x+3}}\\
&=&3+\dfrac{1}{\dfrac{30x+13}{7x+3}}\\
&=&3+\dfrac{7x+3}{30x+13}\\
&=&\dfrac{90x+39}{30x+13}+\dfrac{7x+3}{30x+13}\\
&=&\dfrac{97x+42}{30x+13}\\
\end{eqnarray}
Now we have
\begin{eqnarray}
x&=&\dfrac{97x+42}{30x+13}\iff\\
30x^2+13x&=&97x+42\iff\\
30x^2-84x-42&=&0\iff\\
5x^2-14x-7&=&0
\end{eqnarray}
Solving this equation we have
$$x_{1,2}=\dfrac{14\pm\sqrt{56}}{10}=\dfrac{14\pm 2\sqrt{14}}{10}=\dfrac{7}{5}\pm \dfrac{1}{5}\sqrt{14}.$$
A: if we take $u=x+1,$ we find that u > 2 has purely periodic c.f. $(2,3,4,3).$
Next
$$
\left(
\begin{array}{cc}
2 & 1 \\
1 & 0 \\
\end{array}
\right)
\left(
\begin{array}{cc}
3 & 1 \\
1 & 0 \\
\end{array}
\right)
\left(
\begin{array}{cc}
4 & 1 \\
1 & 0 \\
\end{array}
\right)
\left(
\begin{array}{cc}
3 & 1 \\
1 & 0 \\
\end{array}
\right) =
\left(
\begin{array}{cc}
7 & 2 \\
3 & 1 \\
\end{array}
\right)
\left(
\begin{array}{cc}
13 & 4 \\
3 & 1 \\
\end{array}
\right) =
\left(
\begin{array}{cc}
97 & 30 \\
42 & 13 \\
\end{array}
\right)
$$
Then
$$  u = \frac{97u+30}{42u + 13}  $$
gives
$$ 42u^2 + 13 u = 97 u + 30 $$
or
$$  7 u^2 - 14 u - 5 = 0. $$
Since $u > 0,$
$$  u = \frac{7 + 2 \sqrt{21}}{7} = 1 + \frac{ 2 \sqrt{21}}{7} $$
and $x=u-1$ is
$$ x = \frac{ 2 \sqrt{21}}{7} $$
