SlideShare una empresa de Scribd logo
1 de 41
Descargar para leer sin conexión
Introduction
    The TEX Document Structure
             General Formatting
          The Math Environment




                 A
           Basic LTEX Typesetting
A Hands-On Seminar for Math Training Elective


                     Kiel F. Granada

     Philippine Science High School – Main Campus


                        Session 1
                       July 17, 2010



                    KFGranada           A
                                  Basic L TEX Typesetting
Introduction            A
                                            What is L TEX?
              The TEX Document Structure
                                            Software Requirements
                       General Formatting
                                            TEXMAKER Basics
                    The Math Environment


        A
What is LTEX?




  A document markup language and a document preparation system
  for the TEX Typesetting Program.




                              KFGranada           A
                                            Basic L TEX Typesetting
Introduction             A
                                             What is L TEX?
              The TEX Document Structure
                                             Software Requirements
                       General Formatting
                                             TEXMAKER Basics
                    The Math Environment


    A
How LTEX Works


                                     pdflatex



 file.tex                     file.dvi                      file.ps                file.pdf
             latex                          dvips                      ps2pdf
source file                                               outputs




                              KFGranada            A
                                             Basic L TEX Typesetting
Introduction            A
                                            What is L TEX?
              The TEX Document Structure
                                            Software Requirements
                       General Formatting
                                            TEXMAKER Basics
                    The Math Environment


                          A
What do we need to create LTEX documents?




     A TEX distribution like TEX Live!
     A LTEX editor like TEXMAKER
       A




                              KFGranada           A
                                            Basic L TEX Typesetting
Introduction            A
                                             What is L TEX?
               The TEX Document Structure
                                             Software Requirements
                        General Formatting
                                             TEXMAKER Basics
                     The Math Environment


TEXMAKER Basics


  TEXMAKER is a free cross-platform LTEX editor.
                                    A


  TEXMAKER Command Shortcuts
      latex – F2                                   View DVI – F3
      dvips – F4                                   View PS – F5
      ps2pdf – F8                                  View PDF – F7
      pdflatex – F6




                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                              Document Classes
                The TEX Document Structure
                                              Options
                         General Formatting
                                              Preamble Declarations
                      The Math Environment


The TEX File: Document Structure


   documentclass [ options ]{ a r t i c l e }

  preamble
  %comments

   b e g i n { document }

  body

   end { document }



                                KFGranada           A
                                              Basic L TEX Typesetting
Introduction
                                               Document Classes
                 The TEX Document Structure
                                               Options
                          General Formatting
                                               Preamble Declarations
                       The Math Environment


General Syntax

      command format
      command [ o p t i o n s ] { a rgument }

      environment markers
       begin { environment }

       content

       end { e n v i r o n m e n t }


  Achtung!
  LTEX is case-sensitive.
  A


                                 KFGranada           A
                                               Basic L TEX Typesetting
Introduction
                                              Document Classes
                The TEX Document Structure
                                              Options
                         General Formatting
                                              Preamble Declarations
                      The Math Environment


Exercise 1


  Create your first LTEX document.
                   A


   1. Launch TEXMAKER.
   2. Create a new file.
   3. Type the following basic structure:
       documentclass{ a r t i c l e }

       b e g i n { document}

       end { document}



                                KFGranada           A
                                              Basic L TEX Typesetting
Introduction
                                             Document Classes
               The TEX Document Structure
                                             Options
                        General Formatting
                                             Preamble Declarations
                     The Math Environment


Exercise 1




   4. In the document’s body, list the first 10 prime numbers.
   5. Save as Ex1.tex.
   6. Compile to PDF by pressing F6 .
   7. View PDF by pressing F7 .




                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                            Document Classes
              The TEX Document Structure
                                            Options
                       General Formatting
                                            Preamble Declarations
                    The Math Environment


Document Classes



     article – for short papers
     report
     book
     letter
     slides
     beamer – for slide presentations




                              KFGranada           A
                                            Basic L TEX Typesetting
Introduction
                                                  Document Classes
                    The TEX Document Structure
                                                  Options
                             General Formatting
                                                  Preamble Declarations
                          The Math Environment


Document Options

  documentclass[options]{article}
        Font Size – 10pt, 11pt, 12pt
        Paper Size – a4paper, letterpaper
        Orientation – landscape
        Layout – twocolumn
        Equation Display – fleqn, leqno

  Example

   d o c u m e n t c l a s s [ 1 1 pt , twocolumn ] { a r t i c l e }



                                    KFGranada           A
                                                  Basic L TEX Typesetting
Introduction
                                             Document Classes
               The TEX Document Structure
                                             Options
                        General Formatting
                                             Preamble Declarations
                     The Math Environment


Preamble Contents


     Document Labels
     (title, subtitle, author, institute, date)


     Package Declarations
     Syntax: usepackage{package1, package2, · · · }


     General Formatting and Declarations
     (page margins, line spacing, etc.)



                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                              Document Classes
                The TEX Document Structure
                                              Options
                         General Formatting
                                              Preamble Declarations
                      The Math Environment


Exercise 2


  Create a “titled” LTEX document.
                    A


   1. Launch TEXMAKER and type the basic structure.
   2. In the preamble, set your own document labels.
      Example:
       t i t l e { B a s i c LaTeX  , T y p e s e t t i n g }
       a u t h o r { K i e l F . Granada }
       d a t e { J u l y 20 , 2010}




                                KFGranada           A
                                              Basic L TEX Typesetting
Introduction
                                            Document Classes
              The TEX Document Structure
                                            Options
                       General Formatting
                                            Preamble Declarations
                    The Math Environment


