From cff1a6af1fef3295d9d4643249072d2ca8aad4d9 Mon Sep 17 00:00:00 2001 From: Tom Conti-Leslie Date: Wed, 19 May 2021 15:53:51 +0200 Subject: [PATCH 1/6] Add IsomorphismSemigroup from Clifford smgp to SSS --- gap/attributes/isomorph.gi | 57 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/gap/attributes/isomorph.gi b/gap/attributes/isomorph.gi index fb5955d11..5cb289f99 100644 --- a/gap/attributes/isomorph.gi +++ b/gap/attributes/isomorph.gi @@ -327,3 +327,60 @@ function(S) UseIsomorphismRelation(H, G); return H; end); + +InstallMethod(IsomorphismSemigroup, +"for IsStrongSemilatticeOfSemigroups and a Clifford semigroup", +[IsStrongSemilatticeOfSemigroups, IsSemigroup and IsFinite], +function(filt, S) + local A, idemps, n, D, N, L, classes, idemp, DC, H, map, SSS, i, j; + # decomposes a finite Clifford semigroup S into a strong semilattice of + # groups and returns an SSS object. + if not (IsCliffordSemigroup(S) and IsFinite(S)) then + TryNextMethod(); + fi; + # There should be one idempotent per D-class, i.e. per semilattice element + # since the semilattice decomposition is by J-classes, and J = D here + A := Semigroup(Idempotents(S)); + idemps := Elements(A); + n := Size(idemps); + + # create semilattice + D := DigraphReflexiveTransitiveReduction(Digraph(NaturalPartialOrder(A))); + # currently wrong way round + D := DigraphReverse(D); + N := OutNeighbours(D); + + # populate list of semigroups in semilattice. + # keep a list of D-classes at the same time, to figure out where elements are + L := []; + classes := []; + for i in [1 .. n] do + idemp := idemps[i]; # the idempotent of this D-class + DC := DClass(S, idemp); + Add(L, Semigroup(DC)); + Add(classes, DC); + od; + + # populate list of homomorphisms + H := []; + for i in [1 .. n] do + idemp := idemps[i]; + Add(H, []); + for j in N[i] do + map := function(elm) + return idemp * elm; + end; + Add(H[i], MappingByFunction(L[j], L[i], map)); + od; + od; + + SSS := StrongSemilatticeOfSemigroups(D, L, H); + + return MagmaIsomorphismByFunctionsNC(S, + SSS, + x -> SSSE(SSS, + Position(classes, + DClass(S, x)), + x), + x -> x![3]); +end); From 79d230fe7c3dff45b30dfca341b77bd0f4974fce Mon Sep 17 00:00:00 2001 From: Tom Conti-Leslie Date: Wed, 19 May 2021 17:14:35 +0200 Subject: [PATCH 2/6] Add IsOrthoGroup property --- gap/attributes/properties.gd | 3 +++ gap/attributes/properties.gi | 6 ++++++ 2 files changed, 9 insertions(+) diff --git a/gap/attributes/properties.gd b/gap/attributes/properties.gd index a1c763f2b..1d46f37bf 100644 --- a/gap/attributes/properties.gd +++ b/gap/attributes/properties.gd @@ -102,3 +102,6 @@ DeclareProperty("IsSurjectiveSemigroup", IsSemigroup); InstallTrueMethod(IsSurjectiveSemigroup, IsRegularSemigroup); InstallTrueMethod(IsSurjectiveSemigroup, IsMonoidAsSemigroup); InstallTrueMethod(IsSurjectiveSemigroup, IsIdempotentGenerated); + +DeclareProperty("IsOrthogroup", IsSemigroup); +DeclareSynonym("IsOrthoGroup", IsOrthogroup); diff --git a/gap/attributes/properties.gi b/gap/attributes/properties.gi index ab588cfcf..9bea4e492 100644 --- a/gap/attributes/properties.gi +++ b/gap/attributes/properties.gi @@ -1784,3 +1784,9 @@ x -> UnderlyingSemigroupOfSemigroupWithAdjoinedZero(x) <> fail); InstallMethod(IsSurjectiveSemigroup, "for a semigroup", [IsSemigroup], S -> IsEmpty(IndecomposableElements(S))); + +InstallMethod(IsOrthogroup, "for a semigroup", +[IsSemigroup], +function(S) + return IsCompletelyRegularSemigroup(S) and IsOrthodoxSemigroup(S); +end); From f8a43663587b552fdd1f1d1f47867f208a7ba61e Mon Sep 17 00:00:00 2001 From: Tom Conti-Leslie Date: Wed, 26 May 2021 18:45:16 +0200 Subject: [PATCH 3/6] SSS Decomp bugfix --- gap/attributes/isomorph.gi | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/gap/attributes/isomorph.gi b/gap/attributes/isomorph.gi index 5cb289f99..15e74aa75 100644 --- a/gap/attributes/isomorph.gi +++ b/gap/attributes/isomorph.gi @@ -332,7 +332,7 @@ InstallMethod(IsomorphismSemigroup, "for IsStrongSemilatticeOfSemigroups and a Clifford semigroup", [IsStrongSemilatticeOfSemigroups, IsSemigroup and IsFinite], function(filt, S) - local A, idemps, n, D, N, L, classes, idemp, DC, H, map, SSS, i, j; + local A, idemps, n, D, N, L, classes, idemp, DC, H, SSS, i, j, addfunc; # decomposes a finite Clifford semigroup S into a strong semilattice of # groups and returns an SSS object. if not (IsCliffordSemigroup(S) and IsFinite(S)) then @@ -366,12 +366,13 @@ function(filt, S) for i in [1 .. n] do idemp := idemps[i]; Add(H, []); + addfunc := function(x, a, b, c) # horrible namespace hack (credits JDM) + Add(x, [a, b, z -> c * z]); + end; for j in N[i] do - map := function(elm) - return idemp * elm; - end; - Add(H[i], MappingByFunction(L[j], L[i], map)); + addfunc(H[i], L[j], L[i], idemps[i]); od; + Apply(H[i], x -> MappingByFunction(x[1], x[2], x[3])); od; SSS := StrongSemilatticeOfSemigroups(D, L, H); From 2c1d259e7202f525db8a434db704699db85a7c1c Mon Sep 17 00:00:00 2001 From: Tom Conti-Leslie Date: Wed, 26 May 2021 18:56:26 +0200 Subject: [PATCH 4/6] SSS Decomp: add test --- tst/standard/isomorph.tst | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/tst/standard/isomorph.tst b/tst/standard/isomorph.tst index 1742c1c6f..3043b8788 100644 --- a/tst/standard/isomorph.tst +++ b/tst/standard/isomorph.tst @@ -385,9 +385,32 @@ gap> G := AutomorphismGroup(S); gap> StructureDescription(G); "S3" +# IsomorphismSemigroup for Clifford semigroups to strong semilattices +gap> S := DualSymmetricInverseMonoid(5);; +gap> T := IdempotentGeneratedSubsemigroup(S);; +gap> map := IsomorphismSemigroup(IsStrongSemilatticeOfSemigroups, T);; +gap> S := Range(map);; +gap> S; + +gap> IsStrongSemilatticeOfSemigroups(S); +true +gap> failed := [];; +gap> for x in T do +> if x <> (x ^ map)![3] then +> Add(failed, x);; +> fi; +> od; +gap> failed; +[ ] +gap> IsomorphismSemigroups(S, T) <> fail; +true +gap> SemilatticeOfStrongSemilatticeOfSemigroups(S); + + # SEMIGROUPS_UnbindVariables gap> Unbind(S); gap> Unbind(T); +gap> Unbind(x); # gap> SEMIGROUPS.StopTest(); From 21e5eaea591639a80cd170540aa18c495ffa3743 Mon Sep 17 00:00:00 2001 From: Tom Conti-Leslie Date: Wed, 26 May 2021 19:26:12 +0200 Subject: [PATCH 5/6] SSS Decomp: add 2 more tests --- tst/standard/isomorph.tst | 42 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) diff --git a/tst/standard/isomorph.tst b/tst/standard/isomorph.tst index 3043b8788..7cb33f442 100644 --- a/tst/standard/isomorph.tst +++ b/tst/standard/isomorph.tst @@ -385,7 +385,7 @@ gap> G := AutomorphismGroup(S); gap> StructureDescription(G); "S3" -# IsomorphismSemigroup for Clifford semigroups to strong semilattices +# IsomorphismSemigroup for Clifford semigroups to strong semilattices (1/3) gap> S := DualSymmetricInverseMonoid(5);; gap> T := IdempotentGeneratedSubsemigroup(S);; gap> map := IsomorphismSemigroup(IsStrongSemilatticeOfSemigroups, T);; @@ -406,8 +406,48 @@ gap> IsomorphismSemigroups(S, T) <> fail; true gap> SemilatticeOfStrongSemilatticeOfSemigroups(S); +gap> BruteForceIsoCheck(map); +true + +# IsomorphismSemigroup for Clifford semigroups to strong semilattices (2/3) +gap> T := Semigroup(Transformation([1, 2, 4, 5, 6, 3, 7, 8]), +> Transformation([3, 3, 4, 5, 6, 2, 7, 8]), +> Transformation([1, 2, 5, 3, 6, 8, 4, 4]));; +gap> Size(T); +864 +gap> NrIdempotents(T); +4 +gap> S := IsomorphismSemigroup(IsStrongSemilatticeOfSemigroups, T);; +gap> map := IsomorphismSemigroup(IsStrongSemilatticeOfSemigroups, T);; +gap> S := Range(map); + +gap> Size(S); +864 +gap> # Property of CLifford semigroups: +gap> List(SemigroupsOfStrongSemilatticeOfSemigroups(S), IsGroupAsSemigroup); +[ true, true, true, true ] +gap> BruteForceIsoCheck(map); +true + +# IsomorphismSemigroup for Clifford semigroups to strong semilattices (3/3) +gap> T := Semigroup(List([2 .. 10], +> x -> Transformation(ListWithIdenticalEntries(x, 1)))); + +gap> IsCliffordSemigroup(T); +true +gap> map := IsomorphismSemigroup(IsStrongSemilatticeOfSemigroups, T);; +gap> S := Range(map); + +gap> BruteForceIsoCheck(map); +true +gap> Size(S) = Size(T); +true +gap> SemilatticeOfStrongSemilatticeOfSemigroups(S) = +> DigraphReflexiveTransitiveClosure(ChainDigraph(9)); +true # SEMIGROUPS_UnbindVariables +gap> Unbind(map); gap> Unbind(S); gap> Unbind(T); gap> Unbind(x); From 825aee3ef4752c85fdd5df8327d7fbc99c3688a0 Mon Sep 17 00:00:00 2001 From: Tom Conti-Leslie Date: Wed, 26 May 2021 19:28:32 +0200 Subject: [PATCH 6/6] SSS Decomp: address Wilf's comments --- gap/attributes/isomorph.gi | 2 +- gap/attributes/properties.gd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gap/attributes/isomorph.gi b/gap/attributes/isomorph.gi index 15e74aa75..096155972 100644 --- a/gap/attributes/isomorph.gi +++ b/gap/attributes/isomorph.gi @@ -345,7 +345,7 @@ function(filt, S) n := Size(idemps); # create semilattice - D := DigraphReflexiveTransitiveReduction(Digraph(NaturalPartialOrder(A))); + D := Digraph(NaturalPartialOrder(A)); # currently wrong way round D := DigraphReverse(D); N := OutNeighbours(D); diff --git a/gap/attributes/properties.gd b/gap/attributes/properties.gd index 1d46f37bf..95228208c 100644 --- a/gap/attributes/properties.gd +++ b/gap/attributes/properties.gd @@ -104,4 +104,4 @@ InstallTrueMethod(IsSurjectiveSemigroup, IsMonoidAsSemigroup); InstallTrueMethod(IsSurjectiveSemigroup, IsIdempotentGenerated); DeclareProperty("IsOrthogroup", IsSemigroup); -DeclareSynonym("IsOrthoGroup", IsOrthogroup); +DeclareSynonymAttr("IsOrthoGroup", IsOrthogroup);