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)

5
votes
1answer
771 views

How to draw a bow-tie risk diagram

I'd like to draw some bow-tie diagrams, which are diagrams for modelling risk, particularly for businesses like oil and gas and transport. In the centre, there is a "top event", and there are zero or ...
3
votes
1answer
268 views

Bad label placing in kiviat diagram

Shouldn't resizebox should resize the label along with the whole picture? How can I avoid the label put above the arrow? (Other than rotating the image, which I don't want to do.) ...
2
votes
2answers
2k views

barchart in pgfplots looks really bad

Problems: The bar value "90" is written over a black line, almost impossible to read The value "58" is written over an x tick, hard to ready Bar spacing is bad. There is too much space between the ...
7
votes
1answer
927 views

callout with multiple pointers

With tikz is there any way of having a callout shape that points to more than one place? I would like to use a callout shape to explain some parts of a graph. This callout shape would point to ...
31
votes
3answers
1k views

How to pimp my tube?

How can I pimp my tube? \documentclass{scrartcl} % needs logicpuzzle bundle v1.8 % http://mirrors.ctan.org/graphics/pgf/contrib/logicpuzzle/logicpuzzle.sty % or replace logicpuzzle -> battleship ...
1
vote
2answers
465 views

draw a DAG with transition labels

I appreciate it if you let me know the most elegant way to draw a DAG such as the followings:
5
votes
2answers
154 views

Can't generate a tikz matrix, using expl3

