1

I'm using the document class amsart, which defines the section counter as follows:

\newcounter{section}

However, I want the section counter to reset to zero every time I start a new part. Thus, I put in the preamble of my document the following code:

\newcounter{section}[part]

However, since the section counter was already defined in amsart, I'm receiving the error message:

Command \c@section already defined.

What is the appropriate way to redefine the section counter?

justin
  • 1,509

1 Answers1

1

You can use

\makeatletter
\@addtoreset{section}{part}
\makeatother

A complete example:

\documentclass{amsart}
\makeatletter
\@addtoreset{section}{part}
\makeatother

\begin{document}

\part{Test part one}
\section{Test section}

\part{Test part two}
\section{Test section}

\end{document}

The result:

enter image description here

Gonzalo Medina
  • 505,128