Overview of Computational Complexity Theory: Savitch's Theorem, PSPACE, and NL-Completeness

 
Computational Complexity Theory
 
 
Lecture 8:
  Savitch’s theorem;
                PSPACE and NL-completeness
 
 
 
Indian Institute of Science
 
Recap: Relation between time & space
 
Obs. 
DTIME(
S(n)
) 
 
DSPACE(
S(n)
) 
 
NSPACE(
S(n)
)
.
 
Theorem.
 
NSPACE(
S(n)
) 
 
DTIME(
2
O(S(n))
)
, if 
S
 is
space constructible.
 
NP
 
co-NP
 
P
 
EXP
 
PSPACE
 
NL
 
L
 
Recap: Configuration graph
 
Definition.  
A 
configuration
 of a TM 
M
 on input 
x
, at any
particular step of its execution, consists of
           (a)  the nonblank symbols of its work tapes,
           (b)  the current state,
           (c)  the current head positions.
It captures a ‘snapshot’ of 
M
 at any particular moment
of execution.
 
Input head
index
 
Work tape
head index
 
b
S(n)
 
State info
 
b
1
 
 
Note:
   A configuration 
C 
can be represented using 
O(S(n))
bits if 
M 
uses 
S(n) ≥ log n 
space on
 n
-bit inputs.
 
Recap: Configuration graph
 
Definition.  
A 
configuration
 
graph
 of a TM 
M
 on input 
x
,
denoted 
G
M,x
, is a directed graph whose nodes are all
the possible configurations of 
M
 on input 
x
. There’s an
edge from one configuration 
C
1
 to another 
C
2
, if 
C
2
can be reached from 
C
1
 by an application of 
M
’s
transition function(s).
 
Number of nodes in 
G
M,x
 = 
2
O(S(n))
, if 
M 
uses 
S(n)
space on
 n
-bit inputs
 
Recap: Configuration graph
 
Definition.  
A 
configuration
 
graph
 of a TM 
M
 on input 
x
,
denoted 
G
M,x
, is a directed graph whose nodes are all
the possible configurations of 
M
 on input 
x
. There’s an
edge from one configuration 
C
1
 to another 
C
2
, if 
C
2
can be reached from 
C
1
 by an application of 
M
’s
transition function(s).
 
 
C
1
 
C
2
 
C
2
 
C
1
 
C
3
 
δ
1
 
δ
1
 
δ
0
 
Conf. graph of a DTM
 
Conf. graph of an NTM
 
 
 
 
Recap: Configuration graph
 
Definition.  
A 
configuration
 
graph
 of a TM 
M
 on input 
x
,
denoted 
G
M,x
, is a directed graph whose nodes are all
the possible configurations of 
M
 on input 
x
. There’s an
edge from one configuration 
C
1
 to another 
C
2
, if 
C
2
can be reached from 
C
1
 by an application of 
M
’s
transition function(s).
 
M
 accepts 
x
 if and only if there’s a path from 
C
start
 to
C
accept
 in 
G
M,x
.
 
Recap: Relation between time & space
 
Obs. 
DTIME(
S(n)
) 
 
DSPACE(
S(n)
) 
 
NSPACE(
S(n)
)
.
 
Theorem.
 
NSPACE(
S(n)
) 
 
DTIME(
2
O(S(n))
)
, if 
S
 is
space constructible.
 
Proof.
 Let 
L
 
 
NSPACE(
S(n)
)
 and 
M
 be an NTM
deciding 
L
 using 
S(n)
 space on length 
n
 inputs.
On input 
x
, compute the configuration graph 
G
M,x 
of
M
 and check if there’s a 
path
 from 
C
start
 to 
C
accept
 .
Running time is 
2
O(S(n))
.
 
Recap: PATH is in NL
 
PATH = 
{
(G,s,t) : G 
is a directed graph having a path
from
 s 
to 
t
}.
Obs.
  
PATH
 is in 
NL
.
 
NP
 
co-NP
 
P
 
EXP
 
PSPACE
 
NL
 
L
 
PATH
 
Recap: UPATH is in L
 
UPATH = 
{
(G,s,t) : G 
is an undirected graph having a
path from
 s 
to 
t
}.
Theorem 
(Reingold)
.
  
U
PATH
 is in 
L
.
 
NP
 
co-NP
 
P
 
EXP
 
PSPACE
 
NL
 
L
 
UPATH
 
Is 
PATH
 in 
L
 ?
…more on this later.
 
PSPACE = NPSPACE
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
 Let 
L 
 
NSPACE(
S(n)
)
, and 
M
 be an NTM
requiring 
O(S(n))
 space to decide 
L
. We’ll show that
there’s a TM 
N
 requiring 
O(S(n)
2
)
 space to decide 
L
.
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
 Let 
L 
 
NSPACE(
S(n)
)
, and 
M
 be an NTM
requiring 
O(S(n))
 space to decide 
L
. We’ll show that
there’s a TM 
N
 requiring 
O(S(n)
2
)
 space to decide 
L
.
 
On input 
x
, 
N
 checks if there’s a path from 
C
start
 to
C
accept
 in 
