4.6 Basic LaTeX formatting

Course subject(s) 4. Reporting your findings

Basic LaTeX formatting

Now you know how to write a report, it is time to learn how you can do this using the LATEX.

We will start with discussing the overall structure of a LATEX document, for which we will use this template: Template_Latex_Report.tex

You need a photo as well for this template: Rainbowfish1000x774.jpg. Download this photo and put it into the same folder as the tex file. That way, Latex will know where to find it.

When you compile this template, the result should be: Template_Latex_Report.pdf.

Note: Always compile your LATEX document three times using PDF-latex, to ensure that all internal references are processed correctly.

In the template you might notice the symbol % plays a special role: It is the LATEX symbol to indicate comments. So everything on a line after a % will not be displayed by LATEX in the compiled document.

Structure of a Latex document

The overall structure of every LATEX document is the same, and must look like this:

\documentclass{...}
...
\begin{document}
...
\end{document}

The preamble are the lines between \documentclass{…} and \begin{document}.

Between \begin{document} and \end{document}, you put the content (i.e. text) of your report.

The preamble

In the preamble you define the following things:

  • The type of document template you will use;
  • The packages you will use in your document. Packages give you the option to use more commands in the document;
  • The (extra) layout options you want;
  • All other stuff that is not the content of your report.
Creative Commons License
Mathematical Modeling Basics by TU Delft OpenCourseWare is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
Based on a work at https://online-learning.tudelft.nl/courses/mathematical-modeling-basics/.
Back to top