Does the centroid depend continuously on the curve?

Let $\gamma$ be a piecewise smooth curve in $\mathbb{R}^n$. Recall that the centroid of $\gamma$ is the point $(\overline{x}, \overline{y})$ where $\overline{x}$ is the average value of $x$ on $\gamma$ and $\overline{y}$ is the average value of $y$ on $\gamma$:

$$\overline{x} = \frac{1}{\text{Length}(\gamma)} \int_\gamma x\, d\gamma, \hspace{1cm} \overline{y} = \frac{1}{\text{Length}(\gamma)} \int_\gamma y\, d\gamma$$

My question is: if $\gamma_n$ is a sequence of piecewise smooth curves which converge uniformly to a piecewise smooth curve $\gamma$, is it true that $(\overline{x_n}, \overline{y_n}) \to (\overline{x}, \overline{y})$? If it is more convenient to replace "piecewise smooth" with "rectifiable" or something else, I don't mind.

A hint that this might not be completely trivial is the observation that $\text{Length}(\gamma_n)$ need not converge to $\text{Length}(\gamma)$: the standard example is a sequence of finer and finer staircase curves converging uniformly to a diagonal line. However, the sequence of centroids does converge to the right limit in this example.

-
Notwithstanding the answer, I think that I am a bit confused about the meaning of "uniform convergence" because this is a concept normally applied to maps. Do you mean convergence in the Hausdorff metric? – Liviu Nicolaescu Mar 4 '14 at 22:05
@LiviuNicolaescu : I think that Paul is thinking of $\gamma$ as a map from $[0,1]$ to $\mathbb{R}^n$. – Andy Putman Mar 4 '14 at 22:06
@LiviuNicolaescu: what I had in mind was really "some parametrization of $\gamma_n$ converges uniformly to some parametrization of $\gamma$ as functions $[0,1] \to \mathbb{R}^n" as Andy Putman suggests, but probably it would have been clearer to use the language of Hausdorff convergence. – Paul Siegel Mar 4 '14 at 22:37 If$length(\gamma_n) \to length (\gamma)$(and they are finite) then the centroids of$\gamma_n$converge to the centroid of$\gamma$. I don't know if that is what the OP meant to say in the last paragraph. – Beni Bogosel Oct 29 '14 at 23:56 4 Answers The answer is "no". In the unit square, take the "half-finished staircase" converging to left half of the diagonal line with its right half running straight along the diagonal (see drawing below). The sequence of these "combined" curves converges uniformly to the diagonal, but the centroids do not converge to the midpoint of the diagonal. Added by request: The length of the left-hand half is$\sqrt2$times the length of the right-hand half, and the centroid of each of the two pieces is in its middle. Therefore the centroid of every curve in the sequence is the weighted average$\frac{\sqrt2(1/4,\ 1/4) + (3/4,\ 3/4)}{1+\sqrt2}\neq(1/2,1/2)$.${\qquad\qquad\qquad}$- This looks like a very nice idea. I'm about to try to calculate the centroid by hand just to make sure; if you happen to know a slick proof that the centroid is not the midpoint, could you share it? – Paul Siegel Mar 4 '14 at 22:03 This checks out, thanks! – Paul Siegel Mar 4 '14 at 22:37 To make Wlodek Kuperberg's example work with the centroid as he claimed, you want to use a stair case that goes above and below the diagonal at each step; as long as it is symmetric, you can arrange for the centroid to be$(1/4, 1/4)$each time. – Paul Siegel Mar 4 '14 at 23:04 Ah, I see, ok, thanks Wlodek and Paul. – Mathieu Baillif Mar 4 '14 at 23:12 It's a pretty construction, it deserves to end in a pretty expression for the centroid:$\left(\frac{1}{\sqrt{2}}-\frac{1}{4}, \frac{1}{\sqrt{2}}-\frac{1}{4}\right)$– Matt F. Mar 5 '14 at 4:58 Given any curve$\gamma:[0,1]\to\mathbb R^3$, any point$p$in the convex hull of the image$\gamma([0,1])$, and any$\epsilon>0$, we can find a$\gamma':[0,1]\to\mathbb R^3$so that$|\gamma(t)-\gamma'(t)|<\epsilon$and the centroid of$\gamma'$is$p$. This follows from the "convex integration" technique of Gromov, which in this case is rather trivial: just add a bunch of small fast loops to$\gamma$near various points in$[0,1]$to jack up their weight in the definition of the centroid. - Here is how one can construct many counterexamples using curves given as graphs of$C^1$-functions$\newcommand{\bR}{\mathbb{R}}[0,1]\to \bR. $Take a sequence of$C^1$functions$f_n:[0,1]\to[0,\infty)$withe the following properties. 1.$f_n$converges$C^0$to$0$. 2. The restriction of$f_n$to$[0,1/2]$converges$C^1$to$0$. 3. The length$L_n$of the graph of the function$f_n$goes to$\infty$. 4. The graph of$f_n\bigl|_{[1/2,1]}$is symmetric about the vertical line$x=3/4$. (Think of$f_n$along$[1/2,1]$as a wave with$2n^2$humps of height$1/n$symmetrically arranged about the vertical line$3/4$. The$x$-coordinate of the barycenter of the limiting graph is$x_\infty=1/2$. Denote by$x_n$the$x$-coordinate$x_n$of the barycenter of the graph of$f_n$. I claim that$x_n$converges as$n \to\infty$to a limit$\neq x_\infty$. We have $$x_n=\frac{\int_0^{1/2} x\sqrt{1+|f'_n|^2} dx+\int_{1/2}^1 x\sqrt{1+|f'_n|^2} dx}{L_n'+L_n''},$$ where $$L_n':=\int_0^{1/2} \sqrt{1+|f_n'|^2} dx,\;\;L_n'':= \int_{1/2}^1 \sqrt{1+|f_n'|^2} dx.$$ Note that as$n\to\infty$we have $$\int_0^{1/2} x\sqrt{1+|f'_n|^2} dx= \frac{1}{8}+o(1),\;\;L_n'=\frac{1}{2}+o(1)$$ while $$L_n''\to\infty.$$ On the other hand the$x$-coordinate of the barycenter of the graph$f_n\bigl|_{[1/2,1]}$is$3/4$due to the symmetry of this function. Hence $$\int_{1/2}^1 x\sqrt{1+|f'_n|^2}=\frac{3}{4}L_n''.$$ We deduce $$x_n=\frac{ \frac{1}{8}+o(1)+\frac{3}{4}L_n''}{\frac{1}{2}+o(1)+L_n''}.$$ This shows that$x_n\to \frac{3}{4}\neq x_\infty$as$n\to \infty$. - It is possible to have$\ \overline{x_n}\rightarrow \overline x\ $while$\ \overline{y_n}\not\rightarrow\overline y\ $(so that the convergence holds just for one coordinate but not for both). Just turn @WlodekKuperberg's example by half of the right angle (by$\ 45^\circ\ $or, professionally speaking, by$\ \frac\pi 4\$).

-
Of course the @JohnPardon's answer covers all possibilities. However, Kazimierz Kuratowski used to say that an example should be the simplest possible. – Włodzimierz Holsztyński Oct 27 '14 at 19:33
You might be interested in meta.mathoverflow.net/a/578 (with hairy details at meta.mathoverflow.net/a/542). – Emil Jeřábek Oct 28 '14 at 11:39
Thank you for the links. – Włodzimierz Holsztyński Oct 28 '14 at 21:06