assignment # 5 - weebly · 2018. 9. 27. · farukh jabeen algorithms 510 assignment #5 due date:...

15
Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define the class P. Give an example. 2. Define the class NP. Give an example (in NP, but not in P) 3. Define the class NP-Complete. Give an example. 4. Define each of the problems shown in figure 34.13: CIRCUIT-SAT, SAT, 3-CNF-SAT, CLIQUE, SUBSET-SUM, VERTEX-COVER, HAM-CYCLE, TSP. 5. Explain the concept of "reduction" and how it applies to figure 34.13. 1. Define the class P. Give an example. The class P is considered the set of “efficiently” solvable problems. Problems with at least one algorithm that solves the problem in polynomial time with respect to the input size. Polynomial time The number of steps needed relates polynomially to the size of the input. – O(n2), O(n9), O(nc), where c is a constant. – but NOT O(n!), O(2n), when n is the size of the input. Example: Sort: Given a set S of n integers, sort S. Sorting n integers requires time _(n log n). 1, 000, 000 numbers on modern hardware in less than 10 secs. This means that algorithms to search or sort lists are in class P 2. Define the class NP. Give an example (in NP, but not in P) The abbreviation NP refers to "nondeterministic polynomial time" Problems that can be solved within an exponential time with respect to the input size. This includes problems that can be solved in polynomial time.

Upload: others

Post on 04-Oct-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009.

Assignment # 5 .

Chapter 34 NP Completeness

Deliverables:

1. Define the class P. Give an example.

2. Define the class NP. Give an example (in NP, but not in P)

3. Define the class NP-Complete. Give an example.

4. Define each of the problems shown in figure 34.13:

CIRCUIT-SAT, SAT, 3-CNF-SAT, CLIQUE, SUBSET-SUM, VERTEX-COVER, HAM-CYCLE, TSP.

5. Explain the concept of "reduction" and how it applies to figure 34.13.

1. Define the class P. Give an example. The class P is considered the set of “efficiently” solvable problems.

Problems with at least one algorithm that solves the problem in polynomial time with respect to

the input size.

• Polynomial time

– The number of steps needed relates polynomially to the size of the input.

– O(n2), O(n9), O(nc), where c is a constant.

– but NOT O(n!), O(2n), when n is the size of the input.

Example:

Sort: Given a set S of n integers, sort S.

Sorting n integers requires time _(n log n).

1, 000, 000 numbers on modern hardware in less than 10 secs.

This means that algorithms to search or sort lists are in class P

2. Define the class NP. Give an example (in NP, but not in P)

The abbreviation NP refers to "nondeterministic polynomial time"

Problems that can be solved within an exponential time with respect to the input size.

• This includes problems that can be solved in polynomial time.

Page 2: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

The complexity class NP can be defined in terms of NTIME as follows:

. NP examples

The graph isomorphism problem of determining whether two graphs can be drawn identically

All NP-complete problems, e.g.:

A variant of the traveling salesman problem, where we want to know if there is a route of some length

that goes through all the nodes in a certain network

The boolean satisfiability problem, where we want to know if a certain formula in propositional logic

with boolean variables can be true for some value of the variables or not

3. Define the class NP-Complete. Give an example In computational complexity theory, the complexity class NP-complete (abbreviated NP-C or NPC, with

NP standing for nondeterministic polynomial time) is a class of problems having two properties.

1)Any given solution to the problem can be verified quickly (in polynomial time); the set of problems

with this property is called NP.

2)If the problem can be solved quickly (in polynomial time), then so can every problem in NP.

Although any given solution to such a problem can be verified quickly, there is no known efficient way to

locate a solution in the first place, the most notable characteristic of NP-complete problems is that no

fast solution to them is known. That is, the time required to solve the problem using any currently

known algorithm increases very quickly as the size of the problem grows. As a result, the time required

to solve even moderately large versions of many of these problems easily reaches into the billions or

trillions of years, using any amount of computing power available today. As a consequence, determining

whether or not it is possible to solve these problems quickly is one of the principal unsolved problems in

computer science today.

Examples

Travelling salesman problem

In the mathematical field of graph theory the Hamiltonian path problem and the Hamiltonian cycle

