We use cookies to ensure that we give you the best experience on our website. You can change your cookie settings at any time. Otherwise, we'll assume you're OK to continue.

Department of Mathematical Sciences

Using LaTeX for maths assignments

LaTeX is the de facto standard software to write mathematical reports. It is an add-on to the famous TeX program by Donald Knuth, and gives it a more friendly face. You can use LaTeX to produce book-quality printed technical material that looks infinitely better than things coming out of Word. It also helps you keep track of references to equation numbers, bibliographies and tables of contents automatically. It handles graphics, too.
The sooner you learn LaTeX, the better. You will need it for various modules, among which Mathematical Modelling II as well as Project III/IV. This page is meant to give you a quick start, and answer some frequently asked questions specific to the modules in Durham. There is loads of additional information on the web; see the links below.

Quick overview

In practise, you edit LaTeX documents by typing them into a text editor. LaTeX documents are ordinary text files, spiced up with instructions to tell LaTeX about sections, special mathematical symbols, references and so on.
A typical LaTeX file (saved with extension .tex) looks like
The text goes here...
More text goes here...
The emphasis is thus on structure, not presentation. In order to produce a nicely looking PDF file from this, you feed it through LaTeX to produce demo.pdf.
To see what else LaTeX (and the underlying TeX software) can do, take a look at the TeX showcase or a similar list of beautiful typography with TeX on tex exchange.

On DUDE computers

In the university computer classrooms, click the 'App Hub' icon. Search for, or browse to, 'LaTeX', and start.

(If you use the magnifying glass in the bottom left corner, then search for 'latex', you will have the option of starting 'Latex - Miktex Texworks'. However, this may or may not hang your machine, depending on the sign of the moon and the current eur/gbp exchange rate.)

A window will open in which you can edit your LaTeX source. To preview or generate a PDF for printing, click the green arrow icon on the very top left. The first time you do this, this will take a long time, and will ask several times for permission to install additional packages. Confirm those requests. Subsequent runs (on the same machine) will be fast.

Important: when saving or loading your files, you need to navigate to the relevant folder by first going to your J: drive. Do not navigate via shortcuts or via implicit shortcuts such as 'Desktop'. If you do not follow this advice, LaTeX will not find figure files or style files which are stored in the same folder.

On your own computer

For a standard LaTeX setup in which you edit your .tex files with a text editor and then run them through LaTeX to produce a PDF file, select one of the options below:

  • On Windows, it is recommended to install MiKTeX, available from
  • On macOS or OS X, install
  • On Linux, all distributions come with some version of LaTeX; look for the texlive package.

There are also graphical frontends with WYSIWYG functionality, which may appeal to some people,

Online in the cloud

Finally, it is possible to use LaTeX directly in your browser, without installing any software at all, by using one of the following online LaTeX services.

Learning LaTeX

There are various books available with introductions to LaTeX, some of which are available in the Durham University library. However, there is plenty available online as well. An excellent introduction is the Not so short introduction to LaTeX.

If you are stuck with a particular problem, the following may be more useful than old-fashioned books:

  • The LaTeX cheat sheet.
  • The TeX stackexchange site, a question-and-answer type of site with very concrete help for concrete problems.
  • There is a TeX FAQ, which contains a lot of information but not always geared at the beginner.
  • A cool visual FAQ.
  • Wikipedia of course has pages for both TeX and LaTeX.

Samples and templates

A number of sites carry LaTeX template files which can get you started quickly:

  • LaTeXtemplates has high quality templates for anything from CVs to posters to books, including previews so you can quickly decide which one is right for you.
  • Overleaf has its own section of template files which you can use even if you do not use the Overleaf service.
  • A similar service is provided by ShareLaTeX's template files.
  • has a small number of relatively simple templates.

Add-on packages

The power of LaTeX lies in its huge number of add-on packages, which do literally anything from typesetting music to chessboard, calendars and a wide variety of other things. Most LaTeX distributions (like the ones listed above) come with the most commonly used packages pre-installed, but if you are adventurous you may want to delve into the Comprehensive TeX Archive (CTAN). There is also a lot more on the LaTeX project site.