% \iffalse
% $Id: aomart.dtx,v 1.92 2025/08/20 23:09:00 boris Exp $
%
% Copyright 2010-2025, Princeton University (Mathematics Department)
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either
% version 1.3 of this license or (at your option) any 
% later version.
% The latest version of the license is in
%    http://www.latex-project.org/lppl.txt
% and version 1.3 or later is part of all distributions of
% LaTeX version 2005/12/01 or later.
%
% This work has the LPPL maintenance status `maintained'.
%
% The Current Maintainer of this work is Boris Veytsman,
% <borisv@lk.net> 
%
% This work consists of the file aomart.dtx and the
% derived file aomart.cls, and files aomplain.bst and aomalpha.bst
%
% The file fullref.pl, included with this package, is in
% public domain.
%
% \fi 
% \CheckSum{0}
%
%
%% \CharacterTable
%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%%   Digits        \0\1\2\3\4\5\6\7\8\9
%%   Exclamation   \!     Double quote  \"     Hash (number) \#
%%   Dollar        \$     Percent       \%     Ampersand     \&
%%   Acute accent  \'     Left paren    \(     Right paren   \)
%%   Asterisk      \*     Plus          \+     Comma         \,
%%   Minus         \-     Point         \.     Solidus       \/
%%   Colon         \:     Semicolon     \;     Less than     \<
%%   Equals        \=     Greater than  \>     Question mark \?
%%   Commercial at \@     Left bracket  \[     Backslash     \\
%%   Right bracket \]     Circumflex    \^     Underscore    \_
%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
%%   Right brace   \}     Tilde         \~} 
%
%\iffalse
% Taken from xkeyval.dtx
%\fi
%\makeatletter
%\def\DescribeOption#1{\leavevmode\@bsphack
%              \marginpar{\raggedleft\PrintDescribeOption{#1}}%
%              \SpecialOptionIndex{#1}\@esphack\ignorespaces}
%\def\PrintDescribeOption#1{\strut\emph{option}\\\MacroFont #1\ }
%\def\SpecialOptionIndex#1{\@bsphack
%    \index{#1\actualchar{\protect\ttfamily#1}
%           (option)\encapchar usage}%
%    \index{options:\levelchar#1\actualchar{\protect\ttfamily#1}\encapchar
%           usage}\@esphack}
%\def\DescribeOptions#1{\leavevmode\@bsphack
%  \marginpar{\raggedleft\strut\emph{options}%
%  \@for\@tempa:=#1\do{%
%    \\\strut\MacroFont\@tempa\SpecialOptionIndex\@tempa
%  }}\@esphack\ignorespaces}
%\makeatother
%
% \MakeShortVerb{|}
% \GetFileInfo{aomart.dtx}
% \newcommand{\progname}[1]{\textsf{#1}}
% \title{\LaTeX{} Class for The \emph{Annals of
% Mathematics}\thanks{\copyright 2010--2025, Princeton University
% (Mathematics Department)}} 
% \author{Boris Veytsman\thanks{%
% \href{mailto:borisv@lk.net}{\texttt{borisv@lk.net}},
% \href{mailto:boris@varphi.com}{\texttt{boris@varphi.com}}}} 
% \date{\filedate, \fileversion}
% \maketitle
% \begin{abstract}
%   This package provides a class for typesetting articles for
%   The \emph{Annals of Mathematics}
% \end{abstract}
% \tableofcontents
%
% \changes{v0.2}{2010/08/24}{First fully functional version} 
% \changes{v0.3}{2010/09/27}{Documentation update} 
% \changes{v0.4}{2010/09/29}{Documentation update} 
% \changes{v0.6}{2010/10/03}{Changes to bst files} 
% \changes{v0.6}{2010/10/03}{Fullref.pl is much less agressive now} 
% \changes{v0.7}{2010/10/09}{Bibliography styles changed} 
% \changes{v0.8}{2010/11/16}{Documentation update} 
% \changes{v0.8}{2010/11/21}{Bibliography styles update} 
% \changes{v0.9}{2010/12/04}{Bibliography styles update} 
% \changes{v0.9}{2010/12/04}{Documentation update} 
% \changes{v0.10}{2010/12/20}{Bibliography styles update} 
% \changes{v0.10}{2010/12/20}{Documentation update} 
% \changes{v1.0}{2010/12/21}{Top matter macros are now only in preamble} 
% \changes{v1.2}{2011/01/05}{Bibliography styles update} 
% \changes{v1.5}{2011/02/26}{Added noopsort to the styles, corrected
% typo} 
% \changes{v1.5}{2011/02/26}{Added sortyear to the styles} 
% \changes{v1.6}{2011/03/06}{Bibliography change: aomalpha now
% respects key field in the bib file} 
% \changes{v1.11}{2012/07/23}{Added new commands for copyright
% statement}  
% \changes{v1.11}{2012/07/24}{Bibliography change: titlenote, deleted bysame}  
% \changes{v1.11}{2012/08/16}{Added \textbackslash fulladdress}  
% \changes{v1.11}{2012/08/16}{Deleted \textbackslash repeatedauthors{} from
% the documentation}  
% \changes{v1.17}{2017/01/26}{Added new field totalpages to the
% bibliography}   
% \changes{v1.17a}{2017/01/26}{Bug fixed in aomplain.bst}   
% \changes{v1.18}{2017/02/11}{New option \texttt{oldkeywords} and
% printing keywords and subjects by default}   
% \changes{v1.19}{2017/04/12}{Bibliography changes}   
%
% \clearpage
%
%\section{Introduction}
%\label{sec:intro}
%
% The \emph{Annals of Mathematics} is published bimonthly with the
% cooperation of Princeton University and the Institute for Advanced
% Study. Founded in 1884 by Ormond Stone of the University of
% Virginia, the journal was transferred in 1899 to Harvard University,
% and in 1911 to Princeton University. Since 1933, the Annals has been
% edited jointly by Princeton University and the Institute for
% Advanced Study (see
% \url{http://annals.princeton.edu/annals/about/journal/about.html}). 
% 
% This class presents a complete redesign of the journal style---with
% new fonts and new interface.  
%
%
% An author well acquainted with AMS\LaTeX{} should find this package
% easy to use and configurable.  The User Manual below illustrates the
% basic use of the class and discusses the differences with \progname{amsart}.
% For an in-depth tutorial of AMS\LaTeX{} I could recommend the
% excellent book~\cite{Graetzer00:MathIntoLaTeX}.
%
%
%\section{User's Guide}
%\label{sec:manual}
%
%
%\subsection{Installation}
%\label{sec:installation}
%
% The installation of the class follows the usual
% practice~\cite{TeXFAQ} for \LaTeX{} packages:
% \begin{enumerate}
% \item Run \progname{latex} on |aomart.ins|.  This will produce the file
% |aomart.cls|.
% \item Put the file |aomart.cls| to
% the place where \LaTeX{} can find them (see
% \cite{TeXFAQ} or the documentation for your \TeX{}
% system).\label{item:install} 
% \item Update the database of file names.  Again, see \cite{TeXFAQ}
% or the documentation for your \TeX{} system for the system-specific
% details.\label{item:update}
% \item The file |aomart.pdf| provides the documentation for the
% package (this is the file you are probably reading now).
% \end{enumerate}
% As an alternative to items~\ref{item:install} and~\ref{item:update}
% you can just put the files in the working directory where your
% |.tex| file is.
% 
%
% The class uses some other \LaTeX{} classes or packages.  Most
% probably, they are already installed on your system.  If not (or if
% their versions are very old), you need to download and
% install them.  Here is the list:
% \begin{enumerate}
% \item \progname{amsart} class and related
% packages~\cite{Downes04:amsart}, 
% \item Package \progname{hyperref}~\cite{Rahtz06:Hyperref},
% \item \progname{ifpdf} package~\cite{Oberdiek06:Ifpdf},
% \item \progname{fancyhdr} package~\cite{Oostrum04:Fancyhdr},
% \item \progname{cmtiup} package~\cite{Znamenskii03:Cmtiup} for
% ``special italics'' with uprgiht digits and punctuation.  Note that
% since many distributions do not include this package, you may need
% to install it yourself.  Just download the file
% \url{http://mirrors.ctan.org/fonts/cm/cmtiup.zip}, unzip it in your
% \path{TEXMF} directory and rebuild the file names database  with the
% command like |mktexlsr|,
% \item \progname{yhmath} package~\cite{Haralambous96:Yhmath}.
% \end{enumerate}
% 
%
%\subsection{Invocation}
%\label{sec:invocation}
%
% To use the class, put in the preamble of your document
% \begin{flushleft}
% |\documentclass[|\meta{options}|]{aomart}|
% \end{flushleft}
% The class internally loads \progname{amsart}, so all facilities of
% \progname{amsart}~\cite{Graetzer00:MathIntoLaTeX, amsldoc} can be used in the
% source.
%
%  The class should work with the
%  \progname{Babel}~\cite{Braams05:Babel} package.  At present,
%  English, French and German languages are fully supported.  See also
%  Section~\ref{sec:non-english}.  
% 
% \DescribeOptions{draft,final}
% The options |draft| and |final| work in the same way as for
% \progname{amsart} and standard \LaTeX.  If the option |draft| is
% chosen, the overfull lines are marked by black boxes on the margins
% \emph{and} the |\includegraphics| prints blank placeholders for the
% images.  The option |final| (default) switches off the marking of
% overfull lines and restores the behavior of |\includegraphics|.  To
% switch on just the overfull marks, without changing the behavior of
% |\includegraphics|, one can either explicitly pass the option final
% to \progname{graphics} package:
% \begin{verbatim}
% \documentclass[draft]{aomart}
% \usepackage[final]{graphics}
% \end{verbatim}
% or add in the beginning of the document
% \begin{verbatim}
% \overfullrule=5pt
% \end{verbatim}
% 
% \DescribeOption{manuscript}
% The option |manuscript| is intended to faciliate the communications
% between the editor and the author.  It enables two things:
% \begin{enumerate}
% \item Numbering of lines in the manuscript is switched off in the
% normal mode, but is on in the manuscript mode.
% \item Command |\EditorialComment| is no-op in normal mode, but
% produces mariginal commentaries in the manuscript
% \item Hyperlinks are black in normal mode, but blue in manuscript
% mode. 
% \end{enumerate}
% 
% \DescribeOption{screen}
% The option |screen| is intended for the onscreen version of the
% acticle.  If this option is selected, the links are blue colored,
% and the margins are reduced.
%
% \DescribeOption{olddoi}%
% Starting from version~1.9 (2011) the formatting of DOI numbers
% changed according to the new recommendations from CrossRef.  The
% option |olddoi| switches on the ``old'' formatting.  It is used for
% compatibility reasons.
%
% \DescribeOption{doi2016}%
% Starting from version~1.5 (2016) the formatting of DOI numbers
% changed again according to Crossref recommendations.  The option
% |doi2016| switches to the version existed between 2011 and 2016.  
%
% \DescribeOption{oldkeywords}%
% Since June 2017 keywords and AMS Mathematical Subjects
% classification numbers are printed on the title page.  The option
% \texttt{oldkeywords} suppresses this.  
%
% \DescribeOptions{8pt,9pt,10pt,11pt,12pt}
% The size-changing options of \progname{amsart} class (|8pt|, |9pt|,
% \dots, |12pt|) have no effect other than producing a warning in the
% log since the journal is designed for 
% only one type size (roughly corresponding to |11pt| of
% \progname{amsart}).
%
%
% \DescribeOption{printscheme}%
% Normally the scheme for MSC numbers is not printed.  If the option
% |printscheme| is chosen, however, it is printed explicitly.
%
%
%\subsection{Top Matter}
%\label{sec:top_matter}
%
%
% There are two kinds of top matter commands:  the ones used primarily
% for authors and the ones used primarily for editors.  We describe
% them separately.
%
% The macros descibed below must be issued in the preamble of the
% document, i.e. before |\begin{document}|.  They produce fatal error
% otherwise.  This behavior is required by the way non-\TeX{} scripts
% process the files to produce  metadata.
%
% The only exception is abstract, which should be placed 
% after |\begin{document}|.
% 
%
%\subsubsection{Commands for Authors}
%\label{sec:authors_commands}
%
%
% \DescribeMacro{\title}
% The command |\title|, as in \progname{amsart} class, has two arguments:  one
% optional, and one mandatory:
% \begin{flushleft}
%   |\title[|\meta{ShortTitle}|]{|\meta{FullTitle}|}|
% \end{flushleft}
% The mandatory argument is the full title of the article.  The
% optional argument, if present, defines the shorter version of the
% title for running heads.  If the optional argument is absent, the
% full title is used instead.  
%
% The optional argument should be used in two cases: when the full
% title is too long to fit in the running head, \emph{and} when the
% author wants to add a footnote or linebreaks to the title.  
%
%
% \DescribeMacro{\author}%
% \DescribeMacro{\email}%
% \DescribeMacro{\address} \DescribeMacro{\curraddr}%
% \DescribeMacro{\urladdr}%
% \DescribeMacro{\orcid}%
% The interface for specifying the authors and their affiliations is
% close the the one of \progname{amsart}~\cite{instr-l} (and different
% from the standard \LaTeX).  For each author a separate command
% |\author| should be used, followed by |\address| and (optionally)
% |\curraddr|, |\email|, |\urladdr| and \cs{orcid}.  Note that the
% house style of the \emph{Annals of Mathematics} requires writing
% |\address| in the form \emph{Institution, City, State} (or
% \emph{Institution, City, Country} for non-US locations).  Like the
% newer versions of \progname{amsart}, \progname{aomart} does
% \emph{not} require the doubling of the |@| symbols in the e-mail
% addresses.  The macro |\author| has two arguments, similarly to
% |\title|:
% \begin{flushleft}
%   |\author[|\meta{AbbrevName}|]{|\meta{FullName}|}|
% \end{flushleft}
% The optional argument defines the shorter form of the author's name
% to be included in the running head.  
%
% \DescribeMacro{\givenname} \DescribeMacro{\surname} 
% The papers published in the \emph{Annals of Mathematics} are
% included in various databases.  For the indexing purposes it is
% important to correctly separate the authors' names into ``First
% Name/Surname'' parts.  This operation is not easy for the
% computers.  Therefore we decided that the authors should know best
% how to deal with their names.  The macros |\givenname| and
% |\surname| are used to indicate how to split the name into the
% parts. 
%
% \DescribeMacro{\fulladdress}
% Another command which does not affect the typesetting is
% \cmd{\fulladdress}.  It is used to store the full mailing address of
% the author for the online version of the journal and various
% databases.
%
% \DescribeMacro{\contrib}%
% Sometimes there are contributors to a paper, who are not full authors:
% the person may write an appendix or other part of the paper.  You
% can use the command \cs{contrib}\oarg{role}\marg{name} for
% indicating these persons.  Note that \oarg{role} argument has a
% special meaning, indicating that the role of this person is the same
% as for the previous contributor, for example,
% \begin{verbatim}
% \contrib[with Appendix~A by]{A. U. Thor}
% \givenname{Alexandra}\surname{Thor}
% \contrib{A. N. Other}
% \givenname{Antony N.}\surname{Other}
% \contrib[with Appendix~B by]{Y. Etanother}
% \givenname{Yakov}\surname{Etanother}
% \end{verbatim}
% In this example Appendix~A is written by A.~U.~Thor and
% A. N. Another, and Appendix~B is written by Y.~Etanother.
% Commands \cs{orcid}, \cs{email}, \cs{address}, \cs{fulladdress},
% \cs{givenname} and \cs{surname} can be used for contributors in the
% same way they are used for authors.  
%
% \DescribeMacro{\shortauthors}
% In some cases the authors list may be too long for the running head,
% even if the abbreviated forms are used for each author.  In this
% case it is possible to change the running head by a
% \emph{redefinition} of the command |\shortauthors|.  This
% redefinition must be done after all |\author| commands, but before
% |\maketitle|:
% \begin{verbatim}
% \renewcommand{\shortauthors}{A.~Smith et al}
% \end{verbatim}
%
%
% \DescribeMacro{\thanks}
% Like \progname{amsart} (and unlike standard \LaTeX{}),
% \progname{aomart} allows |\thanks| only \emph{outside} of commands
% |\title| and |\author|.
%
%
% \DescribeMacro{\copyrightnote}
% Normally each paper is copyrighted by Department of Mathematics,
% Princeton University.  This is reflected in the footnote on the
% first page of the article.  However, by arrangement with the
% editors, certain papers may have different copyright.  The command
% \cmd{\copyrightnote}\marg{copyright statement}, if issued, changes
% the footnote to the corresponding text, for example: 
% \begin{verbatim}
% \copyrightnote{\textcopyright~2012 by the authors.  This paper may
% be reproduced, in its entirety, for noncommercial purposes.}
% \end{verbatim}
% Note that if you issue this command, you should explicitly include
% both the copyright sign and the year unless the paper does not have
% a copyright, for example:
% \begin{verbatim}
% \copyrightnote{This paper is in the public domain}
% \end{verbatim}
% 
%
%
% \DescribeEnv{abstract}
% The abstract of the paper must be put between |\begin{abstract}| and
% |\end{abstract}|.   Unlike the situation in \progname{amsart}
% class, abstract may be put \emph{after} |\maketitle|.
%
% A paper may have several abstracts in different languages.  This
% sitation is discussed in Section~\ref{sec:non-english}.  
%
% \DescribeMacro{\maketitle}
% The macro |\maketitle| typesets the top matter.  All top matter
% information should be specified before this command.
%
%
%\subsubsection{Commands for Editors}
%\label{sec:editors_commands}
%
% The commands described in this section should be used by the editors
% to insert the information about the published paper.  They must be
% put before the |\maketitle| command.
%
% \DescribeMacro{\keyword}
% The command |\keyword| adds a keyword to the list of keywords.  This
% command may be repeated, for example
% \begin{verbatim}
% \keyword{Embedding theorem}
% \keyword{Relatively hyperbolic group}
% \end{verbatim}
% 
% \DescribeMacro{\subject}
% The command |\subject| has  three parameters: whether the subject is
% primary or secondary, the classification scheme and the subject
% itself, for example
% \begin{verbatim}
% \subject{primary}{msc2000}{20E45}
% \subject{secondary}{msc2000}{20F65}
% \end{verbatim}
%
% \DescribeMacro{\formatdate}%
% The macro |\formatdate| is used to format the dates in the
% commands.  Its argument is the date in the format |YYYY-MM-DD|, for
% example
% \begin{verbatim}
% \formatdate{2010-08-13}
% \end{verbatim}
% 
% \DescribeMacro{\received}
% \DescribeMacro{\revised}
% \DescribeMacro{\accepted}
% \DescribeMacro{\published}
% \DescribeMacro{\publishedonline}
% The commands |\received|, |\revised|, |\accepted|, |\published|,
% |\publishedonline| accept as a parameter a date in the form
% |\formatdate|\marg{YYYY-MM-DD}, for example
% \begin{verbatim}
% \received{\formatdate{2004-12-24}}
% \revised{\formatdate{2006-04-12}}
% \accepted{\formatdate{2007-10-02}}
% \end{verbatim}
%
% \DescribeMacro{\proposed}
% \DescribeMacro{\seconded}
% \DescribeMacro{\corresponding}
% \DescribeMacro{\editor}
% \DescribeMacro{\version}
% The macros |\proposed|, |\seconded|, |\corresponding|, |\editor|,
% |\version| are used to set the corresponding metadata for the
% editorial process, for example
% \begin{verbatim}
% \proposed{E. D. Itor}
% \seconded{A. S. Sociate}
% \corresponding{A. U. Thor}
% \version{2.1}
% \end{verbatim}
% 
% 
% 
% \DescribeMacro{\volumenumber}
% \DescribeMacro{\issuenumber}
% \DescribeMacro{\publicationyear}
% \DescribeMacro{\papernumber}
% \DescribeMacro{\startpage}
% \DescribeMacro{\endpage}
%  The macros |\volumenumber|, |\issuenumber|, |\publicationyear|,
%  |\papernumber|, |\startpage|, |\endpage| set up the corresponding
%  data for the paper, for example:
% \begin{verbatim}
% \volumenumber{172}
% \issuenumber{1}
% \publicationyear{2010}
% \papernumber{1}
% \startpage{1}
% \endpage{39}
% \end{verbatim}
% Note that if the argument of |\endpage| is empty, \LaTeX{} tries to
% calculate the last page number as best as it can.
%
% \DescribeMacro{\copyrightyear}
% In the standard copyright statement the copyright year is assumed to
% be the same as the |\publicationyear|.  However, for special cases
% one can set the copyright year explicitly, for example,
% \begin{verbatim}
% \publicationyear{2012}
% \copyrightyear{2011}
% \end{verbatim}
% Note that if you use your own copyright statement instead of the
% canned one (with the command \cmd{\copyrightnote}), you need to put
% there the copyright year explicitly instead of using this command.  
%
% \DescribeMacro{\doinumber}%
% \DescribeMacro{\mrnumber}%
% \DescribeMacro{\zblnumber}%
% \DescribeMacro{\arxivnumber}%
% The macros |\doinumber|, |\mrnumber| and |\zblnumber|  set the
% information about paper in four major reference databases:  DOI
% (\url{http://www.doi.org/}), MathSciNet
% (\url{http://www.ams.org/mathscinet/}, Zentralblatt MATH
% (\url{http://www.zentralblatt-math.org/zmath/}) and arXiv
% (\url{https://www.arxiv.org}).  The use of these  
% macros should be obvious: 
% \begin{verbatim}
% \doinumber{10.1215/S0012-7094-92-06520-3}
% \mrnumber{1154181}
% \zblnumber{0774.14039}
% \arxivnumber{1234.567890}
% \end{verbatim}
% Note the difference between these commands and the bibliography
% commands discussed in Section~\ref{sec:biblio}.  Commands in this
% Section set up the data for the \emph{current article.}  Commands in
% Section~\ref{sec:biblio} set up the data for the articles in the
% bibliography list.
%
% Normally you should \emph{not} use |\doinumber| command, since the
% class will construct the standard DOI for the paper from the volume,
% issue and paper information.  Use it \emph{only} if the result is by
% any reason wrong.
%
%
% \DescribeMacro{\oldsubsections}
% Starting with version~1.2 we decreased the vertical spacing before
% |\subsection|.  The command |\oldsubsections| restores the ``old''
% values.
%
%
% 
% The class has a system of editorial comments and highlighting for
% communication between copy editors, production editors, journal
% editors and authors.  All these comments are visible only in the
% |maniscript| mode.  In production environment they are not
% displayed.
%
% The important feature of these commands is the notion of |audience|.
% Each comment or highlighting has an audience in mind, which is the
% optional argument of the comments and highlights.  One can
% selectively enable the comments for the given audience.  There is a
% special audience called |default|, which is enabled, well, by
% default.  All other audiences must be enabled explicitly.  
%
% \DescribeMacro{\EditorialComment}%
% The macro
% |\EditorialComment|\oarg{audience}\marg{comments}\oarg{vertical
% offset} typesets 
% the comments on the margins in the |manuscript| mode for the
% selected audience, for example,
% \begin{verbatim}
% Erd\"os proved the following theorem.\EditorialComment{A citation is
% needed}
%
% Erd\"os proved the following
% theorem~\cite{Erd01}.\EditorialComment[Editor]{Please check the
% citation} 
% \end{verbatim}
%
% The style does not check whether comments overlap, so sometimes you
% need to manually shift a comment up or down.  The second optional
% argument will do it, for example
% \begin{verbatim}
% Erd\"os proved the following
% theorem~\cite{Erd01}.\EditorialComment[Editor]{Please check the
% citation}[-5pt]
% \end{verbatim}
%
% \DescribeMacro{\Highlight}%
% The macro |\Highlight|\oarg{audience}\marg{text} highlights the
% |text| for the selected |audience|.  The highlighting is done using
% the color selected for the given audience, for example
% \begin{verbatim}
% This is described by the following
% theorem\Highlight{:}\EditorialComment{Added ``:''}
%
% This is described by the following
% theorem\Highlight[Editor]{:}\EditorialComment[Editor]{Do we need
% ``:'' here?}
% \end{verbatim}
% 
% \DescribeMacro{\ECSelect}
% The audiences to be displayed are selected by the command
% \cs{ECSelect}\oarg{color}\marg{audience} 
% audiences, for example, 
% \begin{verbatim}
% \ECSelect{Editor}
% \ECSelect[teal]{Author}
% \end{verbatim}
% The default color is black, and the audience ``default'' is selected
% by default.
%
% \DescribeMacro{\HSelect}%
% The command \cs{Hselect}\oarg{color}\marg{audience} selects the
% audience for which the highlght is intended.  The optinal argument
% ``color'' is used for highlighting, for example,
% \begin{verbatim}
% \HSelect[green]{Editor}
% \end{verbatim}
% The default color is red, and the audience ``default'' is selected by default.
%
%\subsection{Additional Macros}
%\label{sec:add_guide}
%
% \DescribeEnv{eqnarray}
% \DescribeEnv{eqnarray*}
% Thee class \progname{aomart} loads the class \progname{amsart}.
% Therefore all familiar \progname{amsmath} commands~\cite{amsldoc}
% are available.  In particular, there are many commands for writing
% multiline equations (|split|, |align|, |gather|, |multline|,
% \dots).  The environments |eqnarray| and |eqnarray*|, while still
% avilable, are \emph{not} recommended and should be avoided if
% possible.  
%
% \DescribeMacro{\widetilde}
% \DescribeMacro{\widehat}
% \DescribeMacro{\widetriangle}
% \DescribeMacro{\wideparen}
% \DescribeMacro{\widering}
% \DescribeMacro{\widebar}
%  A number of ``wide'' mathematical accents is available due to the
%  (internally loaded) package
%  \progname{yhmath}~\cite{Haralambous96:Yhmath}: |\widetilde|, 
% |\widehat|, |\widetriangle|, |\wideparen|, |\widering|, |\widebar|. See
% Table~\ref{tab:accents} for the example of the usage.  
%
% \begin{table}
%   \centering
%   \begin{tabular}{ll}
%     \toprule
%     Code & Example \\
%     \midrule
%     |\widetilde{AB}| & $\widetilde{AB}$\\
%     |\widehat{AB}| & $\widehat{AB}$\\
%     |\widetriangle{AB}| & $\widetriangle{AB}$\\
%     |\wideparen{AB}| & $\wideparen{AB}$\\
%     |\widering{AB}| & $\widering{AB}$\\
%     |\widebar{AB}| & $\widebar{AB}$\\
%     \bottomrule
%   \end{tabular}
%   \caption{Wide Mathematical Accents}
%   \label{tab:accents}
% \end{table}
%
%
%
% \DescribeMacro{\fullref}%
% \DescribeMacro{\pfullref}%
% \DescribeMacro{\bfullref}%
% \DescribeMacro{\eqfullref}%
% \DescribeMacro{\fullpageref}%
% A set of macros is used to make more convenient clickable references
% in the online versions of papers.  The
% package~\progname{hyperref}~\cite{Rahtz06:Hyperref} 
% makes clickable reference numbers in the phrases like
% \begin{verbatim}
% ...in theorem~\ref{thm:Noeter}...
% ...see equation~\eqref{eq:alpha}...
% \end{verbatim}
% However, it is more convenient for the readers if both
% the number \emph{and} the word ``theorem'' or ``equation'' were
% clickable.  The macros |\*fullref| solve this problem.  Each macro
% has two arguments:  the word and the reference, for example
% \begin{verbatim}
% ...in \fullref{theorem}{thm:Noeter}...
% \end{verbatim}
% The command |\pfullref| typesets
% the reference in parentheses.  The command |\bfullref| typesets it
% in brackets, and the command |\eqfullref| uses the |\eqref|
% command, for example,
% \begin{verbatim}
% ...see \eqfullref{equation}{eq:alpha}...
% \end{verbatim}
% The similar command  |\fullpageref| is used to make the word
% ``page'' clickable, for example,
% \begin{verbatim}
% ...see \eqfullref{equation}{eq:alpha} on
% \fullpageref{eq:alpha}...
% \end{verbatim}
% By default the command adds the word ``page'' to the text.  You can
% override this choice using the optiomal parameter, e.g.
% \begin{verbatim}
% \fullpageref[The page]{eq:alpha} starts the discussion of...
% \end{verbatim}
% 
%
%
% The \progname{Perl} script \path{fullref.pl} can be used to convert
% change all references to the |\fullref| commands.  It works in the
% following way:
% \begin{verbatim}
% perl fullref.pl original.pl > result.pl
% \end{verbatim}
% The script converts all instances of combinations
% ``|word \ref{reference}|'', ``|word~\ref{reference}|'' and
% ``|word~\pageref{reference}|'' to ``|\fullref{word}| |{reference}|'', and
% similarly for parenthesized references, |\eqref| commands, and page
% references.  To prevent the converting, just put |\ref{reference}|
% or |\eqref{reference}| inside braces.  The ``word'' here must not
% start with a backslash (i.e. must not be a macro itself).  This
% prevents disastrous results for phrases like
% ``|see~\ref{a},  \ref{b}|''.
%
%
% The distribution includes two sample files, \path{aomsample.tex} and
% \path{aomsample1.tex}, the latter being obtained from the former by
% the script \path{fullref.pl}.
% 
%
% Note that |\autoref| command of \progname{hyperref} provides for
% another mechanism that achieves the same goal.  Unlike |\fullref|
% command, the command |\autoref| tries to figure out the name of the
% reference from the context.  See the manual~\cite{Rahtz06:Hyperref}
% for more information.
%
%\subsection{Theorems}
%\label{sec:theorems}
%
% \DescribeMacro{\newtheorem}
% You can use the commands of \progname{amsthm}
% package~\cite{amsthdoc} like
% |\newtheorem{lem}{Lemma}| for numbered theorems, or
% |\newtheorem*{KL}{Klein's Lemma}| for unnumbered theorems, or
% tune the numbering using the optional arguments of these commands.  
%
% To provide backward compatibility with some other classes used
% internally by the \emph{Annals of Mathematics,} the class provides
% yet another optional argument for the command |\newtheorem|,
% allowing constructions like |\newtheorem[\it]{lem}| |{Lemma}|.  This
% optional parameter is not used in our typesetting.
%
%
% The class provides two theorem styles:
% \begin{description}
% \item[plain:] This is the default theorem style.  It is used for 
% Theorem, Lemma, Proposition, Conjecture, Corollary and  Claim.
% \item[definition:] This style is used for Definition, Remark,
% Notation, Condition,  Example etc.
% \end{description}
% Note that AMS classes define the third theorem style,
% \textbf{remark.}  In our class remarks are typeset in the
% \textbf{definition} style.  To make the authors' lives easier we
% define the theorem style \textbf{remark,} which is identical to the
% theorem style \textbf{definition.}
%
%
%
%\subsection{Illustrations and color}
%\label{sec:illustrations}
%
% The authors can use the \progname{graphics}, \progname{graphicx},
% \progname{PSTricks}, \progname{pgf/tikz}, \progname{Metapost} or
% other tools to include illustrations
% (see~\cite{Goossens97:LateXGraphicsCompanion} for a comprehensive
% discussion of \LaTeX{} graphics possibilities).
%
% \DescribeMacro{\includecolorgraphics}%
% The printed edition of the journal cannot use color illustrations.
% The online version can, although we recommend against the reliance
% of color since it might not be accessible for people with color
% perception problems.  If you want to use color illustrations for the
% online version, you need to prepare two versions, a color one, and a
% BW (or grayscale one) with \emph{identical sizes and contents}.  The
% command
% |\includecolorgraphics|\oarg{options}\marg{color\_file}\marg{bw\_file}
% can be used to select the proper illustration: in the screen mode
% the color one is chosen, and otherwise the bw one is chosen.  
%
%
%\subsection{Funding}
%\label{sec:ug_funding}
%
% \DescribeMacro{\funding}%
% There is a special command for showing the support for the paper, 
% \cs{funding}\oarg{text} \marg{sponsor}\marg{grantid}.  Normally it
% prints the name of the sponsor and in parentheses the id of the
% grant, if it is not empty.  However, you can override this using the
% optional argument of the command. For example, the following text
% \begin{verbatim}
% AB is grateful to \funding{NASA}{123GH456}, while MJ was supported
% by \funding{NIH}{}.  Both authors acknowledge \funding[the generous
% help of other agencies]{Department of Defense}{Special project
% grant}. 
% \end{verbatim}
% will expand to
% \begin{verbatim}
% % AB is grateful to NASA (123GH456), while MJ was supported
% by NIH.  Both authors acknowledge the generous
% help of other agencies. 
% \end{verbatim}
%
% The command will save the information about the grants in the form
% suitable for automatic processing.
% 
%
%\subsection{Bibliography}
%\label{sec:biblio}
%
% The authors are encouraged to use Bib\TeX{} for uniform style of
% bibliography.  The distribution includes the BST files
% \path{aomplain.bst} and \path{aomalpha.bst}.  These files have
% several additional non-standard fields:
% \begin{description}
% \item[mrnumber:] MathSciNet number for the article.
% \item[zblnumber:] Zentralblatt number for the article.
% \item[doi:] DOI number for the article.
% \item[jfmnumber:] JFM number for the article.
% \item[arxiv:] ArXiv reference for the ArXiv manuscript.
% \item[url:] If the reference is available online, the corresponding
% url. 
% \item[venue:] (for \texttt{conference} entries)  The place where the
% conference took place.
% \item[sortyear:] Some entries do not have a year set up (e.g. some
%   \texttt{unpublished} entries.  If you have several entries from
%   the same author, some with a year, and some without, you may want
%   to put them in a certain order.  The field |sortyear| overrides
%   |year| for the sorting purposes.
% \item[titlenote:] this field is like \texttt{note}, but is typeset
% immediately after a title.  It should be used for additional
% information, for example,
% \begin{verbatim}
% @Book{Knuth94:TheTeXbook,
%  author =	 {Knuth, Donald Ervin},
%  title = 	 {The \TeX book},
%  publisher = 	 {Addison-Wesley Publishing Company},
%  year = 	 1994,
%  series =	 {Computers \& Typesetting A},
%  address =	 {Reading, MA},
%  titlenote  =  {with illustrations by Duane Bibby}
% }
% \end{verbatim}
% \item[totalpages:] some articles (especially published in an electronic
% format) do not have start and end page numbers; instead you may put
% the total number of pages.   If both \texttt{pages} and
% \texttt{totalpages} are present, \texttt{pages} take precedence.
% For books, dissertations, manuals and reports this field stores the
% total pages in the item, for example,
% \begin{verbatim}
% @Book{Arnold89:MathMethodsMechanics,
%  author =	 {Arnold, V. I.},
%  title = 	 {Mathematical Methods of Classical Mechanics},
%  publisher = 	 {Springer},
%  year = 	 1989,
%  volume =	 60,
%  series =	 {Graduate Texts in Mathematics},
%  address =	 {New York},
%  edition =	 {Second},
%  totalpages =  {xvi+516}
%}
% \end{verbatim}
% 
% \end{description}
% 
%
% \DescribeMacro{\doi}
% \DescribeMacro{\mr}
% \DescribeMacro{\zbl}
% \DescribeMacro{\jfm}
% \DescribeMacro{\arxiv}
% There are several databases routinely used in the science and
% mathematics communities.  Among them are DOI, MathSciNet,
% Zentralblatt, Jahrbuch Database, ArXiv.  Many bibliographies include
% references to 
% these databases.  The commands |\doi|, |\mr|, |\zbl|, |\jfm|, |\arxiv| are
% used to typeset these  references.  If you use Bib\TeX{}, these
% commands are automatically used for the corresponding fields in your
% database entries.
%
%
%\subsection{Papers in languages other than English}
%\label{sec:non-english}
%
% The recommmended way to typeset papers in languages other than
% English is \textsl{babel} package~\cite{Braams05:Babel}.  For
% example, to typeset a paper in French (with an English abstract, see
% below), one puts in the preamble
% \begin{verbatim}
% \usepackage[utf8]{inputenx}
% \usepackage[english,frenchb]{babel}
% \end{verbatim}
%
% Such papers often contain several abstracts: for example, in the
% language the paper is written \emph{and} in English.  Accordingly,
% \textsl{aomart} allows several abstracts.  Each abstract must be put
% inside a group with the corresponding language selected using
% \cs{selectanguage} command, for example
% \begin{verbatim}
% {\selectlanguage{french}%
%   \begin{abstract}
%     French abstract
%   \end{abstract}}
%
% {\selectlanguage{english}%
%   \begin{abstract}
%     English abstract
%   \end{abstract}}
% \end{verbatim}
% 
%
% \StopEventually{%
% \clearpage
%
% \bibliography{aomart}
% \bibliographystyle{unsrt}}
% 
% \clearpage
%
%
%\section{Implementation}
%\label{sec:impl}
%
%\subsection{Identification}
%\label{sec:ident}
%
% We start with the declaration who we are.  Most |.dtx| files put
% driver code in a separate driver file |.drv|.  We roll this code into the
% main file, and use the pseudo-guard |<gobble>| for it.
%    \begin{macrocode}
%<class>\NeedsTeXFormat{LaTeX2e}
%<*gobble>
\ProvidesFile{aomart.dtx}
%</gobble>
%<class>\ProvidesClass{aomart}
[2025/08/20 v1.36 Typesetting articles for the Annals of Mathematics]
%    \end{macrocode}
%
%
%
% And the driver code:
%    \begin{macrocode}
%<*gobble>
\documentclass{ltxdoc}
\usepackage{array,booktabs,amsmath,graphics}
\let\widebar\overline
\usepackage{url}
\usepackage{amsfonts,yhmath}
\usepackage[breaklinks,colorlinks,linkcolor=black,citecolor=black,
            pagecolor=black,urlcolor=black,hyperindex=false]{hyperref}
\PageIndex
\CodelineIndex
\RecordChanges
\EnableCrossrefs
\begin{document}
  \DocInput{aomart.dtx}
\end{document}
%</gobble> 
%<*class>
%    \end{macrocode}
%
%
%\subsection{Options}
%\label{sec:options}
%
%
% The size-changing options produce a warning:
%    \begin{macrocode}
\long\def\aom@size@warning#1{%
  \ClassWarning{aomart}{Size-changing option #1 will not be
    honored}}%
\DeclareOption{8pt}{\aom@size@warning{\CurrentOption}}%
\DeclareOption{9pt}{\aom@size@warning{\CurrentOption}}%
\DeclareOption{10pt}{\aom@size@warning{\CurrentOption}}%
\DeclareOption{11pt}{\aom@size@warning{\CurrentOption}}%
\DeclareOption{12pt}{\aom@size@warning{\CurrentOption}}%
%    \end{macrocode}
% 
% \begin{macro}{\if@aom@manuscript@mode}
% \changes{v0.3}{2010/09/28}{Added manuscript mode} 
%   Check whether we are in the manuscript mode
%    \begin{macrocode}
\newif\if@aom@manuscript@mode
\@aom@manuscript@modefalse
\DeclareOption{manuscript}{\@aom@manuscript@modetrue}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\if@aom@screen@mode}
% \changes{v0.10}{2010/12/20}{Added screen mode} 
%   Check whether we are in the screen mode
%    \begin{macrocode}
\newif\if@aom@screen@mode
\@aom@screen@modefalse
\DeclareOption{screen}{\@aom@screen@modetrue}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\if@aom@olddoi}
% \changes{v1.10}{2011/06/21}{Added old DOI processing} 
%   DOI processing is different in the ``old'' and new mode.
%    \begin{macrocode}
\newif\if@aom@olddoi
\@aom@olddoifalse
\DeclareOption{olddoi}{\@aom@olddoitrue}
%    \end{macrocode}
%   
% \end{macro}
%
%
% \begin{macro}{\if@aom@doiMMXVI}
% \changes{v1.15}{2016/11/18}{Added another options} 
%   DOI processing is different in the 2016 and new mode
%    \begin{macrocode}
\newif\if@aom@doiMMXVI
\@aom@doiMMXVIfalse
\DeclareOption{doi2016}{\@aom@doiMMXVItrue}
%    \end{macrocode}
%   
% \end{macro}
%
%
% \begin{macro}{\if@aom@oldkeywords}
% \changes{v1.18}{2017/02/11}{Added keywords processing} 
%   Keywords processing is different in the ``old'' and new mode.
%    \begin{macrocode}
\newif\if@aom@oldkeywords
\@aom@oldkeywordsfalse
\DeclareOption{oldkeywords}{\@aom@oldkeywordstrue}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\if@aom@printscheme}
% \changes{v1.24}{2020/08/09}{Added optional printing of scheme}
%    \begin{macrocode}
\newif\if@aom@printscheme
\@aom@printschemefalse
\DeclareOption{printscheme}{\@aom@printschemetrue}
%    \end{macrocode}
% 
% \end{macro}
%
% All other options are passed to \progname{amsart}:
%    \begin{macrocode}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{amsart}}
%    \end{macrocode}
% 
% Now we read the configuration file
%    \begin{macrocode}
\InputIfFileExists{aomart.cfg}{%
  \ClassInfo{aomart}{%
    Loading configuration file aomart.cfg}}{%
  \ClassInfo{aomart}{%
    Configuration file aomart.cfg is not found}}
%    \end{macrocode}
% And process the options:
%    \begin{macrocode}
\ProcessOptions\relax
%    \end{macrocode}
%
%
%\subsection{Loading Class and Packages}
%\label{sec:loading}
%
% \begin{macro}{\@makefnmark@kernel}
% \changes{v1.30}{2025/01/07}{Use kernel version of footnote marks} 
% AMS redefines |\@makefnmark|.  Here we return to the kernel version
%    \begin{macrocode}
\let\@makefnmark@kernel\@makefnmark
%    \end{macrocode}
% \end{macro}
%
%
% We start with the base class
% \changes{v1.4}{2011/01/21}{Deleted noamsfonts option} 
%    \begin{macrocode}
\LoadClass[11pt]{amsart}
%    \end{macrocode}
%
% \begin{macro}{\@makefnmar}
% \changes{v1.30}{2025/01/07}{Use kernel version of footnote marks} 
% Restoring the kernel version
%    \begin{macrocode}
\let\@makefnmark\@makefnmark@kernel
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\@citex}
% \changes{v1.30}{2025/01/07}{Redefined macro}
% \changes{v1.32}{2025/01/25}{Added `and' and oxford comma} 
% We redeine this macro early in case some package wants to patch it.
% Basically house style for repeated citations is not [1, 2, 3], but
% [1], [2], and [3].
%
% Note that we do not want to use |\andify| since it requires fine
% control of expansion.  Rather, we just count the number of
% commas. Below |\@tempcnta| is the total number of cites, and
% |\@tempcntb| is the current cite.
%    \begin{macrocode}
\def\@citex[#1]#2{\leavevmode
  \@tempcnta=0
  \@for\@citeb:=#2\do{\advance\@tempcnta by 1}%
  \@tempcntb=1
  \let\@citea\@empty
  \@cite{\@for\@citeb:=#2\do
    {\@citea\def\@citea{], [}%
     \advance\@tempcntb by 1
     \ifnum\@tempcnta=\@tempcntb\relax
        \ifnum\@tempcnta=2\relax
           \def\@citea{] and~[}%
        \else
           \def\@citea{], and~[}%
         \fi
     \fi
     \edef\@citeb{\expandafter\@firstofone\@citeb\@empty}%
     \if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
     \@ifundefined{b@\@citeb}{\hbox{\reset@font\bfseries ?}%
       \G@refundefinedtrue
       \@latex@warning
         {Citation `\@citeb' on page \thepage \space undefined}}%
       {\@cite@ofmt{\csname b@\@citeb\endcsname}}}}{#1}}
%    \end{macrocode}
% \end{macro}
%
% A bunch of packages:
% \changes{v0.5}{2010/10/24}{Made Roman font the default URL font} 
% \changes{v0.10}{2010/12/20}{Screen mode triggers special URL
% settings} 
% \changes{v1.1}{2010/12/31}{In manuscript mode the links are always
% blue} 
% \changes{v1.22}{2018/05/21}{In screen mode we no longer crop pages}
% \changes{v1.34}{2025/05/06}{We need zref for margin notes}
%    \begin{macrocode}
\RequirePackage{fancyhdr, lastpage, ifpdf, graphicx}
\RequirePackage{zref-savepos}
\RequirePackage[breaklinks,colorlinks]{hyperref}
\if@aom@screen@mode
\hypersetup{linkcolor=blue,citecolor=blue, 
  urlcolor=blue}%
\else\if@aom@manuscript@mode
\hypersetup{linkcolor=blue,citecolor=blue, 
  urlcolor=blue}%
\else
\hypersetup{linkcolor=black,citecolor=black, 
  urlcolor=black}%
\fi\fi
\urlstyle{rm}
%    \end{macrocode}
%
% \changes{v0.4}{2010/09/29}{Deleted lineno package dependence} 
% \changes{v1.16}{2016/12/03}{We require environ package} 
% Amsart has \cs{collect@body} macro.  However, we want the \cs{long}
% version, so we use \textsl{environ}
%    \begin{macrocode}
\RequirePackage{environ}
%    \end{macrocode}
% 
% 
%
%
%\subsection{Internationalization}
%\label{sec:babel}
% 
% There are some papers published in languages other than English.
% The \progname{Babel} is expected to be used for them.  Here we add some
% macros extending captions for these languages.
%
%
% First, let us define English defaults:
%
%
% \begin{macro}{\@aom@by}
% \changes{v1.10}{2011/06/21}{Added macro}
%   This is just ``By'' in English:
%    \begin{macrocode}
\def\@aom@by{By}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\@aom@and}
% \changes{v1.10}{2011/06/21}{Added macro}
%   This is ``and'' in English:
%    \begin{macrocode}
\def\@aom@and{and}
%    \end{macrocode}
% \end{macro}
%
% Now we can define internationalization:
%    \begin{macrocode}
\AtBeginDocument{\@ifpackageloaded{babel}{%
  \addto\captionsfrench{\def\@aom@by{Par}\def\@aom@and{et}}%
  \addto\captionsgerman{\def\@aom@by{Von}\def\@aom@and{und}}%
  \addto\captionsenglish{\def\@aom@by{By}\def\@aom@and{and}}}{}}
%    \end{macrocode}
% 
%
%\subsection{Fonts}
%\label{sec:fonts}
%
% \changes{v0.8}{2010/1/16}{Added yhmath}
% We use \progname{yhmath} for large symbols:
%    \begin{macrocode}
\RequirePackage{yhmath}
%    \end{macrocode}
% 
% \changes{v1.23}{2018/12/25}{Made ymath large symbols default}
% Since version 1.2 ymath no longer makes its large symbols default.
% We override this
%    \begin{macrocode}
\DeclareSymbolFont{largesymbols}{OMX}{yhex}{m}{n}
%    \end{macrocode}
% 
% \begin{macro}{\widehat}
% \begin{macro}{\widetilde}
% \changes{v1.23}{2018/12/25}{We are taking wide hat and wide tilde
% from amsfonts}
% The way \cs{widehat} and \cs{widetilde} are implemented in ymath is
% buggy, see
% \url{https://www.reddit.com/r/LaTeX/comments/2j7mtn/usepackageamsmath_vs_usepackageyhmath_and_the/}.  We use AMS definitions instead 
%    \begin{macrocode}
\xdef\widehat#1{\noexpand\@mathmeasure\z@\textstyle{#1}%
  \noexpand\ifdim\noexpand\wd\z@>\tw@ em%
  \mathaccent"0\hexnumber@\symAMSb 5B{#1}%
  \noexpand\else\mathaccent"0362{#1}\noexpand\fi}
\xdef\widetilde#1{\noexpand\@mathmeasure\z@\textstyle{#1}%
  \noexpand\ifdim\noexpand\wd\z@>\tw@ em%
  \mathaccent"0\hexnumber@\symAMSb 5D{#1}%
  \noexpand\else\mathaccent"0365{#1}\noexpand\fi}
%    \end{macrocode}
% 
% \end{macro}
% \end{macro}
%
% \changes{v0.3}{2010/09/26}{Added package mdputu} 
% \changes{v0.4}{2010/09/28}{Switched to upright digits in italics
% everywhere} 
% \changes{v0.8}{2010/1/16}{Switched to cmtiup} 
% We need \progname{cmtiup} package, but we may find out it is not
% installed.
%    \begin{macrocode}
\IfFileExists{cmtiup.sty}{%
  \RequirePackage{cmtiup}}{%
  \ClassWarning{aomart}{The package mdputu is not found.\MessageBreak
    You need this package to get italics with upright digits!}}
%    \end{macrocode}
% 
% \begin{macro}{\specialdigits}
% \changes{v0.8}{2010/1/16}{Redefined to noop} 
%   A legacy macro.  We do not need it anymore.
%    \begin{macrocode}
\def\specialdigits{}%
\let\sishape=\itshape
\let\textsi=\textit
%    \end{macrocode}
%   
% \end{macro}
%
% The \progname{amsart} class defines several options for different
% font sizes (10pt, 11pt, etc).  We have just one design size for the
% articles.
%
% \begin{macro}{\@typesizes}
% \changes{v0.5}{2010/10/24}{Increased LARGE from 16 pt to 17 pt} 
% \changes{v0.5}{2010/10/24}{Corrected typo in the definition of Small} 
%   The font information in \progname{amsart} is stored in
%   |\@typesizes| macro.  It has 11 typesizes:  5 below and 5 above
%   |\normalsize| .
%    \begin{macrocode}
\def\@typesizes{%
  \or{\@vipt}{9}\or{\@viipt}{9}\or{\@viiipt}{9}\or{\@ixpt}{12}%
  \or{\@xpt}{13}%
  \or{\@xipt}{14}% normalsize
  \or{\@xiipt}{15}\or{13}{17}\or{\@xviipt}{20}%
  \or{19}{23.2}\or{22}{27.8}}%
\normalsize \linespacing=\baselineskip
%    \end{macrocode}
% \end{macro}
% 
%
% \begin{macro}{\widebar}
%   The functionality of |\widebar| coincides with that of
%   \progname{amsmath} |\overline|:
%    \begin{macrocode}
\let\widebar\overline
%    \end{macrocode}   
% \end{macro}
%
% 
%\subsection{Page Dimensions and Paragraphing}
%\label{sec:page}
%
% \begin{macro}{\textwidth}
% \begin{macro}{\textheight}
% These are from the old \progname{aomamlt2e}:
%    \begin{macrocode}
\setlength{\textwidth}{31pc}
\setlength{\textheight}{48pc} 
%    \end{macrocode}
% \end{macro}
% \end{macro}
% 
% \begin{macro}{\evensidemargin}
% \begin{macro}{\oddsidemargin}
%   The margins:
%    \begin{macrocode}
\oddsidemargin=.65in
\evensidemargin=.65in
%    \end{macrocode}
%   
% \end{macro}
% \end{macro}
%
% \begin{macro}{\footins}
% \begin{macro}{\topskip}
% \begin{macro}{\abovedisplayskip}
% \begin{macro}{\belowdisplayskip}
% \changes{v0.6}{2010/10/03}{Changed belowdisplayskip} 
%   Some skips from \progname{aomamlt2e}:
%    \begin{macrocode}
\setlength{\topskip}{12pt}
\setlength{\abovedisplayskip}{6.95pt plus3.5pt minus 3pt}
\setlength{\belowdisplayskip}{6.95pt plus4.5pt minus 3pt}
\setlength{\skip\footins}{20pt}
\setlength{\dimen\footins}{3in}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
%
% \begin{macro}{\footskip}
%   Some space for footnotes:
%    \begin{macrocode}
\setlength\footskip{30pt}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\parskip}
% \begin{macro}{\parindent}
%   Paragraph shape:
%    \begin{macrocode}
\setlength{\parindent}{22pt}
\setlength{\parskip}{\z@}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\widowpenalty}
% \begin{macro}{\clubpenalty}
%   We suppress widows and clubs:
%    \begin{macrocode}
\widowpenalty=10000
\clubpenalty=10000
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \changes{v2.30}{2025/01/07}{Changed the margins for enumerate}
% AMS defines the margins for lists |\AtBeginDocument|.  Our lists are
% tighter
%    \begin{macrocode}
\AtBeginDocument{%
  \labelsep=5pt\relax
  \settowidth\leftmargini{\labelenumi\hskip\labelsep}%
  \leftmargin=\leftmargini
  \labelwidth=\leftmargini \advance\labelwidth-\labelsep
  \@listi}
%    \end{macrocode}
%
% \begin{macro}{\itemize}
% \changes{v2.32}{2025/01/25}{Changed the margins for itemize}
%    \begin{macrocode}
\renewenvironment{itemize}{%
  \ifnum\@itemdepth>3 \@toodeep
  \else \advance\@itemdepth\@ne
    \edef\@itemitem{labelitem\romannumeral\the\@itemdepth}%
    \list{\csname\@itemitem\endcsname}%
    {\settowidth\leftmargin{\labelitemi\hskip\labelsep}%
      \def\makelabel##1{\hss\llap{\upshape##1}}}%
  \fi
}{%
  \endlist
}
%    \end{macrocode}
% \end{macro}
%
%\subsection{Headers}
%\label{sec:headers}
%
% \begin{macro}{\headsep}
%   Separation between the header and the body
%    \begin{macrocode}
\setlength{\headsep}{14pt}
%    \end{macrocode}
% \begin{macro}{\headheight}
% \changes{v2.28}{2024/06/08}{Increased}
% Slightly increasing head height
%    \begin{macrocode}
\setlength{\headheight}{18.0pt}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \begin{macro}{\headrulewidth}
% \begin{macro}{\footrulewidth}
%   We do not want decorative rules in the journal:
%    \begin{macrocode}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% 
%
% \begin{macro}{\@aom@linecount}
% \changes{v0.4}{2010/09/29}{Added macro} 
%   This is the box displayed in the manuscript mode
%    \begin{macrocode}
\if@aom@manuscript@mode
  \newsavebox{\@aom@linecount}
  \savebox{\@aom@linecount}[4em][t]{\parbox[t]{4em}{%
      \@tempcnta\@ne\relax
      \loop{\underline{\scriptsize\the\@tempcnta}}\\
      \advance\@tempcnta by \@ne\ifnum\@tempcnta<43\repeat}}
\fi
%    \end{macrocode}
%   
% \end{macro}
%
% \changes{v0.4}{2010/09/29}{Used line numbers for headings} 
% \changes{v0.5}{2010/10/24}{Added extra footer in manuscript mode} 
% \changes{v0.5}{2010/10/24}{Corrected the byg with math in headers} 
% \changes{v0.8}{2010/11/16}{Changed authors in header} 
% It is easy to set up headers with \progname{fancyhdr}:
%    \begin{macrocode}
\pagestyle{fancy}
\fancyhead{}
\fancyfoot{}
\fancyhead[CO]{\scriptsize\shorttitle}
\fancyhead[RO,LE]{\footnotesize\thepage}
\if@aom@manuscript@mode
  \fancyhead[LE]{\footnotesize\thepage\begin{picture}(0,0)%
      \put(-26,-25){\usebox{\@aom@linecount}}%
    \end{picture}}
  \fancyhead[LO]{\begin{picture}(0,0)%
      \put(-21,-25){\usebox{\@aom@linecount}}%
    \end{picture}}
  \fancyfoot[C]{\scriptsize Proof: page numbers may be temporary}
\fi
\fancyhead[CE]{\scriptsize\MakeUppercase\shortauthors}
%    \end{macrocode}
% 
% \changes{v0.3}{2010/09/26}{Added DOI number in headers} 
% \changes{v0.9}{2010/12/04}{Changed font for the folio on the first
% page} 
% \changes{v1.3}{2011/01/07}{Corrected bug with doinumber} 
% The first page has the special headers.  The style |firstpage| is
% invoked by \progname{amsart}; here we just redefine it.
%    \begin{macrocode}
\fancypagestyle{firstpage}{%
  \fancyhf{}%
  \if@aom@manuscript@mode
    \lhead{\begin{picture}(0,0)%
        \put(-21,-25){\usebox{\@aom@linecount}}%
      \end{picture}}
  \fi
  \chead{\scriptsize%
    \href{\@annalsurl}{Annals of Mathematics} \textbf{\currentvolume}
    (\currentyear), 
%    \end{macrocode}
% \changes{v1.7}{2011/03/08}{Suppressed page number in the header for
% one-page articles} 
%  We always print the starting page.  However, we print the last page
%  only if it does not coincide with the first page.  There are two
%  cases here: first, the last page may still be
%  |\pageref{LastPage}|.  In this case we need to extract the numerical
%  value of the counter---note that hyperref is in action!
%  Second, we could redefine the last page, and it is no
%  longer |\pageref{LastPage}|.  In this case we need to compare the
%  value with the first page.
%    \begin{macrocode}
    \start@page%
    \def\tempa{\pageref{LastPage}}%
    \edef\tempb{\start@page}%
    \ifx\tempa\end@page
      \edef\tempa{\HyPsd@@@pageref{LastPage}}%
    \else
       \edef\tempa{\end@page}%
    \fi
    \ifx\tempa\tempb\else--\end@page\fi\\
  \ifx\@doinumber\@empty\else
  \edef\@doinumber{\@doinumber}%
  \expandafter\doi\expandafter{\@doinumber}\fi}%
   \cfoot{\footnotesize\thepage}}%
%    \end{macrocode}
%
% \begin{macro}{\annalsurl}
% \changes{v1.14a}{2015/02/18}{New url}
%   The command to set up the URL of the journal
%    \begin{macrocode}
\def\annalsurl#1{\gdef\@annalsurl{#1}}
\annalsurl{http://annals.math.princeton.edu/about}
%    \end{macrocode}
%   
% \end{macro}
%
%
%\subsection{Top Matter Macros}
%\label{sec:top_matter_code}
% 
% We make these macros allowed only in the preamble:
%    \begin{macrocode}
\@onlypreamble{\title}
\@onlypreamble{\author}
\@onlypreamble{\contrib}
\@onlypreamble{\email}
\@onlypreamble{\address}
\@onlypreamble{\curraddr}
\@onlypreamble{\urladdr}
\@onlypreamble{\orcid}
\@onlypreamble{\givenname}
\@onlypreamble{\fulladdress}
\@onlypreamble{\surname}
\@onlypreamble{\thanks}
\@onlypreamble{\keyword}
\@onlypreamble{\subject}
\@onlypreamble{\received}
\@onlypreamble{\revised}
\@onlypreamble{\accepted}
\@onlypreamble{\published}
\@onlypreamble{\publishedonline}
\@onlypreamble{\proposed}
\@onlypreamble{\seconded}
\@onlypreamble{\corresponding}
\@onlypreamble{\editor}
\@onlypreamble{\version}
\@onlypreamble{\volumenumber}
\@onlypreamble{\issuenumber}
\@onlypreamble{\publicationyear}
\@onlypreamble{\copyrightnote}
\@onlypreamble{\copyrighyear}
\@onlypreamble{\papernumber}
\@onlypreamble{\startpage}
\@onlypreamble{\endpage}
\@onlypreamble{\doinumber}
\@onlypreamble{\mrnumber}
\@onlypreamble{\zblnumber}
\@onlypreamble{\arxivnumber}
%    \end{macrocode}
% 
%
% Most top matter macros are defined in \progname{amsart}.  Here we
% just add some new macros and redefine some.
%
% \begin{macro}{\fulladdress}
% \changes{v1.11}{2012/08/16}{Added macro} 
% \changes{v1.16}{2016/12/03}{Redefined} 
% \begin{macro}{\givenname}
% \changes{v1.16}{2016/12/03}{Redefined} 
% \begin{macro}{\surname}
% \changes{v1.16}{2016/12/03}{Redefined} 
%   We store the information to output it later in the rpi file
%    \begin{macrocode}
\def\@names{}
\def\givenname#1{\g@addto@macro\@names{givenname=#1;}}
\def\surname#1{\g@addto@macro\@names{surname=#1;}}
\def\fulladdress#1{\g@addto@macro\@names{fulladdress=#1;}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\author}
% \changes{v1.16}{2016/12/03}{Redefined amsart definition} 
%   We add mangling of \cs{@names} to the amsart macro
%    \begin{macrocode}
\renewcommand{\author}[2][]{%
  \ifx\@empty\authors
    \gdef\authors{#2}%
    \g@addto@macro\@names{author=#2;}%
  \else
    \g@addto@macro\authors{\and#2}%
    \g@addto@macro\@names{\and author=#2;}%
  \fi
  \gdef\aom@current@orcid@target{\authors}%
  \@ifnotempty{#1}{%
    \ifx\@empty\shortauthors
      \gdef\shortauthors{#1}%
    \else
      \g@addto@macro\shortauthors{\and#1}%
    \fi
  }%
  \g@addto@macro\addresses{\author{#2}}%
}
\edef\author{\@nx\@dblarg
  \@xp\@nx\csname\string\author\endcsname}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\@currentcontribution}
% \changes{v1.26}{2022/01/18}{Introduced macro}
% The current contribution
%    \begin{macrocode}
\def\@currentcontribution{}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@currentcontributors}
% \changes{v1.26}{2022/01/18}{Introduced macro}
% The current contributors with the same contribution
%    \begin{macrocode}
\def\@currentcontributors{}
%    \end{macrocode}
% 
% \end{macro}
% 
% \begin{macro}{\contribs}
% \changes{v1.26}{2022/01/18}{Introduced macro}
% All contributors to the paper
%    \begin{macrocode}
\def\contribs{}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\if@startcontribgroup}
% \changes{v1.26}{2022/01/19}{Introduced macro}
% A switch whether the new group is started
%    \begin{macrocode}
\newif\if@startcontribgroup
\@startcontribgroupfalse
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@processcurrentcontribgroup}
% \changes{v1.26}{2022/01/19}{Introduced macro}
% Add current contributors to \cs{contributors}
%    \begin{macrocode}
\def\@processcurrentcontribgroup{%
  \ifx\@currentcontributors\@empty\else
    \def\@@and{{\upshape \@aom@and}}%
    \author@andify\@currentcontributors
    \ifx\contribs\@empty\else
      \g@addto@macro\contribs{\and}%
    \fi
    \expandafter\g@addto@macro\expandafter\contribs
    \expandafter{\@currentcontribution}%
    \g@addto@macro\contribs{\space}%
    \expandafter\g@addto@macro\expandafter\contribs
    \expandafter{\@currentcontributors}%
  \fi
}
%    \end{macrocode}
% 
% \end{macro}
%
% \begin{macro}{\contrib}
% \changes{v1.26}{2022/01/19}{Redefined amsart macro}
% \changes{v1.28}{2024/06/08}{Added typesetting orcids}
% The processing of contributors.  Contributors are separated into
% groups with the same contribution.  Within the group one can omit
% the contribution.
%    \begin{macrocode}
\renewcommand{\contrib}[2][]{%
  \def\@tempa{#1}%
  \gdef\aom@current@orcid@target{\@currentcontributors}%
  \@startcontribgrouptrue
  \ifx\@tempa\@empty\relax
    \ifx\@currentcontribution\@empty\relax
      \ClassError{aomart}{You must define contribution for
        contributors}{The first \contrib command must have the
        optional argument indicating the contribution}%
    \else
      \@startcontribgroupfalse  
    \fi
  \fi
  \ifx\@currentcontribution\@tempa\relax
    \@startcontribgroupfalse
  \fi
  \if@startcontribgroup
     \@processcurrentcontribgroup
     \gdef\@currentcontribution{#1}%
     \gdef\@currentcontributors{#2}%
  \else
    \g@addto@macro\@currentcontributors{\and#2}%
  \fi
  \g@addto@macro\@names{\and contributor=#2;}%
  \g@addto@macro\@names{role=}%
  \expandafter\g@addto@macro\expandafter%
  \@names\expandafter{\@currentcontribution}%
  \g@addto@macro\@names{;}%
  \g@addto@macro\addresses{\author{#2}}%
}
%    \end{macrocode}
% 
% \end{macro}
%
% \begin{macro}{\email}
% \changes{v1.16}{2016/12/03}{Redefined amsart definition} 
%   We change amsart macro to output metadata
%    \begin{macrocode}
\renewcommand{\email}[2][]{%
  \g@addto@macro\addresses{\email{#1}{#2}}%
  \g@addto@macro\@names{email=#2;}%
}
%    \end{macrocode}
%   
% \end{macro}
% \begin{macro}{\urladdr}
% \changes{v1.16}{2016/12/03}{Redefined amsart definition} 
%   We change amsart macro to output metadata
%    \begin{macrocode}
\renewcommand{\urladdr}[2][]{%
  \g@addto@macro\addresses{\urladdr{#1}{#2}}%
  \g@addto@macro\@names{urladdr=#2;}%
}
%    \end{macrocode}
%   
% \end{macro}
%
%
% \begin{macro}{\aom@current@orcid@target}
% \changes{v1.28}{2024/06/08}{Added macro}
% Each new orcid can be added either to the authors or to the
% contributors.  This macro defines where it goes
%    \begin{macrocode}
\def\aom@current@orcid@target{\authors}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\orcid}
% \changes{v1.18}{2017/02/15}{Added macro}
% \changes{v1.28}{2024/06/08}{Added typesetting orcid} 
%   Orcid also outputs metadata
%    \begin{macrocode}
\newcommand{\orcid}[1]{%
  \g@addto@macro\addresses{\orcid{#1}}%
  \g@addto@macro\@names{orcid=#1;}%
  \expandafter\g@addto@macro\aom@current@orcid@target{\aom@orcidlink{#1}}%
}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\aom@orcidlink}
% \changes{v1.28}{2024/06/08}{Added macro}
% The package orcidlink~\cite{orcidlink} requires TikZ, so here we
% reproduce its functionality using our own version of orcid logo.
% Note that the original logo is licenses under CC0, see
% \url{https://orcid.figshare.com/articles/figure/ORCID_iD_icon_graphics/5008697}
%    \begin{macrocode}
\newcommand\aom@orcidlink[1]{\kern0.2ex\href{https://orcid.org/#1}{\includecolorgraphics[height=2ex]{aom_orcid_logo}{aom_orcid_logo_bw}}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\keyword}
%   Actually \progname{amsart} has |\kewords| macro. It redefines
%   |\@keywords|.  Our macro adds to the stack instead.
%    \begin{macrocode}
\def\keyword#1{\ifx\@keywords\@empty\gdef\@keywords{#1}\else
  \g@addto@macro\@keywords{, #1}\fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\subject}
% \changes{v1.18}{2017/02/15}{Drop scheme and primary/secondary} 
% \changes{v1.20}{2017/05/09}{Make primary and secondary subjects
% separated}
% \changes{v1.24}{2020/08/09}{Added scheme} 
%   Subjects.
%    \begin{macrocode}
\let\@primarysubjects\@empty
\let\@secondarysubjects\@empty
\let\@primaryscheme\@empty
\let\@secondaryschme\@empty
\def\subject#1#2#3{%
  \expandafter\ifx\csname @#1subjects\endcsname\@empty\relax
     \expandafter\gdef\csname @#1subjects\endcsname{#3}%
  \else
     \expandafter\g@addto@macro\csname @#1subjects\endcsname{, #3}%
  \fi
  \if@aom@printscheme
  \expandafter\g@addto@macro\csname @#1subjects\endcsname{%
    ~(#2)}%
  \fi}
%    \end{macrocode}
%   
% \end{macro}
%
%
% \begin{macro}{\formatdate}
%   This just sends the date to the special macro |\@formatdate|
%    \begin{macrocode}
\def\formatdate#1{\@formatdate#1\@endformatdate}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\@formatdate}
%   This macro takes date in the form YYYY-MM-DD and properly formats
%   it.  Note how we delete the leading zero in dates like April 02.
%    \begin{macrocode}
\def\@formatdate#1-#2-#3\@endformatdate{%
  \@tempcnta=#3\relax
  \ifcase#2\or
  January\or February\or March\or April\or May\or June\or
  July\or August\or September\or October\or November\or December\fi
  \space\the\@tempcnta,\space#1}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\received}
% \begin{macro}{\revised}
% \begin{macro}{\accepted}
% \begin{macro}{\published}
% \begin{macro}{\publishedonline}
%   The following macros add stuff to the footnotes material:
%    \begin{macrocode}
\def\received#1{\def\@received{#1}}
\let\@received\@empty
\def\revised#1{\def\@revised{#1}}
\let\@revised\@empty
\def\accepted#1{\def\@accepted{#1}}
\let\@accepted\@empty
\def\published#1{\def\@published{#1}}
\let\@published\@empty
\def\publishedonline#1{\def\@publishedonline{#1}}
\let\@publishedonline\@empty
%    \end{macrocode}
%   
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% The next macros mimic the functionality of \progname{amsart}
% |\issueinfo| command.  Note that |\issueinfo| still works.
% \begin{macro}{\volumenumber}
%   This sets the volume of the paper
%    \begin{macrocode}
\def\volumenumber#1{\def\currentvolume{#1}}
%    \end{macrocode}
% \end{macro}
% \begin{macro}{\issuenumber}
%   This sets the issue of the paper:
%    \begin{macrocode}
\def\issuenumber#1{\def\currentissue{#1}}
%    \end{macrocode}
% \end{macro}
% \begin{macro}{\publicationyear}
%   This sets the year of the paper
%    \begin{macrocode}
\def\publicationyear#1{\def\currentyear{#1}}
%    \end{macrocode}
% \end{macro}
% \begin{macro}{\papernumber}
% \changes{v1.0}{2010/12/21}{Added macro} 
%   This is absent from the |\issueinfo|.  
%    \begin{macrocode}
\def\papernumber#1{\def\currentpaper{#1}}
\papernumber{0000}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\startpage}
%   This defines the starting page of the paper.  We have some nice
%   features to set up roman page numbers for editorial
%   stuff---probably not needed for this journal at this time\dots
%    \begin{macrocode}
\def\startpage#1{\pagenumbering{arabic}\setcounter{page}{#1}%
  \def\start@page{#1}%
  \ifnum\c@page<\z@ \pagenumbering{roman}\setcounter{page}{-#1}%
    \def\start@page{\romannumeral#1}%
  \fi}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\endpage}
%   This macro again has a twist in it: if the argument is not set, it
%   calculates the last page number itself.
%    \begin{macrocode}
\def\endpage#1{\def\@tempa{#1}%
  \ifx\@tempa\@empty\def\end@page{\pageref{LastPage}}%
  \else\def\end@page{#1}\fi}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\pagespan}
%   This macro is different from the one provided by \progname{amsart}
%   because we want to have the option of automatic calculation of the
%   last page number.
%    \begin{macrocode}
\def\pagespan#1#2{\startpage{#1}\endpage{#2}}
\pagespan{1}{}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\g@addto@abstract}
% \changes{v1.21}{2017/12/13}{Added macro} 
% Syntactic sugar around \cs{g@addto@macro}
%    \begin{macrocode}
\def\g@addto@abstract#1{\g@addto@macro{\@aom@abstract}{#1}}
%    \end{macrocode}
% 
% \end{macro}
%
% \begin{macro}{\@getabstract}
% \changes{v1.21}{2017/12/13}{Added multilanguage abstracts} 
%   Amsart typesets the abstract in a box.  We preserve this
%   peculuarity, but we need to put abstract in a macro to output in
%   the rpi file.
%    \begin{macrocode}
\long\def\@aom@abstract{}
\long\def\@getabstract#1{%
  \bgroup
    \ifx\languagename\undefined
      \def\languagename{english}%
    \fi
    \g@addto@abstract{<begin abstract }%
    \expandafter\g@addto@abstract\expandafter{\languagename>}%
    \g@addto@macro\@aom@abstract{#1}%  
    \g@addto@abstract{<end abstract }%
    \expandafter\g@addto@abstract\expandafter{\languagename>}%
  \egroup
  \ifx\maketitle\relax
    \ClassWarning{aomart}{Abstract should precede
      \protect\maketitle\space in AMS derived classes}%
  \fi
  \global\setbox\abstractbox=\vtop\bgroup%
    \box\abstractbox
    \vglue1pc%
    {\centering\normalfont\normalsize\bfseries\abstractname\par\vglue1pc}%
    \list{}{\labelwidth\z@%
      \leftmargin3pc \rightmargin\leftmargin%
      \listparindent\normalparindent \itemindent\normalparindent%
      \parsep\z@ \@plus\p@%
      \let\fullwidthdisplay\relax%
    }%
    \item[]\normalfont\Small#1
  \endlist\egroup}
%    \end{macrocode}
%   
% \end{macro}
%
%
% \begin{macro}{abstract}
% \changes{v0.9}{2010/12/04}{Added parindent for the first par} 
% \changes{v1.16}{2016/12/03}{Redefined using environ} 
%   This puts abstract in a box \emph{and} in a macro.  Wasteful, but
%   backword compatible
%    \begin{macrocode}
\renewenvironment{abstract}{\Collect@Body\@getabstract}{%
  \ifx\@setabstract\relax\@setabstracta\fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\proposed}
% \changes{v0.3}{2010/09/26}{Added macro} 
% We do not typeset the name of the proposer
%    \begin{macrocode}
\let\proposed\@gobble
%    \end{macrocode} 
% \end{macro}
% \begin{macro}{\seconded}
% \changes{v0.3}{2010/09/26}{Added macro} 
% Or the seconder
%    \begin{macrocode}
\let\seconded\@gobble
%    \end{macrocode} 
% \end{macro}
% \begin{macro}{\corresponding}
% \changes{v0.3}{2010/09/26}{Added macro} 
% This is the corresponding author---again not typeset
%    \begin{macrocode}
\let\corresponding\@gobble
%    \end{macrocode} 
% \end{macro}
% \begin{macro}{\version}
% \changes{v0.3}{2010/09/26}{Added macro} 
% We do not typeset the current version of the manuscript either\dots 
%    \begin{macrocode}
\let\version\@gobble
%    \end{macrocode} 
% \end{macro}
%
% \begin{macro}{\doinumber}
% \changes{v0.3}{2010/09/26}{Added macro} 
% \changes{v1.0}{2010/12/21}{Added default} 
% \begin{macro}{\mrnumber}
% \changes{v0.3}{2010/09/26}{Added macro} 
% \begin{macro}{\zblnumber}
% \changes{v0.3}{2010/09/26}{Added macro} 
% \begin{macro}{\arxivnumber}
% \changes{v1.16}{2016/12/04}{Added macro} 
%   Now databases' numbers of the article:
%    \begin{macrocode}
\def\doinumber#1{\gdef\@doinumber{#1}}
\doinumber{10.4007/annals.\currentyear.\currentvolume.\currentissue.\currentpaper}
\def\mrnumber#1{\gdef\@mrnumber{#1}}
\mrnumber{}
\def\zblnumber#1{\gdef\@zblnumber{#1}}
\zblnumber{}
\def\arxivnumber#1{\gdef\@arxivnumber{#1}}
\arxivnumber{}
%    \end{macrocode}
%   
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\copyrightyear}
% \changes{v1.11}{2012/07/23}{Added macro} 
%   This is the copyright year in case it does not coincide with the
%   publication year:
%    \begin{macrocode}
\def\copyrightyear#1{\def\@copyrightyear{#1}}
\copyrightyear{}
%    \end{macrocode}
%   
% \end{macro}
% 
% \begin{macro}{\copyrightnote}
% \changes{v1.11}{2012/07/23}{Added macro} 
%   This is the copyrightnote.  The default has some trickery with the
%   year:
%    \begin{macrocode}
\def\copyrightnote#1{\def\@copyrightnote{#1}}
\copyrightnote{\textcopyright~%
  \ifx\@empty\@copyrightyear\currentyear\else\@copyrightyear\fi~%
  Department of Mathematics, Princeton University}
%    \end{macrocode}
%   
% \end{macro}
%
%\subsection{Typesetting Top Matter}
%\label{sec:maketitle}
%
%
% \begin{macro}{\@mainrpi}
% \changes{v1.14}{2014/03/03}{Added macro} 
% We write the information about the paper into file.rpi (the 
%   The stream for the rpi file:
%    \begin{macrocode}
\newwrite\@mainrpi
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\aom@write@paper@info}
% \changes{v1.14}{2014/03/04}{Added macro} 
% \changes{v1.16}{2016/12/03}{Added names, abstract, subjects,
% keywords, zblnumber, arxivnumber} 
% \changes{v1.16}{2016/12/03}{Corrected the endpage bug} 
% \changes{v1.20}{2017/05/09}{Make primary and secondary subjects
% separated}
% \changes{v1.21}{2017/12/13}{Added main language}
% \changes{v1.27}{2022/04/30}{Keep the .rpi file open till the end of
% document} 
% \changes{v1.35}{2025/05/25}{Added paper url} 
%   This writes the information about the paper into the file
%   |jobname.rpi|.  Note that hyperref makes our life a little bit
%   more complex
%    \begin{macrocode}
\def\aom@write@paper@info{%
  \bgroup
  \if@filesw
    \openout\@mainrpi\jobname.rpi%
    \def\and{\string\and\space}%
    \ifx\r@LastPage\@undefined
       \edef\@tempa{\start@page}%
    \else
       \def\@tempc##1##2##3##4##5{##2}%
       \edef\@tempa{\expandafter\@tempc\r@LastPage}%
   \fi
   \ifx\languagename\undefined
     \def\languagename{english}%
   \fi
   \protected@write\@mainrpi{}%
    {\@percentchar authors=\authors}%
   \protected@write\@mainrpi{}%
    {\@percentchar authors.information={\@names}}%
   \protected@write\@mainrpi{}%
    {\@percentchar title=\@title}%
   \protected@write\@mainrpi{}%
    {\@percentchar year=\currentyear}%
   \protected@write\@mainrpi{}%
    {\@percentchar volume=\currentvolume}%
   \protected@write\@mainrpi{}%
    {\@percentchar issue=\currentissue}%
   \protected@write\@mainrpi{}%
    {\@percentchar paper=\currentpaper}%
   \protected@write\@mainrpi{}%
    {\@percentchar startpage=\start@page}%
   \protected@write\@mainrpi{}%
    {\@percentchar endpage=\@tempa}%
   \protected@write\@mainrpi{}%
    {\@percentchar doi=\@doinumber}%
   \ifx\@zblnumber\@empty\else
   \protected@write\@mainrpi{}%
    {\@percentchar zbl=\@zblnumber}%
   \fi
   \ifx\@mrnumber\@empty\else
   \protected@write\@mainrpi{}%
    {\@percentchar mr=\@mrnumber}%
   \fi
   \ifx\@arxivnumber\@empty\else
   \protected@write\@mainrpi{}%
    {\@percentchar arxiv=\@arxivnumber}%
   \fi
   \protected@write\@mainrpi{}%
    {\@percentchar subjects=Primary \@primarysubjects; Secondary:
      \@secondarysubjects}% 
   \protected@write\@mainrpi{}%
    {\@percentchar keywords=\@keywords}%
   \protected@write\@mainrpi{}%
    {\@percentchar abstract=\@aom@abstract}%    
   \protected@write\@mainrpi{}%
     {\@percentchar articlelanguage=\languagename}%
   \def\paperUrl{https://annals.math.princeton.edu/\currentyear/\currentvolume-\currentissue/p\currentpaper}%
   \protected@write\@mainrpi{}%
     {\@percentchar paperUrl=\paperUrl}%
    \AtEndDocument{\closeout\@mainrpi}%
    \fi
\egroup}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\@maketitle@hook}
% \changes{v1.14}{2014/03/04}{Added macro} 
%   We add writing the information to the hook:
%    \begin{macrocode}
\def\@maketitle@hook{\aom@write@paper@info\global\let\@maketitle@hook\@empty}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\@settitle}
%   We do not uppercase title.  Also, we use this occasion to set PDF
%   information:
%    \begin{macrocode}
\def\@settitle{\begin{center}%
  \baselineskip20\p@\relax
    \bfseries\LARGE
  \@title
  \ifpdf
    \hypersetup{pdftitle=\@title}%
  \fi
  \end{center}%
}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\@setauthors}
% \changes{v0.6}{2010/11/04}{'By' and 'and' are in Roman font now} 
% \changes{v1.10}{2011/06/21}{Internationalization}
% \changes{v1.28}{2024/06/08}{Added treatment of orcids}
%   Now we typeset authors according to our specs.  Again, we use this
%   occasion to set some PDF information:
%    \begin{macrocode}
\def\@setauthors{%
  \ifx\authors\@empty\relax\else
    \begingroup
    \def\thanks{\protect\thanks@warning}%
    \trivlist
    \centering\footnotesize \@topsep30\p@\relax
    \advance\@topsep by -\baselineskip
    \item\relax
    \def\@@and{{\upshape \@aom@and}}%
    \author@andify\authors
    \ifpdf
      \bgroup
         \def\aom@orcidlink##1{}%
         \xdef\@tempa{\authors}%
      \egroup
      \hypersetup{pdfauthor=\@tempa}%
    \fi
    \def\\{\protect\linebreak}%
    \small \@aom@by{} \scshape\authors%
    \@processcurrentcontribgroup
    \ifx\@empty\contribs
    \else
      ,\penalty-3 \space \@setcontribs
    \fi
    \endtrivlist
    \endgroup
    \fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@setcontribs}
%   Contributors are set up in the same way as authors:
%    \begin{macrocode}
\def\@setcontribs{%
    \def\@@and{{\upshape \@aom@and}}%
    \author@andify\contribs
    \contribs
}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@adminfootnotes}
% \changes{v1.11}{2012/07/23}{Added copyright statement} 
% \changes{v1.20}{2017/05/09}{Make primary and secondary subjects separated} 
%   We do not typeset keywords, so we change the definition:
%    \begin{macrocode}
\def\@adminfootnotes{%
  \let\@makefnmark\relax  \let\@thefnmark\relax
  \ifx\@empty\@date\else \@footnotetext{\@setdate}\fi
  \ifx\@empty\@subjclass\else \@footnotetext{\@setsubjclass}\fi
  \ifx\@empty\@keywords\else\@setkeywords\fi
  \ifx\@empty\@primarysubjects
     \ifx\@empty\@secondarysubjects
     \else\@setsubjects\fi
  \else\@setsubjects\fi
  \ifx\@empty\thankses\else \@footnotetext{%
    \def\par{\let\par\@par}\@setthanks}%
  \fi
  \ifx\@empty\@copyrightnote\else \@footnotetext{%
    \def\par{\let\par\@par}\@copyrightnote\@addpunct.}%
  \fi
}
%    \end{macrocode}
%   
% \end{macro}
%
%
% \begin{macro}{\@setkeywords}
% \changes{v1.18}{2017/02/11}{Now we print keywords} 
%   Typesetting keywords
%    \begin{macrocode}
\def\@setkeywords{%
    \ifpdf
      \hypersetup{pdfkeywords=\@keywords}%
    \fi
    \if@aom@oldkeywords\else
    \@footnotetext{Keywords: \@keywords}%
    \fi
}  
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@setsubjects}
% \changes{v1.18}{2017/02/11}{Now we print subjects} 
% \changes{v1.20}{2017/05/09}{Make primary and secondary subjects separated} 
%   Setting subjects
%    \begin{macrocode}
\def\@setsubjects{%
  \let\@subjects\@empty
   \ifx\@primarysubjects\@empty\else
     \edef\@subjects{Primary:~\@primarysubjects}%
    \fi
   \ifx\@secondarysubjects\@empty\else
     \ifx\@primarysubjects\@empty
       \edef\@subjects{Secondary:~\@secondarysubjects}%
     \else
       \edef\@subjects{\@subjects; Secondary:~\@secondarysubjects}%
     \fi
    \fi
    \ifpdf
      \hypersetup{pdfsubject=\@subjects}%
    \fi
    \if@aom@oldkeywords\else
    \@footnotetext{AMS Classification:~\@subjects.}%
    \fi
}  
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\@@and}
% \changes{v0.9}{2010/12/04}{Redefined macro} 
% \changes{v1.10}{2011/06/21}{Added internationalization} 
%   We want ``and'' in the footers to be lowercase.  Since there is
%   some uppercase involved, we protect it:
%    \begin{macrocode}
\def\@@and{\MakeLowercase{\@aom@and}}
%    \end{macrocode}
%   
% \end{macro}
%
%\subsection{Typesetting End Matter}
%\label{sec:endmatter}
%
% End matter is typeset at the end of the paper.  
%
% \begin{macro}{\enddoc@text}
% \changes{v0.4}{2010/09/28}{Deleted many dates.} 
%   This is the main macro for typesetting endmatter.
%    \begin{macrocode}
\def\enddoc@text{%
  \ifx\@empty\@translators \else\@settranslators\fi
  \ifx\@empty\@received \else\@setreceived\fi
  \ifx\@empty\@revised \else\@setrevised\fi
  \ifx\@empty\addresses \else\@setaddresses\fi}
%    \end{macrocode}
% \end{macro}
% 
% \begin{macro}{\@setreceived}
% \begin{macro}{\@setrevised}
% \begin{macro}{\@setaccepted}
% \begin{macro}{\@setpublished}
% \begin{macro}{\@setpublishedonline}
% \changes{v0.5}{2010/10/24}{Decreased font} 
% \changes{v0.9}{2010/12/04}{Increased font} 
%   A bunch of macros for setting centered dates
%    \begin{macrocode}
\def\@setreceived{{\centering(Received: \@received)\par}}
\def\@setrevised{{\centering(Revised: \@revised)\par}}
\def\@setaccepted{{\centering(Accepted: \@accepted)\par}}
\def\@setpublished{{\centering(Published: \@published)\par}}
\def\@setpublishedonline{{\centering(Published online: \@publishedonline)\par}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\emailaddrname}
% \changes{v0.5}{2010/10/24}{Changed macro} 
% We do not want the word ``address'' here:
%    \begin{macrocode}
\def\emailaddrname{{\itshape E-mail}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@setaddresses}
% \changes{v0.5}{2010/10/24}{Deleted the word URL} 
% \changes{v0.5}{2010/10/24}{E-mail is now in Roman font} 
% \changes{v0.9}{2010/12/04}{Deleted spurious space in urladdress} 
% \changes{v1.2}{2011/01/05}{Changed font for current address} 
% \changes{v1.11}{2012/07/23}{Changed email handling} 
% \changes{v1.18}{2017/02/15}{Added orcid}
% \changes{v1.29}{2024/11/13}{Reformatted}
% \changes{v1.31}{2025/01/08}{Reformatted}
% \changes{v1.33}{2025/01/08}{No break after author name} 
%   The difference between our definition and the one in
%   \progname{amsart} is that we want the e-mail and URL to be clickable
%    \begin{macrocode}
\def\@setaddresses{\par
  \nobreak \begingroup
\footnotesize
  \def\author##1{\goodbreak\addvspace\bigskipamount{\scshape##1\par\nobreak}}%
  \def\\{\unskip, \ignorespaces}%
  \interlinepenalty\@M
  \def\address##1##2{\begingroup\nobreak
    \par\hangindent=22pt\hangafter=0\parindent=0pt
    \@ifnotempty{##1}{(\ignorespaces##1\unskip) }%
    {\ignorespaces##2}\par\endgroup}%
  \def\curraddr##1##2{\begingroup
    \@ifnotempty{##2}{\nobreak\indent\curraddrname
      \@ifnotempty{##1}{, \ignorespaces\scshape##1\unskip}\hskip0.2em:\space
      ##2\par}\endgroup}%
  \def\email##1##2{\begingroup
    \@ifnotempty{##2}{\nobreak\indent\emailaddrname
      \@ifnotempty{##1}{, \ignorespaces##1\unskip}\hskip0.2em:\space
      \href{mailto:##2}{\nolinkurl{##2}}\par\nobreak}\endgroup}%
  \def\urladdr##1##2{\begingroup
    \@ifnotempty{##2}{\nobreak\indent
      \@ifnotempty{##1}{, \ignorespaces##1\unskip}%
      \url{##2}\par\nobreak}\endgroup}%
  \def\orcid##1{\begingroup
    \@ifnotempty{##1}{\nobreak\indent
      \url{https://orcid.org/##1}\par\nobreak}\endgroup}%
  \addresses
  \endgroup
}
%    \end{macrocode}
%   
% \end{macro}
%
%
%\subsection{Sectioning}
%\label{sec:sectioning}
%
% \begin{macro}{\contentsnamefont}
%   This is the font for the word ``Contents'':
%    \begin{macrocode}
\renewcommand\contentsnamefont{\bfseries}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\section}
%   We want our sections to be centered and bold:
%    \begin{macrocode}
\def\section{\@startsection{section}{1}%
  \z@{.7\linespacing\@plus\linespacing}{.5\linespacing}%
  {\normalfont\bfseries\centering}}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\subsection}
% \changes{v0.5}{2010/10/24}{Redefined macro} 
% \changes{v1.2}{2011/01/05}{Decreased vertical spacing} 
% \changes{v1.4}{2011/01/21}{Deleted stretch in vertical spacing} 
%   We want our subsections to be indented and italic:
%    \begin{macrocode}
\def\subsection{\@startsection{subsection}{2}%
  {\parindent}{.5\linespacing}{-.5em}%
  {\normalfont\itshape}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\oldsubsections}
% \changes{v1.2}{2011/01/05}{Introduced macro} 
%   This macro restores the values for |\subsection| spacing prior to
%   v1.1.
%    \begin{macrocode}
\def\oldsubsections{%
\gdef\subsection{\@startsection{subsection}{2}%
  {\parindent}{.5\linespacing\@plus.7\linespacing}{-.5em}%
  {\normalfont\itshape}}}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\subsubsection}
% \changes{v1.4}{2011/01/21}{Introduced the macro} 
%   Subsubsections are formatted exactly like subsections:
%    \begin{macrocode}
\def\subsubsection{\@startsection{subsubsection}{3}%
  {\parindent}{.5\linespacing}{-.5em}%
  {\normalfont\itshape}}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\Hy@AlphNoErr}
% \changes{v1.13}{2012/10/26}{Added macro for older installations} 
%   The newer (circa 2012) hyperref defines this command.  However,
%   older versions do not.  Here we provide it:
%    \begin{macrocode}
\providecommand\Hy@AlphNoErr[1]{%
  \ifnum\value{#1}>26 %
    Alph\number\value{#1}%
  \else
    \ifnum\value{#1}<1 %
      Alph\number\value{#1}%
    \else
      \Alph{#1}%
    \fi
  \fi
}%
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\appendix}
% \changes{v1.6}{2011/03/06}{Redefined the macro} 
% \changes{v1.12}{2012/10/25}{Added hyperref definition} 
%   We redefine appendix to ensure the letter in section number is
%   always upright:
%    \begin{macrocode}
\def\appendix{\par\c@section\z@ \c@subsection\z@
  \gdef\theHsection{\Hy@AlphNoErr{section}}%
   \let\sectionname\appendixname
   \def\thesection{{\upshape\@Alph\c@section}}}
%    \end{macrocode}
%   
% \end{macro}
%
%\subsection{Figures and Tables}
%\label{sec:figs}
%
% \begin{macro}{\@captionheadfont}
%   This is the font for the words ``Figure'' or ``Table'' in
%   captions.  Unlike \progname{amsmath} with is small caps, we want
%   just plain Roman font:
%    \begin{macrocode}
\def\@captionheadfont{\normalfont}
%    \end{macrocode}   
% \end{macro}
%
%
%
%
%\subsection{Theorems}
%\label{sec:theorems}
%
% Here we redefine three main style of \progname{amsart}.  Here are
% the arguments of |\newtheoremstyle| from~\cite{Downes04:amsart}:
%\begin{verbatim}
%                   #1
% \newtheoremstyle{NAME}%
%     #2          #3          #4
%   {ABOVESPACE}{BELOWSPACE}{BODYFONT}%
%     #5      #6        #7         #8
%   {INDENT}{HEADFONT}{HEADPUNCT}{HEADSPACE}%
%     #9
%   {CUSTOM-HEAD-SPEC}
%\end{verbatim}
%
%
% \changes{v0.4}{2010/09/28}{Changed plain theorem style} 
% In the |plain| style the name (``theorem'') is in small caps, the
% number is in normal font, the optional note  is also
% in normal font, and the text is italics.
%    \begin{macrocode}
\newtheoremstyle{plain}{0.5\linespacing}{0.5\linespacing}{\sishape}%
   {\parindent}{\scshape}{.}{0.5em}%
   {\thmname{#1}\thmnumber{ #2}\thmnote{\normalfont{} (#3)}}
%    \end{macrocode}
%
% \changes{v0.4}{2010/09/28}{Changed definition theorem style} 
% In the |definition| style the name is italics, and the body font is
% upright: 
%    \begin{macrocode}
\newtheoremstyle{definition}{0.5\linespacing}{0.5\linespacing}%
   {\upshape}{\parindent}%
   {\sishape}{.}{0.5em}%
   {\thmname{#1}\thmnumber{ #2}\thmnote{\normalfont{} (#3)}}
%    \end{macrocode}
%
% \changes{v0.4}{2010/09/28}{Deleted remark theorem style} 
% \changes{v0.5}{2010/10/24}{Made remark theorem style identical to
% definition theorem style} 
% In our class there is no difference between |remark| and
% |definition| theorem styles: 
%    \begin{macrocode}
\newtheoremstyle{remark}{0.5\linespacing}{0.5\linespacing}%
   {\upshape}{\parindent}%
   {\sishape}{.}{0.5em}%
   {\thmname{#1}\thmnumber{ #2}\thmnote{\normalfont{} (#3)}}
%    \end{macrocode}
%
% \begin{macro}{\newtheorem}
% \changes{v0.3}{2010/09/26}{Redefined macro} 
% For compatibility reasons we need to accept |\newtheorem| with
% optional first argument---and silently drop it.  The problem is,
% there is |\newtheorem*|, so we need to check which one we deal
% with\dots{}  The command |\@xnthm| here is from \progname{amsthm};
% it does the real work with the real parameters.
%    \begin{macrocode}
\renewcommand{\newtheorem}{\@ifstar{\@aom@newthm@star}{\@aom@newthm}}
\def\@aom@newthm@star{\@ifnextchar[{\@aom@newthm@star@}{\@aom@newthm@star@[]}}
\def\@aom@newthm{\@ifnextchar[{\@aom@newthm@}{\@aom@newthm@[]}}
\def\@aom@newthm@star@[#1]{\@xnthm *}
\def\@aom@newthm@[#1]{\@xnthm \relax}
%    \end{macrocode}
%   
% \end{macro}
% 
% \begin{macro}{proof}
% \changes{v0.5}{2010/10/24}{Redefined macro} 
%   We want our proofs to be indented:
%    \begin{macrocode}
\renewenvironment{proof}[1][\proofname]{\par
  \pushQED{\qed}%
  \normalfont \topsep6\p@\@plus6\p@\relax
  \trivlist
  \item[\hskip\labelsep\hskip\parindent
        \itshape
    #1\@addpunct{.}]\ignorespaces
}{%
  \popQED\endtrivlist\@endpefalse
}
%    \end{macrocode}
% \end{macro}
%
%
%\subsection{Bibliography Macros}
%\label{sec:bibl}
%
% \begin{macro}{\repeatedauthors}
% \changes{v1.11}{2012/08/16}{Now this command is obsolete} 
%   When the authors are repeated, we used change them to |\bysame|;
%   we no more do this:
%    \begin{macrocode}
\def\repeatedauthors#1{\ClassWarning{aomart}{The command is obsolte}#1}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\bysame}
% \changes{v1.11}{2012/08/16}{Made the macro obsolete}
%   We no longer use \cmd{\bysame}
%    \begin{macrocode}
\let\bysame@@orig=\bysame
\def\bysame{\ClassWarning{aomart}{We no longer omit
    repeated authors}\bysame@@orig}
%    \end{macrocode}
%
% \end{macro}
%
% \begin{macro}{\doi}
% \changes{v1.2}{2011/01/05}{Now we properly treat numbers with underscores} 
% \changes{v1.9}{2011/06/13}{Changed doi look} 
% \changes{v1.10}{2011/06/21}{Introduced the logic for old doi
% formatting} 
% \changes{v1.15}{2016/11/18}{Doi according to the new Crossref
% recommendations}  
%   Typesetting doi\dots
%    \begin{macrocode}
\def\doi#1{%
  \if@aom@doiMMXVI
     \url{http://dx.doi.org/#1}%
  \else
     \if@aom@olddoi
         \href{http://dx.doi.org/#1}{doi: \path{#1}}%
      \else
          \url{https://doi.org/#1}%
      \fi
  \fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\mr}
% \changes{v0.3}{2010/09/27}{Added macro} 
% \changes{v1.2}{2011/01/05}{Now we properly treat numbers with underscores} 
% \begin{macro}{\zbl}
% \changes{v0.3}{2010/09/27}{Added macro} 
% \changes{v0.6}{2010/10/03}{Changed capitalization} 
% \changes{v1.2}{2011/01/05}{Now we properly treat numbers with underscores} 
% \begin{macro}{\arxiv}
% \changes{v0.3}{2010/09/27}{Added macro} 
% \changes{v1.2}{2011/01/05}{Now we properly treat numbers with
% underscores} 
% \changes{v1.5}{2011/02/26}{Typo corrected} 
% \begin{macro}{\jfm}
% \changes{v0.10}{2010/12/18}{Added macro} 
% \changes{v1.2}{2011/01/05}{Now we properly treat numbers with underscores} 
%   Typesetting urls
%    \begin{macrocode}
\def\mr#1{\href{http://www.ams.org/mathscinet-getitem?mr=#1}{MR~\path{#1}}}
\def\zbl#1{\href{http://www.zentralblatt-math.org/zmath/en/search/?q=an:#1}{Zbl~\path{#1}}}
\def\arxiv#1{\href{http://www.arxiv.org/abs/#1}{arXiv~\path{#1}}}
\def\jfm#1{\href{http://www.emis.de/cgi-bin/JFM-item?#1}{JFM~\path{#1}}}
%    \end{macrocode}
%   
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\bibliofont}
% \changes{v0.6}{2010/10/03}{Changed default} 
%   We make this |\small| rather than |\Small| in \progname{amsart}
%    \begin{macrocode}
\renewcommand{\bibliofont}{\small}
%    \end{macrocode}
%   
% \end{macro}
%
%\subsection{Additional Macros}
%\label{sec:additional}
%
% \begin{macro}{\c@aom@EC@counter}
% \changes{v1.34}{2025/05/06}{Added macro}
% The counter for editorial comments
%    \begin{macrocode}
\newcounter{aom@EC@counter}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\EditorialComment}
% \changes{v0.3}{2010/09/28}{Added macro}
% \changes{v1.32}{2025/01/25}{Rewrote macro, adding levels}
% \changes{v1.34}{2025/05/06}{Rewrote the macro} 
%   This macro is  tiny marginpar in
%   manuscript mode
%    \begin{macrocode}
\NewDocumentCommand\EditorialComment{O{default} +m O{0pt}}{%
  \if@aom@manuscript@mode\bgroup
  \expandafter\ifx\csname EditorialComment@#1\endcsname\relax\else
    \stepcounter{aom@EC@counter}%
    \setlength\unitlength{1sp}%
    \zsavepos{aom@EC@position\arabic{aom@EC@counter}}%
    \begin{picture}(0,0)%
      \put(\the\dimexpr
      -\zposx{aom@EC@position\arabic{aom@EC@counter}}sp + 15pt,#3){%
        \parbox{80pt}{\raggedright
          \normalfont\scriptsize\raggedright\expandafter\color\expandafter{%
            \csname EditorialComment@#1\endcsname}#2}}%
    \end{picture}%
  \fi
  \egroup
\fi}
%    \end{macrocode}   
% \end{macro}
%
% \begin{macro}{\ECSelect}
% \changes{v1.32}{2025/01/25}{Added macro}
% \changes{v1.34}{2025/04/13}{Added colors}
%    \begin{macrocode}
\newcommand\ECSelect[2][black]{\if@aom@manuscript@mode
    \expandafter\gdef\csname
    EditorialComment@#2\endcsname{#1}% 
  \fi}
\AtBeginDocument{\ECSelect{default}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\Highlight}
% \changes{v1.32}{2025/01/25}{Added macro}
%    \begin{macrocode}
\newcommand\Highlight[2][default]{%
  \expandafter\ifx\csname Highlight@#1\endcsname\relax
  #2\else
  \csname Highlight@#1\endcsname{#2}\fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\HSelect}
% \changes{v1.32}{2025/01/25}{Added macro}
%    \begin{macrocode}
\newcommand\HSelect[2][red]{\if@aom@manuscript@mode
  \@for\TC@level:=#2\do{\expandafter
    \gdef\csname Highlight@\TC@level\endcsname##1{\bgroup
      \Hy@colorlinksfalse
      \def\Hy@colorlink####1{\begingroup}%
      \def\Hy@endcolorlink{\endgroup}%                         
      \color{#1}##1\egroup}}%
  \fi}
\AtBeginDocument{\HSelect{default}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@fullref}
% \changes{v0.5}{2010/10/24}{Added macro} 
%   This macro creates a wide link for the reference.  It has four
%   parameters: the word (theorem, equation,\dots), the ``pre''
%   punctuation, the reference and the ``post'' punctuation.
%    \begin{macrocode}
\def\@fullref#1#2#3#4{\hyperref[#3]{#1~#2\ref*{#3}#4}}
%    \end{macrocode}
% \end{macro}
% \begin{macro}{\fullref}
% \changes{v0.5}{2010/10/24}{Added macro} 
%   A reference without parentheses:
%    \begin{macrocode}
\newcommand{\fullref}[2]{\@fullref{#1}{}{#2}{}}
%    \end{macrocode}
% \end{macro}
% \begin{macro}{\pfullref}
% \changes{v0.5}{2010/10/24}{Added macro} 
%   A reference with parentheses:
%    \begin{macrocode}
\newcommand{\pfullref}[2]{\@fullref{#1}{(}{#2}{)}}
%    \end{macrocode}   
% \end{macro}
% \begin{macro}{\bfullref}
% \changes{v0.5}{2010/10/24}{Added macro} 
%   A reference with brackets:
%    \begin{macrocode}
\newcommand{\bfullref}[2]{\@fullref{#1}{[}{#2}{]}}
%    \end{macrocode}   
% \end{macro}
% \begin{macro}{\eqfullref}
% \changes{v0.5}{2010/10/24}{Added macro} 
%   Here we do not use the standard common |\@fullref| because we want
%   |\eqref| to work\dots
%    \begin{macrocode}
\newcommand{\eqfullref}[2]{\hyperref[#2]{#1~\textup{\tagform@{\ref*{#2}}}}}
%    \end{macrocode}   
% \end{macro}
% \begin{macro}{\fullpageref}
% \changes{v1.25}{2021/04/10}{Added macro} 
%   A wide link for page reference.  Note that the word ``page'' can
%   be omitted
%    \begin{macrocode}
\newcommand{\fullpageref}[2][page]{\hyperref[#2]{#1~\pageref*{#2}}}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\eqnarray}
% \changes{v0.9}{2010/12/04}{Redefined standard macro} 
%   While we do \emph{not} recommend the use of |eqnarray|, we still
%   would like to correct the ugly spacing around it\dots
%    \begin{macrocode}
\def\eqnarray{%
   \stepcounter{equation}%
   \def\@currentlabel{\p@equation\theequation}%
   \global\@eqnswtrue
   \m@th
   \global\@eqcnt\z@
   \tabskip\@centering
   \let\\\@eqncr
   $$\arraycolsep1\p@
   \everycr{}\halign to\displaywidth\bgroup
       \hskip\@centering$\displaystyle\tabskip\z@skip{##}$\@eqnsel
      &\global\@eqcnt\@ne\hskip \tw@\arraycolsep \hfil${##}$\hfil
      &\global\@eqcnt\tw@ \hskip \tw@\arraycolsep
         $\displaystyle{##}$\hfil\tabskip\@centering
      &\global\@eqcnt\thr@@ \hb@xt@\z@\bgroup\hss##\egroup
         \tabskip\z@skip
      \cr
}
%    \end{macrocode}
%   
% \end{macro}
%
% \begin{macro}{\includecolorgraphics}
% \changes{v1.32}{2025/01/25}{Added macro}
% Color graphics: select either the first or the second argument.
%    \begin{macrocode}
\newcommand\includecolorgraphics[3][]{\if@aom@screen@mode
  \includegraphics[#1]{#2}\else
  \includegraphics[#1]{#3}\fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@aom@sponsors}
% \changes{v1.35}{2022/05/25}{Added macro} 
% The list of sponsors, separated by |\and|
%    \begin{macrocode}
\def\@aom@sponsors{}
\AtEndDocument{%
  \ifx\@aom@sponsort\@empty\else
     \protected@write\@mainrpi{}%
     {\@percentchar grants=\@aom@sponsors}%
  \fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\funding}
% \changes{v1.27}{2022/04/30}{Added macro} 
% The macro to print grants.  It adds to the rpi file the information
% about grants
%    \begin{macrocode}
\newcommand\funding[3][]{%
  \ifx\@aom@sponsors\@empty
     \gdef\@aom@sponsors{sponsor=#2, grantid=#3}%
  \else
     \g@addto@macro{\@aom@sponsors}{\protect\and sponsor=#2, grantid=#3}%
  \fi
     \def\@tempa{#1}\relax%
     \ifx\@tempa\@empty\relax
       \def\@tempb{#3}%
        #2%
        \ifx\@tempb\@empty\relax\else\ (grant~#3)\fi
     \else
        #1
     \fi}
%    \end{macrocode}
% 
% \end{macro}
%
%\subsection{End of Class}
%\label{end}
%
%
%    \begin{macrocode}
%</class>
%    \end{macrocode}
%
%\Finale
%\clearpage
%
%\PrintChanges
%\clearpage
%\PrintIndex
%
\endinput