Exercise 2

   3. In the document’s body, type:
      maketitle
   4. Save as Ex2.tex.
   5. Compile and view.

  Note
  Close PDF reader before running pdflatex.

  Follow-up Exercise
  Try out the options: 11pt, 12pt, twocolumn


                              KFGranada           A
                                            Basic L TEX Typesetting
Introduction
                                               Document Classes
                 The TEX Document Structure
                                               Options
                          General Formatting
                                               Preamble Declarations
                       The Math Environment


Commonly Used Packages

       amsmath, amsfonts, amssymb
       amsthm
       fullpage
       multicol
       setspace

  Simplest Declaration

   u s e p a c k a g e { amsmath , a m s f o n t s , amssymb , amsthm ,
  fullpage , multicol , setspace }



                                 KFGranada           A
                                               Basic L TEX Typesetting
Introduction
                                               Document Classes
                 The TEX Document Structure
                                               Options
                          General Formatting
                                               Preamble Declarations
                       The Math Environment


Page Numbers, Margins and Line Spacing
Handy Commands


       pagestyle{empty}


       setlength{topmargin}{-0.5in}
       setlength{oddsidemargin}{-0.5in}
       setlength{evensidemargin}{-0.5in}
       setlength{textwidth}{7.27in}
       setlength{textheight}{10.69in}


       doublespacing
       singlespacing
       onehalfspacing

                                 KFGranada           A
                                               Basic L TEX Typesetting
Introduction
                                               Document Classes
                 The TEX Document Structure
                                               Options
                          General Formatting
                                               Preamble Declarations
                       The Math Environment


Other Declarations
Handy Commands




       definecolor{darkblue}{rgb}{0,0.08,0.45}
       color{darkblue}


       DeclareMathOperator{cis}{cis}


       usepackage[none]{hyphenat}




                                 KFGranada           A
                                               Basic L TEX Typesetting
Introduction
                                             Document Classes
               The TEX Document Structure
                                             Options
                        General Formatting
                                             Preamble Declarations
                     The Math Environment


Exercise 3


  Modify Ex2.tex for its output to meet the following specifications:

      Font size: 12 pt
      Orientation: portrait
      Layout: two-column
      Margins: 1.5” left, 1” right, 1.25” top and bottom
      Spacing: double-spaced
      Hyphenation: on



                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                                     Paragraphs
                       The TEX Document Structure
                                                     Font Sizes and Styles
                                General Formatting
                                                     List Environments
                             The Math Environment


White Spaces, Lines and Indentation
Illustration: Source


    It is a pleasure to thank those who read the first
    draft of this paper and particularly to N. Katz who
    patiently answered many questions in the course of
    this project, listened to many false trails, and
    together with Illusie read the original draft of
    Chapter 3.

    Several others made valuable suggestions and
    criticisms of this paper,
    especially Diamond,
    de Shalit,
    Ribet, Rubin and Taylor.

                                       KFGranada           A
                                                     Basic L TEX Typesetting
Introduction
                                                     Paragraphs
                       The TEX Document Structure
                                                     Font Sizes and Styles
                                General Formatting
                                                     List Environments
                             The Math Environment


White Spaces, Lines and Indentation
Illustration: Output




         It is a pleasure to thank those who read the first draft of
   this paper and particularly to N. Katz who patiently answered many
   questions in the course of this project, listened to many false trails,
   and together with Illusie read the original draft of Chapter 3.

        Several others made valuable suggestions and criticisms of this
   paper, especially Diamond, de Shalit, Ribet, Rubin and Taylor.




                                       KFGranada           A
                                                     Basic L TEX Typesetting
Introduction
                                               Paragraphs
                 The TEX Document Structure
                                               Font Sizes and Styles
                          General Formatting
                                               List Environments
                       The Math Environment


White Spaces, Lines and Indentation
Handy Commands




       white spaces – ,           :          ;
       spaces between paragraphs
       – smallskip, medskip, bigskip, vspace{1in}
       new line – newline or 
       new page – newpage
       remove indentation – noindent




                                 KFGranada           A
                                               Basic L TEX Typesetting
Introduction
                                                   Paragraphs
                     The TEX Document Structure
                                                   Font Sizes and Styles
                              General Formatting
                                                   List Environments
                           The Math Environment


Paragraph Alignments


   begin { f l u s h l e f t }     begin { center }                 begin { f l u s h r i g h t }
  left                             center                            right
   end { f l u s h l e f t }       end { c e n t e r }              end { f l u s h r i g h t }


  left

                                              center

                                                                                            right




                                     KFGranada           A
                                                   Basic L TEX Typesetting
Introduction
                                           Paragraphs
             The TEX Document Structure
                                           Font Sizes and Styles
                      General Formatting
                                           List Environments
                   The Math Environment


Font Sizes


              {tiny text}                                   text

              {scriptsize text}                             text
              {footnotesize text}                          text
              {small text}                                 text
              {normalsize text}                            text
              {large text}                                 text
              {Large text}                                text
              {LARGE text}                               text
              {huge text}                               text
              {Huge text}                              text
                             KFGranada           A
                                           Basic L TEX Typesetting
Introduction
                                            Paragraphs
              The TEX Document Structure
                                            Font Sizes and Styles
                       General Formatting
                                            List Environments
                    The Math Environment


Font Styles




                      textbf{text}                    text
                      underline{text}                 text
                      textit{text}                    text
                      emph{text}                      text
                      texttt{text}                    text




                              KFGranada           A
                                            Basic L TEX Typesetting
Introduction
                                             Paragraphs
               The TEX Document Structure
                                             Font Sizes and Styles
                        General Formatting
                                             List Environments
                     The Math Environment