G
M,x
 as follows:  Let 
|x| = n
.
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
N
 computes 
m = O(S(n))
,
 
the no. of bits
required to represent a configuration of 
M
. It also
finds out 
C
start
 and 
C
accept
. Then 
N
 checks if there’s a
path from 
C
start
 to 
C
accept
 of length at most 
2
m
 in 
G
M,x
recursively using the following procedure.
 
REACH(
C
1
, C
2
, i
)
 : returns 
1
 if there’s a path from 
C
1
to 
C
2
 of length at most 
2
i
 in 
G
M,x
;   
0
 otherwise.
 
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
N
 computes 
m = O(S(n))
,
 
the no. of bits
required to represent a configuration of 
M
. It also
finds out 
C
start
 and 
C
accept
. Then 
N
 checks if there’s a
path from 
C
start
 to 
C
accept
 of length at most 
2
m
 in 
G
M,x
recursively using the following procedure.
 
REACH(
C
1
, C
2
, i
)
 : returns 
1
 if there’s a path from 
C
1
to 
C
2
 of length at most 
2
i
 in 
G
M,x
;   
0
 otherwise.
 
 
Space constructibility of 
S(n)
 used here
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
REACH(
C
1
, C
2
, i
)
 {
        
If 
i = 0
 check if 
C
1
 and 
C
2
 are adjacent.
        Else,   
for every
 configurations 
C
,
                       
a
1
 =
 
REACH(
C
1
, C, i-1
)
                       
a
2
 =
 
REACH(
C, C
2
, i-1
)
                       if 
a
1
=1
 & 
a
2
=1
, return 
1
. Else return 
0
.
   }
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
REACH(
C
1
, C
2
, i
)
 {
        
If 
i = 0
 check if 
C
1
 and 
C
2
 are adjacent.
        Else,   
for every
 configurations 
C
,
                       
a
1
 =
 
REACH(
C
1
, C, i-1
)
                       
a
2
 =
 
REACH(
C, C
2
, i-1
)
                       if 
a
1
=1
 & 
a
2
=1
, return 
1
. Else return 
0
.
   }
 
Require 
O(S(n))
 space
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
REACH(
C
1
, C
2
, i
)
 {
        
If 
i = 0
 check if 
C
1
 and 
C
2
 are adjacent.
        Else,   
for every
 configurations 
C
,
                       
a
1
 =
 
REACH(
C
1
, C, i-1
)
                       
a
2
 =
 
REACH(
C, C
2
, i-1
)
                       if 
a
1
=1
 & 
a
2
=1
, return 
1
. Else return 
0
.
   }
 
Reuse space
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
                   
Space(i) = Space(i-1) + O(S(n))
Space complexity:  
O(S(n)
2
)
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
                   
Space(i) = Space(i-1) + O(S(n))
Space complexity:  
O(S(n)
2
)
 
                   Time(i) = 2
m
.2.Time(i-1) + O(S(n))
Time complexity:  
2
O(S(n)  )
 
 
2
 
Savitch’s theorem
 
Theorem.
  
NSPACE(
S(n)
) 
 DSPACE(
S(n)
2
)
, where
S(n)
 is space constructible.   
(So, 
PSPACE = NPSPACE
)
 
Proof.
                   
Space(i) = Space(i-1) + O(S(n))
Space complexity:  
O(S(n)
2
)
 
                   Time(i) = 2
m
.2.Time(i-1) + O(S(n))
Time complexity:  
2
O(S(n)  )
 
 
2
 
Recall, 
NSPACE(
S(n)
) 
 
DTIME(
2
O(S(n))
).
There’s an algorithm with time complexity
2
O(S(n))
, but higher space requirement.
 
PSPACE-completeness
 
PSPACE-completeness
 
Recall, to define completeness of a complexity class,
we need an appropriate notion of a 
reduction
.
What kind of reductions will be suitable is guided by 
a
complexity question
, like a comparison between the
complexity class under consideration & another class.
Is 
P = PSPACE
 ?
 
PSPACE-completeness
 
Recall, to define completeness of a complexity class,
we need an appropriate notion of a 
reduction
.
What kind of reductions will be suitable is guided by 
a
complexity question
, like a comparison between the
complexity class under consideration & another class.
Is 
P = PSPACE
 ? …use poly-time Karp reduction!
 
Definition.  
A language
 
L’
 
is
 
PSPACE-hard
 
if for every 
L
in
 
PSPACE
, 
 
L  ≤
p
  L’
.
  
Further, 
if
 L’ 
is in 
PSPACE
 
then 
L’
is
 
PSPACE-complete
.
 
A PSPACE-complete problem
 
Recall, to define completeness of a complexity class,
we need an appropriate notion of a 
reduction
.
What kind of reductions will be suitable is guided by 
a
complexity question
, like a comparison between the
complexity class under consideration & another class.
Is 
P = PSPACE
 ? …use poly-time Karp reduction!
 
Example. 
L’ = 
{
(M,w,1
m
) 
: 
M 
accepts 
w 
using 
m
 space}
 
Natural PSPACE-complete problem
 
Definition. 
A 
quantified Boolean formula (QBF)
 is a
