Add area-weighted geographic polygon centroids.

This generalises the centre of mass formula given in:

  J. E. Brock, The Inertia Tensor for a Spherical Triangle,
  J. Applied Mechanics 42, 239 (1975)
Fix d3.geo.centroid for coincident polygon points.
Simplify a few trigonometry calls.

Optimised d3_acos, and used d3_asin and d3_acos where appropriate
instead of Math.min and Math.max.
Support centroids of zero-extent features.

Specifically, lines of zero length are now treated as points.  A polygon
with zero area may be treated as a line, or a point if the line would
have zero length.

This applies to both d3.geo.centroid and d3.geo.path.centroid.

Fixes #1011.