Vous êtes sur la page 1sur 3

OR 7310 · Fall 2020 1

OR 7310 Logistics, Warehousing, and Scheduling


Fall 2020

Assignment 2, due October 7, 2020

1. (Optional) Describe an algorithm for finding the smallest integer in a finite sequence of natural
numbers.

2. (Optional) Describe an algorithm based on the binary search for determining the correct
position in which to insert a new element in an already sorted list.

3. (Optional) Find the least integer n such that f (x) is O(xn ) for each of the functions below.

(a) f (x) = 2x2 + x3 logx


(b) f (x) = 3x5 + (logx)4
(c) f (x) = (x4 + x2 + 1)/(x4 + 1)
(d) f (x) = (x3 + 5logx)/(x4 + 1)

4. Show that x2 + 4x + 17 is O(x3 ) but that x3 is not O(x2 + 4x + 17).

5. (a) Explain how graphs can be used to model electronic mail messages in a network. Should
the edges be directed or undirected? Should multiple edges be allowed? Should loops
be allowed?
(b) Describe a graph that models the electronic mail sent in a network in a particular week.

6. (Optional) How can a graph that models e-mail messages sent in a network be used to find
people who have recently changed their primary e-mail address?

7. Suppose that a new company has five employees: Zamora, Agraharam, Smith, Chou, and
Macintyre. Each employee will assume one of six responsibilities: planning, publicity, sales,
marketing, development, and industry relations. Each employee is capable of doing one or
more of these jobs: Zamora could do planning, sales, marketing, or industry relations; Agra-
haram could do planning or development; Smith could do publicity, sales, or industry rela-
tions; Chou could do planning, sales, or industry relations; and Macintyre could do planning,
publicity, sales, or industry relations.

(a) Model the capabilities of these employees using a bipartite graph.


(b) Find an assignment of responsibilities such that each employee is assigned a responsibil-
ity.

8. What is the sum of the entries in a row of the adjacency matrix for an undirected graph? For
a directed graph?

9. What is the sum of the entries in a column of the adjacency matrix for an undirected graph?
For a directed graph?
OR 7310 · Fall 2020 2

10. What is the sum of the entries in a row of the incidence matrix for an undirected graph?

11. What is the sum of the entries in a column of the incidence matrix for an undirected graph?

12. Show that an edge in a graph with no parallel edges is a cut edge if and only if this edge is
not part of any simple circuit (cycle with no sub-loops) in the graph.

13. A communication link in a network should be provided with a backup link if its failure makes
it impossible for some message to be sent. For the communication network G with the below
edge set E determine those links that should be backed up.
E = {(SF, LA)(LA, DN )(SF, DN )(Denver, CH), (CH, DC)(DC, N Y C)(N Y C, B)}

14. How many different channels are needed for six stations located at the distances shown in
the table, if two stations cannot use the same channel when they are within 150 miles of each
other?

1 2 3 4 5 6
1 − 85 175 200 50 100
2 85 − 125 175 100 160
3 175 125 − 100 200 250
4 200 175 100 − 210 220
5 50 100 200 210 − 100
6 100 160 250 220 100 −

15. Show that an edge with smallest weight in a connected weighted graph must be part of any
minimum spanning tree.

16. Suppose that the computer network connecting the cities with the given link costs in the
table below must contain a direct link between New York and Denver. What other links
should be included so that there is a link between every two computer centers and the cost
is minimized?

San Francisco Denver Chicago New York Atlanta


San Francisco − 900 1200 2000 2200
Denver 900 − 1300 1600 1400
Chicago 1200 1300 − 1000 700
New York 2000 1600 1000 − 800
Atlanta 2200 1400 700 800 −

17. (Optional) Show that the Constrained Shortest Path Problem is NP-complete by transform-
ing the Knapsack Problem to it.

Knapsack problem Given a finite set of N elements, two integers v ∗ and w∗ , and a value
v(i) and a weight w(i) associated with every element i ∈ N , does some subset S ⊂ N satisfy
the property that i∈S v(i) ≥ v ∗ and i∈S w(i) ≤ w∗ ?
P P
OR 7310 · Fall 2020 3

Constrained shortest path problem Given a directed graph G = (N, A), integers C and
T and an arc length cij and a reversal time tij associated with every arc (i, j) ∈ A, does the
graph contain a directed path from node s to node t whose length is at most C and traversal
time is at most T ?

Vous aimerez peut-être aussi