\documentclass[landscape]{slides}
\oddsidemargin=0in
\topmargin=-1in
\textwidth=10in
\textheight=7in
\parskip=0in
\usepackage{pstcol,pst-char,pst-grad}
\usepackage{graphicx,color}
\usepackage{array,amsmath}
\usepackage{url}
\usepackage{float}
\usepackage{openbib}


\definecolor{backgroundcolor}{rgb}{.5,0,0}
\definecolor{textcolor}{rgb}{1,1,1}
\definecolor{headcolor}{rgb}{1,1,0}
\definecolor{fillcolor}{rgb}{.8,0,0}
\definecolor{filllcolor}{rgb}{.3,0,0}
\definecolor{gradbegin}{rgb}{0,1,0}
\definecolor{gradend}{rgb}{0,0,1}

\def\TeX{T\kern-.15em\lower.5ex\hbox{E}X}
\newcommand{\slt}[1]{\hfill\textcolor{headcolor}{\Large\textbf{#1}}\hfill\hbox{}\vfill\raggedright\par}
\newcommand{\code}[1]{\texttt{#1}}
\newlength\contboxwidth
\newcommand{\cont}{\setbox0=\hbox{\small\space(continued)}%
	\contboxwidth=\wd0\box0\hspace{-\contboxwidth}}
\def\abovecaptionskip{5ex}

\let\saveendslide=\endslide
\let\saveendoverlay=\endoverlay
\renewcommand{\endslide}{\vfill\saveendslide}
\renewcommand{\endoverlay}{\vfill\saveendoverlay}
\let\saveslide=\slide
\renewcommand{\slide}{\saveslide\flushright}
\let\saveoverlay=\overlay
\renewcommand{\overlay}{\saveoverlay\flushright}

\title{\mbox{}\vspace{-10ex}\textcolor{headcolor}{
\begin{flushright}\Huge\bfseries
\TeX, \LaTeX, and Farsi\TeX
\end{flushright}
}}
\author{\mbox{}\vfill\vspace{-8ex}\textcolor{textcolor}{
\begin{flushright}\Large
Hamed Hatami\\[-1ex]
\texttt{hatami@ce.sharif.edu}\\
Behdad Esfahbod\\[-1ex]
\texttt{behdad@sharif.edu}%
\end{flushright}
}}
\date{\mbox{}\vfill\textcolor{headcolor}{%
\begin{flushright}
Computer Engineering Department\\
Sharif University of Technology\\
Tehran, Iran\\
\today
\end{flushright}
}}

\pagecolor{backgroundcolor}
\color{textcolor}
\begin{document}
\color{textcolor}

\hspace{-6em}
\smash{
\raisebox{-\textheight}{
\includegraphics[height=.9\textheight,keepaspectratio=true]{tex.eps}
}
}\\
\maketitle

\slide
\thispagestyle{empty}
\begin{pspicture}(0,0)(10,10)
\fontfamily{ptm}\selectfont
\pscharpath[fillstyle=gradient,
	gradangle=30,gradbegin=gradbegin,gradend=gradend,
	linecolor=black,linewidth=1.5pt]
{\fontsize{.66in}{.66in}\selectfont
\parbox{\textwidth}{\begin{center}\bfseries
``Things have changed in the past dacades.'', quotes Professor
Donald Knuth from Bill Gates.  The \TeX\ system is known to have
revolutionized the art of computer typesetting in the past three
decades.  After talking about the history of \TeX, we will turn
to \LaTeX\ and focus on what it offers an author, to reduce the
time spent on style and work on the content.
\end{center}}}
\end{pspicture}
\endslide

\slide
\slt{What is \TeX}
\begin{itemize}
\item A computer language designed for use in typesetting;
particularly, for typesetting math and other \TeX nical
(from greek \emph{techne}, i.e. art/craft, the stem of \emph{technology}) material.
\item {\Large $\tau\varepsilon\chi$}, pronounced similar to ``blecch'',
not to the state known for ``Tex-Mex'' chili.
\end{itemize}
\endslide

\slide
\slt{History of \TeX}
\begin{itemize}
\item In the late 1970s, Donald Knuth of Stanford University, was not satisfied
when he saw first samples of the new computer typesetting for the second volume
of his multivolume opus \emph{The Art of Computer Programming}.
\item He set out to learn what were the traditional rules for typesetting math.
\item A year after Knuth was invited by the American Math Society (AMS).
The topic he presented was his new work on \TeX.
\end{itemize}
\endslide

\slide
\slt{History of \TeX\cont}
\begin{itemize}
\item \TeX\ came along just before the beginnings of the personal computer.
It was developed on one of the last of the \emph{academic} mainframes.
\item It was very quickly ported to some early HP workstations and,
as they emerged, the new personal systems.
\item After some highly useful enhancements in about 1990,
Tex handles the composition of many different languages according to
their own traditional rules, and is for this reason quite widely used
in eastern Europe.
\end{itemize}
\endslide

\slide
\slt{Why did \TeX\ Attract Scientists}
\begin{itemize}
\item It was intended to be used directly by authors
(and their secretaries) who are the ones who really know
what they are writing about.
\item It came from an academic source, and was intended
to be available for no monetary fee.
\item It was available on just about any computer and operating system.
\end{itemize}
\endslide

\slide
\slt{Why did \TeX\ Attract Scientists\cont}
\begin{itemize}
\item Other systems available at the time for mathematical composition were:
\begin{itemize}
\item proprietary,
\item very expensive,
\item often limited to specific hardware,
\item if WYSIWYG\footnote{What You See Is What You Get},
the same expression in two places in the same
document might very well not look the same,
never mind look the same if processed on two different systems.
\end{itemize}
\end{itemize}
\endslide

\slide
\slt{Main Features of \TeX}
\begin{itemize}
\item A \TeX\ system can stand on its own,
provided all the fonts one needs are available.
It does not require any other application.
\item The \TeX\ macro language is an interpreted one:
\begin{itemize}
\item It produces a \emph{device independent} output file in
\code{.dvi} format.
\item It can be run on any operating system.
\item Running TeX on different platforms result in
exactly identical outputs.
\end{itemize}
\item \TeX\ and its friends are available freely with source code.
Moreover, the \TeX\ itself is not even copyrighted.
\end{itemize}
\endslide

\slide
\slt{Main Features of \TeX\cont}
\begin{itemize}
\item Instead of the user, \TeX\ automatically tries thousands of
combinations of line breaks and page breaks on every job, picking the most
charming one.
\item You do not need to specify the exact appearance of everything.
Whenever you leave something unspecified, it knows how to
conform to standard practice of the used stylesheet.
\item There are many tools, fonts, and macros developed for \TeX.
Moreover, there is a \TeX\ engine named pdf\TeX, which produces \code{pdf} files
directly.
\end{itemize}
\endslide

\slide
\slt{Main Features of \TeX\cont}
\begin{itemize}
\item The command language is very low level (skip so much space,
change to font \emph{X}, set this string of words in paragraph form, ...),
but is amenable to being enhanced by defining macro commands to build a
very high level user interface.
\item \TeX\ has a very powerful algorithmical base.
Some of the algorithms in \TeX, for example the paragraph breaking algorithm,
have not been bettered in any of the composition tools devised in the years
since \TeX\ appeared.
\item \TeX\ has all the paraphernalia of academic publishing, e.g. footnotes,
floating insertions (figures and tables), etc.
\end{itemize}
\endslide

\slide
\slt{Main Features of \TeX\cont}
\begin{itemize}
\item A text written in \TeX\ is a plain ASCII file
with markup codes inserted, for example
\begin{verbatim}
$$ % begin displayed math
\left(\prod^{n}_{i=1}\prod^{c_i-1}_{j=0}
(n-j)!^{\frac{1}{n-j}}\right)
\le
\frac{ n!^n e^{n(3+\frac{\ln(2\pi n)^2}{4})} }
{(n-\frac{k}{n})!^n e^k}
$$ % end displayed math
\end{verbatim}
will produce:
$$\left(\prod^{n}_{i=1}\prod^{c_i-1}_{j=0}
(n-j)!^{\frac{1}{n-j}}\right) \le \frac{n!^n e^{n(3+\frac{\ln(2\pi
n)^2}{4})} }{(n-\frac{k}{n})!^n e^k}$$
\end{itemize}
\endslide

\slide
\slt{Main Features of \TeX\cont}
\begin{itemize}
\item \TeX\ files can be typed, viewed, and edited with any file editor or
word processor.
\item \TeX\ You do not have to worry about whether subtle details
of typography are visible on the screen.
Instead, you type \TeX\ commands and \TeX\ will set exactly what you tell it to.
\item A completely separate file called a style sheet (actually a set of
\TeX\ macros) defines what the commands like \verb|\chapter| and \verb|\section|
and their kin, actually should do. The typist does not have to worry about the
physical layout or consistency of chapter or section headings on the screen.
\end{itemize}
\endslide

\slide
\slt{Main Features of \TeX\cont}
\begin{itemize}
\item It is designed for archival purposes.  The same document
will produce exactly the same output ten years later, with the \TeX\ of
that era.
\item It is designed for batch processing.  The input file to \TeX\ is
in a text file, so you can easily create your project result tables automatically
as a \TeX\ input file, process it, and get a nice \code{pdf}.
\item \dots
\end{itemize}
\endslide

\slide
\slt{\TeX\ and Other Systems}
\begin{itemize}
\item Alternatives to \TeX\ are FrameMaker and Adobe InDesign, which both
are professional typesetting systems.
\item Microsoft Word is not counted as a professional typesetting
system, but a word processor.
\item \TeX\ both produces the high quality of a typesetting system,
and holds the ease of use of a word processor.
\end{itemize}
\endslide

\slide
\slt{\TeX\ versus Microsoft Word}
\begin{itemize}
\item \TeX's math mode is a thing of beauty.
Equations come out looking perfect.
\item Unlike Word files, \TeX\ documents are small and clean.
\item In \emph{What You See Is What You Get} word processors,
it is very hard to write a large consistent text.
\item \TeX\ versions are compatible. A given Word file produces
different results on different versions of Word, so all the painstaking
effort you put in getting a perfect document in version 7 is broken in
version 8.
\end{itemize}
\endslide

\slide
\slt{\TeX\ versus Microsoft Word\cont}
\begin{itemize}
\item  Unlike \TeX, Microsoft Word is not available for all
operating systems.
\item There are no \TeX\ \emph{macro} viruses.
You can safely receive TeX documents by email and not worry
about it reading your address book and mailing copies
of itself to all your friends. 
\item The typesetting algorithm employed by Microsoft Word
sacrifices quality to the speed required for setting and resetting type of the
user's input in real time.
The final product is greatly inferior to that of a real typesetting system.
\end{itemize}
\endslide

\slide
\slt{When Should We Use It}
\begin{itemize}
\item \TeX\ is the best tool for writing a scientific text, but
\item If you want a tool for producing a newspaper or a novel or
a slick advertisement or a letter to Aunt Henrietta,
\TeX\ is not the tool for you.\footnote{\TeX\ is actually in use
for producing many scientific and \TeX nical magazines and journals.}
\item Professor Knuth in an interview has said that:
\begin{quote}
I never expected TeX to be the universal thing that people would
turn to for the quick-and-dirty stuff.
I always thought of it as something that you turned to if you
cared enough to send the very best.
\end{quote}
\end{itemize}
\endslide

\slide
\slt{Bugs of \TeX}
\begin{itemize}
\item Donald Knuth, a professor of computer science at Stanford
University and the author of numerous books on computer science and
the TeX composition system,
rewards the first finder of each typo or computer program bug with
a check based on the source and the age of the bug.
\item Typos and other errors in books typically yield \$2.56
each once a book is in print
(pre-publication \emph{bounty-hunter} photocopy editions are priced at \$.25 per).
\item Program bugs' cost rise by powers of 2 each year from \$2.56  to
a maximum of \$327.68.
\item So you can imagine how bug-free is \TeX!
\end{itemize}
\endslide

\begingroup
\textwidth=\paperwidth
\topmargin=-5cm
\parindent=0em
\parskip=0em
\raisebox{1.5cm}{
\includegraphics[width=.55\textwidth,height=\textheight,keepaspectratio=true]{don-hires.eps}
}
\hspace{-1cm}
\raisebox{.5\textheight}{
\begin{pspicture}(0,0)(9,10)
\fontfamily{ptm}\selectfont
\pscharpath[fillstyle=solid,linecolor=black,
	fillcolor=filllcolor,linewidth=.1pt]
{\fontsize{1.5in}{1.5in}\selectfont
\parbox{0\textwidth}{
\bfseries \begin{flushright} Donald\\ Ervin\\ Knuth \end{flushright}
}}
\end{pspicture}
}
\endgroup
\newpage

\slide
\slt{What is \LaTeX}
\begin{itemize}
\item The \TeX\ language is very low level.
\item Originally \TeX\ comes with a package called plain.
\item There are many high level macro packages available.
\item The most popular is \LaTeX, another one is Con\TeX t.
\item \LaTeX\ knows how to format each logical part of the
document.
\item \LaTeX\ is Leslie Lamport's high level definition of a document,
later developed by the \LaTeX\ Project Team.
\end{itemize}
\endslide

\slide
\slt{Structure of a \LaTeX\ Document}
\begin{itemize}
\item Starts with a preamble.  The preamble is logically structured as below:
\begin{itemize}
\item The document class definition (e.g. \verb|\documentclass{article}|).
\item Include packages used (e.g. \verb|\usepackage{color}|).
\item Configuration (e.g. \verb|\textwidth=10in|).
\item User macro definitions (e.g. \verb|\definecolor{backgroundcolor}{rgb}{.5,0,0}|).
\end{itemize}
\item The document body.  Starts with \verb|\begin{document}| and ends with
\verb|\end{document}|.
\item Everything after the body is ignored.
\end{itemize}
\endslide

\slide
\slt{\LaTeX\ Document Classes}
\begin{itemize}
\item There are some predefined classes:
\begin{itemize}
\item \textbf{article}
\item \textbf{report}
\item \textbf{book}
\item \textbf{letter}
\item \textbf{slides}
\end{itemize}
\item It is always possible to define new classes based on availble
ones, or from scratch.
\end{itemize}
\endslide

\slide
\slt{Structure of the Document Body}
Structure of the document body depends on the document class
used, but for articles, reports, and books it is something like
this:
\begin{itemize}
\let\x\item
\def\item{\vspace{-2ex}\x}
\item Title, Author, and Date definitions
\item The title of the document
\item The table of contents
\item The abstract
\item Parts, Chapters, Sections, Subsections, etc, in a
nested manner
\item Appendices
\item The Bibliography
\item The Index
\end{itemize}
\endslide

\slide
\slt{Structure of a Simple Article}
\begin{quote}
\obeylines\obeyspaces\tt\def\\{\char"5C}\parskip=0em
\\documentclass\{article\} \% the standard class `{}`article'{}'
\\begin\{document\}
\\maketitle
\\begin\{abstract\} ... \\end{abstract}
\\section\{...\}
\\section\{...\}
\   \\subsection\{...\}
\      \\subsubsection\{...\}
\\section\{...\}
\\begin\{thebibliography\} ... \\end\{thebibliography\}
\\end\{document\}
\end{quote}
\endslide

\slide
\slt{Structure of a Simple Book}
\begingroup
\small
\begin{quote}
\obeylines\obeyspaces\tt\def\\{\char"5C}\parskip=0em
\\documentclass\{book\} \% the standard class `{}`book'{}'
\\begin\{document\}
\%--------------------- front matter of the document
\\maketitle
\  \\section*\{...\}     \% e.g. section named like ``Preface''
\\tableofcontents     \% chapter with the table of contents
\\listoffigures       \% chapter with the list of figures
\\listoftables        \% chapter with the list of tables
\%--------------------- body of the document
\\part\{...\}
\\chapter\{...\}
\   \\section\{...\}
\\chapter\{...\}
\\part\{...\}
\%--------------------- back matter of the document
\\appendix            \% following chapters are appendices
\\chapter\{...\}
\\chapter\{...\}
\\begin\{thebibliography\} ... \\end\{thebibliography\}
\\begin\{theindex\}        ... \\end\{theindex\}
\\end\{document\}
\end{quote}
\endgroup
\endslide

\slide
\slt{Other Things \TeX\ and \LaTeX\ Take Care of}
\begin{itemize}
\item Footnotes\footnote{This is a footnote}
(e.g. \verb|Footnotes\footnote{This is a footnote}|)
\item Floats (Tables and Figures)
\item Equations
\item Theorems and friends
\item References
\item Index terms
\item Citations
\end{itemize}
\endslide

\slide
\slt{Properties Shared by All Objects}
\begin{itemize}
\item New objects of all kinds can be defined.
\item All objects are automatically numbered in its own way.
\item Numbering of different objects can be defined to follow your own style.
\item Objects without number or caption can be declared.
\end{itemize}
\endslide

\slide
\slt{Float Objects}
\begin{itemize}
\item A float object is a box with a type and caption.
\item Table and Figure are already defined as floats.
\item New floats can be defined.  For example, there is a package to
define an Algorithm float object.
\item List of floats of a type can be placed anywhere in the document.
\item Floats are automatically placed in top of a page, or at the end
of the chapter or document.
\item A float can be forced to be placed where it is defined.
\end{itemize}
\endslide

\slide
\slt{A Simple Float}
\begingroup
\small
\begin{verbatim}
\newfloat{algorithm}{h}{alg}
\floatname{algorithm}{Algorithm}
\begin{algorithm}
\caption{No comments}
\label{errless}
\begin{center}
\begin{enumerate}
\item Err and err and err again
\item but less and less and less
\end{enumerate}
\end{center}
\end{algorithm}
\end{verbatim}
\newfloat{algorithm}{h}{alg}
\floatname{algorithm}{Algorithm}
\begin{algorithm}
\caption{No comments}
\label{errless}
\begin{center}
\begin{enumerate}
\item Err and err and err again
\item but less and less and less
\end{enumerate}
\end{center}
\end{algorithm}
\endgroup
\endslide

\slide
\slt{Theorem-like Objects}
\begin{itemize}
\item These are objects like Theorem, Lemma, Corollary, Congecture,
etc.
\item New theorem-like objects can be defined.
\item Like all other objects, they can be numbered globally, or inside
a part, chapter, section, etc.
\item They are defined simply by \verb|\newtheorem{lemma}{Lemma}|
\newtheorem{lemma}{Lemma}
\item They can be used by \verb|\begin{lemma}\label{texlovers}Anyone ... \end{lemma}|:
\begin{lemma}
\label{texlovers}
Anyone heard of \TeX\ would use it to typeset her thesis.
\end{lemma}
\end{itemize}
\endslide

\slide
\slt{Refrences}
\begin{itemize}
\item A point to be refrenced is defined by \verb|\label{labelname}|.
\item To refer to a defined lable, you use \verb|\ref{labelname}|.
\item \LaTeX\ knows what kind of object the label is refering to
and puts the object's number.
\item Refrences to page numbers of objects is also supported.
Moreover, \LaTeX\ can also handle refrences to objects in the
same page, facing page, next or previous page.
\item For example \verb|Lemma \ref{texlovers} and Algorithm \ref{errless}| will
produce: Lemma \ref{texlovers} and Algorithm \ref{errless}.
\end{itemize}
\endslide

\slide
\slt{Indexes}
\begin{itemize}
\item An occurence of an index term in the document is identified
by \verb|\index{term}|.
\item A program called \code{makeindex} takes care of merging,
sorting, and preparing the index.
\item The \verb|\begin{theindex} ... \end{theindex}| puts the
index in the document.
\end{itemize}
\endslide

\slide
\slt{Citations}
\begin{itemize}
\item Citations in the text are made by \verb|\cite{refname}|.
\item References are then defined in the
\verb|\begin{thebibliography} ... \end{thebibliography}|.
\item There is a program named Bib\TeX, which can extract used
refrences from a big set of reference definition file.
\end{itemize}
\endslide

\slide
\slt{The Slides Class}
\begin{itemize}
\item Each slide is placed between \verb|\begin{slide} ... \end{slide}|.
\item The slides come out highly readable, and well spaced.
\item As there is almost no fancy feature, the audience's focus will
be on the content.
\item There is a package\footnote{\code{stepslid}, by Behdad Esfahbod}
which enables parts of an slide to become visible in the next step.
\end{itemize}
\endslide

\slide
\slt{What is Farsi\TeX}
\begin{itemize}
\item Farsi\TeX\ is a Persian enabled version of \LaTeX.
\item The current release of Farsi\TeX\ is based on the old
\LaTeX 2.09.  The current version of \LaTeX\ is \LaTeXe.
\item Farsi\TeX\ supports almost all features of article, book,
report, and letter classes, but not slides.
\item All you need to use Farsi\TeX\ is the editor and macros.
The rest is simply \LaTeX.
\end{itemize}
\endslide

\slide
\slt{Where to Find Them}
\begin{itemize}
\item \TeX\ Users Group's (TUG) Home Page at
\url{http://www.tug.org/} is the best place to look
for \TeX\ related tools and articles.
\item \TeX, \LaTeX, and all of their tools, fonts, etc can be found on
Comprehensive \TeX\ Archive Network (CTAN) set of CDs,
downloadable from \url{http://dante.de/}.
\item Farsi\TeX, is available from
\url{http://www.farsitex.org/}.
\end{itemize}
\endslide
\slide
\slt{Where to Find Them\cont}
\begin{itemize}
\item There are many distributions:
\begin{itemize}
\item \TeX live, by Sebastian Rahtz, is a set of CDs, ready to run under Windows,
Linux, MacOS, etc.  It can be downloaded from
\url{http://dante.de/} too.
\item MiK\TeX\, by Christian Schenk, is a distribution for Microsoft Windows.  It is
available from \url{http://www.miktex.org/}.
\item te\TeX\, by Thomas Esser, is a distribution for Unices
(based on Karl Berry's kpathsea, and web2c), but
ported to Windows under Cygwin, and also as another distribution
named fp\TeX, by Fabrice Popineau.  It is distributed by almost all Linux
distributions, as well as Cygwin.
\end{itemize}
\end{itemize}
\endslide

\slide
\slt{Conclusions}
The \LaTeX\ system has become the \emph{de-facto} standard for
typesetting mathematical and technical papers, reports, and books.  We
have shown some of the aspects of \TeX, and \LaTeX\ and mostly
attracts authors all around the world to set type of their work
themselves with \LaTeX.  Interested audience are encouraged to read
\emph{\LaTeX, A Document Preparation System}, and then get their hands
on \LaTeX, to feel what is known as the spirit of \TeX.

Farsi\TeX, as a Persian enabled \LaTeX\ system, is widely used in
Iranian academic centers, but as we mentioned, it is far from a modern
Persian \LaTeX\ system.  Work is getting done to port Farsi\TeX\ to
the latest standards of \LaTeX\ system.
\endslide

\slide
\slt{Refrences}
\hoffset=1em
\parindent=-1em
\parskip=2ex

Knuth, Donald. \emph{The \TeX book}.  Addison-Wesley, 1996.

Knuth, Donald. \emph{Digital Typography}.  CLSI Publications, 1999.

Lamport, Leslie.  \emph{\LaTeX, A Document Preparation System}.  Addison-Wesley, 1994.

Goossens, Michel, Frank Mittelback, and Alexander Samarin.  \emph{The \LaTeX\ Companion}.
Addison-Wesley, 1994.

\TeX\ Users Group Home Page.  Available at \url{http://www.tug.org/}.

Nordhaug, Hans Fredrik. ``Why \TeX''.  Available at \url{http://www.mi.uib.no/~hansfn/tex/advocacydft.pdf}.

\endslide

\end{document}

\slide
\slt{}
\begin{itemize}
\item
\end{itemize}
\endslide