List Environments

     enumerate                                b egin { enumerate }
       1. Items                               i t e m numbered
       2. are                                 item items
                                              end { e n u m e r a t e }
       3. numbered.
     itemize                                  begin { itemize }
         Items                                item b u l l e t e d
         are                                  item l i s t
         bulleted.                            end { i t e m i z e }
     description
                                              begin { d e s c r i p t i o n }
           Labels are                         item in d en ted
         indented with                        item l a b e l s
               the items.                     end { d e s c r i p t i o n }



                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                             Paragraphs
               The TEX Document Structure
                                             Font Sizes and Styles
                        General Formatting
                                             List Environments
                     The Math Environment


Exercise 4 – “Decode Me”




  Create a LTEX document with the given output Ex4.pdf.
            A
  Font size is 12 pt and page has 1” margin in all sides.




                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                           Math Modes
             The TEX Document Structure
                                           Some Math Symbols and Commands
                      General Formatting
                                           Useful Math Structures
                   The Math Environment


Math Modes

    paragraph mode

        $ math content $                             begin{math}
                                                     math content
                                                     end{math}


    display mode

        $$ math content $$                           begin{displaymath}
                                                     math content
                                                     end{displaymath}


                             KFGranada           A
                                           Basic L TEX Typesetting
Introduction
                                                  Math Modes
                    The TEX Document Structure
                                                  Some Math Symbols and Commands
                             General Formatting
                                                  Useful Math Structures
                          The Math Environment


Math Modes
Example: Source




   S i n c e $x = 1 $ and $y = −2$ , we can now e a s i l y g e t t h e
   v a l u e o f $ z$ u s i n g any o f t h e t h r e e e q u a t i o n s .

   From Eq . 1 , we have

   $$ 2 ( 1 ) − ( −2) + z = 5 $$
   $$2 + 2 + z = 5 $$

   T h e r e f o r e , $z = 1 $ .




                                    KFGranada           A
                                                  Basic L TEX Typesetting
Introduction
                                                Math Modes
                  The TEX Document Structure
                                                Some Math Symbols and Commands
                           General Formatting
                                                Useful Math Structures
                        The Math Environment


Math Modes
Example: Output




         Since x = 1 and y = −2, we can now easily get the value of
   z using any of the three equations.
         From Eq. 1, we have

                                2(1) − (−2) + z = 5
                                     2+2+z =5
         Therefore, z = 1.




                                  KFGranada           A
                                                Basic L TEX Typesetting
Introduction
                                             Math Modes
               The TEX Document Structure
                                             Some Math Symbols and Commands
                        General Formatting
                                             Useful Math Structures
                     The Math Environment


Exercise 5 – “Quick Decode”




  Complex numbers√ of the form a + bi , where a and b are real
                  are
  numbers and i = −1.

  Tip
  You may use TEXMAKER’s Math dropdown menu.




                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                          Math Modes
            The TEX Document Structure
                                          Some Math Symbols and Commands
                     General Formatting
                                          Useful Math Structures
                  The Math Environment


Basic Operations




  +
  −
   times
   div
  pm




                            KFGranada           A
                                          Basic L TEX Typesetting
Introduction
                                          Math Modes
            The TEX Document Structure
                                          Some Math Symbols and Commands
                     General Formatting
                                          Useful Math Structures
                  The Math Environment


Relation Symbols



  <
  =
  >
  leq
   geq
   neq




                            KFGranada           A
                                          Basic L TEX Typesetting
Introduction
                                                  Math Modes
                    The TEX Document Structure
                                                  Some Math Symbols and Commands
                             General Formatting
                                                  Useful Math Structures
                          The Math Environment


Subscripts and Superscripts




  ˆ{ s u p e r s c r i p t }
   { subscript }
  ˆa
   b




                                    KFGranada           A
                                                  Basic L TEX Typesetting
Introduction
                                                  Math Modes
                    The TEX Document Structure
                                                  Some Math Symbols and Commands
                             General Formatting
                                                  Useful Math Structures
                          The Math Environment


Fractions and Radicals




   f r a c { n u m e r a t o r }{ d e n o m i n a t o r }
   d f r a c { n u m e r a t o r }{ d e n o m i n a t o r }

   sqrt { radicand}
   sqrt [ index ]{ radicand}




                                    KFGranada           A
                                                  Basic L TEX Typesetting
Introduction
                                             Math Modes
               The TEX Document Structure
                                             Some Math Symbols and Commands
                        General Formatting
                                             Useful Math Structures
                     The Math Environment


Exercise 6 - “Quick Encode”




  Typeset the Quadratic Formula.




                               KFGranada           A
                                             Basic L TEX Typesetting
Introduction
                                              Math Modes
                The TEX Document Structure
                                              Some Math Symbols and Commands
                         General Formatting
                                              Useful Math Structures
                      The Math Environment


Sets and Set Operations



   mathbb{N, W, Z , Q, R}                          N, W, Z, Q, R
  Re

   f o r a l l x  i n  mathbb{Z}          ∀x ∈ Z
   e x i s t s y  n o t  i n  mathbb {N} ∃y ∈ N

  A  cup B                                         A∪B
  A  cap B                                         A∩B




                                KFGranada           A
                                              Basic L TEX Typesetting
Introduction
                                                    Math Modes
                      The TEX Document Structure
                                                    Some Math Symbols and Commands
                               General Formatting
                                                    Useful Math Structures
                            The Math Environment


