• Nem Talált Eredményt

First we state a few basic properties of F F packings. Assumption 4.2.1 as well as all parts of Lemma 4.2.1 are known and easy facts used explicitly or implicitly in previous works on F F including [73, 85, 10].

Assumption 4.2.1 We assume, without loss of generality, that no two itemsai andaj are packed into the same bin both inF F andOP T solutions.

This is w.l.o.g., since any two such items may be replaced by a single item of sizeai+aj that arrives at the time of arrival of the first of the original items. It is easy to see that both F F and OP T solutions are unchanged (except for this replacement).

Lemma 4.2.1 In theF F packing the following holds:

(i) The sum of sizes of any twoF F-bins is greater than1. The total size of anyk ≥2F F-bins is greater thank/2.

(ii) TheD-items are packed into different optimal bins. Thusδ≤OP T.

(iii) There is at most one common binC0withs(C0)≤2/3. Furthermore, ifs(C0) = 2/3−2xfor x ≥0then for any other2+-bin (i.e., any other common or big bin)B we haves(B)> 2/3 +x;

in addition, ifBis opened afterC0, thens(B)>2/3 + 4x.

(iv) Ifk ≥3, then the total size ofkarbitrary2+-bins is greater than 23k.

(v) Suppose thatk ≥1, we havek+ 1F F-binsB1,B2, . . . ,Bk,B, in this order, and such thatB is ak+-bin. Then the sum of the sizes of thesek+ 1bins is greater thank.

Proof. (i): The first item in anyF F-bin does not fit in any previous bin, thus the sum of their sizes is greater than1already at the time when the second bin is opened. Forkbins, order the bins cyclically and sum the inequalitiess(Bi) +s(Bj)>1for pairs of adjacent bins.

(ii): Follows from (i), as the size of eachD-item equals the size of its dedicatedF F-bin.

(iii): IfB is afterC0, then it contains only items of size larger than1−s(C0) = 1/3 + 2x; since it contains two items, s(B) > 2/3 + 4xfollows. If B is before C0, then notice that C0 contains an item of size at mosts(C0)/2 = 1/3−x; This item was not packed intoB, thus it follows that s(B)>2/3 +x.

(iv): Follows immediately from (iii).

(v): Letx be the minimum of s(Bi), i = 1, . . . , k. Then by theF F-rule, any item in bin B is larger than 1−x. Since there are at least k items in bin B, we have s(B) +Pk

i=1s(Bi) >

k(1−x) +kx=k. 2

Now we assume that the instance violates the absolute ratio 1.7and derive some easy conse-quences that exclude some degenerate cases. The first claim, OP T ≥ 7, follows from [10, 85];

we include its proof for completeness. Note that the values of1.7·OP T are multiples of0.1and F F is an integer, thusF F > 1.7·OP T impliesF F ≥ 1.7·OP T + 0.1. Typically we derive a contradiction with the factS ≤OP T stated above.

Lemma 4.2.2 IfF F > 1.7·OP T then the following holds:

(i)OP T ≥7.

(ii) No common binC has sizes(C)≤1/2.

(iii) The number of dedicated bins is bounded byδ ≥3.

(iv) The number of common bins is bounded byγ ≥OP T /2 + 1>4. IfF F ≥1.7·OP T +τ /10

After the modificationδ = 2andβ+γ ≥3, thus the above calculation works. We possibly apply this calculation also in later parts (ii) and (iii) if needed.

IfOP T = 2andF F >1.7·OP T thenF F ≥4, and by Lemma 4.2.1(i) we haveS >4·12 = OP T, a contradiction. ForOP T = 1,F F is trivially optimal.

(ii): Suppose that s(C0) ≤ 1/2 for a contradiction. Lemma 4.2.1(iii) implies that any big or common bin C before C0 has s(C) ≥ 3/4. Furthermore, any bin after C0 is a D-bin (as it can contain only items larger than1/2) and by Lemma 4.2.1(i), the total size ofC0 and all D-bins is at least(δ+ 1)/2. Thus we can obtain a contradiction by usingOP T ≥ 7from (i) andδ≤ OP T

(iii): Suppose for a contradiction that δ ≤ 2. Then each F F-bin contains at least two items, except for at most two dedicated F F-bins. Since OP T ≥ 7 from (i), we can apply Lemma 4.2.1(iv) for theF F −2≥3of2+-bins and Lemma 4.2.1(i) for the remaining two bins, and thus

