Documentation

CslibFrontier.Computability.Complexity.Classes.Alternation.DeterministicTime

Alternating space within deterministic exponential time #

An alternating machine within space s is simulated deterministically within time 2 ^ O(log₂ n + s) Chandra, Kozen and Stockmeyer, Section 3 Sipser, Section 10.3: list the reachable views by breadth-first search until no new view appears, then mark them bottom-up (Turing.MultiTapeATM.reachableAccepts). The simulation holds for recognizers (Turing.MultiTapeATM.RecognizesInSpace), whose branches need not halt, which is the space-bounded acceptance of Chandra, Kozen and Stockmeyer. Acceptance is the least fixed point of the labelling, so an infinite branch never helps a view accept. The class Cslib.Complexity.ASPACE uses the deciding form, in which every branch also halts, so the inclusion holds for it a fortiori. The space bound need not be constructible: the search stops by itself, and the bound enters only the analysis.

Main results #

References #

theorem Turing.MultiTapeATM.RecognizesInSpace.mem_DTIME {α : Type} {enc : α ↪ List Bool} {k : ℕ} {State : Type} [Finite State] {atm : MultiTapeATM k Bool State} {A : Set α} {s : ℕ → ℕ} (h : atm.RecognizesInSpace enc A fun (a : α) => s (enc a).length) :
∃ (c : ℕ), A ∈ Cslib.Complexity.DTIME enc fun (n : ℕ) => 2 ^ (c * (n.log2 + s n + 1))

Space-bounded alternating recognizers are within exponential time Chandra, Kozen and Stockmeyer, Section 3: a problem recognized by an alternating machine within space s n, whose branches need not halt, is decided deterministically within time 2 ^ (c * (log₂ n + s n + 1)) for a constant c of the machine. The space bound need not be constructible.

theorem Cslib.Complexity.exists_mem_DTIME_of_mem_ASPACE {α : Type} {enc : α ↪ List Bool} {s : ℕ → ℕ} {A : Set α} (h : A ∈ ASPACE enc s) :
∃ (c : ℕ), A ∈ DTIME enc fun (n : ℕ) => 2 ^ (c * (n.log2 + s n + 1))

Alternating space is within deterministic exponential time Chandra, Kozen and Stockmeyer, Section 3 Sipser, Section 10.3: ASPACE s ⊆ DTIME (2 ^ O(log₂ n + s n)). The space bound need not be constructible.

theorem Cslib.Complexity.exists_mem_DTIME_of_mem_ASPACE_of_log2_le {α : Type} {enc : α ↪ List Bool} {s : ℕ → ℕ} {A : Set α} (hs : ∀ (n : ℕ), n.log2 ≤ s n) (h : A ∈ ASPACE enc s) :
∃ (c : ℕ), A ∈ DTIME enc fun (n : ℕ) => 2 ^ (c * s n)

Alternating space is within deterministic exponential time above logarithmic space Chandra, Kozen and Stockmeyer, Section 3 Sipser, Section 10.3: ASPACE s ⊆ DTIME (2 ^ O(s n)) when log₂ n ≤ s n.