-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mitsch Order #1024
base: main
Are you sure you want to change the base?
Mitsch Order #1024
Conversation
gap/attributes/attr.gi
Outdated
@@ -1052,6 +1052,188 @@ function(S) | |||
end; | |||
end); | |||
|
|||
InstallMethod(KernelContainment, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please:
- move this to
gap/elements/transf.g*
- add tests
- add doc
- rename to
IsRefinementKernelOfTransformation
- improve the error message using the format: "where, what went wrong, what was expected, and what was found"
deg := DegreeOfTransformationSemigroup(S); | ||
return | ||
function(x, y) | ||
# Only returns the correct answer if y is a regular element |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add check that y
is regular.
Also what happens if x
or y
not in S
?
gap/attributes/attr.gi
Outdated
return out; | ||
end); | ||
|
||
InstallMethod(MitschOrderOfTransformationSemigroup, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this, unless it is actually much faster.
Co-authored-by: James Mitchell <[email protected]>
Co-authored-by: James Mitchell <[email protected]>
Co-authored-by: James Mitchell <[email protected]>
Co-authored-by: James Mitchell <[email protected]>
exists := false; | ||
for i in [1 .. Size(class)] do | ||
if class[i] ^ a = class[i] ^ b then | ||
exists := true; | ||
break; | ||
fi; | ||
od; | ||
if not exists then | ||
return false; | ||
fi; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not saying this is better, but I think you could also write it like this (assuming class
is an iterable object):
exists := false; | |
for i in [1 .. Size(class)] do | |
if class[i] ^ a = class[i] ^ b then | |
exists := true; | |
break; | |
fi; | |
od; | |
if not exists then | |
return false; | |
fi; | |
if ForAll(class, x -> x ^ a <> x ^ b) then | |
return false; | |
fi; |
return ForAny(Elements(S), s -> x = x * s and x = y * s) and | ||
ForAny(Elements(S), t -> t * y = x and t * x = x); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aren't semigroups iterable? Because if they are, can't you just write
return ForAny(Elements(S), s -> x = x * s and x = y * s) and | |
ForAny(Elements(S), t -> t * y = x and t * x = x); | |
return ForAny(S, s -> x = x * s and x = y * s) and | |
ForAny(S, t -> t * y = x and t * x = x); |
Add methods for finding the Mitsch order of a semigroup