An optimization problem in Euclidean Geometry - finding “the smallest” inscribed triangle

What is the smallest perimeter of a triangle that can be inscribed in a triangle with sides of lengths $5$, $9$, and $10$?

I have read that such a triangle has its vertices at the feet of altitudes from the three vertices of the given triangle. (I guess the given triangle must be an acute triangle.) What is an efficient computation for the location of the vertices of the inscribed triangle.

I would appreciate a link to a demonstration that the triangle with its vertices at the feet of altitudes from the three vertices of a given triangle is a triangle with the smallest perimeter that can be inscribed in it.

Suppose we have a triangle $\Delta ABC$ with $|AB| = c$, $|BC| = a$ and $|AC| = b$. Let $E$ be the foot lying on $AB$, so that $AB \perp EC$. Without loss of generality, assume $b \ge a$. Then \begin{align*} |AE|^2 + |EC|^2 &= |AC|^2 = b^2 \\ |BE|^2 + |EC|^2 &= |BC|^2 = a^2 \\ |AE| + |BE| &= |AB| = c \end{align*} Subtracting the first two equations, we obtain $$b^2 - a^2 = |AE|^2 - |BE|^2 = (|AE| - |BE|)(|AE| + |BE|)$$ Using this with the third equation gives us $$b^2 - a^2 = c(|AE| - |BE|) \implies |AE| - |BE| = \frac{b^2 - a^2}{c}.$$ Using the third equation again allows us to solve for $|AE|$, in particular, $$2|AE| = c + \frac{b^2 - a^2}{c} \implies |AE| = \frac{b^2 + c^2 - a^2}{2c}.$$ (Note the not-so-subtle or coincidental resemblance to the law of cosines!) So, for example, if we wish to find the position of the foot on the length $5$ edge, we have $c = 5$, $b = 10$, and $a = 9$ (so chosen to preserve $b \ge a$). Thus, we have $$|AE| = \frac{10^2 + 5^2 - 9^2}{2 \cdot 5} = \frac{22}{5}.$$ The point $A$ is incident on the edges of length $5$ and length $10$. The foot along the length $5$ edge is $\frac{22}{5}$ distance from this point (and $\frac{3}{5}$ distance from the other point).