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)

1
vote
2answers
26 views

How to center text in a ellipse and to draw circle nodes?

I have spend much time on this figure too and I have tried different types of tikz, pstricks and multido use packages. I would like to create a figure, which look like this: I have wrote following: ...
1
vote
1answer
33 views

How to add text and a more correct zigzag-line to a figure?

I have now spend hours by creating this figure - without luck. I have tried different types of tikz, pstricks and multido usepackages. My biggest problem is to add text, to add a more correct ...
2
votes
0answers
30 views

\pgfmathtruncate rounds result

The following code should generate a 7x7 grid on the quadrangle. However it only generates 3x3 points. All coordinates of the generated points seem to have integer coordinates, so I suspect that the ...
1
vote
0answers
24 views

TikZ error when using `.search also` or `.unknown`

Let me begin with this minimal example: \documentclass{article} \usepackage{tikz} \usetikzlibrary{graphs} \pgfkeys{ /tikz/graphs/feynman graph/.style={ feynman/.cd, base layout ...
0
votes
0answers
40 views

problem with compilation of the solution contain pgfplots package

I try to use this solution from Harish Kumar it's works fine when i'm using sharelatex but it doesn't work for my system here is log Os: windows 7 implementation of TeX: MiKTeX 2.9 Editor: ...
3
votes
1answer
52 views

A big arrow crossing several states in automata with TiKZ

I have six states in an automata drawing: \documentclass{article} \usepackage{tikz} \usetikzlibrary{automata} \begin{document} \begin{tikzpicture}[node distance=5cm,thick,every state/.style={minimum ...
0
votes
1answer
43 views

text break within tikz node

What is the reason that the following code is producing an error with text break (\\) \node (text_1) [draw=none, below=1cm of func, align=left, xshift=1.5cm,yshift=-1cm] { \begingroup ...
4
votes
2answers
93 views

Need to plot a function in coordinate system

I would like to plot a rational function in LaTeX. I tried different ways with Tikz or pgfplots... nothing works. There are many different ways. Often there are problems with poles / asymptotes etc. ...
2
votes
1answer
41 views

pstricks with “colorfunction” in a tikz loop

Trying to make a spiral of vectors (rotating arrow as a function of x-position) I came across tikz for making a proper loop. Concerning other loop solutions I had problems to apply more complicated ...
1
vote
0answers
75 views

Möbius transform Tikz - special request

I would need some picture in Tikz but I don't know how could I achieve them. ( I don't know if exsist some code of it). There is a youtube video which shows the Möbius transforms in two dimension ...
7
votes
2answers
168 views

There is a more compact way for drawing this quarter-car model?

I have written this code: \documentclass[tikz,border=10pt]{standalone} \usepackage{tikz} \begin{document} \pagestyle{empty} \begin{tikzpicture} % Sprung mass \shade[top color=gray, bottom ...
0
votes
2answers
44 views

Draw line to rectangle

I want to connect a node with an edge of a complex shape. I am just able to connect it with the center. I have the following code: \documentclass[tikz]{standalone} \usetikzlibrary{positioning} ...
0
votes
0answers
22 views

Can we get references to pgfplots to work with arXiv?

I have some plots created with TikZ and pgfplots. In the captions, I use \ref{...} with plot labels in order to get the marker printed there; a neat feature indeed. Now, when submitting to arXiv one ...
0
votes
0answers
23 views

Position of `groupplot` Titles in TiKz

Can I customize the position of the titles in tikz groupplots? In the following example, I would like to place the titles (a, b, c, and d) inside the axis (near the upper-left corner). ...
0
votes
0answers
20 views

Change font type in tikztimingtable without displacing signals

I decided to play a little bit with the tikztimingtable, however I'm not sure that I "like" the font used in the signal labels So I tried to change it by adding a [font=\rmfamily] in front of the ...
1
vote
0answers
38 views

Tikz: Rational Functions (Hyperbola)

I am aware of similar questions, but as they don't exactly use the same syntax as I am trying to do, I can't see what's different between my way of writing functions down and the others. Here's what ...
0
votes
0answers
27 views

colour options in tikz are good on dvi and ps but not so good in pdflatex and printing

I use tikz to produce graphics and then have some shading parts in black, gray. The graphics look good on DVI and PS and the printing is also good from these files. But when I use pdflatex, the shaded ...
1
vote
1answer
35 views

Group plot: Replacing the values (labels) on x-axis

I'd like to replace numerical labels (e.g., 1,2,3,4,5) on x-axis with names (e.g., A,B,C,D,E) in a group plot environment on a case-by-case basis. The group plot environment seems to easily support ...
3
votes
3answers
74 views

pgfplot fill one bin with color

I am using pgfplot to draw a ybar graph. It can fill color for full graphic but I wish to only fill one bin with red color. e.g. fill bin 3 with red. Current code fill all bins with red color as ...
2
votes
2answers
65 views

Adding text above a node in Tikzpicture tree diagram

I'm trying to add text above the lines coming from a chance node in a Tikzpicture decision tree. It seems easy to add text at the end of a line, or above the parent node's lines, but I can't figure ...
0
votes
0answers
23 views

Tikz-uml create nesting relation

I am using tikz-uml, but it seems there is not UML nesting relationship. I am not very good with tikz could you help me how I can implement it. You can see how it should look here at the end under ...
10
votes
2answers
148 views

Fill in between polar curves

I am trying to fill in space between a pair of spiral curves in tikz. I have tried using the fillbetween library but it just shades in the whole spiral. Does anyone have a hint they could offer? ...
4
votes
1answer
58 views

tikz overlay pictures horizontal positioning

I think I have a problem about how the box created by tikzpicture is positioned with respect the rest of the text. I have read Positioning TikZ pictures and I think I have understood how the vertical ...
0
votes
0answers
12 views

pgfmathsetmacro increases border size [duplicate]

Upon creating some graphs with TikZ, I noticed that the border at one side was much larger than it needed to be. The cause seems to be the \pgfmathsetmacro command: \documentclass{standalone} ...
2
votes
1answer
31 views

How to use Umlauts (äüö) in axis label with knitr, LuaTex and tikz?

When compiling pdf documents with complex tikz figures using knitr, the pdftex engine would sometimes run out of memory. Thus, I used the luatex engine to compile these Rnw files. However, I am not ...
0
votes
0answers
25 views

Different row separator for multiple rows in tikz dependency

I want row space for the four rows differently in the below mentioned example. For example 1ex for first 2 rows, 4ex for 2 and 3 rows and 1ex for last 2 rows. Setting row sep gives equal spacing for ...
2
votes
1answer
40 views

drawing snake decoration in a box tikz

I am trying to draw some snake decorations in a box using tikz library but couldn't achieve what I want. Why there is mis-alignment between the actual markings and the snakes. I am using the following ...
3
votes
2answers
71 views

add vertical line of equation x=2 and shade a region in graph by pgfplots

I would like to plot these four equations : $$y=\dfrac{3}{2x+1}, y=3x-2, x=2 y=0$$ and i don't know how to draw vertical line of equation x=2 and shade a region like the picture below ...
1
vote
1answer
28 views

Set node distance between borders in tikz

From \documentclass[tikz,border=10pt]{standalone} \usetikzlibrary{shapes,arrows,positioning} \begin{document} \tikzstyle{block} = [draw, rectangle, minimum height=3em, minimum width=6em] ...
2
votes
1answer
51 views

add a little arrow at the end of a function

I have the following code of a segment of tikz: \begin{tikzpicture}[line cap=round,line join=round,>=triangle 45,x=3cm,y=2cm] \draw[->,color=black] (-0.9,0.) -- (1.9,0.); ...
2
votes
1answer
49 views

how to achieve and draw the final rotation of a frame with Euler angles.

I would like to do the final rotation using Euler angles. In this link Euler Angles, the final rotation undergoes three successive rotations, starting from frame (x,y,z), going through (x',y',z') and ...
1
vote
0answers
43 views

Package TikZ Error: Problem Compiling in Ubuntu

I get the following error Package tikz Error: Giving up on this path. Did you forget a semicolon?. when compiling this TikZ code: \documentclass{standalone} \usepackage{tikz} \begin{document} ...
0
votes
1answer
84 views

Adding a rectangular box with tikz to table (beamer)

I would like to add a rectangular box to my table to highlight some rows. I'm trying to use tikz with the second lot of code from Harish Kumar's answer to a similar question. However, unlike the ...
1
vote
1answer
40 views

Aligning edge labels horizontally with tikz package

I have the following figure: \documentclass{standalone} \usepackage{tikz} \usepackage{pgfplots} \usepackage[active,float]{preview} \usetikzlibrary{calc} ...
0
votes
0answers
50 views

Commutative diagram with tikz [on hold]

I write \usepackage{tikz} \usetikzlibrary{matrix,arrows,decorations.pathmorphing} but this gives the error Environment tickzcd undefined.
1
vote
2answers
65 views

Plotting Floating point number when changes are very small in data

I want to plot the following data, i am using the CSV file, and pgfplotstable package. (0,2.42130785530195E-02), (113.8,2.42130785530195E-02), (227.6,2.42130781357695E-02), ...
1
vote
1answer
38 views

Naming Externalized Images via MD5 Sum

I have a large presentation with over 200 figures (mainly created through stepping through each image). I'm using the external library to cache the results to great effect. Each figure is cached in ...
2
votes
3answers
213 views

Using loops with chains?

Is there a smarter way to achieve the same result as the one from the following MWE: 1) by using some kind of loop instead of hand typing every node, 2) by drawing the arrows with tikz instead of ...
2
votes
0answers
46 views

Tikz axis border on top, grids below

Is there an easy way to place the border box of a tikz graph on top, while keeping the grid lines behind data lines? \begin{axis}[axis on top] The above puts the border, x grid lines, and y grid ...
1
vote
2answers
39 views

Remove clk signal from wave environment

How do I remove the clk signal in the wave environment? I still want to keep alle the help lines (i.e. the t0, t1, etc.) Here's the code: \documentclass[11pt]{minimal} \usepackage{tikz} ...
3
votes
1answer
50 views

Centering group plot figure

Can anyone show me how to center this group plot? I've tried every trick in the tex.stackexchange book of similar posts (e.g., How to center large figures in LaTeX and how to fix short justified ...
1
vote
2answers
134 views

How to draw some targets like this?

I would like to show some stimators properties in statistics. I'm very beginner in LaTeX, so I need some help.
4
votes
3answers
146 views

Shading inside a triangle when the coordinates of one vertex are calculated by TikZ

The following code instructs TikZ to draw a right triangle and to put a grid on the Cartesian plane. I would like to make two modifications to it. I want the inside of the triangle to be "colored" ...
0
votes
0answers
69 views

Simple beam deflection tikz

I'm beginner user of Tikz, so can somebody help me to draw this? I would be very thankful.
0
votes
0answers
37 views

Error by creating normal distribution in tikz

Hello I wanna create a Normal distributed figure. with sigma = 10 and mu =185; I have the following code based on Bi-variate Normal distribution \usepackage{tikz} \usepackage{pgfplots} ...
0
votes
0answers
30 views

TikZ and other figures in documents meant for multiple paper sizes

Sometimes scientific papers are sent to multiple journals with very varying paper sizes. Usually, changing from one to another, I simply cross my fingers that TikZ figures still fit, and rescale PDF ...
1
vote
0answers
34 views

\pic: undefined control sequence

I am using Texmaker on Macbook but I have a problem with my code. When I run my code it always shows this message: "undefined control sequence \pic". \documentclass{article} \usepackage{tikz} ...
3
votes
2answers
54 views

Placing nodes which vary in length harmoniously

The code \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture}[font=\footnotesize, very thick] \def\r{3} \foreach \a/\n in {-2/{p-2}, -1/{p-1}, 0/0, 1/1, 2/2, 3/3, 4/4} ...
3
votes
2answers
114 views

plotting a function with smooth curves

I am trying to plot the following function The issue is I do not know what is the best setting for the coordinates. I tried different coordinates with no success. Here is my code: ...
2
votes
1answer
45 views

tikz/pgf upgrade and decorations

Since a major upgrade in pgf, my code does not compile any more. I am trying to make "decorated" source listing, where the decorations can be like highlighting some lines (see the MWE), balls on some ...