% From Felix Kwok, SCCM, Nov 30, 2007.
%
% Basically this is a template file -- you should be able to take it and
% start running.  It makes use of the suthesis-2e package from Emma Pease
%     http://help-csli.stanford.edu/tex/suthesis/

% The philosophy behind this template is that each chapter or
% chapterlike section goes in a separate file and you use the \include
% command to input it into the final document.  The \includeonly
% command can be used so you only need to work on one or two chapters
% at a time (instead of having to either latex the entire book each
% time or losing cross-references and page numbering)

% Copy this file and call it something like mythesis.tex

\documentclass[10pt,twoside]{report}

% Note that the documentclass can take other options such as
%   twoside - for double sided printing
%   openright - if double side  chapters always start on odd pages
%   openany - if double side chapters start on the next page even or odd
% 10pt can be replaced by 11pt (or 12pt), but NOTE THAT
% THE REGISTRAR'S OFFICE ACCEPTS THE PARAMETERS SHOWN HERE,
% including \setstretch{1.213}, which seems to be as close
% to single spacing as they allow so far (2007).

\usepackage{suthesis-2e}
\usepackage{amsmath, amsfonts, amsthm,
  verbatim, fancyhdr, graphicx, array,
  color, listings, afterpage, epsfig, boxedminipage}

%% Load other packages you need

%% Uncomment the following and create mythesis-macros.sty for all your
%% own macros.  This keeps this top level file looking fairly neat.
% \usepackage{mythesis-macros}

%% Certain types of theses require special title page format.  See the
%% style file for the full list.  An example would be that for some of
%% the language departments.
% \dualthesis \dept{Asian Languages} \languagemajor{Korean}
%% or education
% \educationthesis

   \title{Scalable Linear and Nonlinear Algorithms
       \\ for Multiphase Flow in Porous Media}
   \author{Wing Hong Felix Kwok}
   \programthesis
   \dept{Scientific Computing and Computational Mathematics}
   \principaladviser{Hamdi Tchelepi}
%  \coprincipaladvisor{}
   \firstreader{Khalid Aziz}
   \secondreader{Michael Saunders}
%  \thirdreader{}

% The following command would (if uncommented) allow only
% chapter1 and chapter2 to be processed
% \includeonly{chapter1,chapter2}

% If you feel real savvy use
% \typein{Now put in includeonly}
% The \typein command stops latex at this point and allows you to type
% in a command such as
%    \includeonly{chapter3,chapter5}
% This can save some time and means you don't have to edit this file
% as much.

\setstretch{1.213}  % SAVE SOME TREES WITH THIS AND 10pt

\begin{document}


% First the preface sections.

% This includes the file preface.tex which should include the
% following commands
% \beforepreface
% \prefacesection{Abstract}
% body of the preface
\include{abstract}

% Any other preface sections

% The last preface section (e.g., acknowledgement.tex)
% should look like
% \prefacesection{Acknowledgement}
% body
% \afterpreface
\include{acknowledgement}


% Now for the body of the thesis, modify the number of these lines as
% needed

% This includes chapter1.tex which should start with a \chapter{...}
% command

\include{chapter1}
\include{chapter3_alt}
\include{chapter2}
\include{chapter4/chapter4}
\include{chapter5/chapter5}
\include{chapter6}

% and the end material

\appendix
\numberwithin{equation}{chapter}
\include{accretive}
\include{cascade-proof}
\include{stone-models}
\include{pres-mats}


% bibliography.tex should include either
\bibliographystyle{plain}
\bibliography{mythesis}
% or some other way of doing the bibliography
% \include{bibliography}

\end{document}
