|
|
Line 1: |
Line 1: |
| In [[computational complexity theory]], the '''Immerman–Szelepcsényi theorem''' was proven independently by [[Neil Immerman]] and [[Róbert Szelepcsényi]] in 1987, for which they shared the 1995 [[Gödel Prize]]. In its general form the theorem states that [[NSPACE]](''s''(''n'')) = co-NSPACE(''s''(''n'')) for any function ''s''(''n'') ≥ log ''n''. The result is equivalently stated as [[NL (complexity)|NL]] = co-NL; although this is the special case when ''s''(''n'') = log ''n'', it implies the general theorem by a standard [[padding argument]]{{Citation needed|date=July 2010}}. The result solved the [[linear bounded automaton#LBA problems|second LBA problem]].
| | Golda is what's created on my birth certification even though it is not the name on my birth certification. I am truly fond of to go to karaoke but I've been taking on new issues lately. Office supervising is what she does for a living. My wife and I reside in Mississippi and I love psychic ([http://cspl.postech.ac.kr/zboard/Membersonly/144571 http://cspl.postech.ac.kr]) every working day living here. |
| | |
| In other words, if a nondeterministic machine can solve a problem, it can solve its [[complement (complexity)|complement]] problem (with the ''yes'' and ''no'' answers reversed) in the same asymptotic amount of space. No similar result is known for the time complexity classes, and indeed it is conjectured that [[NP (complexity)|NP]] is not equal to [[co-NP]].
| |
| | |
| ==Proof ==
| |
| '''Theorem:''' Let ''s''(''n'') ≥ log ''n'' be any function. Then NSPACE[''s''(''n'')] = co-NSPACE[''s''(''n'')].
| |
| | |
| The first step is to demonstrate that [[NL (complexity)|NL]] = co-NL. This can be accomplished by taking the [[st-connectivity]] problem (known to be [[NL-complete]]), and showing that the complement of this problem (called [[st-non-connectivity]]) is also in NL.
| |
| | |
| '''Definition:''' Given a [[directed graph]] ''G'' with ''n'' vertices, and vertices ''s'' and ''t'' in ''G'', the st-non-connectivity problem is to determine whether there is no [[Path (graph theory)|directed path]] between vertex ''s'' and ''t'':
| |
| :<math>\text{st-non-connectivity}=\{\langle G=\langle V,E\rangle,s,t\rangle\colon \text{there is no path from }s\text{ to }t\text{ in graph }G\}.</math>
| |
| | |
| In order to illustrate that st-non-connectivity is in NL, one can construct a non-deterministic algorithm that, in logarithmic space, decides whether two given vertices are not connected. To prove correctness of this algorithm, one must show two things:
| |
| | |
| *If the non-deterministic choices are made "correctly" and ''s'' and ''t'' are disconnected, then the algorithm accepts.
| |
| *If ''s'' and ''t'' are connected, no matter what non-deterministic choices are made the algorithm does not accept.
| |
| | |
| Here are the key ideas of the proof of the second condition. For sake of contradiction assume that ''s'' and ''t'' are connected but the algorithm accepts. To keep the adversary controlling the non-determinism "honest", the algorithm is designed so that if the non-determinism is uncooperative, the algorithm rejects at the end of the ENUMERATE subroutine. Therefore since we assumed that the algorithm accepts, the non-determinism must have been cooperative, which implies by the design of the algorithm that we should have rejected, a contradiction.
| |
| | |
| First, define ''A<sub>i</sub>'' as follows:
| |
| ''A<sub>i</sub>'' = {''v'': there is a path from ''s'' to ''v'' of length ≤ ''i''}. In other words, ''A<sub>i</sub>'' will include all vertices that are reachable from ''s'' in ''i'' or
| |
| fewer hops. Let ''r<sub>i</sub>'' = |''A<sub>i</sub>''|. Note that if ''t'' is not in ''A''<sub>''n''−1</sub>, where ''n'' = |''V''|, then there is no path from ''s'' to ''t'' in ''G'', i.e., <math>\langle G,s,t\rangle</math> ∈ st-non-connectivity.
| |
| | |
| '''Lemma''': An algorithm can be constructed that given ''r<sub>i</sub>'' will enumerate vertices in ''A<sub>i</sub>'' and ACCEPT in logarithmic space. Note that if the given ''r<sub>i</sub>'' is larger than the true number of vertices in ''A<sub>i</sub>'', then the algorithm REJECTs; however, if ''r<sub>i</sub>'' is less than the true number of vertices in ''A<sub>i</sub>'' the algorithm would ACCEPT but enumerate only a subset of ''A<sub>i</sub>''.
| |
| | |
| ENUMERATE(s,i,r_i,G)
| |
| 1: Counter := 0
| |
| 2: FOR ALL vertices v in G
| |
| 3: Nondeterministically either CONTINUE or guess a path of length less than or equal to i from s to v
| |
| 4: Counter := Counter + 1
| |
| 5: Output v
| |
| 6: IF Counter ≥ r_i
| |
| 7: ACCEPT
| |
| 8: REJECT
| |
| | |
| ENUMERATE goes through all vertices of graph ''G'' in logarithmic space, since the representation of each vertex and the Counter requires only log |''G''| bits and nondeterministically selecting a path also requires only logarithmic space.
| |
| | |
| Now, with ENUMERATE at hand it is possible to compute the actual ''r<sub>i</sub>'' in log-space using an algorithm that is based on the principle of [[mathematical induction]]. When using ENUMERATE as a subroutine, replace ACCEPT in ENUMERATE with RETURN while leaving REJECT as REJECT.
| |
| | |
| Obviously ''r''<sub>0</sub> = 1 since ''A<sub>i</sub>'' includes only the vertex ''s'' itself.
| |
| | |
| Now, assume ''r<sub>i</sub>'' is given. Then ''r''<sub>''i''+1</sub> can be calculated by the following algorithm in log-space:
| |
| | |
| INDUCTIVE-COUNTING (s,i,r_i,G)
| |
| 1: r := 1
| |
| 2: FOR ALL vertices v ≠ s:
| |
| 3: FOR EACH u such that (u,v) is an edge in G
| |
| 4: ENUMERATE (s,i,r_i,G)
| |
| 5: IF u is ever output
| |
| 6: r := r + 1
| |
| 7: BREAK
| |
| 8: Output r
| |
| | |
| This algorithm first accounts for the initial vertex ''s'', and then goes through all other vertices ''v'' of the graph ''G''. In lines 3–6 the algorithm tries to find a vertex ''u'' in ''A<sub>i</sub>'' directly connected to the vertex ''v'' by simulating ENUMERATE. If such vertex is found, that means that ''v'' is in ''A''<sub>''i''+1</sub>, so the result is incremented to account for this vertex. Note that the algorithm does not need to store all of the output of ENUMERATE every time it is called as a sub-routine. It can only store one vertex at a time and check if ''u'' is ever output. Thus, this algorithm runs in logarithmic space.
| |
| | |
| With this algorithm at hand we can devise an algorithm for st-non-connectivity consisting of two parts. The first part would compute ''r<sub>n</sub>'' by starting with ''r''<sub>0</sub> = 1 and then using INDUCTIVE-COUNTING ''n'' − 1 times. In the second part the algorithm just simulates ENUMERATE with the computed ''r<sub>n</sub>'' and if ''t'' is ever output that means it can be reached from ''v'', and the algorithm REJECTs.
| |
| | |
| NOT-CONNECTED (G,s,t)
| |
| 1: r_n := 1;
| |
| 2: FOR i := 1 TO n
| |
| 3: r_n := INDUCTIVE-COUNTING (s,i,r_n,G)
| |
| 4: ENUMERATE (s,n,r_n,G)
| |
| 5: IF t is ever output
| |
| 6: REJECT
| |
| 8: ELSE
| |
| 9: ACCEPT
| |
| | |
| This algorithm runs in logarithmic space, since we need log |''G''| bits for storing ''i'' and ''r<sub>n</sub>''. As was shown above, the ENUMERATE and INDUCTIVE-COUNTING algorithms also run in logarithmic space and again we do not need to store all of the output of ENUMERATE in line 4, but need only to check if ''t'' is ever output. Thus, NOT-CONNECTED can decide if there exists no path from vertex ''s'' to ''t'' in logarithmic space. I.e., st-non-connectivity is in NL. Since we can reduce each problem in NL to st-connectivity and each problem in co-NL to st-non-connectivity we conclude that NL = co-NL.
| |
| | |
| Now, for ''s''(''n'') ≥ log ''n'' we can transform the computations of any [[non-deterministic Turing machine]] ''M'' on language ''L'' into a graph of its states and simulate ''M'' using st-connectivity algorithm. Analogously we can transform any ''co-language'' into st-non-connectivity problem.
| |
| Both of these graphs would have 2<sup>''O''(''s''(''n''))</sup> vertices if ''L'' ∈ NSPACE(''s''(''n'')). Thus, we can decide both reachability and non-reachability of the ACCEPT state in log(2<sup>''O''(''s''(''n''))</sup>) = ''O''(''s''(''n'')) space and NSPACE(''s''(''n'')) = co-NSPACE(''s''(''n'')).
| |
| | |
| == Logspace hierarchy ==
| |
| As a corollary, in the same article, Immerman proved that, using [[descriptive complexity]]'s equality between [[NL (complexity)|NL]] and [[FO_(complexity)#Transitive_closure_is_NL|FO(Transitive Closure)]], the logarithmic hierarchy, i.e. the languages decided by [[alternating Turing machine]] in logarithm space with a bounded number of alternation, is the same class as NL.
| |
| | |
| ==See also==
| |
| * [[Savitch's theorem]] relates nondeterministic space classes to their deterministic counterparts
| |
| | |
| ==References==
| |
| * N. Immerman, ''[http://www.cs.umass.edu/~immerman/pub/space.ps Nondeterministic space is closed under complementation]'', SIAM Journal on Computing 17, 1988, pp. 935–938.
| |
| * R. Szelepcsényi, ''The method of forcing for nondeterministic automata'', Bulletin of the EATCS 33, 1987, pp. 96–100.
| |
| | |
| ==External links==
| |
| *Lance Fortnow, ''[http://oldblog.computationalcomplexity.org/archive/2003_06_01_archive.html#200380198 Foundations of Complexity, Lesson 19: The Immerman–Szelepcsenyi Theorem].'' Accessed 09/09/09.
| |
| | |
| {{DEFAULTSORT:Immerman-Szelepcsenyi theorem}}
| |
| [[Category:Structural complexity theory]]
| |
| [[Category:Mathematical theorems in theoretical computer science]]
| |
| [[Category:Articles containing proofs]]
| |
Golda is what's created on my birth certification even though it is not the name on my birth certification. I am truly fond of to go to karaoke but I've been taking on new issues lately. Office supervising is what she does for a living. My wife and I reside in Mississippi and I love psychic (http://cspl.postech.ac.kr) every working day living here.