{diagrams} is for general questions about vector graphics created programmatically inside a (La)TeX document. For questions about specific packages, use the appropriate tag, e.g. {tikz-pgf} or {pstricks}. For questions about inclusion of external graphic files, use {graphics} instead.

learn more… | top users | synonyms (1)

175
votes
4answers
27k views

Drawing on an image with TikZ

Recently I have learned how to draw simple stuff with TikZ. I really like it. Now I wonder if it is possible to draw with TikZ on a image. Instead of pasting a image in Illustrator and adding some ...
23
votes
4answers
4k views

How to draw arrows between parts of an equation to show the Math Distributive Property (Multiplication)?

there is a part of my paper where I use the distributive property and it's not that clear for the reader to see (I'm using in proposional logic for a proof). The logic equation (part of) is: (l_{1}) ...
38
votes
4answers
5k views

How do you draw the “snake” arrow for the connecting homomorphism in the snake lemma?

How does one draw the "snake" arrow for the connecting homomorphism when using the snake lemma? I'd also be interested in drawing similar arrows act as "carriage returns" when considering a long ...
82
votes
8answers
7k views

Simulating hand-drawn lines

I am working on a project that will have some vector graphics, perhaps using TikZ (or a similar tool). All of the graphics consists of lines, in shades of gray. However, the lines from TikZ appear too ...
37
votes
8answers
6k views

How to draw a torus

Is there an easy way to draw a contour image of torus below with tikz? Or for that matter with any other graphics package.
35
votes
11answers
27k views

Best way to generate a nice function graph in LaTeX?

Which is the best way to put function graphs into a LaTeX document?
44
votes
7answers
17k views

Typsetting UML class diagrams

What's the best way to draw UML class diagrams in LaTeX?
49
votes
4answers
8k views

How do I insert an image in LaTeX so it looks good on print?

LaTeX documents print beautifully, but images often looks "ugly", "pixelated" or "low-res" compared to the text. By images I don't mean photos, which I rarely use, but rather diagrams, charts and ...
21
votes
1answer
2k views

TikZ picture shapes

I am very new to the TikZ package, and I need to draw some flow chars by using the following shapes. However I couldn't figure out how to draw the 4th and and 6th ones below. It would be very nice ...
7
votes
2answers
2k views

Centering a TikZ picture around an area

I often find myself in the following situation: A tikzpicture of mine consists of a main area and some outer material like text labels which are hardly symmetric around the main area. If such a ...
41
votes
7answers
15k views

What graphics packages are there for creating graphics in LaTeX documents?

