SetEchoInput (true); SetLogFile ("queenstown-1.log"); // set up standard matrix group G := SL(4, 7); G; // generator of G G.1; x := G.1 * G.2; x; Order (x); RandomSchreier (G); Base (G); BasicOrbitLengths (G); G := OmegaPlus (100, 5); g := Random (G); time n := Order (g); n; time h := g^(n div 2); Order (h); // char and min poly computations repeat g := Random (G); c := CharacteristicPolynomial (g); m := MinimalPolynomial (g); until m ne c; F := GF (5); P := PolynomialRing (F); c := P!c; Factorisation (c); m := P!m; Factorisation (m); // reducible example O53 := PermutationGroup<45 | (2,3)(4,6)(7,9)(8,11)(12,16)(13,14)(15,19)(18,22)(20,25)(21,26)(27,33)(28,35) (29,34)(31,38)(36,43)(39,41), (1,2,4,7,10,14,16,3,5)(6,8,12,17,21,27,34,41,44)(9,13,18,23,29,37,33,40,43) (11,15,20)(19,24,30,25,31,22,28,36,38)(26,32,39)(35,42,45)>; O53; CompositionFactors (O53); P := PermutationModule(O53, GaloisField(2)); P; IsIrreducible (P); // module composition series S, F := CompositionSeries(P); // submodules S; // module composition factors F; C := Constituents(P); C; [IsAbsolutelyIrreducible(m): m in C]; M := C[3]; M; f, A, d := IsAbsolutelyIrreducible (M); // matrix algebra generator for endomorphism algebra E of M (field) A; // dimension of E d; // action of O53 on this factor H := ActionGroup (M); // absolute representation A := AbsoluteRepresentation (H); A; CompositionFactors (A); // setting up a matrix group G := sub ; G; #G; IdentifyGroup (G); H := SmallGroup (20, 3); H; // imprimitive group G := MatrixGroup<6, GF(7) | [ 5, 0, 4, 5, 2, 4, 3, 2, 1, 4, 5, 2, 6, 0, 0, 4, 3, 6, 5, 4, 4, 3, 6, 1, 2, 3, 3, 5, 2, 6, 0, 2, 3, 4, 0, 6 ], [ 0, 0, 6, 4, 3, 6, 4, 4, 5, 4, 2, 1, 2, 0, 3, 6, 1, 2, 2, 5, 6, 3, 1, 4, 5, 2, 1, 5, 0, 3, 6, 6, 1, 2, 3, 1 ], [ 3, 3, 3, 5, 1, 6, 3, 0, 5, 0, 5, 4, 3, 1, 2, 4, 5, 2, 5, 3, 6, 1, 6, 2, 2, 4, 1, 0, 2, 5, 3, 4, 2, 3, 5, 0 ], [ 1, 2, 3, 4, 0, 5, 6, 0, 1, 2, 3, 0, 0, 3, 2, 6, 0, 4, 3, 3, 4, 2, 5, 0, 4, 4, 3, 6, 3, 0, 5, 2, 1, 5, 6, 4 ], [ 1, 6, 2, 5, 0, 1, 1, 4, 2, 2, 4, 5, 0, 2, 4, 4, 0, 5, 4, 5, 1, 2, 2, 6, 3, 2, 6, 6, 6, 1, 2, 4, 1, 0, 1, 6 ], [ 4, 6, 1, 3, 2, 5, 2, 0, 6, 2, 5, 4, 5, 0, 5, 1, 2, 3, 2, 6, 6, 1, 4, 2, 5, 3, 1, 0, 2, 2, 1, 4, 0, 4, 2, 2 ], [ 5, 3, 4, 1, 2, 6, 0, 0, 3, 4, 4, 1, 1, 0, 6, 5, 0, 4, 2, 6, 6, 1, 4, 2, 6, 2, 3, 1, 0, 1, 0, 4, 2, 5, 5, 4 ] >; G; IsPrimitive (G); // blocks B := Blocks (G); #B; B[1]; // Now obtain a permutation representation of G in its action on the blocks. P := BlocksImage (G); P; #P; g := G.6 * G.7; ImprimitiveAction (G, g); // hom from G to P tau := hom< G -> P | [P.i : i in [1..Ngens (P)]]>; // kernel of hom K := Kernel (tau); K; /* name simple group */ F := GF(3); P := GL(5,F); gens := [ P![2,1,2,1,2,2,0,0,0,2,0,2,0,0,0,0,1,2,0,1,1,0,2,2,1], P![2,1,0,2,1,1,2,0,2,2,1,1,2,1,1,0,2,0,1,1,1,1,2,2,2]]; G := sub

