# equation

Used for a numbered displayed equation that should participate in equation tagging.

https://texform.dev/latex/environments/equation

## Metadata

| Field | Value |
| --- | --- |
| Topic | [Alignment](https://texform.dev/latex/topics/alignment) |
| Packages | base |
| Allowed mode | math |
| Tags |  |
| Commonality | high |
| Body mode | math |

## Syntax

### base

Argument specification: ``

Used for a numbered displayed equation that should participate in equation tagging.

## Common tasks

### How to write a single numbered equation

```latex
\begin{equation} E=mc^2 \end{equation}
```

[Open in Playground](https://play.texform.dev/?input=%5Cbegin%7Bequation%7D+E%3Dmc%5E2+%5Cend%7Bequation%7D)

### How to number a displayed fraction

```latex
\begin{equation} \frac{a}{b}+\frac{c}{d}=\frac{ad+bc}{bd} \end{equation}
```

[Open in Playground](https://play.texform.dev/?input=%5Cbegin%7Bequation%7D+%5Cfrac%7Ba%7D%7Bb%7D%2B%5Cfrac%7Bc%7D%7Bd%7D%3D%5Cfrac%7Bad%2Bbc%7D%7Bbd%7D+%5Cend%7Bequation%7D)

### How to wrap a split derivation in one number

```latex
\begin{equation} \begin{split} a &= b+c \\ &= d \end{split} \end{equation}
```

[Open in Playground](https://play.texform.dev/?input=%5Cbegin%7Bequation%7D+%5Cbegin%7Bsplit%7D+a+%26%3D+b%2Bc+%5C%5C+%26%3D+d+%5Cend%7Bsplit%7D+%5Cend%7Bequation%7D)

## Examples

```latex
\begin{equation} a = b + c \end{equation}
```

[Open in Playground](https://play.texform.dev/?input=%5Cbegin%7Bequation%7D+a+%3D+b+%2B+c+%5Cend%7Bequation%7D)

```latex
\begin{equation} \int_0^1 x^2 \, dx = \frac{1}{3} \end{equation}
```

[Open in Playground](https://play.texform.dev/?input=%5Cbegin%7Bequation%7D+%5Cint_0%5E1+x%5E2+%5C%2C+dx+%3D+%5Cfrac%7B1%7D%7B3%7D+%5Cend%7Bequation%7D)

## Renderer support

| Package | MathJax | KaTeX | XeTeX |
| --- | --- | --- | --- |
| base | full | none | full |

## Usage frequency

37.20% of formulas in the measured corpus contain this entry, rank 1 of 31 entries with frequency data.

## In TeXForm

TeXForm reads the environment body in math mode.

## See also

- [displaymath](https://texform.dev/latex/environments/displaymath)
- [equation*](https://texform.dev/latex/environments/equation-star)
- [math](https://texform.dev/latex/environments/math)

## Test cases

### base

| Input | Case | MathJax | KaTeX | XeTeX |
| --- | --- | --- | --- | --- |
| \begin{equation} a \end{equation} | Positive: baseline | Pass | Fail | Pass |
