Tagged Questions

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)

6
votes
1answer
76 views

TikZ - Compute the array being the min of 2 arrays

I define 2 arrays r and p and draw them. I would like now to compute the min of r and p in order to draw it in a similar way. The resulting array would be {0.2, 0.4, 0.8, 0.8, 0.4, 0.0, 0.1, 0.0, 0.1 ...
4
votes
1answer
59 views

Beamer uncover decoration bug

\documentclass{beamer} \usepackage[utf8]{inputenc} \usepackage{pgf,tikz} \usepackage{tikz} \begin{document} \frame{ \usetikzlibrary{decorations.pathmorphing} \tikzstyle{kringel}=[decoration={random ...
2
votes
3answers
139 views

Tikz Node with rounded corners

I refer to this question: LaTeX Photo With Rounded Corners I would like to round the corners of a Tikz node (which actually is a fitted node around two other nodes), but would like to have an ...
1
vote
1answer
60 views

Tikz pattern areas become black when printing

I'm afraid this question has been asked before, but I couldn't find it. When I have an element in a tikzpicture environment that has a hatched filling, the filling becomes black when printing. ...
0
votes
0answers
68 views

Tikz code for spheres

I would like to draw the following shown in the link: I only know how to draw the spheres (I have stored some guidelines on a paper on my pc) but not like this. This is way too much for me. Any ...
2
votes
1answer
84 views

rotation problem text in arrow tikz

I'm trying to make a graphic that needs two arrows, I've already found how to rotate the arrow, but I don't want the text to be rotated 180 degrees. Bonusproblem, I want the red line ticker ... ...
1
vote
1answer
71 views

Drawing a single line of cache memory

I'm trying to draw what a single address line of cache memory would look like. I want to draw just one line of the diagram (one index): How would I generate this using TikZ?
3
votes
1answer
57 views

\draw not working inside axis environment

Judging from the pgfplots manual I expected the following code to work: \documentclass{article} \usepackage{pgfplots} \begin{document} \begin{figure} \begin{tikzpicture} \begin{axis}[ ...
2
votes
0answers
33 views

Verbatim and Bacground&TikZ compatibility problems

If to compile below MWE, you'll get next error: According the error message, the problem is tikz and calc library package, which looks like links with background package. Also, you will not find ...
3
votes
1answer
84 views

tikz arc with arrow

I am drawing the coordinate system using tikz and I intended to use arrow for the arcs \phi and \theta. But when I use -> in the arc options (resulting a proper arc), inside the graph remains an ...
-1
votes
1answer
82 views

I need help to build a tikzpicture of the covering of S^1

I want to make a picture the looks like the picture in this video, if you pause it at 42 seconds. https://www.youtube.com/watch?v=vP7NAeeKjrw If anyone could help, I would really appreciate it! ...
4
votes
2answers
73 views

xtick/ytick and \draw not agreeing on the scale used

I would like to draw an ellipsis with x radius 2 and y radius 1, inside a tikzpicture with a pgfplot. This is my attempt: \documentclass{article} \usepackage{tikz} \usepackage{pgfplots} ...
6
votes
2answers
114 views

phases (stages) of economic cycle

I would like to make the following figure: My already code is: \documentclass{standalone} \usepackage[english, greek]{babel} \usepackage{ucs} \usepackage[utf8x]{inputenc} ...
3
votes
0answers
90 views

tikz stops drawing into pdf after 20 line segments in plot generated through knitr tikzDevice

Problem If I try to draw a curve generated through knitr using tikzDevice into .pdf only 20 line segments of that curve are drawn and TeXstudio, through which I do it, just leaves message running ...
2
votes
1answer
49 views

Tikz node command changes (0,0) position?

I am trying to preapare a poster with a0poster. I wrote: \noindent\begin{tikzpicture} \fill[DarkOrange,rounded corners=20pt] (0,0.5) rectangle (\linewidth,5); % \node (myfirstpic) at (0,0) ...
2
votes
1answer
65 views

beamer: How to get tikz spy overlay on top of the other content of a frame

The problem is as follows: On a slide, I have several figures. I would like to zoom into whole figures or parts of them susequently. I tried to do so using tikz spy library with the spy using ...
3
votes
1answer
44 views

Expansion for Macro to pass to scaleBox

I am trying to calculate some width in a macro and use the macro for scalebox. However I get a flood of errors when I try to pass the macro to scalebox. MinimalExample: \documentclass{article} ...
4
votes
2answers
80 views

How to draw a single commutative diagram with double-ended arrow?

I would like to draw a very single commutative diagram, I look for some basic examples to modify but did not found one that uses an arrow towards the left and the right (<--->): , if I write ...
3
votes
1answer
107 views

Pyramid Commutative Diagram for Cones

In the second edition of Awodey's Category Theory he suggests visualizing a cone as a many sided pyramid. I'd much like to make the proper commutative diagrams, but I don't know how to make a many ...
1
vote
1answer
59 views

Tikz circuit - Coordinates of terminals of components

I am drawing a schematic and I would like to specify the particular coordinates of terminals of the components. For instance, in my drawing (source below), I would like the 'X' dot to be at the same ...
14
votes
3answers
535 views

How to bend a curve above text with TikZ?

I want to connect to "positions" of text with a curved upwards arrow. So far I have done this (trivially following the TikZ manual): \documentclass[a4paper,12pt]{book} \usepackage{tikz} ...
16
votes
2answers
258 views

How to make a longitudinal sine wave shading with pgfplots?

At the moment I use TikZ shadings to show up longitudinal waves in my document like this: The shading is white where the sine is –1 and blue where the sine equals 1. This looks ok, but ...
3
votes
1answer
51 views

Position tikzpictures side by side

I have the following tikzpictures, and I would like to present them in two columns. However, no matter what I try, whether it be multicol or minipage or subcaption, they stubbornly stay in one column. ...
3
votes
1answer
39 views

TikZ framebox (simple box + text inside)

I am beginning with TikZ. How to do the simplest square of defined position, width&height, eventually color with text inside please ? I used before the command framebox, but I don't have the same ...
3
votes
1answer
55 views

PGFplots: Can I do vector addition/substraction?

I'd like, in the following MWE, to draw a vector from P to P+v and to P-v for some given point P and directional vector v in the axis coordinate system of a pgfplot. Can it be done? ...
4
votes
2answers
63 views

Incomplete path fading “gradient range” in short pathes

I would like to draw a (very thick) line that is faded on one end. My idea was to draw the line, extend it, and apply path fading only to the extended part. For short extensions the fading seems not ...
3
votes
1answer
68 views

TikZ and tikzorbital: problem with background

It looks like tikzorbital package is not compatible with background library of basic TikZ. As you see in the picture below, just p_y displayed (do not pay attention to notations in MWE). It displays ...
1
vote
1answer
86 views

Opinions: Circuit_macros or circuitikz ? what is better? [closed]

I'd gladly read your opinions on Circuit_macros pros and cons, as well as yours on circuitikz. Gives the macro more variables to play with? Is the circuitikz language easier? Macro use seems far more ...
4
votes
2answers
108 views

Is there an easy way to have node border anchors centered on the borders?

I would like to place nodes with given distances relative to each other. For consistence with other drawings these distances have to be very accurate. Node border anchors are placed at the outer ...
1
vote
1answer
59 views

auto adjust node position in a binary tree

I'm trying to draw a binary tree using tikz. I use shift option to define the relative position of child nodes. But as the tree grows, the nodes start to overlap if I use a fixed shift. I'm able to ...
3
votes
0answers
56 views

PGFPlots only have one 0 at the origin

When I create a figure using tikzpicture, tikz adds two 0's at the origin for a plot (one for the x-axis and another for the y-axis). I think it looks cleaner to only have one zero at the origin. I ...
3
votes
0answers
101 views

How to draw the vectors from point to point

I have the file "gradmethod.dat" that contains the values ​​of the 3D coordinates: "gradmethod.dat" is 0.4166337995 -0.0003214561 0.1735863062 0.0036860331 0.0076438475 0.0014742969 ...
7
votes
3answers
121 views

Single arrow node with fixed, text-independent dimensions

I would like to have several single arrow nodes all with the same dimensions (independent of the node text). I tried to achieve this by setting minimum width, minimum height, inner sep, and single ...
0
votes
1answer
58 views

Chapter Title in box at the margin with different rounded corners

The title combines two discussion threads on this board. Chapter Title in rotated vertical box at the margin TikZ rectangular node with different rounded corners I have adapted the first solution ...
4
votes
2answers
165 views

Tikz: Proper Alignment of Nodes and Text in this diagram

I want to refine the following diagram. I want to left allign the text showing on the left of this diagram and need straight paths. Any help will be highly appreciated. Thanks ...
0
votes
1answer
76 views

smooth curved arrow in flowchart

I am new to latex with a very little idea in tikzpicture or pgfplots, so you know what would happen... Please help me with the following flowchart-type diagram. Here the cartesian plot is a regular X ...
2
votes
1answer
55 views

Revert to scale=1

I often write procedures that I call from my main draw procedure. I would like my procedures be independent of the scale of the tikz picture from which it was called. In example below I would like ...
0
votes
0answers
61 views

How do I add a “less than” symbol in the flowchart?

This the edge drawing command using the tikz package. I want to display, Blinks < 3 in the line. \path [line] (L) -- node {Blinks 3}(N); Melons!
5
votes
2answers
106 views

Strange behaviour with pstricks/TikZ/center

I'm working on a long document (written by someone else). The author has used a lot of pstricks pictures, and I'd like to compile the document using pdflatex (without doing the detour over dvi). The ...
5
votes
1answer
129 views

Lualatex capacity exceeded with Gb's of free RAM

I'm trying to compile dense graphs generated my matlab2tikz (file size ~ 50Mb). I'm running lualatex and externalising with lualatex \tikzset{external/system call={lualatex ...
6
votes
1answer
104 views

TikZ zero-width line with dashed line

When drawing a dashed line, it seems that TikZ inserts a zero-width line that is visible on some (e.g., Acrobat, Sumatra) but not all (e.g., Evince, Chromium browser) PDF viewers. From the PDF 1.7 ...
1
vote
1answer
40 views

Background package - \NoBgThispage different output

This question related with my oter two questions: Replacing \fancyhdr with \titlesec in complicated design documents White fields in ltjsarticle class The design, which has been reached in these ...
2
votes
1answer
43 views

Label faceted surf in pgfplots

I have a series of X,Y,Z points and like to create a discrete surf plot and label each point. I am using \addplot3[surf...] to generate the plot but I can't figure out how to label the colors. I don' ...
2
votes
2answers
80 views

Tikz: connect two nodes

I have many nodes and want to connect two of them, but in such way that the path is not scratch off nodes, which are between these two like in the example below (I want to connect L_0 and R_0): To ...
2
votes
2answers
52 views

Shorten an edge between nodes to abolut length

How can I draw only a part of an edge/arrow (of a defined absolut length) between nodes; something like the following but shorten always has to be adapted to the distance between A and B what is ...
2
votes
1answer
61 views

Tikz how to draw a conditional iterative statement

I'd like to draw the figure below with Tikz. So far, my code looks like this : \begin{tikzpicture}[node distance=2cm] % styles \tikzstyle{startstop} = [rectangle, rounded corners, minimum ...
4
votes
1answer
63 views

Setting \tikzstyle inside \foreach

I am building a tree structure in tikz and am following this texample, which suggests adding styles for the children according to their depth in the tree (first, second and so on). The purpose is that ...
1
vote
0answers
43 views

How can I fill intersection of two (three) sets like this pictures? [duplicate]

I want to fill intersection of two (three) sets like this pictures, but I can't do that. How can I do that?
2
votes
1answer
57 views

Special characters and math-mode in tikz graphics using knitr

This question closely relates to this one: Using '$' in a tikz plot generated by knitr I am able to get tikz graphics using knitr working with either math mode as in this post: Math mode in ...
1
vote
0answers
32 views

tikz externalize itself is slow

I am following the instructions for externalization and makefiles. I'm using a macbook air with 4Gb of RAM. I find that the step involving the parallel make is extremely slow and uses a lot of RAM, ...