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)

2
votes
1answer
97 views

What is the overflow limit for a named path in tikz / pgfplots?

I asked this question FillBetween library sometimes works and sometimes does not which led to this answer and discussion http://tex.stackexchange.com/a/180926/6908. There seems to be a limit of data ...
8
votes
4answers
896 views

How to bend more than 90 degree?

\documentclass{article} \usepackage{tikz} \usetikzlibrary{positioning} \begin{document} \begin{tikzpicture} \node(a){test}; \node(b)[below=5cm of a]{test2}; \draw[red,bend right=90](b.east)to(a.east); ...
3
votes
1answer
184 views

TikZ: extend a line along a path

I would like to extend a line. I could find the angle and then use (\angle:\radius) to do this. I was wondering if there is a way to execute this command without having to do the math. In the ...
2
votes
2answers
312 views

pgfplots- Adding a mark at the origin

I'm trying to show the beginning of a sketch of the graph y=xe^x, and this is what I have: \documentclass[10pt]{article} \usepackage{tikz} \usepackage{pgfplots} ...
0
votes
0answers
22 views

How to debug the “Argument of \XC@definec@lor has an extra }” error in Foreach statement? [duplicate]

First, I draw three nodes each of which has three parts. Everything is OK. The code and the image are as follows. \documentclass{article} \usepackage[utf8]{inputenc} \usepackage[]{tikz} ...
2
votes
1answer
173 views

Minus signs on coordinates not visible enough with TikZ

I want to draw a system of coordinates with TikZ. At the moment I use the following code (which I copied from somewhere). Now I would like to make the minus signs on the negative y-coordinates more ...
6
votes
3answers
683 views

Multiple tikz path fading in multiple directions

I'd like to create a theorem decoration. Here's a quick take on one: \documentclass{article} \usepackage{tikz} \newcommand{\theoremname}{Theorem} \newcounter{theorem} ...
3
votes
0answers
171 views

Fork down edge style with Tikz 3.0 tree graph

When node/child style is used, it is possible to achieve fork down edge style picured here: What would be the syntax for the similar edge style, but using graph? The below MWE produces sloped ...
11
votes
4answers
1k views

TikZ: How to make a convex lens

How can I make a convex lens with TikZ? I tried using arcs but this doesn't look right. \documentclass[tikz]{standalone} \begin{document} \begin{tikzpicture} \pgfmathsetmacro{\xr}{0.35} ...
3
votes
1answer
213 views

Are the line breaks allowed in the PGF 3.0 tree graph nodes?

The node/child layout of the trees allows to break node text into multiple lines. I tried the same with graph but luaLatex compilation never completed (using Texmaker) and I had to stop it, which ...
1
vote
1answer
128 views

Commutative diagram with blank spacing and crossing-layer arrows

Related to a previous post, now pardon me to go to a specific example, here is my output and my Minimum Working Environment ...
1
vote
1answer
447 views

Specifying level 2 style for a tree in Tikz

The idea is to produce the org charts automatically by application code reading a database and calculating the node counts and sizes based on the names of teammates and their hierarchy. After reading ...
13
votes
3answers
5k views

TikZ: xshift not shifting

Why wont xshift work here? \documentclass[tikz]{standalone} \begin{document} \begin{tikzpicture} \coordinate (Q) at (2.1cm, -1cm); \draw[xshift = 0.5cm] (Q) -- +(0, 3cm); % no shift ...
0
votes
1answer
205 views

Node frame in background and node label in foreground

I would like to highlight a text with a node where the node frame would appear in background and where the node label would appear in foreground (the text itself being in the middle of both). For ...
2
votes
1answer
154 views

Tikz' sloped text with refs has non sloped link boxes

I use the sloped option to place slanted nodes along arrows in tikz. Now if that text contains clickable references with the hyperref package, they are not sloped. The text and the link are not ...
12
votes
2answers
432 views

diagonal text in math mode w/ vertical equality

The goal is a code where one can label elements in math mode in the following way: without having to manually position each letter of each word as a node in tikz. Preferably, other than the stacks ...
4
votes
0answers
2k views

Installing pfgornament? [closed]

