Computational Complexity
Lecture 8 More of the Polynomial Hierarchy Oracle-based Definition
1
Computational Complexity Lecture 8 More of the Polynomial - - PowerPoint PPT Presentation
Computational Complexity Lecture 8 More of the Polynomial Hierarchy Oracle-based Definition 1 Recall PH { x | u 1 u 2 u 3 F( x ,u 1 ,u 2 ,u 3 )} { x | u 1 u 2 u 3 F( x ,u 1 ,u 2 ,u 3 )} 3P 3P { x | u 1 u 2
1
P NP coNP
{x|F(x)} {x|∃u1 F(x,u1)}
Σ2P Π2P Σ3P Π3P
{x|∃u1∀u2∃u3 F(x,u1,u2,u3)} {x|∀u1∃u2∀u3 F(x,u1,u2,u3)} {x|∀u1 F(x,u1)} {x|∃u1∀u2 F(x,u1,u2)} {x|∀u1∃u2 F(x,u1,u2)}
2
3
Recall Oracle Machine
3
Recall Oracle Machine Writes queries on query-tape, enters and leaves query state, and expects answer from oracle on the tape
3
Recall Oracle Machine Writes queries on query-tape, enters and leaves query state, and expects answer from oracle on the tape Can run an oracle machine with any oracle
3
Recall Oracle Machine Writes queries on query-tape, enters and leaves query state, and expects answer from oracle on the tape Can run an oracle machine with any oracle Oracle fully specified by the input-output behavior
3
Recall Oracle Machine Writes queries on query-tape, enters and leaves query state, and expects answer from oracle on the tape Can run an oracle machine with any oracle Oracle fully specified by the input-output behavior Language oracle: answer is a single bit
3
Recall Oracle Machine Writes queries on query-tape, enters and leaves query state, and expects answer from oracle on the tape Can run an oracle machine with any oracle Oracle fully specified by the input-output behavior Language oracle: answer is a single bit This is what we consider
3
4
Non-deterministic oracle machine
4
Non-deterministic oracle machine Can make non-deterministic choices and make
4
Non-deterministic oracle machine Can make non-deterministic choices and make
Said to accept if any thread reaches accept state
4
Non-deterministic oracle machine Can make non-deterministic choices and make
Said to accept if any thread reaches accept state Equivalently, a deterministic oracle machine which takes a (read-once) certificate w (the list of non- deterministic choices)
4
Non-deterministic oracle machine Can make non-deterministic choices and make
Said to accept if any thread reaches accept state Equivalently, a deterministic oracle machine which takes a (read-once) certificate w (the list of non- deterministic choices) Said to accept x if ∃w such that (x,w) takes it to accepting state
4
Non-deterministic oracle machine Can make non-deterministic choices and make
Said to accept if any thread reaches accept state Equivalently, a deterministic oracle machine which takes a (read-once) certificate w (the list of non- deterministic choices) Said to accept x if ∃w such that (x,w) takes it to accepting state co- ^ all threads reach ∀w
5
6
NPA : class of languages accepted by oracle NTMs with
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form B = {x | ∃w MA(x,w) = 1}
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form B = {x | ∃w MA(x,w) = 1} where M deterministic oracle machine
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form B = {x | ∃w MA(x,w) = 1} where M deterministic oracle machine MA runs in poly(|x|) time and |w|=poly(|x|)
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form B = {x | ∃w MA(x,w) = 1} where M deterministic oracle machine MA runs in poly(|x|) time and |w|=poly(|x|) i.e., B = {x | ∃w (x,w) ∈ L}, where L in PA
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form B = {x | ∃w MA(x,w) = 1} where M deterministic oracle machine MA runs in poly(|x|) time and |w|=poly(|x|) i.e., B = {x | ∃w (x,w) ∈ L}, where L in PA co-(NPA) = (co-NP)A
6
NPA : class of languages accepted by oracle NTMs with
Certificate version: NPA has languages of the form B = {x | ∃w MA(x,w) = 1} where M deterministic oracle machine MA runs in poly(|x|) time and |w|=poly(|x|) i.e., B = {x | ∃w (x,w) ∈ L}, where L in PA co-(NPA) = (co-NP)A languages of the form {x | ∀w (x,w) ∈ L}, where L in PA
6
7
If A in P, NPA = NP
7
If A in P, NPA = NP Can “implement” the oracle as a subroutine
7
If A in P, NPA = NP Can “implement” the oracle as a subroutine If A in NP?
7
If A in P, NPA = NP Can “implement” the oracle as a subroutine If A in NP? Oracle for A is an oracle for Ac too! NPA = NPAc
7
If A in P, NPA = NP Can “implement” the oracle as a subroutine If A in NP? Oracle for A is an oracle for Ac too! NPA = NPAc NP ∪ co-NP ⊆ NPSAT
7
If A in P, NPA = NP Can “implement” the oracle as a subroutine If A in NP? Oracle for A is an oracle for Ac too! NPA = NPAc NP ∪ co-NP ⊆ NPSAT Can we better characterize NPSAT?
7
8
NPSAT = ∪A∈NP NPA
8
NPSAT = ∪A∈NP NPA Oracle for A can be implemented using oracle for SAT in polynomial time (deterministically)
8
NPSAT = ∪A∈NP NPA Oracle for A can be implemented using oracle for SAT in polynomial time (deterministically) NPSAT also called NPNP
8
NPSAT = ∪A∈NP NPA Oracle for A can be implemented using oracle for SAT in polynomial time (deterministically) NPSAT also called NPNP NPΣk = ∪A∈Σk NPA = NPΣkSAT
8
NPSAT = ∪A∈NP NPA Oracle for A can be implemented using oracle for SAT in polynomial time (deterministically) NPSAT also called NPNP NPΣk = ∪A∈Σk NPA = NPΣkSAT Will show NPΣk = Σk+1P (alt. definition for Σk+1P)
8
NPSAT = ∪A∈NP NPA Oracle for A can be implemented using oracle for SAT in polynomial time (deterministically) NPSAT also called NPNP NPΣk = ∪A∈Σk NPA = NPΣkSAT Will show NPΣk = Σk+1P (alt. definition for Σk+1P) In particular, NPNP = Σ2P
8
9
Consider L ∈ Σk+1P
9
Consider L ∈ Σk+1P L = { x| ∃w (x,w) ∈ L ’}, where L ’ in ΠkP
9
Consider L ∈ Σk+1P L = { x| ∃w (x,w) ∈ L ’}, where L ’ in ΠkP So L in NPL
’ where L
’ in ΠkP
9
Consider L ∈ Σk+1P L = { x| ∃w (x,w) ∈ L ’}, where L ’ in ΠkP So L in NPL
’ where L
’ in ΠkP So NPL
’ ⊆ NPΠk = NPΣk
9
Consider L ∈ Σk+1P L = { x| ∃w (x,w) ∈ L ’}, where L ’ in ΠkP So L in NPL
’ where L
’ in ΠkP So NPL
’ ⊆ NPΠk = NPΣk
So Σk+1P ⊆ NPΣk
9
Consider L ∈ Σk+1P L = { x| ∃w (x,w) ∈ L ’}, where L ’ in ΠkP So L in NPL
’ where L
’ in ΠkP So NPL
’ ⊆ NPΠk = NPΣk
So Σk+1P ⊆ NPΣk Now to show NPΣk ⊆ Σk+1P
9
10
To show NPA ⊆ Σk+1P if A in ΣkP
10
To show NPA ⊆ Σk+1P if A in ΣkP For B ∈ NPA poly-time TM M s.t. B = { x| ∃w MA(x,w)=1}
10
To show NPA ⊆ Σk+1P if A in ΣkP For B ∈ NPA poly-time TM M s.t. B = { x| ∃w MA(x,w)=1} i.e., B = { x| ∃w ∃ans M<ans>(x,w)=1 and “ans correct”}
10
To show NPA ⊆ Σk+1P if A in ΣkP For B ∈ NPA poly-time TM M s.t. B = { x| ∃w MA(x,w)=1} i.e., B = { x| ∃w ∃ans M<ans>(x,w)=1 and “ans correct”} To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P
10
To show NPA ⊆ Σk+1P if A in ΣkP For B ∈ NPA poly-time TM M s.t. B = { x| ∃w MA(x,w)=1} i.e., B = { x| ∃w ∃ans M<ans>(x,w)=1 and “ans correct”} To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Then B also in Σk+1P
10
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Suppose M makes only one query z=Z(x,w). ans is a single bit saying if z in A or not
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Suppose M makes only one query z=Z(x,w). ans is a single bit saying if z in A or not “ans correct”: (ans=1 ∧ z ∈ A) or (ans=0 ∧ z ∉ A)
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Suppose M makes only one query z=Z(x,w). ans is a single bit saying if z in A or not “ans correct”: (ans=1 ∧ z ∈ A) or (ans=0 ∧ z ∉ A) C={(x,w,ans) | M<ans>(x,w)=1 ∧ [(ans=1 ∧ ∃u1∀u2...Qkuk F(z,u1,...)=1) or (ans=0 ∧ ∀v1∃v2...Q’kvk F(z,v1,...)=0)] }
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Suppose M makes only one query z=Z(x,w). ans is a single bit saying if z in A or not “ans correct”: (ans=1 ∧ z ∈ A) or (ans=0 ∧ z ∉ A) C={(x,w,ans) | M<ans>(x,w)=1 ∧ [(ans=1 ∧ ∃u1∀u2...Qkuk F(z,u1,...)=1) or (ans=0 ∧ ∀v1∃v2...Q’kvk F(z,v1,...)=0)] } C={(x,w,ans) | ∃u1∀u2v1∃u3v2...Qkukvk-1Q’kvk M<ans>(x,w)=1 ∧ [(ans=1 ∧ F(z,u1,...)=1) or (ans=0 ∧ F(z,v1,...)=0)] }
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Suppose M makes only one query z=Z(x,w). ans is a single bit saying if z in A or not “ans correct”: (ans=1 ∧ z ∈ A) or (ans=0 ∧ z ∉ A) C={(x,w,ans) | M<ans>(x,w)=1 ∧ [(ans=1 ∧ ∃u1∀u2...Qkuk F(z,u1,...)=1) or (ans=0 ∧ ∀v1∃v2...Q’kvk F(z,v1,...)=0)] } C={(x,w,ans) | ∃u1∀u2v1∃u3v2...Qkukvk-1Q’kvk M<ans>(x,w)=1 ∧ [(ans=1 ∧ F(z,u1,...)=1) or (ans=0 ∧ F(z,v1,...)=0)] } i n Σk+1P
11
To show C = {(x,w,ans) | M<ans>(x,w)=1 and “ans correct”} in Σk+1P Suppose M makes only one query z=Z(x,w). ans is a single bit saying if z in A or not “ans correct”: (ans=1 ∧ z ∈ A) or (ans=0 ∧ z ∉ A) C={(x,w,ans) | M<ans>(x,w)=1 ∧ [(ans=1 ∧ ∃u1∀u2...Qkuk F(z,u1,...)=1) or (ans=0 ∧ ∀v1∃v2...Q’kvk F(z,v1,...)=0)] } C={(x,w,ans) | ∃u1∀u2v1∃u3v2...Qkukvk-1Q’kvk M<ans>(x,w)=1 ∧ [(ans=1 ∧ F(z,u1,...)=1) or (ans=0 ∧ F(z,v1,...)=0)] } Changes for t queries: z=Z(x,w) ! (z(1)...z(t)) = Z(x,w,ans), ui ! ui(1)...ui(t), vi ! vi(1)...vi(t), and use conjunction of t checks (for j=1,...,t) of the form [ (ans(j)=1 ∧ F(z(j),u1(j),...)=1) or (ans(j)=0 ∧ F(z(j),v1(j),...)=0) ] i n Σk+1P
11
12
Σk+1P = NPΣk (with Σ0P = P)
12
Σk+1P = NPΣk (with Σ0P = P) Πk+1P = co-NPΠk (with Π0P = P)
12
Σk+1P = NPΣk (with Σ0P = P) Πk+1P = co-NPΠk (with Π0P = P) Πk+1P = co-(NPΣk) = co-NPΣk = co-NPΠk
12
13
Δk+1P = PΣk = PΠk
13
Δk+1P = PΣk = PΠk Δ1P = P
13
Δk+1P = PΣk = PΠk Δ1P = P Δ2P = PNP
13
Δk+1P = PΣk = PΠk Δ1P = P Δ2P = PNP Note that Δ2P = co-Δ2P
13
Δk+1P = PΣk = PΠk Δ1P = P Δ2P = PNP Note that Δ2P = co-Δ2P Δk+1P ⊇ ΣkP ∪ ΠkP
13
Δk+1P = PΣk = PΠk Δ1P = P Δ2P = PNP Note that Δ2P = co-Δ2P Δk+1P ⊇ ΣkP ∪ ΠkP Δk+1P ⊆ Σk+1P ∩ Πk+1P (why?)
13
Δk+1P = PΣk = PΠk Δ1P = P Δ2P = PNP Note that Δ2P = co-Δ2P Δk+1P ⊇ ΣkP ∪ ΠkP Δk+1P ⊆ Σk+1P ∩ Πk+1P (why?) PΣk ⊆ NPΣk ∩ coNPΣk
13
P NP coNP Σ2P Π2P Σ3P Π3P
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP NPNPNP
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP NPNPNP coNPNPNP
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP NPNPNP coNPNPNP
Δ2P
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP NPNPNP coNPNPNP
Δ3P Δ2P
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP NPNPNP coNPNPNP PNP
Δ3P Δ2P
14
P NP coNP Σ2P Π2P Σ3P Π3P
NPNP coNPNP NPNPNP coNPNPNP PNP PNPNP
Δ3P Δ2P
14
15
Today, more PH
15
Today, more PH Oracle-based definitions (in particular NPNP = Σ2P)
15
Today, more PH Oracle-based definitions (in particular NPNP = Σ2P) Next lecture, more PH
15
Today, more PH Oracle-based definitions (in particular NPNP = Σ2P) Next lecture, more PH Alternating TM-based definitions
15
Today, more PH Oracle-based definitions (in particular NPNP = Σ2P) Next lecture, more PH Alternating TM-based definitions Time-Space tradeoffs
15