TikZ is a higher-level drawing language built on top of the PGF graphics framework. For questions specifically about the PGF layer use {pgf-core} instead. Both tags are possible on the same question. The tag {diagrams} is also compatible with this tag.

learn more… | top users | synonyms (3)

16
votes
2answers
2k views

Drawing complex integration [duplicate]

Could someone help me to draw this picture but in point (0,0) to have small circle negative oriented, like here I am beginner with tikz and this looks to complicated for me. Any help is ...
2
votes
0answers
113 views

Artifacts in TikZ picture when using scale option [closed]

When compiling the example code below with pdflatex Version 3.1415926-2.4-1.40.13 (TeX Live 2012/W32TeX), I observe an artifact (horizontal line starting from the start point of the objects) in the ...
5
votes
1answer
177 views

Crossed hierarchy

I appreciate it if you let me know the most elegant way to draw a crossed hierarchy such as the followings: X /\ Y Z /\/\ p q t q has two parents Y and Z.
7
votes
3answers
390 views

Fitting as a background to nodes in multiple pictures

I'm using TikZ pictures to represent terms in an equation, and I want to visually group some of these terms by drawing a rectangle behind them. But each term is its own separate picture, which means I ...
3
votes
1answer
2k views

how to fill intersection of 2 shapes in latex tikz package [duplicate]

I have to fill a specific region as given in the following figure. The code I have written is \begin{tikzpicture} \draw (0,0) rectangle (10,10); \draw (3.5,3.5) circle (5) node {A}; ...
6
votes
1answer
3k views

2D surface on a 3D surface plot external data in a file

I am drawing a 3D surface from external data. Here they are: 0 0 -0.64 1 0 -0.5 2 0 -0.4 3 0 -0.31 4 0 -0.23 5 0 -0.2 6 0 -0.24 7 0 -0.32 8 0 -0.42 9 0 -0.59 10 0 -0.76 0 1 -0.54 1 1 -0.4 2 1 -0.27 ...
9
votes
2answers
2k views

Tikz add arrows to multiple segments of a `\draw` command

I'm drawing an org chart and I'd like to have arrows pointing to each of the nodes I do so. I'm also lazily using a single draw command to draw a line from each of the nodes as the last part of my ...
3
votes
1answer
2k views

Bell curve with multiple x-axes and annotations

I've just started working with pgfplots and I'm getting good results, but I'm having difficulties getting this one done in LaTeX: The curve itself is not a problem, but the multiple x-axes (I don't ...
5
votes
2answers
605 views

Uncover parts of a tree in TikZ

I'm trying to apply Daniel's method to uncover the bottom right part of the tree in the following MWE. However, when I pass the option [visible on=<2->] to one of the children, it appears to ...
11
votes
1answer
968 views

Draw additional parallel paths in TikZ

How can parallel lines elegantly be added to an existing path? I am looking for a solution or hint to, how a general style can be made, that works with any path. Example path: ...
1
vote
0answers
112 views

No correct output [closed]

After installation of the last version of MiKTeX and TikZ, I created following document: \documentclass{article} \usepackage{tikz} \begin{document} The version of Tikz is : \pgfversion ...
0
votes
0answers
36 views

Place node at right of and above of centered [duplicate]

Is there a way to place a node in TikZ such that it is above/below a certain node and left/right of another, while being centered with the other corresponding node. In the MWE is below, I want to ...
1
vote
1answer
897 views

arrow heads on arc curves

How can I have arrow head appear properly on the arced curve? \documentclass{article} \usepackage{tikz} \usetikzlibrary{arrows,decorations.markings,calc,fadings,decorations.pathreplacing, patterns, ...
10
votes
1answer
2k views

TikZ: adding nodes to a circular diagram from smartdiagram package

This is what I would like to achieve: My MWE is below: \documentclass{article} \pagestyle{empty} \usepackage{lmodern} \usepackage{smartdiagram} \usetikzlibrary{shapes.geometric} ...
2
votes
1answer
2k views

gnuplot and TexnicCenter setup

I just downloaded and ran the gnuplot setup exe. Now, how do I setup TeXnicCenter and gnuplot so I can use gnuplot with TikZ? So I have been able to add --enable-write18 but the inverted cycloid ...
0
votes
1answer
2k views

tikz pgfplots forget plot

I'm having problems finding how to use forget plot in tikz. I need only 2 legendentries like this: but get a massive long list of every object in the graph. This post addresses the problem but seems ...
4
votes
1answer
174 views

Creating labes on diagram edges

I want to add labels 3, 4, 5 on tree edges like you can see on picture, but I don't know how :( My minimal example: \documentclass{article} \usepackage[T1]{fontenc} \usepackage{tikz} ...
23
votes
3answers
2k views

How to build parallel paths between nodes?

I want to create a figure with TikZ: I tried first with the following code (remark: Complete MWE on bottom): \begin{tikzpicture} \node [block] (A) at (0,0) {\rule{2cm}{2cm}}; \node [block] (B) at ...
7
votes
1answer
623 views

TikZ flowchart child

Is it possible to show block C as a single block rather than having 3 blocks? \documentclass[landscape]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} ...
0
votes
1answer
473 views

