In redrawing a geometric figure with TikZ, it seems that some wrong calculation in tkz-euclide with incircles (the red color below). The command
\tkzDrawCircle[in,color=red](A2,B2,C2)
give different circles when I change the order, such as (C2,B2,A2). Morover, a blank before (A2,B2,C2)
\tkzDrawCircle[in,color=red] (A2,B2,C2)
results an error.
Can you give some explanation/suggestion/improvement ?
\documentclass[tikz,border=5mm]{standalone}
\usetikzlibrary{calc}
\usepackage{tkz-euclide}
\usetkzobj{all}
\def\a{3} % side of the equilateral triangle
\pgfmathsetmacro{\d}{\a/sqrt(3)}
\begin{document}
\begin{tikzpicture}[line join=round]
\pagecolor{yellow!20}
\path
(210:\d) coordinate (A0)
(330:\d) coordinate (B0)
(90:\d) coordinate (C0)
($(C0)!.3!(B0)$) coordinate (A1)
($(A0)!.3!(C0)$) coordinate (B1)
($(B0)!.3!(A0)$) coordinate (C1)
(intersection of A0--A1 and B0--B1) coordinate (A2)
(intersection of B0--B1 and C0--C1) coordinate (B2)
(intersection of C0--C1 and A0--A1) coordinate (C2);
\clip (A0)--(B0)--(C0)--cycle;
\draw[cyan]
(A0)--(A1) (B0)--(B1) (C0)--(C1)
(A0)--(B0)--(C0)--cycle;
\draw (A2)--(B2)--(C2)--cycle;
\tkzDrawCircle[in,color=blue](A0,B0,A2)
\tkzDrawCircle[in,color=blue](B0,C0,B2)
\tkzDrawCircle[in,color=blue](C0,A0,C2)
\tkzDrawCircle[in,color=red](A2,B2,C2)
%\tkzDrawCircle[in,color=red](C2,B2,A2)
%\tkzDrawCircle[in,color=red](B2,A2,C2)
\end{tikzpicture}
\end{document}



tkz-euclide. This leaves us with the situation in which you are (almost, i.e. up to the above-mentioned issues) fine if you know French and less so if you don't. In principle one can do everything withcalcbut this requires one sometimes to punch in formulae and, what is worse, find out by trial and error which solution is most stable. – May 02 '19 at 23:35\tikzset{incircle/.style n args={3}{% insert path={ let \p1=($(#2)-(#1)$), \p2=($(#3)-(#1)$),\p3=($(#2)-(#3)$), \n1={0.5*(veclen(\x1,\y1)+veclen(\x2,\y2)+veclen(\x3,\y3))}, \n2={sqrt(((\n1-veclen(\x1,\y1))/\n1))*sqrt((\n1-veclen(\x2,\y2))*(\n1-veclen(\x3,\y3)))}, \n3={veclen(\x1,\y1)}, % length #1 -- #2 \n4={veclen(\x2,\y2)}, % length #1 -- #3 \n5={veclen(\x3,\y3)}, % length #2 -- #3 \n6={\n3+\n4+\n5} in \pgfextra{\xdef\BlackMildRadius{\n2}} (${(\n5/\n6)}*(#1)+{(\n4/\n6)}*(#2)+{(\n3/\n6)}*(#3)$) coordinate (incenter) circle (\n2) }}}– Jun 19 '19 at 16:02\draw[red,dashed] (incenter) circle[radius=\BlackMildRadius];after a blue circle. – Jun 19 '19 at 16:03