\documentclass[12pt]{amsart}
\usepackage{amsthm}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage[all]{xy}
\usepackage{graphicx}
\usepackage[left = 1 in,top = 1 in, bottom=1in,right=1in]{geometry}
\begin{document}

\newcommand{\Q}{{\mathbb Q}}
\newcommand{\C}{{\mathbb C}}
\newcommand{\Z}{{\mathbb Z}}
\newcommand{\F}{{\mathbb F}}
\newcommand{\N}{{\mathbb N}}
\newcommand{\R}{{\mathbb R}}

\newtheorem{theorem}{Theorem}[section] % (If you want theorem
\newtheorem{lemma}[theorem]{Lemma} % with section
\newtheorem{corollary}[theorem]{Corollary} % goes for lemmas,
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{conj}[theorem]{Conjecture}
\newtheorem*{example}{Example}
\newtheorem{question}[theorem]{Question}
\newtheorem*{theoreme}{Th\'eor\`eme}
\newtheorem{remark}[theorem]{Remark}

\numberwithin{equation}{section}


\title{Periodic Continued Fractions}

\author{ Jordan SCHETTLER}

\maketitle

\noindent {\bf Abstract.} \textit{The goals of this project are to have the reader explore some of the basic properties of continued fractions and prove that $\alpha \in \R$ is a quadratic irrational iff $\alpha$ is equal to a periodic continued fraction.}

\section{Finite Continued Fractions}

Fix $s=(a_0, (a_1, \ldots, a_n))\in \Z \times \N^n$. The \textbf{finite (simple) continued fraction} of $s$ is defined as
\[[s]=[a_0; a_1, \ldots, a_n] = a_0+\frac{1}{a_1 + \displaystyle{\frac{1}{a_2 + \cdots + \displaystyle{\frac{1}{a_n}} }} },\]
and if $n \geq k \in \N_0$, the $k$th \textbf{convergent} $c_k$ of $s$ %and $k$th \textbf{remainder} $r_k$ of $s$ are
is taken as $c_k = [a_0; a_1, \ldots, a_k]$. %\hspace{0.5 in} \mbox{and} \hspace{0.5 in} r_k = [a_k; a_{k+1}, \ldots, a_n].\]
Prove that $k \in \{0, \ldots, n\} \Rightarrow$
\begin{equation}\label{1.1}
c_k = \frac{p_k}{q_k}
\end{equation}
where $p_0 = a_0$, $p_1 = a_0a_1+1$, $q_0=1$, $q_1=a_1$, and
\begin{eqnarray}
p_m &=& a_mp_{m-1}+p_{m-2}, \\
q_m &=& a_mq_{m-1}+q_{m-2}
\end{eqnarray}
for all $m \in \{2, \ldots, n\}$. Next, use \ref{1.1} and the definitions of $p_m, q_m$ to show that
\begin{equation}\label{1.2}
c_{k-1}-c_k=\frac{(-1)^k}{q_kq_{k-1}}
\end{equation}
for all $k \in \{1, \ldots, n\}$ (Hint: Subtract $q_{m-1}$ times 1.2 from $p_{m-1}$ times 1.3.). Now employ \ref{1.2} to conclude
\begin{equation}\label{1.3}
c_0 \leq c_2 \leq c_4 \leq \ldots \leq [s] \leq \ldots \leq c_5 \leq c_3 \leq c_1.
\end{equation}
Also, use \ref{1.2} again to demonstrate that $(p_k,q_k)=1$ for all $k \in \{0, \ldots, n\}$.

\section{Infinite Continued Fractions}

Fix $t=(a_0, (a_1, a_2, \ldots)) \in \Z \times \N^{\infty}$ and extend the definitions of $c_k, p_k, q_k$ to all $k \in \N_0$. Prove that the limit (called the \textbf{infinite (simple) continued fraction} of $t$)
\[\lim_{k \rightarrow \infty} c_k = [t] = [a_0; a_1, a_2, \ldots] = a_0+\frac{1}{a_1 + \displaystyle{\frac{1}{a_2 + \displaystyle{\frac{1}{a_3+ \cdots}} }} }\]
exists as follows: First, note that \ref{1.3} implies the limits $\lim_{k \rightarrow \infty} c_{2k}, \lim_{k \rightarrow \infty} c_{2k+1}$ exist by the monotone convergence theorem. Next, argue it's enough to show these limits are equal, which amounts to proving $q_{2k+1}q_{2k} \rightarrow \infty$ as $k \rightarrow \infty$ by \ref{1.2}. Lastly, complete the proof by establishing the estimate $q_k \geq k$ for all $k \in \N_0$.

Now show that $[t] \notin \Q$. Suppose $[t] = n_0/d_0$ for some $n_0,d_0 \in \Z$ with $d_0>0$. Obtain a contradiction by showing that for each $k \in \N_0$ there are $n_k,d_k \in \Z$ such that $r_k=n_k/d_k$ and $d_0 > d_1 > \ldots > d_{k-1} > d_k > 0$ where $r_k$ is the $k$th \textbf{remainder} of $t$ defined as $r_k=[a_k; a_{k+1}, a_{k+2}, \ldots]$.

Next, fix $\alpha \in \R \backslash \Q$. Let $a'_0 = \left\lfloor \alpha \right\rfloor \in \Z$ be the greatest integer less than or equal to $\alpha$. Then $\alpha - a'_0 > 0$ since $\alpha \notin \Q$, so one may define $a'_1 = \left\lfloor (\alpha - a'_0)^{-1} \right\rfloor \in \N$. Likewise, $(\alpha - a'_0)^{-1} - a'_1 > 0$, so one may define $a'_2 = \left\lfloor ((\alpha - a'_0)^{-1} - a'_1)^{-1} \right\rfloor \in \N$. Iterating this process gives a sequence $t' = (a'_0,(a'_1, a'_2, \ldots)) \in \Z \times \N^{\infty}$. Deduce that $\alpha = [t']$ (Hint: Let $c'_k$ denote the $k$th convergent of $t'$ and observe that by construction $\alpha > c'_{2k}$ and $\alpha < c'_{2k+1}$ for all $k \in \N_0$, so the result follows by the squeeze theorem). Finally, prove $[t]=[t'] \Rightarrow t = t'$. Thus all real irrational numbers are equal to the infinite (simple) continued fraction of a uniquely determined sequence in $\Z \times \N^{\infty}$.

\section{Characterization of Quadratic Irrationals}

Fix $t = (a_0, (a_1, a_2, \ldots)) \in \Z \times \N^{\infty}$ as above and denote its convergents and remainders as before by $c_k=p_k/q_k$ and $r_k$, respectively. Use the relation $r_k = (r_{k-1} - a_{k-1})^{-1}$ for all $k \in \N$ to prove the following lemma.

\bigskip

\noindent \textbf{Lemma.} $2 \leq k \in \N \Rightarrow$
\begin{equation*}
[t] = \frac{r_kp_{k-1}+p_{k-2}}{r_kq_{k-1}+q_{k-2}}.
\end{equation*}

\bigskip

We say that $[t]$ is a \textbf{periodic continued fraction} iff there are $m,n \in \N$ such that $m \leq k \in \N \Rightarrow a_k = a_{k+n}$; this is a well-defined notion by uniqueness. Also, we say that $\alpha$ is a \textbf{quadratic irrational} iff $\alpha \in \R \backslash \Q$ and $\alpha$ is the root of a quadratic polynomial with integer coefficients. Somewhat surprisingly, these concepts are related in the same way that repeating decimal expansions are related to rationality; in particular, we have the following theorem. Fill in the details of the proof.

\bigskip

\noindent \textbf{Theorem.} \textit{$\alpha \in \R$ is a quadratic irrational iff $\alpha$ is equal to a periodic continued fraction.}


\begin{proof}
($\Rightarrow$) Suppose $\alpha \in \R$ is a quadratic irrational. Then we've seen that $\alpha$ is equal to the infinite continued fraction of a uniquely determined sequence in $\Z \times \N^{\infty}$, so wlog $\alpha = [t]$. Also, there are $a,b,c \in \Z$ such that $a\alpha^2 + b\alpha+c=0$. An application of the above lemma and a tedious calculation shows that $2\leq k \in \N \Rightarrow A_kr_k^2+B_kr_k+C_k=0$ where $A_k, B_k, C_k \in \Z$ with
\begin{eqnarray}
A_k = C_{k+1} &=& \alpha p_{k-1}^2 + b p_{k-1}q_{k-1}+cq_{k-1}^2, \\
B_k^2-4A_kC_k &=& b^2 - 4ac.
\end{eqnarray}
In addition, utilizing the lemma again along with 1.2, 1.3, and \ref{1.2}, gives that $3 \leq k \in \N \Rightarrow$
\[\left|\alpha-\frac{p_{k-1}}{q_{k-1}}\right| = \frac{r_{k-1}-a_{k-1}}{(r_{k-1}q_{k-2}+q_{k-3})q_{k-1}} < \frac{1}{q_{k-1}^2}.\]
Thus by taking $\delta_{k-1}=p_{k-1}q_{k-1}-\alpha q_{k-1}^2$ for $3 \leq k \in \N$ we have $p_{k-1} = \alpha q_{k-1}+\delta_{k-1}/q_{k-1}$ with $|\delta_{k-1}|<1$, so 3.1 implies
\begin{equation}\label{3.2}
|A_k| = |C_{k+1}| = \left| 2a\alpha \delta_{k-1} + a\frac{\delta_{k-1}^2}{q_{k-1}^2} + b\delta_{k-1} \right| < 2|a\alpha|+|a|+|b|<\infty.
\end{equation}
Hence $|\{(A_k, B_k, C_k)| 2 \leq k \in \N\}| < \infty$ since \ref{3.2} shows $A_k, C_k$ are bounded sequences of integers and, consequently, 3.2 shows $B_k$ is a bounded sequence of integers. Therefore $|\{r_k | k \in \N\}|< \infty$, so there are $m, n \in \N$ such that $r_m = r_{m+n}$, giving $a_k = a_{k+n}$ whenever $m \leq k \in \N$.

($\Leftarrow$) Conversely, suppose $\alpha = [t]$ is a periodic continued fraction, so $\exists m,n \in \N$ such that $m \leq k \in \N \Rightarrow a_k = a_{k+n}$. It follows that $m \leq k \in \N \Rightarrow r_k = r_{k+n}$, so by the lemma we have
\[\frac{r_mp_{m-1}+p_{m-2}}{r_mq_{m-1}+q_{m-2}} = \frac{r_mp_{m+n-1}+p_{m+n-2}}{r_mq_{m+n-1}+q_{m+n-2}},\]
whence $r_m$ is a quadratic irrational since we know infinite continued fractions are irrational from the previous section. On the other hand, the reciprocal of a quadratic irrational is a quadratic irrational and the sum of an integer plus a quadratic irrational is a quadratic irrational, so $r_{m-1}$ is a quadratic irrational. Inductively, $[t]=r_0$ is a quadratic irrational.
\end{proof}

By the theorem we know that
\[\phi = 1+\frac{1}{1 + \displaystyle{\frac{1}{1 + \displaystyle{\frac{1}{1+ \cdots}} }} }\]
is a quadratic irrational; in this case, it's easy to see that $\phi = \frac{1+\sqrt{5}}{2}$ is the golden ratio. Recall that $F_n = [\phi^n-(1-\phi)^n]/\sqrt{5}$ for all $n \in \N_0$ where $F_n$ is the $n$th Fibonacci number defined recursively by $F_0 = 0$, $F_1 = 1$, and $F_n = F_{n-1}+F_{n-2}$ for $n \geq 2$. Less trivially, the theorem also shows that the continued fraction constant $C$ given by
\[C= 0+\frac{1}{1 + \displaystyle{\frac{1}{2 + \displaystyle{\frac{1}{3+ \cdots}} }} }\]
is either transcendental or algebraic of degree greater than or equal to 3. In general, however, infinite continued fractions are rather mysterious animals and there are no analogous characterizations for transcendentals or algebraic numbers of degree higher than 2, although there are beautiful non-simple continued fraction expansions for transcendentals as well as the approximations $\gamma \approx [0, 1, 1, 2, 1, 2, 1, 4]$, $e \approx [2,1,2,1,1,4,1,1]$, and $\pi \approx [3, 7, 15, 1, 292, 1, 1, 1]$ where $\gamma$ is Euler's constant. Moreover, as of the early 21st century not one (simple) continued fraction expansion has yet been completely determined for any numbers other than rationals and quadratic irrationals. So little is known, in fact, that deciding whether or not the elements of the infinite continued fraction of $\sqrt[3]{2}$ are bounded would be a major discovery.

\bibliographystyle{plain}
\begin{thebibliography}{7}

\bibitem{1} G.H. Hardy and E.M. Wright, \textit{An Introduction to the Theory of Numbers}, 5th ed., Oxford University Press, Oxford, 2000.

\bibitem{2} A.Ya. Kinchin, \textit{Continued Fractions}, Dover, Mineola, 1997.

\end{thebibliography}

\end{document}