0

Just wondered if anyone could help me with this issue. I'm trying to reference a theorem using \cite{ref}, but the theorem finishes with an equation, so the citation move onto the next line. This is the code I have:

\begin{thm}[Euler's Formula]
Let $G$ be any planar graph which contains $v$ vertices, $e$ edges and $f$ faces of $G$. Then,
$$v-e+f=2.$$
\cite{ref}
\end{thm} 
  • welcome to tex.sx. if you're using amsmath, you could try this: \[ v-e+f=2. \qquad \text{\cite{ref}} \] – barbara beeton Mar 19 '16 at 21:27
  • 1
    Are you trying to create a cross-reference to a theorem that's been set up elsewhere in the document? If that's the case, you should use \ref{ref} rather than \cite{ref}. – Mico Mar 19 '16 at 21:28

1 Answers1

1

if you're using amsmath, you could try this:

\[
 v-e+f=2. \qquad \text{\cite{ref}}
\]

an additional comment on the style ...

it would be beneficial for you to become more familiar with "good practices". here are a couple of questions that address that topic.

Why is \[ … \] preferable to $$?

What are good learning resources for a LaTeX beginner?

  • It seems \text isn't even necessary. This is one more example why one should not use $$ … $$, b.t.w. – Bernard Mar 19 '16 at 21:48