为什么这个例子只起到部分作用?
\documentclass{minimal}
\usepackage{etex}
\usepackage{tikz}
\usetikzlibrary{shapes,calc,arrows,trees,positioning,through,intersections,fadings}
\begin{document}
\begin{tikzpicture}[scale=0.5]
\coordinate (a) at (0,0);
\coordinate (b) at (6,0);
\coordinate (c) at (9,6);
\node(A)[label=$A$] at (a) {$\bullet$};
\node(B)[label=50:$B$] at (b) {$\bullet$};
\node(C)[label=$C$] at (c) {$\bullet$};
\draw[thick] (a)--(b)--(c)--cycle;
% \node(c1) at (a)[draw,circle through=(b)] {};
% \coordinate(ac) at(intersection 1 of c1 and a--c);
%
% \node(c2) at (ac)[draw,circle through=(b)] {};
% \node(c3) at (b)[draw,circle through=(ac)] {};
% \coordinate(bta) at(intersection 1 of c2 and c3 );
% \node(xx)[label=$C$] at (bta) {$\bullet$};
% \coordinate(bisa) at(intersection 1 of a--bta and b--c);
% \draw (a)--(bisa);
%%%%%%%%%%%%%%%%%%%%%%%%%%% work %%%%%%%%%%%%%%%%%%
\node(c4) at (b)[draw,circle through=(a)] {};
\coordinate(bc) at(intersection 1 of c4 and b--c);
\node(xx)[label=$prova$] at (bc) {$\bullet$};
\node(c5) at (bc)[draw,circle through=(a)] {};
\node(c6) at (a)[draw,circle through=(bc)] {};
\coordinate(btb) at(intersection 1 of c5 and c6 );
\node(xx)[label=$prova$] at (btb) {$\bullet$};
\coordinate(bisb) at(intersection 1 of b--btb and a--c);
\draw (b)--(bisb);
%%%%%%%%%%%%%%%%%%%%%%%%%%% work %%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%% it doesn't work%%%%%%%%%%%%%%%%%%
\node(c7) at (c)[draw,circle through=(b)] {};
\coordinate(ac) at(intersection 2 of c7 and a--c);
\node(xx)[label=$prova2$] at (ac) {$\bullet$};
%%%%%%%%%%%%%%%%%%%%%%%%%%% it doesn't work %%%%%%%%%%%%%%%%%%
\end{tikzpicture}
\end{document}
答案1
首先,我认为最好使用带有等的新语法path name
,name intersections
就像在 Euclide 的 pgf 2.1 教程中一样。
(c)--(a)
而不是(a)--(c)
解决问题。
\documentclass{minimal}
\usepackage{etex}
\usepackage{tikz}
\usetikzlibrary{shapes,calc,arrows,through,intersections}
\begin{document}
\begin{tikzpicture}[scale=0.5]
\coordinate (a) at (0,0);
\coordinate (b) at (6,0);
\coordinate (c) at (9,6);
\node(A)[label=$A$] at (a) {$\bullet$};
\node(B)[label=50:$B$] at (b) {$\bullet$};
\node(C)[label=$C$] at (c) {$\bullet$};
\draw[thick] (a)--(b)--(c)--cycle;
%%%%%%%%%%%%%%%%%%%%%%%%%%% work %%%%%%%%%%%%%%%%%%
\node(c4) at (b) [draw,circle through=(a)] {};
\coordinate(bc) at (intersection 1 of c4 and b--c);
\node(xx) at (bc) {\color{red}$\bullet$};
\node(c5) at (bc)[draw,circle through=(a)] {};
\node(c6) at (a)[draw,circle through=(bc)] {};
\coordinate(btb) at(intersection 1 of c5 and c6 );
\node(xx) at (btb) {\color{green}$\bullet$};
\node(bisb) at (intersection 1 of b--btb and a--c){\color{blue}$\bullet$};
\draw[dashed] (b)--(bisb);
%%%%%%%%%%%%%%%%%%%%%%%%%%% work %%%%%%%%%%%%%%%%%%
\node(c7) at (c)[draw,circle through=(b)] {};
\coordinate(ac) at (intersection 1 of c7 and c--a);
\node(xx) at (ac) {\color{orange}$\bullet$};
\end{tikzpicture}
\end{document}
更新
使用更新的语法,代码变为
\documentclass{minimal}
\usepackage{etex}
\usepackage{tikz}
\usetikzlibrary{shapes,calc,arrows,through,intersections}
\begin{document}
\begin{tikzpicture}[scale=0.5]
\tikzset{mark coordinate/.style={inner sep=0pt,
outer sep=0pt,
minimum size=3pt,
fill=#1,
circle}
}
\draw[thick] (0,0) coordinate [mark coordinate=black,label=$A$] (a) --
(6,0) coordinate [mark coordinate=black,label=50:$B$] (b) --
(9,6) coordinate [mark coordinate=black,label=$C$] (c) -- cycle ;
\node [name path=Circle1,draw,circle through=(a)] at (b) {};
\path [name path=BC] (b) -- (c);
\path [name intersections={of=BC and Circle1, name=i}]
(i-1) coordinate [mark coordinate=red];
\node [name path=Circle2,draw,circle through=(a)] at (i-1) {};
\node [name path=Circle3,draw,circle through=(i-1)] at (a) {};
\fill [name intersections={of=Circle2 and Circle3, name=j}]
(j-1) coordinate [mark coordinate=green];
\path [name path=AC] (a) -- (c);
\path [name path=Bj-1] (b) -- (j-1);
\fill [name intersections={of=Bj-1 and AC, name=k}]
(k-1) coordinate [mark coordinate=blue];
\draw [red] (b)--(k-1);
\node [name path=Circle4,draw,circle through=(b)] at (c) {};
\fill [name intersections={of=Circle4 and AC, name=l}]
(l-1) coordinate [mark coordinate=orange];
\end{tikzpicture}
\end{document}