File Exchange

image thumbnail

Minimum Enclosing Circle

version 1.0.0.0 (977 Bytes) by Frank Staals
Smallest Enclosing Circle around a group of points

3 Downloads

Updated 15 Dec 2006

No License

This code takes an input of a set of given (x,y) points in the Cartesian coordinates and returns the center and radius of the minimum circle enclosing the points.

This code is based on that of Yazan Ahed, and contains no changes in the algorithm but only in the structure.

The previous code was written based on the very nice Java applet found here: http://heyoka.cs.uiuc.edu/~thite/mincircle/
Credit are due mainly to author of the applet.

Cite As

Frank Staals (2020). Minimum Enclosing Circle (https://www.mathworks.com/matlabcentral/fileexchange/13389-minimum-enclosing-circle), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (7)

Uasonm

Sorry, but I get wrong answers sometimes, and the circle is always larger......

z z

Pepito Grillo

please update

This program algorithm is not-true.
(max(pointada)-min(pointdata))/2 = R
This solution is not possible all node combination, if you your combination is linear than true else, not-true.

Jos Groot

I found the cause for getting radius 0: the
program expects 1xN input vectors, while
I supplied Nx1 vectors. I suggest to make
the program more robust.

Jos Groot

I'm sorry, but I'm getting radius 0 always.

r rekha

MATLAB Release Compatibility
Created with R13
Compatible with any release
Platform Compatibility
Windows macOS Linux
Acknowledgements

Inspired by: Minimum Enclosing Circle

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!