5. (FRA 2) A circle of radius 1 is located in a right-angled trihedron and touches all its faces. Find the locus of centers of such circles.
5. Let $O$ be the vertex of the trihedron, $Z$ the center of a circle $k$ inscribed in the trihedron, and $A, B, C$ points in which the plane of the circle meets the edges of the trihedron. We claim that the distance $O Z$ is constant. Set $O A=x, O B=y, O C=z, B C=a, C A=b, A B=c$, and let $S$ and $r=1$ be the area and inradius of $\triangle A B C$. Since $Z$ is the incenter of $A B C$, we have $(a+b+c \overrightarrow{O Z}=a \overrightarrow{O A}+b \overrightarrow{O B}+\overrightarrow{O C}$. Hence
$$
(a+b+c)^{2} O Z^{2}=(a \overrightarrow{O A}+b \overrightarrow{O B}+\infty \overrightarrow{O C})^{2}=a^{2} x^{2}+b^{2} y^{2}+c^{2} z^{2} .
$$

But since $y^{2}+z^{2}=a^{2}, z^{2}+x^{2}=b^{2}$ and $x^{2}+y^{2}=c^{2}$, we obtain $x^{2}=\frac{-a^{2}+b^{2}+c^{2}}{2}, y^{2}=\frac{a^{2}-b^{2}+c^{2}}{2}, z^{2}=\frac{a^{2}+b^{2}-c^{2}}{2}$. Substituting these values in (1) yields
$$
\begin{aligned}
(a+b+c)^{2} O Z^{2} & =\frac{2 a^{2} b^{2}+2 b^{2} c^{2}+2 c^{2} a^{2}-a^{4}-b^{4}-c^{4}}{2} \\
& =8 S^{2}=2(a+b+c)^{2} r^{2}
\end{aligned}
$$

Hence $O Z=r \sqrt{2}=\sqrt{2}$, and $Z$ belongs to a sphere $\sigma$ with center $O$ and radius $\sqrt{2}$.
Moreover, the distances of $Z$ from the faces of the trihedron do not exceed 1 ; hence $Z$ belongs to a part of $a$ that lies inside the unit cube with three faces lying on the faces of the trihedron. It is easy to see that this part of $\sigma$ is exactly the required locus.