Emile Timothy
Main Page

Blog

Proving the Karp-Lipton theorem: \(\text{PH} = S_2^P\)

Happy Monday! Today, I'm going to share something really cool about the polynomial hierarchy. I know that I've written prior entries about the polynomial hierarchy where I've praised some of its properties, but this result about the Polynomial Hierarchy is the WILDest thing ever! If you're new here, I'm going to start by giving my regular schpiel about what the polynomial hierarchy is.

Define \(\Delta_0^P := \Sigma_0^P := \Pi_0^P:=P\), where \(P\) is the set of problems that can be solved in poly-time. Then, for all \(i \geq 0\), define: $$\Delta_{i+1}^P:=\text{P}^{\Sigma_i^P}$$ $$\Sigma_{i+1}^P:=\text{NP}^{\Sigma_i^P}$$ $$\Pi_{i+1}^P:=\text{coNP}^{\Sigma_i^P}$$ The polynomial-time hierarchy is defined as: $$\text{PH} = \bigcup_{i\in\mathbb{N}} \{\Delta_i^P, \Sigma_i^P, \Pi_i^P\}$$ The result that I want to show here is that every language in the polynomial hierarchy is equivalent in computational power to the complexity class of symmetric functions \(S_2^P\), which resides between the first and second levels of the polynomial hierarchy.

The formal definition of \(S_2^P\) is that any language \(L\) is said to be in \(S_2^P\) if there is a polynomial-time predicate \(P\) such that:
If \(x\in L\), then there exists a \(y\) such that for all \(z\), \(P(x,y,z)=1\)
If \(x\not\in L\), then there exists a \(z\) such that for all \(y\), \(P(x,y,z)=0\)

Another, more intuitive way to look at \(S_2^P\) is the following: Suppose that a polynomial-time computable judge has to decide whether a string \(x\) is in a language \(L\). Two lawyers submit written arguments to convince the judge, one arguing for the string in the language and the other arguing for the string to be out of the language. Neither lawyer can see the others arguments. For what languages can we have the judge always convinced? (The answer is \(S_2^P\)!)


Let L be an arbitrary language in \(𝑆_𝑝\). It follows by definition then that: $$ π‘₯ ∈ 𝐿 β‡’ βˆƒπ‘¦ βˆ€π‘§, (π‘₯, 𝑦, 𝑧) ∈ 𝑅$$ $$ π‘₯ βˆ‰ 𝐿 β‡’ βˆƒπ‘§ βˆ€π‘¦, (π‘₯, 𝑦, 𝑧) βˆ‰ 𝑅 $$ However, note that the order of the universal and existential quantifiers is commutative in this case only if the commutator is taken in both directions. So, from this we can write two alternate versions of the definition, where version 1 commutes the quantifiers in the case for \(π‘₯ ∈ 𝐿\) while holding the case for \(π‘₯ βˆ‰ 𝐿\) to be constant, and version 2 commutes the quantifiers in the case for \(π‘₯ βˆ‰ 𝐿\) while holding the case for \(π‘₯ ∈ 𝐿\) to be constant. This procedure yields:

Version 1: $$π‘₯ ∈ 𝐿 β‡’ βˆ€π‘§ βˆƒπ‘¦, (π‘₯, 𝑦, 𝑧) ∈ 𝑅$$ $$π‘₯ βˆ‰ 𝐿 β‡’ βˆƒπ‘§ βˆ€π‘¦, (π‘₯, 𝑦, 𝑧) βˆ‰ 𝑅$$ Version 2: $$π‘₯ ∈ 𝐿 β‡’ βˆƒπ‘¦ βˆ€π‘§, (π‘₯, 𝑦, 𝑧) ∈ 𝑅$$ $$π‘₯ βˆ‰ 𝐿 β‡’ βˆ€π‘¦ βˆƒπ‘§, (π‘₯, 𝑦, 𝑧) βˆ‰ 𝑅$$ However, by definition, the complexity class that version 1 decides is equal to \(\Sigma_2^P\), and the complexity class that version 2 decides is equal to \(\Pi_2^P\). Therefore, if \(π‘₯ ∈ S_2^P\) then \(π‘₯ ∈ \Sigma_2^P\) and \(π‘₯ ∈ \Pi_2^P\).

Therefore, we have that: $$S_2^𝑃 βŠ† (\sigma_2^P ∩ \Pi_2^P)$$ QED.


The language LEX-FIRST-ACCEPTANCE consists of those pairs \((π‘ͺ_𝟏, π‘ͺ_𝟐)\) for which \(π‘ͺ_𝟏, π‘ͺ_𝟐\) are circuits, and the lexicographically first-string \(x\) for which \(π‘ͺ_𝟏(𝒙) = 𝟏\) is also accepted by \(π‘ͺ_𝟐\). (If there is no lexicographically first string, i.e., \(π‘ͺ_𝟏\) is unsatisfiable, then \((π‘ͺ_𝟏, π‘ͺ_𝟐)\) is not in the language). A bitstring \(x\) lexicographically precedes a bitstring \(y\) if the first position \(i\) in which they differ has \(𝒙_π’Š = 𝟎\) and \(π’š_π’Š = 𝟏\).

The purpose of this lemma is to show that LEX-FIRST-ACCEPTANCE is \(P^{\text{NP}}\)-complete - that not only is it solvable by \(P^{\text{NP}}\) Turing Machine, but also it is representative of every problem in the \(P^{\text{NP}}\) complexity class.

Sub-Lemma 2.1: \(𝐿𝐹𝐴 ∈ P^{\text{NP}}\):

Given an instance \((𝐢_1, 𝐢_2)\), call the \(\text{NP}\) oracle to determine the first lexicographically first string \(π‘₯ ∈ \{0, 1\}^𝑛\) that is accepted by \(𝐢_1\). The \(\text{NP}\) oracle nondeterministically evaluates each string with \(𝐢_1\) but uses an arbitrary enumeration scheme to prioritize which string that is accepted by \(𝐢_1\) is lexicographically first. If there is no such string, the machine returns false.

If \(βˆƒ\) a lexicographically-first string \(x\), the \(P\) machine would check if \(𝐢_2(π‘₯) = 1\):
If \(𝐢_2(π‘₯) = 1\), the \(P\) machine returns ACCEPT.
If \(𝐢_2(π‘₯) = 0\), the \(P\) machine returns REJECT.

QED.



In Lemma 2, I showed that LEXβˆ’FIRSTβˆ’ACCEPTANCE (LFA) \(∈ \text{P}^\text{NP}\)-complete. Therefore, to show that \(P^\text{NP} βŠ† 𝑆_2^P\), we can instead just show that \(\text{LFA} ∈ S_2^P\) since \(\text{LFA}\) can then be generalized to all other languages in \(𝑃^{\text{NP}}\). Therefore, our goal is to show that for some predicate \(T\):
$$1) βˆ€π‘₯∈\text{LFA}, βˆƒπ‘¦βˆ€π‘§, 𝑇(π‘₯,𝑦,𝑧)=1$$ $$2) βˆ€π‘₯βˆ‰\text{LFA}, βˆƒπ‘§βˆ€π‘¦, 𝑇(π‘₯,𝑦,𝑧)=0$$ Given an instance \((𝐢_1, 𝐢_2)\) of \(\text{LFA}\), we let \(πœ™(π‘₯, 𝑦)\) be the lexicographically-first string (to be accepted by circuit \(𝐢_1\)) between \(x\) and \(y\). Therefore, we define the following predicate \(T\): \(𝑇(π‘₯, 𝑦, 𝑧) = 𝐢_2(πœ™(π‘₯, 𝑦))\).

