Documentation

CslibFrontier.Foundations.Data.List.Splits

Bounded splittings of a list #

List.Splits P K w says that w is the concatenation of at most K factors satisfying P. Restricted classes of runs of multistack pushdown automata are of this form: a sequence with at most K contexts splits into at most K factors that each use at most one stack.

Main results #

def List.Splits {β : Type u_1} (P : List β → Prop) (K : ℕ) (w : List β) :

Splits P K w holds when w is the concatenation of at most K factors satisfying P.

theorem List.Splits.mono_bound {β : Type u_1} {P : List β → Prop} {K K' : ℕ} {w : List β} (h : Splits P K w) (hK : K ≤ K') :
Splits P K' w

A splitting into at most K factors is one into at most K' factors for K ≤ K'.

theorem List.Splits.mono {β : Type u_1} {P Q : List β → Prop} {K : ℕ} {w : List β} (h : Splits P K w) (hPQ : ∀ (v : List β), P v → Q v) :
Splits Q K w

A splitting into factors satisfying P is one into factors satisfying a weaker Q.

theorem List.Splits.trans {β : Type u_1} {P : List β → Prop} {K : ℕ} {w : List β} {m : ℕ} (h : Splits (Splits P m) K w) :
Splits P (K * m) w

A splitting into factors that themselves split boundedly gives a bounded splitting.

theorem List.Splits.of_isInfix {β : Type u_1} {P : List β → Prop} {K : ℕ} {w : List β} (hP : ∀ (u v : List β), u <:+: v → P v → P u) (h : Splits P K w) {u : List β} (hu : u <:+: w) :
Splits P K u

If P is closed under taking infixes, so is having a splitting into at most K factors satisfying P.

theorem List.Splits.card_le {β : Type u_1} {P : List β → Prop} {K : ℕ} {w : List β} (hP : ∀ (u v : List β), u <:+: v → P v → P u) (h : Splits P K w) (T : Finset ℕ) (hT : ∀ t ∈ T, t < w.length) (hTP : ∀ t ∈ T, ∀ t' ∈ T, t < t' → ¬P (w.extract t (t' + 1))) :
T.card ≤ K

If w splits into at most K factors satisfying an infix-closed P, then every set T of positions of w such that no two of them lie in a common factor satisfying P has at most K elements.