# LaTeX & MathJax basic tutorial – Highlighting equation

To highlight an equation, \bbox can be used. E.g,

# LaTeX & MathJax basic tutorial – System of equations

## System of equations

• Use \begin{array}…\end{array} and \left\{…\right.. For example, you get this:

$$\left\{ \begin{array}{c} a_1x+b_1y+c_1z=d_1 \\ a_2x+b_2y+c_2z=d_2 \\ a_3x+b_3y+c_3z=d_3 \end{array} \right.$$

# LaTeX & MathJax basic tutorial – Crossing things out

## Crossing things out

Use \require{cancel} in the first formula in your post that requires cancelling; you need it only once per page. Then use:

$$\require{cancel}\begin{array}{rl} \verb|y+\cancel{x}| & y+\cancel{x}\\ \verb|\cancel{y+x}| & \cancel{y+x}\\ \verb|y+\bcancel{x}| & y+\bcancel{x}\\ \verb|y+\xcancel{x}| & y+\xcancel{x}\\ \verb|y+\cancelto{0}{x}| & y+\cancelto{0}{x}\\ \verb+\frac{1\cancel9}{\cancel95} = \frac15+& \frac{1\cancel9}{\cancel95} = \frac15 \\ \end{array}$$

# LaTeX & MathJax basic tutorial – Fussy spacing issues & Colors

## Fussy spacing issues

These are issues that won’t affect the correctness of formulas, but might make them look significantly better or worse. Beginners should feel free to ignore this advice; someone else will correct it for them, or more likely nobody will care.

# LaTeX & MathJax basic tutorial – Arrays

## Arrays

It is often easier to read tables formatted in MathJax rather than plain text or a fixed width font. Arrays and tables are created with the array environment. Just after \begin{array} the format of each column should be listed, use c for a center aligned column, r for right aligned, l for left aligned and a | for a vertical line. Just as with matrices, cells are separated with &  and rows are broken using \\. A horizontal line spanning the array can be placed before the current line with \hline.

# LaTeX & MathJax basic tutorial – Symbols & Cases

## Symbols

In general, you have to search in long tables about a specific symbol you’re looking for, things like $\Psi$, $\delta$, $\zeta$, $\ge$, $\subseteq$ … And it turns out that this operation can be frustrating and time consuming, which can cause the buddy to abandon writing the complete $\LaTeX$ sentence in his answer, or in some cases, the complete answer itself.

# LaTeX & MathJax basic tutorial – Aligned equations

## Aligned equations

Often people want a series of equations where the equals signs are aligned. To get this, use \begin{align}…\end{align}. Each line should end with \\, and should contain an ampersand at the point to align at, typically immediately before the equals sign.

For example,

# LaTeX & MathJax basic tutorial – Matrices

## Matrices

1. Use $$\begin{matrix}…\end{matrix}$$ In between the \begin and \end, put the matrix elements. End each matrix row with \\, and separate matrix elements with & . For example,

# LaTeX & MathJax basic tutorial and quick reference for commands

## A basic tutorial

1. To see how any formula was written in any question or answer, including this one, right-click on the expression it and choose “Show Math As > TeX Commands”. (When you do this, the ‘\$’ will not display. Make sure you add these. See the next point.)