Skip to content

Math

All the symbols can be found here.

Inline

For inline structure, the equation needs to be enclosed within $ delimiter.

$\int_a^b f^{\prime}(x)dx = f(x)$

And it produces result: \(\int_a^b f^{\prime}(x)dx = f(x)\)

Block

These equations take the whole line.

With Equation Numbers

\begin{equation}
    \int_a^b f^{'}(x)dx = f(x)
\end{equation}

Pasted image 20240402232017.png

Equation with equation number

Without Equation Numbers

Similar to inline version, the equation needs to be enclosed within $$ delimiters.

$$\int_a^b f^{\prime}(x)dx = f(x)$$

Produces the result:

\[\int_a^b f^{\prime}(x)dx = f(x)\]

Alternatively, you can use

\usepackage{amsmath}

\begin{equation*}
% Equation here
\end{equation*}

Structures

When only one character is required for argument to a command, there is no need for \(\{\}\).

Fractions

\frac{numerator}{denominator}

Example

\frac{1}{2}
% or \frac 1 2

Produces:

\[\frac 1 2\]

Matrices

\begin{matrix}
    1 & 0\\ % \\ is used for new line
    0 & 1
\end{matrix}

Produces:

\[ \begin{matrix} 1 & 0\\ 0 & 1 \end{matrix} \]
\begin{bmatrix}
    1 & 0\\ % \\ is used for new line
    0 & 1
\end{bmatrix}

Produces:

\[ \begin{bmatrix} 1 & 0\\ 0 & 1 \end{bmatrix} \]
\begin{vmatrix}
    1 & 0\\ % \\ is used for new line
    0 & 1
\end{vmatrix}

Produces:

\[ \begin{vmatrix} 1 & 0\\ 0 & 1 \end{vmatrix} \]

Subscript

The _ is used for subscript.

Example

\sum_{i = 0}

Produces:

\[ \sum_{i= 0} \]

Superscript

The ^ is used for subscript.

Example

\sum^\infty

Produces:

\[ \sum^\infty \]