# Learning LaTeX

LaTeX is a document preparation system for creating technical and scientific documents. It is especially useful for typesetting logic with its plethora of special symbols. The Logical Theory textbook, as well as most of our lecture notes/slides are all produced using LaTeX.

Writing in LaTeX is much simpler than using a word processor like Word. A LaTeX file is just a plain text file containing the content of your document and a few special commands describing the structure of your document. If you are familiar with basic html or markdown (both used extensively in web design) you will be at home with LaTeX. Feeding this text file to LaTeX will produce a pdf of the document.

# Getting started

Nowadays you can write LaTeX documents on the web without needing to download and install anything. A popular online LaTeX tool is Overleaf.

- Start with the
*Learn LaTeX in 30 minutes*guide. - Learn the interface provided by Overleaf by creating a document in Overleaf.
- The LaTeX Wikibook is an excellant resource for learning about the more advanced features of LaTeX.

# Logic in LaTeX

LaTeX is an excellent tool for typesetting mathematical notation. The basics of this are covered in the *Learn LaTeX in 30 minutes* guide listed above. More functionality is provided through *packages* which is usually as simple as adding `\usepackage{package-name}`

to the preamble of your document (i.e., somewhere above `\begin{document}`

).

- Read the documentation on typesetting mathematics in LaTeX provided by Overleaf. This guide also introduces the mathematics package
`amsmath`

that introduces the most common mathematical symbols, provides better support for equations, and much more. See also the list of further reading provided at the end of the guide and the LaTeX wikibook on using`amsmath`

. - Check out the logic related tips you can find at the LaTeX for Logicians page, ranging from logic-specific symbols to writing truth-tables and proof trees.
- Visit the TeX StackExchange for answers to your LaTeX questions.
- If you need to figure out how to display a particular symbol in LaTeX, detexify is your tool: you just paste or draw the symbol you want and that site will tell you the command.
- See the LaTeX miscellany below our own recommendations.

# Beam your logic with Beamer

At some point you will want to present your labour to others. Beamer is a LaTeX class for creating presentations.

- Learn how to create a presentation in Beamer.
- Use a beamer template to create your own presentation.

# A LaTeX miscellany

There are thousands of LaTeX packages. These can be adding new symbols, new design templates, or new functionality. Here is a brief (and highly personal) recommendation. All of the following are included in the standard LaTeX setup and their documentation is available through the Comprehensive TeX Archive Network (CTAN); simply search for the package name on that site.

## Logic specific

**Alphabets**You can never have too many ‘x’s. The`amsmath`

package implements the caligraphic and fraktur scripts. Use these sparingly: your work is to be read, not framed!**Proof trees**Whether its natural deduction, tableaux or sequent calculus, we all need to typeset a formal proof at somepoint in our lifetime. The LaTeX for Logicians page has a separate entry on typesetting natural deduction proofs with links to different packages. I recommend`ebproof`

and`bussproofs`

. The latter package (and its extension`bussproofs-extra`

) is used in the Open Logic Text.**Automata**The TikZ package provides an extensive (and quite scary) toolkit for building figures and graphics within LaTeX. Search the TeXample database for what you need and adapt from there.

## General packages

- Theorems, lemmas and proofs, oh my! The
`amsthm`

package is the classic. A modern alternative is provided by`thmtools`

. - Internal links. The
`hyperref`

package to the rescue. I recommend the overview in the LaTeX wikibook. To reduce the chance of another package conflictin with`hyperref`

it is recommended to be the*last*package loaded.