public class MinimumBoundingCircle extends Object
Geometry
.
The MBC is the smallest circle which covers
all the input points
(this is also known as the Smallest Enclosing Circle).
This is equivalent to computing the Maximum Diameter
of the input point set.
The computed circle can be specified in two equivalent ways, both of which are provide as output by this class:
Geometry
which approximates the
shape of the Minimum Bounding Circle (although as an approximation
it is not guaranteed to cover all the input points.)
The Maximum Diameter of the input point set can be computed as well. The Maximum Diameter is defined by the pair of input points with maximum distance between them. The points of the maximum diameter are two of the extremal points of the Minimum Bounding Circle. They lie on the convex hull of the input. However, that the maximum diameter is not a diameter of the Minimum Bounding Circle in the case where the MBC is defined by an inscribed triangle.
MinimumDiameter
Constructor and Description 

MinimumBoundingCircle(Geometry geom)
Creates a new object for computing the minimum bounding circle for the
point set defined by the vertices of the given geometry.

Modifier and Type  Method and Description 

Coordinate 
getCentre()
Gets the centre point of the computed Minimum Bounding Circle.

Geometry 
getCircle()
Gets a geometry which represents the Minimum Bounding Circle.

Geometry 
getDiameter()
Gets a geometry representing the diameter of the computed Minimum Bounding
Circle.

Coordinate[] 
getExtremalPoints()
Gets the extremal points which define the computed Minimum Bounding Circle.

Geometry 
getFarthestPoints()
Deprecated.
use #getMaximumDiameter()

Geometry 
getMaximumDiameter()
Gets a geometry representing the maximum diameter of the
input.

double 
getRadius()
Gets the radius of the computed Minimum Bounding Circle.

public MinimumBoundingCircle(Geometry geom)
geom
 the geometry to use to obtain the point setpublic Geometry getCircle()
public Geometry getMaximumDiameter()
The points are two of the extremal points of the Minimum Bounding Circle. They lie on the convex hull of the input.
public Geometry getFarthestPoints()
The points are two of the extremal points of the Minimum Bounding Circle. They lie on the convex hull of the input.
public Geometry getDiameter()
public Coordinate[] getExtremalPoints()
public Coordinate getCentre()
public double getRadius()
Copyright © 2020. All rights reserved.