formula of the form
       
Q
1
x
1
 Q
2
x
2
 … Q
n
x
n
  
ϕ(x
1
, x
2
, …, x
n
)
 
 
 
A QBF is either 
true
 or 
false
 as all variables are
quantified. This is unlike a formula we’ve seen before
where variables were 
unquantified/free
.
 
Quantifiers 
 or 
 
Just a formula on
Boolean variables
 
Natural PSPACE-complete problem
 
Example.   
x
1
 
x
2
x
n
  
ϕ(x
1
, x
2
, …, x
n
)
 
The above QBF is true iff 
ϕ 
is satisfiable.
 
We could have defined 
SAT
 as
        
SAT
 = {
x
 
ϕ(
x
) 
:
 ϕ 
is a CNF and 
x
 
ϕ(
x
) 
is true}
  instead of
       
SAT
 = {
ϕ(
x
) 
:
 ϕ 
is a CNF and 
ϕ 
is satisfiable}
 
Natural PSPACE-complete problem
 
Definition. 
A 
quantified Boolean formula (QBF)
 is a
formula of the form
       
Q
1
x
1
 Q
2
x
2
 … Q
n
x
n
  
ϕ(x
1
, x
2
, …, x
n
)
 
 
 
Homework:
  By using auxiliary variables (as in the
proof of Cook-Levin) and introducing some more 
quantifiers at the end, we can assume w.l.o.g. that 
ϕ 
is
a 3CNF.
 
 
 
Quantifiers 
 or 
 
Just a formula on
Boolean variables
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
  Easy to see that 
TQBF
 is in 
PSPACE
 – just
think of a suitable recursive procedure. We’ll now
show that every 
L 
 
PSPACE
 reduces to 
TQBF
 via
poly-time Karp reduction…
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
  … Let 
M
 be a TM deciding 
L
 using 
S(n) =
poly(n)
 space. We intend to come up with a poly-time
reduction 
f
 s.t.
             
x 
 L
             
ψ
x
 
is a true QBF
 
f
 
Size of 
ψ
x 
must be bounded
by 
poly(n)
, where 
|x| = n
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
  … Let 
M
 be a TM deciding 
L
 using 
S(n) =
poly(n)
 space. We intend to come up with a poly-time
reduction 
f
 s.t.
             
x 
 L
             
ψ
x
 
is a true QBF
 
Idea:
 Form 
ψ
x
 
in such a way that 
ψ
x
 
is true iff there’s a path from
C
start
 to 
C
accept
 in 
G
M,x
.
 
f
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
f
 computes 
S(n)
 from 
n
 (recall, any poly
function 
S(n)
 is time constructible). It also computes
m = O(S(n))
, the no. of bits required to represent a
configuration in 
G
M,x
.
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
f
 computes 
S(n)
 from 
n
 (recall, any poly
function 
S(n)
 is time constructible). It also computes
m = O(S(n))
, the no. of bits required to represent a
configuration in 
G
M,x
. Then, it forms a 
semi-QBF
Δ
i
(C
1
,C
2
)
, such that 
Δ
i
(C
1
,C
2
)
 is true iff there’s a path
from 
C
1
 to 
C
2
 of length at most 
2
i
 in 
G
M,x
.
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
f
 computes 
S(n)
 from 
n
 (recall, any poly
function 
S(n)
 is time constructible). It also computes
m = O(S(n))
, the no. of bits required to represent a
configuration in 
G
M,x
. Then, it forms a 
semi-QBF
Δ
i
(C
1
,C
2
)
, such that 
Δ
i
(C
1
,C
2
)
 is true iff there’s a path
from 
C
1
 to 
C
2
 of length at most 
2
i
 in 
G
M,x
.
 
The variables corresponding to the bits of 
C
1
and 
C
2
 are unquantified/free variables of 
Δ
i
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:
 …QBF 
Δ
i
(C
1
,C
2
)
 is formed, recursively, as
follows:
                             (first attempt)
        
Δ
i
(C
1
,C
2
) = 
C  
(
Δ
i-1
(C
1
,C) 
 Δ
i-1
(C,C
2
)
)
 
Issue:
  Size of 
Δ
i
 
is 
twice
 the size of 
Δ
i-1
 
!!
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof: 
…QBF 
Δ
i
(C
1
,C
2
)
 is formed, recursively, as
follows:
                         (careful attempt)
  
Δ
i
(C
1
,C
2
) = 
C 
D
1
D
2
   ( 
(
(
D
1
 = C
1
 
 D
2
 = C
)
 
 
(
D
1
 = C 
 D
2
 = C
2
)
)       
Δ
i-1
(D
1
,D
2
)  
)
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof: 
…QBF 
Δ
i
(C
1
,C
2
)
 is formed, recursively, as
follows:
                         (careful attempt)
  
Δ
i
(C
1
,C
2
) = 
C 
D
1
D
2
   (
¬
(
(
D
1
 = C
1
 
 D
2
 = C
)
 
 
(
D
1
 = C 
 D
2
 = C
2
)
)  
 
  
Δ
i-1
(D
1
,D
2
)  
)
 
Note: 
  Size of 