(iv): To obtain the first bound from the second one, useτ = 1and the integrality ofOP T. Now suppose for a contradiction thatγ ≤(OP T +τ)/2. Ifγ ≥3, then we use Lemma 4.2.1(iv) for the common bins, Lemma 4.2.1(i) for the dedicated bins, and the fact that the remaining bins are big, and we obtain

a contradiction. Ifγ ≤2then

usingτ ≥1and (i) in the last step, and we obtain a contradiction as well. 2 The weight function and the main lemma. Now we introduce the main ingredients of our analysis: the modified weight function and the main lemma that is used for the amortized analysis of the weight of F F bins. As in the simple proof in the introduction and previous bin packing literature, our ultimate goal is to prove that eachOP T-bin has weight at most 1.7and eachF F -bin has an amortized (average) weight at least1.

It is convenient to describe the weight of each itemain two parts. The first part,r(a), is called the regular (part of the) weight, and it is proportional to the size ofa; it is the same as in the simple proof. The other part,v(a)is called the bonus and it is modified so that it depends both on the size ofaand the type ofF F-bin whereais packed. B-items have no bonus.C-items have bonus equal to0for items of size at most1/6, equal to0.1for items of size at least1/3, and linearly interpolated between these values.D-items have bonus0.4if they have size at least1/2and slightly smaller if they have smaller size (this concerns only the single itemd0).

Compared to the simple proof and the previous literature, we make several modifications to the weight function. These are mostly a matter of convenience and simplification of the case analysis in the proof. First, we move the bonus from the items larger than1/2to theD-items. Mostly these are actually the same items, except ford0. As we shall see later, in the tight cases, eachOP T-bin contains a D-item and this change allows a more uniform analysis. Second, we decrease some of the weights that we do not use in the proof, namely we do not put any bonus on B-items and decrease the bonus ond0 (this is necessary to guarantee that itsOP T-bin has weight at most1.7;

however, in tight casesd0 is very close to1/2).

The third change is essential in our last step of the proof where we remove the remaining additive constant of 0.1. We define a set of at most two exceptional C-items whose bonus is decreased to 0. Since they are in different3+-bins in the F F packing, this does not change the analysis of the F F packing significantly. On the other hand, the exceptional items are chosen so that one OP T-bin is guaranteed to have weight at most 1.6, which is exactly the necessary improvement. Formally we define the exceptional items as follows:

Definition 4.2.1 IfOP T ≡ 7(mod 10)and there exists anOP T-binE that contains no C2-item, then fix any such binE for the rest of the proof. OtherwiseE is undefined. IfE contains at most two C-items with size larger than 1/6, denote the set of these items E0. Otherwise (if there are three or more C-items inE or noE exists) put E0 =∅. Let us callE theexceptionalbin and the items inE0theexceptionalitems.

Note that there is at most one exceptional item in eachF F-bin by Assumption 4.2.1. Later we shall show that in a potential counterexample withF F = 1.7·OP T + 0.1the binE exists.

Definition 4.2.2 The weight function is defined as follows:

For a B-itembwe define v(b) = 0.

For a C-itemcwe define v(c) =





0 ifc≤ 16 orc∈E0,

3

5(c− 16) ifc∈1

6,13

andc6∈E0, 0.1 ifc≥ 13 andc6∈E0. For a D-itemdwe define v(d) =

