TECH-MUSINGS

Thoughts On Algorithms, Geometry etc...

Thursday, April 19, 2007

A Different 'Center' To A Polygon

In the last post here, we pondered (without nailing to the wall), the problem of finding the point inside a convex polygon which maximizes the minimum angle subtended there by the edges of the polygon. Now, we have something else on similar lines.

Problem: Given a convex polygon, find the point in its interior for which the sum of distances to the vertices of the polygon is least.

Thoughts: The required point need not be the centroid of the polygon.
---------
Example. consider a convex polygon formed by (1) 100 points extremely close to each other - so close that they are separate only at near infinite zoom - near the point x=-1 on the X axis, (2) another 100 points similarly close to each other but near the point x = +1 on the X axis and (3) a single point on the Y axis at Y = 201. Of course, the close by points lie so that the total set of 21 points form a convex polygon - from a distance this polygon looks like a triangle though.

Now, the centroid of this polygon is very close to a point on Y axis: y = +1. this centroid is at a distance 200 from the lone apex point and nearly sqrt(2) distant from the other 200 points. Now, consider the mid point of the base of the polygon, lying between the two point bunches at x = +/-1. This mid point is at distance 201 from the lone apex point but only at distance equal to nearly 1 from the other 200 points. Its distance sum is clearly less than that of the centroid.

------------

It might be interesting to see how this distance sum function varies across the region of the polygon in various cases. If I understand right, Earnshaw's theorem probably implies Sum (reciprocals of distances from vertices) has no proper minimum in the interior (only saddle points). Maybe something similar could be said about the distance sum as well.

Note added on May 23rd: Earnshaw's theorem is, as far as I know, a consequence of the electrostatic potential satisfying Laplace equation. The present problem has a potential that increases linearly with distance from the 'charge' and this *does not* satisfy Laplace equation. Hence there can very well be local maxima and minima for the distance sum function in the interior of the polygon. I know of no case where the *maximum* of the (sum of distances from vertices) is somewhere in the interior of the convex polygon - here we look at only the interior of the polygon and its boundary, not exterior.

Note added on July 5th 2007: Experiments indicate that the point which minimizes the sum of distances from the vertices has a unique position (there are no local minima etc for this distance sum function) . This appears true not only when the vertices are those of a convex polygon - any distribution of points (call them vertices)appears to have this property: a unique point minimizes the sum of the distances from these vertices.

And here is some further perspective from 'Mathworld':
"A convex function is a continuous function whose value at the midpoint of every interval in its domain does not exceed the arithmetic mean of its values at the ends of the interval."
This implies a convex function has to have at most one local minimum in its domain. I remember hearing that distance is a convex funtion (not sure about the proof) and probably, so is the sum of distances. Thus, we could say:
"Given a distribution of vertices on a plane and a point P which varies along any straight line. The sum of the distances from P to the vertices has a unique minimum on its straight line path. And since for P running along *any* straight line path in that plane, the distance sum function has a unique minimum, the function has to have a unique minimum *for the plane as a whole*.

Note added on December 12th and edited on May 26th 2015: If the input polygon is a triangle, this problem is called the Fermat's problem. In this special case, the solution also solves the Steiner tree problem. Coxeter has described this special case in his 'Intro to Geometry' and proved the point is such that all the 3 sides of the triangle subtend 120 degrees there. Note: This solves for triangles the problem (next post here) of finding the interior point that maximizes the least angle subtended by a side of the polygon. And this wikipedia article has more details: http://en.wikipedia.org/wiki/Geometric_median

Question: For any convex polygon, are the interior points that maximizes the min side-subtended angle and minimizes the sum of distances from vertices respectively are same?

Answer: Not necessarily. Consider a regular polygon with very large by finite n vertices. The center maximuizes both the minimual side-subtended angle and the sum of distances from vertices. Now add an n+1th vertex very close to one of the vertices to form an n+1-gon. At the physical center of the polygon (which is essentially unchanged with new vertex), the least side subtended angle will be extremely small. To make this angle compparable to the others, the corresponding center has to be moved very close to the neighborhood of the newly added vertex. But there is no need to move the distance sum center (which is the center of mass)that much if n is large.

1 Comments:

  • At 2:50 AM, Blogger Anurag said…

    Interesting. I'll try to comment with some data soon.

     

Post a Comment

<< Home