Skip to content

DescentSet

The positions where the word falls.

DescentSet(Permutation)

Domain: Combinatorial maps

Details
  • Takes a `Permutation` and returns a `Finset` — a typed map, so a wrong carrier is a type error rather than a wrong answer.
  • The statistics Descents and MajorIndex are the size and the sum of this set — which is the reduction worth having: a statistic of a map's output rather than a fresh walk.

Examples