number several equations with only one number

前端 未结 2 1085
深忆病人
深忆病人 2021-01-30 10:37

How can I number several equations in a align environment using only one number?

For example

\\begin{align}
w^T x_i + b \\geqslant 1-\\xi_i \\text{ if }         


        
2条回答
  •  粉色の甜心
    2021-01-30 11:24

    How about something like:

    \documentclass{article}
    
    \usepackage{amssymb,amsmath}
    
    \begin{document}
    
    \begin{equation}\label{A_Label}
      \begin{split}
        w^T x_i + b \geqslant 1-\xi_i \text{ if } y_i &= 1, \\
        w^T x_i + b \leqslant -1+\xi_i \text{ if } y_i &= -1
      \end{split}
    \end{equation}
    
    \end{document}
    

    which produces:

提交回复
热议问题