# [pstricks] problem in equation numbering

hh-brasil at bol.com.br hh-brasil at bol.com.br
Thu Apr 18 19:34:51 CEST 2013

Dear kari,

I would put the label command within the equation (before the "end{equation}")

hh

Em 18/04/2013 12:45, Kari Eloranta < kari.eloranta at mac.com > escreveu:
This might not be a pstricks related question, but any help is greatly appreciated. I have created a macro

\newcommand{\info}[1]{%
\vskip10pt
\noindent\psframebox*[framesep=10pt,%
fillstyle=solid,%
fillcolor=yellow!55,%
linecolor=black]{\parbox[c][\height][s]{\textwidth-18pt}
{\noindent  #1}}
}

which draws a filled yellow box around #1. If I call the macro with

\info{{\blue Resistance}\\%
The resistance of an electrical component is
$$R=\frac{V}{I}$$\label{eq:res}
where $V$ is the potential difference across the component, and $I$ the electric current flowing through it.}

the equation number (label) becomes 1.20 in the output pdf. However, when I try use \ref{eq:res} to reference the equation, the reference tag is 1.10 instead of 1.20. Recompiling does not help. Is there a solution to this problem?

Best regards,
Kari
_______________________________________________
PSTricks mailing list
PSTricks at tug.org
http://tug.org/mailman/listinfo/pstricks
archive: http://www.tug.org/pipermail/pstricks/