Sie sind auf Seite 1von 22

B K THAKKAR

What is LaTex?

TeX is a typesetter
You

write and TeX will place it on the page

TeX

LaTeX

Advantages
g of LaTex

Professional typesetting
yp
g

Best output

It is the standard for scientific documents


Processing Mathematical (& other) symbols
Meaning based structuring (rather than
appearance)
Knowledgeable and helpful user group
Its FREE!
Platform independent

Disadvantages
g of LaTex

Hard
Hard to write disorganized documents
documents*

Learning Curve

C
Customizing
i i iis tedious.
di

* Taken verbatim from Not so short introduction to LaTeX

LaTex Paradigm
g

What You See is NOT What You Get

Unlike Microsoft Word!!!


Word !!!

A Simple
p LaTex Document
\documentclass{article}
\begin{document}
This is some sample text.
text
\end{document}

Another Sample
p
\documentclass{article}
\title{Simple Example}
\author{Andrei Gurtov}
\date{March 2000}
\begin{document}
\maketitle
Hello
ll world!
ld!
\end{document}

Parts of a LaTex File

Document Class
Predefined Formats (article, report, book,..).

Packages used
Added Functionality (graphics, reference style,...).

Main Body
y
Text and Bibliography References.

Basics

Document Class
\documentclass[options]{class}
options = a4paper, 11pt, 12pt, 10pt, twocolumn, landscape,...
class = article,
article report,
report book,...
book

Packages
\usepackage{package name}
epsfig = insert PS pictures into the document
fancyhdr = easy definition of footer and header

Parts of a LaTeX Document: Preamble

Everything between \documentclass and


\begin{document}
Use for customizing the formatting

Body
y of Text

Start with \begin{document}


End with \end{document}
Typesetting Text
\\ or \newline and \newpage
Quotations
Q
Bold \textbf{} or \bf
Italics \emph{} or \textit{} or \it
Underline \underline{} or \ul

Format

Sections
\section{}
= 1. Latex is Great
\subsection{}
= 1.1 Why Latex is Great
\subsubsection{} = 1.1.1 Reason One
\appendix - changes numbering scheme
\chapter{}
\chapter{ } - To be used with book and report
document classes

Titles, Authors and others


\title{}
\footnote{}

\author{}

Format (Contd.)
(
)

\maketitle - Display Title and Author


\tableofcontents - generates TOC
\listoftables - generates LOT
\listoffigures - generates LOF
Labels

\label{marker} - Marker in document.


\pageref{marker} - Displays page no. of marker.
\ref{marker} - Displays section location of marker.

It i
Itemize

Use either enumerate, itemize or description.


see handout for example.

Font Size
\tiny \scriptsize

\footnotesize

\small \normalsize

\large \Large

\
\LARGE
\h
\huge

\Huge

Mathematics
Calculus
\i t 0^\i ft
\int_0^\infty
\frac{\partial u}{\partial x}

\i t{\i t}
\int{\int}

Mathematics (Contd)
(
)
x = \frac{-b \pm \sqrt{b^2-4ac} } {2a}

Figures
g
& Tables

Figures & Tables cannot be broken between pages


They are floated
floated

\begin{figure}
\includegraphics{sample}
\\caption{A
p
{ sample
p figure.}
g }
\end{figure}

Images
g

Use epsfig package

\usepackage{epsfig}

I l di iimages iin main


Including
i b
body
d

\epsfig{file=filename.eps,
width 10cm height
width=10cm,
height=9cm,
9cm angle
angle=90}
90}

Creating EPS - Use xv and/or xfig.


MS Power Point, save as GIF and convert to
EPS.

Bibliography
g p y
\begin{thebibliography}{}
\bibitem[Come95]{Come95} Comer,
D E.,
D.
E {\it Internetworking with TCP/IP:
Principles, Protocols and Architecture},
volume
l
1
1, 3rd
3 d edition.
di i Prentice-Hall,
P
i H ll
1995.
\end{thebibliography}

Output
p Formats

.dvi
.ps
.pdf
pdf
.rtf
.html
ht l
.xml

Device Independent
Post Script
PDF
Rich Text Format
HTML
XML

Benefits

Automatic equation numbering

Automatic reference citation

A
Automatic
i fi
figure numbering
b i

Automatic figure placement

Closure

LaTex gives better quality documents compared to


Microsoft Word

Eases preparation of large documents

Has become the industry standard world wide

Das könnte Ihnen auch gefallen