Group that allows us to define a group given its generators.Order that returns the number of elements in a group, which is also known as the group order.Elements that returns a list of all elements in the group.MultiplicationTable that generates the multiplication table of the group.IsAbelian that returns true if the group is abelian false otherwise.One that returns the identity of the group.Inverse that returns the inverse of an element in a particular group.gap> G := Group((1, 2, 3), (1, 2));
Group([ (1,2,3), (1,2) ])
G is the whole symmetric group gap> G = SymmetricGroup(3);
true
Now, let's recover some known properties of the group.
Recall that the order of G.
gap> Order(G);
6
G:gap> Elements(G);
[ (), (2,3), (1,2), (1,2,3), (1,3,2), (1,3) ]
gap> MultiplicationTable(G);
[ [ 1, 2, 3, 4, 5, 6 ], [ 2, 1, 4, 3, 6, 5 ], [ 3, 5, 1, 6, 2, 4 ],
[ 4, 6, 2, 5, 1, 3 ], [ 5, 3, 6, 1, 4, 2 ], [ 6, 4, 5, 2, 3, 1 ] ]
ShowMultiplicationTable to get the multiplication table in a readable format.
gap> ShowMultiplicationTable(G);
* | () (2,3) (1,2) (1,2,3) (1,3,2) (1,3)
--------+------------------------------------------------
() | () (2,3) (1,2) (1,2,3) (1,3,2) (1,3)
(2,3) | (2,3) () (1,2,3) (1,2) (1,3) (1,3,2)
(1,2) | (1,2) (1,3,2) () (1,3) (2,3) (1,2,3)
(1,2,3) | (1,2,3) (1,3) (2,3) (1,3,2) () (1,2)
(1,3,2) | (1,3,2) (1,2) (1,3) () (1,2,3) (2,3)
(1,3) | (1,3) (1,2,3) (1,3,2) (2,3) (1,2) ()
gap> IsAbelian(G);
false
gap> One(G);
()
gap> g1 := Elements(G)[4];
(1,2,3)
gap> Inverse(g1);
(1,3,2)
Permutation groups naturally acts on sets.
[ In Lecture 3, we will talk more about group actions.]
A moved point is any element that is not fixed by all the permutations in the group. In other words, a number remains unchanged by every permutation in the group, it is not considered a moved point.
The function MovedPoint gives the list of moved points.
gap> g := Group((1,2,3,4), (1,2));
Group([ (1,2,3,4), (1,2) ])
gap> MovedPoints(g);
[ 1, 2, 3, 4 ]
NrMovedPoints(g) for the total count of moved points.LargestMovedPoint(g) for the highest-numbered moved point.SmallestMovedPoint(g) for the lowest-numbered moved point.gap> g:=Group((1,2,3,4), (1,2));
Group([ (1,2,3,4), (1,2) ])
gap> MovedPoints(g);
[ 1, 2, 3, 4 ]
gap> NrMovedPoints(g);
4
gap> LargestMovedPoint(g);
4
gap> SmallestMovedPoint(g);
1
Cayley’s Theorem. Every finite group is isomorphic to a subgroup of a symmetric group.
CyclicGroup.gap> CyclicGroup(2);
<pc group of size 2 with 1 generator>
gap> C3 := CyclicGroup(3);
<pc group of size 3 with 1 generator>
gap> iso := IsomorphismPermGroup(C3);
[ f1 ] -> [ (1,2,3) ]
gap> Image(iso);
Group([ (1,2,3) ])
IsomorphismPermGroup gives us an isomorphism from Image gives the image of such isomorphism, i.e. the cyclic group (as permutation group) generated by by the permutation CyclicGroup to tell GAP which presentation we want.gap> CyclicGroup(IsPermGroup, 2);
Group([ (1,2) ])
gap> CyclicGroup(IsMatrixGroup, 2);
Group([ [ [ 0, 1 ], [ 1, 0 ] ] ])

