Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top


Let $G$ be a group of size $k\cdot p^n$.

Let $S$ be the set of all subsets of size $p^n$ of $G$.

Define the map $f\colon G \times S \rightarrow S$ by $(g, s) \mapsto gs$ if $s \in S$.

I would like to create the group action table of $f$ with GAP. So in the case of $S_3$ I would get a table with twenty rows ( elements of $S$ ) and six columns ( elements of $S_3$ ) containing $gs$.

Question: How do I create a ( this ) group action table with GAP?

share|cite|improve this question
up vote 6 down vote accepted

You'll find it easier to work with GAP if you switch to right actions.

G := SymmetricGroup( 3 );;
S := Combinations( AsSet( G ), 3 );;

myLeftAction := function( act, pnt ) # useless for Orbits, Stabilizer, etc.
  return AsSet( List( pnt, x -> act*x ) );

myRightAction := function( pnt, act )
  return AsSet( List( pnt, x -> x*act ) );

table := List( S, s -> List( G, g -> myRightAction( s, g ) ) );;

PrintArray( table ); # If you have around 200 columns of screen
Browse( table ); # takes less screen space, but requires the Browse package

# Here is a way to display them in 72 columns using one-line notation
  JoinStringsWithSeparator( List( table, row ->
  JoinStringsWithSeparator( List( row, ent ->
  JoinStringsWithSeparator( List( ent, perm ->
  JoinStringsWithSeparator( ListPerm( perm, NrMovedPoints(G) ),
  "" )), "|")), " ")), "\n" ));
share|cite|improve this answer
@Steve: thanks. a recent OS upgrade introduced auto-correct. – Jack Schmidt Jan 28 '12 at 18:13
Super. Thank you very much for this clear answer. – nilo de roock Jan 28 '12 at 20:07
How did you learn GAP that well? - See:… – nilo de roock Jan 31 '12 at 13:31

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.