Sabancı University
Faculty of Engineering and Natural Sciences
CS301 – Algorithms
Homework 5
Due: December 8, 2009 (17:40  Recitation @ FASS 1103)
PLEASE NOTE
:
•
Provide only the requested information and nothing more. Unreadable, unintelligible and
irrelevant answers will not be considered.
•
You can collaborate with your friends and discuss the solutions of the problems. However
you have to write down the solutions on your own.
•
Plagiarism will not be tolerated.
•
You don’t have to typeset your answers but feel free to do so if you want to.
•
Please hand in the hard copies of your answer sheets to TAs at the beginning of the recitation
hour on December 8, 2009.
Question 1)
Boxplacement problem can be defined as follows:
We have a set of boxes of
k
different size. Suppose
W
[
i
]
>
0 denote the weight of the box type
i
. We are given a nonnegative
integer value
N
, and we would like to provide the minimal number of boxes whose cumulative
weight is
N
. Formally, let [
k
] denote the set
{
1
,
2
, . . . , k
}
and
S
[
i
] denote the number of boxes of
type
i
selected in the solution. We want to have
∑
i
∈
[
k
]
(
S
[
i
]
W
[
i
]) =
N
with
∑
i
∈
[
k
]
S
[
i
] minimized. You
can assume that we have as many copies of the boxes as needed.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview.
Sign up
to
access the rest of the document.
 Spring '10
 .
 Algorithms, Dynamic Programming, match, Sabanci University Faculty, Natural Sciences CS301, Character matching problem, Boxplacement problem

Click to edit the document details