Skip to content

Commit

Permalink
Make test files more resilient to StructureDescription
Browse files Browse the repository at this point in the history
Further, grpnames.g contains the "nice" outputs of StructureDescription.
  • Loading branch information
hungaborhorvath committed Nov 27, 2016
1 parent e883a6d commit 561d109
Show file tree
Hide file tree
Showing 5 changed files with 80 additions and 77 deletions.
127 changes: 64 additions & 63 deletions lib/grpnames.g
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#############################################################################
##
#W grpnames.g Stefan Kohl
#W grpnames.g Gábor Horváth
## Stefan Kohl
##
##
#Y Copyright (C) 2004 The GAP Group
Expand Down Expand Up @@ -79,7 +80,7 @@ NAMES_OF_SMALL_GROUPS :=
"C4 x S3",
"D24",
"C2 x (C3 : C4)",
"C3 : D8",
"(C6 x C2) : C2",
"C12 x C2",
"C3 x D8",
"C3 x Q8",
Expand Down Expand Up @@ -111,7 +112,7 @@ NAMES_OF_SMALL_GROUPS :=
"C8 x C4",
"C8 : C4",
"(C8 x C2) : C2",
"((C4 x C2) : C2) : C2",
"(C2 x C2 x C2) : C4",
"(C8 : C2) : C2",
"C2 . ((C4 x C2) : C2) = (C2 x C2) . (C4 x C2)",
"(C8 x C2) : C2",
Expand All @@ -132,30 +133,30 @@ NAMES_OF_SMALL_GROUPS :=
"(C4 x C4) : C2",
"C4 x D8",
"C4 x Q8",
"(C2 x D8) : C2",
"(C2 x D8) : C2",
"(C4 : C4) : C2",
"((C4 x C2) : C2) : C2",
"((C4 x C2) : C2) : C2",
"(C2 x C2 x C2 x C2) : C2",
"(C4 x C2 x C2) : C2",
"(C2 x Q8) : C2",
"(C4 x C2 x C2) : C2",
"(C4 x C4) : C2",
"(C2 x C2) . (C2 x C2 x C2)",
"(C4 x C4) : C2",
"(C2 x D8) : C2",
"(C4 x C4) : C2",
"C4 : Q8",
"C8 x C2 x C2",
"C2 x (C8 : C2)",
"(C8 x C2) : C2",
"C2 x D16",
"C2 x QD16",
"C2 x Q16",
"(D8 : C2) : C2",
"(D8 : C2) : C2",
"QD16 : C2",
"(C8 x C2) : C2",
"C8 : (C2 x C2)",
"(C2 x Q8) : C2",
"C4 x C2 x C2 x C2",
"C2 x C2 x D8",
"C2 x C2 x Q8",
"C2 x ((C4 x C2) : C2)",
"(C2 x D8) : C2",
"(D8 : C2) : C2",
"(C2 x C2 x C2) : (C2 x C2)",
"(C2 x Q8) : C2",
"C2 x C2 x C2 x C2 x C2" ],
[ "C33" ],
[ "D34",
Expand Down Expand Up @@ -187,7 +188,7 @@ NAMES_OF_SMALL_GROUPS :=
"C4 x D10",
"D40",
"C2 x (C5 : C4)",
"C5 : D8",
"(C10 x C2) : C2",
"C20 x C2",
"C5 x D8",
"C5 x Q8",
Expand Down Expand Up @@ -215,21 +216,21 @@ NAMES_OF_SMALL_GROUPS :=
"C48",
"(C4 x C4) : C3",
"C8 x S3",
"C3 : (C8 : C2)",
"C3 : QD16",
"C24 : C2",
"C24 : C2",
"D48",
"C3 : Q16",
"C2 x (C3 : C8)",
"C3 : (C8 : C2)",
"(C3 : C8) : C2",
"C4 x (C3 : C4)",
"C3 : (C4 : C4)",
"C3 : (C4 : C4)",
"C3 : ((C4 x C2) : C2)",
"C3 : D16",
"C3 : QD16",
"C3 : QD16",
"(C3 : C4) : C4",
"C12 : C4",
"(C12 x C2) : C2",
"(C3 x D8) : C2",
"(C3 : Q8) : C2",
"(C3 x Q8) : C2",
"C3 : Q16",
"C3 : ((C4 x C2) : C2)",
"(C6 x C2) : C4",
"C12 x C4",
"C3 x ((C4 x C2) : C2)",
"C3 x (C4 : C4)",
Expand All @@ -247,13 +248,13 @@ NAMES_OF_SMALL_GROUPS :=
"C2 x (C3 : Q8)",
"C2 x C4 x S3",
"C2 x D24",
"C3 : (D8 : C2)",
"(C12 x C2) : C2",
"D8 x S3",
"C3 : (D8 : C2)",
"(C4 x S3) : C2",
"Q8 x S3",
"C3 : (D8 : C2)",
"(C4 x S3) : C2",
"C2 x C2 x (C3 : C4)",
"C2 x (C3 : D8)",
"C2 x ((C6 x C2) : C2)",
"C12 x C2 x C2",
"C6 x D8",
"C6 x Q8",
Expand Down Expand Up @@ -281,8 +282,8 @@ NAMES_OF_SMALL_GROUPS :=
"C54",
"C3 x D18",
"C9 x S3",
"((C3 x C3) : C3) : C2",
"(C9 : C3) : C2",
"(C3 x C3) : C6",
"C9 : C6",
"(C9 x C3) : C2",
"((C3 x C3) : C3) : C2",
"C18 x C3",
Expand All @@ -300,7 +301,7 @@ NAMES_OF_SMALL_GROUPS :=
"C4 x D14",
"D56",
"C2 x (C7 : C4)",
"C7 : D8",
"(C14 x C2) : C2",
"C28 x C2",
"C7 x D8",
"C7 x Q8",
Expand All @@ -314,11 +315,11 @@ NAMES_OF_SMALL_GROUPS :=
[ "C59" ],
[ "C5 x (C3 : C4)",
"C3 x (C5 : C4)",
"C3 : (C5 : C4)",
"C15 : C4",
"C60",
"A5",
"C3 x (C5 : C4)",
"C3 : (C5 : C4)",
"C15 : C4",
"S3 x D10",
"C5 x A4",
"C6 x D10",
Expand Down Expand Up @@ -357,7 +358,7 @@ NAMES_OF_SMALL_GROUPS :=
"C4 x D18",
"D72",
"C2 x (C9 : C4)",
"C9 : D8",
"(C18 x C2) : C2",
"C36 x C2",
"C9 x D8",
"C9 x Q8",
Expand All @@ -371,25 +372,25 @@ NAMES_OF_SMALL_GROUPS :=
"(C3 x C3) : C8",
"(C3 : C4) x S3",
"(C3 x C3) : (C4 x C2)",
"(C3 x C3) : D8",
"(C3 x C3) : D8",
"(C6 x S3) : C2",
"(C6 x S3) : C2",
"(C3 x C3) : Q8",
"C3 x SL(2,3)",
"C3 x (C3 : Q8)",
"C12 x S3",
"C3 x D24",
"C6 x (C3 : C4)",
"C3 x (C3 : D8)",
"C3 x ((C6 x C2) : C2)",
"(C3 x C3) : Q8",
"C4 x ((C3 x C3) : C2)",
"(C3 x C3) : D8",
"(C12 x C3) : C2",
"C2 x ((C3 x C3) : C4)",
"(C3 x C3) : D8",
"(C6 x C6) : C2",
"C12 x C6",
"C3 x C3 x D8",
"C3 x C3 x Q8",
"(C3 x C3) : C8",
"(C3 x C3) : D8",
"(S3 x S3) : C2",
"(C3 x C3) : Q8",
"C3 x S4",
"(C3 x A4) : C2",
Expand Down Expand Up @@ -422,21 +423,21 @@ NAMES_OF_SMALL_GROUPS :=
"C80",
"C5 : C16",
"C8 x D10",
"C5 : (C8 : C2)",
"C5 : QD16",
"C40 : C2",
"C40 : C2",
"D80",
"C5 : Q16",
"C2 x (C5 : C8)",
"C5 : (C8 : C2)",
"(C5 : C8) : C2",
"C4 x (C5 : C4)",
"C5 : (C4 : C4)",
"C5 : (C4 : C4)",
"C5 : ((C4 x C2) : C2)",
"C5 : D16",
"C5 : QD16",
"C5 : QD16",
"(C5 : C4) : C4",
"C20 : C4",
"(C20 x C2) : C2",
"(C5 x D8) : C2",
"(C5 : Q8) : C2",
"(C5 x Q8) : C2",
"C5 : Q16",
"C5 : ((C4 x C2) : C2)",
"(C10 x C2) : C4",
"C20 x C4",
"C5 x ((C4 x C2) : C2)",
"C5 x (C4 : C4)",
Expand All @@ -446,22 +447,22 @@ NAMES_OF_SMALL_GROUPS :=
"C5 x QD16",
"C5 x Q16",
"C5 : (C8 x C2)",
"C5 : (C8 : C2)",
"(C5 : C8) : C2",
"C4 x (C5 : C4)",
"C5 : (C4 : C4)",
"C20 : C4",
"C2 x (C5 : C8)",
"C5 : (C8 : C2)",
"C5 : ((C4 x C2) : C2)",
"(C5 : C8) : C2",
"(C10 x C2) : C4",
"C2 x (C5 : Q8)",
"C2 x C4 x D10",
"C2 x D40",
"C5 : (D8 : C2)",
"(C20 x C2) : C2",
"D8 x D10",
"C5 : (D8 : C2)",
"(C4 x D10) : C2",
"Q8 x D10",
"C5 : (D8 : C2)",
"(C4 x D10) : C2",
"C2 x C2 x (C5 : C4)",
"C2 x (C5 : D8)",
"C2 x ((C10 x C2) : C2)",
"C20 x C2 x C2",
"C10 x D8",
"C10 x Q8",
Expand Down Expand Up @@ -492,13 +493,13 @@ NAMES_OF_SMALL_GROUPS :=
"C4 x (C7 : C3)",
"C7 x (C3 : C4)",
"C3 x (C7 : C4)",
"C3 : (C7 : C4)",
"C21 : C4",
"C84",
"C2 x (C7 : C6)",
"S3 x D14",
"C2 x C2 x (C7 : C3)",
"C7 x A4",
"(C2 x C2) : (C7 : C3)",
"(C14 x C2) : C3",
"C6 x D14",
"C14 x S3",
"D84",
Expand All @@ -513,7 +514,7 @@ NAMES_OF_SMALL_GROUPS :=
"C4 x D22",
"D88",
"C2 x (C11 : C4)",
"C11 : D8",
"(C22 x C2) : C2",
"C44 x C2",
"C11 x D8",
"C11 x Q8",
Expand All @@ -528,7 +529,7 @@ NAMES_OF_SMALL_GROUPS :=
"C15 x S3",
"C3 x D30",
"C5 x ((C3 x C3) : C2)",
"(C3 x C3) : D10",
"(C15 x C3) : C2",
"C30 x C3" ],
[ "C91" ],
[ "C23 : C4",
Expand Down
5 changes: 5 additions & 0 deletions tst/testinstall/opers/SemidirectDecompositions.tst
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,9 @@ gap> G := SemidirectProduct(aut, N);; StructureDescription(G);
"PSL(2,32) : C5"
gap> SemidirectDecompositionsOfFiniteGroup(G, "any", "full");
Error, usage: SemidirectDecompositionsOfFiniteGroup(<G> [, <Ns>] [, <mthd>])
gap> G := Group([ (4,8)(6,10), (4,6,10,8,12), (2,4,12)(6,10,8), (3,9)(4,6,10,8,12)(7,11), (3,5)(4,6,10,8,12)(9,11), (1,3,11,9,5)(4,6,10,8,12) ]);;
gap> infolevel:=InfoLevel(InfoWarning);; SetInfoLevel(InfoWarning,0);
gap> Length(SemidirectDecompositions(G));
8
gap> SetInfoLevel(InfoWarning,infolevel);
gap> STOP_TEST("Semidirectdecompositions.tst", 10000);
22 changes: 10 additions & 12 deletions tst/testinstall/opers/StructureDescription.tst
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,8 @@ gap> l := AllSmallGroups(12);;
gap> List(l, StructureDescription);; l;
[ C3 : C4, C12, A4, D12, C6 x C2 ]
gap> List(AllSmallGroups(40),G->StructureDescription(G:short));
[ "5:8", "40", "5:8", "5:Q8", "4xD10", "D40", "2x(5:4)", "5:D8", "20x2",
[ "5:8", "40", "5:8", "5:Q8", "4xD10", "D40", "2x(5:4)", "(10x2):2", "20x2",
"5xD8", "5xQ8", "2x(5:4)", "2^2xD10", "10x2^2" ]
gap> List(AllSmallGroups(16), G -> StructureDescription(G:recompute));
[ "C16", "C4 x C4", "(C4 x C2) : C2", "C4 : C4", "C8 x C2", "C8 : C2", "D16",
"QD16", "Q16", "C4 x C2 x C2", "C2 x D8", "C2 x Q8", "(C4 x C2) : C2",
"C2 x C2 x C2 x C2" ]
gap> List(AllSmallGroups(60), G -> StructureDescription(G:recompute));
[ "C5 x (C3 : C4)", "C3 x (C5 : C4)", "C3 : (C5 : C4)", "C60", "A5",
"C3 x (C5 : C4)", "C3 : (C5 : C4)", "S3 x D10", "C5 x A4", "C6 x D10",
Expand All @@ -18,12 +14,14 @@ gap> List(AllPrimitiveGroups(DegreeAction, 8), StructureDescription);
"(C2 x C2 x C2) : PSL(3,2)", "PSL(3,2)", "PSL(3,2) : C2", "A8", "S8" ]
gap> List(AllTransitiveGroups(DegreeAction, 6), G -> StructureDescription(G:short));
[ "6", "S3", "D12", "A4", "3xS3", "2xA4", "S4", "S4", "S3xS3", "(3^2):4",
"2xS4", "A5", "(3^2):D8", "S5", "A6", "S6" ]
"2xS4", "A5", "(S3xS3):2", "S5", "A6", "S6" ]
gap> StructureDescription(PSL(4,2));
"A8"
gap> G := Group([ (4,8)(6,10), (4,6,10,8,12), (2,4,12)(6,10,8), (3,9)(4,6,10,8,12)(7,11), (3,5)(4,6,10,8,12)(9,11), (1,3,11,9,5)(4,6,10,8,12) ]);;
gap> infolevel:=InfoLevel(InfoWarning);; SetInfoLevel(InfoWarning,0);
gap> StructureDescription(G);
"A5 x A5"
gap> SetInfoLevel(InfoWarning,infolevel);
gap> N := PSL(2,32);; aut := SylowSubgroup(AutomorphismGroup(N),5);;
gap> G := SemidirectProduct(aut, N);; StructureDescription(G);
"PSL(2,32) : C5"
Expand All @@ -45,8 +43,8 @@ gap> G := PerfectGroup(IsPermGroup,1344,1);; StructureDescription(G);
"(C2 x C2 x C2) : PSL(3,2)"
gap> G := PerfectGroup(IsPermGroup,1344,2);; StructureDescription(G);
"(C2 x C2 x C2) . PSL(3,2)"
gap> StructureDescription(SmallGroup(32,8):recompute);
"C2 . ((C4 x C2) : C2) = (C2 x C2) . (C4 x C2)"
gap> StructureDescription(SmallGroup(32,15):recompute);
"C4 . D8 = C4 . (C4 x C2)"
gap> List(AllSmallNonabelianSimpleGroups([1..1000000]), StructureDescription);
[ "A5", "PSL(3,2)", "A6", "PSL(2,8)", "PSL(2,11)", "PSL(2,13)", "PSL(2,17)",
"A7", "PSL(2,19)", "PSL(2,16)", "PSL(3,3)", "PSU(3,3)", "PSL(2,23)",
Expand All @@ -58,8 +56,8 @@ gap> List(AllSmallNonabelianSimpleGroups([1..1000000]), StructureDescription);
"PSL(2,89)", "PSL(3,5)", "M22", "PSL(2,97)", "PSL(2,101)", "PSL(2,103)",
"HJ", "PSL(2,107)", "PSL(2,109)", "PSL(2,113)", "PSL(2,121)", "PSL(2,125)",
"O(5,4)" ]
gap> StructureDescription(AbelianGroup([0,2,3,4,5,6,7,8,9,10]));
"C0 x C2520 x C60 x C6 x C2 x C2"
gap> StructureDescription(AbelianGroup([0,0,0,2,3,4,5,6,7,8,9,10]));
"C0 x C0 x C0 x C2520 x C60 x C6 x C2 x C2"
gap> infolevel:=InfoLevel(InfoWarning);; SetInfoLevel(InfoWarning,2);
gap> StructureDescription(SmallGroup(48,16):recompute,nice);
#I Warning! Non-unique semidirect product:
Expand All @@ -74,6 +72,6 @@ gap> SetInfoLevel(InfoWarning,infolevel);
##
## Currently the value "short" does not work for infinite abelian groups.
##
##gap> StructureDescription(AbelianGroup([0,2,3,4,5,6,7,8,9,10]):short);
##"0x2520x60x6x2x2"
##gap> StructureDescription(AbelianGroup([0,0,0,2,3,4,5,6,7,8,9,10]):short);
##"0^3x2520x60x6x2^2"
gap> STOP_TEST("StructureDescription.tst", 10000);
1 change: 0 additions & 1 deletion tst/teststandard/opers/StructureDescription.tst
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@ gap> START_TEST("StructureDescription.tst");
gap> G := Group([ (6,7,8,9,10), (8,9,10), (1,2)(6,7), (1,2,3,4,5)(6,7,8,9,10) ]);;
gap> StructureDescription(G);
"A5 : S5"
gap> for n in [1..100] do for i in [1..NumberSmallGroups(n)] do if n<>64 and n<>96 then G := SmallGroup(n,i); H := SmallGroup(n, i); if StructureDescription(G)<>StructureDescription(H:recompute) then Print(n, ", ", i, ", ", StructureDescription(H:recompute), "\n"); fi; fi; od; od;
gap> STOP_TEST("StructureDescription.tst", 10000);
2 changes: 1 addition & 1 deletion tst/teststandard/small_groups2.tst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ gap> for n in [1..Length(NAMES_OF_SMALL_GROUPS)] do
> G := SmallGroup(n, i);
> descA := NAMES_OF_SMALL_GROUPS[n][i];
> G := Subgroup(G, GeneratorsOfGroup(G));
> descB := StructureDescription(G : recompute := true);
> descB := StructureDescription(G : recompute := true, nice := true);
> if descA <> descB then
> Print([n,i], ": bad description ", descB, ", should be ", descA, "\n");
> AddSet(bad, [n,i]);
Expand Down

0 comments on commit 561d109

Please sign in to comment.