[pdftex] Automatic custom equation numbers, hyperref and \ref*

Heiko Oberdiek oberdiek at uni-freiburg.de
Tue Feb 21 14:25:41 CET 2006


On Tue, Feb 21, 2006 at 06:19:27AM -0500, Victor Ivrii wrote:

> I have equation which is numbered automatically, currently as (2.12)
> (for example)
> and labeled by \label{A}.
> 
> Now, I want to create equation numbered as (2.12)^* and changing its
> number automatically as number of equation labeled by A changes.
> The logical and working construction is
> \begin{equation}
> 1+1=2
> \tag*{$(\ref{A})^*$}
> \label{B}
> \end{equation}
> 
> however with hyperref it would create a nested hyperlink which behaves
> in funny way:
> 
> (\ref{B}) blah-blah-blah
> 
> looks as (2.12)^* blah-blah-blah  and (2.12)^* is clickable (a correct
> link) but blah-blah-blah becomes clickable too with the link to the
> first page.

A minimal example would have shown your problem, e.g. about
warnings about already defined destinations.

I wouldn't use equation and eqnarray with amsmath. Because of
compatibility issues they aren't too well supported.

\begin{gather}
1+1=2
\tag*{$(\ref*{A})^*$}
\label{B}
\end{gather}

or (references aren't math)

\tag*{(\ref*{A})\textsuperscript{\textasteriskcentered}}

Yours sincerely
  Heiko <oberdiek at uni-freiburg.de>
-- 



More information about the pdftex mailing list