Maximum Flow
Reading: CLRS Sections 26.1-26.3.
CSE 6331 Algorithms
Steve Lai
Flow Network
A flow network G = (V , E ) is a directed graph with
a source node s V ,
a sink node t V ,
a capacity func
Linear Programming
Reading: CLRS, Ch. 29 or reference
CSE 6331 Algorithms
Steve Lai
Linear functions and linear constraints
Let a1 , a2 , , an , b be real numbers and
let x1 , x2 , , xn be variables.
CSE 6331 Homework 1
Due Tuesday, September 3 by class time
1. Order the following function by asymptotic dominance. That is, produce an order
f1 (n), f2 (n), . . . such that fi = O(fi+1 ).
(a) f (n) =
Examples of Analysis
Give the asymptotic running time of the following algorithms in notation.
Give your solution in the simplest terms possible. Show how you get the answer.
1.
function func1(n)
s 0;
VISUALIZATION
FOR
DOUBLECHECK LCC
Anil Sunke
Cynthea Godwin
Miao-chen Chou
Yen Nei Lee
Tasks Completed before 1st release
Bar Chart
Click event pops up parameters of the graph when clicked on the
ba
CSE 6331 Homework 3
Due: Thursday, September 7 by class time
1. A function T (n) (defined for positive integers n) satisfies the following recurrence:
(
T (n) =
if n 1
c,
3T (bn/4c) + n, if n > 1
wher
CSE 6331 Homework 2
Due: Tuesday, September 5, by class time
We proved the following theorem in class.
Theorem 5. If T (n) is asymptotically nondecreasing and f (n) is smooth, then T (n) =
O(f (n)|n a
CSE 6331 Homework 1
Due Thursday, August 31 by class time
1. Order the following function by asymptotic dominance. That is, produce an order
f1 (n), f2 (n), . . . such that fi = O(fi+1 ).
(a) f (n) =
CIS 6331 Homework 8
Due: Friday, March 22 by class time
Note: use the definition of flow that includes the skew-symmetry condition.
1. Consider a flow network in which vertices, as well as edges, have
CIS 6331 Homework 7
Due: Friday, March 8 by class time
Note: There are four questions; Q4 is on the other side.
1. Prove or disprove the following statement: v is an articulation of G if and only if
t
Divide-and-Conquer
Reading: CLRS Sections 2.3, 4.1, 4.2, 4.3, 28.2, 33.4.
CSE 780 Analysis of Algorithms
Steve Lai
Divide and Conquer
Given an instance x of a problem, the divide-and-conquer
method w
Dynamic Programming
Reading: CLRS Chapter 15 & Section 25.2
CSE 6331: Algorithms
Steve Lai
Optimization Problems
Problems that can be solved by dynamic programming
are typically optimization problems
Greedy Algorithms
CSE 6331
Reading: Sections 16.1, 16.2, 16.3, Chapter 23.
1
Introduction
Optimization Problem:
Construct a sequence or a set of elements cfw_x1 , . . . , xk that satises
given constr
Number-Theoretic Algorithms
Chapter 31, CLRS book
p1.
Modular Arithmetic
p2.
Integers
a | b: a divides b, a is a divisor of b.
gcd( a, b): greatest common divisor of a and b.
Coprime or relatively
CSE 6331 Homework 2
Due: Thursday, September 5, by class time
We proved the following theorem in class.
Theorem 5. If T (n) is asymptotically nondecreasing and f (n) is smooth, then T (n) =
O(f (n)|n
CSE 6361 Homework 3
Due: Thursday, September 12 by class time
1. A function T (n) satises the following recurrence:
cfw_
T (n) =
if n 1
c,
3T (n/4) + n, if n > 1
where c ia a positive constant. Prove
CSE 6331 Homework 4
Due: Monday, February 4
1. Write a divide-and-conquer algorithm that nds the minimum of n integers. Analyze its time complexity assuming the algorithm is run by (1) one processor a
CIS 6331 Homework 5
Due: Monday, February 11 by class time
1. [Coin Changing] Let An = cfw_a1 , a2 , . . . , an be a set of distinct coin types (e.g.,
a1 = 50 cents, a2 = 25 cents, a3 = 10 cents, etc
CIS 6331 Homework 6
Due: Monday, February 25 by class time
For each problem you should give a complete solution, including a recurrence relation, boundary conditions, and a nonrecursive algorithm. You
Mathematical Foundation
CSE 6331 Algorithms
Steve Lai
Be a Thinker!
2
Complexity of Algorithms
Analysis of algorithm: to predict the running time
required by an algorithm.
Elementary operations:
ar