numerical_semigroup

class pocketpartition.core.numerical_semigroup.NumericalSemigroup(gaps=None, generators=None)[source]

Bases: NumericalSet

property genus
apery_set(n)[source]

Compute the Apéry set of the numerical set with respect to n.

Parameters: n (int): The modulus for the Apéry set computation.

Returns: set of int: The Apéry set with respect to n.

minimal_generating_set()[source]

Compute the minimal generating set of the numerical semigroup.

Returns: list of int: The minimal generating set of the numerical semigroup.

The algorithm used here is based on the method described by Rosales and Vasco in their works on numerical semigroups.

void()[source]

Compute the void of the numerical semigroup.

Returns: set: The void of the numerical semigroup.

gap_poset()[source]

Compute the poset of the gaps of the numerical semigroup.

Returns: set of tuple: The poset of the gaps of the numerical semigroup.

void_poset()[source]

Compute the poset of the void of the numerical semigroup.

Returns: set of tuple: The poset of the void of the numerical semigroup.

effective_weight()[source]

Calculates the effective weight of the numerical partition.

The effective weight is the sum of the number of boxes above each minimal generating set element.

Returns:

int: The effective weight of the numerical partition.

apery_weight()[source]

Calculates the Apery weight of the numerical partition.

The effective weight is the sum of the number of boxes above each Apery set element. We look use m instead of 0 for the weight about 0 residue class.

Returns:

int: The apery weight of the numerical partition.

pseudofrobenius_numbers()[source]

Calculate the pseudo-Frobenius numbers of the semigroup.

Returns:

list of int – The unique pseudo-Frobenius numbers.

type()[source]
depth()[source]
remove_minimal_generator(n)[source]

Remove a minimal generator from a numerical semigroup.

Parameters: n (int): The minimal generator to remove.

Returns: NumericalSemigroup: The resulting numerical semigroup after removal.

effective_generators()[source]
get_children()[source]
get_parent()[source]
special_gaps()[source]

Compute the gaps that can be added to S and still yield a numerical semigroup.

Returns:

list of int – The special gaps of S.

add_specialgap(p)[source]

Add a special gap to the numerical semigroup.

get_frobchildren()[source]