Documentation

CslibFrontier.Computability.Complexity.Classes.Space.Time

Comparing deterministic time and space classes #

Time bounds space linearly, while a halting space-bounded computation can run for at most its number of readable configurations. These are the encoded-instance inclusions corresponding to cslib pull request #767; no hierarchy theorem is needed.

Main results #

References #

theorem Cslib.Complexity.DTIME_subset_DSPACE {α : Type u_1} {enc : α ↪ List Bool} {t : ℕ → ℕ} :
DTIME enc t ⊆ DSPACE enc t

Time bounds space: a machine visits at most one new cell per work tape and step, so DTIME t ⊆ DSPACE t.

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

Space bounds time exponentially (DSPACE s ⊆ DTIME ((n + 2) * 2 ^ O(s)), for encoded instances, corresponding to the space-to-time inclusion of cslib pull request #767): a decider within space O(s n) halts within its number of configurations, O((n + 2) * 2 ^ (c * s n)) for a constant c of the decider.