I am using the achemso
package to submit a paper to Environmental Science and Technology. When I include a reference to a figure (\ref{Fig1}
), the figure number appears preceded by the word "Figure." I would like to reference "Figures 1-2", but using \ref{Fig1,Fig2}
gives an error and \ref{Fig1}-\ref{Fig2}
gives "Figure 1-Figure 2."
[Tex/LaTex] achemso package: referencing multiple figures
achemsocross-referencing
Best Answer
Use the
cleveref
package and the\cref
command. It automatically sorts and compress the references. For instance, typesetting\cref{Fig1, Fig5, Fig2, Fig3}
will printfigures 1-3 and 5
(if they're labelled so). If later your figures become another structure (say a table), the names will change accordingly. It has a multilingual support.For the current versions of
achemso
andcleveref
(7/2015), this looks like the following. You might want to read thecleveref
manual on how to get a hyphen instead of the word "to".