Nestings
SetPartition: pairs of arcs a < b < c < d with a~d and b~c. Permutation: pairs i, j with j < i < p(i) < p(j) or p(j) < p(i) <= i < j.
✓ checked against that system · ! checked, with disagreements (hover a chip)FindStat
St000041via PerfectMatching✓St000223via Permutation✓St000233via SetPartition✓Nestings(p)SetPartition: pairs of arcs a < b < c < d with a~d and b~c. Permutation: pairs i, j with j < i < p(i) < p(j) or p(j) < p(i) <= i < j.Typed signatures
| Type | Package | Applies |
|---|---|---|
(permutation | set_partition) -> number | combinatorics | always |
Details
- Defined over
SetPartitionas an expression in_x, evaluated by compute-engine — the definition IS the implementation. - Takes a
SetPartitionand nothing else — it reads values against their positions, or walks the orbits, so it needs the bijection. Applying it to a bare list is a type error, not a wrong answer. - The complementary case to Crossings: one arc's span strictly contains the other's. Equidistributed with Crossings over set partitions of [n] (Kasraoui–Zeng), and the noncrossing and nonnesting partitions are each counted by the Catalan numbers.
- Defined over
Permutationas an expression in_x, evaluated by compute-engine — the definition IS the implementation. - Takes a
Permutationand nothing else — it reads values against their positions, or walks the orbits, so it needs the bijection. Applying it to a bare list is a type error, not a wrong answer. - Nestings of the arcs of the permutation diagram.
Definition
Epsil, as the implementation runs it.
on Permutation, over _x
0 if Length(_x) < 1 else Sum(Map(Function(
Count(Filter(
Range(1, Length(_x)),
Function(
j < i && i <
_x[i] &&
_x[i] < _x[j] || _x[j] <
_x[i] && _x[i] <=
i && i <
j,
j,
),
)),
i,
), Range(1, Length(_x))))on SetPartition, over _x
0 if Length(Flatten(Map(Function(Most(b), b), _x))) < 2 else Sum(Map(
Function(Count(Filter(
Range(
i + 1,
Length(Flatten(Map(Function(Most(b), b), _x))),
1,
),
Function([Max(
Flatten(Map(Function(Most(b), b), _x))[i],
Flatten(Map(Function(Most(b), b), _x))[j],
) <
(Flatten(Map(Function(Rest(b), b), _x))[i] if Flatten(Map(Function(Most(b), b), _x))[i] <
Flatten(Map(Function(Most(b), b), _x))[j] else Flatten(Map(Function(Rest(b), b), _x))[j]) &&
(Flatten(Map(Function(Rest(b), b), _x))[i] if Flatten(Map(Function(Most(b), b), _x))[i] <
Flatten(Map(Function(Most(b), b), _x))[j] else Flatten(Map(Function(Rest(b), b), _x))[j]) <
(Flatten(Map(Function(Rest(b), b), _x))[j] if Flatten(Map(Function(Most(b), b), _x))[i] <
Flatten(Map(Function(Most(b), b), _x))[j] else Flatten(Map(Function(Rest(b), b), _x))[i]), Max(
Flatten(Map(Function(Most(b), b), _x))[i],
Flatten(Map(Function(Most(b), b), _x))[j],
) <
(Flatten(Map(Function(Rest(b), b), _x))[i] if Flatten(Map(Function(Most(b), b), _x))[i] <
Flatten(Map(Function(Most(b), b), _x))[j] else Flatten(Map(Function(Rest(b), b), _x))[j]) &&
(Flatten(Map(Function(Rest(b), b), _x))[j] if Flatten(Map(Function(Most(b), b), _x))[i] <
Flatten(Map(Function(Most(b), b), _x))[j] else Flatten(Map(Function(Rest(b), b), _x))[i]) <
(Flatten(Map(Function(Rest(b), b), _x))[i] if Flatten(Map(Function(Most(b), b), _x))[i] <
Flatten(Map(Function(Most(b), b), _x))[j] else Flatten(Map(Function(Rest(b), b), _x))[j])][2], j),
)), i),
Range(
1,
Length(Flatten(Map(Function(Most(b), b), _x))),
1,
),
))Examples
Basic #
Properties #
About
| Examples | 10 |
|---|---|
| Checked against | SageMath 5 agree |
| Crosswalk | FindStat ×3 |