• No results found

Improved lower bound for online strip packing

N/A
N/A
Protected

Academic year: 2021

Share "Improved lower bound for online strip packing"

Copied!
8
0
0

Bezig met laden.... (Bekijk nu de volledige tekst)

Hele tekst

(1)

(Extended Abstract)

Rolf Harren1and Walter Kern2 1 Max-Planck-Institut f¨ur Informatik (MPII)

Campus E1 4, 66123 Saarbr¨ucken, Germany

rharren@mpi-inf.mpg.de

2 University of Twente, Department of Applied Mathematics

P.O. Box 217, 7500 AE Enschede, The Netherlands

w.kern@utwente.nl

1

Introduction

In the two-dimensional strip packing problem a number of rectangles have to be packed without rotation or overlap into a strip such that the height of the strip used is minimal. The width of the rectangles is bounded by 1 and the strip has width 1 and infinite height. We study the online version of this packing problem. In the online version the rect-angles are given to the online algorithm one by one from a list, and the next rectangle is given as soon as the current rectangle is irrevocably placed into the strip. To evalu-ate the performance of an online algorithm we employ competitive analysis. For a list of rectanglesL, the height of a strip used by online algorithm ALG and by the opti-mal solution is denoted by ALG(L) and OPT(L), respectively. The optimal solution is not restricted in any way by the ordering of the rectangles in the list. Competitive analysis measures the absolute worst-case performance of online algorithm ALG by its competitive ratio ρALG= sup L  ALG(L) OPT(L)  .

Known Results. Regarding the upper bound on the competitive ratio for online strip

packing, recent advances have been made by Ye, Han & Zhang[6] and Hurink & Paulus[3]. Independently they showed that a modification of the well-known shelf algorithm yields an online algorithm with competitive ratio 7/2 +√10 ≈ 6.6623. We refer to these two papers for a more extensive overview of the literature.

In the early 80s, Brown, Baker & Katseff[1] derived a lower boundρ ≥ 2 on the competitive ratio of any online algorithm by constructing certain (adversary) sequences in a fairly straightforward way. These sequences, that we call BBK sequences in the sequel, were further studied by Johannes[4] and Hurink & Paulus[2], who derived im-proved lower bounds of 2.25 and 2.43, respectively. (Both results are computer aided and presented in terms of online parallel machine scheduling, a closely related prob-lem.) The paper of Hurink & Paulus[2] also presents an upper bound ofρ ≤ 2.5 for packing BBK sequences. Kern & Paulus[5] finally settled the question how well the BBK sequences can be packed by providing a matching upper and lower bound of ρBBK= 3/2 +√33/6 ≈ 2.457.

R. Solis-Oba and G. Persiano (Eds.): WAOA 2011, LNCS 7164, pp. 211–218, 2012. c

(2)

that we use consist solely of two types of items, namely, thin items that have negligible width (and thus can all be packed in parallel) and blocking items that have width 1. The advantage of these sequences is that the structure of the optimal packing is simple, i.e., the optimal packing height is the sum of the heights of the blocking items plus the maximal height of the thin items. Therefore, we call such sequences primitive.

On the positive side, we present an online algorithm for packing primitive sequences with competitive ratio (3 +√5)/2 = 2.618 . . .. This upper bound is especially inter-esting as it not only applies to the concrete adversary instances that we use to show our lower bound. Thus to show a new lower bound for strip packing that is greater than 2.618 . . . (and thus reduce the gap to the general upper bound of 6.6623), new techniques are required that take instances with more complex optimal solutions into consideration.

Organization. We start our presentation with a description of the Brown-Baker-Katseff

sequences and their modification. Afterwards we present our lower bound based on these modifications, and finally we describe our algorithm for packing primitive sequences.

2

Sequence Construction