problem are problems of determining whether a Hamiltonian path or a Hamiltonian cycle exists in a

given graph (whether directed or undirected). Both problems are NP-complete.

Page 3: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

4. Define each of the problems shown in figure 34.13:

CIRCUIT-SAT, SAT, 3-CNF-SAT, CLIQUE, SUBSET-SUM, VERTEX-COVER,

HAM-CYCLE, TSP.

CIRCUIT-SAT A circuit is a boolean combinational circuit that has a single output. We assume that such a circuit is

built from AND, OR, and NOT gates that are connected by wires.

A circuit is satisfiable if it has an input such that the output has value 1 (true).

CIRCUIT-SAT is NP-Complete.

Example

First we know here , what is mean by a circuit. Consider the standard boolean operator that we used to

define the Satisfiability Problem: AND ( ) , OR( ), and NOT( )Our definition of a circuit is designed to

represent a physical circuit built out of gates that implement these operators. Thus we define a circuit K

to be labeled ,directed acyclic graph , as shown in the figure.

The sources in K(the nodes with no incoming edges) are labeled either with one of the constants ) or 1,

or with the name of the distinct variable. The nodes of the latter type will be referred to as the inputs to

the circuit.

Every other node is labeled with one of the Boolean Operators AND,OR or NOT : nodes labeled with

AND or OR will have two incoming edges, and nodes labeled with NOT will have one incoming edge.

There is a single node with no outgoing edges, and it will represent the output: the result that is

computed by the circuit.

A circuit computes a function of its inputs in the following natural way. We imagine the edges as “wires”

that carry the 0/1 value at the node they emanate from. Each node other than resources will take the

values on its coming edge(s) and apply the Boolean operator that labels it. . The result of this AND, OR

and NOT will be passed along the edge . The overall value computed by the circuit will be the value

computed at the output node.

For example consider the circuit in the following figure. The leftmost two sources are preassigned the

value 1 and 0 and next three sources constitute the inputs. If the inputs are assigned the values 1,0,1

from left to right then we get values 0,1,1 for the gates in the second row, values 1,1 for the gates in

the third row , and the value 1 for the output.

Now the Circuit Satifiability Problem is the following. We are given a circuit as input , and we need to

decide whether there is an assignment of values to the inputs that causes the output to take the value

1. (if so, we will say that the given circuit is satifiable, and as satisfying assignment is one that result in an

output of 1 ). In our example , we have just seen via the assignment 1,0,1 to the inputs so the circuit in

the figure is satisfiable.

Page 4: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

A circuit with three inputs, two additional sources that have assigned truth values and one

output.

SAT

Satisfiability is the problem of determining if the variables of a given Boolean formula can be assigned in

such a way as to make the formula evaluate to TRUE. Equally important is to determine whether no such

assignments exist, which would imply that the function expressed by the formula is identically FALSE for

all possible variable assignments. In this latter case, we would say that the function is unsatisfiable;

otherwise it is satisfiable. To emphasize the binary nature of this problem, it is frequently referred to as

Boolean or propositional satisfiability. The shorthand "SAT" is also commonly used to denote it, with the

implicit understanding that the function and its variables are all binary-valued.

Cook's theorem proves that the Boolean satisfiability problem is NP-complete. Examples of such

problems in Electronic Design Automation include combinational equivalence checking, model checking,

formal verification of pipelined microprocessors, automatic test pattern generation, routing of FPGAs,

and so on. In fact, a SAT-solving engine is now considered to be an essential component in the EDA

toolbox and all EDA vendors provide such a capability .

Page 5: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

3-CNF-SAT

We say that a boolean formula is in 3-CNF (3-Conjunctive Normal Form) if it is the AND

(conjunction) of clauses, each consisting of the OR (disjunction) of three distinct literals (a literal

is a variable or its negation).

The decision problem of whether a 3-CNF formula is satisfiable is called 3-CNF-SAT.

3-CNF-SAT is in NPC.

Here is an example of a formula in 3-CNF-SAT; variables are shown as integers, and the NOT

operation is shown as a minus sign: 2 -3 1

-3 -2 5

-5 3 2

-4 -2 3

