Savitch's theorem: NSPACE(s) ⊆ DSPACE(s²) #
A problem decided, or only recognized, by a nondeterministic machine within space O(s) is
decided by a deterministic machine within space O(s ^ 2), whenever log₂ n ≤ s n: this
inclusion is Savitch's theorem [Sav70]. No constructibility of s is assumed. As in Sipser's
proof of Theorem 8.5, which tries the space bounds 1, 2, 3, … in turn [Sip13], the simulating
machine (Turing.MultiTapeNTM.exists_decidableInTimeAndSpace_sq) tries growing radices for the
configuration graph and detects when the simulated machine leaves the current radix. The radices
are those of Turing.MultiTapeNTM.ConfigurationGraph.roundRadix, shared with Immerman's inductive
counting for Cslib.Complexity.NSPACE_eq_coNSPACE.
Sipser's Theorem 8.5 assumes f(n) ≥ n; the final paragraph of his Section 8.4 (3rd edition,
p. 351) extends it to sublinear bounds f(n) ≥ log n. Arora and Barak's Theorem 4.14 assumes a
space-constructible bound S(n) ≥ log n. The sources are about deciders on strings; the
statements here also cover nonhalting recognizers and arbitrary encoded instances.
Main results #
Cslib.Complexity.mem_DSPACE_sq_of_recognizesInSpace: a recognizer within spaceO(s), whose branches need not halt, places its problem inDSPACE(s²).Cslib.Complexity.NSPACE_subset_DSPACE_sq: Savitch's theorem,NSPACE(s) ⊆ DSPACE(s²)forlog₂ n ≤ s n.
References #
- W. J. Savitch, Relationships between nondeterministic and deterministic tape complexities; journal text not inspected (paywalled), so no theorem number or page is cited.
- M. Sipser, Introduction to the Theory of Computation, 3rd edition, Theorem 8.5 and its proof, and the final paragraph of Section 8.4 (p. 351)
- S. Arora and B. Barak, Computational Complexity: A Modern Approach, Theorem 4.14
Savitch's theorem for recognizers [Sav70]: a problem recognized by a nondeterministic
machine within space c₁ * s n + c₂, whose branches need not halt, is in DSPACE(s²) when
log₂ n ≤ s n. The bound s need not be constructible.
Savitch's theorem [Sav70]: NSPACE(s) ⊆ DSPACE(s²) for every bound with
log₂ n ≤ s n, for the library's native machines and arbitrary injective instance encodings. The
bound s need not be constructible: the simulation tries growing bounds, as in Sipser's proof of
Theorem 8.5 [Sip13].