CoBarS: Fast Reweighted Sampling for Polygon Spaces

Conformal barycenter sampling is a method for generating random samples from polygon spaces in Rd where the number of edges n and the edgelengths r1, …, rn are fixed. The basic idea is that a configuration of such a polygon (up to translation) may be described by a weighted point cloud w1, …, wn on Sd-1 where the weighted sum r1 w1 + … + rn wn = 0.

We can generate configurations of wi by sampling them uniformly from the sphere and using an appropriate Möbius transformation to recenter them. This method introduces some sampling bias, but the appropriate weights to correct for the bias are computed in the paper (CoBarS: Fast Reweighted Sampling for Polygon Spaces in any Dimension, Jason Cantarella and Henrik Schumacher, 2023).

CoBarS is extremely fast (linear time in fixed dimension) and produces almost-uniform samples even without the weights. The method is implemented in two GitHub repositories: