-
Notifications
You must be signed in to change notification settings - Fork 126
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
Group cosets: implement custom in
, improve iterator
#4289
Comments
For a coset Concerning the iterator for double cosets, one solution would be to use the functionality of GAP's |
Add the type of the *subgroup* as a parameter, then we can prescribe a better `Base.IteratorSize(::Type{<:GroupCoset})`, as proposed in oscar-system#4289. Note that in principle, we could omit the type of the *big group* from the parameters since it is the `parent_type` of the element type parameter. (The design of the `GroupCoset` type dates back to the times when we thought that a group has the same type as its subgroups. At the time when this idea was given up, I should have changed `GroupCoset` to take the *subgroup* type as a parameter.)
Where are we now: With #4302, we get
Concerning double cosets, we would need more GAP functionality on the Oscar side in order to replace the delegations to GAP by something better. For both iteration and membership tests for double cosets, my idea would be to split the double coset into right cosets and to delegate to these object, as is done in GAP. For that, GAP's |
Right now
in
for group cosets resorts to iterating over the coset, which is very inefficient.We should provide a custom method for this. I would not dispatch to GAP's, but instead implement this "directly": i.e. to test
g in Hx
, test ifg/x in H
and similar forg in xH
(so that we avoid creatingGapObj
for those).Speaking of iterators, the
iterate
implementation forGroupCoset
currently directly wraps a GAP coset iterator. But (a) this requires creating aGapObj
(with extra overhead for left cosets). And furthermore on the GAP side, the iterator is a wrapper for an enumerator.Instead, the Julia iterator for a coset
C
could be based on the group iterator forC.H
.Lastly, contrast
versus
I suggest we use something like this:
And then I assume similar for
GroupDoubleCoset
.The text was updated successfully, but these errors were encountered: