Ade Malsasa Akbar contact
Senior author, Open Source enthusiast.
Saturday, February 27, 2021 at 10:40

Academics people and alike tend to love documents written with LaTeX -- one of the best text creation systems you can run on computer. The benefit is, the resulting document is truly beautiful. To start making LaTeX document on Ubuntu, you can start with the user friendly application, Gummi, which features preview. This short tutorial includes examples for basic texting and several math formulas. Now let's learn!

Subscribe to UbuntuBuzz Telegram Channel to get article updates.

What is LaTeX? 

It is best to know LaTeX from the examples so you can grab PDF documents from KDE (KBibTex) and arxiv.org (Guix) among plenty plenty others to see how a LaTeX document looks.

(A beautiful book you can write too -- this is page 9 of KDE KBibTex program's user manual which is produced with LaTeX)

Basics

In LaTeX, basically you create everything with a start and an end. Everything is code with some frequent examples shown below.

Bold: \textbf{?}

Italic: \italic{?}

Underline: \underline{?}

Footnote: \footnote{?}

Bullets list: \item

Preparations

Install software needed to write LaTeX documents on your computer. Just run command below:

$ sudo apt-get install gummi texlive

First Step

Open start menu and run Gummi application. 

 

Create A Document

- Click File > New > a blank document appeared.

- Copy and paste this LaTeX code below.

- You instantly see the preview on the right.

- Click File > Save > give it file name document.tex > OK.

- Document created.


The code:

\documentclass{article}
\title{\textbf{Hello, \LaTeX!}}
\author{Ade Malsasa Akbar}
\begin{document}
\maketitle
\section{Introduction}
Hello, this is my document written with not word processor but {\LaTeX}.

\section{Basic Text}
I am a knowledge seeker who loves knowledge and now trying how good {\LaTeX} is. Apparently, it is truly beautiful! It supports \textbf{BOLD}, \emph{ITALIC}, \underline{UNDERLINE}, and also bullets and numberings. Do not forget pictures as well.

\section{Mathematics Text}
Below is some examples of math formulas.
\newline
Basic addition: $ 1 + 1 = 2 $
\newline
Basic multiplication: $ 2 \times 2 = 4 $
\newline
Basic fraction: $ \frac{1}{2} $
\newline
Basic trigonometry: $ \cos (2\theta) = \cos^2 \theta - \sin^2 \theta $
\newline

\end{document}

The result:
The program when writing:

Example above should be self-explanatory that basically, \textbf{?} is BOLD; while mathematically every formulae should be wrapped in $     $ (a pair of dollar signs) and \times is multiply sign. You can grasp the rest yourself. 
 
To create another document, simply copy paste example above and adjust everything else as you wish.

Edit Document

From the example above, please try to:

  • change the author name to yours,
  • change the title as you wish,
  • make some other bolds, italics, and underlines;
  • change the formulas by adding more additions, fractions, and cosines or sines;


Create PDF

Click menu File > Export as PDF > a PDF document produced in same folder as the .tex (dot tex) document file. Now your document can be opened in all computer devices including smartphones and can open collaborations with people across different operating systems.

 

Afterwords

That's all as a starter. I wish you feel the best experience of writing from here. For more exercise, try to read Wikibooks of LaTeX it gives you so many many examples to try. Enjoy writing!


This article is licensed under CC BY-SA 3.0.