\documentclass{book}
\usepackage{tikz}
\usetikzlibrary{intersections}
\usetikzlibrary{calc}
\begin{document}
\begin{tikzpicture}
\draw[dotted](-10,-5) grid (5,5);
\path(0,0) node{0};
\draw(-10,0)--(5,0);
\coordinate(I')at(-2,2);
\coordinate(F'1)at(4,0);
\coordinate(F2)at(-3,0);
\draw[name path=D2](0,-5)--(0,5);
\draw(-9,2)--(I') node {};
\draw[name path=1'](I')--(F'1) node {};
\fill[red,name intersections={of=1' and D2,by={U'}}](intersection-1) circle(2pt);
\draw[shorten <=-5.5cm,name path=2'](F2)--+($(I')-(F'1)$) node {Y};
%so far so good, the intersection is at the right location (0,1.3)
\fill[green,name intersections={of=2' and D2,by={X}}](intersection-1) circle (1pt);
%here is the problem : the green circle is also located where the red circle (first intersection) is instead of (0,-1)
\end{tikzpicture}
\end{document}
|
|
|||||
|
|
The extension of You have to change your path
or
Code:
|
|||||
|