Equations

   begin{ equation }
    n P r =  d f r a c {n ! } { ( n−r ) ! }                                      n!
   end { e q u a t i o n }                                       n Pr   =                   (1)
                                                                               (n − r )!
   begin{ equation }
    n C r =  d f r a c {n ! } { ( n−r ) ! r ! }
                                                                                  n!
   end { e q u a t i o n }                                     n Cr     =                   (2)
                                                                              (n − r )!r !
   b e g i n { e q u a t i o n ∗}
    n C r = n C {n−r }
   end { e q u a t i o n ∗}                                        n Cr     =n Cn−r

  Note
  The equation environment is not written inside $ $.
                                      KFGranada           A
                                                    Basic L TEX Typesetting
Introduction
                                                Math Modes
                  The TEX Document Structure
                                                Some Math Symbols and Commands
                           General Formatting
                                                Useful Math Structures
                        The Math Environment


Equation Arrays


   b e g i n { e q n a r r a y ∗}
  x &=& 5 − ( −1) + 3
  &=& 5 + 1 + 3                                       x     = 5 − (−1) + 3
  x &=& 9                                                     = 5+1+3
   end { e q n a r r a y }                             x     = 9

   begin { eqnarray }
  e q u a t i o n 1 & a l i g n h e r e &
  e q u a t i o n 2 & a l i g n h e r e &
  e q u a t i o n 3 & a l i g n h e r e&
   end { e q n a r r a y }


                                  KFGranada           A
                                                Basic L TEX Typesetting
Introduction
                                                 Math Modes
                   The TEX Document Structure
                                                 Some Math Symbols and Commands
                            General Formatting
                                                 Useful Math Structures
                         The Math Environment


Theorems and Proofs
Example: Source



    newtheorem {thm}{ Theorem }

    b e g i n {thm } [ Fermat ’ s L a s t Theorem ]
   The d i o p h a n t i n e e q u a t i o n $x ˆn + y ˆn = z ˆ n$
   h a s no n o n t r i v i a l s o l u t i o n s f o r $n  geq 3 $ .
    end {thm}

    begin { proof }
   ‘ ‘ I ha ve d i s c o v e r e d a t r u l y r e m a r k a b l e p r o o f
   whi ch t h i s ma rgi n i s t o o s m a l l t o c o n t a i n . ”
    end { p r o o f }


                                   KFGranada           A
                                                 Basic L TEX Typesetting
Introduction
                                              Math Modes
                The TEX Document Structure
                                              Some Math Symbols and Commands
                         General Formatting
                                              Useful Math Structures
                      The Math Environment


Theorems and Proofs



  Theorem (Fermat’s Last Theorem)
  The diophantine equation x n + y n = z n has no nontrivial solutions
  for n ≥ 3.

  Proof.
  “I have discovered a truly remarkable proof which this margin is
  too small to contain.”




                                KFGranada           A
                                              Basic L TEX Typesetting
Introduction
                                             Math Modes
               The TEX Document Structure
                                             Some Math Symbols and Commands
                        General Formatting
                                             Useful Math Structures
                     The Math Environment


Assignment


  Part 1
                            √
  Encode the proof that      2 is irrational.

  Part 2
  Encode the derivation of the quadratic formula.

  Send yourlastname1.tex and yourlastname2.tex to
  kielgranada@yahoo.com by Friday, July 23, 2010, 5pm.




                               KFGranada           A
                                             Basic L TEX Typesetting

Más contenido relacionado

La actualidad más candente

La actualidad más candente (20)

Learn Latex
Learn LatexLearn Latex
Learn Latex
 
Introduction Latex
Introduction LatexIntroduction Latex
Introduction Latex
 
Introduction to LaTeX
Introduction to LaTeXIntroduction to LaTeX
Introduction to LaTeX
 
Introduction to LaTeX (For Word users)
 Introduction to LaTeX (For Word users) Introduction to LaTeX (For Word users)
Introduction to LaTeX (For Word users)
 
Latex workshop: Essentials and Practices
Latex workshop: Essentials and PracticesLatex workshop: Essentials and Practices
Latex workshop: Essentials and Practices
 
Introduction to Latex
Introduction to Latex Introduction to Latex
Introduction to Latex
 
Training basic latex
Training basic latexTraining basic latex
Training basic latex
 
Text classification presentation
Text classification presentationText classification presentation
Text classification presentation
 
Lisp
LispLisp
Lisp
 
Latex for beginner
Latex for beginnerLatex for beginner
Latex for beginner
 
XML and XML Applications - Lecture 04 - Web Information Systems (WE-DINF-11912)
XML and XML Applications - Lecture 04 - Web Information Systems (WE-DINF-11912)XML and XML Applications - Lecture 04 - Web Information Systems (WE-DINF-11912)
XML and XML Applications - Lecture 04 - Web Information Systems (WE-DINF-11912)
 
Introduction to Latex
Introduction to LatexIntroduction to Latex
Introduction to Latex
 
Introduction to JavaScript
Introduction to JavaScriptIntroduction to JavaScript
Introduction to JavaScript
 
Introduction to Overleaf Workshop
Introduction to Overleaf WorkshopIntroduction to Overleaf Workshop
Introduction to Overleaf Workshop
 
Htmltag.ppt
Htmltag.pptHtmltag.ppt
Htmltag.ppt
 
Understanding linq
Understanding linqUnderstanding linq
Understanding linq
 
Matlab basic and image
Matlab basic and imageMatlab basic and image
Matlab basic and image
 
Lesson 5 php operators
Lesson 5   php operatorsLesson 5   php operators
Lesson 5 php operators
 
Basic matlab and matrix
Basic matlab and matrixBasic matlab and matrix
Basic matlab and matrix
 
XQuery
XQueryXQuery
XQuery
 

Destacado

Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...
Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...
Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...Kenneth "Kip" Nance
 
Corso di carni
Corso di carniCorso di carni
Corso di carnidonasapo
 
