Is there any difference between \eqref
and \ref
? I used both of them in my document using the package classicthesis
and saw no difference in the result. Is there any specific situation in which I should use \eqref
or \ref
?
[Tex/LaTex] the difference between \eqref and \ref
cross-referencingequations
Best Answer
The command
\ref
is defined in the LaTeX Kernel. The command\eqref
is defined byamsmath
. In the documentation ofamsmath
you will find the explanation in section 3.11.2 Cross references to equation numbers.\eqref
puts brackets around the reference number. It's also places the references in in\upshape
(or\textup
), to match the equation reference exactly (Thanks to Werner). This is shown in the example below.If you use the package
classicthesis
, you must loadamsmath
before. Because the packageclassicthesis
loads the packagehyperref
. However the package itself doesn't change the format of the output.