Skip to content

Commit

Permalink
small edits
Browse files Browse the repository at this point in the history
  • Loading branch information
Tianrun-Y committed Aug 21, 2024
1 parent dfc6a66 commit ae4f45d
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 23 deletions.
1 change: 1 addition & 0 deletions gap/attributes/attr.gd
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ DeclareAttribute("NambooripadPartialOrder", IsSemigroup);
DeclareOperation("KernelContainment",
[IsTransformation, IsTransformation, IsPosInt]);
DeclareAttribute("RegularLeqTransformationSemigroupNC", IsTransformationSemigroup);
DeclareAttribute("MitschLeqSemigroupNC", IsSemigroup);
DeclareAttribute("MitschLeqSemigroup", IsSemigroup);
DeclareAttribute("MitschOrderOfTransformationSemigroup",
IsFinite and IsTransformationSemigroup);
Expand Down
49 changes: 26 additions & 23 deletions gap/attributes/attr.gi
Original file line number Diff line number Diff line change
Expand Up @@ -1045,10 +1045,10 @@ function(S)

return
function(x, y)
local R;
R := RClass(S, x);
return IsGreensLessThanOrEqual(R, RClass(S, y))
and ForAny(Idempotents(R), e -> e * y = x);
local E;
E := Idempotents(S);
return ForAny(E, e -> e * y = x)
and ForAny(E, f -> y * f = x);
end;
end);

Expand Down Expand Up @@ -1089,18 +1089,11 @@ function(S)
end;
end);

InstallMethod(MitschLeqSemigroup,
InstallMethod(MitschLeqSemigroupNC,
"for a semigroup",
[IsSemigroup],
function(S)
if IsInverseSemigroup(S) then
return NaturalLeqInverseSemigroup(S);
elif IsRegularSemigroup(S) and IsTransformationSemigroup(S) then
return RegularLeqTransformationSemigroupNC(S);
elif IsRegularSemigroup(S) then
return NambooripadLeqRegularSemigroup(S);
else
return
return
function(x, y)
if x = y then
return true;
Expand All @@ -1109,6 +1102,20 @@ function(S)
ForAny(Elements(S), t -> t * y = x and t * x = x);
fi;
end;
end);

InstallMethod(MitschLeqSemigroup,
"for a semigroup",
[IsSemigroup],
function(S)
if IsInverseSemigroup(S) then
return NaturalLeqInverseSemigroup(S);
elif IsRegularSemigroup(S) and IsTransformationSemigroup(S) then
return RegularLeqTransformationSemigroupNC(S);
elif IsRegularSemigroup(S) then
return NambooripadLeqRegularSemigroup(S);
else
return MitschLeqSemigroupNC(S);
fi;
end);

Expand All @@ -1120,19 +1127,15 @@ function(S)
elts := ShallowCopy(AsListCanonical(S));
p := Sortex(elts, {x, y} -> IsGreensDGreaterThanFunc(S)(y, x)) ^ -1;
func1 := RegularLeqTransformationSemigroupNC(S);
func2 := MitschLeqSemigroup(S);
func2 := MitschLeqSemigroupNC(S);
out := List([1 .. Size(S)], x -> []);
regular := BlistList([1 .. Size(S)], []);
if IsRegularSemigroup(S) then
FlipBlist(regular);
else
for D in RegularDClasses(S) do
for a in D do
i := PositionCanonical(S, a) ^ (p ^ -1);
regular[i] := true;
od;
for D in RegularDClasses(S) do
for a in D do
i := PositionCanonical(S, a) ^ (p ^ -1);
regular[i] := true;
od;
fi;
od;
for j in [Size(S), Size(S) - 1 .. 1] do
if regular[j] then
for i in [j - 1, j - 2 .. 1] do
Expand Down

0 comments on commit ae4f45d

Please sign in to comment.