Fqf 2009 test
Fqf 2009 testFqf 2009 test
Fqf 2009 testjimmTPL
 
Sovereignty, Secession, and Successor States
Sovereignty, Secession, and Successor StatesSovereignty, Secession, and Successor States
Sovereignty, Secession, and Successor Statesbengavin
 
Proyecto final
Proyecto finalProyecto final
Proyecto finaljoaquin
 
Charleston
CharlestonCharleston
Charlestonsstieb
 
Las flequis 6º
Las flequis 6ºLas flequis 6º
Las flequis 6ºLorena
 
Problem of the day - April
Problem of the day - AprilProblem of the day - April
Problem of the day - Aprilsmolinaalvarez
 
Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103cesmyra
 
Matychak future of_retail
Matychak future of_retailMatychak future of_retail
Matychak future of_retailXanthe
 
Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103cesmyra
 
Columbus County Community Resource Guide
Columbus County Community Resource GuideColumbus County Community Resource Guide
Columbus County Community Resource GuideKenneth "Kip" Nance
 
Test ppt
Test pptTest ppt
Test pptjimmTPL
 
Monsters slide port
Monsters slide portMonsters slide port
Monsters slide portN Messmore
 

Destacado (20)

Beamer Example
Beamer ExampleBeamer Example
Beamer Example
 
Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...
Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...
Realtor Kip Nance's Maximum Home Audit for Sellers in The Carolina Grand Stra...
 
Corso di carni
Corso di carniCorso di carni
Corso di carni
 
Fqf 2009 test
Fqf 2009 testFqf 2009 test
Fqf 2009 test
 
Sovereignty, Secession, and Successor States
Sovereignty, Secession, and Successor StatesSovereignty, Secession, and Successor States
Sovereignty, Secession, and Successor States
 
Proyecto final
Proyecto finalProyecto final
Proyecto final
 
ferifikase
ferifikaseferifikase
ferifikase
 
Charleston
CharlestonCharleston
Charleston
 
Las flequis 6º
Las flequis 6ºLas flequis 6º
Las flequis 6º
 
Problem of the day - April
Problem of the day - AprilProblem of the day - April
Problem of the day - April
 
Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103
 
SOUTH CAROLINA TAX SUMMARY
 SOUTH CAROLINA TAX SUMMARY SOUTH CAROLINA TAX SUMMARY
SOUTH CAROLINA TAX SUMMARY
 
Matychak future of_retail
Matychak future of_retailMatychak future of_retail
Matychak future of_retail
 
Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103Seminar Workshop Course Guide For Eng 103
Seminar Workshop Course Guide For Eng 103
 
Columbus County Community Resource Guide
Columbus County Community Resource GuideColumbus County Community Resource Guide
Columbus County Community Resource Guide
 
A Present
A PresentA Present
A Present
 
Test ppt
Test pptTest ppt
Test ppt
 
Yu
YuYu
Yu
 
Monsters slide port
Monsters slide portMonsters slide port
Monsters slide port
 
Manuale
ManualeManuale
Manuale
 

Similar a Basic Latex Typesetting - Session 1

LaTeX for Undergraduate Linguists
LaTeX for Undergraduate LinguistsLaTeX for Undergraduate Linguists
LaTeX for Undergraduate Linguistsdnwood
 
LaTeX Part 1
LaTeX Part 1LaTeX Part 1
LaTeX Part 1awv7t
 
Introduction to-Tex-and-LaTeX
Introduction to-Tex-and-LaTeXIntroduction to-Tex-and-LaTeX
Introduction to-Tex-and-LaTeXrsamurti
 
latex-workshop Dr: Mohamed A. Alrshah
latex-workshop Dr: Mohamed A. Alrshahlatex-workshop Dr: Mohamed A. Alrshah
latex-workshop Dr: Mohamed A. AlrshahAbdulazim N.Elaati
 
Editing documents with LaTeX
Editing documents with LaTeXEditing documents with LaTeX
Editing documents with LaTeXLaura M. Castro
 
LATEX and BEAMER for Beginners
LATEX and BEAMER for Beginners LATEX and BEAMER for Beginners
LATEX and BEAMER for Beginners Tilak Devaraj
 
ReST Editor - Eclipse Demo Camp Grenoble 2011
ReST Editor - Eclipse Demo Camp Grenoble 2011ReST Editor - Eclipse Demo Camp Grenoble 2011
ReST Editor - Eclipse Demo Camp Grenoble 2011tcalmant
 

Similar a Basic Latex Typesetting - Session 1 (16)

LaTeX for Undergraduate Linguists
LaTeX for Undergraduate LinguistsLaTeX for Undergraduate Linguists
LaTeX for Undergraduate Linguists
 
LaTeX for beginners
LaTeX for beginnersLaTeX for beginners
LaTeX for beginners
 
LaTeX Part 1
LaTeX Part 1LaTeX Part 1
LaTeX Part 1
 
Keeping Up! with LaTeX
Keeping Up! with LaTeXKeeping Up! with LaTeX
Keeping Up! with LaTeX
 
Introduction to-Tex-and-LaTeX
Introduction to-Tex-and-LaTeXIntroduction to-Tex-and-LaTeX
Introduction to-Tex-and-LaTeX
 
Document typesetting using LateX
Document typesetting using LateXDocument typesetting using LateX
Document typesetting using LateX
 
latex-workshop Dr: Mohamed A. Alrshah
latex-workshop Dr: Mohamed A. Alrshahlatex-workshop Dr: Mohamed A. Alrshah
latex-workshop Dr: Mohamed A. Alrshah
 
LATEX.ppt
LATEX.pptLATEX.ppt
LATEX.ppt
 
