ch of ver tices of c hp in counterclockwise order

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: utput: a sequence L = (c1 , c2 , . . . ch ) of ver tices of C H(P ) in counterclockwise order Example: L = (p3 , p4 , p8 , p6 , p1 , p5 ) p6 p1 p8 p2 p7 p4 p5 p3 C H(P ) Introduction, Convex Hulls – p.13/40 CONVEX Characterizationization HULL - Character The directed edge (p, q ) is an edge of C H(P ) iff q p C H(P ) CONVEX CharacChaization tion HULL - ter racteriza The directed edge (p, q ) is an edge of C H(P ) iff q p r − all r ∈ P \ {p, q } lies to the left of line pq (oriented by →). pq CONVEX HULLrization Characte PROBLEM The directed edge (p, q ) is an edge of C H(P ) iff q p r ∀r ∈ P \ {p, q } the triangle (p, q , r) is oriented counterclock- wise. Introduction, Convex Hulls – p.16/40 OCONVEX HULL t rientation tes We denote C C W (p, q , r) = xp xq xr yp yq yr 111 = (xq − xp )(yr − yp ) − (xr − xp )(yq − yp ) Triangle (p, q , r) is counterclockwise iff C C W (p, q , r) > 0. How fast can we perform this test? 2 multiplications and 5 subtractions takes O(1) time CONVEX HULL - tNaive Aithrithm Firs algor lgo m Algorithm SlowConvexHull (P)...
View Full Document

This note was uploaded on 01/15/2012 for the course COT 5405 taught by Professor Ungor during the Fall '08 term at University of Florida.

Ask a homework question - tutors are online