04.09.2013 Views

Algorithm Design

Algorithm Design

Algorithm Design

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

434<br />

Chapter 7 Network Flow<br />

31.<br />

moving to the new system are in fact negative: If bi < 0, then it is preferable<br />

(by an amount quantified in hi) to keep i on the old system. Again, give<br />

a polynomial-time algorithm to find a set $ ~_ {1, 2 ..... n} for which the<br />

sum of the benefits mlnus the expenses of moving the applications in S<br />

to the Sew system is maximized.<br />

Some of your friends are interning at the small high-tech company Web-<br />

Exodus. A running joke among the employees there is that the back room<br />

has less space devoted to high-end servers than it does to empty boxes<br />

of computer equipment, piled up in case something needs to be shipped<br />

back to the supplier for maintainence.<br />

A few days ago, a large shipment of computer monitors arrived, each<br />

in its own large box; and since there are many different kinds of monitors<br />

in the shipment, the boxes do not all have the same dimensions. A bunch<br />

of people spent some time in the morning trying to figure out how to<br />

store all these things, realizing of course that less space would be tkken<br />

up If some of the boxes could be nested inside others.<br />

Suppose each box i is a rectangnlar parallelepiped with side lengths<br />

equal to (i 1, iz, i3); and suppose each side length is strictly between half a<br />

meter and one meter. Geometrically, you know what it means for one box<br />

to nest inside another: It’s possible if you can rotate the smaller so that<br />

it fits inside the larger in each dimension. Formally, we can say that box<br />

i with dimensions (il, i2, i3) nests inside boxj with dimensions (Jl,J2,J3) If<br />

there is a permutation a, b, c of the dimensions {1, 2, 3} so that in

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

Saved successfully!

Ooh no, something went wrong!