Join of a list of lists #
This file proves basic properties of List.join, which concatenates a list of lists. It is defined
in Init.Data.List.Basic.
Alias of List.join_filter_not_isEmpty.
See List.length_join for the corresponding statement using List.sum.
See List.countP_join for the corresponding statement using List.sum.
See List.count_join for the corresponding statement using List.sum.
See List.countP_bind for the corresponding statement using List.sum.
See List.count_bind for the corresponding statement using List.sum.
In a join, taking the first elements up to an index which is the sum of the lengths of the
first i sublists, is the same as taking the join of the first i sublists.
See List.take_sum_join for the corresponding statement using List.sum.
In a join, dropping all the elements up to an index which is the sum of the lengths of the
first i sublists, is the same as taking the join after dropping the first i sublists.
See List.drop_sum_join for the corresponding statement using List.sum.
Taking only the first i+1 elements in a list, and then dropping the first i ones, one is
left with a list of length 1 made of the i-th element of the original list.
In a join of sublists, taking the slice between the indices A and B - 1 gives back the
original sublist of index i if A is the sum of the lengths of sublists of index < i, and
B is the sum of the lengths of sublists of index ≤ i.
See List.drop_take_succ_join_eq_getElem for the corresponding statement using List.sum.
We can rebracket x ++ (l₁ ++ x) ++ (l₂ ++ x) ++ ... ++ (lₙ ++ x) to
(x ++ l₁) ++ (x ++ l₂) ++ ... ++ (x ++ lₙ) ++ x where L = [l₁, l₂, ..., lₙ].