1 / 33

Introduction to Latex

Introduction to Latex. Introduction. TeX is essentially a Markup Language (like HTML, XML and RTF) TeX written by Donald Knuth in 70´s A revolution in typesetting Latex is an extension of TeX Macro packages to make TeX easier to use. Latex vs. Word Processors. High typeset quality

jaclynf
Télécharger la présentation

Introduction to Latex

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to Latex

  2. Introduction • TeX is essentially a Markup Language (like HTML, XML and RTF) • TeX written by Donald Knuth in 70´s • A revolution in typesetting • Latex is an extension of TeX • Macro packages to make TeX easier to use

  3. Latex vs. Word Processors • High typeset quality • Easy to include math formulas • Easy to deal for formatting images and tables inside text paragraphs. • Good for large documents • Source file format is not bounded to a particular OS or platform • Latex implementations exists for all platforms (Windows, Mac,..) • Latex is free

  4. Example of Latex document \documentclass{article} \title{Simple Example} \author{Ahmed Ali} \date{November 2015} \begin{document} \maketitle Hello world! \end{document}

  5. Example of Latex document

  6. Downloading Latex MiKTeX : a complete LaTeX system for Windows. http://www.miktex.org/ TeXnicCenter: an open-source editor and development environment for LaTeX files (Windows). http://www.texniccenter.org/

  7. Latex File Structure • Document Class Predefined Formats (article, report, book,..). • Packages used Added Functionality (graphics, reference style,...). • Main Body Text and Bibliography References.

  8. The Basics • Document Class \documentclass[options]{class} • options = a4paper, 11pt, 12pt, 10pt, twocolumn, landscape,... • class = article, report, book,... • Packages \usepackage{package name} • Package name : (examples) • epsfig = insert PS pictures into the document. • fancyhdr = easy definition of footer and header. • hyperref = manage links/URL within the document. • graphicx= insert graphic files within a document.

  9. Body of Text • Start with \begin{document} • End with \end{document} • Typesetting Text • \\ or \newlineand \newpage • Quotations • Bold \textbf{……………} or\bf • Italics \emph{…………}or \textit{………} or \it • Underline \underline{…………} or\ul

  10. 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. • Itemize • Use either enumerate, itemize or description.

  11. Body of Text cont… The .tex extension is optional • Using Multiple Files • \input{filename.tex} • \include{filename.tex} This is a good idea to separate the formatting from the real writing and to split the large documents into small parts. Main differences between \input and \include :

  12. Body of Text cont… \input \include

  13. Format • Sections and subsection • \section{Latex is Great} 1. Latex is Great • \subsection{Why Latex is Great} 1.1 Why Latex is Great • \subsubsection{Reason one}1.1.1 Reason One • Titles, Authors and others • \title{…} • \author{…} • \date{…}

  14. Lists • Two types of lists • itemize  Bullets • enumerate  Numbering Lists can be recursive (nested) • Formats • \begin{itemize} • \item …… • \item …… • \end{itemize} • \begin{enumerate} • \item …… • \item …… • \end{enumerate}

  15. Lists

  16. Example of Latex document

  17. Bibliography using Bibtex • Bibliography information is stored in a *.bib file, in Bibtex format. • Include chicago package • \usepackage{chicago} • Set referencing style • \bibliographystyle{chicago} • Create reference section by • \bibliography{bibfile with no extension}

  18. Bibliography using Bibtex • You need a file (e.g. myref.bib) where you have the Bibtex of your reference (e.g. a book, an article, website..etc.) • Put the file in the same folder of your Latex file. • Inside your text , cite a reference using : • \cite{……} • \citeN {……} • \shortcite{……}

  19. Bibliography example. 1 myref.bib 2 Example.tex

  20. How to use Latex 1 • Create new Latex document

  21. How to use Latex 2 • a new Latex document

  22. How to use Latex 4 • Save the file as (example.tex) 3 • Type your Latex text

  23. How to use Latex • Build your file (example.tex) 5 • If your text has no errors then the PDF file for this Latex will be created and opened

  24. How to use Latex 6 • The created PDF file for (example.tex) is then opened

  25. How to create Bibtex files 1 • Create new document

  26. How to create Bibtex files 2 • a new document

  27. 3 • Type your Bibtex

  28. How to create Bibtex files 4 • (Save As ) your Bibtex file 3 • Type your Bibtex

  29. How to create Bibtex files 5 • Type a name for the file and add extension (.bib) (e.g. myref.bib) and put in same folder where your Latex will be

  30. How to create Bibtex files 6 • The file after saving as .bib

  31. How to useBibtex files 8 • Now you can cite any refrence in that file • Specify your Bibtex file (myref) 7

  32. Conclusions • Latex is optimal for master and phd thesis. • Latex is good for large documents, reports, papers. • Mathematical formulas are easy. • Formatting figures and tables inside a large document is easier. • Referencing is easier using Latex.

More Related