ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Thu, 13 Sep 2012 22:53:44 +0200double cosets in Sagehttps://ask.sagemath.org/question/9303/double-cosets-in-sage/Suppose G is a group and H and I are two subgroup of it how can I compute the double cosets I\G/H?Fri, 07 Sep 2012 18:57:16 +0200https://ask.sagemath.org/question/9303/double-cosets-in-sage/Answer by benjaminfjones for <p>Suppose G is a group and H and I are two subgroup of it how can I compute the double cosets I\G/H?</p>
https://ask.sagemath.org/question/9303/double-cosets-in-sage/?answer=14027#post-id-14027The `DoubleCoset` function in GAP has not been wrapped yet, so this is currently "not implemented". But, you can always ask GAP to compute (double) cosets from within Sage:
sage: gap.eval('g:=Group((1,2,3,4),(1,2));;')
sage: gap.eval('u:=Subgroup(g,[(1,2,3),(1,2)]);;')
sage: gap.eval('v:=Subgroup(g,[(3,4)]);;')
sage: gap.eval('c:=DoubleCoset(u,(2,4),v);')
'DoubleCoset(Group( [ (1,2,3), (1,2) ] ),(2,4),Group( [ (3,4) ] ))'
sage: gap.eval('List(c);')
'[ (2,3,4), (1,4,2), (1,3)(2,4), (2,4), (1,4,2,3), (1,3,4,2) ]'Wed, 12 Sep 2012 18:23:55 +0200https://ask.sagemath.org/question/9303/double-cosets-in-sage/?answer=14027#post-id-14027Comment by benjaminfjones for <p>The <code>DoubleCoset</code> function in GAP has not been wrapped yet, so this is currently "not implemented". But, you can always ask GAP to compute (double) cosets from within Sage:</p>
<pre><code>sage: gap.eval('g:=Group((1,2,3,4),(1,2));;')
sage: gap.eval('u:=Subgroup(g,[(1,2,3),(1,2)]);;')
sage: gap.eval('v:=Subgroup(g,[(3,4)]);;')
sage: gap.eval('c:=DoubleCoset(u,(2,4),v);')
'DoubleCoset(Group( [ (1,2,3), (1,2) ] ),(2,4),Group( [ (3,4) ] ))'
sage: gap.eval('List(c);')
'[ (2,3,4), (1,4,2), (1,3)(2,4), (2,4), (1,4,2,3), (1,3,4,2) ]'
</code></pre>
https://ask.sagemath.org/question/9303/double-cosets-in-sage/?comment=19060#post-id-19060I think this could be easily wrapped, the return type is a list of tuples. It's just that no one has done it yet.Thu, 13 Sep 2012 22:53:44 +0200https://ask.sagemath.org/question/9303/double-cosets-in-sage/?comment=19060#post-id-19060Comment by kcrisman for <p>The <code>DoubleCoset</code> function in GAP has not been wrapped yet, so this is currently "not implemented". But, you can always ask GAP to compute (double) cosets from within Sage:</p>
<pre><code>sage: gap.eval('g:=Group((1,2,3,4),(1,2));;')
sage: gap.eval('u:=Subgroup(g,[(1,2,3),(1,2)]);;')
sage: gap.eval('v:=Subgroup(g,[(3,4)]);;')
sage: gap.eval('c:=DoubleCoset(u,(2,4),v);')
'DoubleCoset(Group( [ (1,2,3), (1,2) ] ),(2,4),Group( [ (3,4) ] ))'
sage: gap.eval('List(c);')
'[ (2,3,4), (1,4,2), (1,3)(2,4), (2,4), (1,4,2,3), (1,3,4,2) ]'
</code></pre>
https://ask.sagemath.org/question/9303/double-cosets-in-sage/?comment=19061#post-id-19061I guess these wouldn't be translatable to Sage... yet.Thu, 13 Sep 2012 22:49:45 +0200https://ask.sagemath.org/question/9303/double-cosets-in-sage/?comment=19061#post-id-19061