Δ
i
  =  O(S(n)) + 
Size of 
Δ
i-1
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:  
Finally,
                       ψ
x
  =  
Δ
m
(C
start
,C
accept
)
 
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:  
Finally,
                       ψ
x
  =  
Δ
m
(C
start
,C
accept
)
 
But, we need to specify how to form 
Δ
0
(C
1
,C
2
)
.
Size of 
ψ
x
  = O(S(n)
2
) + 
Size of
 
Δ
0
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:  
Finally,
                       ψ
x
  =  
Δ
m
(C
start
,C
accept
)
 
But, we need to specify how to form 
Δ
0
(C
1
,C
2
)
.
Size of 
ψ
x
  = O(S(n)
2
) + 
Size of
 
Δ
0
 
Remark:
  We can easily bring all the quantifiers at the
beginning in 
ψ
x 
(as in 
prenex normal form
).
 
Natural PSPACE-complete problem
 
Definition.   
TQBF 
is the set of 
true
 quantified
Boolean formulas.
 
Theorem.
  
TQBF
 is PSPACE-complete.
Proof:  
Finally,
                       ψ
x
  =  
Δ
m
(C
start
,C
accept
)
 
But, we need to specify how to form 
Δ
0
(C
1
,C
2
)
.
Size of 
ψ
x
  = O(S(n)
2
) + 
Size of
 
Δ
0
 
??
 
Adjacent configurations
 
Claim. 
There’s an
 
O(S(n)
2
)
-size circuit 
ϕ
M,x
 
on 
O(S(n))
inputs such that for every inputs 
C
1
 and 
C
2
,
ϕ
M,x
(C
1
, C
2
) = 1 
iff 
C
1
 and 
C
2
 encode two neighboring
configurations in 
G
M,x
 
.
 
Proof
. Think of a 
linear time
 algorithm that has the
knowledge of 
M
 and 
x
, and on input 
C
1
 and 
C
2
 it
checks if 
C
2
 is a neighbor of 
C
1
 in 
G
M,x
.
 
Adjacent configurations
 
Claim. 
There’s an
 
O(S(n)
2
)
-size circuit 
ϕ
M,x
 
on 
O(S(n))
inputs such that for every inputs 
C
1
 and 
C
2
,
ϕ
M,x
(C
1
, C
2
) = 1 
iff 
C
1
 and 
C
2
 encode two neighboring
configurations in 
G
M,x
 
.
 
Proof
. Think of a 
linear time
 algorithm that has the
knowledge of 
M
 and 
x
, and on input 
C
1
 and 
C
2
 it
checks if 
C
2
 is a neighbor of 
C
1
 in 
G
M,x
. Applying ideas
from the proof of Cook-Levin theorem, we get our
desired 
ϕ
M,x
 
of size
 
O(S(n)
2
)
.
 
Size of Δ
0
 
Obs. 
We can convert the circuit 
ϕ
M,x
(C
1
, C
2
) 
to a
quantified CNF 
Δ
0
(C
1
,C
2
) 
by introducing auxiliary
variables (as in the proof of Cook-Levin theorem).
 
Hence, size of
 
Δ
0
(C
1
,C
2
)
 
is 
O(S(n)
2
)
.
Therefore, size of 
ψ
x
  = O(S(n)
2
)
.
 
Other PSPACE complete problems
 
 
 
 
Checking if a player has a winning strategy in certain
two-player games, like (generalized) Hex, Reversi,
Geography etc.
 
NL-completeness
 
NL-completeness
 
Recall again, to define completeness of a complexity
class, we need an appropriate notion of a 
reduction
.
What kind of reductions will be suitable is guided by 
a
complexity question
, like a comparison between the
complexity class under consideration & another class.
Is 
L = NL 
?
 
NL-completeness
 
Recall again, to define completeness of a complexity
class, we need an appropriate notion of a 
reduction
.
What kind of reductions will be suitable is guided by 
a
complexity question
, like a comparison between the
complexity class under consideration & another class.
Is 
L = NL 
? …poly-time (Karp) reductions are much
too powerful for 
L
.
We need to define a suitable 
‘log-space’
 reduction.
 
Log-space reductions
 
                     
x
                  
f(x)
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
 
Log-space TM
 
…unless we restrict 
|f(x)|
 
=  O(log |x|)
, in which case
we’re severely restricting the power of the reduction.
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
 
Log-space TM
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Definition:  
A function 
f : {0,1}*    {0,1}*
 is 
implicitly log-
space computable
 if
          1. 
|f(x)| ≤ |x|
c
 for some constant 
c
,
          2. The following two languages are in 
L
 :
 
Log-space TM
 
L
f
 = {(x, i) : f(x)
i
 = 1}
   and  
L’
f
 = {(x, i) : i ≤ |f(x)|}
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Definition:  
A language 
L
1
 is 
log-space reducible
 to a
language 
L
2
, denoted 
L
1
l
 L
2
, if there’s an implicitly
log-space computable function 
f
 such that
                     
x 
 L
1
              f(x) 
 L
2
 
Log-space TM
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
  Let 
f
 be the reduction from 
L
1
 to 
