"GIFT WRAPPING" aka JARVIS' MARCH
- 1. Start with V0, vertex with minimum y coordinate coordinate.
- 2. While Vi ≠ V0, continue.
- 3. Compute angles of V0Pi with horizontal through extended V0, for all Pi.
- 4. Take point with minimum angle.
- 5. At step i, we have Vi on Convex Hull and then compute angles between ViPj and the extension of ViVi-1
- 6. Take minimum, which will be Vi +1
- 7. Go to step 2.
APPLETS FOR GIFT-WRAPPING:
REPRESENTATION OF GIFT WRAPPING IN THE PARABOLIC DUALITY
- Start with line L0 with minimum slope.
In CH algorithm, start with point of min x coordinate.
- Compute the coordinates for all intersections of L0 and lines Li for all lines in the arrangement.
In CH algorithm, equates to computing the angle of the horizontal through chosen point, with the line from chosen point to all other points in the set of points.
- Choose line Li that intersects L0 at minimum x coordinate. Call this intersection Ij
In CH algorithm, equates to choosing the point whose line has minimum angle with horizontal line.
- While there exists a line Li+1 that intersects Li after Ij, i.e. to the right of Ij go to 2.
In CH algorithm, equates to continuing algorithm till all points have been verified and the algorithm reaches the intial point.
- The upper envelope with be made up of all the segments between the chosen intersections and the two infinate lines (min slope and max slope).