protocol message diagram - rectangle

\documentclass{article} \usepackage[margin=12mm]{geometry} \usepackage{hyperref} \usepackage[underline=true]{pgf-umlsd} \usetikzlibrary{calc} \begin{document} \begin{sequencediagram} ...
2
votes
1answer
169 views

Can't find tikz subfiles

I've the following project structure: ./main.tex ./ch1/ch1.tex ./ch1/tikz1/tikz1.tex The main.tex looks like: \documentclass{book} \begin{document} \subfile{./ch1/ch1.tex} \end{document} The ...
4
votes
2answers
156 views

Is PostScript access from TeX (via PSTricks or TikZ) safe?

PSTricks and TikZ grant us access to PostScript. Is it safe? I meant: Is there a vulnerability hole open for someone to exploit? Edit: I just found that compiling PSTricks with xelatex might be ...
4
votes
0answers
926 views

Matlab2tikz adds extra legend entries [closed]

The legend from a boxplot figure is not being created properly. I get this: Instead of thiS: But really only need 2 legend entries. Any Ideas why all the objects in this plot are being given ...
7
votes
3answers
1k views

Delayed drawing of arrows in tikz-cd

I want to draw an arrow which passes over another arrow in a tikz-cd commutative diagram. I can do that as follows from the documentation: \documentclass{article} \usepackage{tikz-cd} ...
4
votes
1answer
835 views

joining atoms in chemfig. Two adjacent molcules

This is a follow up of drawing cellulose and aligning monomers in chemfig. I'm trying to refine the structure adding some hydrogen bonds. No problem with the intra-chain ones, but I cannot figure ...
3
votes
1answer
764 views

How to draw the outlines of a patch in pgfplots?

In pgfplots the patch plot library allows to basically draw 3D bezier planes easily. This is very helpful if the exact mathematical form of a plane is not known or not important. What I have not ...
4
votes
2answers
671 views

protocol message diagram - arrow colored

\documentclass{article} \usepackage[margin=12mm]{geometry} \usepackage{hyperref} \usepackage[underline=true]{pgf-umlsd} \usetikzlibrary{calc} \begin{document} \begin{sequencediagram} \newinst{ue}{UE} ...
35
votes
6answers
11k views

Why draw diagrams using LaTeX when there are open source tools like OpenOffice?

I was looking at recent questions here and was surprized that people were drawing diagrams in LaTeX, when it can be done in SmartDraw, OpenOffice or other programs. Is there any benefit to using LaTeX ...
29
votes
3answers
3k views

How to draw a layered architecture using Latex?

I have a layered architecture to be drawn in a paper. The architecture looks similar to the one below. How to draw something like this? What I have so far: ...
11
votes
1answer
2k views

How do I zoom a rectangle area in pgfplots adding a gray background even for the axis labels?

The background to this question is: I want to "zoom" into a certain area of a function and show it a little bigger. Furthermore, I want to put a gray rectangle as a background of the zoomed area, ...
5
votes
1answer
702 views

How can I customize TikZ’ calendar?

I'm playing around with the TikZ’ calendar library to make a simple course calendar. I want to make weekend days and days when there is a week break or something to be grayed out, lecture days to be ...
8
votes
1answer
1k views

Tikz: \foreach and axis environment incompatibility

I'm trying to plot a figure with TikZ. I have a few .txt files with the coordinates of the curves that I want to plot, in a list such as file2.txt, file4.txt, ... file30.txt and I want to add ...
3
votes
1answer
416 views

Test on same shaped with Tikz and PStricks

Following up at my previous question: let operation vs tkz-euclide Could Tikz fans and PStricks respectively give the same shaped, as following, as to see the advantages and disadvantages of each ...
4
votes
1answer
2k views

