
LaTeX Beginner's Guide
Description
Alles über E-Books | Antworten auf Fragen rund um E-Books, Kopierschutz und Dateiformate finden Sie in unserem Info- & Hilfebereich.
- Learn LaTeX through hands-on examples covering math formulas, tables, figures, and presentations
- Explore modern LaTeX features, including AI-powered tools and advanced PDF capabilities
Book DescriptionWriting a thesis, research paper, technical report, or book often challenges users with formatting and consistency. The LaTeX typesetting tool offers a powerful, structured approach to document creation, though mastering it can be daunting for beginners. This third edition of the LaTeX Beginner's Guide simplifies the learning curve, providing a hands-on introduction to writing professional-quality documents efficiently. Written by Stefan Kottwitz, a leading LaTeX expert and community moderator, this book builds on over 20 years of coding and publishing experience along with feedback from LaTeX users worldwide. Through step-by-step tutorials and real-world examples, you'll learn how to fine-tune text, typeset complex equations, manage citations, and produce high-quality tables, images, and presentations. The book also explores modern LaTeX features, including advanced PDF capabilities and different TeX engines. With dedicated sections on slide presentations and best practices for document structuring, this edition ensures that users can optimize their workflows and produce publication-ready documents with ease. By the end of this book, you'll confidently use the LaTeX software to produce academic papers, generate bibliographies, and achieve professional layouts for any type of document. *Email sign-up and proof of purchase requiredWhat you will learn - Format and structure research papers, reports, books, or theses
- Create tables, figures, citations, and bibliographies with ease
- Typeset math and scientific notations professionally
- Design presentations slides
- Generate polished PDFs with hyperlinks and metadata
- Manage large projects consistently
- Boost productivity with AI-powered coding, writing, and formatting tools
Who this book is forThis book is for students, researchers, educators, and professionals in academia, STEM, and publishing who need to create structured, high-quality documents. Whether you're preparing research papers, technical reports, books, or presentations, this guide simplifies LaTeX for beginners while offering advanced features for experienced users. No prior LaTeX knowledge is required, making it ideal for anyone looking to skill up in professional document formatting, citations, and PDF production with ease.
All prices
More details
Other editions
New editions

