TikZ: a LaTeX package for creating graphics in scientific documents

Dr. Soumen Atta, Ph.D.
5 min readSep 21, 2022
TikZ: a LaTeX package for creating graphics in scientific documents

In this tutorial, we will learn the basics of TikZ which is a LaTeX package for creating graphics in scientific documents. In this tutorial, it is assumed that the reader is familiar with the basics of LaTeX for writing scientific documents.

To use TikZ in our LaTeX document, we need to use the following package:

\usepackage{tikz}

Note that there is no need to use an external graphics program.

The basic structure of the TikZ code block is shown below:

\begin{tikzpicture}
< TikZ codes >
\end{tikzpicture}

Drawing lines

In TikZ, the basic drawing command is \draw. We can draw the figure shown below using TikZ commands. The corresponding codes are given below:

\begin{tikzpicture}[scale=1.5]
\draw[color=red,very thick]

--

--

Dr. Soumen Atta, Ph.D.
Dr. Soumen Atta, Ph.D.

Written by Dr. Soumen Atta, Ph.D.

I am a Postdoctoral Researcher at the Faculty of IT, University of Jyväskylä, Finland. You can find more about me on my homepage: https://www.soumenatta.com/

Responses (1)