Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [tikz-pgf]

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.

3
votes
2answers
73 views

How can I use pgf from within TikZ

Background: I understand that TikZ is built on top of pgf. Both are described in the pgf manual. However, I have been unable to find the section (if it exists at all) of the manual describing how the ...
3
votes
2answers
50 views

Problems with anchors and pgfkeys

In How to properly use new options into \pgfdeclareshape of makeshape package I had a problem with including \ifx in \pgfdeclareshape which was solved by @marmot. At this moment, I'm trying to ...
4
votes
1answer
142 views

PGF Plot settings

I have this tikzpicture/pgfplot (see below). I have a few questions about it. How do you put the x-labels (101, 102 and so on) on top of the x-axis? How do you point the y-axis downwards (the arrow ...
0
votes
0answers
32 views

Tikzpicture goes off the page in standalone mode?

I'm trying to make two Tikzpictures side by side, but I am not sure why it is going off the page in Tikzpicture... Here is my code: \documentclass[tikz,border=3.14mm]{standalone} \usepackage{amsmath}...
2
votes
1answer
82 views

Molecular orbital diagram for CH2

I'm trying to draw an MO diagram for CH2 by mimicking this MO diagram (excluding the orbital images), but things don't look like the way I want it to be. I really want to make it nice and similar to ...
2
votes
1answer
83 views

Combine tikz curve with random variation

I would like to combine a curve defined with \draw with a random variation along the path. So far I have found quite some interesting discussions on tex.SE like How to draw Brownian motions in tikz/...
-2
votes
4answers
137 views

How do they draw this in Latex? [duplicate]

How do they draw this in Latex ?
4
votes
4answers
609 views

Tikzing a circled star

I have used \tikzcircle[fill=red]{3pt} This item. for showing a filled circle for an item. But I wish to have a circled star as below one instead of single circle. How can I use TikZ for ...
9
votes
2answers
521 views

Better way to make this picture of sequence with arrows

I created this picture with very basic TikZ components and the code looks a bit messy, is there a more elegant way to do this? And secondly, is there a way to put dots at the stubs of the arrows in ...
2
votes
1answer
52 views

Add details to TikZ, woodworking diagram

I am trying to recreate this hand drawn diagram of a wooden stand: Here is the .tex: (it is a bit longer than a MWE). \documentclass[12pt]{article} \usepackage[paper=a2paper,margin=1cm,landscape]{...
9
votes
2answers
249 views

Segment marks with round caps

(I guess many will view this nitpicking.) How can I replicate the soft-yet-beautiful-looking segment marks of GeoGebra. \documentclass[tikz,border=10pt]{standalone} \usepackage{tkz-euclide} \...
1
vote
0answers
54 views

New shapes with fixed dimensions and without text

With the valuable help of marmot, I am designing new shapes with fixed dimensions. If I write text in these nodes, they are not adapted to the text. I need to eliminate the posibility of writing ...
0
votes
0answers
26 views

Colormap error in overleaf

So I'm working with the visualization of data with a colormap, with the compiler of my computer I could genrate this graph: That's the way I want to put it in overleaf, but when I use the same ecode ...
4
votes
1answer
61 views

TikZ path with perpendicular and cycle doesn't connect nicely when rounded corners involved

In the following MWE, the TikZ path with perpendicular and cycle doesn't connect nicely when rounded corners involved. Why, and how to circumvent the problem? \documentclass{standalone} \pagestyle{...
7
votes
1answer
89 views

Breaking a Loop in Tikz

\documentclass{article} \usepackage{tikz} \begin{document} \foreach \N in {8} {\begin{tikzpicture}[scale=1.2,declare function={f(\x)=((1/3)*(\x)^(3)-3* (\x)^(2)+8*\x-3;}, lnode/...
5
votes
1answer
113 views

Cyclic flowchart in TikZ

How to draw this image with TikZ? Any suggestions? I want to try my own but I need some help to start. EDIT, First try, I am working on it: \documentclass[tikz,border=2mm]{standalone} \...
0
votes
1answer
84 views

Constructing a network-graph using TikZ

I want to construct the following image in LaTeX, but I'm not sure how to do it: EDIT: \begin{example} Consider the graph $G$ following shown in figure 1.2. The transition matrix of a simple random ...
3
votes
1answer
60 views

How to fill color in logic gates in Tikz?

How to color fill this AND gate? \documentclass[border=2mm]{standalone} \usepackage{tikz} \usetikzlibrary{shapes.gates.logic.US} \usetikzlibrary{circuits.ee.IEC} \begin{document} \begin{...
2
votes
1answer
44 views

How to detect fill color option with pgfkeys

I have the following code section: \pgfkeys{ /tikz/.cd, color izquierda/.initial=\tikz@fillcolor, color derecha/.initial=\tikz@fillcolor, } It works, but if I don't have activated both options,...
0
votes
0answers
29 views

“node contents” is no more available in label, what's going on?

Normally a label is a node and we can use it as such, at least I think I was able to do it before version 3.1 of TikZ. Now when I try to use node contents in label, for example like this : \...
0
votes
1answer
50 views

Wrong position of arrows in Tikz with pgfplots version 1.3

I use the following code to draw an arrow in Tikz with \pgfplotsset{compat = 1.3}: \documentclass{standalone} \usepackage{pgfplots} \pgfplotsset{compat = 1.3} \begin{document} \begin{tikzpicture}...
-2
votes
0answers
49 views

How one can filling outside and inside of an arc? [duplicate]

I want to draw a figure like this: The main problem is to fill outside of arc. Please help me to get a Latex code for the image.
5
votes
1answer
82 views

Draw one function, varying color by (gradient) using another function's value

I'm trying to draw something in TikZ where I want to vary the draw color. E.g. I'm drawing this line \documentclass[tikz]{standalone} \usetikzlibrary{intersections} \begin{document} \begin{...
-1
votes
0answers
62 views

plotting convex sphere [duplicate]

I want to draw a figure like this: The main problem is to fill outside of arc Please help me to get a Latex code for image.
0
votes
0answers
58 views

draw this block diagram? [duplicate]

I would like to draw the following picture. I have tried my best but nothing work. My document class memoir. thanks.
-1
votes
0answers
53 views

Drawing orbitals for molecules [duplicate]

Is there a way to draw orbitals or the images below in TikZ? I can only figure out how to draw one simply symmetric dumbbell. Please let me know and thank you. Since people want to see something: \...
2
votes
1answer
38 views

How to align coordinates vertically and horizontally in TikZ

I have points with irrational coordinates, because I'm mixing polar and Cartesian coordinates. I'd like to specify a coordinate as the x-value of one thing and the y-value of another thing. In this ...
0
votes
1answer
52 views

How do I draw 3-D axes in TIKZ?

Can someone help me draw this? I need it to show the effect of a rotated polarizing component, and things always looks better in tikz, my my skills are sub-standard.
-1
votes
1answer
106 views

How to draw this graph in LaTeX [duplicate]

I would like help drawing a specific graph in LaTeX
5
votes
1answer
88 views

Draw tangent of an arbitrary curve at intersections

I have this picture: and I want to draw a tangent line at each of the marked intersections. I have found some answers (and examples in the TikZ manual) using the decorations.markings library. The ...
1
vote
1answer
41 views

How to have different types of edges based on values in foreach loop?

I am trying to draw a Knodel graph using TikZ. The graph I am trying to reproduce has different style edges for each "dimension". I would like to have different edges for the different values of Delta ...
2
votes
1answer
51 views

Place Value Chart in Matrix Environment

I want to add another columns (yellow) for the Millions Place plus I would like to auto adjust textwidth and height of the nodes while reading the place values from bottom up: \documentclass{article} ...
3
votes
2answers
67 views

Combine rectangle split with array

I want to draw a "complicated" figure, like shown below. What is need to be done: Enlarge the \hdashline to fit the hole width (drawn in red) Remove the dashed line (:) from the first row (done per ...
2
votes
1answer
81 views

How to plot the schematic diagram of the following diagram using tikz latex?

want to plot the schematic diagram of the following diagram using tikz latex, but it is not correct. \begin{tikzpicture}[node distance=4cm,auto,>=latex',every node/.append style={align=center},int/...
0
votes
0answers
21 views

how to include a .xcf gimp file in tikzpicture?

Gimp usualy saves files with .xcf extensions and I have experiences loos of quality by using "export" instead of "save". I would like to know if there is a standard way to include an .xcf file in a ...
1
vote
0answers
26 views

Copy of series in legend for prepared boxplot

When I add a legend entry to a boxplot prepared plot, I get an identical copy of the box plot (which may be huge!) in the legend. How can I fix this? As a workaround, I am currently adding area legend ...
0
votes
1answer
32 views

Square root in pgfplots not being plotted

I'm running the following bit of code, which I've used to plot a couple of functions already, but when I'm running it with the following function, it plots only the axes \usepackage{pgfplots} \...
3
votes
1answer
70 views

Coordinates unit in pt although default is cm in TikZ

As we know that in TikZ, if unit is not mentioned in the coordinate in TikZ, it takes cm by default. When I extract the coordinates, I was expecting the unit as cm. But TikZ shows the unit in the ...
0
votes
1answer
32 views

Defining TikZ function to produce Knodel graphs

I am trying to define a function that will produce a Knodel graph (examples pictured below). I'm not completely sure how the code works for TikZ to do a for loop using a range, and how to compute ...
1
vote
1answer
56 views

How could I graph z=sqrt(x^2-y^2) using Pgftools? I believe I've all suggestions on the internet but to no avail

I have tried graphing it with the parametric notation (i.e. ({x},{y},{sort(x^2-y^2)}) and as seen on my code below but nothing renders the image shown on graphing calculators. \begin{tikzpicture}[...
1
vote
1answer
22 views

Second mark coordinate in decoration in postaction not recognized

In decoration, second mark coordinate is not recognized: \draw[thick,red,zigzag,postaction={ decoration={ markings, mark=at position 0.7 with \coordinate (x); mark=at ...
4
votes
4answers
254 views

Positioning node within rectangle Tikz

Without using phantom how can I place the text starting from the bottom up? \documentclass{article} \usepackage{tikz} \begin{document} \def\n{.5} \definecolor{aqua}{rgb}{0.0, 1.0, 1.0} \...
1
vote
1answer
36 views

How do I remove extra padding from drawing on a figure with tikz?

I am trying to draw over a figure using tikz, using a method for adding scalebars from this answer. The figures that are drawn over this way have extra padding around them (i.e. between the subfigures)...
2
votes
0answers
21 views

Input Values To Produce changing Tikzpicture

I have a general question with a minimal example. Is it at all possible in Latex or Tikz to produce a field where an input value can be placed and once the enter key is pressed then a new output is ...
-1
votes
1answer
59 views

How to draw |x-y| <= 1/2

I am trying different solution but unable to draw something like this.
2
votes
2answers
41 views

Problems with new options in new shapes using \pgfkeys

I have a problem with new options in new shapes using \pgfkeys: when I compile the following code: \documentclass[border=2mm]{standalone} \usepackage{tikz,makeshape,filecontents} % Require ...
4
votes
1answer
42 views

Draw arrows with multiple lengths

I'm currently facing a problem with drawing arrows in a diagram. I have currently a few arrows in online, I want a second arrow below which spans over all the objects in the line above. My code looks ...
1
vote
1answer
58 views

How can I 3D plot y=4x^2+z^2 using Pgfplots?

I am trying to 3D plot y=4x^2+z^2 using Pgftools but I'm unable to use z as an independent variable in the function. \begin{tikzpicture}[scale=1.5] \begin{axis}[ grid=major, 3d box=complete, ...
2
votes
1answer
38 views

TikZ: Define a style of node that puts halo/contour around text [duplicate]

How put halo around text using the contour package as suggested in this answer in many nodes by defining a style? MWE: \documentclass[tikz]{standalone} \usepackage[outline]{contour} %halo around ...
2
votes
3answers
123 views

I want to color a graph

Im very new to making latex so all the tutorials I have found about my question were too hard to understand or didn't do exactly what I wanted. I already have the graph I want without the coloring: \...