Note: I have already searched through this site on how to do this but a lot of the things explained make little to no sense to me, I am a novice at this stuff so I was wondering if could get a little ...
5
votes
1answer
549 views

Using scope to move objects using the same coordinate system as the objects themselves

Summary of answers The question has been answered by TorbjørnT. with a comment. If using scope with xshift it is necessary to specify the unit as cm. This is also working if the entire picture ...
5
votes
1answer
636 views

how to include tikz figure in beamer

While copy-pasting the following code from my article to one of the frames in my beamer presentation (along with all the packages), I get 11 errors that are mostly "undefined control sequence" and ...
19
votes
2answers
952 views

Lifted or curved drop shadow

Does anyone know if it is possible to create a "lifted corner" or curved drop shadow effect for a text box? Something similar to this drop shadow effect
9
votes
1answer
373 views

How to get a tangent coordinate system for the decoration of a path?

I want to draw some lines in a tangent coordinate system of the decoration of a path. Especially I want to draw a tangent segment at the end of the decoration with full controll, i.e. with having the ...
3
votes
1answer
331 views

Problem with mdframed, lstlisting and subfig

I'm trying to understand why the following code does not compile. \documentclass[12pt]{article} \usepackage[svgnames]{xcolor} \usepackage{filecontents} \usepackage{tikz} ...
7
votes
1answer
618 views

Drawing SQL tables

I'd like to draw SQL tables, some example content and relations between the id's. Output should be something like below, without the contents. Could you help me with a head start here? Is there any ...
4
votes
0answers
135 views

TikZ: turn a box into a shape [duplicate]

I want to turn a rectangle with ports in the top and bottom into a shape I can use with a node. How can I do this? \documentclass[tikz,14pt,border=10pt]{standalone} %%%< \usepackage{verbatim} ...
4
votes
1answer
319 views

How to make adjustbox work correctly with wrapfigure?

I have an adjustbox environment which gives colored background to content. It doesn't play nicely with wrapfigure. It overlaps with the content. Below is the mew. \documentclass{scrartcl} ...
7
votes
2answers
2k views

How to draw a multiplexer 8 to 1 with circuitikz

How can I draw a multiplexer 8 to 1 with tikz or circuitikz? A hand-drawn example is shown below.
6
votes
1answer
187 views

How to draw curved paths

I'm trying to do this picture : I have a problem to draw the curved paths. MWE \documentclass[scale=0.5,border=12pt]{standalone} \usepackage[utf8]{inputenc} \usepackage{tikz} ...
7
votes
5answers
1k views

How to plot a linear function with axes, arrows, and labels?

I have now spend hours by creating this figure - without luck. I have tried different types of tikz, pstricks and multido usepackages. The lines from a to x_2, d to x_1 and p_1 to c, should be ...
3
votes
1answer
196 views

Displaced circuits with PGF 3.0.0

Please consider the following MWE: \documentclass{article} \usepackage{tikz} \usetikzlibrary{circuits} \usetikzlibrary{circuits.ee.IEC} \begin{document} \begin{center} PGF version: ...
4
votes
1answer
331 views

Double arrow a la chef with two edges shows gap

I am looking for a double arrow that describes a complete 180 degree path. I found a wonderful example, but I have a little issue with one of the edges. \documentclass{article} \usepackage{tikz} ...
5
votes
3answers
508 views

Table of x-y values with first and second order differences

I would like to code a pages of notes that has the layout shown in the picture below. My question is the most efficient way to do this with LaTeX. I would think tikz with lots of nodes and edges, but ...
8
votes
1answer
268 views

Problems to start drawing an energy landscape

I am trying to create a diagram as depicted below. The colors, dotted lines, circles etc are not important. Ideally, the number of plots behind each other should be easily adaptable and the "shape" ...
3
votes
2answers
137 views

Place node above specific path segment

I am trying to put a node above a specific segment of a path that is "bent" using "|-" (kind of broken into segments). A minimal example follows here: \begin{tikzpicture} \node[rectangle,draw] ...
1
vote
2answers
288 views

Control pgf/tikz semilog factor

