Autonum.info Direct
\enddocument
autonum is often preferred over mathtools ’ showonlyrefs because autonum works with more environments and handles \label placement more robustly. \documentclassarticle \usepackageamsmath \usepackage[colorlinks]hyperref \usepackagecleveref \usepackageautonum \begindocument
\beginequation g(x) = \sqrtx \labeleq:root \endequation
\enddocument
\usepackageautonum \documentclassarticle \usepackageamsmath \usepackageautonum \begindocument
\enddocument
\beginequation f(x) = x^2 \labeleq:square \endequation autonum.info
\sectionTest
We only refer to \eqrefeq:first. Hence only the first line gets a number.
% This equation will be numbered because it is referenced below \beginequation E = mc^2 \labeleq:einstein \endequation \enddocument autonum is often preferred over mathtools ’
1. Overview The autonum package (found at autonum.info ) provides a sophisticated solution for managing equation numbering in LaTeX documents. Its core purpose is to automatically control which equations receive numbers based on whether they are referenced elsewhere in the text.
\beginalign x &= y + z \labeleq:first \ a &= b - c \labeleq:second \endalign