Convex hull and diameter of 2d point sets

Category: Python - Miscellaneous

This script returns the convex hull (separated into upper and lower chains of vertices) and the diameter (farthest pair of points), given input consisting of a list of 2d points represented as pairs (x,y). The convex hull algorithm is Graham's scan, using a coordinate-based sorted order rather than the more commonly seen radial sorted order. A rotating calipers algorithm generates candidate pairs of vertices for the diameter calculation. Care was taken handling tricky cases such as pairs of points with the same x-coordinate and colinear triples of points. Date: 23 February, 2012


Convex Hull - 2d Point Sets - Convex Hull Algorithm - Convex - Hull

Homepage: http://code.activestate.com

Developer: code.activestate.com

License: Artistic License, GNU General Public License (GPL)

Operating System: Windows, Linux, Mac OS, BSD, Solaris

Add a Comment

all are required fields

     
What do you think of this resource?

Select Your Rate:

Votes:0

 

Related Scripts Download

This simple code calculates the convex hull of a set of 2D points and generates EPS files to visualise them.

developer Developer: code.activestate.com
license License: Freeware
operating systems Operating System: All


This script returns the convex hull (separated into upper and lower chains of vertices) and the diameter (farthest pair of points), given input consisting of a list of 2d points represented as pairs (x,y).

developer Developer: code.activestate.com
license License: Freeware
operating systems Operating System: All


This simple code calculates the convex hull of a set of 2D points and generates EPS files to visualise them.

developer Developer: code.activestate.com
license License: Artistic License, GNU General Public License (GPL)
operating systems Operating System: Windows, Linux, Mac OS, BSD, Solaris


The Parma Polyhedra Library (PPL) is a modern C library providing numerical abstractions especially targeted at applications in the field of analysis and verification of complex systems.

developer Developer: ftp.cs.unipr.it
license License: Artistic License, GNU General Public License (GPL)
operating systems Operating System: Windows, Linux, Mac OS, BSD, Solaris


This script implements the instance method for performing currying.

developer Developer: code.activestate.com
license License: Artistic License, GNU General Public License (GPL)
operating systems Operating System: Windows, Linux, Mac OS, BSD, Solaris


Storage for store information about prefixes script allows you to store information about domains determined by key prefixes.

developer Developer: code.activestate.com
license License: Artistic License, GNU General Public License (GPL)
operating systems Operating System: Windows, Linux, Mac OS, BSD, Solaris