L
2
, and 
g
 the
reduction from 
L
2
 to 
L
3
. We’ll show that the function
h(x) = g(f(x))
 is implicitly log-space computable which
will suffice as,
 
Log-space TM
 
x 
 L
1
           f(x) 
 L
2
          g(f(x)) 
 L
3
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
 …Think of the following log-space TM that
computes 
h(x)
i
 
from 
(x, i)
. Let
 
Log-space TM
 
 
M
f
 
be the 
log-space TM that computes 
f(x)
j
 
from 
(x, j)
,
 
 
M
g
 
be the log-space TM that computes 
g(y)
i
 
from 
(y, i).
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
 …On input 
x
, simulate 
M
g
 on 
(f(x), i)
 pretending
that 
f(x)
 is there in some fictitious tape. During the
simulation whenever 
M
g
 tries to read a 
j
-th bit of 
f(x)
,
postpone
 
M
g
’s computation and start simulating 
M
f
 on
input 
(x, j)
.
 
Log-space TM
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
 …On input 
x
, simulate 
M
g
 on 
(f(x), i)
 pretending
that 
f(x)
 is there in some fictitious tape. During the
simulation whenever 
M
g
 tries to read a 
j
-th bit of 
f(x)
,
postpone
 
M
g
’s computation and start simulating 
M
f
 on
input 
(x, j)
.  Space usage 
= O(log |f(x)|) + O(log |x|)
.
 
Log-space TM
 
stores 
M
g
’s current configuration
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
 …On input 
x
, simulate 
M
g
 on 
(f(x), i)
 pretending
that 
f(x)
 is there in some fictitious tape. During the
simulation whenever 
M
g
 tries to read a 
j
-th bit of 
f(x)
,
postpone
 
M
g
’s computation and start simulating 
M
f
 on
input 
(x, j)
.  Space usage 
= O(log |x|)
.
 
Log-space TM
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
 …On input 
x
, simulate 
M
g
 on 
(f(x), i)
 pretending
that 
f(x)
 is there in some fictitious tape. During the
simulation whenever 
M
g
 tries to read a 
j
-th bit of 
f(x)
,
postpone
 
M
g
’s computation and start simulating 
M
f
 on
input 
(x, j)
.  This shows 
L
h
 is in 
L
.
 
Log-space TM
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
l
 L
3 
then 
L
1
l
 L
3
.
Proof:
 …Similarly, 
L’
h
 is in 
L
 and so 
h
 is implicitly log-
space computable.
 
Log-space TM
 
Log-space reductions
 
                  
(x, i)
                
f(x)
i
Issue:
  A log-space TM may not have enough space to
write down the whole output 
f(x)
 in one shot.
Solution:
 Have the log-space TM output any bit of 
f(x)
.
Claim:  
If 
L
1
l
 L
2
 and 
L
2
 
 
L
 
then 
L
1
 
 
L
.
Proof:
  Same ideas. 
(
Homework
)
 
Log-space TM
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
Theorem:  
PATH
 is NL-complete.
Proof:
  We’ve already shown that 
PATH 
 
NL
. Now
we’ll show that for every 
L 
 
NL
,  
L ≤
l 
PATH
.  We
need to come up with an implicitly log-space
computable function 
f
 s.t.
                   
x 
 L              f(x) 
 PATH
 
PATH = 
{
(G,s,t) : G 
is a digraph having a path from
 s 
to 
t
}.
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
Theorem:  
PATH
 is NL-complete.
Proof:
  … Let 
M
 be a log-space NTM deciding 
L
.
Define, 
f(x) := (G
M,x
, C
start
, C
accept
)
, where 
G
M,x
 is given
as an adjacency matrix.
 
PATH = 
{
(G,s,t) : G 
is a digraph having a path from
 s 
to 
t
}.
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
Theorem:  
PATH
 is NL-complete.
Proof:
  … Let 
M
 be a log-space NTM deciding 
L
.
Define, 
f(x) = (G
M,x
, C
start
, C
accept
)
, where 
G
M,x
 is given
as an adjacency matrix. Let 
m = O(log |x|)
 be the no.
of bits required to represent a configuration. Then,
|f(x)| = 2
2m
 + 2m = poly(|x|)
.
 
PATH = 
{
(G,s,t) : G 
is a digraph having a path from
 s 
to 
t
}.
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
Theorem:  
PATH
 is NL-complete.
Proof:
  …Let’s see how to compute 
f(x)
i
 from 
(x, i)
using log-space:
 
PATH = 
{
(G,s,t) : G 
is a digraph having a path from
 s 
to 
t
}.
 
f(x)
 
G
M,x
 
C
start
 
C
accept
 
2
2m
 bits
 
If 
i > 2
2m
 then 
i
 indexes a bit in the 
(C
start
, C
accept
)
 part of 
f(x)
; so
f(x)
i
 can be computed by simply writing down 
C
start
 and 
C
accept
.
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
Theorem:  
PATH
 is NL-complete.
Proof:
  …Let’s see how to compute 
f(x)
i
 from 
(x, i)
using log-space:
 
PATH = 
{
(G,s,t) : G 
is a digraph having a path from
 s 
to 
t
}.
 
