# Citing the source of an equation?

I cant find a good way of adding a \cite to an equation. I'd like to give a reference to the equation's source, but I can't figure out how to typeset it nicely. If I include it in with the equation itself, it pushes the alignment leftwards and feel too much like it's invading the equation's space. I've tried putting an \hfill\cite{example} on the line after the equation, but there's too much vertical space between the equation and the reference.

I'd love to know if there's a commonly accepted way of doing this that I haven't managed to find. Failing that, if anyone has any not-too-inelegant compromises, that'd be great too.

-
Welcome to TeX.SE! It would be also great if you canadd a minimal working example (MWE) that illustrates your problem. –  percusse Nov 14 '12 at 23:49
What would be wrong with something like $$\label{1}...$$, and then Equation~\ref{1} can be found in \cite{} (or before the equation, maybe)? –  T. Verron Nov 14 '12 at 23:56

You shouldn't add the references inside the equation IMO, but outside as in this code:

% arara: pdflatex: {synctex: yes}
% arara: biber
% arara: pdflatex: {synctex: yes}
% arara: pdflatex: {synctex: yes}
%
\documentclass{article}
\usepackage{filecontents}
\usepackage[backend=biber]{biblatex}
\begin{document}
From the famous inequality math relation~\cite{companion}
$$y \neq x$$
%
Or you can also say:
$$y \neq x$$
as proved by~\cite{companion}
\printbibliography
\end{document}

Thus leaving equations to themselves. This reduces the confusion between the parameters and the citation number. (Equations are equations - Don't put something else inside :-))

-
Fair enough - I wasn't sure if there was a commonly-accepted way to incorporate the reference into the equation line, but if not, then that'll have to do. Thanks very much! –  TroyHurts Nov 18 '12 at 19:17