; flag, name := SimpleGroupName(G); flag; "name is ", name; F := GF(7^2); P := GL (6,F); w := PrimitiveElement (F); gens := [ P![w^12,w^36, 0, 5, 2, 0,w^44,w^36, 0, 6, 2, 0, w^42,w^42,w^28,w^22,w^22, 3, 4, 3, 0,w^36,w^12, 0, 2, 3, 0,w^20,w^12, 0,w^14,w^14, 1,w^18,w^18, w^4], P![w^38,w^26,w^25,w^21, w^9, 3,w^21,w^45,w^33, w^4,w^28, 2, 6, 4, w^1, w^7,w^15, 4, 1,w^36,w^35, w^5,w^41, 5, w^31, w^7,w^43,w^36,w^12, 1,w^34,w^42,w^11,w^39,w^47, 2] ]; G := sub

; LieCharacteristic (G); flag, name := LieType(G, 5); flag; name; // constructive recognition S := Alt (26); S; M := PermutationModule (S, GF (5^2)); G := ActionGroup (M); G := RandomConjugate (G); f, type, n := GuessAltsymDegree (G); f, type, n; f, alpha, beta := RecogniseAlternating (G, n); f; x := beta (S.1); alpha (G.2); x := Random (G); y := alpha (x); z := beta (y); Order (x * z^-1); // matrix group defined over "large" field K := GF(5, 7); G := MatrixGroup<6, GF(5, 7) | [w^19035, w^14713, w^50617, w^14957, w^51504, w^48397, w^16317, w^3829, w^35189, w^2473, w^19497, w^77192, w^46480, w^6772, w^29577, w^61815, w^54313, w^16757, w^43765, w^64406, w^58788, w^30789, w^13579, w^66728, w^7733, w^45434, w^42411, w^61613, w^12905, w^6889, w^50116, w^16117, w^56717, w^25226, w^49940, w^36836 ], [w^63955, w^40568, w^45004, w^11642, w^39536, w^11836, w^52594, w^71166, w^47015, w^74450, w^32373, w^37021, w^76381, w^18155, w^57943, w^31194, w^62524, w^65864, w^11868, w^76867, w^26483, w^41335, w^64856, w^41125, w^43990, w^40104, w^24842, w^3153, w^23777, w^60024, w^14454, w^68648, w^43403, w^26710, w^39779, w^22074 ] >; LMGCompositionFactors (G); // databases of sporadic and other groups G := MatrixGroup ("J1", 1); G; // maximals of classical groups // normalisers in GL(8, 7) of maximals of O^+(8, 7) // which are of C6-type L := ClassicalMaximals ("O+", 8, 7: normaliser := true, classes := {6}); LMGCompositionFactors (L[1]); G := L[1]; P, phi, M := RadicalQuotient (G); P; Q, tau := DegreeReduction (P); Q; tau; CompositionFactors (Q); SetVerbose ("Subgroups", 2); // all insoluble subgroups of order not divisible by 7 S := NonsolvableSubgroups (Q: OrderDividing := #Q div 7); #S; L := [s`subgroup: s in S]; T := [ (l @@ tau) @@ phi: l in L]; [LMGOrder (t): t in T]; V := VectorSpace (GF (7), 8); // demonstrate that there are orbits of vectors having // different lengths under each subgroup for i in [1..#T] do i; repeat v := Random (V); O := Orbit (T[i], v); u := Random (V); O1 := Orbit (T[i], u); until #O ne #O1; end for; // 6-dimensional repn of the Braid group on 4 strings // defined over rational function field of rank 2 Q := Rationals (); E := RationalFunctionField (Q, 2); A := [-t * q^2, 0,0,q^2 -q, q^2 - q,0, 0,0,0,q,0,0, 0,0,0,0,q,0, 0,1,0,1-q,0,0, 0,0,1,0,1-q,0, 0,0,0,0,0,1]; B := [0,q,0,0,0,0, 1,1-q,0,0,0,0, 0,0,1,0,0,0, 0,t*(q - q^2), 0, -t *q^2, 0, q^2 - q, 0,0,0,0,0,q, 0,0,0,0,1,1-q]; C := [1,0,0,0,0,0, 0,0,q,0,0,0, 0,1,1-q,0,0,0, 0,0,0,0,q,0, 0,0,0,1,1-q,0, 0,0,t*(q-q^2), 0, t*(q - q^2), -t * q^2]; R := sub; R; // now specialise to case t = -1/q F := RationalFunctionField (Q); G := GL(6, F); a := [q,0,0,q^2 - q, q^2 - q, 0, 0,0,0,q, 0, 0, 0,0,0,0, q, 0, 0,1,0,1-q,0,0, 0,0,1,0,1-q,0, 0,0,0,0,0,1]; b:=[ 0,q,0,0,0,0, 1,1-q,0,0,0,0, 0,0,1,0,0,0, 0,q-1,0,q,0,q^2 - q, 0,0,0,0,0,q, 0,0,0,0,1,1-q]; c := [ 1,0,0,0,0,0, 0,0,q,0,0,0, 0,1,1-q,0,0,0, 0,0,0,0,q,0, 0,0,0,1,1-q,0, 0,0,q-1,0,q-1,q]; H := sub; I := CongruenceImage (H); I; IsIsomorphic (I, Sym (4)); // P_4, the "pure braid group" is a subgroup of index 24 inside B_4 W := SLPGroup (3); pure := [ W.3 * W.2 * W.1^2 * W.2^-1 * W.3^-1, W.2 * W.1^2 * W.2^-1, W.3 * W.2^2 * W.3^-1, W.1^2, W.2^2, W.3^2 ]; A := Evaluate (pure, [H.1, H.2, H.3]); P := sub ; // P has no torsion elements I := CongruenceImage (P); I; M := GModule (H); f, U, W := IsIrreducible (M); U, W; // can prove that 2-dimension repn // is faithful repn for P_3 // so PA is in kernel of hom from P_4 to P_3 A := ActionGroup (U); gens := [ActionGenerator (U, i): i in [1..3]]; A; IsSoluble (A); X := Evaluate (pure, [A.i : i in [1..3]]); PA := sub< A | X >; PA; // commutator of two generators? (PA.1, PA.2); // do all generators commute? gens := [PA.i : i in [1..Ngens (PA)]]; for i in [1..#gens] do for j in [i + 1..#gens] do x := (gens[i], gens[j]); i, j, IsIdentity (x); end for; end for; // do all generators commute? forall{: x in gens, y in gens | IsIdentity ((x, y))}; // is PA abelian IsAbelian (PA); // this group is abelian so can't be in kernel from P_4 to P_3 Q := Rationals (); P := PolynomialRing (Q); f := x^2 - 2; E := ext; P := GL(2, E); G := sub

; G; CongruenceImage; I := [CongruenceImage (G: Prime := p): p in [3, 5,7,11, 13, 19, 23,29]]; LMGCompositionFactors (I[1]); LMGCompositionFactors (I[2]); LMGCompositionFactors (I[3]); LMGCompositionFactors (I[4]); [LMGCompositionFactors (h): h in I]; // if p > 3 and y^2 - 2 is irreducible mod p // then CongruenceImage is SL(2, p^2) otherwise SL(2,p) quit;