You are on page 1of 2

LATEX 2ε Cheat Sheet Lists Verbatim text

\begin{enumerate} Numbered list. \begin{verbatim} Verbatim environment.


\begin{itemize} Bulletted list. \begin{verbatim*} Spaces are shown as .
Document classes \verb!text! Text between the delimiting characters (in
book Default is two-sided. \begin{description}Description list.
\item text Add an item. this case !) is verbatim.
report No \part divisions.
article No \part or \chapter divisions. \item[x ] text Use x instead of normal bullet or number.
Required for descriptions.
Justification
letter Letter (?). Environment Declaration
slides Large sans-serif font. \begin{center} \centering
References
Used at the very beginning of a document: \begin{flushleft} \raggedright
\documentclass{class}. Use \begin{document} to start \label{marker } Set a marker for cross-reference, often of the
\begin{flushright} \raggedleft
contents and \end{document} to end the document. form \label{sec:item}.
\ref{marker } Give section/body number of marker. Miscellaneous
Common documentclass options \pageref{marker } Give page number of marker.
\linespread{x} changes the line spacing by the multiplier x.
10pt/11pt/12pt Font size. \footnote{text} Print footnote at bottom of page.
letterpaper/a4paper Paper size. Text-mode symbols
twocolumn Use two columns. Floating bodies
twoside Set margins for two-sided. \begin{table}[place] Add numbered table. Symbols
landscape Landscape orientation. Must use dvips \begin{figure}[place] Add numbered figure. & \& \_ ... \ldots • \textbullet
-t landscape. \begin{equation}[place] Add numbered equation. $ \$ ˆ \^{} | \textbar \ \textbackslash
draft Double-space lines. \caption{text} Caption for the body. % \% ˜ \~{} # \# | \textbar
Usage: \documentclass[opt,opt]{class}. The place is a list valid placements for the body. t=top,
h=here, b=bottom, p=separate page, !=place even if ugly. Accents
Packages ò \‘o ó \’o ô \^o õ \~o ō \=o
Captions and label markers should be within the environment.
fullpage Use 1 inch margins. ȯ \.o ö \"o o̧ \c o ǒ \v o ő \H o
anysize Set margins with \marginsize{l}{r }{t}{b}. ç \c c o. \d o o \b o o
o \t oo œ \oe
multicol Use n columns with \begin{multicols}{n}.
Text properties Œ \OE æ \ae
¯
Æ \AE å \aa Å \AA
latexsym Use LATEX symbol font. Font face ø \o Ø \O l \l L \L ı \i
Use before \begin{document}. Usage: \usepackage{package}  \j ¡ ~‘ ¿ ?‘
Command Declaration Effect
Title \textrm{text} {\rm text} Roman family Delimiters
\author{text} Author of document. \textsf{text} {\sf text} Sans serif family ‘‘ “ ‘‘ { \{ [[ (( < \textless
\title{text} Title of document. \texttt{text} {\tt text} Typewriter family ’’ ” ’’ } \} ]] )) > \textgreater
\date{text} Date. \textmd{text} {\md text} Medium series
These commands go before \begin{document}. The \textbf{text} {\bf text} Bold series Dashes
declaration \maketitle goes at the top of the document. \textup{text} {\up text} Upright shape Name Source Example Usage
\textit{text} {\it text} Italic shape hyphen - X-ray In words.
Miscellaneous \textsl{text} {\sl text} Slanted shape en-dash -- 1–5 Between numbers.
\pagestyle{empty} Empty header, footer and no page num- \textsc{text} {\sc text} Small Caps shape em-dash --- Yes—or no? Punctuation.
bers. \emph{text} {\em text} Emphasized
\textnormal{text}{\normalfont text}Document font Line and page breaks
Document structure \underline{text} Underline \\ Begin new line without new paragraph.
\part{title} \subsubsection{title} The command (tttt) form handles spacing better than the \\* Prohibit pagebreak after linebreak.
\chapter{title} \paragraph{title} declaration (tttt) form. \kill Don’t print current line.
\section{title} \subparagraph{title} \pagebreak Start new page.
\subsection{title} Font size \noindent Do not indent current line.
Section commands can be followed with an *, like
\section*{title}, to supress heading numbers.
\tiny tiny \Large Large Miscellaneous
\setcounter{secnumdepth}{x} supresses heading numbers of
\scriptsize scriptsize
\footnotesize footnotesize
\LARGE LARGE \today
$\sim$
May 11, 2002.
Prints ∼ instead of \~{}, which makes ˜.
depth > x, where chapter has depth 0.

Text environments
\small small
\normalsize normalsize
\huge huge ~ Space, disallow linebreak (W.J.~Clinton).

\begin{comment} Comment block (not printed).


