GAP Lesson 4

Change to the directory where you store your GAP files, and then start up GAP.

gap> LogTo("GAPlesson4");
gap> At:=KnownAttributesOfObject;

Groups given by Presentations

There is more than one syntactically correct way to input a group given by a presentation. We start with various ways to input free groups.

gap> a:=FreeGroup(2);
gap> a.1*a.2;
gap> f1*f2;
gap> b:=FreeGroup(2,"b");
gap> b.1/b.2^3;
gap> b1*b2;
gap> c:=FreeGroup(2,"b");
gap> c.1*c.2;
gap> b.1*b.2;
gap> c.1*c.2=b.1*b.2;
gap> c.1 in c;
gap> c.1 in b;
gap> d:=FreeGroup("u","v");
gap> u;
gap> d.1;

Discuss all the things that went on in the last lines. How many ways can you think of to specify to the computer the first generator of the group d? What should you try to avoid? Would the computer allow you to do, for example, e:=FreeGroup("ab", "b^-1"); and why might this be a bad idea?

gap> u:=d.1;
gap> v:=d.2;
gap> u*v/(v*u);

Having named variables in a convenient fashion, we now impose relations on a free group.

gap> d;
gap> Size(d);
gap> d:=d/[u^4,v^2,v*u*v*u];
gap> At(d);
gap> Size(d);
gap> At(d);
gap> Elements(d);
gap> At(d);
gap> Center(d);
gap> isod:=IsomorphismPermGroup(d);
gap> Image(isod);
gap> Image(isod, d.1*d.2));

What is going on in the following lines?

gap> v;
gap> v in d;
gap> GeneratorsOfGroup(d);
gap> d.2;
gap> d.2 in d;

We had started to feel comfortable about GAP's conventions, and now we see more pitfalls!

gap> u:=d.1;
gap> v:=d.2;
gap> v in d;

The following computes the homomorphism to a permutation group which GAP has already done:

gap> FactorCosetOperation(d,Subgroup(d,[v]));
[ u, v ] -> [ (1,2,3,4), (2,4) ]

The following command is also possible at this stage.

gap> Action(d,RightCosets(d,Subgroup(d,[v])),OnRight);

We now study the group <r,s,t | r^2 = s^3 = t^5 = rst>. Somehow we have to enter these three relations, and it may help to shorten the generator names, as in the following.

gap> e:=FreeGroup(3,"e");
gap> e1:=e.1;
gap> e2:=e.2;
gap> e3:=e.3;
gap> e:=e/[e1^2/e2^3,e2^3/e3^5,e3^5/(e1*e2*e3)];
gap> Size(e);
gap> At(e);
gap> ce:=Centre(e);

Exercises: 1. Show that the center is in fact generated by the element rst.
2. Determine the isomorphism type of the factor group e/ce.
3. Show that e is not isomorphic to the direct product of ce and (e/ce).
In doing these exercises you will explore what commands seem to work for groups given by a presentation.

We have seen before how to get a copy of a group given by generators and relations as a permutation group, using commands such as:
gap> isoe:=IsomorphismPermGroup(e);
gap> Image(isoe,e.1*e.2);
gap> g:=Image(isoe);

We now go in the reverse direction:
gap> h:=Group((1,2,3,4,5),(1,2,3));
gap> presh:=IsomorphismFpGroup(h);
gap> Image(presh,(1,2)(3,4));
gap> At(presh);

1. Express (3,4,5) as a word in the generators (1,2,3,4,5), (1,2,3) of h.
2. (Requiring some investigation) Express (3,4,5) as a word in the generators (1,2,3,4,5), (1,3,2,4,5) of h.

Here is another example of the kind of thing GAP can do:

gap> P := PresentationViaCosetTable(h);
gap> Size(P);
gap> Print(P);
gap> TzPrint(P);
gap> TzPrintRelators(P);
gap> SimplifyPresentation(P);
gap> FpGroupPresentation( P );
gap> Size(last);

Investigate the groups
<a,b,c | a^2, b^2, c^2, (a*b)^3, (b*c)^4, (a*c)^2>
<a,b,c | a^2, b^2, c^2, (a*b)^3, (b*c)^5, (a*c)^2>
<a,b,c | a^2, b^2, c^2, (a*b)^3, (b*c)^3, (a*c)^2>

More about groups given by presentations
References: ?Creating Presentations
Also: D.L. Johnson, Presentations of Groups, Cambridge U.P.
In the next example we study the group SL(2,Z) which is known to be isomorphic to the free product with amalgamation of a cycle of order 4 with a cycle of order 6, amalgamating the subgroups of order 2. In other words it has a presentation as follows.

gap> g:=FreeGroup(2,"g");
gap> g:=g/[g.1^6,g.2^4,g.1^3*g.2^2];
gap> AbelianInvariants(g);

GAP calls an integer matrix diagonalization program which computes Smith normal form to find AbelianInvariants, the elementary divisors of the quotient by the commutator subgroup. This will work even if the commutator quotient group is infinite. We could also have done the following:

gap> h:=CommutatorFactorGroup(g);
gap> RelatorsOfFpGroup(h);
gap> AbelianInvariants(h);
gap> Size(h);

gap> DerivedSubgroup(g);

Although the commutator subgroup only has index 12, something seems to be rather difficult for the computer here. You might well wonder what the computer is trying to do anyway. We use a different approach, observing that the commutator subgroup is the smallest normal subgroup containing the commutators of the generators.

gap> sub:=Subgroup(g,[g.1*g.2*g.1^-1*g.2^-1]);
gap> NormalClosure(g,sub);

Something went wrong there as well. We try a new idea.

gap> p:=PresentationNormalClosure(g,sub);
gap> Print(p);
gap> TzPrint(p);
gap> TzPrintRelators(p);
gap> AbelianInvariants(p);

To change between a group presentation and a group we use FpGroupPresentation and PresentationFpGroup.

gap> pg:=FpGroupPresentation(p);
gap> RelatorsOfFpGroup(pg);
gap> AbelianInvariants(pg);
gap> SimplifyPresentation(p);

At this stage we know that our group has a free subgroup of rank 2 as a normal subgroup, with abelian quotient which is cyclic of order 12. We could try to do more computations. For example we know from theory that the center of this group has order 2. However, the command Center does not help us. Computing with groups given as presentations is not so easy!

Exercise: Find out what you can about the normal closure of the first generator
g.1 in g.