(0.4 ifd≥ 12, 0.4− 35(12 −d) ifd < 12. For every itemawe define r(a) = 65aandw(a) =r(a) +v(a).

For a set of itemsAand a set of binsA, letw(A)andw(A)denote the total weight of all items inAorA; similarly forrandv. Furthermore, letW =w(I)be the total weight ofI.

In Definition 4.2.2 the functionv is continuous on the boundary of the cases. Furthermore, if we have a set A of k C-items with size in [16,13] (and no of them is exceptional item), then the definition implies that its bonus is exactlyv(A) = 35 s(A)− k6

. More generally, ifAcontainsk items, each of size at least1/6and noD-item, then we get an upper boundv(A)≤ 35 s(A)−k6

. First we analyze the weight of theOP T-bins.

Lemma 4.2.3 For every optimal binAits weightw(A)can be bounded as follows:

(i)w(A)≤1.7.

(ii) IfEis the exceptionalOP T-bin thenw(E)≤1.6.

(iii) IfAcontains no D-item, thenw(A)≤1.5.

Proof. In all casesr(A)≤1.2, thus it remains to boundv(A). We distinguish three cases:

Case 1:Acontains noD-item. Either it contains at least 4 items with non-zero bonus, in which case their total bonus is at mostv(A)≤ 35(s(A)− 46)≤ 35 · 26 = 0.2. Or else it contains at most3 items with non-zero bonus andv(A)≤ 0.3. In both subcases (iii) follows and thus (ii) also holds ifE =A.

Case 2: A contains a D-item larger than1/2. The bonus of the D-item is0.4. In addition, Acontains at most 2items larger than1/6of total sizeyat most y < 1/2; they may be B-items or C-items. If E = A then they have no bonus and both (i) and (ii) hold. Otherwise we have v(A)≤0.4 + 35(y− 26)<0.4 + 35 · 16 = 0.5and (i) follows.

Case 3: Acontainsd0. Let the size ofd0 be 12 −xforx≥ 0. We havev(d0) = 0.4− 35x. We distinguish two subcases.

Case 3.1: Acontains at most two items other thand0and larger than1/6. Then their total size is at most 12 +x. IfE = A then they have no bonus and both (i) and (ii) hold. Otherwise their bonus is at most0.1 + 35xand (i) holds.

Case 3.2: IfAcontains at least three items other thand0and larger than1/6. Then their total bonus is at most 35x, thusv(A)≤0.4and both (i) and (ii) hold. (This subcase may also happen if E =A, but there is no need to distinguish this in the proof.) 2

Next we analyze the weight ofF F-bins. The case of big and dedicated bins is easy:

Lemma 4.2.4 (i) The total weight of the big bins isw(B)≥β.

(ii) The total weight of the dedicated bins isw(D)> δ.

Proof. (i): For every big binB,w(B) =r(B) = 65s(B)≥ 65 · 56 = 1. Now we focus on the commonF F-bins. The next lemma gives the key insight for the amor-tized analysis. It shows that for most common bins, the regular weight of the bin plus the bonus of thenextcommon bin is at least1. A similar method was used for the analysis ofBF in [70]. For the rest of the upper bound proof, number the common bins asC1, . . . , Cγ, in the order of their

Proof. If Ci is a2-bin, then it contains no exceptional item. IfCi is a3+-bin, then it contains at most one exceptional item by Assumption 4.2.1. In both cases c and c0 exist. Since Ci−1 is common, the size of this bin is smaller than 5/6and it is at least 2/3 by the assumption of the lemma. Letx∈(0,16]be such thats(Ci−1) = 56 −x. Thusc, c0 > 16 +xandv(c), v(c0)> 35x. We getr(Ci−1) +v(c) +v(c0)> 65(56 −x) + 35x+35x= 1. 2 The outline of the rest of the proof is this: We will prove that the commonF F-bins have total weight at least γ −0.2 (note that this follows almost immediately from Lemma 4.2.5 if there is no common bin smaller than2/3). Since the total weight of the dedicated bins is strictly greater thanδ, this impliesW > F F −0.2. Together withW ≤1.7·OP T nowF F ≤1.7·OP T + 0.1 follows. However,F F = 1.7·OP T + 0.1can hold only if OP T ≡ 7(mod 10). Then we show that the exceptional bin is defined, thusW ≤1.7·OP T −0.1and we save the last0.1.

The analysis is considerably harder in case when the last common bin is smaller than2/3, thus we will distinguish between these two main cases later: the last common bin is big or small.

Lemma 4.2.6 Supposew(C)≥γ−0.2. Then (i)F F ≤1.7·OP T + 0.1, and

(ii) if the exceptional binE is defined, thenF F ≤1.7·OP T.

Proof. By Lemma 4.2.4 and the assumption we have W > β + (γ −0.2) +δ = F F −0.2.

By Lemma 4.2.3(i) we have W ≤ 1.7· OP T. Thus F F − 0.2 < W ≤ 1.7· OP T. Since F F andOP T are integers, (i) follows. IfE is defined then by Lemma 4.2.3(i) and (ii) we have W ≤1.7·OP T −0.1. ThusF F −0.2< W ≤1.7·OP T −0.1and (ii) follows. 2 To decrease the bound by the last one tenth, we only need to show that the exceptional OP T -bin is defined. First yet another auxiliary lemma:

Lemma 4.2.7 Suppose that every OP T-bin contains aD-item. Then no OP T bin contains two 2-itemsc1andc2.

Proof. For contradiction, assume we have suchc1 and c2 and number them so that theF F-bin of c1 is before the F F-bin of c2. (Note that by Assumption 4.2.1, c1 and c2 are not in the same F F-bin.) Letc3be the other item in theF F-bin ofc1. Sincec2was not packed into this bin, which contains onlyc1 andc3, we havec1 +c2+c3 >1. This implies thatc3 cannot be in theOP T-bin of c1 and c2. EveryOP T-bin contains a D-item by the assumption; let d1 be the D-item in the OP T-bin ofc1 andc2 andd3 the D-item in the OP T-bin ofc3. By Lemma 4.2.1(i),d1 +d3 >1 and thusc1+c2+c3+d1+d3 >2. As all these items are in twoOP T-bins, this is a contradiction.

2

Proposition 4.2.1 Suppose thatw(C)≥γ−0.2. ThenF F ≤1.7·OP T.

Proof. By Lemma 4.2.6 (i) we have F F ≤ 1.7·OP T + 0.1. If OP T 6≡ 7 mod(10)then by checking all the other residue classes we can verify that 1.7·OP T + 0.1 is non-integral. Thus F F ≤ 1.7·OP T + 0.1 implies F F ≤ 1.7·OP T and we are done. It remains to handle the case whenOP T ≡ 7 mod(10)andF F = 1.7·OP T + 0.1. First we claim that every OP T-bin contains a D-item and thusδ = OP T. If some OP T-bin does not contain a D-item, its weight is at most 1.5 by Lemma 4.2.3(iii). Thus W ≤ 1.7· OP T −0.2. Since F F > W − 0.2, we obtainF F ≤ 1.7·OP T, a contradiction. Lemma 4.2.7 now implies that no OP T-bin contains twoC2-items. Note thatOP T is odd, asOP T ≡ 7 mod(10). On the other hand, the number of C2-items is even (in anyF F-bin there are either zero or two C2-items). Thus some OP T-bin contains noC2-item. This bin satisfies all the conditions of Definition 4.2.1 of the exceptional bin.

ThusE is defined and by Lemma 4.2.6(ii) the proposition follows. 2

4.2.1 The last common bin is large

Now we prove that if the last common bin is large, then the total weight of the common bins is w(C)≥γ−0.2. By this, our proof is complete in this case.

Lemma 4.2.8 Ifs(Cγ)≥2/3, then the total weight of the common bins isw(C)≥γ −0.2.

Proof. First consider the case when every common bin has size at least2/3. We apply Lemma 4.2.5 for everyi= 2, . . . , γ. The regular weight of the last bin is at leastr(Cγ)≥ 65·23 = 0.8. Summing all of these inequalities we obtain

w(C) =

γ

X

i=1

w(Ci)≥r(Cγ) +

γ

X

i=2

(r(Ci−1) +v(Ci))≥0.8 + (γ−1) =γ−0.2.

Now suppose thats(Ck) = 2/3−xforx >0and1≤k < γ. Using Lemma 4.2.1(iii), eachCj,j >

k, contains (exactly) two items larger than1/3 +x. Thusv(Cj) = 0.2and alsos(Cj)>2/3 + 2x which impliesPγ

i=ks(Ci)>(γ+ 1−k)23. Combining these we haver(Ck) +Pγ

j=k+1w(Cj)≥ (γ + 1− k) −0.2. Adding the last inequality and the inequalities r(Ci−1) +v(Ci) ≥ 1 from Lemma 4.2.5 fori= 2, . . . , k, the lemma follows also in this case. 2

We gained the next Theorem:

Theorem 4.2.1 For any instance of bin packing, in the last common bin is large, then F F ≤ 1.7·OP T.

4.2.2 The last common bin is small

Suppose the last common bin is small, i.e. s(Cγ)< 2/3. The analysis of this case goes along the line of the case when the last common bin is large. This investigation is a bit more technical, so it is put into Appendix C.