Skip to content

Commit

Permalink
Fixed tests and version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
laurentbartholdi committed Mar 19, 2019
1 parent 00ac7b0 commit 92c6bd0
Show file tree
Hide file tree
Showing 7 changed files with 112 additions and 104 deletions.
8 changes: 4 additions & 4 deletions PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
SetPackageInfo( rec(
PackageName := "IMG",
Subtitle := "Computations with iterated monodromy groups",
Version := "0.2.2",
Date := "16/03/2019",
Version := "0.2.3",
Date := "19/03/2019",
## <#GAPDoc Label="Version">
## <!ENTITY Version "0.2.2">
## <!ENTITY Date "16/03/2019">
## <!ENTITY Version "0.2.3">
## <!ENTITY Date "19/03/2019">
## <#/GAPDoc>
Persons := [
rec(
Expand Down
7 changes: 6 additions & 1 deletion src/img.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ static Obj COMPLEX_ROOTS (Obj self, Obj coeffs)
Obj result;
Int i, numroots, degree = LEN_PLIST(coeffs)-1;
xcomplex op[degree+1], zero[degree];

bool real = true;

if (degree < 1)
return Fail;

Expand All @@ -81,6 +82,8 @@ static Obj COMPLEX_ROOTS (Obj self, Obj coeffs)
__imag__(op)[degree-i] = VAL_FLOAT(ELM_PLIST(ELM_PLIST(coeffs,i+1),2));
if (isnan(__real__(op)[degree-i]) || isnan(__imag__(op)[degree-i]))
return Fail;
if (__imag__(op)[degree-i] != 0.0)
real = false;
}

#ifdef DEBUG_COMPLEX_ROOTS
Expand All @@ -106,6 +109,8 @@ static Obj COMPLEX_ROOTS (Obj self, Obj coeffs)
result = ALLOC_PLIST(numroots);
for (i = 1; i <= numroots; i++) {
Obj t = ALLOC_PLIST(2);
if (real && fabs(__imag__(zero)[i-1]) < 2*degree*DBL_EPSILON*fabs(__real__(zero)[i-1]))
__imag__(zero)[i-1] = 0.0;
set_elm_plist(t,1, NEW_FLOAT(__real__(zero)[i-1]));
set_elm_plist(t,2, NEW_FLOAT(__imag__(zero)[i-1]));
set_elm_plist(result,i, t);
Expand Down
8 changes: 6 additions & 2 deletions src/p1.c
Original file line number Diff line number Diff line change
Expand Up @@ -776,8 +776,10 @@ static Obj P1PREIMAGES(Obj self, Obj map, Obj objp)
return Fail;

Obj obj = ALLOC_PLIST(deg);
for (i = 0; i < numroots; i++)
for (i = 0; i < numroots; i++) {
// clean?
set_elm_plist(obj,i+1, NEW_P1POINT(zero[i]));
}
for (i = numroots; i < deg; i++)
set_elm_plist(obj,i+1, P1infinity);
return obj;
Expand All @@ -796,8 +798,10 @@ static Obj P1CRITICAL(Obj self, Obj map)
if (numroots < 0)
return Fail;
Obj obj = ALLOC_PLIST(2*deg-2);
for (i = 0; i < numroots; i++)
for (i = 0; i < numroots; i++) {
// clean?
set_elm_plist(obj,i+1, NEW_P1POINT(zero[i]));
}
for (i = numroots; i < 2*deg-2; i++)
set_elm_plist(obj,i+1, P1infinity);
return obj;
Expand Down
2 changes: 1 addition & 1 deletion tst/chapter-12.tst
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,6 @@ gap>
gap>
gap> STOP_TEST( "chapter-12.tst", 3*10^8 );
fr:chapter 12
GAP4stones: 10000
msecs: 0

#E chapter-12.tst . . . . . . . . . . . . . . . . . . . . . . . . . ends here
55 changes: 28 additions & 27 deletions tst/chapter-9-a.tst
Original file line number Diff line number Diff line change
Expand Up @@ -25,48 +25,49 @@ gap> e := EquivalenceRelationPartition(ExternalAnglesRelation(2,5));
[ 19/31, 20/31 ], [ 21/31, 22/31 ], [ 5/7, 6/7 ], [ 11/15, 4/5 ],
[ 23/31, 24/31 ], [ 25/31, 26/31 ], [ 13/15, 14/15 ], [ 27/31, 28/31 ],
[ 29/31, 30/31 ] ]
gap> ForAll(e,p->SupportingRays(PolynomialIMGMachine(2,[p[1]]))[2][1][1]*2 in [p[1],p[2],p[1]+1,p[2]+1]);
gap> ForAll(e,p->SupportingRays(PolynomialSphereMachine(2,[p[1]]))[2][1][1]*2 in [p[1],p[2],p[1]+1,p[2]+1]);
true
gap>
gap> Info(InfoFR,1,"Testing rabbit and z^2+i twists");
#I Testing rabbit and z^2+i twists
gap> ri := PolynomialIMGMachine(2,[],[1/6]);
<FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [ f\
1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>
gap> ri := PolynomialSphereMachine(2,[],[1/6]);
<sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group(\
[ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>
gap> model := StateSet(ri);
<free group on the generators [ f1, f2, f3, f4 ]>
<sphere group on generators [ f1, f2, f3, f4 ], ordering f4*f3*f2*f1>
gap> twist := GroupHomomorphismByImages(model,model,GeneratorsOfGroup(model),[model.1,model.2^(model.3*model.2),model.3^model.2,model.4]);
[ f1, f2, f3, f4 ] -> [ f1, f2^-1*f3^-1*f2*f3*f2, f2^-1*f3*f2, f4 ]
[ f1, f2, f3, f4 ] -> [ f1, f1*f4*f2*f3*f2, f2^-1*f3*f2, f4 ]
gap>
gap> r := PolynomialIMGMachine(2,[1/7],[]);
<FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [ f\
1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>
gap> r := PolynomialSphereMachine(2,[1/7],[]);
<sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group(\
[ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>
gap> model := StateSet(r);
<free group on the generators [ f1, f2, f3, f4 ]>
<sphere group on generators [ f1, f2, f3, f4 ], ordering f4*f3*f2*f1>
gap> twist := GroupHomomorphismByImages(model,model,GeneratorsOfGroup(model),[model.1^(model.2*model.1),model.2^model.1,model.3,model.4]);
[ f1, f2, f3, f4 ] -> [ f1^-1*f2^-1*f1*f2*f1, f1^-1*f2*f1, f3, f4 ]
[ f1, f2, f3, f4 ] -> [ f4*f3*f1*f2*f1, f1^-1*f2*f1, f3, f4 ]
gap> rt := List([0..4],i->r*twist^i);
[ <FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<FR machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]> ]
gap> m := PolynomialIMGMachine(3,[[3/4,1/12],[1/4,7/12]],[]);
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f3) on Group( [ f\
1, f2, f3 ] )/[ f3*f2*f1 ]>
[ <sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 2 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]> ]
gap> m := PolynomialSphereMachine(3,[[3/4,1/12],[1/4,7/12]],[]);
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f3) on Group(\
[ f1, f2, f3 ] )/[ f3*f2*f1 ]>
gap>
gap> Info(InfoFR,1,"Testing a folding");
#I Testing a folding
gap> fold1 := NewIMGMachine("a=<,,b,,,B>(1,2,3)(4,5,6)","b=<,,b*a/b,,,B*A/B>","A=<,,b*a,,,B*A>(3,6)","B=(1,6,5,4,3,2)");
<FR machine with alphabet [ 1 .. 6 ] on Group( [ a, b, A, B ] )/[ a*B*A*b ]>
gap> fold1 := NewSphereMachine("a=<,,b,,,B>(1,2,3)(4,5,6)","b=<,,b*a/b,,,B*A/B>","A=<,,(B*A)^-1,,,(b*a)^-1>(3,6)","B=(1,6,5,4,3,2)","A*b*a*B");
<sphere machine with alphabet [ 1 .. 6 ] on Group( [ a, b, A, B ] ) / [ A*b*a*\
B ]>
gap>
gap> STOP_TEST( "chapter-9-a.tst", 10^10 );
fr:chapter 9 (1/2)
GAP4stones: 4681000
msecs: 503

#E chapter-9-a.tst . . . . . . . . . . . . . . . . . . . . . . . . .ends here
130 changes: 64 additions & 66 deletions tst/chapter-9-b.tst
Original file line number Diff line number Diff line change
Expand Up @@ -26,59 +26,57 @@ gap> SetFloats(IEEE754FLOAT);
gap> z := P1z;
<z>
gap> a := RootsFloat((z-1)*(3*z^2-2*z^3)+1);
[ 0.598631+0.565259i, -0.426536, 0.598631-0.565259i, 1.72927-2.22045e-16i ]
[ 0.598631+0.565259i, -0.426536, 0.598631-0.565259i, 1.72927 ]
gap> c := RootsFloat((z^3+z)^3+z);
[ 0., 0.557573+0.540347i, -0.557573+0.540347i, -0.557573-0.540347i,
0.557573-0.540347i, 0.264425+1.26049i, -0.264425+1.26049i,
-0.264425-1.26049i, 0.264425-1.26049i ]
gap> am := List(a,a->IMGMachine((a-1)*(3*z^2-2*z^3)+1));
[ <FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f2*f1*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f2*f3*f1*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f2*f1*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f1*f2*f4 ]> ]
gap> cm := List(c,c->IMGMachine(z^3+c));
[ <FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f2) on Group( [\
f1, f2 ] )/[ f1*f2 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f1*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f1*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f1*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f3*f1*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f1*f3*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f1*f3*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f1*f3*f2*f4 ]>,
<FR machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Group( [\
f1, f2, f3, f4 ] )/[ f1*f3*f2*f4 ]> ]
gap> am := List(a,a->SphereMachine((a-1)*(3*z^2-2*z^3)+1));
[ <sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]> ]
gap> cm := List(c,c->SphereMachine(z^3+c));
[ <sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f2) on Grou\
p( [ f1, f2 ] )/[ f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]>,
<sphere machine with alphabet [ 1 .. 3 ] and adder FRElement(...,f4) on Grou\
p( [ f1, f2, f3, f4 ] )/[ f4*f3*f2*f1 ]> ]
gap> m := ListX(am,cm,Mating);;
gap> RationalFunction(NewIMGMachine(am[2]));
<1.9353365831410638_z*z^3+(-6.5315742879608081_z)*z^2+5.2080077920476935_z*z+0\
.51788488659999687_z>
gap> RationalFunction(m[9+2]);
<((0.19853514848979054+0.094747862775783384i_z)*z^3+(0.36448217409192502+1.067\
1933890697718i_z)*z^2+(0.65828774719150207+0.56768707293267628i_z)*z+(-1.13054\
18372331943-1.8215142432570175i_z))/((0.42613189662774054+0.10853855675161406i\
_z)*z^3+(1.1298164009633644+1.950676369983551i_z)*z^2+(1.5115657119504351+0.85\
698452757134347i_z)*z+1._z)>
gap> P1MapBySphereMachine(am[2]);
<z^3+(-2.1398032727526402_z)*z+(-0.36023134081173841_z)>
gap> P1MapBySphereMachine(m[9+2]);
<((1.4686858846983573-1.0290716144155767i_z)*z^3+(1.9850056687104112-1.7893204\
8860004i_z)*z^2+(-1.8069445331386629-0.83371844877356505i_z)*z+(-1.66797918021\
99766+0.67701449505226674i_z))/((1.3981038147796185-1.4150160285253968i_z)*z^3\
+(1.8103784467122102-2.3473103431921412i_z)*z^2+(-2.1376242871497211-0.5505179\
5026414962i_z)*z+1._z)>
gap>
gap> Info(InfoFR,1,"An obstructed mating");
#I An obstructed mating
gap> RationalFunction(m[9+8]);
rec( machine := <FR machine with alphabet [ 1 .. 3 ] on Group(
[ f1, f2, f3, g1, g2, g3 ] )/[ f2*f3*f1*g1*g3*g2 ]>,
matrix := [ [ 1/2, 1 ], [ 1/2, 0 ] ], obstruction := [ f1*g1, f2^-1*g2^-1 ],
spider := <marked sphere on <triangulation with 9 vertices, 42 edges and 14 \
faces> marked by [ f1, f2, f3, g1, g2, g3 ] -> [ f1^-1*f4^-1, f3^-1*f2*f3, f3^\
-1*f5, f4*f1*f5^-1*f4^-1, f2^-1*f3, f4 ]> )
gap> P1MapBySphereMachine(m[9+6]);
rec(
machine := <sphere machine with alphabet [ 1, 2, 3 ] on Group( [ f1, f2, f3, g1, g2, g3 ] ) / [ f\
3*f2*f1*g3*g2*g1 ]>, matrix := [ [ 1/2, 1 ], [ 1/2, 0 ] ],
multicurve := [ f1*f3*f2*f1*f3*f2*f1*f3*f2*f1*g1*g3*g2*g1*g3*g2*g1*g3*g2*g1^G,
f1^-1*f2^-1*f1*f3*f2*f1*f3*f2*f1*f3*f2*f1*g2^-1*g3*g2*g1*g3*g2*g1*g3*g2*g1^G ] )
gap>
gap> Info(InfoFR,1,"Testing Triangulations");
#I Testing Triangulations
Expand All @@ -91,54 +89,54 @@ gap> DelaunayTriangulation(cube);
gap> DelaunayTriangulation(cube{[1,5]});
<triangulation with 6 vertices, 24 edges and 8 faces>
gap> p := List([[0.,0.,1.],[0.,0.,-1.],SphereP1(P1Point(1.e-4)),SphereP1(P1Point(0.,1.e4))],P1Sphere);
[ <0+0i>, <P1infinity>, <0.0001+0i>, <-0+10000i> ]
[ <0+0i>, <P1infinity>, <0.0001+0i>, <0+10000i> ]
gap> DelaunayTriangulation(p,100.);
<triangulation with 32 vertices, 180 edges and 60 faces>
gap>
gap> Info(InfoFR,1,"Testing RationalFunction");
#I Testing RationalFunction
gap> f := RationalFunction(PolynomialIMGMachine(2,[],[7/16]):param_unicritical);
<z^2+(-1.7712570233568821+0.066161509080687936i_z)>
gap> f := P1MapBySphereMachine(PolynomialSphereMachine(2,[],[7/16]):param_unicritical);
<z^2+(-1.771257023356245+0.066161509079844388i_z)>
gap>
gap> Info(InfoFR,1,"Testing Pilgrim's obstructed blowup of the torus");
#I Testing Pilgrim's obstructed blowup of the torus
gap> F := SphereGroup(4,[0,0,0,0],FreeGroup("a","b","c","d"));
<fp group of size infinity on the generators [ a, b, c, d ]>
gap> AssignGeneratorVariables(F); o := One(F);;
#I Assigned the global variables [ a, b, c, d ]
<sphere group on generators [ a, b, c, d ], ordering d*c*b*a>
gap> a := F.1;; b := F.2;; c := F.3;; d := F.4;; o := One(F);;
gap> M := FRMachine(F,[[c^-1,o,o,o,c],[o,o,o,d,d^-1],[a,o,o,a^-1,o],[b,o,d,a,c]],
> [(1,5)(2,4,3),(1,2)(4,5),(1,4)(2,3,5),()]);
<FR machine with alphabet [ 1 .. 5 ] on Group( [ a, b, c, d ] )>
<sphere machine with alphabet [ 1 .. 5 ] on Group( [ a, b, c, d ] ) / [ d*c*b*\
a ]>
gap> P1MapBySphereMachine(M);
rec(
machine := <FR machine with alphabet [ 1 .. 5 ] on Group( [ a, b, c, d ] )/[\
d*c*b*a ]>, matrix := [ [ 1 ] ], obstruction := [ a^-1*c^-1 ],
spider := <marked sphere on <triangulation with 7 vertices, 30 edges and 10 \
faces> marked by [ a, b, c, d ] -> [ f1^-1*f2^-1, f3^-1*f1, f3, f2 ]> )
machine := <sphere machine with alphabet [ 1, 2, 3, 4, 5 ] on Group( [ a, b,\
c, d ] ) / [ d*c*b*a ]>, matrix := [ [ 1 ] ], multicurve := [ a*c^G ] )
gap>
gap> Info(InfoFR,1,"Testing mating of airplane with z^2+i");
#I Testing mating of airplane with z^2+i
gap> m := Mating(PolynomialIMGMachine(2,[3/7],[]),PolynomialIMGMachine(2,[],[1/6]));
<FR machine with alphabet [ 1 .. 2 ] on Group( [ f1, f2, f3, g1, g2, g3 ] )/[ \
f3*f2*f1*g3*g2*g1 ]>
gap> m := Mating(PolynomialSphereMachine(2,[3/7],[]),PolynomialSphereMachine(2,[],[1/6]));
<sphere machine with alphabet [ 1 .. 2 ] on Group( [ f1, f2, f3, g1, g2, g3 ] \
) / [ f3*f2*f1*g3*g2*g1 ]>
gap> Unbind(f1); Unbind(f2); Unbind(f3); Unbind(g1); Unbind(g2); Unbind(g3);
gap> AssignGeneratorVariables(StateSet(m));
#I Assigned the global variables [ f1, f2, f3, g1, g2, g3 ]
gap> i := FreeGroup("f1","f2","f3","g1","x");
<free group on the generators [ f1, f2, f3, g1, x ]>
gap> i := SphereGroup([1,4,3,2,5],[0,0,0,0,0],i);
<sphere group on generators [ f1, f2, f3, g1, x ], ordering f1*g1*f3*f2*x>
gap> tm := ChangeFRMachineBasis(m,[f1^-1*g2,One(StateSet(m))]);;
gap> inj := GroupHomomorphismByImages(i,StateSet(m),GeneratorsOfGroup(i),[f1^g2,f2,f3,g1,f1*g3/f1*g2]);
[ f1, f2, f3, g1, x ] -> [ g2^-1*f1*g2, f2, f3, g1, f1*g3*f1^-1*g2 ]
gap> m2 := SubFRMachine(tm,inj);
<FR machine with alphabet [ 1 .. 2 ] on Group( [ f1, f2, f3, g1, x ] )/[ f3*f2\
*x*f1*g1 ]>
gap> RationalFunction(m2);
<((2.1173218773245877+0.092523780325534474i_z)*z^2+(3.6019898773482266+1.59353\
23696078603i_z)*z+(2.3547834193556909+1.5278264334816143i_z))/((-4.64791571561\
72919-5.8835287029321073i_z)*z+1._z)>
<sphere machine with alphabet [ 1 .. 2 ] on Group( [ f1, f2, f3, g1, x ] ) / [\
f1*g1*f3*f2*x ]>
gap> P1MapBySphereMachine(m2);
<((-1.1898473846113464+0.24902829777699695i_z)*z^2+(1.9648756079548171+1.99403\
77105934426i_z)*z+(-0.65573526775326108-2.4418235808459454i_z))/((3.4179914358\
760768+2.610275400738987i_z)*z+1._z)>
gap>
gap> STOP_TEST( "chapter-9-b.tst", 10^10 );
fr:chapter 9 (2/2)
GAP4stones: 2498000
msecs: 13604

#E chapter-9-b.tst . . . . . . . . . . . . . . . . . . . . . . . . .ends here
6 changes: 3 additions & 3 deletions tst/testall.g
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
LoadPackage("img");
SetInfoLevel(InfoIMG,1);
dirs := DirectoriesPackageLibrary("img","tst");
ReadTest(Filename(dirs,"chapter-12.tst"));
ReadTest(Filename(dirs,"chapter-9-a.tst"));
ReadTest(Filename(dirs,"chapter-9-b.tst"));
Test(Filename(dirs,"chapter-12.tst"), rec(compareFunction := "uptowhitespace"));
Test(Filename(dirs,"chapter-9-a.tst"), rec(compareFunction := "uptowhitespace"));
Test(Filename(dirs,"chapter-9-b.tst"), rec(compareFunction := "uptowhitespace"));

0 comments on commit 92c6bd0

Please sign in to comment.