The 2024 Developer Survey results are live! See the results

# Questions tagged [edge]

The tag has no usage guidance.

121 questions
Filter by
Sorted by
Tagged with
1 vote
54 views

### Tikz forest. grow east Issue with arrows. How to keep them straight?

For my flow chart, if I do not use grow=east option for the tree, it does not fit the page width. Using grow=east makes it fit. But now the arrows connecting the nodes no longer are straight as they ...
• 20.4k
62 views

### Tikzpicture flow chart: how to avoid lines crossing each other

I'm trying to draw a chart; I tried avoiding that lines cross each other in vain. The following picture illustrate what I get: I would like to avoid if possible that the lines and the edges cross ...
• 591
1 vote
44 views

### How to draw edge between points in two different tikz-pictures

how can I draw an edge between point a (=O) in the first picture and d (=1) in the second picture: \usepackage {tikz} \usetikzlibrary {shapes,arrows,positioning} \begin {tikzpicture} [-latex, node ...
1 vote
35 views

### given two nodes, how to define a custom edge style that draws a circular arc instead of a segment joining the two?

Given two points A and B (left), I need to draw a beam that looks like this: i.e. end points of the arc are defined by the nodes, with some specific angle that I can specify. e.g using draw custom ...
58 views

### lines between nodes [closed]

my question is if there is an "easy" way to draw a line between each node of a square with every node of the other squares which have been drawn symmetrically, here is the code of what I'm ...
• 73
83 views

### Latex forest edge with weird positioning

I'm facing a weird position of edge in standard forest code. Every edge is fine but the last one. How can I fix this problem? \begin{forest} for tree={draw, l sep=3em, s sep=0.5em, anchor=center, ...
1 vote
1k views

### Browser not showing math symbols when I am visiting certain websites [closed]

Okk so here is my issue I visited the stack math website and all the mathematical symbols were replaced with probably some tex code or something else that I don't know of I tried my best to search it ...
1 vote
92 views

### Labelling arc in network flow diagram

I produced the following image with the Latex code below. Can anyone explain how to make the nodes and text bigger and label the arcs, for example add label 3 to the arc connecting n1 and n2? \...
• 143
145 views

### Artifacts in edge labels in tikz graph

I have this code which I am compiling with luatex: \usepackage{tikz} \usetikzlibrary{graphs, graphdrawing, positioning, quotes} \usegdlibrary{force} \begin{tikzpicture} \graph[spring layout, nodes=...
• 199
130 views

### How to draw a rook graph?

I'm trying to draw a $4\times 4$ rook graph. That is, the graph whose vertices form a $4\times 4$ grid whose edges indicate the allowed movement of the rook on a chess board. I'm struggling to draw ...
82 views

### How to fix edge overlapping node in forest (increase distance between just two nodes)

I've the following tree made with forest package but unfortunately there is the edge to Z going through M. Why is that? I already tried to increase the s sep option but couldn't fix it. Does anybody ...
• 27
106 views

### Tikz: how to attach labels to edges in trees where some nodes are missing?

I want to grow a tree that has some nodes empty/missing so that the lines directly connect: \begin{tikzpicture} \coordinate child { child {node {pAp} edge from parent node[left] {x}} ...
• 123
1 vote
59 views

### Edge endpoints when automating node connections with Tikz/automata

I'm trying to draw a Markov chain. As I have 11 states, I tried to automate the declaration of states as well as the edges in a for loop. Here is my MWE: \documentclass{standalone} \usepackage{tikz} \...
54 views

### decision tree formatting (edges merge)

I am trying to draw a decision tree that's structured like this: here's what I have so far: \usepackage{tikz} \begin{document} \begin{tikzpicture} [ grow = right, sibling ...
1 vote
188 views

### drawing trees with forest

i want to draw a tree with thicker branches like the one in the picture, what could i put instead of ''thick'' ? \documentclass[border=3.141592]{standalone} \usepackage{forest} \begin{document}...
205 views

### Coloring a tikz cycle with a different color for each segment

I have the following code: \documentclass[letterpaper]{article} \usepackage[table]{xcolor} \definecolor{asparagus}{rgb}{0.53, 0.66, 0.42} \definecolor{bleudefrance}{rgb}{0.19, 0.55, 0.91} \...
• 501
83 views

### Drawing lines in tikz - just like a graph, but with extended edges (?)

I am familiar with graphs in tikz and I feel like I can do some work already. But how would one reproduce extended edges? I know how to create a simple graph with edges between its nodes, but how ...
• 501
178 views

### Squiggly transition in automaton

I need to make an automaton, that looks like this: I can only do the following: \usepackage{tikz} \usetikzlibrary{arrows, automata, quotes, positioning } \begin{...
• 63
108 views

### Display weight without edge with Tikz

I would like to put a weight on an invisible edge in a graph. I tried to use opacity to make the edge disapear and let the weight, but obviously the weight is affected to. Do you have a solution ? ...
• 51
1 vote
207 views

### Bipartite Graph

The edges of my graph are overlapping, is there a way to have some distance between them and also how to color a specific edge? \definecolor{myblue}{RGB}{80,80,160} \definecolor{mygreen}{RGB}{80,160,...
363 views

### Make edges parallel

The edges are matching. I would like them to be parallel horizontally. I tried changing the value of the yshit parameter, but it didn't work. \documentclass{article} \usepackage{geometry} \...
• 153
44 views

### How to make edges parallel

How can I make the edges between the vertices {q_1,q_3} and {q_1,q_2,q_3} parallel? Code: \documentclass[tikz,12pt,border=1mm]{standalone} \usepackage[brazil]{babel} \usepackage{tkz-euclide} \...
• 153
1 vote
81 views

### Reposition graph edges

How can I place the loop of vertex {q_1, q_2, q_3} and vertex {empty set} above and below these vertices, respectively (as in the drawing below), instead of on the right? This is my .TEX: \...
• 153
148 views

### How do I remove these corner markers /edge markers?

Hello everyone out there. I'm currently writing my thesis in Overleaf and for some reason all of my pages have these edge markers on them. How do I remove them? \documentclass[oneside,12pt]{...
128 views

### how to change the angle between the edges of the automaton/graph

I would like to get this: but this is what i got: this is the code: \begin{center} \begin{tikzpicture}[ node distance=1.5cm, every node/.style={draw, fill, circle, inner sep=1....
• 153
1 vote
60 views

### Drawing dashed edges in a binary tree and adding new edges between different nodes

I would like to add extra edges between nodes that aren't specifically related as child and parents in a binary tree and also to change the styling of the edges. Currently I have the following code: \...
• 501
1 vote
258 views

### How to add text above the lines nodes in LaTeX

I have following code and I try to add text above the edges, but don't how to do it \begin{tikzpicture}[every tree node/.style={draw,circle},sibling distance=30pt, level distance=50pt] \tikzset{edge ...
1 vote
118 views

So i am trying to make a flowchart with tikz. Everything was working fine and as expected. But then I tried to specify starting and endpoints of edges between some rectangles and out of nowhere tikz ...
• 45
64 views

### Border on subset of pages

I want a gray border on the outside edges of pages of specific chapters in a textbook to obtain the visual effect that looking at the closed text pages you can spot the relevant special chapters. ...
• 249
1 vote
70 views

### I'm looking for general code to get labels the same orthogonal distance from their lines in a forest probability tree

I've got this: \documentclass{article} \usepackage{forest,tikz} \forestset{ ptree/.style={ for tree={ grow'=east, %grow' reverses direction of reading...for horizontal to the ...
610 views

### Line Break in Tikz Arrow Label

My goal is that, in the image shown below, that the label below appear on the line below above;, directly under above;. I've used \\ (and some other ideas) to try to achieve this (as shown in the ...
• 133
657 views

### TikZ: Placing a coordinate or node at end of edge

How can I place a node or coordinate at end of the edge? I expected this syntax: \draw (0,0) edge +(1,1) coordinate (x); Because the same syntax with the -- command, it works: \draw (0,0) -- +(1,1) ...
88 views

### drawing curved connectors within \foreach loop in a graph

I am trying to draw a graph on 216 vertices - 215 vertices distributed on a wheel around a fulcrum. Then I want to connect all the peripheral vertices to the fulcrum and join the vertices on the wheel ...
1 vote
146 views

### How do I make a graph with branching rectangular edges, labeled before branching?

This graph duplicates the label, and the edges are not vertical or horizontal. I would like a vertical edge to leave A, labeled 'x' then split into two right and left horizontal branches which would ...
• 299
222 views

### How to anchor fork separation in forest trees

In the process of creating a family tree using forest, I have used forked edge style in the main for tree{}. However when the children node texts vary in length, the parent node's fork loses it's ...
257 views

### positioning of the arrow text

The edge elements (the text) are not placed correctly on the right side (look at red circles). Is it possible to make them look like a mirror (compare to the left side)? Code of my edges: \...
• 325
64 views

### Colour arrows graphdrawing

I am using graphdrawing tikz to create a small tree. In the MWE below, I would like to have a blue arrow pointing to B1 and an orange arrow pointing to B2. How could I do this? \documentclass[tikz,...
• 105
144 views

### How can label an edge of a tree which was manually added?

One can use TikZ to create a tree manually , or use the forest package to make the process easier. Below I show how I can use the forest package to create a binary tree, and turn it into a recombinant ...
• 23
1k views

### How can I write text above the edges?

I have the following code to draw a graph with directed edges: \begin{tikzpicture} % vertices \node[vertex] (1) at (0,0) {$\times$}; \node[below left=1cm of 1] (A) {}; \node[below right=1cm of 1] (B) ...
• 113
65 views

### Horizontal edges crossing vertical edges

How can I draw the horizontal edges as shown of the picture below? My code is as below. Thank you. \documentclass[12pt]{book} \usepackage[paperwidth=16cm, paperheight=24cm]{geometry} \usepackage[T1]{...
• 591
114 views

### Is there a way in Tikz to draw a path specified by only two nodes avoiding regions in the drawing?

I want to connect a set of predefined nodes using a simple sintaxe like "\draw (SD00) -- (ED03);" using only the start and end nodes, instead of specifying a whole path through intermediate nodes. The ...
• 167
1 vote
91 views

### Adding extra lines to trees with forest [closed]

I have trying to draw trees using forest with consonants and vowels on different tiers. With help from Sašo Živanović I managed to do this as in (1) in the following MWE. I next wanted a tree with a ...
300 views

### edge labels with boundary in tikz

I have the following graph I am trying to replicate with Tikz. I am having trouble creating the square edge label containers. Is there an easy way to do this in tikz? EDIT I made a small example ...
769 views

### Drawing a 7-node polygon

I am trying to draw 7 nodes in the shape of a heptagon, I have found how to draw the heptagon, but I dont how how to label each node 1-7 and then how to draw edges between the nodes. \begin{...
1 vote
1k views

### Set another bend point for a tikz edge

On the left hand side you can see a tikz graph with a bend edge that is not placed really optimal. Is there a way to place the edge somewhat similar to the illustration on the right hand side. ...
• 453
297 views

### Multiple parallel edges with with a knee point in tikz

Is there an easy way to draw multiple parallel edges from one node to another with an knee point (two 90 degree turns) and equally distributed distance between the edges (not really perfect in the ...
116 views

### TikZ' Pic Syntax doesn't work with edge nodes

Eventually, I'd like to draw a picture inside of a node of a bigger picture. Since nesting tikzpictures is not recommended, I thought that the pic syntax provided a convenient alternative. However, ...
• 23
1 vote
200 views

### Avoid edges and labels overlapping automatically

I would like to avoid edges and labels overlapping. I have seen different solutions, but all of them need manual adjustments. However, I need to produce several graph like the one below and find it ...
• 41