0% found this document useful (0 votes)
38 views2 pages

Assignment 1

This document contains a homework assignment on discrete optimization. It includes 4 problems: 1) 5 true/false statements about big O notation and limits of functions. 2) Prove that an undirected graph with unique edge costs has a unique minimum spanning tree. 3) Prove that a simple algorithm that adds the cheapest edge between any non-empty subset at each step computes a minimum spanning tree. 4) Analyze an algorithm that connects components with cheapest edges: (a) prove it outputs a minimum spanning tree if it terminates, (b) note how many iterations are needed.

Uploaded by

Joyce Cruz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
38 views2 pages

Assignment 1

This document contains a homework assignment on discrete optimization. It includes 4 problems: 1) 5 true/false statements about big O notation and limits of functions. 2) Prove that an undirected graph with unique edge costs has a unique minimum spanning tree. 3) Prove that a simple algorithm that adds the cheapest edge between any non-empty subset at each step computes a minimum spanning tree. 4) Analyze an algorithm that connects components with cheapest edges: (a) prove it outputs a minimum spanning tree if it terminates, (b) note how many iterations are needed.

Uploaded by

Joyce Cruz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

University of Twente

Bodo Manthey
Discrete Optimization
Homework Assignment 1
Due: September 29, 2014
(1) Are the following statements true or false? Give a short reason or a counterexample.
(a) (1 point) The following holds for all functions f, g : N R
+
:
f = (g) if and only if lim
n
f(n)
g(n)
exists.
(b) (1 point) The following holds for all monotonically increasing, unbounded functions
f, g, h : N N:
If f = O(g), then f h = O(g h).
(The symbol denotes the concatenation of functions, i.e., (f h)(n) = f(h(n)).)
(c) (1 point) The following holds for all monotonically increasing, unbounded functions
f, g, h : N N:
If f = O(g), then h f = O(h g).
(d) (1 point) log(n!) = (n log n).
(e) (1 point) The following holds for all monotonically increasing, unbounded functions
f, g : N R
+
:
Either f (g) or f O(g) or both.
(2) (5 points) Consider an undirected graph G = (V, E) with an injective edge cost function
c : E R.
Prove that G has a unique minimum spanning tree.
(3) (5 points) Consider the following rather stupid algorithm for computing a minimum span-
ning tree of a graph G = (V, E) if the edge costs c : E R
+
are injective:
input: undirected graph G = (V, E), injective edge cost function c : E R
output: minimum spanning tree T of G
1: for all non-empty X V do
2: e argmin
e

(X)
c(e

)
3: T T {e}
4: end for
Prove that the algorithm indeed computes a minimum spanning tree. (Note that T is a
set, not a multi-set.)
page 1 of 2
(4) (10 points) Consider the following algorithm for computing minimum spanning trees:
input: undirected graph G = (V, E), injective edge cost function c : E R
output: minimum spanning tree T of G
1: T
2: while T is not connected do
3: A
4: for each connected component C of T do
5: let e be the cheapest edge in (C)
6: add e to A
7: end for
8: T T A
9: end while
(a) (4 points) Prove that T is a minimum spanning tree if the algorithm terminates.
(b) (1 point) How many iterations of the while loop does the algorithm need?
page 2 of 2

You might also like