Suppose, I want to generate a matrix of nodes: \documentclass{article} \usepackage{expl3} \usepackage{tikz} \usetikzlibrary{positioning} \begin{document} \begin{tikzpicture} \matrix [ row ...
2
votes
2answers
2k views

Sketch sinusoidal wave in Tikz

What is the easiest way to sketch a sinusoidal wave in PGF/Tikz? I have tried this: \begin{tikzpicture} \draw[loosely dotted] (0,0) grid (4,2); \draw[x=0.5cm,y=1cm, ultra thick, red] (0,1) ...
2
votes
2answers
885 views

How to draw spherical using 3dplot

I would like do draw some sphericals using the package 3dplot. Does anybody know how to draw spericals with different diameter and postition in a coordinate system like that one? ...
2
votes
0answers
113 views

Plot doesn't care about axis setting [closed]

I have a Pgfplot and for some reason it does not care about my y-axis settings... I have set ymax to 15 but for some reason it only goes up to ymax is 14 or something... Can anyone explain why? And ...
6
votes
2answers
2k views

LaTeX (TikZ) image centering

I have a problem with the horizontal alignment of an image. I have compiled the image from the matlab extension and added it to my LaTeX file with the following code: \begin{figure}[H] \centering ...
7
votes
2answers
1k views

How to position multiple decorations on a path while keeping their separation constant?

The at position=<value> syntax for decorations obviously makes the positioning of the decorations dependent on the path length: \documentclass{article} \usepackage{tikz} ...
6
votes
1answer
3k views

Tikz Paths in Automata

I'm trying to draw an automata in LaTeX with TikZ, but I don't know how to make a long transition between two states. I need a sized label to be placed on it. \documentclass{article} ...
6
votes
2answers
206 views

Novice's question: I don't want other objects' locations to move when I add a circle

TikZ novice, here. I want to create two slides (in Beamer), identical except for the addition of a circle in the second slide. I don't want the addition of the circle to shift about the placement of ...
8
votes
1answer
2k views

TikZ: Superimpose text over arrow

I am trying to superimpose some text over an arrow with TikZ. I know it is possible to have the text over the arrow but this is not what I am trying to achieve. What I have done so far is: ...
3
votes
1answer
214 views

Multiple shapes on edges of automaton

Anybody who knows how to add multiple objects to edge of automaton? I tried label, but I can add only one label. I need to draw streett automaton, like in this picture:
2
votes
1answer
542 views

Intersecting planes not shown correctly with TikZ

I made a plot in MATLAB of a deformed and an undeformed model. I converted the figure to TikZ using matlab2tikz and added it to my .tex file. I then noticed that the two configurations, which are ...
3
votes
1answer
132 views

Stretching each cell to the same height

I'm building a TikZ diagram in a row-by-row fashion. Each row is composed of a sequence of blobs, and the end of the row is signalled by issuing \newrow. Here is the code I have produced so far: ...
4
votes
1answer
164 views

Why does \centering have no effect in my code?

It seems that when I use the \centering command to center a TikZ picture within a Beamer frame, it only works if there is a blank line between the \end{tikzpicture} and \end{frame}. Can someone ...
9
votes
1answer
660 views

how to draw two connected rectangles

How can I draw two rectangles (or two shapes in general) so that they touch each other. Below is the minimum working example. \documentclass{standalone} \usepackage{tikz} ...
4
votes
1answer
2k views

Different xstep and ystep in TikZ with to[path] (precisely to[grid with coordinates])

As it's my first question, I want to say hello first! I am using [grid with coordinates] code from Andrew Stacey answer (link) for How can I show coordinates by grid in TikZ automatically?. I ...
4
votes
1answer
2k views

Circular drop shadow example

Sorry for such an elementary question, but all the examples I could find in search were too complicated. I'm trying to recreate a circular drop shadow example from the pgf manual. What packages are ...
1
vote
1answer
162 views

adding complexity to a hyperbolic trajectory

Jubobs generated this code from Drawing a hyperbolic trajectory. If we draw a horizontal line that intersects the hyperbola (I really dont want to add this to the picture), we would have some angle. ...
5
votes
2answers
1k views

anchor arrow start position

Attached below is the minimum working example. I would like the arrow to end at the west anchor of the node "operation". I tried anchor and few other possibilities but they don't seem to affect the ...
6
votes
3answers
352 views

How can I calculate the length of the longest word in a node?

I would like to create an inline brace command \inline{} for xelatex using TikZ. The difficult part is calculating the text width for the node without hardcoding it into the tikzpicture environment. ...
1
vote
1answer
449 views

How do I put arrows inside circle in tikz?

I need your help in creating the following figure in tikz. I am absolute beginner in tikz. I saw the example in the following page, but I need it the way as shown in the picture which I could not ...
1
vote
0answers
481 views

Problem with “semilogyaxis” in TikZ [closed]

I've some trouble using the following code. I'm using MiKTeX 2.9 x64 with (in this case) QTikZ and got this code by the matlab2tikz function, and the following example simply just don't work in QTikZ. ...
1
vote
1answer
516 views

Comic strip in TeX

I am creating figures using Stykz. Every frame (should have customisable resolution) consists of stick figure 2 or more text boxes Frame outline (will be best if looks handdrawn) I want to fit ...
5
votes
1answer
310 views

Pass a 3d coordinate via pgfkeys

I'm using 3dplot to draw in 3D. Now I want to define my own environment, called pose, that is supposed to be used inside a tikzpicture-environment. It should perform a coordinate system tansformation ...
3
votes
2answers
1k views

Direction arrows on a circle [duplicate]

I would like to plot circle (or another curve) with positive direction (and show it wit arrows). This plots the circle \documentclass{article} \usepackage{tikz} \RequirePackage{pgfplots} ...
3
votes
1answer
700 views

Drawing a hyperbolic trajectory

In Drawing the Celestial Sphere with Tikz Package, they use pspicture. Is there a way to use pspicture inside of tikz? I want to have a hyberbola pass by the Earth with a periapsis of 500km (scaled ...
4
votes
2answers
1k views

Drawing a hyperbola of a certain eccentricity in TikZ

This question is a follow-up question to half of a hyperbola. When constructing a hyperbola in TikZ, how can I specify the eccentricity to be 1.44022?
8
votes
2answers
687 views

half of a hyperbola

Only top portion of half my hyperbola is coming in correctly. The other half is doing something strange: \documentclass{article} \usepackage{tikz, pgf} \begin{document} \begin{center} ...
2
votes
1answer
423 views

how to add new page (page break) to article

This is my code, I am learning how to use the TikZ package and am trying to put different examples on different pages. I would like to have a page break between lines 22 & 24 if at all possible. ...
21
votes
3answers
3k views

Projection of Circle onto Spherical Surface

I want to draw shapes looks like 15 degrees tilted-semi-sphere and there are circles, placed in a triangular shaped array, on the base area. Then these circles are projected onto surface of sphere. ...
4
votes
0answers
462 views

Is fine-grained grid control possible? [closed]

I want to make a variety of checklists which are essentially based on a grid layout. I care about having fine-grained control over the exact placement of labels and boxes. I do not care about ...
5
votes
1answer
387 views

Align TikZ grid with geometry crop marks

I am drawing a grid on top of the layout defined with geometry. \documentclass[letter]{article} \usepackage{geometry} \geometry{ showcrop, paper = a4paper, layout = a5paper, ...
1
vote
0answers
325 views

Plot a range/subset of coordinates in Tikz [closed]

SOLVED: How would you plot subset of a function in Tikz: In Syntax for smoothing a coordinate plot with the foreach command \documentclass{article} \usepackage{tikz} ...
8
votes
1answer
477 views

TIKZ drawing Gaussian Blur

I am a complete newbie to latex and have been working on thesis. At the moment, I am trying to draw this and have no idea how to start. I did some google and found out that tikz is very popular for ...
24
votes
2answers
5k views

How can I make a standard timeline?

I am looking to make a standard timeline, nothing fancy, like the one below (although, it does not have to be like that) using any library. How can I go about the achieving this in the best way?
3
votes
0answers
198 views

pgfplots — Patterns are not displaying correctly in PDF version 1.4 [closed]

I am using this method to plot a pattern in-between two curves. If I save the file as PDF version 1.5 everything looks great. Unfortunately the journal that I am submitting the paper to requires PDF ...
4
votes
1answer
999 views

drawing a circle in the xy plane when using 3d coordinates

I am trying to make a circle in the xy plane that has walls that slope up. How can I do this? Basically a bucket with a bigger opening then base. \documentclass{article} \usepackage{tikz, ...
1
vote
1answer
73 views

What syntax and parameter placement allows me to specify the radius of this circle inside tikz-pgf?

\begin{tikzpicture}[overlay,remember picture] \path node [draw, circle, inner sep = 0] at (current page.center) {Test circle\ldots}; \end{tikzpicture} I have this circle and want to specify it's ...
8
votes
1answer
1k views

Square edges in forest package

I can easily do trees with horizontal (square) edges in tikz-qtree (see MWE). The forest package is however a far superior alternative for my purposes. However, every attempt to do either horizontal ...
6
votes
3answers
329 views

\newcommand and boolean statements

I'm getting better at creating \newcommand instances but I've just reached a part where my knowledge is just not enough for it and also reading this site or the manual doesn't help. Basically I'd ...
14
votes
5answers
1k views

How to draw this pyramid with TeX?

I draw this pyramid with GeoSpacw. How to draw this figure with TeX? Where: $M$ is midpoint of the segment $SA$; $I$ is midpoint of the segment $SD$; $H$ is project of the point $A$ on the line ...
4
votes
1answer
195 views

Good-looking luminosity function plot

I'm trying to make a good-looking photopic luminosity function plot. So I want to make colored plot, but its colormap should depend on X values. Is it possible with pgfplots? I'll also appreciate any ...
4
votes
1answer
123 views

Exposing a new command for each element of a list

I have a macro lVars, defined using foreach from the pgffor package (part of PGF) as: \newcommand{\lVars}[1]{\foreach \x [count=\ii] in {#1}{ \ifnum\ii=1{} \else {,} \fi \lVar[\x]} } The intended ...
7
votes
1answer
282 views

Using TikZ to depict pitchlevel

After the very productive outcome of my recent question on intonation, I'm emboldened to ask a related question. In the previous one, particular pitchlevels are connected to produce an intonation ...
3
votes
0answers
75 views

Placing a node on top of lines in TikZ [duplicate]

I'm using TikZ to draw a polytope/simplicial complex and I'd like to label the vertices with their names (which are numbers). However, in the picture below, the node seems to be placed behind the ...