\documentclass{report}

\usepackage[margin=1.5cm]{geometry}                                   % Defines the margins for the whole document.
%\usepackage{helvet}                                                  % Add the Helvet font
\renewcommand{\familydefault}{\rmdefault}                             % Change default font to serif font family (default)
%\renewcommand{\familydefault}{\ttdefault}                            % Change default font to monospace font family
%\renewcommand{\familydefault}{\sfdefault}                            % Change default font to sans serif font family
\usepackage[T1]{fontenc}                                              % Set the font (output) encoding
\usepackage[french]{packages/language_selector}                       % Allow to the language the document is written to ([french], english)
%\usepackage[autolanguage]{numprint}                                  % for the \nombre command
\usepackage{hyphenat}                                                 % Hyphenation rules
\usepackage{tikz-cd}                                                  % Use for commutative diagram (Category Theory)
\hyphenation{mate-mática recu-perar}
\usepackage{setspace}                                                 % Sets the line spacing.
\setstretch{1.0}
\usepackage{multibib}                                                 % Allow multiple separates bibliography citations
\newcites{annexes}{Annexes}
\langnewcites{references}{Références}{References}
\usepackage[language=\langoption]{lipsum}                             % Command to generate temporary dummy text
\usepackage[ruled,vlined,linesnumbered]{algorithm2e}                  % Add the algorithm environnement
\usepackage[codedark]{packages/themes}                                % Include many colours themes ([default], codedark or dracula)
\pagecolor{theme_colour_background}
\color{theme_colour_foreground}
\usepackage{amsmath}                                                  % Provides command to typeset matrices with different delimiters
\usepackage{listings}                                                 % Add an environnement to highlight code
\usepackage{xargs}                                                    % Allow multiple optional parameters parsing
\usepackage{packages/macros}                                          % Customs macros
\usepackage{graphicx}
\usepackage{makeidx}[intoc]                                           % Make a word index
\usepackage{enumerate}                                                % Allow (1) index for enumerate
\usepackage{paracol}                                                  % The paracol package lets you typeset columns of text in parallel

\usepackage{fontspec}
\setmonofont{FreeMono} % switch to a monospace font supporting more Unicode characters

\setcounter{tocdepth}{5}

\makeindex

\langtitle{Notebook ultime}{Ultimate Notebook}
\author{Pierre Saunders}
%\date{}

\begin{document}

\maketitle

%\renewcommand{\contentsname}{\lang{Sommaire}{Summary}}
\tableofcontents

\langchapter{Préambule}{Stuffings}

\section{Motivations}

Ce carnet est destiné à accueillir mes maigres connaissances de manière digeste, mais intrinsèquement incomplet, imprécis voir erroné. À vous lecteur qui découvre ce carnet, accueillez le davantage comme une liste de connaissances que comme un manuel scolaire.

\langsection{Remerciements}{Thankings}

Je remercie Adel Medjhoub pour nos nombreuses interminables conversations qui on mûrit mes visions du monde.
Je remercie Damien Graux de m'avoir introduit le monde de la recherche ainsi que le langage LaTeX sur laquelle ce carnet est rédigé.

Et de manière honteusement démagogique, je vous remercie tous lecteurs de ce carnet.

\input{contents/latex}
\input{contents/computer_science}
\input{contents/logic}
\input{contents/set_theory}
\input{contents/number_theory}
\input{contents/combinatorics}
\input{contents/algebra}
\input{contents/group_theory}
\input{contents/group_theory_exo}
\input{contents/ring_theory}
\input{contents/algebra_dm1}
\input{contents/algebra_dm2}
\input{contents/trigonometry}
\input{contents/differentiability}
\input{contents/complex_analysis}
\input{contents/differential_equations}
\input{contents/measure_theory}
\input{contents/suites}
\input{contents/fourier}
\input{contents/topology}
\input{contents/topology_exo}
\input{contents/topology_dm1}
\input{contents/dynamic_systems}
\input{contents/category_theory}
\input{contents/GaussianParadigm}
\input{contents/music_theory}
\input{contents/philosophy}
\input{contents/linguistic}
\input{contents/definitions}

\addcontentsline{toc}{chapter}{Références}
\begingroup
	\bibliographystylereferences{IEEEtran}
	\bibliographyreferences{references/references}
\endgroup

\addcontentsline{toc}{chapter}{Annexes}
\begingroup
	\bibliographystyleannexes{IEEEtran}
	\bibliographyannexes{references/annexes}
\endgroup

\printindex

\end{document}
