Documentation

CslibFrontier.Computability.Complexity.Classes.CountingSimulation.FastSimulation

Counting, nondeterministic and probabilistic time in time 2 ^ O(T / √log T) and polynomial space #

The class containments of CslibFrontier.Computability.Complexity.Classes.CountingSimulation.BlockNetworks, with the contraction algorithm of Theorem D.1 of [OAI26k] (CountingSimulation.fastContractionAlgorithm) in place of their hypothesis. These are the containments of #1833: for time-constructible T with max n 2 ≤ T n, every counting function in SharpTIME[T] is computed, with its exact value in binary, and every problem in NTIME[T], BPTIME[T] or PPTIME[T] is decided, by one deterministic machine in time 2 ^ (C T n / √⌊log₂ (T n)⌋) and workspace T n ^ d.

Main results #

References #

theorem Cslib.Complexity.CountingSimulation.exists_computableInTimeAndSpace_two_pow_div_sqrt_log_two_of_mem_SharpTIME {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) {f : α → ℕ} (hf : f ∈ SharpTIME enc T) :
∃ (C : ℕ) (d : ℕ), Turing.MultiTapeTM.ComputableInTimeAndSpace f enc Turing.MultiTapeTM.encNat (fun (a : α) => 2 ^ (C * T (enc a).length / (Nat.log 2 (T (enc a).length)).sqrt)) fun (a : α) => T (enc a).length ^ d

Exact terminal counting in time 2 ^ O(T / √log T) and space T ^ O(1). One deterministic machine computes each function in SharpTIME[T], writing the exact count in binary.

theorem Cslib.Complexity.CountingSimulation.exists_decidableInTimeAndSpace_two_pow_div_sqrt_log_two_of_mem_NTIME {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) {L : Set α} (hL : L ∈ NTIME enc T) :
∃ (C : ℕ) (d : ℕ), Turing.MultiTapeTM.DecidableInTimeAndSpace L enc (fun (a : α) => 2 ^ (C * T (enc a).length / (Nat.log 2 (T (enc a).length)).sqrt)) fun (a : α) => T (enc a).length ^ d

Nondeterministic time T in time 2 ^ O(T / √log T) and space T ^ O(1).

theorem Cslib.Complexity.CountingSimulation.exists_decidableInTimeAndSpace_two_pow_div_sqrt_log_two_of_mem_BPTIME {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) {L : Set α} (hL : L ∈ BPTIME enc T) :
∃ (C : ℕ) (d : ℕ), Turing.MultiTapeTM.DecidableInTimeAndSpace L enc (fun (a : α) => 2 ^ (C * T (enc a).length / (Nat.log 2 (T (enc a).length)).sqrt)) fun (a : α) => T (enc a).length ^ d

Bounded-error probabilistic time T in time 2 ^ O(T / √log T) and space T ^ O(1).

theorem Cslib.Complexity.CountingSimulation.exists_decidableInTimeAndSpace_two_pow_div_sqrt_log_two_of_mem_PPTIME {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) {L : Set α} (hL : L ∈ PPTIME enc T) :
∃ (C : ℕ) (d : ℕ), Turing.MultiTapeTM.DecidableInTimeAndSpace L enc (fun (a : α) => 2 ^ (C * T (enc a).length / (Nat.log 2 (T (enc a).length)).sqrt)) fun (a : α) => T (enc a).length ^ d

Strict-majority probabilistic time T in time 2 ^ O(T / √log T) and space T ^ O(1).

theorem Cslib.Complexity.CountingSimulation.SharpTIME_subset_iUnion_FTIME_two_pow_div_sqrt_log_two {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) :
SharpTIME enc T ⊆ ⋃ (C : ℕ), FTIME enc Turing.MultiTapeTM.encNat fun (n : ℕ) => 2 ^ (C * T n / (Nat.log 2 (T n)).sqrt)

SharpTIME[T] ⊆ ⋃ C, FTIME[2 ^ (C T / √⌊log₂ T⌋)], with the exact count in binary, for time-constructible T with max n 2 ≤ T n.

theorem Cslib.Complexity.CountingSimulation.NTIME_subset_iUnion_DTIME_two_pow_div_sqrt_log_two {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) :
NTIME enc T ⊆ ⋃ (C : ℕ), DTIME enc fun (n : ℕ) => 2 ^ (C * T n / (Nat.log 2 (T n)).sqrt)

NTIME[T] ⊆ ⋃ C, DTIME[2 ^ (C T / √⌊log₂ T⌋)] for time-constructible T with max n 2 ≤ T n.

theorem Cslib.Complexity.CountingSimulation.BPTIME_subset_iUnion_DTIME_two_pow_div_sqrt_log_two {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) :
BPTIME enc T ⊆ ⋃ (C : ℕ), DTIME enc fun (n : ℕ) => 2 ^ (C * T n / (Nat.log 2 (T n)).sqrt)

BPTIME[T] ⊆ ⋃ C, DTIME[2 ^ (C T / √⌊log₂ T⌋)] for time-constructible T with max n 2 ≤ T n.

theorem Cslib.Complexity.CountingSimulation.PPTIME_subset_iUnion_DTIME_two_pow_div_sqrt_log_two {α : Type} {enc : α ↪ List Bool} {T : ℕ → ℕ} (hT : TimeConstructible T) (hTn : ∀ (n : ℕ), max n 2 ≤ T n) :
PPTIME enc T ⊆ ⋃ (C : ℕ), DTIME enc fun (n : ℕ) => 2 ^ (C * T n / (Nat.log 2 (T n)).sqrt)

PPTIME[T] ⊆ ⋃ C, DTIME[2 ^ (C T / √⌊log₂ T⌋)] for time-constructible T with max n 2 ≤ T n.