An Improved FPTAS for 0-1 Knapsack Ce Jin Tsinghua University 0-1 - - PowerPoint PPT Presentation

β–Ά
an improved fptas for 0 1 knapsack
SMART_READER_LITE
LIVE PREVIEW

An Improved FPTAS for 0-1 Knapsack Ce Jin Tsinghua University 0-1 - - PowerPoint PPT Presentation

An Improved FPTAS for 0-1 Knapsack Ce Jin Tsinghua University 0-1 Knapsack Problem Given: Knapsack capacity > 0 items Each item has weight 0 < and profit > 0 Find a subset of items


slide-1
SLIDE 1

An Improved FPTAS for 0-1 Knapsack

Ce Jin Tsinghua University

slide-2
SLIDE 2

π‘œ items Each item 𝑗 has weight 0 < π‘₯𝑗 ≀ 𝑋 and profit π‘žπ‘— > 0

Given:

  • π‘₯ 𝐽 ≔ Οƒπ‘—βˆˆπ½ π‘₯𝑗 ≀ 𝑋
  • π‘ž 𝐽 ≔ Οƒπ‘—βˆˆπ½ π‘žπ‘— is maximized

Find a subset of items 𝐽 βŠ† π‘œ such that:

0-1 Knapsack Problem

Knapsack capacity 𝑋 > 0

slide-3
SLIDE 3

π‘œ items Each item 𝑗 has weight 0 < π‘₯𝑗 ≀ 𝑋 and profit π‘žπ‘— > 0

Given:

  • π‘₯ 𝐽 ≔ Οƒπ‘—βˆˆπ½ π‘₯𝑗 ≀ 𝑋
  • π‘ž 𝐽 ≔ Οƒπ‘—βˆˆπ½ π‘žπ‘— is maximized

Find a subset of items 𝐽 βŠ† π‘œ such that: A well-known NP-hard problem

0-1 Knapsack Problem

Knapsack capacity 𝑋 > 0

slide-4
SLIDE 4

FPTAS for 0-1 Knapsack

OPT = optimal total profit π‘ž(𝐽) For 𝜁 > 0, find a subset 𝐽 βŠ† π‘œ such that:

  • π‘₯ 𝐽 ≀ 𝑋
  • π‘ž 𝐽 β‰₯

OPT 1+𝜁

Solvable in poly π‘œ,

1 𝜁 time

slide-5
SLIDE 5

Prior Work

  • ΰ·¨

𝑃(π‘œ3/𝜁) (textbook algorithm)

  • ΰ·¨

𝑃(π‘œ + πœβˆ’4) [Ibarra and Kim, 1975]

  • ΰ·¨

𝑃(π‘œ + πœβˆ’3) [Kellerer and Pferschy, 2004]

  • ΰ·¨

𝑃(π‘œ + πœβˆ’2.5) [Rhee, 2015]

  • ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ“) [Chan, 2018]

FPTAS for 0-1 Knapsack:

slide-6
SLIDE 6

Prior Work

  • ΰ·¨

𝑃(π‘œ3/𝜁) (textbook algorithm)

  • ΰ·¨

𝑃(π‘œ + πœβˆ’4) [Ibarra and Kim, 1975]

  • ΰ·¨

𝑃(π‘œ + πœβˆ’3) [Kellerer and Pferschy, 2004]

  • ΰ·¨

𝑃(π‘œ + πœβˆ’2.5) [Rhee, 2015]

  • ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ“) [Chan, 2018]

  • ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ‘πŸ”) (this work) FPTAS for 0-1 Knapsack:

No 𝑃 π‘œ + πœβˆ’1 2βˆ’πœ€ time algorithm,

unless 𝐧𝐣𝐨, + convolution has truly subquadratic algo [Cygan, Mucha, WΔ™grzycki, and WΕ‚odarczyk, 2017]

Conditional Lower Bound:

slide-7
SLIDE 7

A Special Case

FPTAS for Subset Sum (π‘žπ‘— = π‘₯𝑗):

  • ΰ·¨

𝑃 min 𝒐 + πœ»βˆ’πŸ‘, π‘œπœβˆ’1 [Kellerer, Mansini, Pferschy, and Speranza, 2003]

slide-8
SLIDE 8

A Special Case

FPTAS for Subset Sum (π‘žπ‘— = π‘₯𝑗):

  • ΰ·¨

𝑃 min 𝒐 + πœ»βˆ’πŸ‘, π‘œπœβˆ’1 [Kellerer, Mansini, Pferschy, and Speranza, 2003]