In this paper we denote the thin items bypi and the blocking items byqi (adopting the notation from [5]). As already mentioned in the introduction, we assume that the width of the thin items is negligible and thus all thin items can be packed next to each other. Moreover, the width of the blocking itemsqiis always 1, so that no item can be packed next to any blocking item in parallel. Therefore, all items are characterized by their heights and we refer to their heights bypiandqias well. By definition, for any list L = q1, q2, . . . , qk, p1, p1, . . . , pconsisting of thin and blocking items we have

OPT(L) = k  i=1 qi+ max i=1,...,pi.

To prove the desired lower bound we assume the existence of aρ-competitive algorithm ALG for some ρ < 2.589 . . . (the exact value of this bound is specified later) and construct an adversary sequence depending on the packing that ALG generates.

To motivate the construction, let us first consider the GREEDYalgorithm for online strip packing, which packs every item as low as possible—see Figure 1a. This algorithm is not competitive (i.e., has unbounded competitive ratio): Indeed, consider the listLn=

p0, q1, p1, q2, p2, . . . , qn, pnof items with

p0:= 1,

qi := ε for 1≤ i ≤ n,

(3)

p0 p1 p2 p3 p4 p5 q5 q4 q3 q2 q1

(a) A greedy packing

α1p1 p0 β0p0 q1 q2 p1 p2 β1p1 β2p2 α2p2 (b) A packing of a BBK se-quence q1 q2 p2 p0p1 (c) An optimal packing of a BBK sequence

Fig. 1. Online and optimal packings

for someε > 0. GREEDYwould pack each item on top of the preceding ones and thus generate a packing of height GREEDY(Ln) =ni=0pi+ni=1qi= n + 1 + Ω(n2ε),

whereas the optimum clearly has height 1 + 2nε.

The GREEDY algorithm illustrates that any competitive online algorithm needs to create gaps in the packing. These gaps work as a buffer to accommodate small blocking items—or, viewed another way, force the adversary to release larger blocking items.

BBK sequences. The idea of Brown, Baker & Katseff[1] was to try to cheat an arbitrary

(non-greedy) online packing algorithm ALG in a similar way by constructing an alter-nating sequencep0, q1, p1, . . . of thin and blocking items. The heights pi respectively qi are determined so as to force the online algorithm ALG to put each item above the previous ones—see Figure 1b for an illustration. To describe the heights of the items formally, we consider the gaps that ALG creates between the items. We distinguish two types of gaps, namely gaps below and gaps above a blocking item, and refer to the-ses gaps asα- and β-gaps, respectively. These gaps also play an important role in our analysis of the modified BBK sequences. We describe the height of the gaps around the blocking itemqirelative to the thin item pi. Thus, we denote the height of theα-gap belowqibyαipiand the height of theβ-gap above qibyβipi. Using this notation, we are ready to formally describe the BBK sequencesL = p0, q1, p1, q2, . . . with

p0:= 1,

q1:= β0p0+ ε,

pi:= βi−1pi−1+ pi−1+ αipi+ ε fori ≥ 1,

(4)

ratio for packing them isρBBK= 3/2 +√33/6 ≈ 2.457.

The optimal online algorithm for BBK sequences that Kern & Paulus[5] describe generates packings with striking properties: No gaps are created except the first possible gapβ0 = ρBBK− 1 and the second α-gap α2 = 1/(ρBBK− 1), which are chosen as large as possible while remainingρBKK-competitive. Observing this behavior of the optimal algorithm led us to the modification of the BBK sequences.

Modified BBK sequences. When packing BBK sequences, a good online algorithm

should be eager to enforce blocking items of relatively large size (as each blocking item of sizeq increases the optimal packing by q as well). These blocking items are enforced by generating corresponding gaps.

Modified BBK sequences are designed to counter this strategy: Each time the online algorithm places a blocking itemqi, the adversary, rather than immediately releasing a thin itempi+1(of height defined as in standard BBK sequences) that does not fit in be-tween the last two blocking items, generates a whole sequence of slowly growing thin items, which “continuously” grow frompitopi+1. Packing this subsequence causes ad-ditional problems for the online algorithm: If the algorithm fits the whole subsequence into the last interval betweenqi−1andqi, it would fill out the whole interval and create anα-gap of 0. On the other extreme, if ALG would pack a thin item of height roughly pi aboveqi, then the (relative)β-gap it can generate is much less compared to what it

