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.

Filter by
Sorted by
Tagged with
0 votes
1 answer
21 views

Arrows to points inside the axis environment

I am making an image that shows plotting points on the cartesian plane. I am using the axis environment from pgfplots. It works well for plotting the points but I can not seem to figure out where to ...
user avatar
1 vote
1 answer
33 views

Circle rows in a matrix and add comments aside

I am trying to modify my bmatrix by circling a row, and adding a \sum symbol as well as circling few other components and writing above them, as seen in figure below: My matrix code is the following: ...
user avatar
1 vote
3 answers
42 views

Given the diameter, draw in pgfplots the circle and its intersection with x-axis

Given two points, A and B, I want to draw the circle of diameter AB together with its intersection with the X axis. Intended result is the figure I got this with the code \documentclass{standalone} \...
user avatar
  • 435
3 votes
2 answers
74 views

tikz curves with repetitive form

Could someone rewrite the code using tikz loop and cycle features to obtain the shape as attached at the bottom. Optionally, add your tricks to make the ends of the ribbon look more natural. \...
user avatar
0 votes
1 answer
30 views

Problems in my Tex files when compiling tikzcircuit

I have been trying to compile my file that contains a tikzcircuit for few hours now (>6hours), on overleaf. The file compiles with no problem whatsoever when the circuitikz is commented. However, ...
user avatar
0 votes
1 answer
25 views

Use a custom figure as a node shape

There are two similar questions to mine: How to use a tikzpicture as a node shape Use a custom shape as a "building block" But they both attempt to draw the node using tikz and I want to ...
user avatar
0 votes
1 answer
20 views

Plot Probability Density Diagram of Accuracy and Precision with Gaussian Distributions in Tikz

I'm trying to generate a diagram like this with Tikz: I just ability create such an image, but it is not desirable. Thank you if you can help me. \documentclass[border=3pt,tikz]{standalone} %[...
user avatar
  • 3
2 votes
1 answer
49 views

Creating a comparison chart

How to create a chart as follows using LaTeX. This is just one example. You can also share your more elegant suggestions. MWE: \documentclass{article} \usepackage{tikz} \usetikzlibrary{intersections} ...
user avatar
  • 263
3 votes
2 answers
49 views

How to Draw Electrons on Bonds Using Chemfig and Contain a Chemfig withn a Box?

I have been playing around with the "chemfig" package to get electrons drawn on a given bond. I used the "chemmove" command to draw the electrons, but it is inefficient to modify ...
user avatar
  • 113
0 votes
1 answer
22 views

Show 0 when printing nodes near coords in chart bar

Problem description: I would like for all values including 0 to be shown above bars in a chart bar. As I am new to latex, I assume something is set in nodes near coords that prevents 0 from showing. ...
user avatar
5 votes
1 answer
121 views

tikzmark no shape named a21 known

