This preview shows pages 1–8. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: The first NPcomplete problem The Satisfiability problem (SAT): Given a formula F, find a satisfying truth assignment or else report that none exists. E.g., (x 1 ∨ x 2 ) ∧ (~ x 2 ) : x 1 = true, x 2 = false x 2 ∧ (~ x 2 ) : no satisfying assignment exists. 1 Theorem [Cook 71]: SAT is NPcomplete. CNFSAT CNFSAT CNFSAT CNFSAT Definition. A formula F is in conjunctive normal form ( CNF ) if F is in the form (x 1 ∨ x 2 ∨ ~x 4 ) ∧ (~x 2 ∨ x 5 ) ∧ (x 2 ∨ x 8 ∨ x 9 ) ∧ … I.e., F comprises several clauses connected with ∧ s, where a clause comprises literals (i.e., variables or their negations) onnected with . 2 connected with ∨ s. The CNFSAT problem: Given a CNF formula F, find a satisfying truth assignment or else report that none exists. Such structural restriction doesn’t make the formula satisfiability problem easier. We will prove that CNFSAT is also NPcomplete. 3CNF 3CNF 3CNF 3CNFSAT (3SAT) SAT (3SAT) SAT (3SAT) SAT (3SAT) Further restriction: 3CNFformula is a CNF formula in which every clause contains exactly 3 literals. he 3CNFSAT (or simply SAT problem: Given a 3CNF 3 The 3CNFSAT (or simply 3SAT ) problem: Given a 3CNF formula F, determine whether F is satisfiable. Fact. (1) SAT, CNFSAT, 3CNFSAT ∈ NP; (2) 3CNFSAT ≤ p CNFSAT ≤ p SAT Today’s roadmap Tool: Suppose A ≤ p B and A is NPcomplete. Then B is NPcomplete. SAT ≤ p CNFSAT conclusion: CNFSAT is NPcomplete CNFSAT ≤ p 3 CNFSAT (more commonly known as 3SAT) onclusion: 3CNFSAT is NP omplete 4 conclusion: 3CNFSAT is NPcomplete 3 CNFSAT ≤ p Clique conclusion: Clique is NPcomplete Clique ≤ p Vertex Cover conclusion: Vertex Cover is NPcomplete 3 CNFSAT ≤ p Knapsack conclusion: Knapsack is NPcomplete SAT CNFSAT 3CNFSAT Clique Knapsack … Vertex Cover SAT ≤ p CNFSAT SAT : Give a formula F, find a satisfying truth assignment … Example of a formula : ~(((x 1 ∨ x 2 ) ∧ ~x 4 )) ∧ (~x 2 ∨ x 5 )) ∨ (x 2 ∨ ( x 8 ∧ x 9 ) ) … CNFSAT : Given a CNFformula F’, find … Example of a CNFformula : (x 1 ∨ x 2 ∨ ~x 4 ) ∧ (~x 2 ∨ x 5 ) ∧ (x 2 ∨ x 8 ∨ x 9 ) ∧ … 5 What is the 1st thing to do ? • Let F be any Boolean formula. Show that, in polynomial time, F can be transformed to a CNFformula F’ such that F has a satisfying assignment ⇔ F’ has a satisfying assignment . a clause A literal is a variable or its neagation 2step transformation: F → F 1 → F 2 Step 1 : Transform F to an equivalent formula F 1 such that all ~ (negation) operators are applied to variables only. Tools: ~(E ∧ E’) ≡ ~E ∨ ~E’; ~(E ∨ E’) ≡ ~E ∧ ~E’; 6 ~~E ≡ E E.g., ~(~(x1 ∧ x2) ∨ x3) is logically equivalent to (x1 ∧ x2) ∧ ~x3 Step 2 : Transform F 1 to a CNFformula F 2 recursively ....
View
Full
Document
This note was uploaded on 03/01/2010 for the course CS 1234 taught by Professor Chan during the Spring '10 term at University of the BíoBío.
 Spring '10
 Chan

Click to edit the document details