To compute the convex hull of a set of points, we begin
with a list containing each point. Each point in the list is a
* Point* structure. This structure consists of
three members,

`x`

`y`

`z`

The *cvxhull* operation (see Example 17.3) begins by locating the
lowest point passed to it in * P*. To
determine this, we traverse all points while keeping track of which
has the smallest

`p0`

The actual process of constructing the convex hull takes place
within a nested loop. At the start of the outer loop, we insert
* p0* into the convex hull. On the first
iteration of the loop,

`p0`

`p0`

`pi`

`P`

`p0`

`pc`

`p0`

`pi`

`pc`

`z`

`pi`

`pc`

`pc`

`pi`

`pi`

`pc`

Start Free Trial

No credit card required