the centroid of the intersection of n disks/circle

2020-05-03 12:35发布

Given that n disks/circles share a common area, meaning that every two of them intersect one another, and we know their coordinates (x1,y1,r1), (x2,y2,r2), ..., (xn,yn,rn), where xi,yi,rn represent the x axis coordinate, the y axis coordinate, and the radius of the ith disks/circle, respectively, can you provide a method to calculate the coordinate of the centroid of the intersection of these disks/circles?!

1条回答
我只想做你的唯一
2楼-- · 2020-05-03 13:32

Let's assume that all the circles overlap such that one can trace a path from any point in one of the circles to an arbitrary point in any other circle while traversing only points contained by circles. And, for generality, that the circles may be of different radii.

Per the wiki page you can decompose this shape into separate geometric regions. That is, you can find an intermediate value for the centroid by considering each circle separately (i.e. pretending they do not overlap).

Unfortunately some of the circles overlap, so you will be counting regions of the figure twice. The figure below, taken from this page, shows these regions of overlap. You therefore must find the centroid of the circle-circle intersection and subtract this from your intermediate centroid (see the wiki page's description of geometric decomposition for further details).

enter image description here

Since you can determine which circles overlap just do these for each overlapping pair and then each region of space will be counted only once. Your problem then reduces to finding the centroid of a circle-circle intersection.

You can find this by using geometric decomposition to break each lens of intersection into circular segments with the height of the segment given via a method here and coupling the result with appropriate coordinate transformations to rotate and translate the centroid to a location relative the center of one of the circles.

查看更多
登录 后发表回答