Adjacent factors of a list #
List.extract l a b is the factor of l from position a (included) to b (excluded). Two
adjacent factors concatenate to the factor spanning both (List.extract_append_extract), a factor
is an infix (List.extract_isInfix), and a factor of a factor is a factor
(List.extract_extract).
Proofs about factors of words, such as matched pushes and pops of a run or the factors of a
concatenation of languages, split a factor at an intermediate position with it.
Main results #
List.extract_append_extract:l.extract a b ++ l.extract b c = l.extract a cfora ≤ b ≤ c.List.extract_extract:(l.extract a b).extract c d = l.extract (a + c) (a + d)fora + d ≤ b.List.extract_append_left,List.extract_append_right: factors of an append that lie in one of its parts.List.getElem?_extract,List.mem_extract_iff_getElem?: the entries of a factor by position.List.take_eq_take_append_extract,List.drop_eq_extract_append_drop: a prefix or suffix split at an intermediate position.