f(x)
 
G
M,x
 
C
start
 
C
accept
 
2
2m
 bits
 
If 
i ≤ 2
2m
 then write 
i
 as 
(C
1
,C
2
)
, where 
C
1
 and 
C
2
 
are 
m
 bits each,
and check if 
C
2
 is a neighbor of 
C
1
 in 
G
M,x
. This takes 
O(m)
 space.
 
NL-completeness
 
Definition:
  A language 
L
 is NL-complete if 
L 
 
NL
 and
for every 
L’ 
 
NL
, 
L’
 is log-space reducible to 
L
.
 
Theorem:  
PATH
 is NL-complete.
Proof:
  …Thus, we’ve argued that 
|f(x)|
 has 
poly(|x|)
length and 
L
f
 
 
L
. Similarly, 
L’
f
 
 
L
. So, 
f
 defines a log-
space reduction from 
L
 to 
PATH
.
 
PATH = 
{
(G,s,t) : G 
is a digraph having a path from
 s 
to 
t
}.
 
Another NL-complete problem
 
 
 
 
2SAT
 
is NL-complete.  
(Exercise)
Slide Note
Embed
Share

This lecture delves into Savitch's theorem, the complexity classes PSPACE and NL, and their completeness. It explores the relationship between time and space complexity, configuration graphs of Turing machines, and how non-deterministic space relates to deterministic time. The concept of configuration graphs is explained, showcasing how they determine the acceptance of inputs, and a proof of NSPACE(S(n)) ⊆ DTIME(2^(O(S(n)))) is provided.

  • Computational complexity
  • Savitchs theorem
  • PSPACE
  • NL-completeness
  • Turing machines

Uploaded on Sep 12, 2024 | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. Download presentation by click this link. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

E N D

