Episode #125 of the Stack Overflow podcast is here. We talk Tilde Club and mechanical keyboards. Listen now

Questions tagged [intersections]

For questions about calculating intersections using {tikz-pgf} or {pgfplots}, including PGF's intersections library.

209 questions
Filter by
Sorted by
Tagged with
35 views

Use named paths inside a scope for intersections outside the scope?

I need to: draw an ellipse, name it so I can intersect it later, clip it. To accomplish 3, it seems most appropriate to use a scope, but this means that I cannot accomplish 2. Consider this MWE: \...
58 views

Clipping an horizontal line in a bell shaped curve

In this figure there are two horizontal lines which I have tried to adjust to the ends of these lines to the bell shaped data curves, \documentclass[border=0.5mm]{standalone} \usepackage{amsmath} \...
61 views

Naming line intersection and using it later

I have drawn tangents to my ellipse, and I would like to find the intersections of those tangents and connect them into a line. I know how to make that line, but I don't know how to get those ...
76 views

dash path between two intersections with other path

I wish to dash the red path when it is between the intersections with the blue path. How can I do this using paths names? \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{intersections} \...
52 views

Create intersect for Venn diagram and resize circles to adjust to box size

Problem: Two minor issues which I have not been able to solve. How do I fill the intersection for the second figure (on the right)? How do I create "padding" or more "air" around the circles in each ...
50 views

Create dashed intersections with labels using pgfplots and tikz

Problem: I have several minor issues that I can not seem to be able to solve. Add and position labels to x/y-axis Add dashed intersections Show x/y-axis numbers for -1 and 1 Minimal Working Example ...
47 views

How to add horizontal, then vertical shorts in circuitikz

I've noticed that in circuitikz, while the regular tikz lines of horizontal-then-vertical (-|) and vertical-then-horizontal (|-) lines work fine when joining two items with different absolute ...
21 views

Sequence of TiKz intersection points [duplicate]

To get intersection points of help lines and a line, I wrote the following code. \documentclass[margin=3mm]{standalone} \usepackage{tikz} \usetikzlibrary{positioning,intersections} \begin{document} ...
37 views

tikz can not find the intersection [duplicate]