Big wide arrows, how to?

I saw someone use this scripts to generate big arrows, but it seems quite tricky to me. And I also hope the arrow is not filled. Any good ideas? \draw[ -triangle 45, line width=1.0mm, ...
13
votes
5answers
1k views

How to draw a return arrow from node-3 to node-1

Say I have a code to draw a flow chart, I want now a arrow from node 3 to node 1, how can I do that? 1<--| | | 2 | | | 3---- MWE \documentclass[class=article,border=0pt]{standalone} ...
1
vote
0answers
451 views

mindmap with rendering artifacts [closed]

I am trying to render this mindmap but I am getting some artifacts. Can anyone tell why. \documentclass{article} \usepackage{pgfplots} \usetikzlibrary{mindmap,trees, backgrounds} \begin{document} ...
9
votes
1answer
254 views

Loop Over Grid File

I have a grid file with data such as: 5 4 0 0 0 0 0 0 1 1 2 0 0 2 2 1 0 3 0 0 3 1 where 5 is the width of the grid, 4 is the height, and each number in the grid corresponds to an elevation. I can ...
5
votes
1answer
359 views

Why it is not centered?

Could anyone tell me why the following scripts have non-zero margin in the left side of the figure???? \documentclass[class=minimal,border=0pt]{standalone} \usepackage{tikz} ...
5
votes
2answers
456 views

new command, pfgkeys within pfgplots axis environment

I am trying to setup an command to create technical drawing dimensions (inspiration from Dimensioning of a technical drawing in TikZ). I would like to use pgfkeys for that, in order to pass multiple ...
2
votes
0answers
226 views

Scatterplot with TikZ/pgfplots [duplicate]

I have 7 *.txt files each with 2 columns of data thus: time(mins) contacts 3.25 8 1.166666667 4 3.2 6 3.2 7 2.25 8 5.466666667 12 2.25 3 2.166666667 7 I'd like to plot them in separate ...
7
votes
1answer
5k views

How to position one node relative to another node at a certain angle in TikZ taking the nodes' size into account?

I asked a question before about how to position a node relative to another node at a certain angle in TikZ, and the answer I got there was that you can use the \path (node1) ++(angle:distance) node ...
5
votes
3answers
472 views

let operation vs tkz-euclide

Before put my question to give some explanation of why I do this question. When I started to use the TeX a matter of luck that I started working with LaTeX (xelatex) and not with LuaTex for example. ...
2
votes
1answer
489 views

bodegraph package just display grids but not curves

I'm using pdfLatex (with --shell-escape option) and I had a problem of compilation with TexWorks that was successfully solved with the help of other post in this site: bodegraph on Ubuntu 10.04. ...
0
votes
1answer
235 views

Stacked chart in TeX (added up line loads)

I've got a problem with finding the correct way or commands to make a nice plot in TeX, even with some basic experience in pgf/TikZ. Imagine a weight distribution with start- and stop values and a ...
2
votes
1answer
2k views

Figure in beamer moves around

This is a MWE of my code: \documentclass{beamer} \usepackage{tikz} \usetikzlibrary{shapes,arrows} \mode<presentation> { \usetheme{Frankfurt} \usecolortheme{dolphin} } \begin{document} ...
11
votes
3answers
502 views

arc that passes from (B) having a center on (A), automatically calculates (AB) distance

I want to create an arc which automatically calculates the distance (AB). Inspired by page 58 at pgf manual. But the code block % \draw (H) ++arc (15:60: $ (A) ! - ! (B) $); does not help much. ...
3
votes
1answer
284 views

Problem with snake ticks in pgfplots for bell shaped normal distribution

I want to draw two sided created region for normal distribution (see figure below). I have issue with snake ticks proper alignment and area looks suspicious to me. Am I missing something here? Any ...
2
votes
1answer
280 views

Create standalone pictures

I am trying to write a sample code to be used as a template to generate pictures that will be latter included in a paper. At this stage, the pictures are only plots. I have the following code. But it ...
9
votes
2answers
1k views

Fading of horizontal lines is impossible?

The path fading option in TikZ is obviously not working for horizontal lines. For plotting constant functions as well as for drawing a line between two points. Making them slightly tilted solves the ...
0
votes
0answers
78 views

TikZ coordinate calculation: Package tikz Error: + or - expected [duplicate]

TikZ calculates correctly the projection of a point and also draws it correctly, however after compiling LaTeX displays 2 error messages which I can not fix. Could you help finding what am I doing ...