Numbering an array as one single equation LaTeX
I would recommend you use the equation
environment if you want a single equation for an entire array
.
However, since this construct does not really seem to need an array
, I would recommend using the align
environment from the amsmath
package, with which you can use \nonumber
to selectively disable an equation number.
Notes:
Use of
eqnarray
is not recommended as per \eqnarray vs \align.Also you should not use double dollar signs for display math as per Why is
\[ … \]
preferable to$$
?The math spacing in you array example was not correct. This has been corrected in the example below.
References:
- An excellent reference for math mode is Herbert Voss' comprehensive review of mathematics in (La)TeX.
Code:
\documentclass{article}
\usepackage{amsmath}
\begin{document}\noindent
Using \verb|equation| with \verb|array|:
\begin{equation}
\begin{array}{r@{}l}
N_{x,sk} &{}= k_{sk}\left(\frac{t_{sk}}{b_{sk}}\right)^{2}\bar{Et}\\
N_{x,st} &{}= k_{st}\left(\frac{t_{st}}{b_{st}}\right)^{2}\bar{Et}
\end{array}
\end{equation}
%
Using \verb|align|:
\begin{align}
N_{x,sk} &= k_{sk}\left(\frac{t_{sk}}{b_{sk}}\right)^{2}\bar{Et}\\
N_{x,st} &= k_{st}\left(\frac{t_{st}}{b_{st}}\right)^{2}\bar{Et}
\end{align}
%
Using \verb|align| with \verb|\nonumber|:
\begin{align}
N_{x,sk} &= k_{sk}\left(\frac{t_{sk}}{b_{sk}}\right)^{2}\bar{Et}\nonumber\\
N_{x,st} &= k_{st}\left(\frac{t_{st}}{b_{st}}\right)^{2}\bar{Et}
\end{align}
\end{document}
Using the eqnarray
environment instead of array
, you can add \nonumber
to any lines you don't want numbered. If you don't do this, every line will be numbered.
\begin{eqnarray}
N_{x,sk} &=& k_{sk}\left(\frac{t_{sk}}{b_{sk}}\right)^{2}\bar{Et} \nonumber \\
N_{x,st} &=& k_{st}\left(\frac{t_{st}}{b_{st}}\right)^{2}\bar{Et}
\end{eqnarray}
(Just remove the \nonumber
from the above to get the second example.)