From 56f91d6d1207bcdb663d86a24652a678a31a074f Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Fri, 12 Jan 2024 17:27:39 +0000 Subject: [PATCH 01/14] Use ReturnFalse rather than function returning false --- lib/coll.gi | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/coll.gi b/lib/coll.gi index 51feb7ce6d..f47ac03456 100644 --- a/lib/coll.gi +++ b/lib/coll.gi @@ -3034,10 +3034,7 @@ InstallGlobalFunction(CanEasilyCompareElementsFamily,function(fam) end); InstallMethod(CanEasilyCompareElements,"family: default false", - [IsFamily], -function(obj) - return false; -end); + [IsFamily], ReturnFalse); InstallOtherMethod(SetCanEasilyCompareElements,"family setter", [IsFamily,IsObject], From bb778205dc167ef0a2095ef0ee5dc87974caee2b Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Fri, 12 Jan 2024 17:28:47 +0000 Subject: [PATCH 02/14] Remove unused function args from Nr(Combinations|Arrangements)(M)SetA --- lib/combinat.gi | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/combinat.gi b/lib/combinat.gi index 80e067951d..4973b1a09d 100644 --- a/lib/combinat.gi +++ b/lib/combinat.gi @@ -454,13 +454,13 @@ BindGlobal( "NrCombinationsX", function ( mset, k ) return nrs; end ); -BindGlobal( "NrCombinationsSetA", function ( set, k ) +BindGlobal( "NrCombinationsSetA", function ( set ) local nr; nr := 2 ^ Size(set); return nr; end ); -BindGlobal( "NrCombinationsMSetA", function ( mset, k ) +BindGlobal( "NrCombinationsMSetA", function ( mset ) local nr; nr := Product( Set(mset), i->Number(mset,j->i=j)+1 ); return nr; @@ -491,9 +491,9 @@ InstallGlobalFunction(NrCombinations,function ( mset, arg... ) mset := ShallowCopy(mset); Sort( mset ); if Length(arg) = 0 then if IsSSortedList( mset ) then - nr := NrCombinationsSetA( mset, Length(mset) ); + nr := NrCombinationsSetA( mset ); else - nr := NrCombinationsMSetA( mset, Length(mset) ); + nr := NrCombinationsMSetA( mset ); fi; elif Length(arg) = 1 then if IsSSortedList( mset ) then @@ -648,7 +648,7 @@ BindGlobal( "NrArrangementsX", function ( mset, k ) return nrs; end ); -BindGlobal( "NrArrangementsSetA", function ( set, k ) +BindGlobal( "NrArrangementsSetA", function ( set ) local nr, i; nr := 0; for i in [0..Size(set)] do @@ -688,7 +688,7 @@ InstallGlobalFunction(NrArrangements,function ( mset, arg... ) mset := ShallowCopy(mset); Sort( mset ); if Length(arg) = 0 then if IsSSortedList( mset ) then - nr := NrArrangementsSetA( mset, Length(mset) ); + nr := NrArrangementsSetA( mset ); else nr := NrArrangementsMSetA( mset, Length(mset) ); fi; From fa5820a70413de4316dfb9022225a61cc3f7d7ca Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Fri, 12 Jan 2024 17:29:12 +0000 Subject: [PATCH 03/14] Remove unused function arg from DxEigenbase --- lib/ctblgrp.gi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/ctblgrp.gi b/lib/ctblgrp.gi index 5f45e94397..46329b2562 100644 --- a/lib/ctblgrp.gi +++ b/lib/ctblgrp.gi @@ -628,9 +628,9 @@ end ); ############################################################################# ## -#F DxEigenbase(,) . . . . . components of Eigenvects resp. base +#F DxEigenbase() . . . . . components of Eigenvects resp. base ## -BindGlobal( "DxEigenbase", function(M,f) +BindGlobal( "DxEigenbase", function(M) local dim,i,eigenvalues,base,minpol,bases; minpol:=MinimalPolynomial(BaseDomain(M),M); @@ -764,7 +764,7 @@ InstallGlobalFunction(SplitStep,function(D,bestMat) N[row,col]:=Row[activeCols[col]]; od; od; - eigen:=DxEigenbase(N,f); + eigen:=DxEigenbase(N); # Base umrechnen base:=Matrix(BaseDomain(base[1]),base); eigenbase:=List(eigen.base,i->List(i,j->j*base)); From 90a3ce04105b97224a6796a3343518ed58ad521e Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Fri, 12 Jan 2024 17:29:50 +0000 Subject: [PATCH 04/14] Remove unused function args from FingerprintPerm I'd like to update the description of the function, but I have no idea what it does. --- lib/ctblperm.gi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/ctblperm.gi b/lib/ctblperm.gi index 7f9e6594d7..a5cd30a8c1 100644 --- a/lib/ctblperm.gi +++ b/lib/ctblperm.gi @@ -16,7 +16,7 @@ #F FingerprintPerm( , , , , , ) #F Entry i,j of the matrix of el in the permutation representation of G ## -BindGlobal( "FingerprintPerm", function(D,el,i,j,orbitJ,representatives) +BindGlobal( "FingerprintPerm", function(D,el,orbitJ,representatives) local x,a,cycle,cycles; a:=0; #cycles:=Cycles(el,D.group.orbit); @@ -55,7 +55,7 @@ BindGlobal("CheapIdentificationPermGroup",function(D,el) od; fi; if t in D.fingerprintCandidates then - Add(s,-FingerprintPerm(D,el,D.p1,D.p2,D.fingerprintOrbitStabilizer, + Add(s,-FingerprintPerm(D,el,D.fingerprintOrbitStabilizer, D.fingerprintRepresentatives)); fi; return s; @@ -205,7 +205,7 @@ local k,structures,ambiguousStructures,i,j,p,cem,ces,z,t,cen,a, c:=Filtered([1..D.klanz],i->IdentificationPermGroup(D, D.classreps[i])=s); f:=List(c,i->FingerprintPerm(D, - D.classreps[i],D.p1,D.p2,fos,fr)); + D.classreps[i],fos,fr)); if Length(Set(f))>1 then Add(fc,s); fi; od; From db54c3f44342aa901278f3b94f0e18046bf01657 Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Fri, 12 Jan 2024 17:35:53 +0000 Subject: [PATCH 05/14] Use ReturnFail rather than function returning fail --- lib/custom_streams.gi | 8 ++------ lib/factgrp.gi | 5 +---- 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/lib/custom_streams.gi b/lib/custom_streams.gi index 01798f9ddc..c3c582446f 100644 --- a/lib/custom_streams.gi +++ b/lib/custom_streams.gi @@ -200,9 +200,7 @@ end ); InstallMethod( RewindStream, "input text custom", [ IsInputTextStream and IsInputTextCustomRep ], -function( stream ) - return fail; -end ); +ReturnFail ); ############################################################################# @@ -213,9 +211,7 @@ InstallMethod( SeekPositionStream, "input text custom", [ IsInputTextStream and IsInputTextCustomRep, IsInt ], -function( stream, pos ) - return fail; -end ); +ReturnFail ); ############################################################################# diff --git a/lib/factgrp.gi b/lib/factgrp.gi index ce9a434c17..0737087b7b 100644 --- a/lib/factgrp.gi +++ b/lib/factgrp.gi @@ -1289,10 +1289,7 @@ RedispatchOnCondition(FindActionKernel,IsIdenticalObj,[IsGroup,IsGroup], [IsGroup and IsFinite,IsGroup],0); InstallMethod(FindActionKernel,"general case: can't do",IsIdenticalObj, - [IsGroup,IsGroup],0, -function(G,N) - return fail; -end); + [IsGroup,IsGroup],0,ReturnFail); BindGlobal("FactPermRepMaxDesc",function(g,n,maxlev) local lim,deg,all,c,recurse,use,start; From b4e015016634bb410931663bd89dd51f2fcbe0c6 Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Fri, 12 Jan 2024 17:36:14 +0000 Subject: [PATCH 06/14] Remove unused function args from Dt_ConvertCoeffVecs --- lib/dt.g | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/dt.g b/lib/dt.g index 3248e021fa..01d1247bb8 100644 --- a/lib/dt.g +++ b/lib/dt.g @@ -255,7 +255,7 @@ end ); ## a pair [j, k] occurring in [i] means that ## [i] occurs in f_j with coefficient k. ## -BindGlobal( "Dt_ConvertCoeffVecs", function(evlistvec, pr) +BindGlobal( "Dt_ConvertCoeffVecs", function(evlistvec) local i,j,res; for i in [1..Length(evlistvec)] do @@ -658,7 +658,7 @@ BindGlobal( "Calcrepsn", function(n, avec, pr, max) # finally convert the polynomials to the final state pols := Dt_Convert(pols); if pols <> 0 then - Dt_ConvertCoeffVecs(pols.evlistvec, pr); + Dt_ConvertCoeffVecs(pols.evlistvec); fi; return pols; end ); From 98e5fb52cfb2116e095b7701b4e09d759a8e0920 Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 12:54:48 +0000 Subject: [PATCH 07/14] Remove unused function TFEvalRFHom This function isn't used anywhere in the GAP library, or anywhere in the gap-4.12.2 archive. --- lib/fitfree.gd | 3 --- lib/fitfree.gi | 23 ----------------------- 2 files changed, 26 deletions(-) diff --git a/lib/fitfree.gd b/lib/fitfree.gd index 3f08944b8e..4768bbcc14 100644 --- a/lib/fitfree.gd +++ b/lib/fitfree.gd @@ -182,9 +182,6 @@ DeclareGlobalFunction("TFMakeInducedPcgsModulo"); DeclareGlobalFunction("OrbitsRepsAndStabsVectorsMultistage"); DeclareGlobalFunction("OrbitMinimumMultistage"); -# utility function: Evaluate the homomorphism to radical factor ``by hand''. -DeclareGlobalFunction("TFEvalRFHom"); - ############################################################################# ## #F FittingFreeElementarySeries( , [, ]) diff --git a/lib/fitfree.gi b/lib/fitfree.gi index 7106d52fd5..fd46150396 100644 --- a/lib/fitfree.gi +++ b/lib/fitfree.gi @@ -450,28 +450,6 @@ local f; return f.radical; end ); -# evaluate homomorphism given by generators -# -InstallGlobalFunction(TFEvalRFHom,function( - # generators for whole group - pcgs,pcgsimgs, # radical part - freps,frimgs, # outside radical - quotelms, # images of freps in G/Rad - fgp, # Group generated by frimgs - elm, elmimg # element to be mapped and its image - ) - -local map,fword,repeval,q,freegens; - map:=EpimorphismFromFreeGroup(fgp); - freegens:=MappingGeneratorsImages(map)[1]; - fword:=PreImagesRepresentative(map,elmimg); - repeval:=MappedWord(fword,freegens,freps); - q:=elm/repeval; # will be trivial in factor, so in radical - return LinearCombinationPcgs(pcgsimgs,ExponentsOfPcElement(pcgs,q))* - MappedWord(fword,freegens,frimgs); -end); - - # We will be in the situation that an IGS has been corrected only on the # lowest level, i.e. the only obstacle to being an IGS is on the lowest # level. Thus the situation is that of a vector space and we do not need to @@ -1571,4 +1549,3 @@ local ff,i,j,c,q,a,b,prev,sub,m,k; od; return c; end); - From 3bdb0f141aed0fb516e1f11da8b0975ffd364ef4 Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 12:55:13 +0000 Subject: [PATCH 08/14] Remove another pointless function wrapper --- lib/factgrp.gi | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/factgrp.gi b/lib/factgrp.gi index 0737087b7b..025e7ebc4b 100644 --- a/lib/factgrp.gi +++ b/lib/factgrp.gi @@ -1280,10 +1280,7 @@ end); #M FindActionKernel() . . . . . . . . . . . . . . . . . . . . generic ## InstallMethod(FindActionKernel,"generic for finite groups",IsIdenticalObj, - [IsGroup and IsFinite,IsGroup],0, -function(G,N) - return GenericFindActionKernel(G,N); -end); + [IsGroup and IsFinite,IsGroup],0,GenericFindActionKernel); RedispatchOnCondition(FindActionKernel,IsIdenticalObj,[IsGroup,IsGroup], [IsGroup and IsFinite,IsGroup],0); From 3706683931617508889f7ed121671a7560741e60 Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 13:02:59 +0000 Subject: [PATCH 09/14] Remove unused func args from OrbitMinimumMultistage The extra arguments were added in 1d7361e296 in 2013, and removed again now. --- lib/clashom.gi | 6 ++---- lib/fitfree.gi | 3 +-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/lib/clashom.gi b/lib/clashom.gi index 0f982fa7d0..ef3fd14993 100644 --- a/lib/clashom.gi +++ b/lib/clashom.gi @@ -2146,11 +2146,9 @@ BindGlobal("LiftClassesEATrivRep", lvec:=Concatenation(vec{range},Zero(vec{[i*ssd+1..Length(vec)]})); result:=OrbitMinimumMultistage(stabradgens, List(stabradgens,x->bas*npcgsact(x)*basinv), - pcisom,0,0, # solvable size not needed stabfacgens, List(stabfacgens,x->bas*npcgsact(x)*basinv), stabfacimgs, - hom,0, #gpsz not needed OnRight,lvec,maxorb,#Maximum(List(lcands,x->x.len)), Set(lcands,x->x.rep)); a:=First(lcands,x->x.rep{range}=result.min{range}); @@ -2178,8 +2176,8 @@ BindGlobal("LiftClassesEATrivRep", if false and allcands[1].len>1 then Error(); fi; - a:=OrbitMinimumMultistage(pcgs,pcgsimgs,pcisom,0,0, - nsgens,nsimgs,nsfgens,hom,0, + a:=OrbitMinimumMultistage(pcgs,pcgsimgs, + nsgens,nsimgs,nsfgens, OnRight,vec,allcands[1].len,minvecs); a.nclass:=First(allcands,x->x.rep=a.min); return a; diff --git a/lib/fitfree.gi b/lib/fitfree.gi index fd46150396..c8f6657eae 100644 --- a/lib/fitfree.gi +++ b/lib/fitfree.gi @@ -781,8 +781,7 @@ local stabilizergen,st,stabrsub,stabrsubsz,ratio,subsz,sz,vp,stabrad, end); InstallGlobalFunction(OrbitMinimumMultistage, - function(pcgs,pcgsimgs,pcisom,solvsz,solvtriv,gens,imgs,fgens, - factorhom,gpsz,actfun,seed,orblen,stops) + function(pcgs,pcgsimgs,gens,imgs,fgens,actfun,seed,orblen,stops) #was: OrbitMinimumMultistage:=function(pcgs,pcgsimgs,gens,imgs,fgens,actfun,seed,orblen,stops) From a54f24db1ecedde7b7a84780593a53a3982acb3a Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 13:18:03 +0000 Subject: [PATCH 10/14] Remove unused function arg from LiftFactorFpHom This function isn't used anywhere else in the GAP library, or anywhere else in the gap-4.12.2 archive. --- grp/glzmodmz.gi | 2 +- lib/fitfree.gi | 6 +++--- lib/gpfpiso.gi | 2 +- lib/grpfp.gd | 4 ++-- lib/grplatt.gi | 8 +++----- lib/maxsub.gi | 2 +- 6 files changed, 11 insertions(+), 13 deletions(-) diff --git a/grp/glzmodmz.gi b/grp/glzmodmz.gi index f8930fdb90..a9916ea9b5 100644 --- a/grp/glzmodmz.gi +++ b/grp/glzmodmz.gi @@ -381,7 +381,7 @@ local oper,n,R,o,nrit, bas:=Basis(sub,bas); RUN_IN_GGMBI:=true; hom:=GroupGeneralMappingByImagesNC(g,fp,gens,GeneratorsOfGroup(fp)); - hom:=LiftFactorFpHom(hom,g,"M",SubgroupNC(g,basm),rec( + hom:=LiftFactorFpHom(hom,g,SubgroupNC(g,basm),rec( pcgs:=basm, prime:=p, decomp:=function(em) diff --git a/lib/fitfree.gi b/lib/fitfree.gi index c8f6657eae..665fae3350 100644 --- a/lib/fitfree.gi +++ b/lib/fitfree.gi @@ -937,7 +937,7 @@ local ser,hom,s,fphom,sf,sg,sp,fp,d,head,mran,nran,mpcgs,ocr,len,pcgs,gens; else # extend presentation RUN_IN_GGMBI:=true; # hack to skip Nice treatment - fphom:=LiftFactorFpHom(fphom,Source(fphom),false,false,mpcgs); + fphom:=LiftFactorFpHom(fphom,Source(fphom),false,mpcgs); RUN_IN_GGMBI:=false; fp:=Image(fphom); sp:=Concatenation(sp,mpcgs); @@ -1263,7 +1263,7 @@ local s,d,c,act,o,i,j,h,p,hf,img,n,k,ns,all,hl,hcomp, pcgs:=List([2..Length(dser)],x->ModuloPcgs(dser[x-1],dser[x])); for j in pcgs do RUN_IN_GGMBI:=true; # hack to skip Nice treatment - fphom:=LiftFactorFpHom(fphom,Source(fphom),false,false,j); + fphom:=LiftFactorFpHom(fphom,Source(fphom),false,j); RUN_IN_GGMBI:=false; od; gens:=MappingGeneratorsImages(fphom); @@ -1427,7 +1427,7 @@ local ser,hom,s,fphom,sf,sg,sp,fp,d,head,mran,nran,mpcgs,ocr,len,pcgs, else # extend presentation RUN_IN_GGMBI:=true; # hack to skip Nice treatment - fphom:=LiftFactorFpHom(fphom,Source(fphom),false,false,mpcgs); + fphom:=LiftFactorFpHom(fphom,Source(fphom),false,mpcgs); RUN_IN_GGMBI:=false; fp:=Image(fphom); sp:=Concatenation(sp,mpcgs); diff --git a/lib/gpfpiso.gi b/lib/gpfpiso.gi index c3cfd1e180..35af1dfb8e 100644 --- a/lib/gpfpiso.gi +++ b/lib/gpfpiso.gi @@ -635,7 +635,7 @@ function(hom,elm) end); InstallGlobalFunction(LiftFactorFpHom, -function(hom,G,M,N,mnsf) +function(hom,G,N,mnsf) local fpq, qgens, qreps, fpqg, rels, pcgs, p, f, qimg, idx, nimg, decomp, ngen, fp, hom2, di, source, dih, dec, i, j; fpq:=Range(hom); diff --git a/lib/grpfp.gd b/lib/grpfp.gd index a3657a114d..3df9ba0a01 100644 --- a/lib/grpfp.gd +++ b/lib/grpfp.gd @@ -1130,10 +1130,10 @@ DeclareGlobalFunction( "SubgroupGeneratorsCosetTable" ); ############################################################################# ## -#F LiftFactorFpHom(,,,,) +#F LiftFactorFpHom(,,,) ## ## -## +## ## ## ## Let hom be an epimorphism from a group G to a finitely presented diff --git a/lib/grplatt.gi b/lib/grplatt.gi index 329e6d1333..a3ce2bdc49 100644 --- a/lib/grplatt.gi +++ b/lib/grplatt.gi @@ -1062,7 +1062,7 @@ InstallGlobalFunction(LatticeViaRadical,function(arg) if H=fail or IsSubset(HN,a) then Add(nu,a);Add(nn,n); if Size(ser[i])>1 then - fphom:=LiftFactorFpHom(u[3][j],a,ser[i-1],ser[i],presmpcgs); + fphom:=LiftFactorFpHom(u[3][j],a,ser[i],presmpcgs); Add(nf,fphom); fi; fi; @@ -1200,7 +1200,7 @@ InstallGlobalFunction(LatticeViaRadical,function(arg) Assert(1,KernelOfMultiplicativeGeneralMapping(fphom)=nts[j]); if Size(nts[j])>Size(ser[i]) then - fphom:=LiftFactorFpHom(fphom,c,nts[j],ser[i],npcgs); + fphom:=LiftFactorFpHom(fphom,c,ser[i],npcgs); Assert(1, KernelOfMultiplicativeGeneralMapping(fphom)=ser[i]); fi; @@ -2309,7 +2309,7 @@ local G, # group Assert(3,KernelOfMultiplicativeGeneralMapping(l!.lattfpres)=M); # lift presentation # note: if notabelian mpcgs is an fp hom - l!.lattfpres:=LiftFactorFpHom(l!.lattfpres,l,M,N,mpcgs); + l!.lattfpres:=LiftFactorFpHom(l!.lattfpres,l,N,mpcgs); l!.obtain:="lift"; fi; od; @@ -3984,5 +3984,3 @@ local s,p,incl,cont,i,j,done; Sort(incl); return incl; end); - - diff --git a/lib/maxsub.gi b/lib/maxsub.gi index a07b74314d..f77a5a5d80 100644 --- a/lib/maxsub.gi +++ b/lib/maxsub.gi @@ -220,7 +220,7 @@ BindGlobal("MaximalSubgroupClassesSol",function(G) if homliftlevel+1 Date: Sat, 13 Jan 2024 13:22:14 +0000 Subject: [PATCH 11/14] Remove unused function arg from ComplementFactorFpHom This function isn't used anywhere else in the GAP library, or anywhere else in the gap-4.12.2 archive. --- lib/gpfpiso.gi | 2 +- lib/grpfp.gd | 8 ++++---- lib/grplatt.gi | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/gpfpiso.gi b/lib/gpfpiso.gi index 35af1dfb8e..d31ea3fa59 100644 --- a/lib/gpfpiso.gi +++ b/lib/gpfpiso.gi @@ -765,7 +765,7 @@ local fpq, qgens, qreps, fpqg, rels, pcgs, p, f, qimg, idx, nimg, decomp, end); InstallGlobalFunction(ComplementFactorFpHom, -function(h,g,m,n,k,ggens,cgens) +function(h,m,n,k,ggens,cgens) local di, hom; if IsBound(h!.decompinfo) then di:=ShallowCopy(h!.decompinfo); diff --git a/lib/grpfp.gd b/lib/grpfp.gd index 3df9ba0a01..7e49d9981e 100644 --- a/lib/grpfp.gd +++ b/lib/grpfp.gd @@ -1154,16 +1154,16 @@ DeclareGlobalFunction( "IsomorphismFpGroupByChiefSeriesFactor" ); ############################################################################# ## -#F ComplementFactorFpHom(,,,,,,) +#F ComplementFactorFpHom(,,,,,) ## ## -## +## ## ## -## Let hom be an epimorphism from a group G to a finitely presented +## Let hom be an epimorphism from a group G to a finitely presented ## group F with kernel M and M/N be elementary abelian and C/N a ## complement to M in G/N. The set Cgens is a set of generators of -## C modulo N, Ggens are corresponding representatives in G. +## C modulo N, Ggens are corresponding representatives in G. ## This function constructs a new epimorphism from C onto F. ##

## No test of the arguments is performed. diff --git a/lib/grplatt.gi b/lib/grplatt.gi index a3ce2bdc49..8575cdef87 100644 --- a/lib/grplatt.gi +++ b/lib/grplatt.gi @@ -1195,7 +1195,7 @@ InstallGlobalFunction(LatticeViaRadical,function(arg) if Size(ser[i])>1 then # need to lift presentation fphom:=ComplementFactorFpHom(ocr.factorfphom, - a,ser[i-1],nts[j],c, + ser[i-1],nts[j],c, ocr.generators,cgs[w.pos]); Assert(1,KernelOfMultiplicativeGeneralMapping(fphom)=nts[j]); @@ -2084,7 +2084,7 @@ local G, # group # transfer a known presentation if not IsPcGroup(k) then k!.lattfpres:=ComplementFactorFpHom( - ocr.factorfphom,l,M,N,k,ocr.generators,comp); + ocr.factorfphom,M,N,k,ocr.generators,comp); Assert(3,KernelOfMultiplicativeGeneralMapping(k!.lattfpres)=N); fi; k!.obtain:="compl"; From 56dd4378529074c455e31d5d62d7bc830175409e Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 13:30:05 +0000 Subject: [PATCH 12/14] Use ReturnTrue and not function returning true --- lib/gprd.gi | 5 +---- lib/grp.gi | 5 +---- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/lib/gprd.gi b/lib/gprd.gi index 58f9a72858..359cedfec5 100644 --- a/lib/gprd.gi +++ b/lib/gprd.gi @@ -1139,10 +1139,7 @@ end); ## InstallMethod( \in,"generic wreath product", IsCollsElms, [ IsGroup and HasWreathProductInfo and IsWreathProductElementCollection - and IsWholeFamily, IsWreathProductElement ], 0, -function(G,e) - return true; -end); + and IsWholeFamily, IsWreathProductElement ], 0, ReturnTrue); # # semidirect product diff --git a/lib/grp.gi b/lib/grp.gi index 1e64bafa90..e3f0bd5af6 100644 --- a/lib/grp.gi +++ b/lib/grp.gi @@ -5570,10 +5570,7 @@ function(G,l) end); InstallOtherMethod( KnowsHowToDecompose,"trivial group",true, - [IsGroup,IsEmpty], -function(G,l) - return true; -end); + [IsGroup,IsEmpty], ReturnTrue); InstallMethod( KnowsHowToDecompose, "group: use GeneratorsOfGroup", From ffb2b9f7297ec8e00780fd11c6071ebdee03a27b Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 13:30:37 +0000 Subject: [PATCH 13/14] Remove unused function arg from PowerMapOfGroupWithInvariants This function isn't used anywhere else in the GAP library, or anywhere else in the gap-4.12.2 archive. --- lib/grp.gd | 4 ++-- lib/grp.gi | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/grp.gd b/lib/grp.gd index d4cf7a50ee..0aa1463897 100644 --- a/lib/grp.gd +++ b/lib/grp.gd @@ -4606,10 +4606,10 @@ DeclareOperation( "PowerMapOfGroup", [ IsGroup, IsInt, IsHomogeneousList ] ); ############################################################################# ## -#F PowerMapOfGroupWithInvariants( , , , ) +#F PowerMapOfGroupWithInvariants( , , ) ## ## -## +## ## ## ## is a list of integers, at position i the position of the conjugacy diff --git a/lib/grp.gi b/lib/grp.gi index e3f0bd5af6..1712ba289b 100644 --- a/lib/grp.gi +++ b/lib/grp.gi @@ -5424,10 +5424,10 @@ end); ############################################################################# ## -#F PowerMapOfGroupWithInvariants( , , , ) +#F PowerMapOfGroupWithInvariants( , , ) ## InstallGlobalFunction( PowerMapOfGroupWithInvariants, - function( G, n, ccl, invariants ) + function( n, ccl, invariants ) local reps, # list of representatives ord, # list of representative orders @@ -5522,7 +5522,7 @@ InstallMethod( PowerMapOfGroup, "method for a group", [ IsGroup, IsInt, IsHomogeneousList ], function( G, n, ccl ) - return PowerMapOfGroupWithInvariants( G, n, ccl, [] ); + return PowerMapOfGroupWithInvariants( n, ccl, [] ); end ); @@ -5536,7 +5536,7 @@ InstallMethod( PowerMapOfGroup, "method for a permutation group", [ IsGroup and IsPermCollection, IsInt, IsHomogeneousList ], function( G, n, ccl ) - return PowerMapOfGroupWithInvariants( G, n, ccl, [CycleStructurePerm] ); + return PowerMapOfGroupWithInvariants( n, ccl, [CycleStructurePerm] ); end ); @@ -5550,7 +5550,7 @@ InstallMethod( PowerMapOfGroup, "method for a matrix group", [ IsGroup and IsRingElementCollCollColl, IsInt, IsHomogeneousList ], function( G, n, ccl ) - return PowerMapOfGroupWithInvariants( G, n, ccl, [ TraceMat ] ); + return PowerMapOfGroupWithInvariants( n, ccl, [ TraceMat ] ); end ); From 8e3f9f401a312b55f46cad0dbb8d769fbd9c1d7f Mon Sep 17 00:00:00 2001 From: "James D. Mitchell" Date: Sat, 13 Jan 2024 13:35:35 +0000 Subject: [PATCH 14/14] Fix doc typo --- lib/grp.gd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/grp.gd b/lib/grp.gd index 0aa1463897..401edcd7d6 100644 --- a/lib/grp.gd +++ b/lib/grp.gd @@ -4613,7 +4613,7 @@ DeclareOperation( "PowerMapOfGroup", [ IsGroup, IsInt, IsHomogeneousList ] ); ## ## ## is a list of integers, at position i the position of the conjugacy -## class containimg the n-th powers of elements in class i +## class containing the n-th powers of elements in class i ## of ccl. ## The list invariants contains all invariants besides element order ## that shall be used before membership tests.