20. How to construct a point $S$ on a plane so that the sum of the squares of its distances to the vertices of a given polygon $A_{1} A_{2} \ldots A_{n}$ is the smallest? (U. 124, R. 186.)

Application of Lagrange's theorem to proving inequalities. Let there be a system of $n$ material points (with positive masses) $\left(A_{1}, m_{1}\right),\left(A_{2}, m_{2}\right), \ldots$ $\ldots,\left(A_{n}, m_{n}\right) ; Z$ - its center of mass, $S$ - an arbitrary point in space. Then, by Lagrange's theorem,

$$
J_{S}=J_{Z}+M \cdot S Z^{2}
$$

where

$$
\begin{aligned}
& J_{S}=m_{1} \cdot S A_{1}^{2}+m_{2} \cdot S A_{2}^{2}+\ldots+m_{n} \cdot S A_{n}^{2} \\
& J_{Z}=m_{1} \cdot Z A_{1}^{2}+m_{2} \cdot Z A_{2}^{2}+\ldots+m_{n} \cdot Z A_{n}^{2} \\
& M=m_{1}+m_{2}+\ldots+m_{n} .
\end{aligned}
$$

From (48) it is clear that always

$$
J_{z} \geqslant 0
$$

and equality in (50) is possible only when all points $A_{1}, A_{2}, \ldots, A_{n}, Z$ coincide. Therefore, by (46)

$$
M \cdot S Z^{2} \leqslant J_{S}
$$

and equality holds only in the case when all points $A_{1}, A_{2}, \ldots, A_{n}$ coincide. Inequality (51) shows that the moment of inertia of a system of material points decreases when the entire mass of the system is concentrated at its center of mass.

By choosing different points $A_{1}, A_{2}, \ldots, A_{n}, S$ and the masses placed in them, we can obtain some remarkable inequalities.

Consider a few examples.
20. Let $Z$ be the center of gravity of $n$ material points $\left(A_{1}, 1\right),\left(A_{2}, 1\right), \ldots,\left(A_{n}, 1\right)$. For any position of point $S$

$$
J_{S}=J_{Z}+n \cdot S Z^{2}
$$

where $J_{S}=S A_{1}^{2}+S A_{2}^{2}+\ldots+S A_{n}^{2}$. In formula (1), $J_{Z}$ does not depend on the position of point $S$ on the plane.

It is clear that the minimum value of the sum $J_{S}$ will be achieved if and only if the non-negative term $n \cdot S Z^{2}$ becomes zero, i.e., when $S \equiv Z$.

Thus, the desired point is the center of gravity of $n$ material points $\left(A_{1}, 1\right),\left(A_{2}, 1\right), \ldots,\left(A_{n}, 1\right)$, and such a point can be easily constructed with a compass and a straightedge.