% generated by GAPDoc2LaTeX from XML source (Frank Luebeck)
\documentclass[a4paper,11pt]{report}
\usepackage{a4wide}
\sloppy
\pagestyle{myheadings}
\usepackage{amssymb}
\usepackage[latin1]{inputenc}
\usepackage{makeidx}
\makeindex
\usepackage{color}
\definecolor{DarkOlive}{rgb}{0.1047,0.2412,0.0064}
\definecolor{FireBrick}{rgb}{0.5812,0.0074,0.0083}
\definecolor{RoyalBlue}{rgb}{0.0236,0.0894,0.6179}
\definecolor{RoyalGreen}{rgb}{0.0236,0.6179,0.0894}
\definecolor{RoyalRed}{rgb}{0.6179,0.0236,0.0894}
\definecolor{LightBlue}{rgb}{0.8544,0.9511,1.0000}
\definecolor{Black}{rgb}{0.0,0.0,0.0}
\definecolor{FuncColor}{rgb}{1.0,0.0,0.0}
%% strange name because of pdflatex bug:
\definecolor{Chapter }{rgb}{0.0,0.0,1.0}

\usepackage{fancyvrb}

\usepackage{pslatex}

\usepackage[pdftex=true,
        a4paper=true,bookmarks=false,pdftitle={Written with GAPDoc},
        pdfcreator={LaTeX with hyperref package / GAPDoc},
        colorlinks=true,backref=page,breaklinks=true,linkcolor=RoyalBlue,
        citecolor=RoyalGreen,filecolor=RoyalRed,
        urlcolor=RoyalRed,pagecolor=RoyalBlue]{hyperref}

% write page numbers to a .pnr log file for online help
\newwrite\pagenrlog
\immediate\openout\pagenrlog =\jobname.pnr
\immediate\write\pagenrlog{PAGENRS := [}
\newcommand{\logpage}[1]{\protect\write\pagenrlog{#1, \thepage,}}
%% were never documented, give conflicts with some additional packages


\newcommand{\GAP}{\textsf{GAP}}

%% nicer description environments, allows long labels
\usepackage{enumitem}
\setdescription{style=nextline}

\begin{document}

\logpage{[ 0, 0, 0 ]}
\begin{titlepage}
\begin{center}{\Huge \textbf{The \textsf{ThreeKPlusOne} Package\mbox{}}}\\[1cm]
\hypersetup{pdftitle=The \textsf{ThreeKPlusOne} Package}
\markright{\scriptsize \mbox{}\hfill The \textsf{ThreeKPlusOne} Package \hfill\mbox{}}
{Version 42\mbox{}}\\[1cm]
\mbox{}\\[2cm]
{\large \textbf{Dummy Auth{\"o}r  \mbox{}}}\\
\hypersetup{pdfauthor=Dummy Auth{\"o}r  }
\end{center}\vfill

\mbox{}\\
{\mbox{}\\
\small \noindent \textbf{Dummy Auth{\"o}r  } --- Email: \href{mailto://3kplusone@dev.null} {\texttt{3kplusone@dev.null}}}\\
\end{titlepage}

\newpage\setcounter{page}{2}
{\small 
\section*{Copyright}
\logpage{[ 0, 0, 1 ]}
{\copyright} 2000 The Author. 

 You can do with this package what you want.

 Really. \mbox{}}\\[1cm]
\newpage

\def\contentsname{Contents\logpage{[ 0, 0, 2 ]}}

\tableofcontents
\newpage

 
\chapter{\textcolor{Chapter }{The $3k+1$ Problem}}\logpage{[ 1, 0, 0 ]}
\hyperdef{L}{X8769FB038733F6F4}{}
{
  
\section{\textcolor{Chapter }{Theory}}\label{sec:theory}
\logpage{[ 1, 1, 0 ]}
\hyperdef{L}{X8729B87B848E3F89}{}
{
  Let $k \in {\ensuremath{\mathbb N}}$ be a natural number. We consider the sequence $n(i, k), i \in {\ensuremath{\mathbb N}},$ with $n(1, k) = k$ and else $n(i+1, k) = n(i, k) / 2$ if $n(i, k)$ is even and $n(i+1, k) = 3 n(i, k) + 1$ if $n(i, k)$ is odd. 

 It is not known whether for any natural number $k \in {\ensuremath{\mathbb N}}$ there is an $m \in {\ensuremath{\mathbb N}}$ with $n(m, k) = 1$. 

 \textsf{ThreeKPlusOne} provides the function \texttt{ThreeKPlusOneSequence} (\ref{ThreeKPlusOneSequence}) to explore this for given $n$. If you really want to know something about this problem, see \cite{Wi98} or \href{http://mathsrv.ku-eichstaett.de/MGF/homes/wirsching/} {\texttt{http://mathsrv.ku-eichstaett.de/MGF/homes/wirsching/}} for more details (and forget this package). }

 
\section{\textcolor{Chapter }{Program}}\logpage{[ 1, 2, 0 ]}
\hyperdef{L}{X7A4605C07A94C9F6}{}
{
  In this section we describe the main function of this package. 

\subsection{\textcolor{Chapter }{ThreeKPlusOneSequence}}
\logpage{[ 1, 2, 1 ]}\nobreak
\hyperdef{L}{X7B1A31B8870EA092}{}
{\noindent\textcolor{FuncColor}{$\Diamond$\ \texttt{ThreeKPlusOneSequence({\slshape k[, max]})\index{ThreeKPlusOneSequence@\texttt{ThreeKPlusOneSequence}}
\label{ThreeKPlusOneSequence}
}\hfill{\scriptsize (function)}}\\


 This function computes for a natural number \mbox{\texttt{\slshape k}} the beginning of the sequence $n(i, k)$ defined in section \ref{sec:theory}. The sequence stops at the first $1$ or at $n(\mbox{\texttt{\slshape max}}, k)$, if \mbox{\texttt{\slshape max}} is given. 
\begin{Verbatim}[fontsize=\small,frame=single,label=Example]
  gap> ThreeKPlusOneSequence(101);
  "Sorry, not yet implemented. Wait for Version 84 of the package"
\end{Verbatim}
 }

 }

 }

 \def\bibname{References\logpage{[ "Bib", 0, 0 ]}
\hyperdef{L}{X7A6F98FD85F02BFE}{}
}

\bibliographystyle{alpha}
\bibliography{3k+1}

\def\indexname{Index\logpage{[ "Ind", 0, 0 ]}
\hyperdef{L}{X83A0356F839C696F}{}
}


\printindex

\newpage
\immediate\write\pagenrlog{["End"], \arabic{page}];}
\immediate\closeout\pagenrlog
\end{document}
