Mappings can be composed by the operator "*"
gap> C:=GF(2);
GF(2)
gap> g:=MappingByFunction(B,C,x->Z(2)*x);
MappingByFunction( Domain([ 0 .. 15 ]), GF(2), function( x ) ... end )
gap> f*g;
CompositionMapping( MappingByFunction( Domain(
[ 0 .. 15 ]), GF(2), function( x ) ... end ), MappingByFunction( Domain(
[ 1 .. 100 ]), Domain([ 0 .. 15 ]), function( x ) ... end ) )
gap> g*f;
Error, no method found! ...
gap> Source(f*g); Range(f*g); Image(f*g);
Domain([ 1 .. 100 ])
GF(2)
[ 0*Z(2), Z(2)^0 ]
gap> IsSurjective(f*g) and not IsInjective(f*g);
true
For a fixed right quasigroup Q
, permutations can be understood in two ways:
Q
.f
is a parent permutation of Q
if it restricts to a permutation of the set ParentInd( Q )
.gap> AsParentPerm(T,(3,6));
(6,15)
Elements( Q )
.f
is a canonical permutation on Q
if it restricts to a permutation on [1..Size(Q)]
.gap> AsCanonicalPerm(T,(3,6));
(2,3)
A permutation does not keep track of
Q
, the right quasigroupQ
must be provided.
For fixed right quasigroups Q1
, Q2
, transformations can be understood in two ways:
Q1
and Q2
.t
is a parent transformation from Q1
to Q2
if for every i
in ParentInt( Q1 )
we have i^t
in ParentInd( Q2 )
.Q1
and Q2
.t
is a canonical transformation from Q1
to Q2
if for every i
in [1..Size(Q1)]
we have i^t
in [1..Size(Q2)]
.A transformation does not keep track of
Q1
andQ2
. The right quasigroupsQ1
andQ2
must therefore be provided.
Given right quasigroups Q1
and Q2
, a mapping from Q1
to Q2
is represented in one of the following ways:
Q1
and range Q2
(used for mappings between two distinct right quasigroups, for instance for homomorphisms),gap> Q:=AffineQuandle(10,3);
<quandle of size 10>
gap> LeftTranslation(Q,Q.3);
Transformation( [ 7, 5, 3, 1, 9, 7, 5, 3, 1, 9 ] )
Q1 = Q2
, for instance for translations in quasigroups, automorphisms, etc.).gap> RightTranslation(Q,Q.3);
(1,7,5,9)(2,10,4,6)
gap> G:=SmallGroup(21,1); StructureDescription(G);
<pc group of size 21 with 2 generators>
"C7 : C3"
gap> M:=CheinLoop(G);
<Moufang loop of size 42>
gap> emb:=MappingByFunction(G,M,x->M[[0,x]]);
MappingByFunction( C7 : C3, <Moufang loop of size 42>, \
function( x ) ... end )
gap> RespectsMultiplication(emb);
true
Remainder: R.i
refers to the index R
gap> S:=Subloop(M,Image(emb,GeneratorsOfGroup(G)));
<Moufang loop of size 21>
gap> T:=DerivedSubloop(S);
<Moufang loop of size 7>
gap> ParentInd(T);
[ 1, 3, 6, 9, 12, 15, 18 ]
gap> T.3=S.3 and T.3=M.3 and not T.3=Elements(T)[3];
true
gap> G; S; T; ParentInd(T);
C7 : C3
<Moufang loop of size 21>
<Moufang loop of size 7>
[ 1, 3, 6, 9, 12, 15, 18 ]
gap> AutomorphismGroup(T);
Group([ (3,6,12)(9,18,15), (3,9,6,18,12,15) ])
gap> IsomorphismRightQuasigroups(AsLoop(G),S);
MappingByFunction( <associative loop of size 21>, \
<Moufang loop of size 21>, function( x ) ... end )