Our 0-1 Knapsack algorithm utilizes this result

slide-9
SLIDE 9
  • Our ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ‘πŸ”) algorithm builds on Chan’s ΰ·© 𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ“) algorithm

  • Two new ideas
  • 1. Extending Chan’s number-theoretic

technique from two levels to multiple levels.

slide-10
SLIDE 10
  • Our ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ‘πŸ”) algorithm builds on Chan’s ΰ·© 𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ“) algorithm

  • Two new ideas
  • 1. Extending Chan’s number-theoretic

technique from two levels to multiple levels.

  • 2. A greedy argument β‡’ less computation

spent on cheap items (small unit profit π‘žπ‘—/π‘₯𝑗)

slide-11
SLIDE 11
  • Our ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ‘πŸ”) algorithm builds on Chan’s ΰ·© 𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ“) algorithm

  • Two new ideas
  • 1. Extending Chan’s number-theoretic

technique from two levels to multiple levels.

  • 2. A greedy argument β‡’ less computation

spent on cheap items (small unit profit π‘žπ‘—/π‘₯𝑗)

This talk

slide-12
SLIDE 12
  • Our ΰ·©

𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ‘πŸ”) algorithm builds on Chan’s ΰ·© 𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ“) algorithm

  • Two new ideas
  • 1. Extending Chan’s number-theoretic

technique from two levels to multiple levels.

  • 2. A greedy argument β‡’ less computation

spent on cheap items (small unit profit π‘žπ‘—/π‘₯𝑗)

This talk

Using Chan’s Lemmas as blackboxes

ΰ·© 𝑷(𝒐 + πœ»βˆ’πŸ‘.πŸ’πŸ’πŸ’) algo

Preliminaries (based

  • n [Chan, 2018])
slide-13
SLIDE 13

Preliminaries

  • Assume π‘œ ≀ poly πœβˆ’1 .
  • Too cheap items (π‘žπ‘— <

𝜁 π‘œ max π‘˜

π‘žπ‘˜) are discarded at the beginning (loss ≀ 𝜁 β‹… OPT) So

max π‘žπ‘˜ min π‘žπ‘˜ ≀ poly πœβˆ’1

π‘œ items, capacity = 𝑋 weight 0 < π‘₯𝑗 ≀ 𝑋 and profit π‘žπ‘— > 0

slide-14
SLIDE 14

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋

  • β€œProfit function” (defined over real 𝑦 β‰₯ 0)

𝑔

𝐽 𝑦 = max π‘ž 𝐾 : 𝐾 βŠ† 𝐽, π‘₯ 𝐾 ≀ 𝑦

slide-15
SLIDE 15

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋

  • β€œProfit function” (defined over real 𝑦 β‰₯ 0)

𝑔

𝐽 𝑦 = max π‘ž 𝐾 : 𝐾 βŠ† 𝐽, π‘₯ 𝐾 ≀ 𝑦

  • Task: compute a 1 + 𝜁 -approximation of profit

function 𝑔

𝐽,

ΰ·© 𝑔

𝐽 𝑦 ≀ 𝑔 𝐽 𝑦 ≀ 1 + 𝜁 ΰ·©

𝑔

𝐽 𝑦 , βˆ€π‘¦ β‰₯ 0

slide-16
SLIDE 16

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋

  • β€œProfit function” (defined over real 𝑦 β‰₯ 0)

𝑔

𝐽 𝑦 = max π‘ž 𝐾 : 𝐾 βŠ† 𝐽, π‘₯ 𝐾 ≀ 𝑦

  • Task: compute a 1 + 𝜁 -approximation of profit

function 𝑔

𝐽,

ΰ·© 𝑔

𝐽 𝑦 ≀ 𝑔 𝐽 𝑦 ≀ 1 + 𝜁 ΰ·©

𝑔

𝐽 𝑦 , βˆ€π‘¦ β‰₯ 0

  • For disjoint sets 𝐽, 𝐾 of items,

𝑔

𝐽βˆͺ𝐾 𝑦 = 𝑔 𝐽 βŠ• 𝑔 𝐾

𝑦 ≔ max

0≀𝑧≀𝑦 𝑔 𝐽 𝑧 + 𝑔 𝐾 𝑦 βˆ’ 𝑧

slide-17
SLIDE 17

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋

  • β€œProfit function” (defined over real 𝑦 β‰₯ 0)

𝑔

𝐽 𝑦 = max π‘ž 𝐾 : 𝐾 βŠ† 𝐽, π‘₯ 𝐾 ≀ 𝑦

  • Task: compute a 1 + 𝜁 -approximation of profit

