DependsOn for functions on lists #
mathlib's DependsOn f s says a function on Π i, α i is determined by the coordinates in
s. A function g : List α → γ is not on a Π-type, but on each fibre Fin n → α the
composite g ∘ List.ofFn is, so "g depends only on the positions in K" is
∀ n, DependsOn (g ∘ List.ofFn) (Fin.val ⁻¹' K). List.forall_dependsOn_ofFn_iff unpacks that
into the word-pair form consumers use: equal-length lists whose getElem? functions are
Set.EqOn on K have equal images. [UPSTREAM] candidate for
Mathlib/Logic/Function/DependsOn.lean.
Main results #
List.forall_dependsOn_ofFn_iff: the word-pair form of fibrewiseDependsOn.Set.EqOn.take_eq,Set.EqOn.drop_eq,Set.EqOn.getElem?_eq: agreement ofgetElem?onSet.Iic jorSet.Ici jtransports prefixes and suffixes, in dot-notation form.
g ∘ List.ofFn depends on the positions in K on every fibre exactly when equal-length
lists agreeing on K have equal images under g.
The pointwise application of window agreement, stated in getElem? form so it rewrites
cleanly.
Agreement on positions up to j transports prefixes of length at most j + 1.
Agreement on positions from j transports suffixes from j on.