Java – what is the best way to determine the position and radius of a circle (or ellipse) so that it best fits all the points I give

I have many points What is the best way to find the center and radius of the minimum radius circle containing all given points

I think after finding the right center, the radius will be equal to the further distance, but how can I find the center?

Any algorithm / pseudo code is very useful

Solution

CGAL provides such an algorithm See @ L_ 419_ 1 @, but this is in C If you need it in Java, you can write a simple wrapper using swig

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>