Documentation in Latex

download Documentation in Latex

of 45

Transcript of Documentation in Latex

  • 8/10/2019 Documentation in Latex

    1/45

  • 8/10/2019 Documentation in Latex

    2/45

  • 8/10/2019 Documentation in Latex

    3/45

    Document structure

    The document environment

  • 8/10/2019 Documentation in Latex

    4/45

    Useful packages

  • 8/10/2019 Documentation in Latex

    5/45

    Document structure

    The document environment

  • 8/10/2019 Documentation in Latex

    6/45

    Output :

  • 8/10/2019 Documentation in Latex

    7/45

    Text styles and -size

    Latex Commands: Output:

    Insert the TEXT

    Between { }

    Insert the

    CommandInline with

    any

    Statement

  • 8/10/2019 Documentation in Latex

    8/45

  • 8/10/2019 Documentation in Latex

    9/45

    Output:

    TeX Code:

  • 8/10/2019 Documentation in Latex

    10/45

    Output:TeX Code:

  • 8/10/2019 Documentation in Latex

    11/45

    Footnotes

  • 8/10/2019 Documentation in Latex

    12/45

    Output:

    TeX Code:

  • 8/10/2019 Documentation in Latex

    13/45

    Output:

    TeX Code:

  • 8/10/2019 Documentation in Latex

    14/45

    Output:

    TeX Code:

  • 8/10/2019 Documentation in Latex

    15/45

  • 8/10/2019 Documentation in Latex

    16/45

  • 8/10/2019 Documentation in Latex

    17/45

    Bibliography management

    BibTeXSample Bibliographic Entry

    @article{ Hemmendinger07,

    author = {David Hemmendinger},

    title = {The ACM and IEEE-CSguidelines for undergraduate CSeducation},

    journal = {Commun. ACM},

    volume = {50},

    number = {5},

    year = {2007},

    issn = {0001-0782},

    pages = {46--53},

    doi ={http://doi.acm.org/10.1145/1230819.1230838},

    publisher = {ACM},

    address = {New York, NY, USA},

    }

    @article lets BibTeX know that thebibliographical entry is an article.

    Other Types: book

    phdthesis

    unpublished

    misc

    and others Hemmendinger07 identifies the entry

    used when citing it in a LaTeX document.

  • 8/10/2019 Documentation in Latex

    18/45

    Why you want to learn BibTex

    Complements LaTeX documents by

    managing bibliography and references

    Minimizes the drudgery of formatting,numbering, and referencing

    Disadvantage:

    Steep Learning Curve

  • 8/10/2019 Documentation in Latex

    19/45

    Types of Documents BibTex can

    handleARTICLE

    BOOK

    BOOKLET

    INBOOK

    INCOLLECTION

    INPROCEEDINGS

    MANUAL

    MISC

    PHDTHESIS

    PROCEEDINGS

    TECHREPORT

    UNPUBLISHED

  • 8/10/2019 Documentation in Latex

    20/45

    Using BibTeX in a LaTeX Doc

    1. Set the bibliography style.The standard is plain: \bibliographystyle{plain}

    Location: after \begin{document}

    Other Styles:unsrtsame as plain except entries are numbered based on when they are cited, not

    alphabetically by author.

    alphaSimilar to plain except instead of having numerical identifiers (e.g. [1]), labelsare created based on the year of publication and the name of the author(s).

    abbrvNames and journal titles are abbreviated.

    2. Make citations.To cite, insert \cite{ident}

    identis the identifier (i.e. Hemmendinger07).

    3. Tell LaTeX to make the bibilography near the end of the document.\bibliography{bibfile}

    bibfileis your bibliography file bibfile.bib (without the .bib)

  • 8/10/2019 Documentation in Latex

    21/45

    The BibTex Process

    1. Create a BibTexfile with Rerefence entries

    2. Get a *.bstfile (bibliographic style file)

    3. Compile or Build your LaTeXdocument tocreate an *.auxfile

    4. Run BibTeXon your LaTeXfile

    5. Run LaTeXtwice on your updated file6. View the dviorpdffile

  • 8/10/2019 Documentation in Latex

    22/45

  • 8/10/2019 Documentation in Latex

    23/45

    Each Document type can have the

    following entries

    address

    author

    booktitle

    chapter

    crossref edition

    editor

    howpublished

    institution

    journal key

    language

    month

    note

    number

    organization

    pages publisher

    school

    series

    title

    type=Ph.D. dissertation

    volume

    year

    Sample BibTex

  • 8/10/2019 Documentation in Latex

    24/45

    Sample BibTex

    Book Entry

    (mybib.bib)

    @BOOK{Press,

    author="W.H. Press",

    title="Numerical Recipes in C: The Art

    of Scientific Computing",

    publisher="Cambridge University Press",year=1992,

    }

  • 8/10/2019 Documentation in Latex

    25/45

    Sample BibTex

    Technical Report Entry

    @TECHREPORT{Berk,

    author="Lex A. Berk andL.S.

    Bernstein andD.C. Robertson",title="MODTRAN: a moderateresolution model for LOWTRAN 7",

    number="GL-TR-89-0122",

    institution="Spectral Science",address = "Burlington, MA",

    year = 1989

    }

  • 8/10/2019 Documentation in Latex

    26/45

    Sample BibTex

    Ph.D. Dissertation Entry

    @PHDTHESIS{Kuo,

    author="Jan-Tai Kuo",

    title="The Influence ofHydrodynamic Transport onPhytoplankton Dynamics inHomogeneous Lakes",

    school="Cornell University",

    address="Ithaca, NY",

    year=1981,

    }

  • 8/10/2019 Documentation in Latex

    27/45

    Sample BibTex

    Masters Thesis Entry

    @MASTERSTHESIS{Knobelspiesse,

    author="Kirk D. Knobelspiesse",

    title="Atmospheric Compensation for SeaWIFSImages of Lake Superior Utilizing SpatialInformation",

    school="Rochester Institute of Technology",

    addess="Rochester, NY",month=Sep,

    year=2000,

    }

  • 8/10/2019 Documentation in Latex

    28/45

    Sample BibTex

    Article Entry

    @ARTICLE{Vodacek,author="Anthony Vodacek and F.E. Hoge and R.N.

    Swift and J.K. Yungel and E.T. Peltzer and N.V.Blough",

    title="The use of in situ and airborne fluorescencemeasurements to determine UV absorption

    coefficients and DOC concentrations in surfacewaters",journal="Limnology and Oceanography",volume=40,number=2,year=1995,

    pages="411--415",}

  • 8/10/2019 Documentation in Latex

    29/45

    Sample BibTex

    Booklet Entry

    @BOOKLET{Sherwood,

    author="D.A. Sherwood",

    title="Phosphorus Loads Entering LongPond, A Small Embayment of Lake Ontarionear Rochester, New York",

    howpublished="USGS Fact Sheet 128-99",

    pages=4,

    month="November",

    year=1999,

    }

  • 8/10/2019 Documentation in Latex

    30/45

    Sample BibTex

    Proceedings Entry

    @INPROCEEDINGS{Stoermer,

    author="E.F. Stoermer",

    title="Nearshore phytoplankton

    populations in the Grand Haven,Michigan vicinity during thermal barconditions",

    booktitle="Proceedings of the 11thConference on Great Lakes Research",

    pages="137--150",year=1968,

    }

  • 8/10/2019 Documentation in Latex

    31/45

    Sample BibTex

    Manual Entry

    @MANUAL{RSI,

    author="RSI",

    title="ENVI User's Guide",publisher="Reasearch Systems Incorporated",

    organization="Research Systems Incorporated",

    howpublished="PDF File",

    address="Boulder, CO",month="September",

    year=2001,

    }

  • 8/10/2019 Documentation in Latex

    32/45

    Different Formatting Styles

    To invoke a particular style, go to

    http://www.ctan.org

    Document styles are defined in *.styfiles

    mla.stybmsplain.sty

    Bibliography styles are defined in *.bstfiles

    mla.bst

    amsplain.bst

    http://www.ctan.org/http://www.ctan.org/
  • 8/10/2019 Documentation in Latex

    33/45

    To invoke these styles in your

    document

    Copy them to your current working directory

    with your LaTeXand BibTexdocument

    Edit your LaTeXfile to appropriately

    reference these style guides

    Sample LaTeX document listing

  • 8/10/2019 Documentation in Latex

    34/45

    Sample LaTeXdocument listing

    Bibliography in

    MLA Style (bib.tex)\documentclass{report}

    \usepackage{mla}

    \begin{document}

    \bibliographystyle{mla}

    \bibliography{mybib}

    \nocite{*}

    \end{document}

  • 8/10/2019 Documentation in Latex

    35/45

    Commands to Build and

    View Document

    To use xdviviewer

    % latex bib.tex

    % bibtex bib.aux

    % latex bib.tex

    % latex bib.tex

    % xdvi bib.dvi

  • 8/10/2019 Documentation in Latex

    36/45

  • 8/10/2019 Documentation in Latex

    37/45

  • 8/10/2019 Documentation in Latex

    38/45

    1

  • 8/10/2019 Documentation in Latex

    39/45

    2

  • 8/10/2019 Documentation in Latex

    40/45

    3

    1

  • 8/10/2019 Documentation in Latex

    41/45

    1

    2

    3

  • 8/10/2019 Documentation in Latex

    42/45

  • 8/10/2019 Documentation in Latex

    43/45

  • 8/10/2019 Documentation in Latex

    44/45

    Output:

    TeX Code:

  • 8/10/2019 Documentation in Latex

    45/45

    Output:

    TeX Code: