[GAP Forum] Generating Set for Special Linear Groups

Max Horn max at quendi.de
Tue Jun 7 12:26:38 BST 2011


Dear Piyush,

Am 07.06.2011 um 02:56 schrieb Piyush garg:

> Dear GAP Forum,
[...]
> I have two more doubts :
> ##    How to get the matrices from the output generated by GeneratorsOfGroup
> for the Special Linear Group;  like for SL(2,17) :
> s:=SL(2,17);
> gens:=GeneratorsOfGroup(s);
> [ [ [ Z(17), 0*Z(17)], [ 0*Z(17), Z(17)^15 ] ],
>  [ [ Z(17)^8, Z(17)^0], [Z(17)^8, 0*Z(17)] ] ]
> 
> this is the output we are getting, now hwo to get the matrices from it which
> can generate the whole set of SL(2,17) ??  (with the elements' values from 0
> to 16.)

Note the output already does consist of two matrices which generate SL(2,17). However, based on what you say last, it seems you want matrices in a special presentation, identifying the field F_17 with certain residues in Z/17Z. A very simple way to do this is to use Display:

gap> Display(gens[1]);
  3  .
  .  6
gap> Display(gens[2]);
 16  1
 16  .

But you seem to need a bit more:

> 
> ##    How can we store this output of matrices in a file and make use of
> them in Matlab program ??
> like storing the matrices now generated in a 3d-array and then later using
> them in Matlab.

I don't know matlab very well, so I can't say what format for matrices it expects, but I can tell you how to convert eh list of matrices GAP gives you into a list of *integer* matrices, which, viewed modulo 17, generate SL(2,17).

For a single element, the Int() function does the job:
gap> Int(Z(17));
3

To apply it to all coefficients of each generator you computed above, you could use for example this:

gap> List(gens,g->List(g,row->List(row,Int)));
[ [ [ 3, 0 ], [ 0, 6 ] ], [ [ 16, 1 ], [ 16, 0 ] ] ]

This program iterates over all elements g in  gens; for each of the g, it iterates over all rows; and for each element of a row, it calls the "Int" function. You could also write this with a loop, of course, and then adapt the output as you need.

Finally, you can store things into a file in GAP by using the PrintTo and AppendTo functions. I suggest you look them up in the GAP reference manual.


Cheers,
Max





More information about the Forum mailing list