I am not able to compile the following. I get an error no shape named a21 is known. What is the mistake I am making? \documentclass{article} \usepackage{array} \usepackage{tikz} \usetikzlibrary{...
user avatar
  • 51
3 votes
2 answers
96 views

\Begin{Graph} side by side

Problem Description This is a continuation of a question I had here: Numbering and captioning pgfplots/tikzpicture Where We solved how to name Graphs in a specific way and in-turn generate a \...
user avatar
0 votes
1 answer
13 views

Unknown error using legend entries

I'm having trouble with my tikzpicture. I have the following code: \begin{center} \begin{tikzpicture}[scale = 1] \begin{axis}[ ...
user avatar
0 votes
0 answers
45 views

Draw this picture in Latex template. (Complex 2) [duplicate]

I ask for scientific support and responsible community members on this platform to find a practical solution to this problem. Draw a diagram establishing a one-to-one correspondence between the ...
user avatar
3 votes
1 answer
32 views

chemplants: fill the default pictures with TikZ options

The chemplants package offers tools to draw simple or barely complex schemes of chemical processes. Process units and styles for streams and utilities are defined to be a sort of extension of the TikZ ...
user avatar
4 votes
1 answer
51 views

How to Automatically Label Vertices Using tkz-graph

Problem Description I am trying to created a labeled digraph using the tkz-graph package, such that the vertices are "automatically" labeled $v_1$, $v_2$, etc., starting with $v_1$ at the &...
user avatar
  • 3,788
4 votes
1 answer
58 views

Numbering and captioning pgfplots/tikzpicture

Problem Description I have a specific way I would like to caption my graphs created with \begin{tikzpicture}. More specifically I want to give them a numbering system, like that of figures and tables, ...
user avatar
2 votes
1 answer
31 views

Tikzposter - Stretching the title box to accommodate a long title

I have a long title for my tikzposter, which I want to keep all on one line for the sake of the poster's spacing. What I have now is this: \centering \settitle{ \parbox{\linewidth}{ \centering \...
user avatar
  • 21
1 vote
1 answer
22 views

Fix node positioning for pgfonlayer to prevent shaky gif

I'd like to create a gif using tikz. However, using the pgfonlayer to create multiple pages results in the nodes being shifted whenever an edge is added between them. This makes the gif very shaky. Is ...
user avatar
1 vote
1 answer
20 views

Include Hyperref Text Field in a UML State Diagram

As you can see in my minimal example, I have a state machine diagram where students can write the name of the transition line in a text box. Can you give me some advice on how to place a text field ...
user avatar
  • 195
1 vote
1 answer
41 views

Please assist with the placing of the labeling next to the lines of the trees and also with increasing the size of the node J

\documentclass[12pt]{article} \usepackage{syntonly} \usepackage{geometry} \usepackage{caption} \usepackage{subcaption} \usepackage{tikz} \usetikzlibrary{arrows.meta, positioning} \...
user avatar
0 votes
1 answer
24 views

A memory layout that has proportional size of block

I got this code from an web and it looks like this. \documentclass[border=10pt]{standalone} \usepackage{tikz} \begin{tikzpicture}[node distance=0 cm,outer sep = 0pt, inner sep = 2pt,font=\...
user avatar
  • 119
0 votes
1 answer
61 views

How to draw internal energy-entropy curve in Tikz

I would like to reproduce the attached internal energy-entropy curve in Tikz. How can I do this? Getting a smooth curve with the correct form is quite difficult for me.
user avatar
  • 1
3 votes
1 answer
42 views

Fill parts of a shape

Could you please tell me how to fill the highlighted parts of the shape with fill=gray!60? Thank you as always. \documentclass[]{article} \usepackage[margin=0.5in]{geometry} \usepackage{pgfplots} \...
user avatar
  • 1,960
0 votes
0 answers
35 views

Inserting a graph that is created by 'tikz' as a 'figure'

A graph has been created by tikz and since it needs a caption similar to the other figures, it should be inserted in the figure environment. Is it possible? and how to do that?
user avatar
3 votes
4 answers
160 views

An element in the middle of a line

Please consider my minimal example. I would like to place an additional element -in this case a text field- in the middle of the line between nodes A and B. How does this work? Which of the following ...
user avatar
  • 195
4 votes
2 answers
180 views

Undefined control sequence for TikZ, issue with \drawfill

The other colored arcs work. Why does the blue arc line give a TikZ complaint? \begin{figure}[h] \begin{center} \begin{tikzpicture}[scale=1.5 ,cap = round, color = blue] \draw [ ultra thick, blue] [...
user avatar
  • 431
0 votes
0 answers
18 views

TikZ forest ignores tikzsetnextfilename

I have the next structure Main.tex \documentclass[12pt]{report} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Draws & diagrams \usepackage{tikz} \usetikzlibrary{shapes.geometric, arrows.meta, shadows} \...
user avatar
0 votes
1 answer
85 views

How to draw three graphs on the same plane with nodes

I am relative new on latex, I therefore request somebody to assist with a code of drawing three graphs (see attached picture): Below is the MWE: \documentclass[12pt]{article} \usepackage{syntonly} \...
user avatar
-3 votes
0 answers
81 views

Converting bitmap diagrams into TikZ

I have some basic experience with LaTeX and used it to help publish the below volume, and others… Hardback: https://www.amazon.co.uk/Chris-Langans-Major-Papers-1989/dp/097191625X/ The hardback edition ...
user avatar
  • 55
5 votes
1 answer
219 views

Looking for how to draw that diagram in TikZ

I'm looking to create something like this in TikZ environment. Im kind of stuck with the relations to each other: it seems weird, positioning one below the other, when unsure if all the block will be ...
user avatar
  • 53
1 vote
1 answer
19 views

Expand command in pgfplots axis options

Depending on a boolean flag, I would like to set axis options like in the following example: \documentclass{article} \usepackage{pgfplots} \pgfplotsset{compat=1.18} \usepackage{xparse} \usepackage{...
user avatar
3 votes
2 answers
371 views

How can I use more colors in TikZ?

There are only white, black, red, green, blue, cyan, magenta, and yellow. How can I add others? (I would like to use Green (different from green).)
user avatar
  • 287
1 vote
1 answer
62 views

Extend a given shape from the UML-TikZ package with the path picture property

I call the style definition mystyle in line 20. As you can see, I pass a \filldraw command as an argument to the style definition mystyle. That way I want to achieve a gray circle to be displayed in ...
user avatar
  • 195
4 votes
2 answers
108 views

Using tikz to draw a rectangle with black-white gradient in form of Gaussian

I want to make a rectangle, longer horizontally than vertically, that is black at the left and right ends and whitish in the center. I don't want a linear gradient change from black to white (and back)...
user avatar
  • 407
1 vote
1 answer
89 views

creating random numbers in a tikz diagram for use in a formula

I would like to create a worksheet similar to this https://pastebin.com/fSuS4C9f but for circumferences of circles not to bothered about the answers section at the moment but I can't even get the ...
user avatar
  • 425
3 votes
1 answer
61 views

Modify the style of UML-tikz elements with standard tikZ commands

I use the UML-tikZ package to create UML state machines. From time to time I want to make changes to the appearance of the given elements. For example, I want to enlarge the arrowhead of the element \...
user avatar
  • 195
4 votes
1 answer
70 views

tikz remember picture - How to set coordinate based on picture's height or width?

When using tikz to draw lines with the remember picture argument, is there a way to set the coordinates based on the height or width of the picture? For example, in the code below \draw [-stealth, ...
user avatar
  • 1,695
2 votes
1 answer
39 views

How to hyperlink the text in the vector diagram with the text in the article in LaTeX?

If we need to link the text in the article in LaTeX with the text in the figures, we can do this with the tikz package. However, tikz is a little difficult and it is very time-consuming, so a lot of ...
user avatar
  • 687
1 vote
1 answer
38 views

Part of tikz plot is missing

The last part of all my functions are missing. I have found a few similar posts here that suggested changing domain/samples. I tried a bunch of different values for samples up to 10000, but none of ...
user avatar
5 votes
1 answer
63 views

Generate TikZ Node with a macro

Inspired by this post, I tried to wrap this normal node... \node[fill=blue!20,shape=ellipse, draw=black] (nodename) at(0,0){\begin{tabular}{l} Main Text\\ \hline extension point: \\ Some ...
user avatar
  • 195
2 votes
2 answers
77 views

Drawing graph: using (x,y) coordinate rather than angle to determine the position of the vertices

In the following answer to draw a graph, is there a way to use (x,y) coordinate rather than angle to determine the position of the vertices to draw the same graph? https://tex.stackexchange.com/a/...
user avatar
0 votes
1 answer
45 views

Drawing lines with node and text

Please can someone help me draw this in latex? My attempt is below \begin{tikzpicture}[xscale=2] \draw [thick, draw=black, *-*] (0,0) -- (7,0); \node[circle,fill=black,inner sep=0pt,minimum size=...
user avatar
4 votes
1 answer
44 views

adding line breaks in tikz and colour to diagram

I have the minimum about of code to produce what I want but am unsure how to split the text into separate lines, for example the examples below the definitions. Colour the ovals. \documentclass[...
user avatar
  • 425
1 vote
1 answer
33 views

Drawing a graph with vertices of different colors and different labels

I want to draw a graph exactly like the output of the following answer, but with vertices of different colors and different labels. https://tex.stackexchange.com/a/357243/148579 What parameters should ...
user avatar
0 votes
1 answer
38 views

Creating hatched cells in a resized table\tabular

I'm writing an elsevier els-cas article and am trying to hatch some table cells for a table\tabular setting. It seemed to work fine until I used \resizebox and set the table size to \textwidth. The ...
user avatar
  • 3
0 votes
2 answers
74 views

I want to create 10x10 squares and fill the elements all around with zeros?

I want to create 10x10 squares and fill the elements all around with zeros As shown in the attached images But when I add zeros, a space appears between these elements. Below is the MWE: \...
user avatar
  • 21
0 votes
0 answers
26 views

Two matlab2tikz figures side by side

I want to have two figures generated with matlab2tikz side by side. I tried \documentclass[12pt,a4paper]{report} \usepackage{parskip} \usepackage{blindtext} \usepackage[onehalfspacing]{setspace} \...
user avatar
0 votes
1 answer
30 views

How to group multiple figures into one and then draw lines over the entire figure?

I have a massive block of code with multiple figures in it. I am looking for an easy way to draw lines anywhere within the massive figure. This is the block of code that I have. \documentclass{article}...
user avatar
  • 1,695
1 vote
2 answers
45 views

Access pgfkeys outside environment

I find that the value of a key defined by \pgfkeys inside an environment can not be invoked outside this environment. In the following example, I want to typeset the value of the key aaa outside the ...
user avatar
  • 2,461

1
2 3 4 5
633