You are on page 1of 4

1 Equations

There are two types of math ‘environments’ (styles) in LATEX. The in-line
and display style.

To see an example of in-line:

The inequality $x+y\ge z$ is an example of in-line math.

This line will result in the following

The inequality x + y ≥ z is an example of in-line math.

For display style we use $$....$$. For example:

The other math environment such as equation, align, eqnarray are all
examples of display math style. They all produce numbered equations.
For the unnumbered ones we use equation*, align*, eqnarray*. The
default numbering is 1,2,....

For instance:

Consider the following examples:


\begin{eqnarray}
x&=u\\y&=z
\end{eqnarray}

will produce:

Consider the following examples:

x =u (1.1)
y =z (1.2)

But in order to convert the numbering a line \numberwithin{equation}{section}


was used in the preamble.

1
The inequality $$x+y\ge z$$ is an example of display math.

This will result in the following:

The inequality
x+y ≥z
is an example of display math.

1.1 Cases Environment

\begin{equation}
Y=\begin{cases}
2x,&\text{when } x\geq 0\\
0,&\text{otherwise}
\end{cases}
\end{equation}

The package required is amsmath or mathtools


(
2x, when x ≥ 0
Y = (1.3)
0, otherwise

\begin{equation}
Y=\begin{dcases}
2x,&\text{when } x\geq 0\\
0,&\text{otherwise}
\end{dcases}
\end{equation}

The package reuired is mathtools

(
2x, when x ≥ 0
Y = (1.4)
0, otherwise

2
\begin{equation}
Y=\begin{dcases*}
2x,& when $x\geq 0$\\
0,& {otherwise}
\end{dcases*}
\end{equation}

The package required is mathtools

(
2x, when x ≥ 0
Y = (1.5)
0, otherwise

Equation numbering can be changed to from the default arabic to suit


user’s preferences. E.g., to be numbered within a chapter or a section
by using the command \numberwithin which requires the package amsmath
or mathtools

2 Theorems

\begin{theorem}[Cauchy]\label{thm:1}
If $G$ is a finite group and $p$ is a prime number dividing
the order of $G$ (the number of elements in $G$), then $G$
contains an element of order $p$.
\end{theorem}

Theorem~\ref{thm:1} is widely used in Finite Group Theory.

The following lines are to be included in the preamble:

\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{theorem}{Theorem}[section]

3
The option can be a chapter, subsection, etc. depending on user’s
preferences in numbering of the theorem.

Theorem 2.1 (Cauchy). If G is a finite group and p is a prime number


dividing the order of G (the number of elements in G), then G contains
an element of order p.

Theorem 2.1 is widely used in Finite Group Theory.

You might also like