Skip to content

Commit

Permalink
FIX: Homomorphism order method tests for finite domain.
Browse files Browse the repository at this point in the history
This fixes gap-system#3097
  • Loading branch information
hulpke authored and ssiccha committed Mar 27, 2019
1 parent a47dc18 commit 4e018ef
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/morpheus.gi
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ InstallMethod(Order,"for automorphisms",true,[IsGroupHomomorphism],0,
function(hom)
local map,phi,o,lo,i,j,start,img,d,nat,ser,jord,first;
d:=Source(hom);
if not (HasIsFinite(d) and IsFinite(d)) then
TryNextMethod();
fi;
if Size(d)<=10000 then
ser:=[d,TrivialSubgroup(d)]; # no need to be clever if small
else
Expand Down
5 changes: 5 additions & 0 deletions tst/testbugfix/2018-12-11-fphomord.tst
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# hom. order of infinite group in special case (fixing #3097)
gap> f := FreeGroup(2);;
gap> x := GroupHomomorphismByImages(f,f,[f.1,f.2],[f.2,f.1]);;
gap> Order(x);
2

0 comments on commit 4e018ef

Please sign in to comment.