Presentation Transcript


  1. Computational Complexity Theory Lecture 8: Savitch s theorem; PSPACE and NL-completeness Indian Institute of Science

  2. Recap: Relation between time & space Obs. DTIME(S(n)) DSPACE(S(n)) NSPACE(S(n)). Theorem. NSPACE(S(n)) DTIME(2O(S(n))), if S is space constructible. EXP PSPACE NP co-NP P NL L

  3. Recap: Configuration graph Definition. A configuration of a TM M on input x, at any particular step of its execution, consists of (a) the nonblank symbols of its work tapes, (b) the current state, (c) the current head positions. It captures a snapshot of M at any particular moment of execution. Input head index Work tape head index b1 bS(n) State info Note: A configuration C can be represented using O(S(n)) bits if M uses S(n) log n space on n-bit inputs.

  4. Recap: Configuration graph Definition. A configurationgraph of a TM M on input x, denoted GM,x, is a directed graph whose nodes are all the possible configurations of M on input x. There s an edge from one configuration C1 to another C2, if C2 can be reached from C1 by an application of M s transition function(s). Number of nodes in GM,x = 2O(S(n)), if M uses S(n) space on n-bit inputs

  5. Recap: Configuration graph Definition. A configurationgraph of a TM M on input x, denoted GM,x, is a directed graph whose nodes are all the possible configurations of M on input x. There s an edge from one configuration C1 to another C2, if C2 can be reached from C1 by an application of M s transition function(s). C2 C2 1 1 C1 C1 0 C3 Conf. graph of a DTM Conf. graph of an NTM

  6. Recap: Configuration graph Definition. A configurationgraph of a TM M on input x, denoted GM,x, is a directed graph whose nodes are all the possible configurations of M on input x. There s an edge from one configuration C1 to another C2, if C2 can be reached from C1 by an application of M s transition function(s). M accepts x if and only if there s a path from Cstart to Caccept in GM,x.

  7. Recap: Relation between time & space Obs. DTIME(S(n)) DSPACE(S(n)) NSPACE(S(n)). Theorem. NSPACE(S(n)) DTIME(2O(S(n))), if S is space constructible. Proof. Let L NSPACE(S(n)) and M be an NTM deciding L using S(n) space on length n inputs. On input x, compute the configuration graph GM,x of M and check if there s a path from Cstart to Caccept . Running time is 2O(S(n)).

  8. Recap: PATH is in NL PATH = {(G,s,t) : G is a directed graph having a path from s to t}. Obs. PATH is in NL. EXP PSPACE NP co-NP P NL PATH L

  9. Recap: UPATH is in L UPATH = {(G,s,t) : G is an undirected graph having a path from s to t}. Theorem (Reingold). UPATH is in L. EXP PSPACE Is PATH in L ? more on this later. NP co-NP P NL UPATH L

  10. PSPACE = NPSPACE

  11. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. Let L NSPACE(S(n)), and M be an NTM requiring O(S(n)) space to decide L. We ll show that there s a TM N requiring O(S(n)2) space to decide L.

  12. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. Let L NSPACE(S(n)), and M be an NTM requiring O(S(n)) space to decide L. We ll show that there s a TM N requiring O(S(n)2) space to decide L. On input x, N checks if there s a path from Cstart to Caccept in GM,x as follows: Let |x| = n.

  13. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. N computes m = O(S(n)), the no. of bits required to represent a configuration of M. It also finds out Cstart and Caccept. Then N checks if there s a path from Cstart to Caccept of length at most 2m in GM,x recursively using the following procedure. REACH(C1, C2, i) : returns 1 if there s a path from C1 to C2 of length at most 2i in GM,x; 0 otherwise.

  14. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Space constructibility of S(n) used here Proof. N computes m = O(S(n)), the no. of bits required to represent a configuration of M. It also finds out Cstart and Caccept. Then N checks if there s a path from Cstart to Caccept of length at most 2m in GM,x recursively using the following procedure. REACH(C1, C2, i) : returns 1 if there s a path from C1 to C2 of length at most 2i in GM,x; 0 otherwise.

  15. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. REACH(C1, C2, i) { If i = 0 check if C1 and C2 are adjacent. Else, for every configurations C, a1 = REACH(C1, C, i-1) a2 = REACH(C, C2, i-1) if a1=1 & a2=1, return 1. Else return 0. }

  16. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. REACH(C1, C2, i) { If i = 0 check if C1 and C2 are adjacent. Else, for every configurations C, a1 = REACH(C1, C, i-1) a2 = REACH(C, C2, i-1) if a1=1 & a2=1, return 1. Else return 0. } Require O(S(n)) space

  17. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. REACH(C1, C2, i) { If i = 0 check if C1 and C2 are adjacent. Else, for every configurations C, a1 = REACH(C1, C, i-1) a2 = REACH(C, C2, i-1) if a1=1 & a2=1, return 1. Else return 0. } Reuse space

  18. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. Space(i) = Space(i-1) + O(S(n)) Space complexity: O(S(n)2)

  19. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. Space(i) = Space(i-1) + O(S(n)) Space complexity: O(S(n)2) Time(i) = 2m.2.Time(i-1) + O(S(n)) Time complexity: 2O(S(n) ) 2

  20. Savitchs theorem Theorem. NSPACE(S(n)) DSPACE(S(n)2), where S(n) is space constructible. (So, PSPACE = NPSPACE) Proof. Space(i) = Space(i-1) + O(S(n)) Space complexity: O(S(n)2) Time(i) = 2m.2.Time(i-1) + O(S(n)) Time complexity: 2O(S(n) ) 2 Recall, There s an algorithm with time complexity 2O(S(n)), but higher space requirement. NSPACE(S(n)) DTIME(2O(S(n))).

  21. PSPACE-completeness

  22. PSPACE-completeness Recall, to define completeness of a complexity class, we need an appropriate notion of a reduction. What kind of reductions will be suitable is guided by a complexity question, like a comparison between the complexity class under consideration & another class. Is P = PSPACE ?

  23. PSPACE-completeness Recall, to define completeness of a complexity class, we need an appropriate notion of a reduction. What kind of reductions will be suitable is guided by a complexity question, like a comparison between the complexity class under consideration & another class. Is P = PSPACE ? use poly-time Karp reduction! Definition. A language L is PSPACE-hard if for every L in PSPACE, L pL . Further, if L is in PSPACE then L is PSPACE-complete.

  24. A PSPACE-complete problem Recall, to define completeness of a complexity class, we need an appropriate notion of a reduction. What kind of reductions will be suitable is guided by a complexity question, like a comparison between the complexity class under consideration & another class. Is P = PSPACE ? use poly-time Karp reduction! Example. L = {(M,w,1m) : M accepts w using m space}

  25. Natural PSPACE-complete problem Definition. A quantified Boolean formula (QBF) is a formula of the form Q1x1 Q2x2 Qnxn (x1, x2, , xn) Just a formula on Boolean variables Quantifiers or A QBF is either true or false as all variables are quantified. This is unlike a formula we ve seen before where variables were unquantified/free.

  26. Natural PSPACE-complete problem Example. x1 x2 xn (x1, x2, , xn) The above QBF is true iff is satisfiable. We could have defined SAT as SAT = { x (x) : is a CNF and x (x) is true} instead of SAT = { (x) : is a CNF and is satisfiable}

  27. Natural PSPACE-complete problem Definition. A quantified Boolean formula (QBF) is a formula of the form Q1x1 Q2x2 Qnxn (x1, x2, , xn) Just a formula on Boolean variables Quantifiers or Homework: By using auxiliary variables (as in the proof of Cook-Levin) and introducing some more quantifiers at the end, we can assume w.l.o.g. that is a 3CNF.

  28. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Easy to see that TQBF is in PSPACE just think of a suitable recursive procedure. We ll now show that every L PSPACE reduces to TQBF via poly-time Karp reduction

  29. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Let M be a TM deciding L using S(n) = poly(n) space. We intend to come up with a poly-time reduction f s.t. x L x is a true QBF f Size of x must be bounded by poly(n), where |x| = n

  30. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Let M be a TM deciding L using S(n) = poly(n) space. We intend to come up with a poly-time reduction f s.t. x L x is a true QBF f Idea: Form x in such a way that x is true iff there s a path from Cstart to Caccept in GM,x.

  31. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: f computes S(n) from n (recall, any poly function S(n) is time constructible). It also computes m = O(S(n)), the no. of bits required to represent a configuration in GM,x.

  32. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: f computes S(n) from n (recall, any poly function S(n) is time constructible). It also computes m = O(S(n)), the no. of bits required to represent a configuration in GM,x. Then, it forms a semi-QBF i(C1,C2), such that i(C1,C2) is true iff there s a path from C1 to C2 of length at most 2i in GM,x.

  33. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: f computes S(n) from n (recall, any poly function S(n) is time constructible). It also computes m = O(S(n)), the no. of bits required to represent a configuration in GM,x. Then, it forms a semi-QBF i(C1,C2), such that i(C1,C2) is true iff there s a path from C1 to C2 of length at most 2i in GM,x. The variables corresponding to the bits of C1 and C2 are unquantified/free variables of i

  34. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: QBF i(C1,C2) is formed, recursively, as follows: (first attempt) i(C1,C2) = C ( i-1(C1,C) i-1(C,C2)) Issue: Size of i is twice the size of i-1 !!

  35. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: QBF i(C1,C2) is formed, recursively, as follows: (careful attempt) i(C1,C2) = C D1 D2 ( ((D1 = C1 D2 = C) (D1 = C D2 = C2)) i-1(D1,D2) )

  36. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: QBF i(C1,C2) is formed, recursively, as follows: (careful attempt) i(C1,C2) = C D1 D2 ( ((D1 = C1 D2 = C) (D1 = C D2 = C2)) i-1(D1,D2) ) Note: Size of i = O(S(n)) + Size of i-1

  37. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Finally, x = m(Cstart,Caccept)

  38. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Finally, x = m(Cstart,Caccept) But, we need to specify how to form 0(C1,C2). Size of x = O(S(n)2) + Size of 0

  39. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Finally, x = m(Cstart,Caccept) But, we need to specify how to form 0(C1,C2). Size of x = O(S(n)2) + Size of 0 Remark: We can easily bring all the quantifiers at the beginning in x (as in prenex normal form).

  40. Natural PSPACE-complete problem Definition. TQBF is the set of true quantified Boolean formulas. Theorem. TQBF is PSPACE-complete. Proof: Finally, x = m(Cstart,Caccept) But, we need to specify how to form 0(C1,C2). Size of x = O(S(n)2) + Size of 0 ??

  41. Adjacent configurations Claim. There s an O(S(n)2)-size circuit M,x on O(S(n)) inputs such that for every inputs C1 and C2, M,x(C1, C2) = 1 iff C1 and C2 encode two neighboring configurations in GM,x . Proof. Think of a linear time algorithm that has the knowledge of M and x, and on input C1 and C2 it checks if C2 is a neighbor of C1 in GM,x.

  42. Adjacent configurations Claim. There s an O(S(n)2)-size circuit M,x on O(S(n)) inputs such that for every inputs C1 and C2, M,x(C1, C2) = 1 iff C1 and C2 encode two neighboring configurations in GM,x . Proof. Think of a linear time algorithm that has the knowledge of M and x, and on input C1 and C2 it checks if C2 is a neighbor of C1 in GM,x. Applying ideas from the proof of Cook-Levin theorem, we get our desired M,x of size O(S(n)2).

  43. Size of 0 Obs. We can convert the circuit M,x(C1, C2) to a quantified CNF 0(C1,C2) by introducing auxiliary variables (as in the proof of Cook-Levin theorem). Hence, size of 0(C1,C2) is O(S(n)2). Therefore, size of x = O(S(n)2).

  44. Other PSPACE complete problems Checking if a player has a winning strategy in certain two-player games, like (generalized) Hex, Reversi, Geography etc.

  45. NL-completeness

  46. NL-completeness Recall again, to define completeness of a complexity class, we need an appropriate notion of a reduction. What kind of reductions will be suitable is guided by a complexity question, like a comparison between the complexity class under consideration & another class. Is L = NL ?

  47. NL-completeness Recall again, to define completeness of a complexity class, we need an appropriate notion of a reduction. What kind of reductions will be suitable is guided by a complexity question, like a comparison between the complexity class under consideration & another class. Is L = NL ? poly-time (Karp) reductions are much too powerful for L. We need to define a suitable log-space reduction.

  48. Log-space reductions Log-space TM x f(x) Issue: A log-space TM may not have enough space to write down the whole output f(x) in one shot. unless we restrict |f(x)| = O(log |x|), in which case we re severely restricting the power of the reduction.

  49. Log-space reductions Log-space TM (x, i) f(x)i Issue: A log-space TM may not have enough space to write down the whole output f(x) in one shot. Solution: Have the log-space TM output any bit of f(x).

  50. Log-space reductions Log-space TM (x, i) f(x)i Issue: A log-space TM may not have enough space to write down the whole output f(x) in one shot. Solution: Have the log-space TM output any bit of f(x). Definition: A function f : {0,1}* {0,1}* is implicitly log- space computable if 1. |f(x)| |x|c for some constant c, 2. The following two languages are in L : Lf = {(x, i) : f(x)i = 1} and L f = {(x, i) : i |f(x)|}

More Related Content

giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#