I spent some time looking at existing posts on this topic but I could not find anything that I was able to use. I am writing a LaTeX document with some sections and an appendix. I would like all the equations in the sections to be labeled (and cross-referenced) normally, using the \label{somelabel}
inside \begin{equation} ... \end{equation}
and then \ref{somelabel}
when I want to reference it. So this will produce labels (1), (2), etc.
But I would like to use a separate counter for the equations in the appendix, and these equations should be labeled (A1), (A2), etc. So the printed output should look like:
Section 1 This is the first equation (1). Using equation (A1), we find the second equation (2)
Section 2 This is the third equation (3), using equation (A2)
Appendix This is the first appendix equation (A1). This is the second appendix equation (A2).
etc.
\setcounter{equation}{0}\renewcommand\theequation{A\arabic{equation}}
after\apendix
solves your problem?