In the case that \(𝐢_1(π‘₯)\) and \(𝐢_1(𝑦)\) are both \(0\), there is no lexicographically-first string. In this case, we simply set \(𝑇(π‘₯, 𝑦, 𝑧) = 0\). However, we can rewrite this as: $$(𝐢_1,𝐢_2) ∈ \text{LFA} \Rightarrow βˆƒyβˆ€z(βˆ€x), T(x,y,z) = 1 \Rightarrow βˆƒyβˆ€x, T(x,y)=1$$ $$(𝐢_1,𝐢_2) βˆ‰ \text{LFA} \Rightarrow βˆƒzβˆ€y(βˆ€x), T(x,y,z) = 0 \Rightarrow βˆƒxβˆ€y, T(x,y)=0$$ Since this is the definition of \(𝑆_2^𝑃\) (modified from above), this implies that \(\text{LFA} ∈ 𝑆_2^𝑃\). Hence, by the \(\text{P}^{\text{NP}}\)-completeness of \(\text{LFA}\), we have that: $$\text{P}^{\text{NP}} βŠ† 𝑆_2^P$$ QED.



\(βˆ€ 𝐿_1 ∈ \text{MA}\), we have by definition that: $$π‘₯ ∈ 𝐿_1 β‡’ βˆƒπ‘¦, \Pr\limits_z [(π‘₯,𝑦,𝑧)βˆˆπ‘…]β‰₯\frac{2}{3}$$ $$π‘₯ βˆ‰ 𝐿_1 β‡’ βˆ€π‘¦, \Pr\limits_z [(π‘₯,𝑦,𝑧)βˆˆπ‘…]≀\frac{1}{3}$$ \(βˆ€ 𝐿_2 ∈ 𝑆_2^P\), we have by definition that: $$π‘₯ ∈ 𝐿_2 β‡’ βˆƒπ‘¦βˆ€π‘§, (π‘₯,𝑦,𝑧)βˆˆπ‘…$$ $$π‘₯ βˆ‰ 𝐿_2 β‡’ βˆƒπ‘§ βˆ€π‘¦, (π‘₯,𝑦,𝑧)βˆ‰π‘…$$ We can increase the probability of successfully accepting a β€œyes” instance through error reduction, from which we know that \(βˆ€ 𝐿_1 ∈ \text{MA}, βˆƒπ‘… ∈ P\) such that: $$π‘₯ ∈ 𝐿_1 β‡’ βˆƒπ‘¦, \Pr\limits_z[(π‘₯,𝑦,𝑧)βˆˆπ‘…]=1$$ $$π‘₯ βˆ‰ 𝐿_1 β‡’ βˆ€π‘¦, \Pr\limits_z[(π‘₯,𝑦,𝑧)βˆˆπ‘…]≀\frac{1}{3}$$ Similarly, we can successfully decrease the probability of incorrectly accepting a β€œno” instance through repeated error reduction which reduces the probability to: $$π‘₯ ∈ 𝐿_1 β‡’ βˆƒπ‘¦, \Pr\limits_z[(π‘₯,𝑦,𝑧)βˆˆπ‘…]=1$$ $$π‘₯ βˆ‰ 𝐿_1 β‡’ βˆ€π‘¦, \Pr\limits_z[(π‘₯,𝑦,𝑧)βˆˆπ‘…]≀ \frac{1}{2^{|𝑦|}}$$ We claim then through these definitions that \(βˆ€πΏ ∈ \text{MA}, 𝐿 ∈ 𝑆_2^P\). To show that \(π‘₯ ∈ 𝐿 β‡’ βˆƒπ‘¦, \Pr\limits_z[(π‘₯, 𝑦, 𝑧) ∈ 𝑅] = 1\) is contained in \(π‘₯ ∈ 𝐿_2 β‡’ βˆƒπ‘¦ βˆ€π‘§, (π‘₯, 𝑦, 𝑧) ∈ 𝑅\): Since the probability of \((π‘₯, 𝑦, 𝑧) ∈ R\) is \(1\) for all \(z\): $$π‘₯ ∈ 𝐿_1 β‡’ βˆƒπ‘¦, \Pr\limits_z [(π‘₯,𝑦,𝑧)βˆˆπ‘…]=1$$ $$ β‡’ π‘₯ ∈ 𝐿_2 β‡’ βˆƒπ‘¦ βˆ€π‘§, (π‘₯,𝑦,𝑧)βˆˆπ‘…$$ Using Boole’s inequality, we can take the union bound of the probability of incorrectly accepting a β€œno” instance of \(L\) across all possible values of \(y\) to get: $$π‘₯ βˆ‰ 𝐿_1 β‡’ βˆ€π‘¦, \Pr\limits_z [(π‘₯,𝑦,𝑧)βˆˆπ‘…]≀ \frac{1}{2^{|y|}}$$ $$∈ βˆƒπ‘¦ \text{ such that }\Pr\limits_z [(x, y, z)βˆˆπ‘…] ≀ \frac{1}{2^{|y|}}\times 2^{|y|}$$ $$= βˆƒπ‘¦ \text{ such that }\Pr\limits_z [(x, y, z)βˆˆπ‘…] =1$$ $$∈ βˆƒ 𝑧 \text{ such that } βˆ€y(x, y, z)βˆ‰π‘…$$ $$π‘₯ βˆ‰ L_2 β‡’ βˆƒπ‘§ βˆ€y, (x, y, z) βˆ‰ 𝑅$$ These equations fits the necessary condition for all languages in \(𝑆_2^P\). Therefore, we have that: $$βˆ€ 𝐿 ∈ \text{MA}, \text{MA} ∈ 𝑆_2^P$$ $$\text{MA} βŠ† 𝑆_2^P$$ QED.