could have achieved with a thin item of larger heightpi+1. The next blocking itemqi+1 will be released as soon as the sequence of thin items has grown frompitopi+1.

This general concept of modified BBK sequences applies after the first blocking itemq1 is released. Since subsequences of thin items and single blocking items are released alternately, we refer to this phase as the alternating phase. Before that, we have a starting phase which ends with the release of the first blocking itemq1. This starting phase needs special attention as we have no preceding interval height as a reference.

The optimal online algorithm by Kern & Paulus[5] generates an initial gapβ0 = ρBBK− 1 of maximal size to enforce a large first blocking item q1. In the starting phase, we seek to prevent the algorithm from creating a largeβ0-gap in the following way. Assume that the online algorithm placesp0“too high” (i.e.,β0is “too large”). Then the adversary, instead of releasingq1, would continue generating higher and higher thin items and observe how the algorithm places them. As long as the algorithm places these thin items next to each other (overlapping in their packing height), the size of the gap below these items decreases monotonically relative to the height where items are packed. Eventually,β0has become sufficiently small—in which case the starting phase comes to an end with the release ofq1—or the online algorithm decides to “jump” in the sense that one of the items in this sequence of increasing height thin items is put strictly above all previously packed thin items, creating a new gap (distance between the last two items) and a significantly increased new packing height. Once a jump has occurred, the adversary continues generating thin items of slowly growing height until a next jump occurs or until the ratio of the largest current gap to the current packing height (the modified analogue to the standardβ0-gap) is sufficiently small and the starting phase comes to an end.

(5)

Summarizing, a modified BBK sequence simply consists of a sequence of thin items, continuously growing in height, interleaved with blocking items which (by definition of their height) must be packed above all preceding items, and are released as described above, i.e., when the thin item size has grown up to the largest gap between two blocking items, c.f. the full paper for more details.

In the next section we use these modified BBK sequences to show the following theorem.

Theorem 1. There exists no algorithm for online strip packing with competitive ratio ρ < ˆρ = 1712+ 1 48 3  22 976 − 768√78 + 1 12 3  359 + 12√78 ≈ 2.589 . . . .

3

Lower Bound

For the sake of contradiction, we assume that ALG is aρ-competitive algorithm for online strip packing with ρ < ˆρ. Let δ = ˆρ − ρ > 0. W.l.o.g. we assume that δ is sufficiently small.

We distinguish between the thin itemspi (whose height matches the height of the previous interval plus an arbitrarily small excess) and the subsequences of gradually growing thin items by denoting the whole sequence of thin items by r1, r2, . . . and designating certain thin items aspi.

Our analysis (cf section 5) distinguishes two phases. In the first phase, the starting phase, we consider the following problem that the online algorithm faces. Given an input that consists only of thin itemsr1, r2, . . . (in this phase no blocking items are released), minimize the competitive ratio while retaining a free gap of maximal size (relative to the current packing height). More specifically, let

h(maxgapALG(ri))

ALG(ri)

be the max-gap-to-height ratio after packingriwhereh(maxgapALG(ri)) denotes the height of the maximal gap that algorithm ALG created up to itemri and ALG(ri) denotes the height algorithm ALG consumed up to item ri. We say ALG is (ρ, c)-competitive in the starting phase if ALG isρ-competitive (i.e., ALG(ri) ≤ ρOPT(ri)) and retains a max-gap-to-height ratio ofc (i.e., h(maxgapALG(ri))/ALG(ri) ≥ c for

i ≥ 1) for all lists L = r1, r2, . . . of thin items.

In the analysis of the starting phase we show that our modified BBK sequences force anyρ-competitive algorithm to reach a state with max-gap-to-height ratio less than

