NecklaceCount
The colorings of a cycle with these color multiplicities, up to rotation: the size's divisors d of the greatest common divisor of the parts, each contributing totient(d) multinomials, over the size.
✓ checked against that system · ! checked, with disagreements (hover a chip)FindStat
St001605via IntegerPartition✓NecklaceCount(partition)The colorings of a cycle with these color multiplicities, up to rotation: the size's divisors d of the greatest common divisor of the parts, each contributing totient(d) multinomials, over the size.Typed signatures
| Type | Package | Applies |
|---|---|---|
(integer_partition) -> number | combinatorics | always |
Details
- Defined over
IntegerPartitionas an expression in_x, evaluated by compute-engine — the definition IS the implementation. - Takes a
IntegerPartitionand 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. - FindStat's St001605 (the cyclic group); its title says colourings of a cycle.
Definition
Epsil, as the implementation runs it.
on IntegerPartition, over _x
0 if Length(_x) < 1 else Apply(
(g: number) => Sum(Map(
Function(
Count(Filter(
Range(1, d),
Function(k * d /
LCM(k, d) ==
1, k),
)) *
(1 if Sum(_x) /
d == 0 else Product(Range(1, Sum(_x) / d))) /
Product(Map(
Function(
1 if _x[i] / d ==
0 else Product(Range(1, _x[i] / d)),
i,
),
Range(1, Length(_x)),
)) if g % d == 0 else 0,
d,
),
Range(1, g),
)),
Fold(
Function(a * b / LCM(a, b), a, b),
_x[1],
Rest(_x),
),
) / Sum(_x)Examples
Properties #
About
| Examples | 5 |
|---|---|
| Crosswalk | FindStat |