I want to define a macro for referencing equations in an article. I want the equation to be referenced as: " Eq. (3) " So I defined a command "\eref{}" as:
\def\eref#1{Eq.~\ref{#1}}
But I also have instances where I want to refer to multiple equations like: "Eq. (3,4,5)" and when I try to use:
\eref{label1,label2,label3}
I simply find " Eq. ?? " in the pdf.
Can anyone kindly help me declare a macro which can take as input a list and simply call another function with that list (like how \ref{}
command of latex does). I tried to replace "#1" in the definition by "##", it didn't work.
I wish to have similar macros for referring to Lemmas, Theorems, etc, which too have similar problems.
cleveref
package.cleveref
package, which does all of this already\def
; use\newcommand
et.al.