12 Good semigroups We will only cover here good semigroups of N^2. A good semigroup S is a submonoid of N^2, with the following properties. (G1) It is closed under infimums (minimum componentwise). (G2) if a, b ∈ M and a_i = b_i for some i ∈ {1, 2}, then there exists c ∈ M such that c_i > a_i = b_i and c_j = min{a_j,b_j}, with j∈{1,2}∖ {i}. (G3) there exists C∈N^n such that C+N^n⊆ S. Value semigroups of algebroid branches are good semigroups, but there are good semigroups that are not of this form. Since good semigroups are closed under infimums, if C_1 and C_2 fulfill C_i+N^n⊆ S, then C_1∧ C_2+N^n⊆ S. So there is a minimum C fulfilling C+N^n⊆ S, which is called the conductor of S. The contents of this chapter are described in [DGSM16]. 12.1 Defining good semigroups 12.1-1 IsGoodSemigroup IsGoodSemigroup( S )  function Detects if S is an object of type good semigroup. 12.1-2 NumericalSemigroupDuplication NumericalSemigroupDuplication( S, E )  function S is a numerical semigroup and E is an ideal of S with E⊆ S. The output is S⋈ E= D∪ (E× E)∪{ a∧ b∣ a∈ D, b∈ E× E}, where D={(s,s)∣ s∈ S}.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> l:=Cartesian([1..11],[1..11]);; gap> Intersection(dup,l); [ [ 3, 3 ], [ 5, 5 ], [ 6, 6 ], [ 6, 7 ], [ 6, 8 ], [ 6, 9 ], [ 6, 10 ],  [ 6, 11 ], [ 7, 6 ], [ 7, 7 ], [ 8, 6 ], [ 8, 8 ], [ 9, 6 ], [ 9, 9 ],  [ 9, 10 ], [ 9, 11 ], [ 10, 6 ], [ 10, 9 ], [ 10, 10 ], [ 11, 6 ],  [ 11, 9 ], [ 11, 11 ] ] gap> [384938749837,349823749827] in dup; true  12.1-3 AmalgamationOfNumericalSemigroups AmalgamationOfNumericalSemigroups( S, E, b )  function S is a numerical semigroup, E is an ideal of a numerical semigroup T with E⊆ T, and b is an integer such that multiplication by b is a morphism from S to T, say g. The output is S⋈^g E= D∪(g^-1(E)× E)∪ {a∧ b∣ a∈ D, b∈ g^-1(E)× E}, where D={(s,b s)∣ s∈ S}.  Example  gap> s:=NumericalSemigroup(2,3);; gap> t:=NumericalSemigroup(3,4);; gap> e:=3+t;; gap> dup:=AmalgamationOfNumericalSemigroups(s,e,2);; gap> [2,3] in dup; true  12.1-4 CartesianProductOfNumericalSemigroups CartesianProductOfNumericalSemigroups( S, T )  function S and T are numerical semigroups. The output is S× T, which is a good semigroup.  Example  gap> s:=NumericalSemigroup(2,3);; gap> t:=NumericalSemigroup(3,4);; gap> IsGoodSemigroup(CartesianProductOfNumericalSemigroups(s,t)); true  12.1-5 GoodSemigroup GoodSemigroup( X, C )  function X is a list of points with nonnegative integer coordinates and C is a pair of nonnegative integer (a list with two elements). If M is the affine and infimum closure of X, decides if it is a good semigroup, and if so, outputs it.  Example  gap> G:=[[4,3],[7,13],[11,17],[14,27],[15,27],[16,20],[25,12],[25,16]]; [ [ 4, 3 ], [ 7, 13 ], [ 11, 17 ], [ 14, 27 ], [ 15, 27 ], [ 16, 20 ],  [ 25, 12 ], [ 25, 16 ] ] gap> C:=[25,27]; [ 25, 27 ] gap> GoodSemigroup(G,C);   12.2 Notable elements 12.2-1 BelongsToGoodSemigroup BelongsToGoodSemigroup( v, S )  operation \in( v, S )  operation S is a good semigroup and v is a pair of integers. The output is true if v is in S, and false otherwise. Other ways to use this operation are \in(v,S) and v in S.  Example  gap> s:=NumericalSemigroup(2,3);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);; gap> BelongsToGoodSemigroup([2,2],dup); true gap> [2,2] in dup; true gap> [3,2] in dup; false  12.2-2 Conductor Conductor( S )  function ConductorOfGoodSemigroup( S )  function S is a good semigroup. The output is its conductor.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> Conductor(dup); [ 11, 11 ] gap> ConductorOfGoodSemigroup(dup); [ 11, 11 ]  12.2-3 SmallElements SmallElements( S )  function SmallElementsOfGoodSemigroup( S )  function S is a good semigroup. The output is its set of small elements, that is, the elements smaller than its conductor with respect to the usual partial ordering.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> SmallElementsOfGoodSemigroup(dup); [ [ 0, 0 ], [ 3, 3 ], [ 5, 5 ], [ 6, 6 ], [ 6, 7 ], [ 6, 8 ], [ 6, 9 ],  [ 6, 10 ], [ 6, 11 ], [ 7, 6 ], [ 7, 7 ], [ 8, 6 ], [ 8, 8 ], [ 9, 6 ],  [ 9, 9 ], [ 9, 10 ], [ 9, 11 ], [ 10, 6 ], [ 10, 9 ], [ 10, 10 ],  [ 11, 6 ], [ 11, 9 ], [ 11, 11 ] ]  12.2-4 RepresentsSmallElementsOfGoodSemigroup RepresentsSmallElementsOfGoodSemigroup( X )  function X is a list of points in the nonnegative orthant of the plane with integer coordinates. Determines if it represents the set of small elements of a good semigroup.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> SmallElementsOfGoodSemigroup(dup); [ [ 0, 0 ], [ 3, 3 ], [ 5, 5 ], [ 6, 6 ], [ 6, 7 ], [ 6, 8 ], [ 6, 9 ], [ 6, 10 ],  [ 6, 11 ], [ 7, 6 ], [ 7, 7 ], [ 8, 6 ], [ 8, 8 ], [ 9, 6 ], [ 9, 9 ], [ 9, 10 ],  [ 9, 11 ], [ 10, 6 ], [ 10, 9 ], [ 10, 10 ], [ 11, 6 ], [ 11, 9 ], [ 11, 11 ] ] gap> RepresentsSmallElementsOfGoodSemigroup(last); true  12.2-5 GoodSemigroupBySmallElements GoodSemigroupBySmallElements( X )  function X is a list of points in the nonnegative orthant of the plane with integer coordinates. Determines if it represents the set of small elements of a good semigroup, and then outputs the good semigroup having X as set of small elements.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> SmallElementsOfGoodSemigroup(dup); [ [ 0, 0 ], [ 3, 3 ], [ 5, 5 ], [ 6, 6 ], [ 6, 7 ], [ 6, 8 ], [ 6, 9 ], [ 6, 10 ],  [ 6, 11 ], [ 7, 6 ], [ 7, 7 ], [ 8, 6 ], [ 8, 8 ], [ 9, 6 ], [ 9, 9 ], [ 9, 10 ],  [ 9, 11 ], [ 10, 6 ], [ 10, 9 ], [ 10, 10 ], [ 11, 6 ], [ 11, 9 ], [ 11, 11 ] ] gap> G:=GoodSemigroupBySmallElements(last);  gap> dup=G; true  12.2-6 MaximalElementsOfGoodSemigroup MaximalElementsOfGoodSemigroup( S )  attribute S is a good semigroup. The output is the set of elements (x,y) of S with the following property: there is no other element (x',y') in S with (x,y)le (x',y') sharing a coordinate with (x,y).  Example  gap> G:=[[4,3],[7,13],[11,17]];; gap> g:=GoodSemigroup(G,[11,17]);; gap> mx:=MaximalElementsOfGoodSemigroup(g); [ [ 0, 0 ], [ 4, 3 ], [ 7, 13 ], [ 8, 6 ] ]  12.2-7 IrreducibleMaximalElementsOfGoodSemigroup IrreducibleMaximalElementsOfGoodSemigroup( S )  attribute S is a good semigroup. The output is the set of elements nonzero maximal elements that cannot be expressed as a sum of two nonzero maximal elements of the good semigroup.  Example  gap> G:=[[4,3],[7,13],[11,17]];; gap> g:=GoodSemigroup(G,[11,17]);; gap> IrreducibleMaximalElementsOfGoodSemigroup(g); [ [ 4, 3 ], [ 7, 13 ] ]  12.2-8 GoodSemigroupByMaximalElements GoodSemigroupByMaximalElements( S, T, M, C )  function S and T are numerical semigroups, M is a list of pairs in S× T. C is the conductor, and thus a pair of nonnegative integers. The output is the set of elements of S× T that are not above an element in M, that is, if they share a coordinate with an element in M, then they must be smaller or equal to that element with respect to the usual partial ordering. The output is a good semigroup, if M is an correct set of maximal elements.  Example  gap> G:=[[4,3],[7,13],[11,17]];; gap> g:=GoodSemigroup(G,[11,17]);; gap> sm:=SmallElements(g);; gap> mx:=MaximalElementsOfGoodSemigroup(g);; gap> s:=NumericalSemigroupBySmallElements(Set(sm,x->x[1]));; gap> t:=NumericalSemigroupBySmallElements(Set(sm,x->x[2]));; gap> Conductor(g); [ 11, 15 ] gap> gg:=GoodSemigroupByMaximalElements(s,t,mx,[11,15]);  gap> gg=g; true  12.2-9 MinimalGoodGeneratingSystemOfGoodSemigroup MinimalGoodGeneratingSystemOfGoodSemigroup( S )  function S is a good semigroup. The output is its minimal good generating system (which is unique in the local case).  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> MinimalGoodGeneratingSystemOfGoodSemigroup(dup); [ [ 3, 3 ], [ 5, 5 ], [ 6, 11 ], [ 7, 7 ], [ 11, 6 ] ]  12.2-10 MinimalGenerators MinimalGenerators( S )  attribute This is just a synonym of  MinimalGoodGeneratingSystemOfGoodSemigroup (S).  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=6+s;; gap> dup:=NumericalSemigroupDuplication(s,e);  gap> MinimalGenerators(dup); [ [ 3, 3 ], [ 5, 5 ], [ 6, 11 ], [ 7, 7 ], [ 11, 6 ] ]  12.3 Symmetric semigroups 12.3-1 IsSymmetricGoodSemigroup IsSymmetricGoodSemigroup( S )  attribute IsSymmetric( S )  attribute S is a good semigroup. Determines if S is a symmetric good semigroup.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=CanonicalIdealOfNumericalSemigroup(s);; gap> e:=15+e;; gap> dup:=NumericalSemigroupDuplication(s,e);; gap> IsSymmetricGoodSemigroup(dup); true  12.3-2 ArfGoodSemigroupClosure ArfGoodSemigroupClosure( S )  function ArfClosure( S )  operation S is a good semigroup. Determines the Arf good semigroup closure of S.  Example  gap> G:=[[3,3],[4,4],[5,4],[4,6]]; [ [ 3, 3 ], [ 4, 4 ], [ 5, 4 ], [ 4, 6 ] ] gap> C:=[6,6]; [ 6, 6 ] gap> S:=GoodSemigroup(G,C);  gap> SmallElements(S); [ [ 0, 0 ], [ 3, 3 ], [ 4, 4 ], [ 4, 6 ], [ 5, 4 ], [ 6, 6 ] ] gap> A:=ArfGoodSemigroupClosure(S);  gap> SmallElements(A); [ [ 0, 0 ], [ 3, 3 ], [ 4, 4 ] ]  12.4 Good ideals A relative ideal I of a relative good semigroup M is a relative good ideal if I fulfills conditions (G1) and (G2) of the definition of good semigroup. 12.4-1 GoodIdeal GoodIdeal( X, S )  function X is a list of points with nonnegative integer coordinates and S is good semigroup. Decides if the closure of X+S under infimums is a relative good ideal of S, and if so, outputs it.  Example  gap> G:=[[4,3],[7,13],[11,17],[14,27],[15,27],[16,20],[25,12],[25,16]]; [ [ 4, 3 ], [ 7, 13 ], [ 11, 17 ], [ 14, 27 ], [ 15, 27 ], [ 16, 20 ], [ 25, 12 ], [ 25, 16 ] ] gap> C:=[25,27]; [ 25, 27 ] gap> g := GoodSemigroup(G,C);  gap> i:=GoodIdeal([[2,3]],g);   12.4-2 GoodGeneratingSystemOfGoodIdeal GoodGeneratingSystemOfGoodIdeal( I )  function I is a good ideal of a good semigroup. The output is a good generating system of I.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=10+s;; gap> d:=NumericalSemigroupDuplication(s,e);; gap> e:=GoodIdeal([[2,3],[3,2],[2,2]],d);; gap> GoodGeneratingSystemOfGoodIdeal(e); [ [ 2, 2 ], [ 2, 3 ], [ 3, 2 ] ]  12.4-3 AmbientGoodSemigroupOfGoodIdeal AmbientGoodSemigroupOfGoodIdeal( I )  function If I is a good ideal of a good semigroup M, then the output is M. The output is a good generating system of I.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=10+s;; gap> a:=AmalgamationOfNumericalSemigroups(s,e,5);; gap> e:=GoodIdeal([[2,3],[3,2],[2,2]],a);; gap> a=AmbientGoodSemigroupOfGoodIdeal(e); true  12.4-4 MinimalGoodGeneratingSystemOfGoodIdeal MinimalGoodGeneratingSystemOfGoodIdeal( I )  function I is a good ideal of a good semigroup. The output is the minimal good generating system of I.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=10+s;; gap> d:=NumericalSemigroupDuplication(s,e);; gap> e:=GoodIdeal([[2,3],[3,2],[2,2]],d);; gap> MinimalGoodGeneratingSystemOfGoodIdeal(e); [ [ 2, 3 ], [ 3, 2 ] ]  12.4-5 BelongsToGoodIdeal BelongsToGoodIdeal( v, I )  operation \in( v, I )  operation I is a good ideal of a good semigroup and v is a pair of integers. The output is true if v is in I, and false otherwise. Other ways to use this operation are \in(v,I) and v in I.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=10+s;; gap> d:=NumericalSemigroupDuplication(s,e);; gap> e:=GoodIdeal([[2,3],[3,2]],d);; gap> [1,1] in e; false gap> [2,2] in e; true  12.4-6 SmallElementsOfGoodIdeal SmallElementsOfGoodIdeal( I )  function SmallElements( I )  function I is a good ideal. The output is its set of small elements, that is, the elements smaller than its conductor and larger than its minimum element (with respect to the usual partial ordering).  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=10+s;; gap> d:=NumericalSemigroupDuplication(s,e);; gap> e:=GoodIdeal([[2,3],[3,2]],d);; gap> SmallElements(e); [ [ 2, 2 ], [ 2, 3 ], [ 3, 2 ], [ 5, 5 ], [ 5, 6 ], [ 6, 5 ], [ 7, 7 ] ]  12.4-7 CanonicalIdealOfGoodSemigroup CanonicalIdealOfGoodSemigroup( S )  function S is a good semigroup. The output is the canonical ideal of S.  Example  gap> s:=NumericalSemigroup(3,5,7);; gap> e:=10+s;; gap> d:=NumericalSemigroupDuplication(s,e);; gap> c:=CanonicalIdealOfGoodSemigroup(d);; gap> MinimalGoodGeneratingSystemOfGoodIdeal(c); [ [ 0, 0 ], [ 2, 2 ] ]