1 -4 -2

Each line is a clause, and the whole clause-set is a formula in 3-CNF-SAT. The interpretation of

this clause-set as a Boolean formula is this: (2 OR NOT 3 OR 1) AND (NOT 3 OR NOT 2 OR 5) AND (NOT 5 OR 3 OR 2)

AND (NOT 4 OR NOT 2 OR 3) AND (1 OR NOT 4 OR NOT 2)

Is this formula a member of 3-CNF-SAT? To show that it is, we need a certificate consisting of a

truth assignment that "satisfies" (i.e., makes true) the formula. One assignment to the variables is

this: 1 = True, 2 = False, 3 = True, 4 = False, 5 = False

This is a satisfying assignment because all of the clauses are simultaneously true: (2 OR NOT 3 OR 1) = (False OR NOT True OR True) = True

(NOT 3 OR NOT 2 OR 5) = (NOT True OR NOT False OR False) = True

(NOT 5 OR 3 OR 2) = (NOT False OR True OR False) = True

(NOT 4 OR NOT 2 OR 3) = (NOT False OR NOT False OR True) = True

(1 OR NOT 4 OR NOT 2) = (True OR NOT False OR NOT False) = True

CLIQUE

A clique in a graph is a set of pairwise adjacent vertices. In the graph at the right, vertices 1, 2

and 5 form a clique.

The clique problem is the optimization problem of finding a clique of maximum size in a graph.

CLIQUE = {<G, k>| G is a graph with a clique of size at least k}

Page 6: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

A brute force algorithm to find a clique in a graph is to list all subsets of vertices, V and check each one

to see if it forms a clique. The algorithm is polynomial if k is constant, but not if k is, say, |V|/2.

SUBSET-SUM In computer science, the subset sum problem is an important problem in complexity theory and

cryptography. The problem is this: given a set of integers, does the sum of some non-empty subset

equal exactly zero? For example, given the set { −7, −3, −2, 5, 8}, the answer is YES because the subset {

−3, −2, 5} sums to zero. The problem is NP-Complete.

VERTEX-COVER

In computer science, the Vertex Cover Problem is an NP-complete

problem in complexity theory.

A vertex cover in a graph is a subset of the verticies of the graph,

chosen with the property that one of the endpoints of each edge is in

the subset. In the graph at right, {1,3,5,6} is an example of a vertex

cover.

The vertex cover problem is the optimization problem of finding a

vertex cover of minimum size in a graph. The problem is a decision

problem.

VERTEX COVER = {<G, k>| k <= the number of vertices in G, G is a graph with a clique of size k or less}

A brute force algorithm to find a vertex cover in a graph is to list all subsets of vertices, V and check each

one to see if it forms a vertex cover. The algorithm is polynomial if k is constant, but not if k is, say,

|V|/2.

HAM-CYCLE

In the mathematical field of graph theory, a Hamiltonian path is a path in an undirected graph which

visits each vertex exactly once. A Hamiltonian cycle (or Hamiltonian circuit) is a cycle in an undirected

graph which visits each vertex exactly once and also returns to the starting vertex. Determining whether

such paths and cycles exist in graphs is the Hamiltonian path problem which is NP-complete.

Examples:

a complete graph with more than two vertices is Hamiltonian

every cycle graph is Hamiltonian

every tournament has an odd number of Hamiltonian paths

every platonic solid, considered as a graph, is Hamiltonian

Page 7: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

TSP

Given a complete graph with edge weights, determine the shortest tour that includes all of the vertices

(visit each vertex exactly once, and get back to the starting point)

5. Explain the concept of "reduction" and how it applies to figure 34.1

In computability theory and computational complexity theory

problem into another problem. Depending on the transformation used this c

complexity classes on a set of problems.

problem A is reducible to problem B if solutions to B exist and give solutions to A whenever A has

solutions. Thus, solving A cannot be harder than solving B. We write A

the ≤ to indicate the type of reduction being used

A very simple example of a reduction is from multiplication to squaring.

.

For computational problems, we sa

there is a log-space reduction R such that

x 2 L1 if and only if R(x) 2 L2

for any string x as the input of decision problem for L

Given a complete graph with edge weights, determine the shortest tour that includes all of the vertices

(visit each vertex exactly once, and get back to the starting point)

duction" and how it applies to figure 34.13

computational complexity theory, a reduction is a transformation of one

into another problem. Depending on the transformation used this can be used to define

on a set of problems.

problem A is reducible to problem B if solutions to B exist and give solutions to A whenever A has

us, solving A cannot be harder than solving B. We write A ≤ B, usually with a subscript on

≤ to indicate the type of reduction being used.

A very simple example of a reduction is from multiplication to squaring.

For computational problems, we say language L1 is reducible to L2 if

space reduction R such that

for any string x as the input of decision problem for L1.

Given a complete graph with edge weights, determine the shortest tour that includes all of the vertices

3.

, a reduction is a transformation of one

an be used to define

problem A is reducible to problem B if solutions to B exist and give solutions to A whenever A has

≤ B, usually with a subscript on

Page 8: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

Now we will see that how reduction can apply on above figure. Polynomial-time reduction from circuit satisfiability to SAT: Given a boolean circuit, we can transform it into a boolean formula by creating new output variables for

each gate, and then just writing down the list of gates separated by And. For example, we could

transform the example circuit into a formula as follows:

Now the original circuit is satisfiable if and only if the resulting formula is satisfiable. Given a

satisfying input to the circuit, we can get a satisfying assignment for the formula by computing the

output of every gate. Given a satisfying assignment for the formula, we can get a satisfying input

the circuit by just ignoring the gate variables yi.

We can transform any boolean circuit into a formula in linear time using depth-first search, and

the size of the resulting formula is only a constant factor larger than the size of the circuit.

Reduction of SAT to 3-CNF-SAT Represent the input formula as a binary tree, add variables to represent the values at nodes in the tree,

and rewrite the formula as a conjunction of clauses representing node values.

Page 9: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

Convert clauses to conjunctive normal form using truth tables and DeMorgan’s Laws.

Give each clause exactly 3 literals.

Reduce the 3CNF-satisfiability problem to the CLIQUE problem

3CNF formula

Each clause has three literals

Language:

3CNF-SAT ={ w : w is a satisfiable

3CNF formula}

A 5-clique in graph G

Language:

CLIQUE = { <G,K> : graph

contains a K -clique}

3CNF-SAT is polynomial time reducible to CLIQUE give a polynomial time reduction

of one problem to the other.

Transform formula to graph

Example:

w

Page 10: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define
Page 11: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

The formula is satisfied if and only if the Graph has a 4-clique

Reduction of 3-CNF SAT to SUBSET- SUM

Given a 3-CNF formula φ over variables x1 ,x 2 ,……..x n with clauses C1 , C 2 ,………C k each containing

exactly three distinct literals, the reduction algorithm constructs an instance S,t of the subset-sum

problem such that φ is satisfiable if and only if there is a subset of S whose sum is exactly t. We make

two simplifying assumptions about the formulaφ . First no clause contain both a variable and its

negation , for such a clause is automatically satisfied by any assignment of values to the variables.

Second each variable appears in at least one clause, for otherwise it does not matter what value is

assigned to the variable.

The reduction creates two numbers in set S for each variable x i and two numbers in S for each clause

C j . We shall creates numbers in base 10, where each number contains n+k digits and each digit

corresponds to either one variable or one clause. Base 10 has property we need of preventing carries

from lower digits to higher digits.

In the following figure, we construct a set S and target t as follows. We label each digit position by

either a variable or clause. The least significant k digits are labeled by clauses and the most significant n

digits are labeled by variables.

The target t has a 1 in each digit labeled by a variable and a 4 in each digit labeled by clause.

For each variable x i , there are two integers, v i and v’ i in S. Each has a 1 in the digit labeled by x i and

0’s in the other variable digits. If literal x i appears in clause C j in v i contains a 1. If literal x i

appears in clause C j then the digit labeled by C j in v’ i contains a 1. All other digits labeled by clauses

in v i and v’ i are 0.

All v i and v’ i values in set S are unique.

Page 12: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

For each clause C j there are two integers, s j and s’ j in S. Each has 0’s in all digits other than the one

labeled by C j . For s j , there is 1 in the C j digit, and s’ j has a 2 in this digit. These integers are “slack

variables”, which we use to get each clause-labeled digit position to add to the target value of 4.

x1 x 2 x 3 C1 C 2 C 3 C 4

V 1 = 1 0 0 1 0 0 1

V’ 1 = 1 0 0 0 1 1 0

V 2 = 0 1 0 0 0 0 1

V’ 2 = 0 1 0 1 1 1 0

V 3 = 0 0 1 0 0 1 1

V’ 3 = 0 0 1 1 1 0 0

S 1 = 0 0 0 1 0 0 0

S’ 1 = 0 0 0 2 0 0 0

S 2 = 0 0 0 0 1 0 0

S’ 2 = 0 0 0 0 2 0 0

S 3 = 0 0 0 0 0 1 0

S’ 3 = 0 0 0 0 0 2 0

S 4 = 0 0 0 0 0 0 1

S’ 4 = 0 0 0 0 0 0 2

t = 1 1 1 4 4 4 4

The formula in 3 CNF is φ = C1 ∧ C 2 ∧ C 3 ∧ C 4 where C1 =(x1 ∨ x 2 ∨ x 3 ) , C 2 = ( x1 ∨ x 2

∨ x 3 ) , C 3 = ( x1 ∨ x 2 ∨ x 3 ) and C 4 = (x1 ∨ x 2 ∨ x 3 ). A satisfying assignment of

φ x1 =0, x 2 =0 and x 3 =1 . The set S produced by reduction consists of base 10 numbers shown :

reading from top to the bottom , S= {1001001, 1000110, 100001,101110,10011, 11100, 1000, 2000, 100,

200,10, 20, 1,2}. The target is 111444. The subset S’ ⊆ S is not shaded and it contains v’1 , v’ 2 , v 3

corresponding to satisfying assignment. It also contains slack variables s1 , s’1 , s’ 2 , s 3 , s 4

and s’ 4 to

achieve the target value of 4 in the digits labeled by C1 through C 4 .

Clique problem (G, k) and reduce it to an instance of the Vertex Cover problem

We want to take an instance of the Clique problem (G, k) and reduce it to an instance of the Vertex

Cover problem.

Specifically, we can take an instance of the Clique problem (G, k)and reduce it to the Vertex Cover

problem (G, n – k) where G is the complement of G (it contains all the edges not in G). This reduction

can easily be done in polynomial time.

Page 13: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

To finish the proof, we must show that G has a clique of size k if and only if G has a vertex cover of

size n − k. Take problem (G, k), compute the complement G. Now test if there is a vertex cover of size n − k in G. If there is, then there must be a clique of size k in the original graph.

Suppose there is a clique A of size k in G. Then there will be no edges between any vertices of A in the complement G. This means that V − A will be a vertex cover of size n − k in G. Suppose there is a vertex cover B of size n − k in G. Let A = V − B. Then by definition, there are no edges between any vertices in A. This means that the complement of G(= G) will contain all edges between any pair of vertices in A. This yields a clique of size k. This completes the reduction from Clique to Vertex Cover (in polynomial time).

Reduction from Vertex- Cover to the Hamilton Cycle A widget is a piece of a graph (i.e., we will use it as a subgraph) that enforces certain (graph) properties.

The widgets for reducing VERTEX-COVER to HAMCYCLE correspond to edges in a graph. Each widget

will have exactly 3 ways a hamiltonian cycle can be routed through it. These routes will correspond to

the edge being covered at one end, the other end, or at both ends.

Page 14: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

Let <G,k> be an instance of VERTEX-COVER.

Form a graph consisting of one widget for each vertex in G plus k additional selector vertices.

For each vertex v in G, let its degree be d. Order the incident edges from 1 to d. Add an edge connecting

the bottom of the v side of the widget for edge i to the top of the v side of widget i+1. Add an edge

from each selector vertex to the top of the v side of v’s edge 1, and to the bottom of the v side of v’s

edge d.

The reduction can be made in polynolmial time. If G has a vertex cover of size k, then the widget graph

has a hamiltonian cycle. If the widget graph has a hamiltonian cycle, then G has a vertex cover of size k.

