[comp.text.tex] Help with LaTeX label and ref

seiler@ccwf.cc.utexas.edu (Carl Seiler) (12/11/90)

Help, I'm having trouble with \label and \ref commands in LaTeX.

In my paper of documentstyle "article", I have several equations that
need to be labeled and referenced in the text.  Here's part of my
*.tex file:

  The cartel will picks a price schedule which will maximize the
  sum of its discounted profits over the time period, i.e.:
  \begin{equation} \max W = \sum_{t=1}^{N}  (1/(1+d)^{t}) (P_{t} -
     m/R_{t} ) D_{t}
  \label{eq:obj}
  \end{equation}
  where $m/R_{t}$ is the average production cost and $d$ is the

and later I have...

  adding a term to the equation ~\ref{eq:obj} so that the
  $D_{t}(P_{t}-m/R_{t})$ portion becomes $D_{t}(P_{t}-m/R_{t}-b

And when I run it through LaTex, I get the message:

Reference `eq:obj' on page 8 undefined.

What's the problem here?  I KNOW I have referenced every single
equation, as above, and NONE of them have worked.  I had to go back in
and manually reference each one, and it worked fine.  There's nothing
wrong with my label declaration I don't think, because Tex doesn't
complain about not knowing what the control sequence is.

Please help soon.  I'm running out of time. >grin, who isn't<

-<Carl>-
...who will do it manually if he has to.
-- 
__________________________________________________________________________
Carl Seiler, Economics, U.T. Austin | INTERNET: seiler@ccwf.cc.utexas.edu
          FidoNet: 1:382/27 -- Carl_Seiler@f86.n382.z1.fidonet.org

cen466p@vaxc.cc.monash.edu.au (12/11/90)

In article <41098@ut-emx.uucp>, seiler@ccwf.cc.utexas.edu (Carl Seiler) writes:
> Help, I'm having trouble with \label and \ref commands in LaTeX.
>
> In my paper of documentstyle "article", I have several equations that
> need to be labeled and referenced in the text.  Here's part of my
> *.tex file:
>
> Reference `eq:obj' on page 8 undefined.
>
> What's the problem here?

You may have to compile the same file with LaTeX again.  That is, in order to
get the cross-references correct, you have to compile it twice. Do not delete
the .aux from the first compilation.  Infact, if you allow the first compilation
to completion, you will find this message. "Re-run to get cross references
correct". Hope this Helps.

Parthasarathy Seshadri
Down Under