Consider dilating the curve by a constant $c$. The moment of inertia of the dilated curve is proportional to $c^2$. The distance between the original curve and the dilated curve is proportional to $c-1$. What does this imply for the statement?
Edit: Okay, if we're not allowed to dilate the string, we can still change its curvature. Define a family of curves $\gamma_r$ for $r>0$ by
$$\gamma_r(s) = \left(r\cos(s/r), r\sin(s/r)\right).$$
Then you can check that $\gamma_r$ is as continuous as you need it to be, and the moment of inertia for any given length is a strictly increasing function of $r$; it has no local extrema.
There is no need for any calculus of variation. Ordinary calculus is enough.
For simplicity of derivation, we will use complex numbers to represent points on the plane.
Let $z(s) = x(s) + i y(s)$ and WOLOG, we will assume $z(0) = 0$. We can express the
position on our curve as an integral:
$$z(t) = \int_0^t z'(s)\;ds$$
Let $\theta(t) = \begin{cases} 1 & t > 0\\ 0 & t \le 0\end{cases}$ be the step function.
The center of mass is given by
$$\begin{align}z_{cm}
&= \frac{1}{L} \int_0^L z(t) dt
= \frac{1}{L} \int_0^L \int_0^t z'(s)\;ds\; dt\\
&= \frac{1}{L} \iint_{[0,L]^2} \theta(t-s) z'(s)\;ds\; dt
= \int_0^L \left(1-\frac{s}{L}\right) z'(s)\;ds
\end{align}
$$
The moment of inertia w.r.t. $z(0)$, the origin, is given by
$$\begin{align}
\mathcal{M}_0
&= \int_0^L |z(s)|^2 ds
= \int_0^L \left(\int_0^t z'(s_1)ds_1\right)\left(\int_0^t \bar{z}'(s_2) ds_2\right) dt\\
&=\iiint_{[0,L]^3} \theta(t-s_1)\theta(t-s_2) z'(s_1) \bar{z}'(s_2) ds_1 ds_2 dt\\
&=\iiint_{[0,L]^3} \theta(t-\max(s_1,s_2)) z'(s_1) \bar{z}'(s_2) ds_1 ds_2 dt\\
&= \iint_{[0,L]^2} \left(L - \max(s_1,s_2)\right) z'(s_1) \bar{z}'(s_2) ds_1 ds_2
\end{align}$$
and hence the moment of inertia w.r.t. the center of mass is
$$\mathcal{M}_{cm} = \mathcal{M}_0 - L |z_{cm}|^2 = L \iint_{[0,L]^2} \Lambda(s_1,s_2) z'(s_1) \bar{z}'(s_2) ds_1 ds_2$$
where
$$\begin{align}\Lambda(s_1,s_2)
&= 1 - \max\left(\frac{s_1}{L},\frac{s_2}{L}\right) - \left(1-\frac{s_1}{L}\right)\left(1-\frac{s_2}{L}\right)\\
&= \left( 1 - \max\left(\frac{s_1}{L},\frac{s_2}{L}\right)\right)\min\left(\frac{s_1}{L},\frac{s_2}{L}\right)
\end{align}$$
Since $|z'(s)| \equiv 1$ and $\Lambda(s_1,s_2) > 0$ for $(s_1,s_2) \in (0,L)^2$, we can bound $\mathcal{M}_{cm}$ as
$$\mathcal{M}_{cm} \le L \iint_{[0,L]^2} \Lambda(s_1,s_2) |z'(s_1)||z'(s_2)| ds_1 ds_2
= L \iint_{[0,L]^2} \Lambda(s_1,s_2) ds_1 ds_2$$
Notice the equality in above inequality is achieved when and only when $z'(s)$ is a constant.
We can conclude $\mathcal{M}_{cm}$ is largest for straight lines.
Best Answer
Here is a numerical solution. The parameters are taken as $A$,$B$,$C$,$M$,$K$,$c$. The equation of the arc is given by $$(y-C)^2+(x-B)^2=A^2$$ and for the line $$y=M\,x+K$$ The break-point is taken as $c$. Therefore the objective function to be minimized becomes $$F=\sum_1^n\bigg((y_i-F_{1,i})^2+(y_i-F_{2,i})^2\bigg)$$ $$F_{1,i}=-\sqrt{A^2-(x_i-B)^2}+C\qquad \text{if }x_i\le c\text{ and }0\text{ elsewhere}$$ $$F_{2,i}=M\,x_i+K\qquad \text{if }x_i>c\text{ and }0\text{ elsewhere}$$ The first constraint function assures that the arc and line meet at the break-point $c$ $$-\sqrt{A^2-(c-B)^2}+C-M\,c-K=0$$ The second constraint that the line is tangent to the arc at $c$ $$\frac{c-B}{\sqrt{A^2-(x-B)^2}}-M=0$$ And the last constraint is that the center of arc lies on a line given by $y=m_1x+k$ $$C-m_1\,B+k_1=0$$ To test the algorithm I generated 120 points and added error terms of $N(0,0.1)$ as given in below graph. The black dots are for circle with $A=3$, $B=1$, $C=4$; and the blue dots for line with $M=0.8944$, $K=-0.9193$. The break-point is given as $c=3$
In Matlab I used "fmincon" with "interior-point" algorithm. The initial guess is randomly generated as $[A=0.9045;B=0.8663;C=0.9225;M=0.5637;K=0.1863;c=0.6766]$. After 170 iterations the algorithm stopped convergent with objective function value of $1.16322$ and maximum constraint violation of $1.66\cdot 10^{-16}$. The parameters are found to be $$A=2.97\qquad B=0.99\qquad C=3.96\qquad M=0.88\qquad K=-0.88\qquad c=2.95$$ As you can see the calculated parameters are very close to the original parameters even though random error is added to the data. The final grap shows the data (red) and the calculated fitting function (blue)
-------------------ADDITION OF CODE------------------------
Please note that $A\rightarrow x(1)$, $B\rightarrow x(2)$, $C\rightarrow x(3)$, $M\rightarrow x(4)$, $K\rightarrow x(5)$, $c\rightarrow x(6)$
First the function file for objective function (save it as a seperate file as objfun.m)
As the second constraint equations (save it as a seperate file as constfun.m)
And the final one is main file (save it as m.file with any name in the same folder with objfun.m and constfun.m)
PS: If you have your own data set put x-data in variable X and y-data in Y_er. In addition put n= your number of data points. Hope it works for you.
PS2: Please modify your constraint "center of arc on a given line" in "constfun.m" in ceq(3).