[GAP Forum] complex product of two groups
    William DeMeo 
    williamdemeo at gmail.com
       
    Wed Apr 18 13:49:08 BST 2012
    
    
  
Dear Forum,
If I have two subgroups H and K of a group G, what's the best way to
form what I think is sometimes called the "complex product"?  That is,
I want to form the set
HK = { hk : h in H, k in K }
(I don't want the group generated by H and K.)
Below is a listing of the obvious/dumb algorithm, but I suspect
there's a better way to do this in GAP.  If someone knows of one,
please let me know.
Thanks!
-William
HK:=[];
for h in H do
   for k in K do
      if h*k not in HK then
         Add(HK,h*k);
      fi;
   od;
od;
    
    
More information about the Forum
mailing list