1

How could I draw three tangent circles, using tikz or tkz-euclide, like in the following picture?

three tangent circles

The biggest circle should have radius 5 cm, the other two can have whatever radius, but less than 2.5 cm. I've managed to draw two tangent circles, but I cannot figure out how to draw the third circle, which should be tangent to the other two. Here is what I've already done:

\documentclass{standalone}
 \begin{document}
  \begin{tikzpicture}
    \tkzDefPoints{0/0/B, 4/1/C}
    \tkzDrawCircle[R](C,5cm)
    \tkzInterLC[R](B,C)(C,5cm) \tkzGetPoints{D}{E}
    \tkzDrawCircle(B,D)
  \end{tikzpicture}
\end{document}

Many thanks in advance

4

The centers of the circles are at intersections of auxiliary circles around the other circles where the radii of the auxiliary circles are given by the original radii plus the radius of the new circle.

\documentclass[tikz,border=3mm]{standalone}
\usetikzlibrary{intersections}
\begin{document}
\begin{tikzpicture}[dot/.style={circle,fill,inner sep=1pt},
    declare function={R=5;rA=1.5;rB=1;rC=1.3;}]
 \draw (0,0) coordinate(O) circle[radius=R];
 \draw (160:R-rA) node[dot,label=20:$A$](A){} circle[radius=rA];
 \path[overlay,name path=auxB1] (O) circle[radius=R-rB]; 
 \path[overlay,name path=auxB2] (A) circle[radius=rA+rB]; 
 \draw[name intersections={of=auxB1 and auxB2,by={aux,B}}]
  (B) node[dot,label=above:$B$]{}  circle[radius=rB];
 \path[overlay,name path=auxC1] (A) circle[radius=rA+rC]; 
 \path[overlay,name path=auxC2] (B) circle[radius=rB+rC]; 
 \draw[name intersections={of=auxC1 and auxC2,by={aux,C}}]
  (C) node[dot,label=above:$C$]{}  circle[radius=rC];
\end{tikzpicture}
\end{document}

enter image description here

Of course, no library is needed for this, only the cosine law which tells us the angles of a triangle with given edge lengths.

\documentclass[tikz,border=3mm]{standalone}
\begin{document}
\begin{tikzpicture}[dot/.style={circle,fill,inner sep=1pt},
    declare function={R=5;rA=1.5;rB=1;rC=1.3;alpha=160;
    cosinelaw(\a,\b,\c)=acos((\a*\a+\b*\b-\c*\c)/(2*\a*\b));}]
 \draw (0,0) coordinate(O) circle[radius=R];
 \draw (alpha:R-rA) node[dot,label=alpha-180:$A$](A){} circle[radius=rA];
 \draw ({-cosinelaw(R-rA,R-rB,rA+rB)+alpha}:R-rB) 
    node[dot,label=above:$B$](B){}  circle[radius=rB];
 \pgfmathsetmacro{\myturn}{cosinelaw(rA+rB,rC+rB,rC+rA)-180}    
 \path (A) -- (B) -- ([turn]\myturn:rB+rC)
  node[dot,label=above:$C$](C){};
 \draw (C) circle[radius=rC]; 
\end{tikzpicture}
\end{document}

enter image description here

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.