Our First NP-Complete Problem - PowerPoint PPT Presentation

1 / 22
About This Presentation
Title:

Our First NP-Complete Problem

Description:

Our First NP-Complete Problem C B A The Cook-Levin theorem Introduction Objectives: To present the first NP-Complete problem Overview: SAT - definition and examples ... – PowerPoint PPT presentation

Number of Views:21
Avg rating:3.0/5.0
Slides: 23
Provided by: 73399
Category:

less

Transcript and Presenter's Notes

Title: Our First NP-Complete Problem


1
Our First NP-Complete Problem
C
B
A
  • The Cook-Levin theorem

2
Introduction
?
  • Objectives
  • To present the first NP-Complete problem
  • Overview
  • SAT - definition and examples
  • The Cook-Levin theorem
  • What next?

3
SAT
  • Instance A Boolean formula.
  • Problem To decide if the formula is satisfiable.

A satisfiable Boolean formula
F
T
F
T
T
T
An unsatisfiable Boolean formula
4
To Which Time Complexity Class Does SAT Clearly
Belong?
SAT
Co-NP
NP
P
5
SAT is in NP Non-Deterministic Algorithm
  • Guess an assignment to the variables.
  • Check the assignment.

F
T
F
T
T
T
x1
F
?
x2
T
x3
T
6
The Cook-Levin Theorem SAT is NP-Complete
  • Proof Idea For any NP machine M and any input
    string w, we construct a Boolean formula ?M,w
    which is satisfiable iff M accepts w.

7
Representing a Computation by a Configurations
Table
upper bound on the running time
the content of the (relevant part of the) tape
and the position of the head
indicates tape bounds
8
Tableau Example
  • TM
  • Qq0,qaccept,qreject
  • ?1
  • ?1,_
  • ?(q0,1)(q0,_,R)
  • ?(q0,_)(qaccept,L)

Q what does thismachine compute?
9
The Variables of the Formula
stands for Is s the content of cell (i,j)?
  • xi, j, s

symbol (s???Q?)
position in the tableau (1?i,j?nk)
10
The Formula ?
?M,w ?cell ? ?start ? ?move ? ?accept
cell content consistency
machine accepts
input consistency
transition legal
11
Ensuring Unique Cell Content
The (i,j) cell must contain some symbol
It shouldnt contain different symbols.
12
Ensuring Initial Configuration Corresponds to
Input
  • Observe we can explicitly state the desired
    configuration in the first step. Assuming the
    input string is w1w2...wn,

13
Ensuring the Computation Accepts
  • The accepting state is visited during the
    computation.

14
Ensuring Every Transition is Legal
Local only need to examine 2?3 windows
15
Which Windows are Legal in the Following Example?
  • TM
  • Qq0,qaccept,qreject
  • ?1
  • ?1,_
  • ?(q0,1)(q0,_,R)
  • ?(q0,_)(qaccept,L)

?
?
?
?
?
?
16
Ensuring Every Transition is Legal
17
The Bottom Line
?M,w ?cell ? ?start ? ?move ? ?accept
  • ?, which is of size polynomial in n - Check! - is
    satisfiable iff the TM accepts the input string.

18
Conclusion SAT is NP-Complete
  • For any language A in NP,

satisfiability problem
testing membership in A
19
Revisiting the Map
SAT
Co-NP
NP
NPC
P
20
Looking Forward
  • From now on, in order to show some NP problem is
    NP-Complete, we merely need to reduce SAT to it.

any NP problem
can be reduced to...
SAT
can be reduced to...
Weve already shown this
new NP problem
will imply the new problem is in NPC
21
... and Beyond!
  • Moreover, every NP-Complete problem we discover,
    provides us with a new way for showing problems
    to be NP-Complete.

any NP problem
can be reduced to...
Known NP-hard problem
can be reduced to...
new NP problem
22
Summary
  • Weve proved SAT is NP-Complete.
  • Weve also described a general method for showing
    other problems are NP-Complete too.

?
Write a Comment
User Comments (0)
About PowerShow.com