1

I just started using Latex and I'm writing my end-of-study thesis. I have been writing chapters and sections and updating my table of content to structurize my work and make it easier. I have also Divided everything into separate tex files and just use \input whenever I need to input that file.

I have met a few problems but the most annoying one that I tried with for a while and It didn't work is that The chapters/sections numbering is messed up. This is an extract of my code:

\begin{document}
\frontmatter
\maketitle
\newpage
\include{Remerciement/dedicace}
\newpage
\include{Remerciement/remerciement}
\newpage
\tableofcontents

\chapter{List of figures}

\chapter{Glossary}
\input{Glossary}

\chapter{General Introduction}
\blindtext[4]
\pagenumbering{arabic}

\chapter{Project Context}
\input{I.Project context/Project Context}

\chapter{Theoretical Concepts and State-of-the-art}
\input{II.Theoretical Concept and state of the art/stateofArt}

\chapter{proposed solution}
\input{III.Proposed Solution/ProposedSolution}
\chapter{Results and Discussion}
\input{IV.Results and discussion/Results}
\chapter{Bibliography}
\input{Bibliography}

\pagestyle{fancy}
\fancyhf{}

\end{document}


This is an example of the first chapter tex file:

{\fontfamily{qtm}\selectfont

\addcontentsline{toc}{section}{Introduction}
\section*{Introduction}
\blindtext[1]

\vspace{1cm}

\section{Host Company Presentation}
\subsection{Lindt Presentation}
\input{I.Project context/Host Company presentation/Lindt/Lindt presentation}\newpage
\subsection{SOPP Presentation}
\input{I.Project context/Host Company presentation/SOPP/SOPP Presentation}\newpage
\subsection{STIR Presentation}
\input{I.Project context/Host Company presentation/STIR/STIR presentation}\newpage


\section{Project Overview}
\subsection{Project Frame}
\input{I.Project context/Project Overview/Project Frame/Project Frame}
\subsection{Problem and issues faced}
\subsection{Existing Solution and limitations}
\subsection{Proposed solution}

\section{Project Schedule}
}

This is how the Table of contents ends up looking : enter image description here

Any one knows what I did wrong or how I can fix it? I want chapters to have Roman numbers on them and section numbering to reset every chapter.

2
  • Please write a minimal working example. See link for more details what it means.
    – user202729
    Dec 22, 2021 at 16:09
  • Have you tried running another pass of LaTeX?
    – user202729
    Dec 22, 2021 at 16:10

1 Answer 1

0

I dont see \mainmatter to begin your document after ToC, Introduction, List of figures, etc. I think this is the cause of the lack of chapter numbers.

1
  • well, I didn't even know that I needed to use that. like I said I'm new to Latex. It seems to be working fine now. thank you very much Dec 23, 2021 at 9:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .