complexity2-handouts

# complexity2-handouts - ECE 537 Foundations of Computing...

This preview shows pages 1–7. Sign up to view the full content.

ECE 537 – Foundations of Computing Module 9, Lecture 2: Complexity Theory – NP-Completeness Proofs Professor G.L. Heileman University of New Mexico Fall 2008 c ± 2008 G. L. Heileman Module 9, Lecture 2

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
NP -completeness Proofs Recall that to prove a problem Π 2 is NP -complete we must: 1 Show Π 2 NP , typically by checking a certiﬁcate in polynomial time. 2 Transform a known NP -complete problem Π 1 to Π 2 : 1 Deﬁne the transformation f : D Π 1 D Π 2 . 2 Show f is polynomial time in terms of the size of the instances. 3 Show I Y Π 1 ⇐⇒ f ( I ) Y Π 2 . c ± 2008 G. L. Heileman Module 9, Lecture 2
Boolean Expressions The SAT problem can be signiﬁcantly restricted, and still remain NP -complete. To see how, we need to deﬁne a few more terms. Deﬁnitions: A literal refers to a Boolean variable or its negation, e.g., x or x . A clause is a collection of literals connected only by disjunctions. Ex : ( x 1 x 2 x 3 x 4 ). A Boolean formula is said to be in conjunctive normal form (CNF) if it contains clauses connected only by conjunctions. Ex : ( x 1 x 2 x 3 x 4 ) ( x 2 x 5 ) ( x 3 x 4 x 6 ). This appears somewhat easier than the general SAT problem — if any one clause evaluates to 0, the entire expression evaluates to 0. c ± 2008 G. L. Heileman Module 9, Lecture 2

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Boolean Expressions You may have seen CNFs referred to as the product-of-sums form in digital logic classes. Every Boolean formula φ can be converted into an equivalent formula φ 0 that is in CNF. It has been shown that CNF satisﬁability NP -complete. A special type of CNF, called 3-CNF , arises if require each clause in a CNF expression to have exactly three literals. Ex : ( x 1 x 2 x 4 ) ( x 2 x 3 x 5 ) ( x 3 x 4 x 6 ). It has been shown that 3-CNF satisﬁability (3-SAT) NP -complete. However, you can show that 2-SAT P . c ± 2008 G. L. Heileman Module 9, Lecture 2
The CLIQUE Problem Deﬁnition : A clique in an undirected graph G = ( V , E ) is a subset V 0 V , where each pair of vertices in V 0 is connected by an edge. I.e., a clique is a completely connected subgraph in G . Ex : The example graph contains a clique of size four (the vertices are shown in blue). c ± 2008 G. L. Heileman Module 9, Lecture 2

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
We can look for the largest clique in a graph — this is the optimization version of the problem. I.e., What is the size of the largest clique in graph G = ( V , E )? In the decision version of the problem, we are asked to determine whether or not a graph contains a clique of a given size: CLIQUE Instance : graph G = ( V , E ) Question : Does G contain a clique of at least size k ? c
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### Page1 / 24

complexity2-handouts - ECE 537 Foundations of Computing...

This preview shows document pages 1 - 7. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online