Content
- Cover
- FM
- Copyright
- Contributors
- Table of Contents
- Preface
- Free benefits with your book
- Chapter 1: Getting Started with LaTeX
- Your purchase includes a free PDF copy + exclusive extras
- Technical requirements
- Getting the LaTeX idea
- Benefits of LaTeX
- Virtues of open source
- Separation of form and content
- Portability
- Protection for your work
- How to get started with LaTeX
- Approaches to working with LaTeX
- Installing and using LaTeX
- Installing TeX Live using the net installer wizard
- Installing TeX Live offline
- Installing TeX Live on other operating systems
- Updating TeX Live and installing new packages
- Creating our first document
- Checking out advanced LaTeX editors
- Working with LaTeX online
- What Overleaf requires and delivers
- Benefits of Overleaf
- Caveats of working online
- Creating our first document online
- Exploring Overleaf
- Grammar and language feedback with Writefull
- Reviewing and commenting
- Accessing documentation
- Summary
- Chapter 2: Formatting Text and Creating Macros
- Using logical formatting
- Creating a document with a title and heading
- Exploring the document structure
- Using LaTeX commands
- Using LaTeX environments
- Understanding how LaTeX processes your input
- Printing special symbols
- Modifying text fonts
- Adjusting the font shape
- Choosing the font family
- Limiting the effect of commands
- Exploring font sizes
- Using color
- Limiting paragraph width
- Creating a narrow text box
- Producing paragraph boxes
- Exploring further paragraph box features
- Using minipages
- Breaking lines and paragraphs
- Improving hyphenation
- Preventing hyphenation
- Improving the justification
- Breaking lines manually
- Exploring line-breaking options
- Preventing line breaks
- Changing text alignment
- Creating ragged-right text
- Creating ragged-left text
- Centering text
- Using environments for justification
- Displaying quotations
- Quoting longer text
- Creating commands
- Using macros for simple text
- Improving spacing after commands
- Creating flexible commands with arguments
- Defining a macro with arguments
- Defining a macro with optional arguments
- Redefining commands
- Creating environments
- Using an alternative syntax
- Summary
- Chapter 3: Designing Pages
- Structuring with chapters
- Adjusting page margins
- Choosing the paper size
- Specifying the text area
- Setting the margins
- Creating a two-column layout
- Designing headers and footers
- Understanding page styles
- Customizing headers and footers
- Using decorative lines in headers or footers
- Changing LaTeX's header marks
- Adding footnotes
- Modifying the footnote line
- Using packages to expand footnote styles
- Handling page breaks
- Enlarging a page
- Changing the line spacing
- Aligning the text area height
- Creating a table of contents
- Summary
- Chapter 4: Creating Lists
- Building lists
- Creating a bulleted list
- Building a numbered list
- Producing a definition list
- Customizing lists
- Getting compact lists
- Choosing bullets and numbering format
- Suspending and continuing lists
- Examining the layout of lists
- Summary
- Chapter 5: Creating Tables
- Aligning text with tab stops
- Creating basic tables
- Drawing lines in tables
- Understanding formatting arguments
- Improving table appearance
- Increasing the row height
- Beautifying tables
- Customizing line thickness and spacing
- Spanning entries across multiple columns
- Inserting code column-wise
- Spanning content across multiple rows
- Adding captions to tables
- Placing captions above tables
- Customizing captions
- Enhancing tables with additional packages
- Auto-fitting columns to the table width
- Generating multi-page tables
- Coloring tables
- Using landscape orientation
- Aligning columns at the decimal point
- Dealing with narrow columns
- Summary
- Chapter 6: Including Images
- Choosing the right image format
- Creating images
- Producing and processing bitmap images
- Editing vector graphics
- Embedding images
- Scaling an image
- Including entire pages
- Putting images behind the text
- Managing floating figures
- Understanding placement options
- Forcing the output of figures
- Limiting floating
- Avoiding floating altogether
- Arranging multiple images
- Letting text flow around images
- Summary
- Chapter 7: Using Cross-References
- Setting labels and references
- Assigning a label
- Referring directly to a labeled position
- Referring to a page
- Using advanced referencing
- Producing smart page references
- Fine-tuning page references
- Referring to page ranges
- Using automatic reference names
- Combining smart references with automatic naming
- Referencing section names and captions
- Referring to labels in other documents
- Checking labels and references
- Displaying labels
- Identifying duplicate labels
- Verifying references
- Turning references into hyperlinks
- Summary
- Chapter 8: Managing Contents, Indexes, and Bibliography
- Customizing the table of contents
- Adjusting the depth of the TOC
- Shortening TOC entries
- Adding TOC entries manually
- Creating and customizing lists of figures
- Creating a list of tables
- Using packages for customization
- Generating an index
- Defining index entries and subentries
- Specifying page ranges
- Using symbols and macros in the index
- Referring to other index entries
- Fine-tuning page numbers
- Designing the index layout
- Creating a bibliography
- Using the built-in bibliography environment
- Using bibliography databases with BibTeX
- Looking at the BibTeX entry fields
- Citing internet resources
- Understanding BibTeX entry types
- Choosing the bibliography style
- Listing references without citing
- Changing the headings
- Adding a glossary
- Summary
- Chapter 9: Writing Math Formulas
- Writing basic formulas
- Embedding math expressions within text
- Displaying formulas
- Numbering equations
- Adding subscripts and superscripts
- Using operators
- Typesetting roots
- Writing fractions
- Writing Greek letters
- Writing script letters
- Producing an ellipsis
- Changing the font, style, and size
- Customizing displayed formulas
- Typesetting multi-line formulas
- Numbering lines in multi-line formulas
- Inserting text into formulas
- Exploring the wealth of math symbols
- Binary operation symbols
- Relation symbols
- Inequality relation symbols
- Subset and superset symbols
- Arrows
- Harpoons
- Symbols derived from letters
- Miscellaneous symbols
- Writing units
- Variable-sized operators
- Variable-sized delimiters
- Building math structures
- Creating arrays
- Typesetting matrices
- Writing binomial coefficients
- Underlining and overlining
- Setting accents
- Putting a symbol above or below another one
- Writing theorems and definitions
- Extended math tools
- Summary
- Chapter 10: Using Fonts
- Using comprehensive font bundles
- Latin Modern - a replacement for the standard font
- Kp-Fonts - another extensive set of fonts
- Choosing specific font families
- Serif fonts
- Times Roman
- Palatino
- Charter
- New Century Schoolbook
- Concrete Roman
- Bookman
- Sans-serif fonts
- Arev
- Computer Modern Bright
- Kurier
- Helvetica
- Typewriter fonts
- Courier
- Inconsolata
- Bera Mono
- Calligraphic fonts
- Calligra
- Miama Nueva
- Writing with TrueType and OpenType system fonts
- Selecting the main font
- Selecting multiple font families
- Selecting a font locally
- Summary
- Chapter 11: Developing Large Documents
- Splitting the input
- Including small pieces of code
- Including bigger parts of a document
- Compiling parts of a document
- Creating front and back matter
- Designing a title page
- Working with templates
- Organizing files and folders
- Summary
- Chapter 12: Using Hyperlinks and Designing Headings
- Working with hyperlinks
- Adding hyperlinks
- Customizing hyperlinks
- Creating hyperlinks manually
- Creating bookmarks
- Using math formulas and special symbols in bookmarks
- Designing headings
- Summary
- Chapter 13: Creating Presentations
- Getting started with the beamer class
- Using overlays and incremental reveals
- Pausing content
- Using incremental specifications
- Using shorthand
- Arranging columns
- Using blocks
- Generating a handout
- Summary
- Chapter 14: Troubleshooting
- Understanding and fixing errors
- Handling the preamble and document body
- Using commands and environments
- Writing math formulas
- Working with files
- Creating tables and arrays
- Working with lists
- Working with floating figures and tables
- General syntax errors
- Handling warnings
- Justifying text
- Referencing
- Choosing fonts
- Placing figures and tables
- Customizing the document class
- Avoiding obsolete classes and packages
- General troubleshooting
- Summary
- Chapter 15: Using Online Resources
- Web forums, Q&A sites, and discussion boards
- LaTeX.org
- TeX and LaTeX on Stack Exchange
- Forums in other languages
- Usenet groups
- Lists of frequently asked questions
- Mailing lists
- TeX user group websites
- The TeX Users Group
- DANTE
- The LaTeX project
- Other local user groups
- Websites for LaTeX software and editors
- LaTeX distributions
- LaTeX editors
- Cross-platform
- Windows
- Linux
- macOS
- The visual editor LyX
- CTAN - the Comprehensive TeX Archive Network
- Graphics galleries
- LaTeX blogs
- X, formerly Twitter
- Summary
- Chapter 16: Exploring Technology: From Engines to AI
- Looking at TeX engines
- The classic TeX engine and DVI output
- pdfTeX: today's workhorse
- XeTeX: Unicode and system fonts
- LuaTeX: extensibility and programmability
- LuaMetaTeX: combining TeX, Lua, and MetaPost
- Understanding TeX formats
- Plain TeX
- LaTeX
- ConTeXt
- Selecting engine and format
- Using artificial intelligence
- Working with AI efficiently
- Asking LaTeX-related questions
- Suggesting packages and alternative solutions
- Generating LaTeX code
- Explaining error and warning messages
- Troubleshooting and debugging
- Improving and polishing existing text
- Brainstorming structure, titles, and section ideas
- Using AI responsibly and carefully
- Looking at the future of AI and LaTeX
- Further reading
- LaTeX Cookbook: over 100 practical and advanced LaTeX solutions
- LaTeX Graphics with TikZ: drawing images
- The LaTeX Companion
- Summary
- Chapter 17: Unlock Your Exclusive Benefits
- Index
- Other Books You May Enjoy
Preface
LaTeX is high-quality, open source typesetting software that produces professional-quality print and PDF output. However, as LaTeX is a powerful and complex tool, getting started can be intimidating, and specific aspects such as layout modifications can seem rather complicated. Using Microsoft Word or other word-processing software may seem more straightforward, but once you've become acquainted with it, LaTeX's capabilities far outweigh any initial difficulties. This book guides you through these challenges and makes it easy to begin with LaTeX. If you are writing mathematical, scientific, or technical papers, this is the perfect book for you.
LaTeX Beginner's Guide, Third Edition, offers you a practical introduction to LaTeX, guiding you through the essential steps of LaTeX, from installing LaTeX to formatting, justification, and page design, including presentation slides. You will learn how to use macros and styles to maintain a consistent document structure while reducing typing. Beginning with installation and basic usage, you will learn how to typeset documents that include professional-looking tables, figures, mathematical formulas, and common book elements such as bibliographies, glossaries, and indexes. Lots of step-by-step examples start with fine-tuning text, formulas, and page layout, and proceed with managing complex documents and using modern PDF features. Detailed information about online resources such as software archives, web forums, and online compilers complements this introductory guide.
Finally, we'll look under the hood at the TeX engines and use artificial intelligence tools to support our work.
Who this book is for
If you are about to write mathematical or scientific papers, seminar handouts, or even plan to write a thesis, then this book offers you a fast-paced and practical introduction. Those studying at school and university as mathematicians or physicists will benefit greatly, as will engineers and humanities students. Anybody with high expectations who plans to write a paper or a book will be delighted by this high-quality, stable software.
What this book covers
Chapter 1, Getting Started with LaTeX, introduces LaTeX and explains its benefits. It guides you through the download and installation of a comprehensive LaTeX distribution and shows you how to create your first LaTeX document. It also introduces Overleaf, an online LaTeX editor. You'll also learn how to access package documentation.
Chapter 2, Formatting Text and Creating Macros, explains how to vary fonts, shapes, and text styles. It covers centering and justification of paragraphs, and how we can improve line breaks and hyphenation. It introduces logical formatting and explains how to define macros and use environments and packages.
Chapter 3, Designing Pages, shows how to adjust margins and line spacing, and how to work with portrait, landscape, and two-column layouts. It shows how to create dynamic headers and footers, control page breaks, and use footnotes. Along the way, you'll also learn how to redefine existing commands and make effective use of class options.
Chapter 4, Creating Lists, covers bulleted, numbered, and definition lists. It shows how to choose bullet and numbering styles and how to fine-tune the overall layout of lists.
Chapter 5, Creating Tables, shows you how to create professional-looking tables and goes deep into formatting details.
Chapter 6, Including Images, explains how to include external images with captions and how LaTeX handles figure placement automatically, with options to adjust it when needed.
Chapter 7, Using Cross-References, introduces smart referencing for sections, footnotes, tables, figures, and numbered environments.
Chapter 8, Managing Contents, Indexes, and Bibliography, explains how to create and customize the table of contents and the lists of figures and tables. It also shows how to cite sources, build bibliographies, and create an index.
Chapter 9, Writing Math Formulas, introduces mathematical typesetting in depth. It starts with basic formulas, then moves on to displayed and numbered equations and the alignment of multi-line expressions. You'll learn how to typeset math symbols such as roots, arrows, Greek letters, and operators, and how to build more complex structures, such as fractions, stacked expressions, and matrices.
Chapter 10, Using Fonts, introduces font selection in LaTeX and shows Roman, sans-serif, and typewriter fonts in various shapes and styles.
Chapter 11, Developing Large Documents, shows how to manage larger projects by splitting them into multiple files. You'll learn how to build complex documents from smaller parts, handle front and back matter with separate page numbering, and create custom title pages. Working through an example book, you'll also get familiar with templates, preparing you to write your own thesis, book, or report.
Chapter 12, Using Hyperlinks and Designing Headings, explains how to enrich PDF documents with hyperlinks, bookmarks, and metadata. It also shows how to customize chapter and section headings.
Chapter 13, Creating Presentations, walks through building slides with LaTeX, from incremental reveals to column and block layouts, and generating handouts.
Chapter 14, Troubleshooting, focuses on solving problems. You'll learn about typical LaTeX errors and warnings and how to read and use LaTeX's messages to track down and correct issues.
Chapter 15, Using Online Resources, shows you where to find reliable LaTeX information on the internet. We'll look at forums and Q&A sites, explore software archives and TeX user group pages, and point you to mailing lists, Usenet groups, and graphics galleries. The chapter also highlights where to download LaTeX editors and where LaTeX users meet on blogs and X.com.
Chapter 16, Exploring Technology: From Engines to AI, takes a look under the hood at TeX engines, compares them, and discusses when to use which one. The chapter also covers AI tools that can improve your coding, writing, and formatting workflows and concludes with recommended reading.
To get the most out of this book
You need access to a computer with LaTeX on it. An online connection would be helpful regarding installation and updates. We can install LaTeX on most operating systems, so you can use Windows, Linux, macOS, or Unix.
This book uses the freely available TeX Live distribution, which runs on all the mentioned platforms. You just need an internet connection or the TeX Live DVD to install it. In the book, we use the cross-platform editor TeXworks, but you can use any editor you like.
Without installing LaTeX, you can work with the code examples at https://latexguide.org, which comes with an online compiler.
If you are using the digital version of this book, we advise you to type the code yourself or access the code from the book's GitHub repository (a link is available in the next section). Doing so will help you avoid potential errors when copying and pasting code.
Download the example code files
The code bundle for the book is hosted on GitHub at https://github.com/PacktPublishing/LaTeX-Beginner-s-Guide-Third-Edition. We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing. Check them out!
Download the color images
We also provide a PDF file that has color images of the screenshots/diagrams used in this book. You can download it here: https://packt.link/gbp/9781805804574.
Conventions used
A number of text conventions are used throughout this book.
CodeInText: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. For example: "The first line starts with the \documentclass command."
A block of code is set as follows:
\begin{name}[optional argument]{argument} . \end{name} When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:
\documentclass{article} \newcommand{\keyword}[2][\bfseries]{{#1#2}} \begin{document} Any command-line input or output is written as follows:
texdoc beamer Screentext: Indicates a new term, an important word, or words that you see on the screen. For instance, words in menus or dialog boxes appear in the text like this. For example: "Click Typeset and check out the result."
Warnings or important notes appear like this.
Tips and tricks appear like this.
Get in touch
Feedback from our readers is always welcome.
General feedback: If you have questions about any aspect of this book or general feedback, please email us at customercare@packt.com and mention the book's title in the...
System requirements
File format: ePUB
Copy protection: Adobe-DRM (Digital Rights Management)
System requirements:
- Computer (Windows; MacOS X; Linux): Install the free reader Adobe Digital Editions prior to download (see eBook Help).
- Tablet/smartphone (Android; iOS): Install the free app Adobe Digital Editions or the app PocketBook before downloading (see eBook Help).
- E-reader: Bookeen, Kobo, Pocketbook, Sony, Tolino and many more (not Kindle).
The file format ePub works well for novels and non-fiction books – i.e., „flowing” text without complex layout. On an e-reader or smartphone, line and page breaks automatically adjust to fit the small displays.
This eBook uses Adobe-DRM, a „hard” copy protection. If the necessary requirements are not met, unfortunately you will not be able to open the eBook. You will therefore need to prepare your reading hardware before downloading.
Please note: We strongly recommend that you authorise using your personal Adobe ID after installation of any reading software.
For more information, see our ebook Help page.
File format: ePUB
Copy protection: without DRM (Digital Rights Management)
System requirements:
- Computer (Windows; MacOS X; Linux): Use a reader that can handle the file format ePUB, such as Adobe Digital Editions or FBReader – both free (see eBook Help).
- Tablet/Smartphone (Android; iOS): Install the free app Adobe Digital Editions or the app PocketBook (see eBook Help).
- E-reader: Bookeen, Kobo, Pocketbook, Sony, Tolino and many more (not Kindle).
The file format ePUB works well for novels and non-fiction books – i.e., 'flowing' text without complex layout. On an e-reader or smartphone, line and page breaks automatically adjust to fit the small displays.
This eBook does not use copy protection or Digital Rights Management
For more information, see our eBook Help page.