function 𝑔

𝐽,

ΰ·© 𝑔

𝐽 𝑦 ≀ 𝑔 𝐽 𝑦 ≀ 1 + 𝜁 ΰ·©

𝑔

𝐽 𝑦 , βˆ€π‘¦ β‰₯ 0

  • For disjoint sets 𝐽, 𝐾 of items,

𝑔

𝐽βˆͺ𝐾 𝑦 = 𝑔 𝐽 βŠ• 𝑔 𝐾

𝑦 ≔ max

0≀𝑧≀𝑦 𝑔 𝐽 𝑧 + 𝑔 𝐾 𝑦 βˆ’ 𝑧

  • ΰ·©

𝑔

𝐽 βŠ• ΰ·©

𝑔

𝐾 is a 1 + 𝜁 -approximation of 𝑔 𝐽βˆͺ𝐾

slide-18
SLIDE 18

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1

  • A nondecreasing step function 𝑔 has a

(1 + 𝜁)-approx. with only ΰ·¨ 𝑃 1/𝜁 steps (by rounding down to powers of (1 + 𝜁))

slide-19
SLIDE 19

Preliminaries

  • A nondecreasing step function 𝑔 has a

(1 + 𝜁)-approx. with only ΰ·¨ 𝑃 1/𝜁 steps (by rounding down to powers of (1 + 𝜁))

  • β€œMerging Lemma”: Computing (a 1 + 𝜁 -
  • approx. of) 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛 takes ΰ·¨

𝑃 𝑛/𝜁2 time. (log 𝑛 depth binary tree. πœβ€² ≔ 𝜁/ log 𝑛)

𝑔 βŠ• 𝑕 ≔ max

0≀𝑧≀𝑦 𝑔 𝑧 + 𝑕 𝑦 βˆ’ 𝑧

slide-20
SLIDE 20
  • Divide items into 𝑃 log 1/𝜁 groups

(group 𝑙: π‘žπ‘— ∈ [2𝑙, 2𝑙+1])

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋 Merging 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛: ΰ·¨

𝑃 𝑛/𝜁2 time.

slide-21
SLIDE 21
  • Divide items into 𝑃 log 1/𝜁 groups

(group 𝑙: π‘žπ‘— ∈ [2𝑙, 2𝑙+1])

  • Compute all 𝑔

𝑙 and merge them in

ΰ·¨ 𝑃(1/𝜁2) time

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋 Merging 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛: ΰ·¨

𝑃 𝑛/𝜁2 time.

slide-22
SLIDE 22
  • Divide items into 𝑃 log 1/𝜁 groups

(group 𝑙: π‘žπ‘— ∈ [2𝑙, 2𝑙+1])

  • Compute all 𝑔

𝑙 and merge them in

ΰ·¨ 𝑃(1/𝜁2) time

  • Now assume π‘žπ‘— ∈ [1,2]

Preliminaries

π‘œ ≀ poly πœβˆ’1 items profit max π‘žπ‘˜/min π‘žπ‘˜ ≀ poly πœβˆ’1 weight 0 < π‘₯𝑗 ≀ 𝑋 Merging 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛: ΰ·¨

𝑃 𝑛/𝜁2 time.

slide-23
SLIDE 23
  • Simple greedy (sort by unit profit

π‘ž1 π‘₯1 β‰₯ π‘ž2 π‘₯2 β‰₯ β‹―)

approximates with additive error 𝑒 ≀ max π‘žπ‘— = 𝑃(1)

profit π‘žπ‘— ∈ 1,2 weight 0 < π‘₯𝑗 ≀ 𝑋

Preliminaries

slide-24
SLIDE 24
  • Simple greedy (sort by unit profit

π‘ž1 π‘₯1 β‰₯ π‘ž2 π‘₯2 β‰₯ β‹―)

approximates with additive error 𝑒 ≀ max π‘žπ‘— = 𝑃(1)

  • For 𝑔 π‘₯ β‰₯ Ξ©(πœβˆ’1), this is 1 + 𝑃(𝜁)

multiplicative approx.

profit π‘žπ‘— ∈ 1,2 weight 0 < π‘₯𝑗 ≀ 𝑋

Preliminaries

slide-25
SLIDE 25
  • Simple greedy (sort by unit profit

π‘ž1 π‘₯1 β‰₯ π‘ž2 π‘₯2 β‰₯ β‹―)

approximates with additive error 𝑒 ≀ max π‘žπ‘— = 𝑃(1)

  • For 𝑔 π‘₯ β‰₯ Ξ©(πœβˆ’1), this is 1 + 𝑃(𝜁)