What packages do you use and recommend for creating graphics in your LaTeX documents? As this is a community wiki post, please add your package to the accepted answer (or add a comment, and ...
39
votes
3answers
9k views

Drawing Mechanical Systems in LaTeX

I really like CircuiTikZ for drawing diagrams in my LaTeX documents. However I mostly draw mechanical and not electronic systems, which is why I'm looking for some similar way to draw mechanical ...
9
votes
3answers
850 views

Replicate this chart using LaTeX

I need to replicate this chart using LaTeX, I understand that TikZ should come in handy: Can anyone please show me the best and easiest way to render the chart? Any ideas, tips, nudges in the right ...
4
votes
2answers
2k views

Center flow chart horizontally

I have the following flow chart but it appears uncentered. How can I center it? \documentclass{article} \usepackage{pstricks} \usepackage{pst-node} \usepackage{pst-blur} \pagestyle{empty} ...
102
votes
12answers
6k views

Can we make a love heart with LaTeX?

I understand that this post may cause some down votes because it seems a bit off-topic, but having seen the discussion on Christmas Tree with LaTeX I am still willing to try. My Girlfriend's birthday ...
66
votes
1answer
4k views

PowerPoint's “Smart Art” for TikZ?

This question led to a new package: smartdiagram I haven't been using PowerPoint for years, but today I immediately fell in love with its "Smart Art" feature (2010 version of PowerPoint). The ...
8
votes
4answers
2k views

Neural Network representation

I would like to translate to Spanish a diagram that represents a neural network, the diagrama is something like this: I would like to clone the design and effects, so I need some examples to do ...
20
votes
1answer
4k views

Making a (simple) directory tree

I'm trying to make a simple directory tree representation in LaTeX. Something like: spam | +-- ham +-- eggs | +-- more spam +-- dead parrots The tree won't be that long (say, ...
14
votes
3answers
3k views

How should I draw a singly/double linked list?

I need to draw some singly and double linked lists for a CS paper and I don't know what package should I use. As far as I've searched over the Internet I can't seem to find a good one. Maybe TiKZ/PGF? ...
41
votes
2answers
5k views

Wordle-like word clouds

Wordle creates word clouds based on the frequency on words in a text, similar to tag clouds. What makes it unique is that it can lay out words in arbitrary directions without too much white space. See ...
27
votes
4answers
8k views

Node shapes in TikZ

I want to draw a block diagram for a software app and I need two shapes which I couldn't find on the Internet. The shapes are a parallelogram and a rectangle with double side margins. One is for data ...
23
votes
2answers
5k views

How to draw a poset Hasse Diagram using TikZ?

I need to draw an Hasse Diagram using LaTeX. TikZ is the solution I would like to use. I tried with a simple structure involving trees but obviously when I need to join two nodes, it is not possible. ...
20
votes
4answers
4k views

Is there a way to control whitespace around a TikZ picture?

When I draw a tikzpicture that includes paths, I get quite a bit of extra whitespace added around the elements of the picture. Depending on the elements the figure contains, this can work out in some ...
11
votes
5answers
4k views

Commutative Diagrams and TikZ

I wish I knew how to draw the this commutative diagram with the TikZ package. I would also like to know how to put subtitles in the diagram.
11
votes
2answers
1k views

Which package can easily write a graph, as an arbitrary curve or area, just for indication

Which package can easily write a graph, as an arbitrary curve or area, just for indication? The circle and ellipse don't be considered for their particular shape. TIKZ's B├ęzier curve is too ...
7
votes
3answers
4k views

Problem with TikZ and vertical alignment of text inside nodes

I have a problem in TikZ with the vertical alignment of text inside nodes. With a very minimal example like this: \usetikzlibrary{arrows,positioning,shapes.geometric} \begin{tikzpicture}[% ->, ...
17
votes
1answer
924 views

Is it possible to use spot colors in TikZ graphics?

Using ConTeXt and Metapost, it is fairly easy to define spot colors and use them in an image: \starttext \definecolor[MyRed][c=0,m=1,y=1,k=0] \definespotcolor[RedSpot][MyRed][p=1,e=MyRed] ...
8
votes
2answers
359 views

Pretty lists for sorting algorithms

I would like to obtain easily something like in this picture so as to illustrate several sorting algorithms. To produce one line, I would like to use one command of the following kind where the ...
26
votes
3answers
3k views

Drawing random paths in TikZ

I am looking for a way to draw with TikZ something that looks like a random path. Here is an inspiration: Is it possible to have TikZ generate something that would be similar to a random path ...
12
votes
1answer
2k views

How to draw lines around multiple table cells

\documentclass[fleqn,12pt,a4paper]{article} \usepackage{tabularx} \begin{document} \begin{table}[ht] \begin{minipage}[b]{1 \linewidth}\centering \begin{tabular}{|c|c|c|c|c|} \hline ...
16
votes
2answers
3k views

Drawing hexagons

I have a case where I need to draw a hexagonal grid in LaTeX. I am considering just reading the grid from an eps file. Is there an alternative way to do it completely within LaTeX?
15
votes
1answer
2k views

How to open a temporary comics-like balloon in a beamer slide?

I would like to open a temporary comics-like balloons to explain a specific word in a beamer slide. Somebody has suggestions?
18
votes
3answers
942 views

Amoeba shape with TikZ

I would like to draw generic amoeba-like shapes with TikZ and don't really want to think too deeply about its boundary. Basically a closed connected set with smooth locally convex boundaries. Any ...
10
votes
4answers
2k views

Drawing arrow heads without the tails in TikZ?

I have an ellipse in a TikZ diagram and I would like to indicate a direction using an arrow head, but do not wish to draw the path leading up to the arrow head. I currently have \draw[->] (0,2) ...
12
votes
3answers
1k views

callout and beamer

I am trying the callout code that Andrew has provided at How to open a temporary comics-like balloon in a beamer slide?, but I am getting an error: Undefined control sequence. \pgf@sh@bg@ellipse ...
8
votes
1answer
767 views

Theorem decorations that stay with theorem environment

I am typesetting a document using the memoir documentclass. Currently, my theorems have the following definition (using macros provided by the ntheorem package): % THEOREMS ...
6
votes
2answers
3k views

Feynman Diagrams with tikz

I am trying to find some example code for some very simple Feynman diagrams. Something similar to any or all of the pictures below I was able to find some example code on texample.net, but being ...
269
votes
46answers
70k views

Nice scientific pictures show off

Task Show off your best scientific illustration ! The main purpose of this question is to share beautiful scientific pictures, preferably with an educational aspect. Content Your post must ...
70
votes
3answers
3k views

How to draw a Sankey Diagram using TikZ

I would like to draw something similar to this (not exactly): using TikZ. Ideally I would be able to set the width by variables and rejoin two flows into one again. Is there a good way to do this? ...
26
votes
3answers
3k views

How to draw tangent vectors and component vectors on a curve

I am searching for a way to have a figure drawn using LaTeX. I am aware of some packages TikZ and PSTricks that could accomplish this, and have been tinkering around with them recently but do not have ...
35
votes
1answer
2k views

Plotting several 2d functions in a 3d graph

I am trying to reproduce a similar figure to the following one. My first guess was to use pgfplots but I didn't find any example that I could use as a starting point. At the moment I am unsure if ...
36
votes
2answers
7k views

Which package can be used to draw automata?

I'm looking for a LaTeX package which helps drawing automata problems. I googled and found A package for drawing automata and graphs (Version 0.4). But I'm not sure is this package a standard one, or ...
28
votes
2answers
2k views

Drawing a hypergraph

What is the proper way to draw a hypergraph? Is there a package to do this, or is there an easy way to draw such diagrams with a common drawing method like tikz? I'm trying to draw something like
22
votes
5answers
3k views

Drawing stars/similar with Tikz

I'm writing a review for a book at the moment, and I thought I'd be clever and show off what LaTeX is capable of by adding a x-out-of-y stars graphic. Tikz can do many things so I would have thought ...
13
votes
3answers
6k views

Is there any way to type LaTeX code directly into the text boxes Inkscape?

I use Inkscape on Windows 7 platform. The principle to enter integrals and other mathematical symbols in Inkscape seems that the best thing to do and write them in a LaTeX compiler and cut them in ...
23
votes
3answers
3k views

How to draw Kiviat Diagrams

This question led to a new package: tkz-kiviat Is there a way to draw Kiviat diagrams easily?
20
votes
1answer
14k views

How to make bend lines/arrows with TikZ?

I've been testing out TikZ lately, but I'm still quite new to it. What I want to do is to create a line to indicate that a parameter belongs to a part of the drawing. For example "This surface that ...
23
votes
4answers
3k views

Is there an easy way to TeX geometric pictures?

Say I want to include geometry graphics such as the following in a document: I don't merely want to import preexisting figures, I want to be able to draw my own corresponding to a solution I may ...
9
votes
2answers
4k views

How to draw up a hierarchical tree diagram for taxonomic classification

Please show me the most simple, elegant code for this: How to do it in other words.
8
votes
2answers
685 views

Drawing the contour of a 3d torus

I would like to draw a torus, like the one on the question How to draw a torus, with a 3d package. I would like to avoid drawing the torus in 2d with inkscape (or directly with tikz) because I will ...