DihedralGroup.
IsPermGroup.gap> D6 := DihedralGroup(6);
<pc group of size 6 with 2 generators>
gap> Order(D6);
6
gap> IsAbelian(D6);
false
IsPermGroup to construct the gap> D6 := DihedralGroup(IsPermGroup, 6);
Group([ (1,2,3), (2,3) ])
gap> Elements(D6);
[ (), (2,3), (1,2), (1,2,3), (1,3,2), (1,3) ]
SymmetricGroup.AlternatingGroup.in to check if a permutation is an element of a group.SignPerm to compute the sign of such permutations.gap> S4 := SymmetricGroup(4);;
gap> A4 := AlternatingGroup(4);;
gap> (1,2,4) in S4;
true
gap> (1,2,4) in A4;
true
gap> SignPerm((1,2,4));
1
gap> (1,2,4,3) in S4;
true
gap> (1,2,4,3) in A4;
false
gap> SignPerm((1,2,4,3));
-1
SubgroupIsSubgroup.IsNormal function.IsNormal(G, H) checks whether every element in gap> S4 := SymmetricGroup(4);;
gap> A4 := AlternatingGroup(4);;
gap> IsSubgroup(S4,A4);
true
gap> IsNormal(S4,A4);
true
gap> H:=Group((1,2,3));;
gap> IsSubgroup(S4, H);
true
gap> IsNormal(S4, H);
false
gap> IsNormal(Group((1,2)), A4); # A4 is not a subgroup of Group((1,2))
true
H is a normal subgroup of G we compute the factor group using the function FactorGroup(G,H) or simply typing G/H.gap> FactorGroup(S4,A4);
Group([ f1 ])
gap> S4/A4;
<pc group with 1 generator>
gap> FactorGroup(S4,A4) = S4/A4;
true
gap> D8 := DihedralGroup(IsPermGroup , 8);;
gap> H := Subgroup(D8 , [(1 ,2 ,3 ,4)^2 ,(2 ,4)]);;
gap> K := Subgroup(D8 , [(2 ,4)]);;
gap> IsSubgroup(H, K);
true
gap> IsNormal(H, K);
true
gap> IsSubgroup(D8, H);
true
gap> IsNormal(D8, H);
true
gap> IsSubgroup(D8, K);
true
gap> IsNormal(D8, K);
false
Orbit(G,k) will give you the orbit of k under G.Stabilizer(G,k) computes the subgroup of G that is the stabiliser of k.gap> S8 := SymmetricGroup(8);;
gap> a := (1,2,3);;
gap> b := (7,8);;
gap> G := Subgroup(S8,[a,b]);
Group([ (1,2,3), (7,8) ])
gap> Orbit(G, 1);
[ 1, 2, 3 ]
gap> Orbit(G, 7);
[ 7, 8 ]
gap> Stabilizer(G, 1);
Group([ (7,8) ])
gap> Stabilizer(G, 7);
Group([ (1,2,3) ])
gap> Elements(Stabilizer(G, 7));
[ (), (1,2,3), (1,3,2) ]
Elements(Stabilizer(G,k)) to see all the elements in the stabiliser.RightCosets(G,H) to compute the list (set) of right cosets.gap> S7 := SymmetricGroup(7);;
gap> A7 := AlternatingGroup(7);;
gap> RightCosets(S7,A7);
[ RightCoset(Alt( [ 1 .. 7 ] ),()), RightCoset(Alt( [ 1 .. 7 ] ),(6,7)) ]
Theorem. If
Moreover, the number of distinct left (right) cosets of
Note that if
Let's test the theorem for
gap> Order(S7)/Order(A7) = Size(RightCosets(S7,A7));
true
The centre is always a normal subgroup.
In GAP to compute the centre of a group we use Center.
gap> D6 := DihedralGroup(IsPermGroup, 12);;
gap> ZD6 := Center(D6);
Group([ (1,4)(2,5)(3,6) ])
gap> IsNormal(D6,ZD6);
true
gap> D6modZD6 := FactorGroup(D6, ZD6);
Group([ f1, f2 ])
gap> RightCosets(D6,ZD6);
[ RightCoset(Group([ (1,4)(2,5)(3,6) ]),()), RightCoset(Group(
[ (1,4)(2,5)(3,6) ]),(2,6)(3,5)), RightCoset(Group([ (1,4)(2,5)(3,6) ]),
(1,5,3)(2,6,4)), RightCoset(Group([ (1,4)(2,5)(3,6) ]),(1,5)(2,4)),
RightCoset(Group([ (1,4)(2,5)(3,6) ]),(1,3,5)(2,4,6)), RightCoset(Group(
[ (1,4)(2,5)(3,6) ]),(1,3)(4,6)) ]
gap> Size(last);
6
gap> IsAbelian(D6modZD6);
false
gap> ordersS3 := List(Elements(S3), Order);;
gap> ordersD6modZD6 := List(Elements(S3), Order);;
gap> Collected(ordersS3);
[ [ 1, 1 ], [ 2, 3 ], [ 3, 2 ] ]
gap> Collected(ordersD6modZD6);
[ [ 1, 1 ], [ 2, 3 ], [ 3, 2 ] ]
Collected returns a new list containing for each element k in the list, a list of length two [k, numberk], where numberk is the number of times k appears in the list.NrSmallGroups in the library SmallGroup to check the number (up to isomorphism) of groups of a given order.gap> NrSmallGroups(6);
2
DerivedSubgroup(G).gap> D12 := DihedralGroup(IsPermGroup, 6);;
gap> D12D12 := DerivedSubgroup(D12);
Group([ (1,3,2) ])
gap> IsAbelian(GL2modD);
true
gap> ns:=NormalSubgroups(D12);;
gap> List(ns, sb -> IsAbelian(D12/sb));
[ true, true, false ]
gap> List(ns, Order);
[ 6, 3, 1 ]
gap> D6D6 = ns[2];
true
AllSmallGroups to find the smallest perfect group.gap> n:=1;;
gap> found := false;;
gap> while found = false do
> for g in AllSmallGroups(n) do
> if Order(g) = Order(DerivedSubgroup(g)) then
> found := true;
> break;
> fi;
> od;
> n:=n+1;
> od;
gap> Print(StructureDescription(g));
A5
Liebeck, M. W., O’Brien, E. A., Shalev, A., & Tiep, P. H. (2010). The Ore Conjecture. Journal of the European Mathematical Society, 12(4), 939–1008.
CommutatorLength which returns the minimal gap> n:=1;;
gap> found := false;;
gap> while found = false do
> n:=n+1;
> if NrPerfectGroups(n)>=1 then
> for i in [1..NrPerfectGroups(n)] do
> g:=PerfectGroup(n, i);
> if CommutatorLength(g) > 1 then
> found := true;
> break;
> fi;
> od;
> fi;
> od;
gap> Print(n, " ", i);
960 2
gap> n:=1;;
gap> found := false;;
gap> n:=n+1;
2
gap> while found = false do
> n:=n+1;
> for g in AllSmallGroups(n) do
> if CommutatorLength(g) > 1 then
> found := true;
> break;
> fi;
> od;
> od;
gap> Print(IdSmallGroup(g));
[ 96, 3 ]
Carmichael, R. D. Introduction to the Theory of Groups of Finite Order. New York: Dover Publications, 1956.
gap> for g in AllSmallGroups(256) do
> if CommutatorLength(g) > 1 then
> found := true;
> break;
> fi;
> od;
gap> Print(IdSmallGroup(g));
[ 256, 23 ]
SmallGroup(256, 23) the same example?IsomorphismGroups.fail if the groups are not isomorphic, or some isomorphismgap> S3 := SymmetricGroup(3);;
gap> C6 := CyclicGroup(6);;
gap> D6:= DihedralGroup(6);;
gap> IsomorphismGroups(S3, C6);
fail
gap> IsomorphismGroups(S3, D6);
[ (1,2,3), (1,2) ] -> [ f2, f1*f2 ]
gap> AreIsomorphic := function(g,h)
> return not IsomorphismGroups(g,h) = fail;
> end;
function( g, h ) ... end
gap> AreIsomorphic(S3, C6);
false
gap> AreIsomorphic(S3, D6);
true
AreIsomorphic to test if SmallGroup(256,23) is indeed Carmichael's example.a := (1 ,3)(2 ,4);;
b := (5 ,7)(6 ,8);;
c := (9 ,11)(10 ,12);;
d := (13 ,15)(14 ,16);;
e := (1 ,3)(5 ,7)(9 ,11);;
f := (1 ,2)(3 ,4)(13 ,15);;
g := (5 ,6)(7 ,8)(13 ,14)(15 ,16);;
h := (9 ,10)(11 ,12);;
CarEx := Group ([ a ,b ,c ,d ,e ,f ,g , h ]);;
gap> AreIsomorphic(SmallGroup(256,23), CarEx);
false
Exercise.
Group([gens]) – group via generators.SymmetricGroup(n) - Symmetric group on AlternatingGroup(n) – Alternating group on CyclicGroup(n) – Cyclic group of order DihedralGroup(n) – Dihedral group of order IsomorphismPermGroup(G) – Isomorphism from group to a permutation group.Subgroup(G, [gens]) – Creates a subgroup.IsSubgroup(G, H) – Checks if IsNormal(G, H) – Checks if H is a normal subgroup of G.FactorGroup(G, H) or G/H – Constructs the factor group.Center(G) – Returns the centre of RightCosets(G, H) – List of right cosets of Orbit(G, k) – Orbit of point Stabilizer(G, k) – Subgroup fixing MovedPoints(G) – List of points moved by the group.NrMovedPoints(G) – Number of moved points.LargestMovedPoint(G), SmallestMovedPoint(G) – Extremes of moved points.Collected(List) – Counts frequency of each unique item.