07.01.2015 Views

O'Rourke Chapter 7: Search & Intersection in PDF - Computer Science

O'Rourke Chapter 7: Search & Intersection in PDF - Computer Science

O'Rourke Chapter 7: Search & Intersection in PDF - Computer Science

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Intersection</strong> of Nonconvex Polygons<br />

• Variation on Bentley-<br />

Ottmann sweep<br />

• Ma<strong>in</strong>ta<strong>in</strong> status for<br />

each piece of sweep<br />

l<strong>in</strong>e:<br />

• 0: exterior to P, Q<br />

• P: <strong>in</strong>side P, outside Q<br />

• Q: <strong>in</strong>side Q, outside P<br />

• PQ: <strong>in</strong>side P , <strong>in</strong>side Q<br />

• Useful for CAD/CAM<br />

P<br />

source: O’Rourke<br />

Q<br />

For n-vertex<br />

P, , m-vertex<br />

Q, , O((n+m<br />

n+m)log( )log(n+m)+k) time to compute:<br />

P ∩ Q<br />

P ∪ Q<br />

P \ Q

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!