Editing documents with LaTeX
Editing documents with LaTeXEditing documents with LaTeX
Editing documents with LaTeX
 
Introduction to LaTeX
Introduction to LaTeXIntroduction to LaTeX
Introduction to LaTeX
 
LATEX and BEAMER for Beginners
LATEX and BEAMER for Beginners LATEX and BEAMER for Beginners
LATEX and BEAMER for Beginners
 
Latex ppt copy
Latex ppt   copyLatex ppt   copy
Latex ppt copy
 
sigproc-sp.pdf
sigproc-sp.pdfsigproc-sp.pdf
sigproc-sp.pdf
 
ReST Editor - Eclipse Demo Camp Grenoble 2011
ReST Editor - Eclipse Demo Camp Grenoble 2011ReST Editor - Eclipse Demo Camp Grenoble 2011
ReST Editor - Eclipse Demo Camp Grenoble 2011
 
Inroduction to Latex
Inroduction to LatexInroduction to Latex
Inroduction to Latex
 
Latex Tutorial
Latex TutorialLatex Tutorial
Latex Tutorial
 

Último

Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdfContoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdfcupulin
 
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdfUGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdfNirmal Dwivedi
 
How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17Celine George
 
How to Manage Website in Odoo 17 Studio App.pptx
How to Manage Website in Odoo 17 Studio App.pptxHow to Manage Website in Odoo 17 Studio App.pptx
How to Manage Website in Odoo 17 Studio App.pptxCeline George
 
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonQUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonhttgc7rh9c
 
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...Nguyen Thanh Tu Collection
 
UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024Borja Sotomayor
 
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaPersonalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaEADTU
 
How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17Celine George
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnershipsexpandedwebsite
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsSandeep D Chaudhary
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxDr. Ravikiran H M Gowda
 
What is 3 Way Matching Process in Odoo 17.pptx
What is 3 Way Matching Process in Odoo 17.pptxWhat is 3 Way Matching Process in Odoo 17.pptx
What is 3 Way Matching Process in Odoo 17.pptxCeline George
 
AIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.pptAIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.pptNishitharanjan Rout
 
How to Send Pro Forma Invoice to Your Customers in Odoo 17
How to Send Pro Forma Invoice to Your Customers in Odoo 17How to Send Pro Forma Invoice to Your Customers in Odoo 17
How to Send Pro Forma Invoice to Your Customers in Odoo 17Celine George
 
Observing-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxObserving-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxAdelaideRefugio
 
Details on CBSE Compartment Exam.pptx1111
Details on CBSE Compartment Exam.pptx1111Details on CBSE Compartment Exam.pptx1111
Details on CBSE Compartment Exam.pptx1111GangaMaiya1
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxannathomasp01
 
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdfFICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdfPondicherry University
 

Último (20)

Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdfContoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
 
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdfUGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
 
How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17
 
How to Manage Website in Odoo 17 Studio App.pptx
How to Manage Website in Odoo 17 Studio App.pptxHow to Manage Website in Odoo 17 Studio App.pptx
How to Manage Website in Odoo 17 Studio App.pptx
 
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonQUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
 
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
 
Including Mental Health Support in Project Delivery, 14 May.pdf
Including Mental Health Support in Project Delivery, 14 May.pdfIncluding Mental Health Support in Project Delivery, 14 May.pdf
Including Mental Health Support in Project Delivery, 14 May.pdf
 
UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024
 
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaPersonalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
 
How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & Systems
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptx
 
What is 3 Way Matching Process in Odoo 17.pptx
What is 3 Way Matching Process in Odoo 17.pptxWhat is 3 Way Matching Process in Odoo 17.pptx
What is 3 Way Matching Process in Odoo 17.pptx
 
AIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.pptAIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.ppt
 
How to Send Pro Forma Invoice to Your Customers in Odoo 17
How to Send Pro Forma Invoice to Your Customers in Odoo 17How to Send Pro Forma Invoice to Your Customers in Odoo 17
How to Send Pro Forma Invoice to Your Customers in Odoo 17
 
Observing-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxObserving-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptx
 
Details on CBSE Compartment Exam.pptx1111
Details on CBSE Compartment Exam.pptx1111Details on CBSE Compartment Exam.pptx1111
Details on CBSE Compartment Exam.pptx1111
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdfFICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
 

