18.04.2013 Views

The.Algorithm.Design.Manual.Springer-Verlag.1998

The.Algorithm.Design.Manual.Springer-Verlag.1998

The.Algorithm.Design.Manual.Springer-Verlag.1998

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.

Lecture 19 - satisfiability<br />

Why? That means each integer is mapped to a point on the parabola .<br />

Listen To Part 21-11<br />

Since this parabola is convex, every point is on the convex hull. Further since neighboring points on the<br />

convex hull have neighboring x values, the convex hull returns the points sorted by x-coordinate, ie. the<br />

original numbers.<br />

Sort(S)<br />

For each , create point .<br />

Call subroutine convex-hull on this point set.<br />

From the leftmost point in the hull,<br />

Creating and reading off the points takes O(n) time.<br />

read off the points from left to right.<br />

What does this mean? Recall the sorting lower bound of . If we could do convex hull in better than<br />

, we could sort faster than - which violates our lower bound.<br />

Thus convex hull must take as well!!!<br />

Observe that any convex hull algorithm also gives us a complicated but correct sorting<br />

algorithm as well.<br />

file:///E|/LEC/LECTUR16/NODE19.HTM (3 of 7) [19/1/2003 1:35:22]

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

Saved successfully!

Ooh no, something went wrong!