multiplicative approx.

  • Only need to 1 + 𝑃(𝜁) approximate

𝐧𝐣𝐨 π‘ͺ, π’ˆπ‘± for π‘ͺ = 𝑷 πœ»βˆ’πŸ !

profit π‘žπ‘— ∈ 1,2 weight 0 < π‘₯𝑗 ≀ 𝑋

Preliminaries

slide-26
SLIDE 26
  • Round π‘žπ‘— down to 1,1 + 𝜁, 1 + 2𝜁, … , 2 βˆ’ 𝜁

1 + 𝜁 multiplicative error

  • Only 𝑛 = 𝑃(1/𝜁) different π‘žπ‘—β€™s!

Preliminaries

π‘žπ‘— ∈ 1,2

slide-27
SLIDE 27
  • Round π‘žπ‘— down to 1,1 + 𝜁, 1 + 2𝜁, … , 2 βˆ’ 𝜁

1 + 𝜁 multiplicative error

  • Only 𝑛 = 𝑃(1/𝜁) different π‘žπ‘—β€™s!
  • Collect all items with the same profit 𝒒.

Then 𝑔

π‘ž can be computed by simple

greedy (sort π‘₯1 ≀ π‘₯2 ≀ β‹―)

Preliminaries

π‘žπ‘— ∈ 1,2

slide-28
SLIDE 28

Recap

π‘žπ‘— ∈ 1,2 Profit functions 𝑔

1, … , 𝑔 𝑛 obtained by simple

greedy (one for every π‘žπ‘—) (𝑛 = 𝑃(1/𝜁) ) Task: 1 + 𝑃 𝜁 approximate min 𝐢, 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛

(𝐢 = 𝑃(πœβˆ’1)) Lemma: Merging 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛 in ΰ·¨

𝑃 𝑛/𝜁2 time.

(Immediately gives ΰ·¨

𝑃(π‘œ + πœβˆ’3) algo)

slide-29
SLIDE 29

π‘œ items with 𝑛 = 𝑃(πœβˆ’1) distinct profit values π‘žπ‘— ∈ 1,2 Task: 1 + 𝑃 𝜁 approximate min 𝐢, 𝑔

1 βŠ• β‹― βŠ• 𝑔 𝑛

(𝐢 = 𝑃(πœβˆ’1))

ΰ·¨ 𝑃 πœβˆ’1 𝐢𝑛 algo

(faster when π‘ͺ small)

ΰ·¨ 𝑃(πœβˆ’4/3π‘œ + πœβˆ’2) algo

(faster when 𝒐 small)

Chan’s results

slide-30
SLIDE 30

A Greedy Lemma

  • the items can be divided into two groups

𝐼, 𝑀 with a large enough gap between their unit profits, max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

  • and group 𝐼 is large enough,

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋

π‘žπ‘— ∈ 1,2 capacity = 𝑋

If Then

  • In an optimal solution, 𝑀-items contribute

total profit ≀ 2/𝛽

slide-31
SLIDE 31

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋

  • Suppose the optimal solution is

𝑔

𝐼βˆͺ𝑀 𝑋 = 𝑔 𝐼 𝑋 βˆ’ 𝑋 𝑀 + 𝑔 𝑀 𝑋 𝑀

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝐼 𝑀

slide-32
SLIDE 32

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋

  • Remove all 𝑀-items, and insert more 𝐼-items

(denoted by 𝐿) to fill in the 𝑋

𝑀 space

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝐼 𝑀

slide-33
SLIDE 33

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒπ’Šβˆˆπ‘° π’™π’Š > 𝑿

  • Remove all 𝑀-items, and insert more 𝐼-items

(denoted by 𝐿) to fill in the 𝑋

𝑀 space

  • Until 𝑋

𝑀 βˆ’ 𝑋 𝐿 < maxβ„ŽβˆˆπΌ π‘₯β„Ž

𝐼 𝑀

slide-34
SLIDE 34

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

𝒒𝒋 ∈ 𝟐, πŸ‘ capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… 𝐧𝐣𝐨 π’Šβˆˆπ‘° π’’π’Š/π’™π’Š = 1 βˆ’ 𝛽 β‹… 𝒓

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋

  • Remove all 𝑀-items, and insert more 𝐼-items

(denoted by 𝐿) to fill in the 𝑋

𝑀 space

  • Until 𝑋

