0

Sorry if this is stupid but writing

$$ \begin{array}{c}  \label{cycle LP}
    \text{min} \ \ \ w^t x \\
    \text{s.t.}  \sum_{C \in \mathcal{C}} x_v \geq 1  \\
    x \geq 0 
     \end{array} $$

the label does not appear how do I make the label appear?

0

Hope you meant label is the equation number, if yes, please try with the following code:

\documentclass{book}
\usepackage{mathtools}
\begin{document}

\begin{equation}\label{cycle LP}
\begin{split}
    \min w^t x \\
    \text{s.t.}  \sum_{C \in \mathcal{C}} x_v \geq 1  \\
    x \geq 0 
     \end{split}
\end{equation}

enter image description here

PS: Don't use $$ for unnumbered equations, it was one of an old PlainTeX tags. please use \[...\] instead of $$

  • can arrays not be labelled? I guess multiline equation is pretty similar but the non centering is a bit annoying – Hao S Sep 3 at 16:02
  • @HaoS Agreed... – MadyYuvi Sep 4 at 4:53
  • 1
    @HaoS - You asked, "can arrays not be labelled"? Short answer: No. Longer answer: Not unless you create an entire new code superstructure -- which does not exist by default in either the LaTeX kernel or any of the main LaTeX document classes. Incidentally, is there a reason for not wishing to cross-reference a displayed equation that contains the array environment of interest? – Mico Oct 3 at 6:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.