Skip to content

Instantly share code, notes, and snippets.



Created May 10, 2013
What would you like to do?
Cross-referencing in LaTeX.
paper.tex: main manuscript
supp.tex: supplementary material
We want to cross-reference equations in paper.tex from supp.tex.
Add the following to supp.tex:
Then use \ref, \eqref, \section etc normally.
Equation numbering
In order for the equation numbering in supp.tex to start from the last equation
in paper.tex, add the following to paper.tex:
This will save the equation counter to a file named "counters".
Other counters include: part, chapter, section, subsection, subsubsection,
paragraph, subparagraph, page, equation, figure, table, footnote, mpfootnote
Then include the "counters" file in supp.tex:
To get the references correctly, each file must be compiled with pdflatex two
(or three) times.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment