Graphics, Figures & TablesBest way to refer to equation in another .tex file

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
gammapoint
Posts: 11
Joined: Fri Jul 24, 2009 11:07 pm

Best way to refer to equation in another .tex file

Post by gammapoint »

Hi, I have two files, one main article .tex file and another supplementary material .tex file. In the main file I have some equations defined with \label associated with them. I'd like to be able to use \ref{eq:whatever} in my supplementary material *.tex file.

Is this possible? If not, is there an easy way for me to simply define in my supplementary material tex file what number I want \ref to refer to and that way I just need to update the equation numbers manually at the top of the document once rather than over and over again throughout the document?

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

Best way to refer to equation in another .tex file

Post by Stefan Kottwitz »

Hi,

for references to external files, you could use the xr package.

Stefan
LaTeX.org admin
gammapoint
Posts: 11
Joined: Fri Jul 24, 2009 11:07 pm

Re: Best way to refer to equation in another .tex file

Post by gammapoint »

Stefan,

That looks absolutely perfect. Thanks so much!

Best,
GP
Post Reply