Lemma \(1\): \(\text{BPP} βŠ† \text{MA}\)

Given an arbitrary language \(\text{L} \in \text{BPP}\), we can show that there is an \(\text{MA}\) protocol that decides an instance \(x\):

Merlin (the prover) sends a single TRUE (\(1\)) bit (This is just a filler so that Merlin is doing something)

Arthur (the verifier) disregards Merlin’s bit and simulates the \(\text{BPP}\) machine for \(L\) on \(x\).
Note here that this is only possible since Arthur has the ability to flip coins and make random decisions.
If the \(\text{BPP}\) machine returns β€œTRUE”, Arthur returns β€œTRUE”.
If the BPP machine returns β€œFALSE”, Arthur returns β€œFALSE”.

Completeness and Soundness are intact here because Arthur simulates the \(\text{BPP}\) machine which has the same probabilities:
In particular, \(βˆ€π‘₯ ∈ L\), \(\Pr[π‘₯ \text{ accepted}] β‰₯ \frac{2}{3}\) and \(βˆ€π‘₯ βˆ‰ L\), \(\Pr[π‘₯ \text{ rejected}] β‰₯ \frac{2}{3}\).

Therefore, any language in \(\text{BPP}\) has an \(\text{MA}\) protocol that decides it. Hence, \(\text{BPP} βŠ† \text{MA}\).

QED.

Therefore, since we know that \(\text{BPP} βŠ† \text{MA}\), we can use the transitivity property and the result proven in Lemma 4 to obtain:
$$\text{BPP} βŠ† \text{MA} βŠ† S_2^P$$ From this, we have that \(\text{BPP} βŠ† S_2^P\).

QED.




It is known from the Cook-Levin theorem that \(\text{SAT} ∈ \text{NP-complete}\). Therefore, if \(\text{SAT}\) has polynomial-size circuits, then: $$ \text{NP} \subseteq \text{P}/\text{poly}$$ To show that \(\text{PH} = S_2^P\), we need to show that:
1) \(\text{PH} = \Sigma_2^P\)
2) \(\text{PH} = \Pi_2^P\)

