This preview shows pages 1–5. Sign up to view the full content.
1
COT 6936: Topics in Algorithms
Giri Narasimhan
ECS 254A / EC 2443; Phone: x3748
[email protected]
http://www.cs.fiu.edu/~giri/teach/COT6936_S10.html
https://online.cis.fiu.edu/portal/course/view.php?id=427
1/7/10
1
COT 6936
Semester Schedule
• Milestones:
– By Jan 18:
Meet with me and discuss project
– By Jan 25:
Send me email with project team
information and topic
– Feb 3
rd
week
: Short presentation (15 minutes)
giving intro to project, problem definition,
notation, and background
– March 2
nd
week
: Takehome Exam
– Starting March last week
: Full length
presentation of project (1 hour)
– April 15
: Written report on project
1/7/10
COT 6936
2
Problems from last lecture
• Achieving diversity in heights:
– Largest empty range problem
– Smallest empty range problem
– Which is harder and why?
• Binary Counter
– How many bits were changed when a binary
counter is incremented from 0 to N?
• Drunken Sailors problem
– How many sailors will sleep in their own cabins?
• Homework: Robot Challenge problem
1/7/10
COT 6936
3
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document 2
NPCompleteness
• Computers and Intractability: A Guide to the
theory of NPCompleteness
, by
Garey
and
Johnson
– Compendium (100 pages) of NPComplete and
related problems
1/7/10
COT 6936
4
1/7/10
COT 6936
5
Polynomialtime computations
• An algorithm has (
worstcase
) time
complexity O(T(n)) if it runs in time at most
cT(n) for some c > 0 and for every
input of
length n. [
Time complexity
±
worstcase.
]
• An algorithm is a polynomialtime algorithm if
its (
worstcase
) time complexity is O(p(n)),
where p(n) is some polynomial in n.
[
Polynomial in what?
]
• Composition of polynomials is a polynomial.
[
What are the implications?
]
1/7/10
COT 6936
6
The class
P
• A problem is in
P
if there exists a
polynomialtime algorithm for the problem.
[
is therefore a class of problems, not
algorithms.
]
• Examples of
–
DFS:
Lineartime algorithm exists
–
Sorting:
O(n log n)time algorithm exists
–
Bubble Sort:
Quadratictime algorithm O(n
2
)
–
APSP:
Cubictime algorithm O(n
3
)
3
1/7/10
COT 6936
7
The class
NP
• A problem is in
NP
if there exists a
non
deterministic
polynomialtime algorithm that
solves the problem.
• [
Alternative definition
] A problem is in
if
there exists a (
deterministic
) polynomial
time algorithm that
verifies
a solution to the
problem.
• All problems in
P
are in
.
[
The converse is
the big deal!
]
1/7/10
COT 6936
8
TSP: Traveling Salesperson Problem
•
Input:
– Weighted graph,
G
– Length bound,
B
•
Output:
– Is there a TSP tour in
G
of length at most
B
?
• Is TSP in
?
– YES
. Easy to verify a given solution.
• Is TSP in
P
?
– OPEN
!
– One of the greatest unsolved problems of this century!
– Same as asking:
Is
=
?
1/7/10
COT 6936
9
So, what is
NPComplete
?
•
problems are the “hardest”
problems in
.
• We need to formalize the notion of
“hardest”.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document 4
1/7/10
COT 6936
10
Terminology
• Problem:
– An
abstract problem
is a function (relation) from a set
I
of instances of the problem to a set
S
of solutions.
This is the end of the preview. Sign up
to
access the rest of the document.
This note was uploaded on 02/18/2012 for the course CIS 6936 taught by Professor Giri during the Spring '12 term at FIU.
 Spring '12
 Giri
 Algorithms

Click to edit the document details