𝑀 βˆ’ 𝑋 𝐿 < maxβ„ŽβˆˆπΌ π‘₯β„Ž ≀ πŸ‘/𝒓

𝐼 𝑀

slide-35
SLIDE 35

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… 𝐧𝐣𝐨 π’Šβˆˆπ‘° π’’π’Š/π’™π’Š = 1 βˆ’ 𝛽 β‹… 𝒓

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 𝑋

𝑀 βˆ’ 𝑋 𝐿 < 2/π‘Ÿ

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

  • ptimal sol:

𝑔

𝐼βˆͺ𝑀 𝑋 = 𝑔 𝐼 𝑋 βˆ’ 𝑋 𝑀 + 𝑔 𝑀 𝑋 𝑀

tot profit β‰₯ 𝑔

𝐼 𝑋 βˆ’ 𝑋 𝑀 + π‘Ÿπ‘‹ 𝐿

slide-36
SLIDE 36

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… 𝐧𝐣𝐨 π’Šβˆˆπ‘° π’’π’Š/π’™π’Š = 1 βˆ’ 𝛽 β‹… 𝒓

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 𝑋

𝑀 βˆ’ 𝑋 𝐿 < 2/π‘Ÿ

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

  • ptimal sol:

𝑔

𝐼βˆͺ𝑀 𝑋 = 𝑔 𝐼 𝑋 βˆ’ 𝑋 𝑀 + 𝑔 𝑀 𝑋 𝑀

tot profit β‰₯ 𝑔

𝐼 𝑋 βˆ’ 𝑋 𝑀 + π‘Ÿπ‘‹ 𝐿

𝒓𝑿𝑳 ≀ π’ˆπ‘΄ 𝑿𝑴

slide-37
SLIDE 37

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… 𝐧𝐣𝐨 π’Šβˆˆπ‘° π’’π’Š/π’™π’Š = 1 βˆ’ 𝛽 β‹… 𝒓

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 𝑿𝑴 βˆ’ 𝑿𝑳 < πŸ‘/𝒓 𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

  • ptimal sol:

𝑔

𝐼βˆͺ𝑀 𝑋 = 𝑔 𝐼 𝑋 βˆ’ 𝑋 𝑀 + 𝑔 𝑀 𝑋 𝑀

tot profit β‰₯ 𝑔

𝐼 𝑋 βˆ’ 𝑋 𝑀 + π‘Ÿπ‘‹ 𝐿

𝒓𝑿𝑳 ≀ π’ˆπ‘΄ 𝑿𝑴

1 βˆ’ 𝛽 β‹… π‘Ÿ β‹… 𝑋

𝑀 β‰₯ 𝑔 𝑀 𝑋 𝑀

𝑔

𝑀 𝑋 𝑀 β‰₯ π‘Ÿπ‘‹ 𝐿

π‘Ÿπ‘‹

𝐿 > π‘Ÿπ‘‹ 𝑀 βˆ’ 2

↓ 1 βˆ’ 𝛽 β‹… π‘Ÿπ‘‹

𝑀 > π‘Ÿπ‘‹ 𝑀 βˆ’ 2

π›½π‘Ÿπ‘‹

𝑀 < 2

𝑔

𝑀 𝑋 𝑀 < 2/𝛽

slide-38
SLIDE 38

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… 𝐧𝐣𝐨 π’Šβˆˆπ‘° π’’π’Š/π’™π’Š = 1 βˆ’ 𝛽 β‹… 𝒓

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 𝑿𝑴 βˆ’ 𝑿𝑳 < πŸ‘/𝒓 𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

  • ptimal sol:

𝑔

𝐼βˆͺ𝑀 𝑋 = 𝑔 𝐼 𝑋 βˆ’ 𝑋 𝑀 + 𝑔 𝑀 𝑋 𝑀

tot profit β‰₯ 𝑔

𝐼 𝑋 βˆ’ 𝑋 𝑀 + π‘Ÿπ‘‹ 𝐿

𝒓𝑿𝑳 ≀ π’ˆπ‘΄ 𝑿𝑴

1 βˆ’ 𝛽 β‹… π‘Ÿ β‹… 𝑋

𝑀 β‰₯ 𝑔 𝑀 𝑋 𝑀

𝑔

𝑀 𝑋 𝑀 β‰₯ π‘Ÿπ‘‹ 𝐿

π‘Ÿπ‘‹

𝐿 > π‘Ÿπ‘‹ 𝑀 βˆ’ 2

↓ 1 βˆ’ 𝛽 β‹… π‘Ÿπ‘‹

