Universal Traversal Sequences

0 downloads 0 Views 111KB Size Report
May 25, 1993 - Consider d-regular, undirected graphs G = (V; E). ... the (2;3)-labeled graph below, the sequence 12211 and start vertex A de ne the walk.
Universal Traversal Sequences Joan Feigenbaum

Nick Reingold

AT&T Bell Laboratories Murray Hill, NJ 07974 USA May 25, 1993

In this article we discuss a purely combinatorial problem, the construction of short universal traversal sequences, and its relationship to questions about logspace computation. We state the problem formally, show how it arises naturally in complexity theory, and review some of the known partial results. A basic introduction to complexity theory can be found in [6]. The P vs. NP problem is recognized by the mathematical world as the central open question in the theory of computation. Less widely known outside of computer science is the fact that the analogous question for space-bounded computation was resolved long ago : Savitch [8] shows that any language accepted by a nondeterministic Turing machine that uses space O(s(n)) is also accepted by a deterministic Turing machine that uses space O((s(n)) ). Hence deterministic polynomial space is equivalent (in terms of language-recognition power) to nondeterministic polynomial space: PSPACE = NPSPACE. However, one question about the relationship of nondeterministic space-bounded computation and its deterministic counterpart remains open: Is the quadratic \blowup" in space complexity exhibited by Savitch's construction necessary? This question turns out to be most interesting for computations that use very little space. Let L be the class of languages accepted by deterministic Turing machines using only O(log n) space, and NL be the class of languages accepted by nondeterministic Turing machines using only O(log n) space. It could be the case that Savitch's theorem is optimal at this low end of the space-complexity spectrum. On the other hand, it could be that any language recognizable by a nondeterministic Turing machine is also recognizable by a deterministic Turing machine with the same space complexity; if that's true, then NL is exactly equal to L. The truth might also lie somewhere between these two extremes. 1

2

Universal Traversal Sequences. We now consider a purely combinatorial prob-

lem. Consider d-regular, undirected graphs G = (V; E ). Such a graph is called (d; n)-labeled if it has n vertices and the edges incident to each vertex are labeled 1

by computer science standards.

1

by a permutation of f1; 2; : : : ; dg. Note that an edge has two labels, one associated with each of its endpoints, and that these labels may di er. A sequence of labels  =      m and a start vertex s de ne a walk s s    sm as follows. Let s = s. For 1  i  m, if i = j , then si is the (unique) vertex such that there is an edge e = fsi? ; sig and the label of e that is associated with si? is j . For example, in the (2; 3)-labeled graph below, the sequence 12211 and start vertex A de ne the walk ABCBAB. 1

2

0 1

1

0

1

A

1TT 2

   

T

  

T

T

T

T

1 B 2

1

T T

2 C

A sequence  is called (d; n)-universal if, for every connected (d; n)-labeled graph (V; E ) and every start vertex s 2 V , the walk de ned by  and s contains every vertex in V . For example, the sequence 112 is (2; 3)-universal. For expository purposes, we also de ne a directed version of universal traversal sequences. A d-regular directed graph G = (V; A) is called (d; n)-labeled if it has n vertices and the arcs out of each vertex are labeled with a permutation of f1; 2; : : : ; dg. Note that, in the directed case, arcs have only one label. A sequence  and start vertex s de ne a walk in essentially the same way as they do in the standard de nition. We say that  is (d; n)-directed-universal if, for every strongly connected (d; n)-labeled digraph (V; A) and every start vertex s, the walk de ned by  and s contains every vertex in V . The connection between universal traversal sequences and L vs. NL is made via the s-t connectivity problem. An instance of this problem consists of a directed graph G and two vertices s and t in V (G). The question is whether there is a path in G from s to t. There is a straightforward nondeterministic logspace algorithm for this problem: Guess a path s s s    sn? such that s = s and then check that each arc si? ! si is present in G and that some si = t. This algorithm is clearly correct, and it only requires space O(log n), where n = jV (G)j. To see why so little space is required, note that the algorithm does not need to store the entire path at any time. Rather, it need only store the names of two consecutive vertices si? and si ; once it has veri ed the presence of the arc si? ! si, it can write over si? with its guess for si . The language STCONN of yes-instances of the s-t connectivity problem is in fact NL-complete. Furthermore, STCONN remains NL-complete if we assume that the input digraphs are regular. So, if we could exhibit a deterministic logspace algorithm for (regular) s-t connectivity, we would have shown that L is equal to NL. It would 0 1 2

1

0

1

1

1

1

+1

2

suce to exhibit, for each constant d, a Turing machine that uses O(log n) space and generates a sequence n that is (d; n)-directed-universal. Note that the restriction to O(log n) space implies that the length of n is polynomial in n. Unfortunately, it can be shown that no family fngn of polynomial-length directed-universal sequences exists. (L might still be equal to NL, but the equality cannot be proven this way.) This raises the question of the existence of a family fngn that is deterministically logspace-generable such that n is (d; n)-universal (which is weaker than (d; n)-directed universal). Aleliunas et al. [1] give a beautiful probabilistic argument that, for any d, there is a polynomial-length family fngn such that n is (d; n)universal. Whether such a family can be generated in deterministic logspace remains open. 1

1

1