ˆc = ρ − 2ˆ ˆ

ρ − 1 ˆ

ρ − 1 .

Thus no (ρ, ˆc)-competitive algorithm exists for ρ < ˆρ. In the moment ALG packs an itemri and hereby reaches a max-gap-to-height ratio of less than ˆc, the starting phase ends with the release of the first blocking itemq1of height ˆc · ALG(ri).

(6)

packing height for

ˆc = 1 −

ρ2− 12ˆρ+ 5 2(ˆρ − 1) . Thus our two phases fit together for

ˆc = ρ − 2ˆ ˆ ρ − 1 ˆ ρ − 1 = 1 −ρ2− 12ˆρ+ 5 2(ˆρ − 1) , which is satisfied for

ˆ ρ = 1712+ 1 48 3  22 976 − 768√78 + 1 12 3  359 + 12√78 ≈ 2.589 . . . . The correseponding value of ˆc is ˆc ≈ 0.04275 . . .. We skip the proof of Theorem 1.

Algorithm 1. Online Algorithm for Restricted Instances 1: Initially the packing is considered to be blocked

2: whenever a rectanglerjis released do 3: ifrjis a blocking item then

4: Packrjat the lowest possible height 5: else ifrjis a thin item then

6: if the packing is open then

7: Packrjbottom-aligned with the top thin item 8: else if the packing is blocked then

9: Try to packrjbelow the top item

10: If this is not possible, packrjat distance(ρ − 2)rjabove the packing

4

Upper Bound

In this section we present the online algorithm ONL for packing instances that consist solely of thin and blocking items. We prove that the competitive ratio of ONL isρ = (3 +√5)/2. We distinguish two kinds of packings according to the item on top: If the item on top of the packing is a blocking item, we have a blocked packing, otherwise we have an open packing. Initially, we have a blocked packing by considering the bottom of the strip as a blocking item of height 0.

The general idea of the algorithm ONL is pretty straight-forward: Generate aβ-gap of relative heightρ − 2 whenever a jump is unavoidable and pack arriving blocking items as low as possible. Since we neglect the starting phase,β = ρ − 2 is the maximal β-gap that we can ensure. This leads to the following algorithm—see also Algorithm 1.

(7)

s i−1 s i si βsi si+1 βsi+1 h h

Fig. 2. Packing after the(i + 1)-th jump. The blocking items that arrived after siare shown in darker shade. By definition,siis the first item that does not fit into the previous interval. Thus we havesi+1> si+ β si− h.

– If a blocking itemrjarrives, we packrj at the lowest possible height. This can be inside the packing, if a sufficiently large gap is available, or directly on top of the packing. In the latter case, the packing is blocked afterwards.

– If a thin itemrjarrives at an open packing, we bottom-alignrjwith the top item. – If, finally, a thin itemrj arrives at a blocked packing, we try to pack rj below

the blocking item on top. If this is not possible, i.e.,rj exceeds the height of all intervals for thin items, we packrj at distanceβ rj = (ρ − 2)rjabove the top of the packing. This changes the packing to an open packing again.

We show that ONL isρ-competitive for ρ = (3 +√5)/2. Actually, this is only ques-tionable in one case, namely, when we pack a thin item rj with distance (ρ − 2)rj above the packing. All other cases are trivial since if the packing height increases, then the optimal height increases by the same value (for thin items the packing height only increases ifrjis the new maximal item).

We denote the thin items that are packed when generating a new gap bysi for the i-th jump. Let s

i−1be the highest thin item that is bottom-aligned withsi−1. Note that

the blocking item that blocks the packing after thei-th jump is packed directly above s

i−1. See Figure 2 for an illustration.

It is obvious that the first jump items1, that is actually the first thin item that arrives, can be packed.

For the induction step we assume ONL(si) ≤ ρ OPT(si). Before a jump can