𝑀 > π‘Ÿπ‘‹ 𝑀 βˆ’ 2

↓ π›½π‘Ÿπ‘‹

𝑀 < 2

𝑔

𝑀 𝑋 𝑀 < 2/𝛽

slide-39
SLIDE 39

𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

𝑋

𝐿

π‘žπ‘— ∈ 1,2 capacity = 𝑋 max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… 𝐧𝐣𝐨 π’Šβˆˆπ‘° π’’π’Š/π’™π’Š = 1 βˆ’ 𝛽 β‹… 𝒓

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 𝑿𝑴 βˆ’ 𝑿𝑳 < πŸ‘/𝒓 𝑋 βˆ’ 𝑋

𝑀

𝑋

𝑀

  • ptimal sol:

𝑔

𝐼βˆͺ𝑀 𝑋 = 𝑔 𝐼 𝑋 βˆ’ 𝑋 𝑀 + 𝑔 𝑀 𝑋 𝑀

tot profit β‰₯ 𝑔

𝐼 𝑋 βˆ’ 𝑋 𝑀 + π‘Ÿπ‘‹ 𝐿

𝒓𝑿𝑳 ≀ π’ˆπ‘΄ 𝑿𝑴

𝟐 βˆ’ 𝜷 β‹… 𝒓 β‹… 𝑿𝑴 β‰₯ π’ˆπ‘΄ 𝑿𝑴

𝑔

𝑀 𝑋 𝑀 β‰₯ π‘Ÿπ‘‹ 𝐿

π‘Ÿπ‘‹

𝐿 > π‘Ÿπ‘‹ 𝑀 βˆ’ 2

↓ 1 βˆ’ 𝛽 β‹… π‘Ÿπ‘‹

𝑀 > π‘Ÿπ‘‹ 𝑀 βˆ’ 2

↓ πœ·π’“π‘Ώπ‘΄ < πŸ‘ ↓

π’ˆπ‘΄ 𝑿𝑴 < πŸ‘/𝜷

slide-40
SLIDE 40

Recap

If: max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 Then: In optimal solution of 𝑔

𝐼βˆͺ𝑀(𝑋), 𝑀-items

contribute total profit ≀ 2/𝛽

Task: 1 + 𝑃 𝜁 approximate min 𝐢, 𝑔

𝐽 , 𝐢 = 𝑃(πœβˆ’1)

𝑛 = 𝑃(πœβˆ’1) distinct values π‘žπ‘— ∈ 1,2

ΰ·¨ 𝑃 πœβˆ’1 𝐢𝑛 algo (Chan)

(faster when π‘ͺ small)

ΰ·¨ 𝑃(πœβˆ’4/3π‘œ + πœβˆ’2) algo (Chan)

(faster when 𝒐 small)

slide-41
SLIDE 41

Improved Algorithm

  • Sort the items by π‘žπ‘—/π‘₯𝑗, and divide into

three groups

π‘žπ‘— ∈ 1,2

slide-42
SLIDE 42

Improved Algorithm

  • Sort the items by π‘žπ‘—/π‘₯𝑗, and divide into

three groups 𝐼: top Θ πœβˆ’1 items

π‘žπ‘— ∈ 1,2

slide-43
SLIDE 43

Improved Algorithm

  • Sort the items by π‘žπ‘—/π‘₯𝑗, and divide into

three groups 𝐼: top Θ πœβˆ’1 items 𝑀: (1 βˆ’ 𝛽) multiplicative gap

𝒓 (𝟐 βˆ’ 𝜷)𝒓 π‘žπ‘— ∈ 1,2

slide-44
SLIDE 44

Improved Algorithm

  • Sort the items by π‘žπ‘—/π‘₯𝑗, and divide into

three groups 𝐼: top Θ πœβˆ’1 items 𝑀: (1 βˆ’ 𝛽) multiplicative gap

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝑁: items in between

π‘žπ‘— ∈ 1,2

slide-45
SLIDE 45

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ 𝐼 = Θ(πœβˆ’1) 𝐼 𝑁 𝑀

If: max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 Then: In optimal solution of 𝑔

𝐼βˆͺ𝑀(𝑋), 𝑀-items

contribute total profit ≀ 2/𝛽 Task: 1 + 𝑃 𝜁 approximate min 𝑃(πœβˆ’1), 𝑔

𝐽

π‘žπ‘— ∈ 1,2

slide-46
SLIDE 46

If: max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 Then: In optimal solution of 𝑔

𝐼βˆͺ𝑀(𝑋), 𝑀-items