Reduction from Hamilton cycle to the traveling salesman CIS

Hamilton Cycle can be defined as:

Input: An unweighted graph G

Output : Does there exist a simple tour that visits each vertex of G without repetition

Hamilton Cycle some obvious similarity to the traveling salesman problem. Both problems ask for a tour

to visit each vertex exactly once. There are also differences between the two problems. TSP works on

weighted graphs, while Hamilton cycle works on unweighted graphs. The following reduction from

Hamilton cycle to the traveling salesman shows that the similarities are greater than the differences:

The actual reduction is quite simple, with the translation from unweighted to weighted graph easily

performed in linear time. This translation is designed to ensure that the answer of two problems will be

identical. If the graph G has a Hamilton Cycle(V1,…..,Vn) then this exact tour will correspond to n edges

in E’, each with weight 1. Therefore , this gives a TSP tour of G’ of weight exactly n. If G does not have a

Hamilton Cycle, then there can be no such TSP tour in G’, because the only way to get a tour of cost n in

G would be to use only edges of weight 1, which implies a Hamilton Cycle in G.

.

References: http://russell.lums.edu.pk/~cs514s07/slides/lecture4.pdf

Page 15: Assignment # 5 - Weebly · 2018. 9. 27. · Farukh Jabeen Algorithms 510 Assignment #5 Due Date: July 06, 2009. Assignment # 5 . Chapter 34 NP Completeness Deliverables: 1. Define

http://ww3.algorithmdesign.net/handouts/NPComplete.pdf http://www.cs.wmich.edu/~elise/courses/cs6800/Mohamed-The-Classes-P-and-NP.pdf http://en.wikipedia.org/wiki/NP_(complexity_class) http://en.wikipedia.org/wiki/NP-complete http://www.eg.bucknell.edu/~cs350/S09/schedule.html http://en.wikipedia.org/wiki/Hamiltonian_path http://books.google.com/books?id=97GV7qegxJ8C&pg=PA466&lpg=PA466&dq=circuit+satisfiability+CIRCUIT-

SAT&source=bl&ots=LXQhLKZVzO&sig=mXZbCFLVMpVU8Ec2SSLPVt2WTyk&hl=en&ei=SW09SoefHpL0sQP11pj5Cg&sa=X&oi=book_result&ct=r

esult&resnum=6 http://en.wikipedia.org/wiki/Boolean_satisfiability_problem http://www.cs.utsa.edu/~dj/ut/utsa/cs3343/lecture24.html http://www.knowledgerush.com/kr/encyclopedia/Clique_problem/ http://en.wikipedia.org/wiki/Subset_sum_problem http://www.knowledgerush.com/kr/encyclopedia/Vertex_cover_problem/ http://en.wikipedia.org/wiki/Reduction_(complexity) http://staffweb.ncnu.edu.tw/shieng/theory/chap8.pdf http://www.cs.cmu.edu/afs/cs/academic/class/15451-f04/www/recitation/rec1110.txt http://books.google.com/books?id=TrXd-

gxPhVYC&pg=PA142&lpg=PA142&dq=TSP+and+reduction+algorithm&source=bl&ots=Bxv69fD5iI&sig=_6wYrq68MhC-

PiknbfSVRei_YlI&hl=en&ei=fQ5BSqDkBYikswPF6fSKCQ&sa=X&oi=book_result&ct=result&resnum=1 http://www.cis.uoguelph.ca/~sawada/6650/notes/npcomplete-1x2.pdf www.eecs.berkeley.edu/~isabelle/cs302/NP-Completeness.ppt

www.cs.rpi.edu/~buschc/courses/modcomp/.../NP_Complete.ppt

http://ideal.ece.utexas.edu/~ghosh/360C/np.pd http://compgeom.cs.uiuc.edu/~jeffe/teaching/373/notes/16-nphard.pdf http://www.cs.berkeley.edu/~necula/autded/lecture24-sat.pdf www.eg.bucknell.edu/~cs350/S09/Slides/3-CNF-SAT.ppt

http://www.eg.bucknell.edu/~cs350/S09/Slides/HAM-CYCLE.pdf

Text Book