Updated «align» section
This commit is contained in:
parent
a524eda084
commit
98c52b7678
11
lbol.tex
11
lbol.tex
@ -7,6 +7,7 @@
|
||||
\usepackage{graphicx}
|
||||
\usepackage{kpfonts}
|
||||
\usepackage{float}
|
||||
\usepackage{longtable}
|
||||
\raggedbottom
|
||||
|
||||
\usepackage{nicefrac}
|
||||
@ -849,28 +850,30 @@ You can typeset matrices and other similar objects using an \texttt{array} envir
|
||||
|
||||
\begin{itemize}[noitemsep]
|
||||
\item \texttt{array} can only be used in a math environment.
|
||||
\item You must declare the number and alignment of the columns by using \verb+\begin{array}{ccl}+. In this instance, we are declaring two centered columns and one left-aligned column.
|
||||
\item You must declare the number and alignment of the columns by using \verb+\begin{array}{crl}+. In this instance, we are declaring one centered column, one right-aligned column, and one left-aligned column.
|
||||
\end{itemize}
|
||||
|
||||
In the example below, I've chose animal names to make the column alignment more explicit.
|
||||
|
||||
\begin{Verbatim}[frame=lines, numbers=left, xleftmargin=5mm, framesep=3mm, breaklines=true, label=array Example]
|
||||
\[
|
||||
Zoo~animals = \left\{ \begin{array}{crl}
|
||||
lion & tiger & gnu \\
|
||||
lion & hippopotamus & gnu \\
|
||||
elephant & zebra & kangaroo \\
|
||||
bear & camel & wallaby
|
||||
\end{array}\right\}
|
||||
\]
|
||||
\end{Verbatim}
|
||||
|
||||
|
||||
\[
|
||||
Zoo~animals = \left\{ \begin{array}{crl}
|
||||
lion & tiger & gnu \\
|
||||
lion & hippopotamus & gnu \\
|
||||
elephant & zebra & kangaroo \\
|
||||
bear & camel & wallaby
|
||||
\end{array}\right\}
|
||||
\]
|
||||
|
||||
If the built-in \texttt{array} environment cannot do all that you want, use the \texttt{amsmath} package and its \texttt{matrix} environment, which provides more options.
|
||||
|
||||
\section{Special Math Environments}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user