Programming Languages

LaTeX Beginner's Guide

LaTeX Tutorials

There are a number of decent resources to learn the syntax and basics of LaTeX throughout the web:

The material here is intended to provide a specific introduction to the LaTeX commands and other information you’ll need when completing written assignments for this course. This is by no means a comprehensive introduction to LaTeX; make sure to ask questions if you have trouble or if something goes wrong.

The Basics

Here are a few basics you should know in preparing to work on your LaTeX documents.

Useful Symbols

The following is a list of symbols which are useful in this course.

If you’re having trouble finding the right command for a particular symbol, try using DeTeXify, a tool that allows you to draw the symbol and get suggestions for commands to use.

Useful Commands

Useful Environments

Environments in LaTeX are opened by the \begin command and closed by the \end command. For instance,


puts the text inside of an environment that centers it on the page. The following environments are of particular note in this course:

Inference Rules

In the homeworks in this course, the \ir command creates inference rules. We write \ir[rulename]{premises}{conclusions} to display a rule. To separate premises from each other, we use the command \\. To write full proofs, we can nest the \ir commands.

The \ir commands must appear in math mode, preferably inside of a mathpar environment.

For instance,

\ir[Rule 2]{
  \ir[Rule 1]{
  \ir[Rule 3]{

creates a proof of \(z\) by Rule 2, which relies on proofs of \(x\) and \(y\) given by the axioms Rule 1 and Rule 3.