be-come unavoidable, new blocking items of total height greater thanβ sineed to arrive as otherwise the gap belowsicould accommodate all of them. Lethbe the height of the blocking items that are packed into theβ-gap below siand lethbe the total height

(8)

on top. As further blocking items could be packed even belowsi−1we get OPT(si+1) ≥ OPT(si) + h+ h+ si+1− si

ONL(si+1) = ONL(si) + si− si+ h+ βsi+1+ si+1.

And thus we have

ONL(si+1) ≤ ρ OPT(si+1)

⇐ ONL(si) + si− si+ h+ βsi+1+ si+1 ≤ ρOPT(si) + h+ h+ si+1− si

(ρ − 1)si+ si− ρh− (ρ − 1)h≤ (ρ − 1 − β)si+1.

Asρ − 1 − β = 1 and si+1 > si+ (ρ − 2)si− hthis is satisfied if (ρ − 1)si+ si− ρh− (ρ − 1)h≤ si+ (ρ − 2)si− h

si≤ (ρ − 1)(h+ h)

si≤ (ρ − 1)(ρ − 2)si= si.

The last equality holds sinceρ = (3+√5)/2 and thus (ρ−1)(ρ−2) = 1. Summarizing, we arrive at

Theorem 2. ONL is aρ-competitive algorithm for packing primitive sequences with ρ = 3 +

5

2 ≈ 2.618.

So the true best possible competitive ratio for packing primitive sequences is some-where in between the two values specified by Theorems 1 and 2. We have reasons to believe that it is strictly in between these two. But perhaps an even more challenging question is whether or not (or to what extent) primitive sequences provide worst case instances for online packing in general.

References

1. Brown, D.J., Baker, B.S., Katseff, H.P.: Lower bounds for online two-dimensional packing algorithms. Acta Informatica 18, 207–225 (1982)

2. Hurink, J., Paulus, J.: Online scheduling of parallel jobs on two machines is 2-competitive. Operations Research Letters 36(1), 51–56 (2008)

3. Hurink, J.L., Paulus, J.J.: Online Algorithm for Parallel Job Scheduling and Strip Packing. In: Kaklamanis, C., Skutella, M. (eds.) WAOA 2007. LNCS, vol. 4927, pp. 67–74. Springer, Heidelberg (2008)

4. Johannes, B.: Scheduling parallel jobs to minimize the makespan. Journal of Scheduling 9(5), 433–452 (2006)

5. Kern, W., Paulus, J.: A tight analysis of Brown-Baker-Katseff sequences for online strip pack-ing. Submitted (J. Combinatorial Opt.)

6. Ye, D., Han, X., Zhang, G.: A note on online strip packing. Journal of Combinatorial Opt. 17(4), 417–423 (2009)

Referenties

GERELATEERDE DOCUMENTEN

The adjusted exhaustive base-stock policy applies the same rules as the exhaustive base-stock policy, but skips an item if, just before the switch to this item, the stock level of

These Āryās and Anuṣṭubhs are matched in the Jātaka with, respectively, the notion of an introductory exchange of ‘recognition’ verses (Triṣṭubh gāthās 1-5) and

FACULTY OF ELECTRICAL ENGINEERING, MATHEMATICS, AND COMPUTER SCIENCE. EXAMINATION COMMITTEE

Master thesis: The effect of adding an online channel to the strategy of !pet Page 10 of 71 ▪ Customer research: Purpose is to gain insight in the opinions of

This short report analyses a simple and intu- itive online learning algorithm - termed the graphtron - for learning a labeling over a fixed graph, given a sequence of labels.. The

Results from the 1-MCP applications on the ‘Navelate’ and ‘Midknight Valencia’ oranges indicate that the abscission process can be positively manipulated but its efficacy depends

Though numerical simulation of the continuous time dynamic system is also discrete, it is different from SPI, as the former can choose integration steps according to

All one-parameter macros hcmdi work this way, unless there are pro- gramming mistakes outside dowith (also thinking of arguments that take over control from dowith commands before