contribute total profit ≀ 2/𝛽

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ 𝐼 = Θ(πœβˆ’1) 𝐼 𝑁 𝑀 π‘žπ‘— ∈ 1,2

Task: 1 + 𝑃 𝜁 approximate min 𝑃(πœβˆ’1), 𝑔

𝐽

slide-47
SLIDE 47

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ 𝑰 = 𝚰(πœ»βˆ’πŸ) 𝐼 𝑁 𝑀

(If π’ˆπ‘± 𝑿 < 𝑷(πœ»βˆ’πŸ) then 𝑿 < 𝒙(𝑰)) Task: 1 + 𝑃 𝜁 approximate 𝐧𝐣𝐨 𝑷(πœ»βˆ’πŸ), π’ˆπ‘± If: max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 Then: In optimal solution of 𝑔

𝐼βˆͺ𝑀(𝑋), 𝑀-items

contribute total profit ≀ 2/𝛽

𝒒𝒋 ∈ 𝟐, πŸ‘

slide-48
SLIDE 48

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ 𝐼 = Θ(πœβˆ’1) 𝐼 𝑁 𝑀

Task: 1 + 𝑃 𝜁 approximate min 𝑃(πœβˆ’1), 𝑔

𝐽

If: max

β„“βˆˆπ‘€ π‘žβ„“/π‘₯β„“ ≀ 1 βˆ’ 𝛽 β‹… min β„ŽβˆˆπΌ π‘žβ„Ž/π‘₯β„Ž

Οƒβ„ŽβˆˆπΌ π‘₯β„Ž > 𝑋 Then: In optimal solution of 𝑔

𝐼βˆͺ𝑀(𝑋), 𝑀-items

contribute total profit ≀ 2/𝛽

π‘žπ‘— ∈ 1,2 𝐧𝐣𝐨{π’ˆπ‘΄ , πŸ‘/𝜷}

slide-49
SLIDE 49

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ 𝐼 = Θ(πœβˆ’1)

𝐼

𝑁

𝑴

min{𝑔

𝑀 , 2/𝛽}

ΰ·¨ 𝑃 πœβˆ’1 𝐢𝑛 algo (Chan)

(faster when π‘ͺ small)

ΰ·¨ 𝑃(πœβˆ’4/3π‘œ + πœβˆ’2) algo (Chan)

(faster when 𝒐 small)

Let 𝜷 = πœ»πŸ‘/πŸ’ ΰ·© 𝑷(πœ»βˆ’πŸ–/πŸ’) ΰ·© 𝑷(πœ»βˆ’πŸ–/πŸ’)

𝒐 ≔ 𝑰 β‰ˆ 𝟐/𝜻 π‘ͺ ≔ πŸ‘/𝜷 𝑛 ≔ 𝑃 πœβˆ’1

slide-50
SLIDE 50

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝐼

𝑁

𝑴

Let 𝜷 = πœ»πŸ‘/πŸ’

ΰ·¨ 𝑃 πœβˆ’7/3 -time ΰ·¨ 𝑃(πœβˆ’7/3)-time

Group 𝑁: Round π‘žπ‘—/π‘₯𝑗 down to powers of (1 + 𝜁)

slide-51
SLIDE 51

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝐼

𝑁

𝑴

Let 𝜷 = πœ»πŸ‘/πŸ’

ΰ·¨ 𝑃 πœβˆ’7/3 -time ΰ·¨ 𝑃(πœβˆ’7/3)-time

Group 𝑁: Round π‘žπ‘—/π‘₯𝑗 down to powers of (1 + 𝜁) Only log1+𝜁

1 1βˆ’π›½ β‰ˆ 𝛽/𝜁 = πœ»βˆ’πŸ/πŸ’

distinct values of π‘žπ‘—/π‘₯𝑗

slide-52
SLIDE 52

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝐼

𝑁

𝑴

Let 𝜷 = πœ»πŸ‘/πŸ’

ΰ·¨ 𝑃 πœβˆ’7/3 -time ΰ·¨ 𝑃(πœβˆ’7/3)-time

Group 𝑁: Round π‘žπ‘—/π‘₯𝑗 down to powers of (1 + 𝜁) Only log1+𝜁

1 1βˆ’π›½ β‰ˆ 𝛽/𝜁 = πœ»βˆ’πŸ/πŸ’

distinct values of π‘žπ‘—/π‘₯𝑗 Items with the same π‘žπ‘—/π‘₯𝑗 (profit ∝ weight ): a Subset Sum instance

ΰ·¨ 𝑃(π‘œ + πœβˆ’2) time [KMPS03]

