# How to reference an equation without knowing the number for it?

I have done this with figures before using.

\ref{}

Where you give the image an associated name so that it does not matter whether you change up the order, (i.e. latex will automatically number your referenced figure correctly).

I am sure it is possible for equations but I have not been able to find out how to do it. This would be very handy to be able to achieve as I am often dealing with lots and lots of equations and moving them about.

Here is a snippet of what I have been writing for my equations:

\begin{align}
\begin{split}
E_{k}={m  {\langle v^2 \rangle} \over 2 } = \frac{3k_{B}T}{2}
\end{split}
\end{align}

I tried messing about with other ways but could not find the right way to use \ref{} or similar to get the desired result! Can anyone advise?

-
May I ask why you put a split into an align? Is that a strongly simplified example or do you actually use it like that? –  Max Jan 3 '13 at 4:15
This works by default. Please provide a minimal working example (MWE) that shows what you're looking at that is problematic. Code snippets doesn't provide a wide enough scope for what you mentioned "doesn't work." –  Werner Jan 3 '13 at 4:54
You have to insert \label{id} in the equation, and then use \ref{id} (where id is the identifier of the equation) to refer to it. –  Guido Jan 3 '13 at 5:11
@max I have been using it but I am not quite sure the meaning to be honest.I am just about to try '\label' now... –  Magpie Jan 3 '13 at 6:19

This MWE show references to equations with \ref, \eqrefand some other alternative commands, as well as page references:

\documentclass{article}
\usepackage{amsmath}
\usepackage{varioref}
\usepackage{cleveref}
\begin{document}

The equation \ref{a} on page \pageref{a}
showed a simple $a$
formula with simple references.
The next equation \eqref{Ek} is more complicated,
as the reference, that need the package \texttt{amsmath}.
For intelligent references see the commands for these
references to \cref{Ek} \vpageref{Ek} using
\texttt{cleveref} and \texttt{varioref} packages.
You can also hyperlik \hyperref[Ek]{this equation}
with \texttt{hyperref} as well as most previous references.
There are more packages for references, but don't use all
at once (even only these in the wrong order are a source
of problems).

$$\label{a} a = b + c$$

$$\label{Ek} E_{k}={m {\langle v^2 \rangle} \over 2 }% = \frac{3k_{B}T}{2}$$

\end{document}
-
if amsmath is used, the command \eqref{...} places the reference in parentheses, and is always upright even in an italic environment (such as theorem). –  barbara beeton Jan 3 '13 at 15:23
@barbarabeeton, Good point, I updated the example with \eqref and some others referencing methods. –  Fran Jan 3 '13 at 18:56
I know some wouldn't worry about this but I wouldnt start a sentence with (2) followed by a lowercase letter. I'd always rephrase the sentence. Equation 2, In (2), etc. –  Marc van Dongen Jan 3 '13 at 20:47