numerical_set

class pocketpartition.core.numerical_set.NumericalSet(gaps)[source]

Bases: object

property gaps
property frobenius_number
atom_monoid_gaps()[source]

Compute the gaps of the atom monoid.

Returns: set of int: The gaps of the atom monoid.

partition()[source]

Creates a partition based on a specific walk profile using the gaps attribute.

The walk is defined as follows: - Start at 0. - If the current number is in gaps, move up (create a new row with the same length as the current row). - If the current number is not in gaps, move right (add one box to the current row). - Continue this process until reaching the maximum number in gaps. - Collect the lengths of each row at the end of the walk.

The resulting partition is returned as a list of integers in non-increasing order.

Returns: list: A partition [a1, a2, …, an] in non-increasing order, representing the profile of the walk.

small_elements()[source]

Compute the small elements of the numerical set.

Returns: set of int: The small elements of the numerical set.

multiplicity()[source]

Compute the multiplicity of the numerical semigroup.

Returns: int: The multiplicity of the numerical semigroup.