\begin{quote} Indented quotation block.
\large large \Huge Huge \@. Indicate that the . ends a sentence when following
an uppercase letter.
\hspace{l} Horizontal space of length l (Ex: l = 20pt).
\begin{quotation}Like quote with indented paragraphs. These are declarations and should be used in the form {\small \vspace{l} Vertical space of length l.
\begin{verse} Quotation block for verse. . . . } or without braces to affect the entire document. \rule{w}{h} Line of width w and height h.
Tabular environments Citation types The LATEX document should have the following two lines just
\cite{key} Full author list and year. (Watson and Crick before \end{document}, where bibfile.bib is the name of the
tabbing environment
1953) BibTEX file.
\= Set tab stop. \> Go to tab stop.
\citeA{key} Full author list. (Watson and Crick)
Tab stops can be set on “invisible” lines with \kill at the end \bibliographystyle{plain}
\citeN{key} Full author list and year. Watson and Crick
of the line. Normally \\ is used to separate lines. \bibliography{bibfile}
(1953)
tabular environment \shortcite{key} Abbreviated author list and year. ?
\begin{array}[pos]{cols} \shortciteA{key} Abbreviated author list. ? BibTEX example
\begin{tabular}[pos]{cols} \shortciteN{key} Abbreviated author list and year. ? The BibTEX database goes in a file called file.bib, which is
\begin{tabular*}{width}[pos]{cols} \citeyear{key} Cite year only. (1953) processed with bibtex file.
All the above have an NP variant without parentheses; Ex.
tabular column specification \citeNP. @String{N = {Na\-ture}}
l Left-justified column. @Article{WC:1953,
c Centered column.
BibTEX entry types author = {James Watson and Francis Crick},
r Right-justified column. @article Journal or magazine article. title = {A structure for Deoxyribose Nucleic Acid},
p{width} Same as \parbox[t]{width}. @book Book with publisher. journal = N,
@{decl} Insert decl instead of inter-column space. @booklet Book without publisher. volume = {171},
| Inserts a vertical line between columns. @conference Article in conference proceedings. pages = {737},
@inbook A part of a book and/or range of pages. year = 1953
tabular elements @incollection A part of book with its own title. }
\hline Horizontal line between rows. @manual Technical documentation.
\cline{x-y} Horizontal line across columns x through y. @mastersthesis Master’s thesis.
\multicolumn{n}{cols}{text} @misc If nothing else fits.
Sample LATEX document
A cell that spans n columns, with cols column \documentclass[11pt]{article}
@phdthesis PhD. thesis.
specification. \usepackage{fullpage}
@proceedings Proceedings of a conference.
\title{Template}
Math mode @techreport Tech report, usually numbered in series.
\author{Name}
@unpublished Unpublished.
To use math mode, surround text with $ or use \begin{document}
\begin{equation}. BibTEX fields \maketitle
^{x} Superscriptx _{x} Pn
Subscript x address Address of publisher. Not necessary for major
\frac{x}{y} xy
\sum_{k=1}^n publishers. \section{section}
√ k=1
\sqrt[n]{x} n x author Names of authors, of format .... \subsection*{subsection without number}
booktitle Title of book when part of it is cited. text \textbf{bold text} text. Some math: $2+2=5$
Math-mode symbols chapter Chapter or section number. \subsection{subsection}
≤ \leq ≥ \geq 6= \neq edition Edition of a book. text \emph{emphasized text} text. \cite{WC:1953}
· \cdot × \times ÷ \div editor Names of editors. discovered the structure of DNA.
∗ \ast ◦ \circ ··· \cdots institution Sponsoring institution of tech. report.
α \alpha β \beta γ \gamma journal Journal name. A table:
δ \delta  \epsilon ε \varepsilon key Used for cross ref. when no author. \begin{table}[!th]
ζ \zeta η \eta θ \theta month Month published. Use 3-letter abbreviation. \begin{tabular}{|l|c|r|}
ϑ \vartheta ι \iota κ \kappa note Any additional information. \hline
λ \lambda µ \mu ν \nu number Number of journal or magazine. first & row & data \\
ξ \xi π \pi ρ \rho organization Organization that sponsors a conference. second & row & data \\
σ \sigma τ \tau υ \upsilon pages Page range (2,6,9--12). \hline
φ \phi χ \chi ψ \psi publisher Publisher’s name. \end{tabular}
ω \omega Γ \Gamma ∆ \Delta school Name of school (for thesis). \caption{This is the caption}
Θ \Theta Λ \Lambda Ξ \Xi series Name of series of books. \label{ex:table}
Π \Pi Σ \Sigma Υ \Upsilon title Title of work. \end{table}
Φ \Phi Ψ \Psi Ω \Omega type Type of tech. report, ex. “Research Note”.
Special symbols volume Volume of a journal or book. The table is numbered \ref{ex:table}.
year Year of publication. \end{document}
◦ ^{\circ} Ex: 22◦ C: $22^{\circ}\mathrm{C}$.
Not all fields need to be filled. See example below.
Bibliography and citations Common BibTEX style files Copyright c 2002 Winston Chang
When using BibTEX, you need to run latex, bibtex, and $Revision: 1.4 $, $Date: 2002/03/18 20:40:59 $.
abbrv Standard abstract alpha with abstract
latex twice more to resolve dependencies. http://www.stdout.org/∼winston/latex/
alpha Standard apa APA
plain Standard unsrt Unsorted

You might also like