From 88e7add423f2fc98b12b9fae72f7ca85343bbfef Mon Sep 17 00:00:00 2001 From: Alexander Hulpke Date: Thu, 5 Nov 2026 10:13:45 -0600 Subject: [PATCH] FIX: SubgroupsSolvableGroups A shortcut for a case of no complements is only valid if the 1-coboundaries are trivial. (This was found with help of Claude AI) --- lib/grppclat.gi | 3 ++- tst/testbugfix/2026-11-05-SubgroupsSolvableGroup.tst | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 tst/testbugfix/2026-11-05-SubgroupsSolvableGroup.tst diff --git a/lib/grppclat.gi b/lib/grppclat.gi index 5bcb2e585f..6031ee7aae 100644 --- a/lib/grppclat.gi +++ b/lib/grppclat.gi @@ -1034,7 +1034,8 @@ Assert(1,ForAll(bs,i->ForAll(efunc,j->Image(j,i)=i))); l:=z.cocycleToComplement(com[kp]); # the projection on the complement k:=ClosureSubgroup(b,l); - if Length(s)=1 and IsOne(s[1]) then + if Length(s)=1 and IsOne(s[1]) + and Dimension(z.oneCoboundaries)=0 then # special case -- no conjugates if ForAll(efunc,x->ForAll(GeneratorsOfGroup(l), y->ImagesRepresentative(x,y) in k)) then diff --git a/tst/testbugfix/2026-11-05-SubgroupsSolvableGroup.tst b/tst/testbugfix/2026-11-05-SubgroupsSolvableGroup.tst new file mode 100644 index 0000000000..9e995e9c10 --- /dev/null +++ b/tst/testbugfix/2026-11-05-SubgroupsSolvableGroup.tst @@ -0,0 +1,5 @@ +# Regression test for bug reported by H. Dietrich on 10/28/2026 +gap> G := SmallGroup(12, 3);; +gap> a:=GroupHomomorphismByImages(G,G,[G.1,G.2,G.3],[G.1^2*G.2,G.3,G.2]);; +gap> Set(List(SubgroupsSolvableGroup(G, rec(actions := [a])), Size)); +[ 1, 2, 3, 4, 12 ]