Constructing Universal Traversal Sequences. Consider a random walk in a connected undirected graph. At each time step the next vertex is chosen uniformly from the neighbors of the current vertex. We say the walk covers G if every vertex is visited at least once during the walk. For any vertex v, let Cv be the expected time at which a random walk starting at v covers G. The maximum over all v of Cv is called the cover time of the graph. Aleliunas et al. [1] show that the cover time for any d-regular graph with n vertices is at most n d. They then use this observation to prove the existence of (d; n)-universal traversal sequences of polynomial length as follows. Let  be a sequence of labels of length 4n d log nd chosen uniformly from the set of all such sequences. We will show that the probability that  is (d; n)-universal is not zero. The probability that  is not (d; n)-universal is the same as the probability that there exists a (d; n)-labeled graph G and a vertex v such that a random walk of length 4n d log nd starting at v does not cover G. This is the same as the probability that there exists a (d; n)-labeled graph G and a vertex v such that G is not covered by 2nd log nd consecutive random walks, each of length 2n d, the rst of which is started at v. Since any graph G has cover time at most n d, Markov's inequality shows that a random walk of length 2n d, starting from any vertex, has probability at most 1=2 of not covering G. If we take 2nd log nd such random walks consecutively, the probability that none of them covers G is at most (1=2) nd 2 nd = (nd)? nd . Thus, for any xed G and v, the walk through G starting at v given by  has probability at most (nd)? nd of not covering G. There are at most (nd)nd choices for v and G, so summing over all these choices shows that the probability that  is not universal is strictly less than one. This proves the existence of polynomial-length universal traversal sequences and suggests the possibility that the language USTCONN (the yes-instances of the s-t connectivity problem for undirected graphs) is in L. However, the above proof does not show this, since it does not show how to generate the traversal sequences using only O(log n) space. Whether this is possible is still an open problem. There are two interesting partial results that are worth mentioning. For d = 2, Istrail [4] gives a construction of polynomial-length traversal sequences, but his sequences cannot be constructed in deterministic logspace. For d = n ? 1, Karlo et al. [5] give an explicit 2

3 2

3 2

2

2

2

2

2

2

2

2

3

2

log

2

construction of traversal sequences of length nO

n

(log )

.

Traversal Sequences and Pseudorandom Generators. The best explicit uni-

versal traversal sequences constructed so far are due to Nisan [7]. This construction exploits a connection, due to Babai et al. [2], between traversal sequences and pseudorandom generators. In this context, a pseudorandom generator is an algorithm that converts a small number of truly random bits into a long sequence of bits that appears random to any Turing machine that uses only a limited amount of space. We will not give a precise de nition of \appears random to any Turing machine that uses only a limited amount of space." The interested reader should see [2] for details. Nisan's generators convert a truly random string of length O(S log R) into a string of length R that appears random to any Turing machine that uses space at most S . In particular, if S = O(log n) and R is polynomial in n, then Nisan's generators can convert O(log n) truly random bits into polynomially many bits that appear random to any Turing machine that uses only O(log n) space. We will now show that the concatenation of all the possible outputs of Nisan's pseudorandom generator is a (d; n)-universal traversal sequence of length nO n . Fix a (d; n)-labeled graph G and vertices u and v. Consider a logspace Turing machine that uses the contents of the random tape to perform a walk of length 4n d on G starting at u. If the Turing machine ever reaches v it returns 0, otherwise it returns 1. When the contents of the random tape is truly random the Turing machine returns 1 with probability at most 1=4n . If the random tape is actually the result of some pseudorandom generator the probability should still be close to 1=4n , else this logspace Turing machine could distinguish the pseudorandom inputs from the random ones. Thus the Turing machine with pseudorandom input will return 1 with probability at most, say, 1=2n . Since there are at most n choices for u and v, the probability that the pseudorandom generator produces a sequence that does not cover G is at most 1=2. This means that every (d; n)-labeled graph is covered by at least half of the possible outputs of the generator, so the concatenation of all of the 2n O outputs must be (d; n)-universal. Since there are 2 possible inputs, and each output has polynomial length, the concatenation of all outputs has length nO n . 2

(log )

4

2

2

2

2

(log

)

(log )

Further Reading. Wigderson [9] provides an extensive overview of the s-t con-

nectivity problem, universal traversal sequences, L vs. NL, and many other related combinatorial and algorithmic problems.

References [1] R. Aleliunas, R. Karp, L. Lovasz, R. Lipton, and C. Racko , Random Walks, Universal Traversal Sequences, and the Complexity of Maze Problems, Proceedings of the 20th Symposium on Foundations of Computer Science, IEEE Computer Society, Los Alamitos, 1979, pp. 218{223. 4

[2] L. Babai, N. Nisan, and M. Szegedy, Multiparty Protocols, Pseudorandom Generators for Logspace, and Time-Space Trade-O s, Journal of Computer and System Sciences, 45 (1992), pp. 204{232. [3] M. Garey and D. Johnson, Computers and Intractability: A Guide to the Theory of NP-Completeness, Freeman, San Francisco, 1979. [4] S. Istrail, Polynomial Universal Traversal Sequences for Cycles are Constructible, Proceedings of the 20th Symposium on Theory of Computing, ACM, New York, pp. 491{503. [5] H. Karlo , R. Paturi, J. Simon, Universal Traversal Sequences of Length nO n for Cliques, Information Processing Letters, 28 (1988), pp. 241{243 [6] B. Marion, \The Computer Science Sampler: Turing Machines and Computational Complexity," The American Mathematical Monthly, January 1994. [7] N. Nisan, Pseudorandom Generators for Space-Bounded Computation, Combinatorica, 12 (1992), pp. 449{461. [8] W. Savitch, Relationships Between Nondeterministic and Deterministic Tape Complexities, Journal of Computer and System Sciences, 4 (1970), pp. 177{192. [9] A. Wigderson, The Complexity of Graph Connectivity, Proceedings of the 17th Mathematical Foundations of Computer Science Conference, Lecture Notes in Computer Science, vol. 629, eds.: Havel and Koubek, Springer, Berlin, 1992, pp. 112{132. (log )

5

Suggest Documents