Introduction to Computational Geometry, Spring 2020

Michael Kazhdan


Assignment 3 Extra Credit: Fortune's Algorithm

Due on April 29 (Wednesday) @ 11:59 pm

Announcements


Overview

For this extra credit part of assignment 3 you will implement Fortune's algorithm for computing the 2D Voronoi Diagram in log-linear time.

Getting Started

You should use the code (Fortune.Code.zip) as a starting point for your assignment. You will need to add your code where it says:
/////////////////////////////
// You need to implement this
/////////////////////////////

After you download the files, the first thing to do is compile the program.


How the Program Works

The program VoronoiDiagram2D runs on the command line. It reads in a set of 2D points (with integer coefficients) in from a PLY file and either outputs the Delaunay Triangulation or shows a visualization of Fortune's sweep-line algorithm. (Note that the point-sets provided in Fortune.Data.zip should be nice, in the sense that no two points are co-horizontal, no three points are collinear, no four points are co-circular, and no point is directly below the circumcenter of three points.)

What You Have to Do

The key to implementing this algorithm is implementing the method Fortune::State::processNextEvent which pops the next event from the event-list, updates the position of the sweep-line (encoded in the static variable Fortune::BeachLineElement::Height), and does the appropritate processing. Many helper functions have been provided for you, though others have been left unimplemented. While the skeleton is provided to make your life easier, you can feel free to deviate from it (or ignore it altogether) if you so choose.
If you stick to the skeleton, you should be able to implement the algorithm by modifying Util/Geometry.inl and VoronoiDiagram2D/Fortune.[h/inl]. (My own implementation did require declaring additional methods in VoronoiDiagram2D.h.)

Evaluation


Code will be evaluated based on correctness (and efficiency).

Submission


Please email your implemented source code to me. (The code should compile under Windows/Linux and should not require any additional libraries.)
HOME