A circle of radius $r$ is inscribed into a triangle. A circle of radius $r$ is inscribed into a triangle $ABC$. Tangent lines to this circle parallel to the sides of the triangle cut out three smaller triangles, $\triangle A_cB_cC$, $\triangle A_bBC_b$, $\triangle AB_aC_a$. The radii of the circles inscribed in these smaller triangles are equal to $1$, $2$ and $3$, respectively. Find $r$.
I have no idea how to start...

 A: Consider triangle ABC, A as top vertex, B the right on and C the left. let;s denote the heights as $h_a$ , $h_b$ and $h_c$, and the radii of circles $r_a=1$, $r_b=2$ and $r_c=3$ and unknown radius as $r$ . The triangles created by tangents to circles and parallel to bases are similar to main triangle, let't denote the heights of these triangles as $h'_a$. $h'_b$ and $h'_c$; we may write:
$\frac{r_a}{r}=\frac{h'_a}{h_a}$ 
$h_a=2r+h'_a$ .
Therefore:
$h_a=2r+\frac{r_ah_a}{r}$
Which gives:
$2r^2-rh_a +h_a=0 $
Similarly we get:
$2r^2-rh_b +2h_b=0 $
$2r^2-rh_c +3h_c=0 $
Now we this statement: If three perpendiculars from a point inside a triangle are droped on the sides (here the radii of circle r) we have:
$\frac{r}{h_a} +\frac{r}{h_b}+\frac{r}{h_c}=1$
Now we have a system of four equations for four unknown $h_a,. h_b,.h_c $ and $r$. Solving this system will give you r. Wolfram alpha gives $r=6, h_a=14.5, h_b=18, h_c=24$. If we use  generalized Descartes theorem and assume the sides of triangle circles with radius infinity, where $k_s=\frac{1}{∞}=0$ will be the curvature of sides we have:
$(\frac{1}{1}+\frac{1}{2}+\frac{1}{3}+0+\frac{1}{r})^2=2(\frac{1}{1^2}+\frac{1}{2^2}+\frac{1}{3^2}+0+\frac{1}{r^2})$
It finally results in:
$23 r^2+132r-36=0$
Which gives $r=6$ 
A: 
Let $|CE|=H_c$ and $|CD|=h_c$ be the altitudes
of similar triangles $\triangle ABC$ and $\triangle A_cB_cC$.
Then
\begin{align}
\frac{|CD|}{r_c}
&=
\frac{|CE|}{r}
\tag{1}\label{1}
,\\
\frac{H_c-2r}{r_c}
&=
\frac{H_c}{r}
\tag{2}\label{2}
,\\
H_c &= \frac{2r^2}{r-r_c}
\tag{3}\label{3}
.
\end{align}
Similarly, two other altitudes of  $\triangle ABC$
in terms of $r,r_a,r_b$ are
\begin{align}
H_a &= \frac{2r^2}{r-r_a}
\tag{4}\label{4}
,\\
H_b &= \frac{2r^2}{r-r_b}
\tag{5}\label{5}
,
\end{align}
and we can apply a well-known relation
\begin{align}
\frac1r&=
\frac1{H_a}+\frac1{H_b}+\frac1{H_c}
\tag{6}\label{6}
\end{align}
to find out that $r$ in terms of $r_a,r_b,r_c$ is just
\begin{align}
r&=r_a+r_b+r_c
\tag{7}\label{7}
.
\end{align}
The original question would be solved by now,
but we can do more than that: we can completely solve the $\triangle ABC$.
Using known  Heron-like formula for the area, we have
\begin{align}
S&=
\frac1{\sqrt{
{(\tfrac1{H_a}+\tfrac1{H_b}+\tfrac1{H_c})}
{(-\tfrac1{H_a}+\tfrac1{H_b}+\tfrac1{H_c})}
{(\tfrac1{H_a}-\tfrac1{H_b}+\tfrac1{H_c})}
{(\tfrac1{H_a}+\tfrac1{H_b}-\tfrac1{H_c})}
}}
\\
&=\frac{r^{7/2}}{\sqrt{r_a r_b r_c}}
\tag{8}\label{8}
.
\end{align}
Next, we can find the semiperimeter $\rho$
and circumradius $R$ of $\triangle ABC$:
\begin{align}
\rho&=\frac Sr
=\frac{r^{5/2}}{\sqrt{r_a r_b r_c}}
\tag{9}\label{9}
,\\
R&=
\frac{2\,S^2}{H_a H_b H_c}
=\tfrac14\,\frac{r(r-r_a)(r-r_b)(r-r_c)}{r_a r_b r_c}
\tag{10}\label{10}
.
\end{align}
Now we are ready to find the three side lengths of $\triangle ABC$
as the roots of cubic equation in terms of $\rho,r,R$:
\begin{align}
x^3-2\rho\,x^2+(\rho^2+r^2+4\,r\,R)\,x-4\,\rho\,r\,R&=0
\tag{11}\label{11}
.
\end{align}
In particular, for $r_a=1,\ r_b=2,\ r_c=3$ we have
\begin{align}
r&=6
,\quad
S=216
,\quad
\rho=36
,\quad
R=15
\tag{12}\label{12}
,
\end{align}
\eqref{11} becomes
\begin{align}
x^3-72\,x^2+1692\,x-12960&=0
\tag{13}\label{13}
\end{align}
with three roots $\{18,\, 24,\, 30\}$,
that is, the sought triangle is
the famous $3-4-5$ right-angled triangle,
scaled by $6$.
Note that the side lengths
are inversely proportional to corresponding radii of incircles.
For another example, the picture illustrates
a solution for $r_a=7,\ r_b=5,\ r_c=3$.
In this case we have $r=15$ and the side lengths are
\begin{align}
a&=\tfrac{120\sqrt7}7
,\quad
b=\tfrac{150\sqrt7}7
,\quad
c=\tfrac{180\sqrt7}7
\tag{14}\label{14}
.
\end{align}

Edit
In fact, solution of the cubic equation \eqref{11}
is unnecessary: since the area and the altitudes are known,
the side lengths can be found explicitly as
\begin{align}
a&=r\,(r-r_a)\,\sqrt{\frac{r}{r_a\,r_b\,r_c}}
\tag{15}\label{15}
,\\
b&=r\,(r-r_b)\,\sqrt{\frac{r}{r_a\,r_b\,r_c}}
\tag{16}\label{16}
,\\
c&=r\,(r-r_c)\,\sqrt{\frac{r}{r_a\,r_b\,r_c}}
\tag{17}\label{17}
.
\end{align}