I'm currently using the semilogy environment and wondering on how to control whether they actually take 10 log or 20 log.
4
votes
1answer
265 views

Stacking plots in animation using fill between library (with dynamic calculation of intersection segments?)

As a followup question to Filling the area under a graph based on intersection with another graph, I'm looking to create the following effect: Fill based on the coordinates of the intersection ...
7
votes
2answers
487 views

Filling the area under a graph based on intersection with another graph

I'm trying to produce this: But I can't get any further than this: This is my code: \documentclass{minimal} \usepackage{pgfplots} \pgfplotsset{compat=newest} \usetikzlibrary{intersections} ...
2
votes
1answer
88 views

Why doesn't `\\` make a newline in TikZ? [duplicate]

This code \tikz \graph [layered layout] { "I want newline after comma:" -> "Hello,\\ World."; }; just gets rid of the whitespace between the "," and the "W" of "World" below: Why doesn't it ...
2
votes
1answer
208 views

Simple animation with tikz and gnuplot won't finish compiling

I got the following code: \documentclass[tikz,border=2pt]{standalone} \usepackage{pgfplots} \usetikzlibrary{calc} \usepackage{animate} \usepackage{fp} \newcommand*\tdist[1]{ \begin{tikzpicture} ...
8
votes
2answers
2k views

Long title in tikzposter

I would like to have a long title in tikzposter and have tried to introduce a newline within the \title{} command using \\ and \newline but it does not start a new line. In the old tikzposter class I ...
3
votes
1answer
201 views

arrows with edges in tikz

I have this tikz figure for my conceputal model. I am trying to have an edged arrow from contextual factors to inputs. Can't figure out how to do it \begin{figure}[h] \centering \begin{tikzpicture} ...
4
votes
2answers
484 views

Tikz for drawing grid-like graph: strange behaviour

I would like to draw a grid-like graph (see the figure below). The following code gives the result shown in the figure. I don't understand why the edges are not vertical. In addition, the commented ...
3
votes
1answer
907 views

Externalize TikZ with TeXstudio and MikTeX [closed]

I have the same problem as written here before, but the externalization doesn't work. I always get the following message: tikz: Sorry, the system call 'pdflatex -halt-on-error -interact I try to ...
7
votes
2answers
494 views

What's the difference between TikZ anchors and coordinates

In his answer to Accessing the logic values of a TikZ coordinate, Jake proposes a code to get the value of TikZ coordinate. Today I've tried to use it to answer Make a polygon with automatically ...
3
votes
1answer
237 views

Global pgfplotset messing up error bars

I have a plot with some error bars generated with this code, but the error bars are messed up. \documentclass{article} \usepackage{pgfplots} \pgfplotsset{compat=newest} \pgfplotsset{ every ...
5
votes
1answer
271 views

`edge quotes mid` TikZ issue

When I render this with LuaLaTex: \documentclass[border=4mm]{standalone} \usepackage{tikz} \usetikzlibrary{graphdrawing,graphs} \usegdlibrary{layered,trees,circular,force} \begin{document} \tikz ...
2
votes
0answers
130 views

How to zoom (and apply grid on) subfigures

So I have folders containing triplets of images which all have the same style as shown in an example below It is basically an automatically generated image and a color-bar besides it. I want to ...
6
votes
3answers
2k views

Make a polygon with automatically labelled nodes according to their coordinates

The goal: Make a polygon (and a circle containing that polygon at the nodes of the polygon, without the polygon's lines) with automatically numbered nodes according to their coordinates (x,y) [which ...
2
votes
1answer
1k views

How to create a timeline with chronosys or something similar?

I need to create a timeline in latex. This is what I have right now \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{chronosys} \begin{document} \startchronology ...
0
votes
2answers
124 views

Missing endgroup in animation

Where is the missing endgroup in the next code ? \documentclass[tikz,margin=5pt]{standalone} \usepackage{calc,animate} \newcommand{\Cercle}[1]{% \begin{tikzpicture}[thick] ...
4
votes
3answers
381 views

Creating Flow Chart with Bezier Curves

How would I use TikZ to make this diagram? I would like to use bezier curves instead of straight lines, too. thanks