Hello I do not understand why tikz can not find the intersection of the curve and the right? thank you \documentclass[border=5mm]{standalone} \usepackage{tikz} \usetikzlibrary{calc,intersections} [!...
290 views

How to draw with Tikz a chord parallel to AC that passes through a point?

I've drawn the following diagram with Tikz: The code used: \documentclass{standalone} \usepackage{pgf,tikz} \usetikzlibrary{babel,calc,arrows,shapes.geometric,intersections,through,backgrounds} \...
37 views

Labeling distinct points of a line and circle using “intersections package”

The following code renders five circles, each circle intersecting one or two other circles, and a line segment PQ. Line segment PQ intersects each circle twice. How do I label the intersection of the ...
49 views

Automatically draw nodes at all intersections (for graph crossings)

I use TikZ to draw (undirected) graphs, but sometimes I would like to be able to mark where all the intersections/crossings are automatically. I understand that the TikZ intersections library has the ...
156 views

Finding the intersection of two circles

I am attempting to use pair[] intersectionpoints to find and label the intersection points of the circles defined by path h and path g. Thanks for the help. \documentclass{standalone} \usepackage{...
151 views

Colouring of intersection of four circles with TikZ

I want to selectively fill intersection of four circles as shown below. I was able to make some of the intersections correctly but not able to figure out how to make the remaining ones. Here is the ...
62 views

The Area of a Region Bounded by Two Graphs

I am looking for a more professional program from that here below. I believe I can name the curves and have TiKz calculate the points of intersections instead of finding them with a pen and paper. I ...
368 views

What is the meaning of option 'by' in TikZ Intersections

Pg 65 of the PGF Manual, shows different operations with the intersections library in TikZ. But I am not able to understand the code. What is the meaning of the option by here. The explanation given ...
58 views

Named paths inside a tikz/pic

I am trying to understand the naming behavior of paths inside a pic definition. Consider the following \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{intersections} \tikzset{% ...
132 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 ...
190 views

How to fill a solid defined by x^2+y^2<=9, z<=16-x^2-y^2 and z>=0 using PGFPlots

I would like to draw the body D defined by x^2+y^2<=9, z<=16-x^2-y^2 and z>=0. We have to graph x^2+y^2=9, z=16-x^2-y^2 and z=0 with less opacity, and then fill (or use patterns) the ...
402 views

Using functions like sine, cosine and tangent to calculate coordinates in Tikz

I am learning TikZ with the pgfmanual. The example given is as follows: I have achieved the following so far: The code is as follows: \documentclass{article} \usepackage{tikz} \tikzset{help lines/....
118 views

Intersection library and Differential approximations

Hi everyone I am looking for a smoother program using the intersection library to calculate where the tangent line intersects the vertical line of the x-coordinate of the second coordinate. I have so ...
203 views

How to create a vertex at the intersection of two edges with tkz-graph?

I want to draw But I don't know how to create v_6 which is the intersection of \Edge(v_3)(v_5) & \Edge(v_1)(v_4) and v_7 is the intersection of \Edge(v_3)(v_5) & \Edge(v_2)(v_4). Here the ...
92 views

Trouble with the intersection of 3 planes

I am trying to make a 3d plots as follows. This is my MWE: ‎\begin{tikzpicture}‎ ‎\begin{axis}[xlabel=$x$‎, ‎ylabel=$y$‎, ‎zlabel={$z$},legend pos=outer north east,z post scale=1.1,grid=both,view={50}...
188 views

Intersection of a circle and a line “path”

\documentclass{standalone} \usepackage{tikz} \usetikzlibrary{intersections} \begin{document} \begin{tikzpicture}[ plotmark/.style = {% solid, fill = red, circle, inner sep = 0pt, minimum size =...
31 views

Problem With Horizontal tangent

I am trying to figure why the tangent to the right looks slightly tilted whereas the other to the left is doing what it is suppose to do? \documentclass{article} \usepackage{tikz} \usetikzlibrary{...
66 views

Color ellipse intersection

I try to color the interception of two ellipses as simple as possible. I found some examples here: Draw ellipses with different coloring for their intersection in tikz? But I'm not sure how to ...
66 views

filling segments by intersection method: there is no named path called

I'm just trying to fill each peripheral segment of my drawing. The names of the hexagon and the circle are test and circ. Additionally, the line pieces connecting edges of the hexagon to the outer ...
49 views

Tangent Lines Intersecting Curves

Why I am only getting one point of intersection read by the program? Solution is to breaking to two parts with tangent lines drawn at different lengths. \documentclass{article} \usepackage{tikz} \...
557 views

Tangent Lines Diagram Along Smooth Curve

I am trying to replicate a diagram and have a minimal example. I don't know how to add additional tangents between the specified points and preserve smoothness. \documentclass{article} \usepackage{...
86 views

Finding an intersection with respect to the decoration

in Naming nodes in a decoration and draw lines from node to node I asked a question, which was answered. The most help was the following. \documentclass[tikz,border=3.14mm]{standalone} \...
51 views

Naming nodes in a decoration and draw lines from node to node

thanks for taking the time. I have the problem, that I want to get normal vectors on a smooth plot, furthermore I have lines intersecting said plot, but they also need to end in the graph. My approach ...
484 views

Tikz name path problems: No shape names is known

I seem to struggle already with the simplest use case of name path in Tikz: \documentclass{article} \usepackage{tikz} \usetikzlibrary{intersections} \begin{document} \begin{tikzpicture} ...
296 views

Problem with intersections: No shape named intersection-1 is known

When I compile the following code I get the error Package pgf Error: No shape named intersection-1 is known. How can I fix it? \documentclass[tikz,border=5mm]{standalone} \usetikzlibrary{...
64 views

Drawing path from intersection of two paths to origin of those two intersecting paths

I have two paths which are to be drawn with dotted lines (shown in figure) and they intersect at some point C. Now I need to draw a resultant path of these two paths with solid lines. The resultant ...
86 views

Interactions between intersections, fillbetween and axis equal

Please be patient, this is a bit complex. I encountered some weird things when trying to answer this nice question. Start with the MWE \documentclass[tikz,border=3.14mm]{standalone} %\usetikzlibrary{...
69 views

foreach and intersection

what's wrong with my code? The usage of the foreach loop instead of the direct draw commands leads to an error that the path is not known. Do you have any suggestions? Thanks a lot in advance! ! ...
40 views

Tikz - Use two coordinates in single command

MWE: \documentclass{article} \usepackage{tikz} \usetikzlibrary{calc,intersections,through,backgrounds,matrix,patterns} \begin{document} \begin{tikzpicture} \draw[<->] (0,8)--(0,0)--(...
60 views

Tikz \path command - use second intersection

I am aiming to produce the following diagram: Here's an MWE which almost does that: \documentclass[11pt]{article} \usepackage{tikz} \usetikzlibrary{calc,intersections,through,backgrounds,matrix,...
713 views

How to fill space between dotted lines in tikz picture?

I'm trying to fill an area between two dotted lines. I tried a lot of options, but none of them seem to work. I labeled the areas I need with the specific colors to fill. My current code is: \...
208 views

Arrows at intersection in TikZ

I want to have the arrow tips on the intersection between the rectangle and the lines. Here I've got a M(N)WE: \documentclass[border=5pt,tikz]{standalone} \usetikzlibrary{intersections} \begin{...
207 views

Draw feasible region between constraints (TikZ and pgf) [closed]

I'm trying to shade the feasible region ABCDE but for some reason, only get a weird line. This is the code: \begin{tikzpicture} % axes \begin{axis}[axis on top,smooth, axis line style=very thick, ...
495 views

How to draw intersect of line sphere?

How to draw intersect of line sphere?
118 views

Visibility of path names declared in \foreach loops

Buildup Basic setting Using the intersection library, I encountered some behaviour of path names that I do not understand. The following works in the intended way: \documentclass{scrartcl} \...
132 views

PGFplots: extract coordinates, assign to global with dynamic name

I would like to loop over nodes, extract their coordinates in the axis coordinate system, and assign these to dynamically named macros. (This is a followup on this and this.) Following this answer, I ...
116 views

Problem with fillbetween pgfplots library and intersections

In this MWE \documentclass[11pt, oneside, landscape]{article} \usepackage{pgfplots} \pgfplotsset{compat=newest} \usetikzlibrary{ calc, intersections, } \usepgfplotslibrary{fillbetween} \...
348 views

No shape named … is known

For this error I can not find a correct answer %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % Welcome to Overleaf --- just edit your LaTeX on the left, % and we'...
209 views

Shading Circle Segments in a complex Venn diagram

I have a Venn diagram with some overlapping ellipses that I segmented into sections using lines. I want to use this to make a few figures, and I am wondering wether there is a clever / clean way to ...
88 views

I ran into the following problem: Constructing a path using "plot", I fail to find intersections that fall exactly onto the coordinates used to construct that path. In the example below, the 2nd ...