slide-53
SLIDE 53

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝐼

𝑁

𝑴

Let 𝜷 = πœ»πŸ‘/πŸ’

ΰ·¨ 𝑃 πœβˆ’7/3 -time ΰ·¨ 𝑃(πœβˆ’7/3)-time

Group 𝑁: Round π‘žπ‘—/π‘₯𝑗 down to powers of (1 + 𝜁) Only log1+𝜁

1 1βˆ’π›½ β‰ˆ 𝛽/𝜁 = πœ»βˆ’πŸ/πŸ’

distinct values of π‘žπ‘—/π‘₯𝑗 Items with the same π‘žπ‘—/π‘₯𝑗 (profit ∝ weight ): a Subset Sum instance

ΰ·¨ 𝑃(π‘œ + πœβˆ’2) time [KMPS03]

Merge πœ»βˆ’πŸ/πŸ’ groups

slide-54
SLIDE 54

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝐼

𝑁

𝑴

Let 𝜷 = πœ»πŸ‘/πŸ’

ΰ·¨ 𝑃 πœβˆ’7/3 -time ΰ·¨ 𝑃(πœβˆ’7/3)-time

Group 𝑁: Round π‘žπ‘—/π‘₯𝑗 down to powers of (1 + 𝜁) Only log1+𝜁

1 1βˆ’π›½ β‰ˆ 𝛽/𝜁 = πœ»βˆ’πŸ/πŸ’

distinct values of π‘žπ‘—/π‘₯𝑗 Items with the same π‘žπ‘—/π‘₯𝑗 (profit ∝ weight ): a Subset Sum instance

ΰ·¨ 𝑃(π‘œ + πœβˆ’2) time [KMPS03] π‘œ + πœ»βˆ’πŸ/πŸ’ β‹… πœβˆ’2

Merge πœ»βˆ’πŸ/πŸ’ groups

slide-55
SLIDE 55

Improved Algorithm

π‘Ÿ (1 βˆ’ 𝛽)π‘Ÿ

𝐼

𝑁

𝑴

Let 𝜷 = πœ»πŸ‘/πŸ’

ΰ·¨ 𝑃 πœβˆ’7/3 -time ΰ·¨ 𝑃(πœβˆ’7/3)-time

Group 𝑁: Round π‘žπ‘—/π‘₯𝑗 down to powers of (1 + 𝜁) Only log1+𝜁

1 1βˆ’π›½ β‰ˆ 𝛽/𝜁 = πœ»βˆ’πŸ/πŸ’

distinct values of π‘žπ‘—/π‘₯𝑗 Items with the same π‘žπ‘—/π‘₯𝑗 (profit ∝ weight ): a Subset Sum instance

ΰ·¨ 𝑃(π‘œ + πœβˆ’2) time [KMPS03] π‘œ + πœ»βˆ’πŸ/πŸ’ β‹… πœβˆ’2

Merge πœ»βˆ’πŸ/πŸ’ groups

Total time: ΰ·© 𝑷 𝒐 + πœ»βˆ’πŸ–/πŸ’

slide-56
SLIDE 56

Further improvement

ΰ·¨ 𝑃 πœβˆ’1 𝐢𝑛 (Chan)

(faster when π‘ͺ small)

ΰ·¨ 𝑃(πœβˆ’4/3π‘œ + πœβˆ’2) (Chan)

(faster when 𝒐 small)

ΰ·¨ 𝑃(πœβˆ’3/2π‘œ3/4 + π‘œ + πœβˆ’2)

(faster when 𝒐 small)

ΰ·¨ 𝑃 πœβˆ’4/3𝐢1/3𝑛2/3

(𝑛2 ≫ πœβˆ’2/𝐢)

(faster when π‘ͺ small)

ΰ·¨ 𝑃(π‘œ + πœβˆ’9/4)

Greedy argument (this talk) extending Chan’s techniques from two levels to multiple levels

slide-57
SLIDE 57

Open problem

Unbounded Knapsack (each item has infinitely many copies) which easily reduces to 0-1 Knapsack: ΰ·¨ 𝑃(π‘œ + πœβˆ’2) [Jansen and Kraft, 2015]

Improve 0-1 Knapsack to ΰ·¨ 𝑃(π‘œ + πœβˆ’2) time?

ΰ·¨ 𝑃 min 𝒐 + πœ»βˆ’πŸ‘, π‘œπœβˆ’1 [Kellerer, Mansini, Pferschy, and Speranza, 2003] Subset Sum:

slide-58
SLIDE 58

Thank you!