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)

0
votes
1answer
53 views

Externalize Tikz Figures with Latex

I want to use the externalize option for tikz pictures to save up compilation time. Because of the need for psfrag, I want to compile via latex, i.e. dvi-->ps-->pdf. I use texStudio. My Latex specs ...
7
votes
6answers
921 views

How to draw a triangle is insribed in a circle so that the vertices divide the circle into three arcs of lengths 3, 4 and 5?

I want to draw a triangle circle is insribed in a circle so that the vertices divide the circle into three arcs of lengths 3, 4 and 5. I tried with Geogebra. \documentclass[12pt]{standalone} ...
1
vote
0answers
38 views

tikz label over path flips!

I'm trying to come up with a nice schematic of recursive calls using tikz, but the result is not what I expect as one label is flipped without a reason: The MWE is: ...
4
votes
1answer
39 views

TikZ: Move points towards center

I want to move a set of points towards the center of my figure, but I want the distance to depend inversely on the relative distance to the center. Thus, for instance move a point at (-2,-3) to ( -2 - ...
6
votes
4answers
155 views

How to use Tikz and macros to very efficiently draw recombining binomial trees when taking notes during class

For a class in derivatives pricing I would like to find a way to quickly and efficiently draw recombining binomial trees. The class involved quite a few of those trees and it would be immensely ...
3
votes
1answer
37 views

Changing global settings for makers doesn't work in pgfplots

Often I have documents where I need plots without makers. In this case I set globally a \pgfplotsset{ no markers } However if I have some special plots in the file which require (only) ...
0
votes
0answers
43 views

Plot the sum of two inverse normal CDFs in three dimensions

I am interested in plotting the sum of two inverse cumulative normal distributions in pgfplots but I am not quite sure how this can be done. Could you please lend me a helping hand here? Thank you in ...
1
vote
1answer
74 views

Text on rectangular spiral with automatic sizing to fill page

I'm wondering how this could be done in TeX: This is along the lines of Text spirals with TikZ but in a rectangle, with all text the same size, and all text should be at right angles (unlike the ...
7
votes
1answer
158 views

Draw acos(1/x) in tikz

I'd like to draw the graph of y=acos(1/x) using TIKZ. I don't want pgfplot nor do I want pstricks. I want to do it strictly in TIKZ. Here is my attempt. I want to eventually draw on the domain [1,4], ...
3
votes
1answer
60 views

How to plot the maximum and the minimum

I am interested in drawing the minimum and the maximum of two variables, i.e. min(x,y) or max(x,y). The way I was going about doing it so far was to get the contour plots using gnuplot but my attempts ...
3
votes
1answer
50 views

tikz circle with number change vertical space between lines

Arg, i try to replicate the diverse answers using tikz i read into this post and in this post, without success, my circle explode the space between lines. Don't understand why the result is ...
9
votes
3answers
186 views

Tikz Edge: Distance from other nodes?

I have the following Tikz code: \usetikzlibrary{positioning} \begin{tikzpicture} \tikzstyle{bordered} = [draw,thick,inner sep=5,minimum size=10,minimum width=100,font=\sffamily] ...
2
votes
1answer
46 views

Default tikz arrow style in pgfplots

I'm trying to change the axis arrow style used in pgfplotsto the default one obtained in tikzusing ->, i. e. I've done some research but can't seem to find a way to do that.
1
vote
1answer
49 views

Nested mdframed

How to change the theo environment in that way, that a inner mdframed will not inherit the style of theo? \documentclass[parskip=false,english,11pt]{ltxmdf} \usepackage{mathtools} ...
3
votes
2answers
53 views

Draw line vertically centred in line of text

I'm trying to draw a line within a line of regular text using tikz, essentially something like: Some text that is followed by a line --- Some more text. So far I have \tikz \draw (0cm,0.5cm) ...
2
votes
1answer
60 views

Writing the size of a Tikz node to a file

I write a program that typesets elements in a Tikz picture. In general the items are not placed correctly. In order to solve this, I was thinking of running a two-stage compiler: the first time the ...
6
votes
1answer
58 views

Croping Tikz animation out of a beamer presentation (producing empty pages)

I've a beamer presentation and want to use the tikz pirctures inside rendered as svgs. So far no problem, but compiling the code via pdflatex the following (minimal) example results in four pages, ...
3
votes
2answers
103 views

Vertically stacked group plot with different horizontal scaling

I've 4 data sets that I'd like to present as a stack using pgfplots' groupplot library. What I'm struggling with is that the first data set has a larger horizontal range to the remaining three. I'd ...
9
votes
2answers
166 views

Light object / source in PGF / TikZ / PGFplots pictures like in PSTricks

I came across the PSTricks animation located at http://melusine.eu.org/syracuse/pstricks/pst-solides3d/animations/a43/ http://i.stack.imgur.com/NlqHZ.gif and noticed that it uses a light object / ...
2
votes
0answers
59 views

How to place two plots inside a node?

I'm eager to have two plots (of the algebraic functions) placed horizontally inside a node. I'd like them to be signed, so something like caption (below the plot) is needed. One of them — "the good ...
0
votes
0answers
36 views

Tikz: Using the size of one node to set the size of another node [duplicate]

I've been working on making diagrams involving many connected components, that will look something like the following: I want to be able to make such diagrams in a reasonably modular fashion, ...
2
votes
1answer
68 views

How to integrate pgfplot inside a pre-existing tikz picture?

I'm trying to put together a pgfplot inside a pre-existing tikz picture. But somehow the axis I create with pfgplot has different units and I'm not sure how to make the two things fit. The code is: ...
5
votes
1answer
59 views

TikZ Spacing Between Arrow and Node

I'm attempting to draw a simple diagram comprised of three nodes arrange in a triangle. I'm having a difficulty with getting the arrows to "connect" to one of the nodes, there's a small space between ...
2
votes
0answers
42 views

3D plot from file

Hi I am currently learning how to do plots in Tex and I found a problem which I cant solve. I would like to do 3D surface plot from file but all what I get is a 3D line. For learning purpose I used ...
1
vote
0answers
40 views

tikz cd: ! I can't find file `librarycd.code.tex'

The cd package for tikz seems to be failing, or missing. I am using Kile in Ubuntu 10.4, and I installed all the tikz-related packages my package manager could find. MWE: ...
0
votes
0answers
70 views

Tikz externalisation not working despite enabling write 18 or shell escape

I am trying to set up tikz externalisation so I can save individual images as .pdfs (and eventually .png's). I am trying to run the following code in TeX works, W7, MikTex 2.9. I have changed the ...
7
votes
4answers
113 views

clip a image with relative coordinate

I want to clip a image with relative coordinate. see below example: \documentclass{standalone} \usepackage{tikz} \tikzset{mynode/.style={draw,solid,circle,inner sep=1pt}} \usepackage{etoolbox} ...
1
vote
2answers
54 views

How to have an invisible layer in tikz?

Back in the day (2014), I've had some code posted in Drawing a styled node invisibly (phantom / off-screen)?, which is reposted below. Then it apparently compiled; with my current texlive 2014 ...
0
votes
0answers
32 views

matplotlib2tikz - compilation error for 2D

Situation: I am using matplotlib2tikz to export a two dimensional plot (comparison). Exported to pdf it looks like this: Including the tikz file (and compiling) yields an error though: Package ...
3
votes
1answer
46 views

CAD-like paths in TIKZ

I have drawn a petrinet diagram using TiKZ, and it doesn't look great when there are too many intersecting paths. It will be great if I can make these paths follow a grid-like (like in the CAD ...
10
votes
1answer
83 views

Hyperref box does not obey slant

When I place text in a 3D figure along a plane, the hyperref box does not get adjusted. The problem text in the image was placed as \node [yz slant style, anchor=west, black] at (0,1,3) ...
6
votes
1answer
143 views

Help with basic block diagram

I'm having trouble figuring out how to do the nodes to make a basic block diagram. And how to incorporate the arrows. Not interested in the colours, just a plain rectangle box like I have used is what ...
5
votes
2answers
147 views

Draw lines inside a matrix

I have the following code to draw a matrix: \documentclass{article} \usepackage{tikz} \usetikzlibrary{matrix} \begin{document} \begin{tikzpicture}[cell/.style={rectangle,draw=black}, nodes in empty ...
2
votes
2answers
35 views

Put a title above a matrix

I have the following code, which draws a title (a matrix:) and a matrix: \begin{tikzpicture}[cell/.style={rectangle,draw=black}, nodes in empty cells] \node at (0,2) {\Large a matrix:}; \matrix[ ...
4
votes
1answer
39 views

Error message in labeling tick marks

I want to label a tick mark on the x-axis and a tick mark on the y-axis. I put a "%" before the commands in the following code so that the line could be plotted and the tick marks can be drawn. The ...
1
vote
1answer
26 views

pgf-pie aside block trouble

I have trouble with a pie chart (pgf-pie). I can't put pie in block aside why? \RequirePackage[absolute,overlay]{textpos} \setlength{\TPHorizModule}{1cm} \setlength{\TPVertModule}{1cm} ...
2
votes
2answers
96 views

How can I draw an implicit equation with pgfplots?

I need some help plotting y^2=x^2(x+1) in pgfplots. I want to print it in the domain -10 to 10. I tried for sometime, but it did not work. Also it should be a smooth curve and not a dotted one.
1
vote
0answers
27 views

TikZ always starts from Center [duplicate]

Trying to use TikZ to draw a diagram, I used the example below, but I see that I could not start the beginning point from a bit left of the page. I checked this question but it's too long and I don't ...
14
votes
4answers
452 views

How to draw an equilateral triangle with TikZ?

I'm trying to draw a little picture with TikZ. It should show an equilateral triangle with length 1 and circles with radius 1/2 on each corner of the triangle. Next, the intersections of the circles ...
1
vote
0answers
55 views

Draw a 2d space-time diagram in latex [closed]

I am very new to tikz. I was wondering if someone could tell me how to go about drawing a space-time diagram pretty much like the one included below within latex. Thank you
4
votes
1answer
66 views

Filling the intersection area of two circles and ellipse

I found a picture like this. I want to fill the intersection area of two circles and ellipse. This is what I have done: \documentclass{article} \usepackage{geometry} \usepackage{tikz} ...
0
votes
0answers
22 views

pgfgantt - adjust vgrid with \gantttitlecalendar

I am using \gantttitlecalendar to generate my title block that consists of months and weeks. The default behaviour of vgrid is to take each unit as a day, or if compress calendar is true, each unit ...
31
votes
7answers
2k views

Generate analog clock with numbered face, add seconds, Roman numerals

Looking at the excellent answers here, I can't help wondering how I can accomplish two apparently simple modifications: I wanted to be able to generate a traditional Roman-number clock; It would be ...
1
vote
2answers
68 views

Putting arrows Properly in Tikz

I have the following code \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{shapes,arrows,shadows,calc,fit} \usepackage{amsmath,bm,times} \newcommand{\mx}[1]{\mathbf{\bm{#1}}} % Matrix ...
1
vote
1answer
53 views

tikz-cd.sty not found

I have certain codes written in LaTeX with several diagrams in tikz-cd. I must compile these codes in other computer (with Ubuntu 12.04 LTS) and when I compile appear this error: tikz-cd.sty not ...
5
votes
2answers
88 views

Indicating lengths of line segments

I would like to label the length of four line segments in a certain plot. In the plot, the length of line segment PQ should be labeled a, the length of line segment QS should be labeled b, the length ...
2
votes
1answer
31 views

tabular inside tikz matrix

The matrix is not being layed out correctly. It should be a 2x3 matrix. What's wrong with the code? MWE: \documentclass{article} \usepackage[table]{xcolor} \usepackage{tikz} ...
1
vote
0answers
43 views

Ending a tikzpicture environment in conditional causes “Missing } inserted”

I want to create a number of tikzpictures. I have a number of items I want to draw. Each tikzpicture takes up a whole page and may contain up to 4 items. (It is not good enough to to have each item in ...
4
votes
1answer
96 views

Tikz relative positioning with ++

The red rectangle is in the correct position, but I need the blue ones to be 4 and 8mm to the right of the red on the same height (not below, as my code makes it). What is wrong with my use of ++? ...
1
vote
1answer
68 views

how to remove the background for png picture

I would like to make the background transparent. In Texmaker, if I right-click on the TikZ picture, I can save it as a png image as follows If I save this picture, I get the white background. Is ...