Basic Latex Typesetting - Session 1

  • 1. Introduction The TEX Document Structure General Formatting The Math Environment A Basic LTEX Typesetting A Hands-On Seminar for Math Training Elective Kiel F. Granada Philippine Science High School – Main Campus Session 1 July 17, 2010 KFGranada A Basic L TEX Typesetting
  • 2. Introduction A What is L TEX? The TEX Document Structure Software Requirements General Formatting TEXMAKER Basics The Math Environment A What is LTEX? A document markup language and a document preparation system for the TEX Typesetting Program. KFGranada A Basic L TEX Typesetting
  • 3. Introduction A What is L TEX? The TEX Document Structure Software Requirements General Formatting TEXMAKER Basics The Math Environment A How LTEX Works pdflatex file.tex file.dvi file.ps file.pdf latex dvips ps2pdf source file outputs KFGranada A Basic L TEX Typesetting
  • 4. Introduction A What is L TEX? The TEX Document Structure Software Requirements General Formatting TEXMAKER Basics The Math Environment A What do we need to create LTEX documents? A TEX distribution like TEX Live! A LTEX editor like TEXMAKER A KFGranada A Basic L TEX Typesetting
  • 5. Introduction A What is L TEX? The TEX Document Structure Software Requirements General Formatting TEXMAKER Basics The Math Environment TEXMAKER Basics TEXMAKER is a free cross-platform LTEX editor. A TEXMAKER Command Shortcuts latex – F2 View DVI – F3 dvips – F4 View PS – F5 ps2pdf – F8 View PDF – F7 pdflatex – F6 KFGranada A Basic L TEX Typesetting
  • 6. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment The TEX File: Document Structure documentclass [ options ]{ a r t i c l e } preamble %comments b e g i n { document } body end { document } KFGranada A Basic L TEX Typesetting
  • 7. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment General Syntax command format command [ o p t i o n s ] { a rgument } environment markers begin { environment } content end { e n v i r o n m e n t } Achtung! LTEX is case-sensitive. A KFGranada A Basic L TEX Typesetting
  • 8. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Exercise 1 Create your first LTEX document. A 1. Launch TEXMAKER. 2. Create a new file. 3. Type the following basic structure: documentclass{ a r t i c l e } b e g i n { document} end { document} KFGranada A Basic L TEX Typesetting
  • 9. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Exercise 1 4. In the document’s body, list the first 10 prime numbers. 5. Save as Ex1.tex. 6. Compile to PDF by pressing F6 . 7. View PDF by pressing F7 . KFGranada A Basic L TEX Typesetting
  • 10. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Document Classes article – for short papers report book letter slides beamer – for slide presentations KFGranada A Basic L TEX Typesetting
  • 11. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Document Options documentclass[options]{article} Font Size – 10pt, 11pt, 12pt Paper Size – a4paper, letterpaper Orientation – landscape Layout – twocolumn Equation Display – fleqn, leqno Example d o c u m e n t c l a s s [ 1 1 pt , twocolumn ] { a r t i c l e } KFGranada A Basic L TEX Typesetting
  • 12. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Preamble Contents Document Labels (title, subtitle, author, institute, date) Package Declarations Syntax: usepackage{package1, package2, · · · } General Formatting and Declarations (page margins, line spacing, etc.) KFGranada A Basic L TEX Typesetting
  • 13. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Exercise 2 Create a “titled” LTEX document. A 1. Launch TEXMAKER and type the basic structure. 2. In the preamble, set your own document labels. Example: t i t l e { B a s i c LaTeX , T y p e s e t t i n g } a u t h o r { K i e l F . Granada } d a t e { J u l y 20 , 2010} KFGranada A Basic L TEX Typesetting
  • 14. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Exercise 2 3. In the document’s body, type: maketitle 4. Save as Ex2.tex. 5. Compile and view. Note Close PDF reader before running pdflatex. Follow-up Exercise Try out the options: 11pt, 12pt, twocolumn KFGranada A Basic L TEX Typesetting
  • 15. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Commonly Used Packages amsmath, amsfonts, amssymb amsthm fullpage multicol setspace Simplest Declaration u s e p a c k a g e { amsmath , a m s f o n t s , amssymb , amsthm , fullpage , multicol , setspace } KFGranada A Basic L TEX Typesetting
  • 16. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Page Numbers, Margins and Line Spacing Handy Commands pagestyle{empty} setlength{topmargin}{-0.5in} setlength{oddsidemargin}{-0.5in} setlength{evensidemargin}{-0.5in} setlength{textwidth}{7.27in} setlength{textheight}{10.69in} doublespacing singlespacing onehalfspacing KFGranada A Basic L TEX Typesetting
  • 17. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Other Declarations Handy Commands definecolor{darkblue}{rgb}{0,0.08,0.45} color{darkblue} DeclareMathOperator{cis}{cis} usepackage[none]{hyphenat} KFGranada A Basic L TEX Typesetting
  • 18. Introduction Document Classes The TEX Document Structure Options General Formatting Preamble Declarations The Math Environment Exercise 3 Modify Ex2.tex for its output to meet the following specifications: Font size: 12 pt Orientation: portrait Layout: two-column Margins: 1.5” left, 1” right, 1.25” top and bottom Spacing: double-spaced Hyphenation: on KFGranada A Basic L TEX Typesetting
  • 19. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment White Spaces, Lines and Indentation Illustration: Source It is a pleasure to thank those who read the first draft of this paper and particularly to N. Katz who patiently answered many questions in the course of this project, listened to many false trails, and together with Illusie read the original draft of Chapter 3. Several others made valuable suggestions and criticisms of this paper, especially Diamond, de Shalit, Ribet, Rubin and Taylor. KFGranada A Basic L TEX Typesetting
  • 20. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment White Spaces, Lines and Indentation Illustration: Output It is a pleasure to thank those who read the first draft of this paper and particularly to N. Katz who patiently answered many questions in the course of this project, listened to many false trails, and together with Illusie read the original draft of Chapter 3. Several others made valuable suggestions and criticisms of this paper, especially Diamond, de Shalit, Ribet, Rubin and Taylor. KFGranada A Basic L TEX Typesetting
  • 21. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment White Spaces, Lines and Indentation Handy Commands white spaces – , : ; spaces between paragraphs – smallskip, medskip, bigskip, vspace{1in} new line – newline or new page – newpage remove indentation – noindent KFGranada A Basic L TEX Typesetting
  • 22. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment Paragraph Alignments begin { f l u s h l e f t } begin { center } begin { f l u s h r i g h t } left center right end { f l u s h l e f t } end { c e n t e r } end { f l u s h r i g h t } left center right KFGranada A Basic L TEX Typesetting
  • 23. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment Font Sizes {tiny text} text {scriptsize text} text {footnotesize text} text {small text} text {normalsize text} text {large text} text {Large text} text {LARGE text} text {huge text} text {Huge text} text KFGranada A Basic L TEX Typesetting
  • 24. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment Font Styles textbf{text} text underline{text} text textit{text} text emph{text} text texttt{text} text KFGranada A Basic L TEX Typesetting
  • 25. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment List Environments enumerate b egin { enumerate } 1. Items i t e m numbered 2. are item items end { e n u m e r a t e } 3. numbered. itemize begin { itemize } Items item b u l l e t e d are item l i s t bulleted. end { i t e m i z e } description begin { d e s c r i p t i o n } Labels are item in d en ted indented with item l a b e l s the items. end { d e s c r i p t i o n } KFGranada A Basic L TEX Typesetting
  • 26. Introduction Paragraphs The TEX Document Structure Font Sizes and Styles General Formatting List Environments The Math Environment Exercise 4 – “Decode Me” Create a LTEX document with the given output Ex4.pdf. A Font size is 12 pt and page has 1” margin in all sides. KFGranada A Basic L TEX Typesetting
  • 27. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Math Modes paragraph mode $ math content $ begin{math} math content end{math} display mode $$ math content $$ begin{displaymath} math content end{displaymath} KFGranada A Basic L TEX Typesetting
  • 28. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Math Modes Example: Source S i n c e $x = 1 $ and $y = −2$ , we can now e a s i l y g e t t h e v a l u e o f $ z$ u s i n g any o f t h e t h r e e e q u a t i o n s . From Eq . 1 , we have $$ 2 ( 1 ) − ( −2) + z = 5 $$ $$2 + 2 + z = 5 $$ T h e r e f o r e , $z = 1 $ . KFGranada A Basic L TEX Typesetting
  • 29. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Math Modes Example: Output Since x = 1 and y = −2, we can now easily get the value of z using any of the three equations. From Eq. 1, we have 2(1) − (−2) + z = 5 2+2+z =5 Therefore, z = 1. KFGranada A Basic L TEX Typesetting
  • 30. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Exercise 5 – “Quick Decode” Complex numbers√ of the form a + bi , where a and b are real are numbers and i = −1. Tip You may use TEXMAKER’s Math dropdown menu. KFGranada A Basic L TEX Typesetting
  • 31. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Basic Operations + − times div pm KFGranada A Basic L TEX Typesetting
  • 32. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Relation Symbols < = > leq geq neq KFGranada A Basic L TEX Typesetting
  • 33. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Subscripts and Superscripts ˆ{ s u p e r s c r i p t } { subscript } ˆa b KFGranada A Basic L TEX Typesetting
  • 34. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Fractions and Radicals f r a c { n u m e r a t o r }{ d e n o m i n a t o r } d f r a c { n u m e r a t o r }{ d e n o m i n a t o r } sqrt { radicand} sqrt [ index ]{ radicand} KFGranada A Basic L TEX Typesetting
  • 35. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Exercise 6 - “Quick Encode” Typeset the Quadratic Formula. KFGranada A Basic L TEX Typesetting
  • 36. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Sets and Set Operations mathbb{N, W, Z , Q, R} N, W, Z, Q, R Re f o r a l l x i n mathbb{Z} ∀x ∈ Z e x i s t s y n o t i n mathbb {N} ∃y ∈ N A cup B A∪B A cap B A∩B KFGranada A Basic L TEX Typesetting
  • 37. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Equations begin{ equation } n P r = d f r a c {n ! } { ( n−r ) ! } n! end { e q u a t i o n } n Pr = (1) (n − r )! begin{ equation } n C r = d f r a c {n ! } { ( n−r ) ! r ! } n! end { e q u a t i o n } n Cr = (2) (n − r )!r ! b e g i n { e q u a t i o n ∗} n C r = n C {n−r } end { e q u a t i o n ∗} n Cr =n Cn−r Note The equation environment is not written inside $ $. KFGranada A Basic L TEX Typesetting
  • 38. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Equation Arrays b e g i n { e q n a r r a y ∗} x &=& 5 − ( −1) + 3 &=& 5 + 1 + 3 x = 5 − (−1) + 3 x &=& 9 = 5+1+3 end { e q n a r r a y } x = 9 begin { eqnarray } e q u a t i o n 1 & a l i g n h e r e & e q u a t i o n 2 & a l i g n h e r e & e q u a t i o n 3 & a l i g n h e r e& end { e q n a r r a y } KFGranada A Basic L TEX Typesetting
  • 39. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Theorems and Proofs Example: Source newtheorem {thm}{ Theorem } b e g i n {thm } [ Fermat ’ s L a s t Theorem ] The d i o p h a n t i n e e q u a t i o n $x ˆn + y ˆn = z ˆ n$ h a s no n o n t r i v i a l s o l u t i o n s f o r $n geq 3 $ . end {thm} begin { proof } ‘ ‘ I ha ve d i s c o v e r e d a t r u l y r e m a r k a b l e p r o o f whi ch t h i s ma rgi n i s t o o s m a l l t o c o n t a i n . ” end { p r o o f } KFGranada A Basic L TEX Typesetting
  • 40. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Theorems and Proofs Theorem (Fermat’s Last Theorem) The diophantine equation x n + y n = z n has no nontrivial solutions for n ≥ 3. Proof. “I have discovered a truly remarkable proof which this margin is too small to contain.” KFGranada A Basic L TEX Typesetting
  • 41. Introduction Math Modes The TEX Document Structure Some Math Symbols and Commands General Formatting Useful Math Structures The Math Environment Assignment Part 1 √ Encode the proof that 2 is irrational. Part 2 Encode the derivation of the quadratic formula. Send yourlastname1.tex and yourlastname2.tex to kielgranada@yahoo.com by Friday, July 23, 2010, 5pm. KFGranada A Basic L TEX Typesetting