In Lemma \(1\), we showed that \(\text{PH} \subseteq \Sigma_2^P \cap \Pi_2^P\). Therefore, the onus of this proof is to show that:
1) \(\Sigma_2^P βŠ† \text{PH}\)
2) \(\Pi_2^P βŠ† \text{PH}\)

Sub-Lemma 6.1: \(\Sigma_2^𝑃 = \text{PH}\)
This follows from the regular Karp-Lipton theorem shown in Lemma 4.
Therefore, \(\Sigma_2^𝑃 βŠ† \text{PH}\) is trivially true.
QED.

Sub-Lemma 6.2: \(\Pi_2^P βŠ† \text{PH}\):
Let \(𝐢\) be a family of circuits which output \(1\) on satisfiable inputs and \(0\) on unsatisfiable inputs.
Let \(C'\) be the family of circuits using self-reducibility of \(\text{SAT}\) instances to output satisfying assignments for \(\text{SAT}\) formulas.

Let \(L\) be an arbitrary language in \(\Pi_2^P\) and let \(πœ™\) be a predicate in \(P\). It follows then that:
$$π‘₯∈𝐿 β‡’ βˆ€π‘¦βˆƒπ‘§, πœ™(π‘₯,𝑦,𝑧)=1$$ $$π‘₯βˆ‰πΏ β‡’ βˆƒπ‘¦βˆ€π‘§, πœ™(π‘₯,𝑦,𝑧)=0$$
However, note here that \(\{(π‘₯, 𝑦) | βˆƒπ‘§, Ο†(x, y, z) = 1\}\) is by definition in \(\text{NP}\) (where \(z\) is a witness).

Therefore, \(C'\) must exist to find satisfying assignments \(z\) for satisfying formulas \(x\).

We define the predicate \(πœ™'\) to be the polynomially verifiable instance \((𝐢, π‘₯, 𝑦)\).
Note that \((C,x,y)\) is \(\text{TRUE}\) if \(𝐢'(π‘₯) = 𝑧\), where \(πœ™(π‘₯, 𝑦, 𝑧) = 1\), and \(\text{FALSE}\) otherwise.

Therefore,
$$π‘₯βˆˆπΏβ‡’ βˆƒπΆ \text{ such that }βˆ€π‘¦, 𝐢'(π‘₯)=𝑧 \text{ such that } πœ™'(π‘₯,𝑦,𝑧)=1$$ $$π‘₯βˆ‰πΏβ‡’ βˆ€πΆ \text{ such that }βˆƒπ‘¦ βˆ€π‘§, 𝐢'(π‘₯)=𝑧 \text{ such that } πœ™'(π‘₯,𝑦,𝑧)=0$$
However, this can just be rewritten as:
$$π‘₯∈𝐿 β‡’ βˆƒπΆβˆ€π‘¦, πœ™'(𝐢,π‘₯,𝑦)=1$$ $$π‘₯βˆ‰πΏ β‡’ βˆƒπ‘¦βˆ€πΆ, πœ™'(𝐢,π‘₯,𝑦)=0$$
Therefore, by definition \(𝐿 ∈ S_2^𝑃\). Since \(L ∈ \Pi_2^P\), we have that \(\Pi_2^P βŠ† S_2^P\).

QED.

Therefore, since we have shown that $$\Sigma_2^P βŠ† \text{PH},\quad \Pi_2^P βŠ† \text{PH},$$ and since we already know that $$\text{PH} βŠ† \Sigma_2^𝑃 ∩ \Pi_2^P,$$ we now have that $$\text{PH} = \Sigma_2^P \text{ and } \text{PH} = \Pi_2^𝑃.$$ Therefore, $$S_2^P = \Pi_2^P = \Sigma_2^P.$$ This gives us: $$\text{PH} = S_2^P$$ QED.