%% ==============================================================================
%% SI3 Reference Manual
%% ==============================================================================


%% Preamble
%% ==============================================================================

%% Document layout
\documentclass{book}

%% Custom style (.sty)
\usepackage{../../styles/NEMO}
\hypersetup{
  pdftitle={SI³ – Sea Ice modelling Integrated Initiative – The NEMO Sea Ice engine},
  pdfauthor={NEMO Sea Ice Working Group},
  colorlinks
}

%% Include references and index for single subfile compilation
\newcommand{\biblio}{\bibliography{../main/SI3_manual}}
\newcommand{\pindex}{\printindex}

\makeindex

%% End of common preamble between main and sub-files
\begin{document}

%% Override custom cmds for full manual compilation
\renewcommand{\biblio}{}
\renewcommand{\pindex}{}


%% Frontmatter
%% ==============================================================================

\graphicspath{{../../figures/logos/}}

%% Frontpage
\title{
  \includegraphics[height=0.05\textheight]{CMCC}\hfill
  \includegraphics[height=0.05\textheight]{CNRS}\hfill
  \includegraphics[height=0.05\textheight]{MOI} \hfill
  \includegraphics[height=0.05\textheight]{UKMO}\hfill
  \includegraphics[height=0.05\textheight]{NERC}       \\
  {\Huge SI$^3$ \\}
  {\Large Sea Ice modelling Integrated Initiative -- The NEMO Sea Ice engine}\\ 
  {\small \textcolor{red}{First draft documentation. Needs completion and rewriting}.}
}
\author{The NEMO Sea Ice Working Group
%  \thanks{
%
%  }                                                        \\
  \textit{Issue 27, Notes du P\^{o}le de mod\'{e}lisation} \\
  \textit{Institut Pierre-Simon Laplace (IPSL)}            \\
  \textit{ISSN 1288-1619}
}
\date{\today}

\maketitle
\frontmatter

%% ToC i.e. Table of Contents
\dominitoc
\tableofcontents


%% Mainmatter
%% ==============================================================================

\mainmatter

\graphicspath{{../../figures/SI3/}}

\subfile{../subfiles/todolist}

%% Abstract - Foreword

\subfile{../subfiles/abstract_foreword}

% Introduction

\subfile{../subfiles/introduction}

% Chapters

\subfile{../subfiles/chap_model_basics}

\subfile{../subfiles/chap_domain}

\subfile{../subfiles/chap_dynamics}

\subfile{../subfiles/chap_transport}

\subfile{../subfiles/chap_ridging_rafting}

\subfile{../subfiles/chap_radiative_transfer}

\subfile{../subfiles/chap_thermo}

\subfile{../subfiles/chap_interfaces}

\subfile{../subfiles/chap_output_diagnostics}

\subfile{../subfiles/chap_single_category_use}

\subfile{../subfiles/chap_bdy_agrif}

\subfile{../subfiles/chap_miscellaneous}

%% Appendix

%\appendix
%% Backmatter
%% ==============================================================================

\backmatter

%% Bibliography
\cleardoublepage
\phantomsection
\addcontentsline{toc}{chapter}{Bibliography}
\bibliography{../main/SI3_manual}
%\bibliography{/Users/ioulianikolskaia/Boulot/LIBRARY/BIBTEX/Martin_biblio.bib} 

%% Index
\cleardoublepage
\phantomsection
\addcontentsline{toc}{chapter}{Index}
\printindex

\end{document}
