Skip to content

If you need to include simple diagrams or figures in your document, the picture environment may be helpful. This article describes circles, lines, and other graphic elements created with LaTeX.


Images can be "programmed" directly in your LaTeX file



The syntax of the picture is


the parameters are passed inside parentheses, width and height as you may expect, determine the width and the height of the picture; the units for this parameter are set by \setlength{\unitlength}{1cm}. The second parameter is optional and establishes the coordinates for the lower-left corner. Below a description of other commands:

will draw a oval centred in the point 4,2. The parameter [r] is optional, you can use r, l, t and b to show the right, left, top or bottom part of the oval. If absent the whole oval is drawn.
draws a circle centred at the point (2,2.2) and whose diameter is 2.

In the next section the rest of the commands are described.

  Open an example the picture environment in ShareLaTeX

Combining lines, circles and text

Different basic elements can be combined for more complex pictures

\put(8,3.3){{\footnotesize $3$-simplex}}


In this example several lines and circles are combined to create a picture, then some text is added to label the points. Below each command is explained:

This changes the thickness of the lines, making them a bit thicker, you can also use \thinlines which has the opposite effect.
\put(8,3.3){{\footnotesize $3$-simplex}}
The text "3-simplex" is inserted at the point (8,3.3), the font size is set to footnotesize. The same command is used to label each point.
This draws a filled circle centred at (9,3) and it's diameter is 0.1. Is so small that is used as a point.


Draws a straight line, whose start point is at (10,1), it's length is 1 and it's direction is (3,2). As you see lines with arbitrary slopes are tricky to draw, some calculations must be performed for this.

Arrows can also be used inside a picture environment, let's see a second example

\put(220,195){upper state}
\put(220,45){lower state 1}
\put(220,5){lower state 2}


The syntax for vectors the same used for line

This renders a vector whose start point is (120,200), its length is 150 and the direction is (0,-1).

  Open an example the picture environment in ShareLaTeX

Bézier curves

Bézier curves are special curves that are drawn using three parameters, one start point, one end point and a control point that determines "how curved" it is.

\put(2,1){{Bézier curve}}


Notice that the command \qbezier (quadratic Bezier curve) is not inside a \put command. The parameters that must be passed are:

  • A start point,
  • A control point and
  • An endpoint.

Picture is the standard tool to create figures in LaTeX, as you see this is tool is sometimes too restrictive and cumbersome to work with, but it's supported by most of the compilers and no extra packages are needed. If you need to create complex figures, for more suitable and powerful tools see the TikZ package and Pgfplots package articles.

  Open an example the picture environment in ShareLaTeX

Further reading

For more information see

Overleaf guides

LaTeX Basics


Figures and tables

References and Citations


Document structure





Field specific

Class files

Advanced TeX/LaTeX